/* Authentication Modal Styles */
.auth-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease-in-out;
}

.auth-modal-overlay.active {
    display: flex;
}

.auth-modal {
    background: white;
    border-radius: 20px;
    padding: 40px;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    position: relative;
    animation: slideUp 0.3s ease-in-out;
}

.auth-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    transition: color 0.3s;
}

.auth-modal-close:hover {
    color: #333;
}

.auth-modal h2 {
    margin-bottom: 10px;
    color: #333;
    font-size: 28px;
}

.auth-modal p {
    color: #666;
    margin-bottom: 30px;
}

.auth-form-group {
    margin-bottom: 20px;
}

.auth-form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
}

.auth-form-group input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    transition: border-color 0.3s;
}

.auth-form-group input:focus {
    outline: none;
    border-color: #8ab369;
}

.auth-submit-btn {
    width: 100%;
    padding: 14px;
    background: #8ab369;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

.auth-submit-btn:hover {
    background: #75a054;
}

.auth-submit-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.auth-toggle {
    text-align: center;
    margin-top: 20px;
    color: #666;
}

.auth-toggle a {
    color: #8ab369;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
}

.auth-toggle a:hover {
    text-decoration: underline;
}

.auth-error {
    background: #fee;
    color: #c33;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: none;
}

.auth-error.active {
    display: block;
}

.auth-success {
    background: #efe;
    color: #3c3;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: none;
}

.auth-success.active {
    display: block;
}

.auth-loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.auth-loading.active {
    display: block;
}

.auth-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #8ab369;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* User menu styles */
.user-menu {
    position: relative;
    display: none;
}

.user-menu.active {
    display: inline-block;
}

.user-menu-btn {
    background: #8ab369;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.user-menu-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    margin-top: 10px;
    min-width: 200px;
    display: none;
    z-index: 1000;
}

.user-menu-dropdown.active {
    display: block;
}

.user-menu-dropdown a {
    display: block;
    padding: 12px 20px;
    color: #333;
    text-decoration: none;
    transition: background 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.user-menu-dropdown a:hover {
    background: #f5f5f5;
}

.user-menu-dropdown a:first-child {
    border-radius: 10px 10px 0 0;
}

.user-menu-dropdown a:last-child {
    border-radius: 0 0 10px 10px;
    color: #c33;
}

/* Dashboard link styling */
#dashboard-menu-link {
    color: #8ab369 !important;
    font-weight: 600;
}

#dashboard-menu-link i {
    font-size: 16px;
}
