@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Poppins:wght@500;600;700;800&display=swap');

:root {
    --blue-900: #0f2d52;
    --blue-700: #1e5a96;
    --blue-600: #2563a8;
    --green-600: #1a7a4a;
    --green-500: #22a058;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-400: #94a3b8;
    --gray-600: #475569;
    --gray-800: #1e293b;
    --radius: 16px;
    --font-display: 'Poppins', sans-serif;
    --font-body: 'Inter', sans-serif;
}

* { box-sizing: border-box; }

body.auth-page {
    font-family: var(--font-body);
    margin: 0;
    min-height: 100vh;
    background: var(--gray-100);
    color: var(--gray-800);
}

.auth-shell {
    display: flex;
    min-height: 100vh;
}

.auth-brand {
    flex: 1;
    background: linear-gradient(145deg, var(--blue-900) 0%, var(--blue-700) 55%, var(--green-600) 100%);
    color: white;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.auth-brand::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('https://images.unsplash.com/photo-1523050854058-8df90110c9f1?w=1200&q=80') center/cover;
    opacity: 0.15;
}

.auth-brand-inner {
    position: relative;
    z-index: 1;
    max-width: 420px;
}

.auth-brand-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--green-500), #34c471);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.auth-brand h1 {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.auth-brand p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.auth-brand-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.auth-brand-features li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.875rem;
}

.auth-brand-features i {
    color: #34c471;
    width: 20px;
    text-align: center;
}

.auth-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: white;
}

.auth-card {
    width: 100%;
    max-width: 420px;
}

.auth-card-header {
    margin-bottom: 2rem;
}

.auth-card-header h2 {
    font-family: var(--font-display);
    font-size: 1.625rem;
    font-weight: 700;
    color: var(--blue-900);
    margin-bottom: 0.35rem;
}

.auth-card-header p {
    color: var(--gray-600);
    font-size: 0.9375rem;
    margin: 0;
}

.auth-alert {
    border-radius: 12px;
    border: none;
    font-size: 0.875rem;
    padding: 0.85rem 1rem;
    margin-bottom: 1.25rem;
}

.auth-alert-danger {
    background: #fef2f2;
    color: #b91c1c;
}

.auth-field {
    margin-bottom: 1.25rem;
}

.auth-field label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 0.4rem;
}

.auth-input-wrap {
    position: relative;
}

.auth-input-wrap i.field-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-400);
    font-size: 0.9rem;
    pointer-events: none;
}

.auth-input-wrap .form-control {
    padding: 0.75rem 1rem 0.75rem 2.75rem;
    border-radius: 12px;
    border: 1.5px solid var(--gray-200);
    font-size: 0.9375rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.auth-input-wrap .form-control:focus {
    border-color: var(--blue-600);
    box-shadow: 0 0 0 4px rgba(37, 99, 168, 0.12);
}

.auth-submit {
    width: 100%;
    padding: 0.85rem;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--blue-700), var(--blue-600));
    color: white;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 16px rgba(30, 90, 150, 0.3);
}

.auth-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(30, 90, 150, 0.35);
    color: white;
}

.auth-demo-box {
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 1rem;
    margin-top: 1.5rem;
    font-size: 0.8125rem;
}

.auth-demo-box strong {
    display: block;
    color: var(--blue-900);
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.auth-demo-row {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.25rem 0;
    color: var(--gray-600);
}

.auth-demo-row code {
    color: var(--blue-700);
    font-size: 0.75rem;
    background: white;
    padding: 0.1rem 0.35rem;
    border-radius: 4px;
}

.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.8125rem;
    color: var(--gray-600);
}

.auth-footer a {
    color: var(--green-600);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

.auth-back {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--gray-600);
    text-decoration: none;
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
    transition: color 0.2s;
}

.auth-back:hover {
    color: var(--blue-700);
}

@media (max-width: 991.98px) {
    .auth-shell {
        flex-direction: column;
    }

    .auth-brand {
        padding: 2rem;
        min-height: auto;
    }

    .auth-brand h1 {
        font-size: 1.35rem;
    }

    .auth-brand-features {
        display: none;
    }

    .auth-panel {
        padding: 2rem 1.25rem 3rem;
    }
}
