/* 
 * KitFolio Modal Styles
 * Common styles for all modals in the KitFolio application
 */

/* Modal Overlay */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}
 
/* Modal Container */
.modal-container {
    background: #222222e6;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    padding: 25px;
    position: relative;
    color: #fff;
    max-height: 90vh;
    overflow-y: auto; 
    transform: scale(1);
} 

/* Modal Close Button */
.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    z-index: 10;
}

/* Modal Title */
.modal-title {
    font-size: 20px;
    margin-bottom: 20px;
    font-weight: bold;
    color: #fff;
}

/* Form Groups */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    color: #dedede;
    margin-bottom: 5px;
    font-weight: normal;
    font-size: 13px;
}

.form-group input, 
.form-group select {
    width: 100%;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #444;
    background: #333;
    color: #fff;
}

.form-group input:focus, 
.form-group select:focus {
    outline: none;
    border-color: #9BEC00;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

/* Buttons */
.btn-cancel {
    background: #f1f1f1;
    color: #333;
    border: none;
    border-radius: 6px;
    padding: 8px 15px;
    cursor: pointer;
}

.btn-submit {
    background: #9BEC00;
    color: #000;
    border: none;
    border-radius: 6px;
    padding: 8px 15px;
    cursor: pointer;
    font-weight: bold;
}

.btn-cancel:hover {
    background: #e0e0e0;
}

.btn-submit:hover {
    background: #8ad700;
}

/* Modal Content Grid (for bookmark display) */
.modal-content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 15px;
    margin-top: 15px;
    max-height: 400px;
    overflow-y: auto;
}

/* Bookmark actions in modal */
.modal-content-grid .bookmark-actions {
    position: absolute;
    top: 8px;
    left: 8px;
    opacity: 0;
    transition: opacity 0.2s;
    z-index: 15;
    pointer-events: auto;
}

.modal-content-grid .bookmark-item:hover .bookmark-actions {
    opacity: 1;
}

.modal-content-grid .bookmark-edit,
.modal-content-grid .bookmark-delete {
    background: rgba(0, 0, 0, 0.8);
    border: none;
    border-radius: 4px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #fff;
    padding: 0;
    margin-right: 4px;
    position: relative;
    z-index: 20;
    pointer-events: auto;
}

.modal-content-grid .bookmark-edit:hover,
.modal-content-grid .bookmark-delete:hover {
    background: rgba(0, 0, 0, 1);
}

/* Specific Modal Types */
/* Authentication Modal */
.auth-modal .modal-container {
    background-color: white;
    color: #333;
}

.auth-modal .modal-title {
    color: #333;
}

/* Permission Text */
.permission-text {
    color: #888;
    font-size: 12px;
    margin-top: 15px;
    line-height: 1.5;
}
