/* AllRounderBaby Admin Panel — authentication pages.
   Split-screen layout: 70% hero image · 30% auth panel. */

.auth-page {
    display: flex;
    min-height: 100vh;
    width: 100%;
    background: #F7F8FA;
}

/* ---------- Left 70% : family / babies image ---------- */

.auth-hero {
    flex: 0 0 70%;
    max-width: 70%;
    background-image: linear-gradient(90deg, rgba(15, 27, 51, 0) 60%, rgba(15, 27, 51, 0.08) 100%),
        url('/images/auth/Babies-Left-side.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    /* Subtle right-edge fade so the image blends with the white panel. */
    position: relative;
}

/* ---------- Right 30% : auth panel ---------- */

.auth-panel {
    flex: 0 0 30%;
    max-width: 30%;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    padding: 3rem 2.25rem;
    box-shadow: -18px 0 40px -30px rgba(15, 27, 51, 0.28);
    overflow-y: auto;
}

/* Admin User (Step 2) — subtle cool tint distinguishes the second step. */
.auth-page.auth-mode-admin .auth-panel {
    background: #F7F9FC;
}

.auth-panel__inner {
    width: 100%;
    max-width: 360px;
    margin: 0 auto;
}

.auth-brand {
    text-align: center;
    margin-bottom: 1.65rem;
}

.auth-brand__logo {
    display: inline-block;
    max-width: 160px;
    height: auto;
}

/* ---------- Header block above the form ---------- */

.auth-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #172B4D;
    margin: 0 0 0.35rem;
    text-align: center;
}

.auth-subtitle {
    font-size: 0.9rem;
    color: #60708A;
    margin: 0 0 1.5rem;
    text-align: center;
}

.auth-step {
    display: inline-block;
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #52647E;
    padding: 0.28rem 0.7rem;
    border: 1px solid #D7E1EF;
    border-radius: 999px;
    background: #F1F5FA;
    margin-bottom: 0.65rem;
}

.auth-mode-label {
    display: block;
    margin-bottom: 0.55rem;
    color: #2859A7;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-align: center;
}

.auth-page.auth-mode-admin .auth-mode-label {
    color: #193A70;
}

/* ---------- Form controls polish ---------- */

.auth-panel .form-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: #263750;
    margin-bottom: 0.35rem;
}

.auth-panel .form-control,
.auth-panel .input-group-text,
.auth-panel .btn {
    border-radius: 0.5rem;
}

.auth-panel .input-group > .form-control {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.auth-panel .input-group > .input-group-text {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    background: #F1F5FA;
    color: #52647E;
    border-color: #D2D9E4;
}

.auth-panel .input-group > .btn-outline-secondary {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.auth-panel .form-control {
    min-height: 43px;
    padding: 0.55rem 0.85rem;
    font-size: 0.95rem;
    border-color: #D2D9E4;
}

.auth-panel .form-control:focus {
    border-color: #2859A7;
    box-shadow: 0 0 0 0.2rem rgba(40, 89, 167, 0.14);
}

.auth-panel .btn-primary {
    min-height: 42px;
    padding: 0.55rem 1rem;
    background: #2859A7;
    border-color: #2859A7;
    border-radius: 7px;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.auth-panel .btn-primary:hover,
.auth-panel .btn-primary:focus-visible {
    background: #1D478C;
    border-color: #1D478C;
}

.auth-panel .btn-primary:disabled {
    opacity: 0.75;
    cursor: progress;
}

/* OTP input specialization */
.auth-panel .form-control-otp {
    letter-spacing: 0.55em;
    text-align: center;
    font-size: 1.3rem;
    padding: 0.85rem 1rem;
}

/* Consistent link color (blue) — spec: LINKS must be blue.
   Exclude .btn so button colors (btn-primary, etc.) are not overridden. */
.auth-panel a:not(.btn),
.auth-panel .btn-link {
    color: #2859A7;
    text-decoration: none;
    font-weight: 500;
}

.auth-panel a:not(.btn):hover,
.auth-panel .btn-link:hover {
    color: #1D478C;
    text-decoration: underline;
}

.auth-panel .btn-link:focus {
    box-shadow: 0 0 0 0.2rem rgba(40, 89, 167, 0.18);
}

/* Small helper text */
.auth-help {
    font-size: 0.8rem;
    color: #60708A;
    text-align: center;
    margin-top: 1.5rem;
}

.auth-help small {
    color: #8D9AB0;
}

/* Field-level validation error text */
.auth-panel .text-danger {
    font-size: 0.8rem;
    color: #b02a37 !important;
}

/* Alerts inside the panel — trim padding */
.auth-panel .alert {
    padding: 0.65rem 0.85rem;
    font-size: 0.87rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
}
    .auth-panel .alert ul {
        margin-bottom: 0;
    }
    .auth-panel .alert ul li {
        list-style: none;
    }
/* ---------- Responsive ---------- */

/* Tablet: keep split but tighter */
@media (max-width: 1199.98px) {
    .auth-hero {
        flex-basis: 55%;
        max-width: 55%;
    }
    .auth-panel {
        flex-basis: 45%;
        max-width: 45%;
        padding: 2.5rem 2rem;
    }
}

/* Small tablet / large phone: hide hero, show compact brand band */
@media (max-width: 767.98px) {
    .auth-page {
        flex-direction: column;
    }

    .auth-hero {
        display: none;
    }

    .auth-panel {
        flex: 1 1 auto;
        max-width: 100%;
        padding: 2rem 1.25rem;
        box-shadow: none;
        min-height: 100vh;
    }

    .auth-panel__inner {
        max-width: 420px;
    }

    .auth-brand__logo {
        max-width: 140px;
    }
}

/* Extra small phones */
@media (max-width: 380px) {
    .auth-panel {
        padding: 1.5rem 1rem;
    }
    .auth-title {
        font-size: 1.2rem;
    }
}
