:root {
    --brand-navy: #0b1f5d;
    --brand-ocean: #3c4fdd;
    --brand-teal: #1c2f7d;
    --brand-gold: #99ecf2;
    --surface: #f7f9ff;
    --surface-strong: #ffffff;
    --text-main: #1c2f7d;
    --text-soft: #6a7691;
    --line-soft: rgba(31, 41, 55, 0.08);
    --shadow-soft: 0 24px 60px rgba(11, 31, 93, 0.12);
    --shadow-card: 0 18px 40px rgba(44, 59, 124, 0.10);
    --landing-soft: #99ecf2;
}

html {
    font-size: 14px !important;
}

html, body {
    min-height: 100%;
    background:
        radial-gradient(circle at top left, rgba(153, 236, 242, 0.45), transparent 24%),
        radial-gradient(circle at right center, rgba(60, 79, 221, 0.12), transparent 30%),
        linear-gradient(180deg, #f7f9ff 0%, #ffffff 58%, #f7f9ff 100%);
}

body.auth-page {
    display: block;
    height: auto;
    margin: 0;
    font-size: 14px !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    color: var(--text-main);
}

h1, h2, h3, h4, h5, .font-display {
    font-family: 'Manrope', sans-serif !important;
}

.auth-shell {
    min-height: 100vh;
    min-height: 100svh;
    padding: 24px;
    padding: max(24px, env(safe-area-inset-top, 0px)) max(24px, env(safe-area-inset-right, 0px)) max(24px, env(safe-area-inset-bottom, 0px)) max(24px, env(safe-area-inset-left, 0px));
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.auth-shell::before,
.auth-shell::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
    filter: blur(2px);
}

.auth-shell::before {
    width: 420px;
    height: 420px;
    top: -160px;
    right: -120px;
    background: radial-gradient(circle, rgba(24, 79, 144, 0.18), rgba(24, 79, 144, 0));
}

.auth-shell::after {
    width: 360px;
    height: 360px;
    bottom: -180px;
    left: -120px;
    background: radial-gradient(circle, rgba(216, 179, 108, 0.18), rgba(216, 179, 108, 0));
}

.auth-layout {
    max-width: 1080px;
    width: 100%;
    margin: 0 auto;
    min-height: 620px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.68);
    border-radius: 32px;
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.auth-layout > * {
    min-width: 0;
}

.brand-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.showcase-intro {
    margin-top: 32px;
}

.auth-showcase {
    position: relative;
    padding: 34px 34px 30px;
    background: #99ecf2;
    color: #000;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
}

.auth-showcase::before {
    content: "";
    position: absolute;
    inset: auto -80px 120px auto;
    width: 260px;
    height: 260px;
    border-radius: 38px;
    transform: rotate(28deg);
    background: rgba(153, 236, 242, 0.30);
}

.auth-showcase::after {
    content: "";
    position: absolute;
    inset: auto auto -110px -70px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(153, 236, 242, 0.18);
}

.auth-showcase > * {
    position: relative;
    z-index: 1;
}

.brand-mark {
    width: min(300px, 48vw);
    height: 92px;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    background: transparent;
    border: 0;
    box-shadow: none;
    overflow: visible;
}

.brand-mark img {
    width: 100%;
    max-height: 92px;
    height: auto;
    object-fit: contain;
    object-position: left center;
}

.brand-chip {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #10243d;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.showcase-title {
    font-size: clamp(1.75rem, 2.6vw, 2.65rem);
    line-height: 1.12;
    font-weight: 800;
    letter-spacing: -0.03em;
    max-width: 560px;
    margin: 1.2rem 0 0.9rem;
}

.showcase-copy {
    max-width: 520px;
    color: #10243d;
    font-size: 0.92rem;
    line-height: 1.65;
}

.showcase-points {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 1.5rem;
    max-width: 520px;
}

.showcase-point {
    display: flex;
    align-items: flex-start;
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.35);
    border: 1px solid rgba(11, 31, 93, 0.10);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.showcase-point-icon {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(11, 31, 93, 0.10);
    color: var(--brand-ocean);
    margin-right: 14px;
    font-size: 1rem;
}

.showcase-point-title {
    display: block;
    color: var(--brand-navy);
    font-size: 0.92rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
}

.showcase-point-desc {
    display: block;
    color: rgba(12, 30, 90, 0.82);
    font-size: 0.82rem;
    line-height: 1.5;
}

.showcase-footer {
    margin-top: 1.5rem;
    max-width: 520px;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.14);
}

