/* Auth Modal Styles */
.auth-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.auth-modal-content {
    background: #fff;
    border-radius: 12px;
    padding: 2.5rem;
    max-width: 420px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-height: 90vh;
    overflow-y: auto;
}

.auth-modal-close {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    background: none;
    border: none;
    font-size: 1.75rem;
    color: #999;
    cursor: pointer;
    line-height: 1;
}

.auth-modal-close:hover {
    color: #333;
}

.auth-form-panel h2 {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    color: #1f2937;
}

.auth-subtitle {
    text-align: center;
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.auth-field {
    margin-bottom: 1.25rem;
}

.auth-field label {
    display: block;
    font-weight: 600;
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
    color: #374151;
}

.auth-field input {
    width: 100%;
    padding: 0.7rem 0.9rem;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.auth-field input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.auth-field small {
    display: block;
    margin-top: 0.3rem;
    font-size: 0.75rem;
    color: #9ca3af;
}

.auth-code-input {
    text-align: center;
    font-size: 1.5rem !important;
    letter-spacing: 0.5rem;
}

.auth-btn {
    width: 100%;
    padding: 0.8rem;
    background: #2563eb;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 0.5rem;
}

.auth-btn:hover {
    background: #1d4ed8;
}

.auth-link-text {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.85rem;
    color: #6b7280;
}

.auth-link-text a {
    color: #2563eb;
    font-weight: 500;
}

.auth-link-text a:hover {
    color: #1d4ed8;
}

.auth-message {
    margin-top: 1rem;
    padding: 0.75rem;
    border-radius: 6px;
    text-align: center;
    font-size: 0.85rem;
}

.auth-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.auth-success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

/* Nav auth link styles */
.nav-divider {
    border-left: 1px solid #d1d5db;
    height: 1.2rem;
    margin: 0 0.5rem;
    align-self: center;
}

.nav-auth-link {
    color: #2563eb !important;
    font-weight: 500 !important;
}

.nav-auth-link:hover {
    color: #1d4ed8 !important;
}

.nav-logout-link {
    color: #dc2626 !important;
}

.nav-logout-link:hover {
    color: #991b1b !important;
}

/* Password toggle */
.password-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-wrapper input {
    width: 100%;
    padding-right: 60px;
}

.toggle-password {
    position: absolute;
    right: 8px;
    background: none;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    color: #6b7280;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}

.toggle-password:hover {
    color: #2563eb;
    border-color: #2563eb;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .auth-modal-content {
        padding: 1.75rem;
        width: 95%;
    }

    .nav-divider {
        border-left: none;
        border-top: 1px solid #e5e7eb;
        width: 100%;
        height: 0;
        margin: 0.5rem 0;
    }
}
