* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    background: #f7fafc;
    color: #1a202c;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ─── HEADER ─── */
.header {
    background: rgba(247, 250, 252, 0.85);
    padding: 1.25rem 2rem;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    border-bottom: 1px solid #e2e8f0;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.logo {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.logo img {
    height: 56px;
    width: auto;
    display: block;
    border-radius: 8px;
}

.back-link {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: #033744;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}

.back-link:hover {
    color: #011418;
}

.back-link svg {
    width: 16px;
    height: 16px;
}

/* ─── MAIN ─── */
main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 7rem 1.5rem 4rem;
    background: linear-gradient(160deg, #f0f7f8 0%, #f7fafc 60%, #e8f4f6 100%);
}

/* ─── CARD ─── */
.auth-card {
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 4px 32px rgba(3, 55, 68, 0.1), 0 1px 4px rgba(3, 55, 68, 0.06);
    padding: 2.75rem 2.5rem;
    width: 100%;
    max-width: 440px;
    animation: fadeInUp 0.5s ease-out backwards;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

.auth-card h1 {
    font-size: 1.875rem;
    font-weight: 700;
    color: #011418;
    margin-bottom: 0.4rem;
    letter-spacing: -0.4px;
}

.auth-card .subtitle {
    color: #64748b;
    font-size: 0.9375rem;
    margin-bottom: 2rem;
}

/* ─── ERROR ─── */
.error-msg {
    display: none;
    background: #fff1f2;
    border: 1px solid #fecdd3;
    color: #be123c;
    border-radius: 10px;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    margin-bottom: 1.25rem;
}

/* ─── FORM ─── */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.45rem;
}

.form-group input {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.9375rem;
    color: #1a202c;
    background: #f8fafc;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.form-group input:focus {
    border-color: #033744;
    box-shadow: 0 0 0 3px rgba(3, 55, 68, 0.1);
    background: #fff;
}

/* ─── REMEMBER + FORGOT ─── */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.75rem;
    margin-top: -0.25rem;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
    color: #4b5563;
}

.remember-me input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #033744;
    cursor: pointer;
}

.forgot-link {
    font-size: 0.875rem;
    color: #033744;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.forgot-link:hover {
    color: #011418;
    text-decoration: underline;
}

/* ─── SUBMIT BUTTON ─── */
.btn-submit {
    width: 100%;
    padding: 0.875rem;
    background: linear-gradient(135deg, #033744, #011418);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.15s;
    letter-spacing: 0.2px;
}

.btn-submit:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn-submit:active {
    transform: translateY(0);
}

/* ─── DIVIDER ─── */
.divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1.75rem 0;
    color: #9ca3af;
    font-size: 0.8125rem;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

/* ─── SOCIAL BUTTONS ─── */
.social-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.btn-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 0.8rem 1rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    background: #fff;
    font-size: 0.9375rem;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, transform 0.15s;
    text-decoration: none;
}

.btn-social:hover {
    background: #f8fafc;
    border-color: #033744;
    transform: translateY(-1px);
}

.btn-social svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* ─── SIGNUP LINK ─── */
.signup-prompt {
    text-align: center;
    margin-top: 1.75rem;
    font-size: 0.9rem;
    color: #6b7280;
}

.signup-prompt a {
    color: #033744;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

.signup-prompt a:hover {
    color: #011418;
    text-decoration: underline;
}

/* ─── FOOTER ─── */
.footer {
    background: #011418;
    color: #ffffff;
    padding: 2.5rem 2rem 1.75rem;
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.25rem;
}

.footer-links a {
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0 0.5rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #ffffff;
}

.footer p {
    color: rgba(255,255,255,0.35);
    font-size: 0.8125rem;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 770px) {
    .back-link span {
        display: none;
    }
}

@media (max-width: 480px) {
    .auth-card {
        padding: 2rem 1.5rem;
        border-radius: 16px;
    }

    .auth-card h1 { font-size: 1.625rem; }

    .footer-links {
        flex-direction: column;
        align-items: center;
        gap: 1.25rem;
    }

    .footer-links a { padding: 0; }
}

.password-field-wrapper {
                position: relative;
                display: flex;
                align-items: center;
            }
            .password-field-wrapper input {
                width: 100%;
                padding-right: 42px;
                box-sizing: border-box;
            }
            .toggle-password {
                position: absolute;
                right: 12px;
                top: 50%;
                transform: translateY(-50%);
                background: none;
                border: none;
                padding: 0;
                margin: 0;
                cursor: pointer;
                color: #8a8a8a;
                display: flex;
                align-items: center;
                justify-content: center;
            }
            .toggle-password:hover {
                color: #4a4a4a;
            }
            .toggle-password svg {
                width: 20px;
                height: 20px;
            }
            .btn-social--disabled {
                opacity: 0.5;
                cursor: not-allowed;
                pointer-events: none;
                filter: grayscale(60%);
            }
            .btn-social__soon {
                font-size: 0.75em;
                margin-left: 4px;
            }