.showcase-footer .eyebrow {
    color: rgba(12, 30, 90, 0.70);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.55rem;
}

.showcase-footer .body {
    color: rgba(12, 30, 90, 0.86);
    font-size: 0.9rem;
    line-height: 1.6;
}

.auth-showcase * {
    color: #10243d !important;
}

.auth-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px 26px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.88));
}

.auth-card {
    width: 100%;
    max-width: 430px;
    background: var(--surface-strong);
    border: 1px solid rgba(16, 36, 61, 0.06);
    border-radius: 24px;
    box-shadow: var(--shadow-card);
    padding: 28px;
    position: relative;
}

.auth-back {
    display: flex;
    align-items: center;
    width: fit-content;
    min-height: 44px;
}

.auth-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 6px;
    border-radius: 24px 24px 0 0;
    background: linear-gradient(90deg, #99ECF2 0%, #3c4fdd 100%);
}

.auth-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: #e9edff;
    color: var(--brand-navy);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border: 1px solid rgba(60, 79, 221, 0.14);
}

.auth-title {
    font-size: 1.65rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--text-main);
    margin: 1rem 0 0.55rem;
}

.auth-subtitle {
    color: var(--text-soft);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 1.45rem;
}

.premium-alert {
    border: 0;
    border-radius: 20px;
    box-shadow: 0 12px 28px rgba(60, 79, 221, 0.10);
}

.field-label {
    display: block;
    color: var(--text-main);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.auth-input-wrap {
    display: flex;
    align-items: center;
    min-height: 54px;
    background: #f2f5ff;
    border: 1px solid transparent;
    border-radius: 14px;
    padding: 0 14px;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease, transform 0.25s ease;
}

.auth-input-wrap:focus-within {
    background: #ffffff;
    border-color: rgba(60, 79, 221, 0.18);
    box-shadow: 0 14px 24px rgba(28, 47, 125, 0.12);
    transform: translateY(-1px);
}

.auth-input-icon {
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    border-radius: 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(60, 79, 221, 0.10);
    color: var(--brand-ocean);
    margin-right: 12px;
    font-size: 0.95rem;
}

.auth-input {
    flex: 1 1 0;
    min-width: 0;
    min-height: 50px;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--text-main) !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    padding: 0 !important;
    height: auto !important;
}

.auth-input::placeholder {
    color: #8a94b2 !important;
    font-weight: 500 !important;
}

.password-toggle {
    flex: 0 0 auto;
    min-height: 44px;
    border: 0;
    background: transparent;
    color: #7b8796;
    padding: 0 0 0 12px;
    cursor: pointer;
    font-weight: 700;
}

.auth-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin: 1.1rem 0 1.2rem;
}

.auth-help {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: var(--brand-ocean);
    font-size: 0.9rem;
    font-weight: 700;
}

.auth-help:hover {
    color: var(--brand-teal);
    text-decoration: none;
}

.auth-remember {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text-main);
    font-size: 13px;
    font-weight: 600;
    min-height: 44px;
    margin: 0;
    cursor: pointer;
}

.auth-remember input {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--brand-ocean);
}

.premium-submit {
    min-height: 54px;
    border: 0 !important;
    border-radius: 14px !important;
    background: #99ecf2 !important;
    color: #10243d !important;
    box-shadow: 0 18px 30px rgba(153, 236, 242, 0.38);
    font-size: 0.96rem !important;
    letter-spacing: 0.03em;
    transition: transform 0.25s ease, box-shadow 0.25s ease !important;
}

.premium-submit:hover,
.premium-submit:focus {
    transform: translateY(-2px);
    box-shadow: 0 24px 36px rgba(153, 236, 242, 0.42) !important;
}

.trust-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 1rem;
}

.trust-item {
    flex: 1 1 140px;
    padding: 9px 11px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid rgba(16, 36, 61, 0.05);
}

.trust-item .title {
    display: block;
    color: var(--text-main);
    font-size: 0.84rem;
    font-weight: 800;
    margin-bottom: 0;
}

.auth-note {
    margin-top: 1rem;
    color: var(--text-soft);
    font-size: 0.84rem;
    line-height: 1.7;
    text-align: center;
}

.auth-demo {
    margin-top: 18px;
    padding: 14px;
    border: 1px solid #d9e3f1;
    border-radius: 12px;
    background: #f3f7fc;
}

.auth-demo .btn {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-demo p {
    font-size: 12px;
    line-height: 1.55;
    color: var(--text-soft);
    text-align: center;
    margin: 12px 0 0;
}

@media (max-width: 1199.98px) {
    .auth-shell { padding: 16px; padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
    .auth-layout { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr); min-height: 0; border-radius: 24px; }
    .auth-showcase { padding: 28px; }
    .auth-panel { padding: 12px 20px; }
    .auth-card { padding: 20px; }
    .brand-mark { width: min(260px, 100%); height: 76px; }
    .brand-mark img { max-height: 76px; }
    .brand-chip, .showcase-footer, .auth-badge, .trust-strip { display: none; }
    .showcase-title { font-size: 2rem; line-height: 1.2; }
    .showcase-points { margin-top: 24px; }
    .auth-title { font-size: 1.75rem; margin: 0 0 8px; }
    .auth-back { margin-bottom: 16px !important; }
    .auth-subtitle { font-size: 14px; margin-bottom: 20px; }
    .auth-meta { margin: 8px 0 14px; gap: 4px 12px; }
}

/* Portrait tablets and split view get a short brand header above the form. */
@media (max-width: 1023.98px), (max-width: 1199.98px) and (orientation: portrait) {
    .auth-layout { display: block; max-width: 600px; }
    .auth-showcase { padding: 18px 28px; }
    .brand-row { justify-content: center; }
    .brand-mark { width: min(250px, 100%); height: 64px; }
    .brand-mark img { max-height: 64px; object-position: center; }
    .showcase-intro, .showcase-points { display: none; }
    .auth-panel { padding: 26px 32px 28px; }
    .auth-card { max-width: 480px; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: transparent; }
    .auth-card::before { display: none; }
    .auth-title { margin-top: 0; }
}

@media (max-width: 575.98px) {
    .auth-shell { padding: 12px; padding: max(12px, env(safe-area-inset-top, 0px)) max(12px, env(safe-area-inset-right, 0px)) max(12px, env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px)); }
    .auth-layout { border-radius: 20px; }
    .auth-showcase { padding: 14px 20px; }
    .brand-mark { width: min(220px, 100%); height: 56px; }
    .brand-mark img { max-height: 56px; }
    .auth-panel { padding: 22px 20px 24px; }
    .auth-title { font-size: 1.6rem; }
    .auth-input-wrap { padding: 0 10px; }
    .auth-input-icon { width: 30px; height: 30px; flex-basis: 30px; margin-right: 9px; }
    .password-toggle { padding-left: 8px; font-size: 12px; }
    .auth-back { font-size: 12px; }
    .premium-submit { white-space: normal; line-height: 1.4; padding: 12px; }
    .auth-note { font-size: 12px; line-height: 1.5; }
}

@media (max-width: 360px) {
    .auth-shell { padding: 8px; }
    .auth-panel { padding: 20px 16px; }
    .auth-meta { column-gap: 8px; }
    .auth-help, .auth-remember { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
    .auth-input-wrap, .premium-submit { transition: none !important; }
}

