:root {
    color-scheme: light;
    --brand-50: #eef6ff;
    --brand-100: #d9e9ff;
    --brand-200: #bcd8ff;
    --brand-500: #2f7eff;
    --brand-700: #154cae;
    --brand-800: #103a85;
    --brand-950: #091d43;
    --ink-500: #5f728f;
    --ink-700: #354259;
    --ink-950: #0b1220;
    --white: #ffffff;
    --bg: #f8fbff;
    --border-soft: #e6edf7;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: #243042;
}

a {
    color: inherit;
}

button:not(:disabled),
[role="button"]:not([aria-disabled="true"]),
input[type="button"]:not(:disabled),
input[type="submit"]:not(:disabled),
input[type="reset"]:not(:disabled) {
    cursor: pointer;
}

#app {
    min-height: 100vh;
}

.loading-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 2rem;
}

.loading-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 2rem 2.25rem;
    border: 1px solid var(--border-soft);
    border-radius: 1.75rem;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 16px 40px rgba(11, 18, 32, 0.06);
    backdrop-filter: blur(20px);
}

.loading-progress {
    width: 4.25rem;
    height: 4.25rem;
    animation: loading-spin 1s linear infinite;
}

.loading-progress circle {
    fill: none;
    stroke-width: 6;
}

.loading-progress .loading-track {
    stroke: var(--border-soft);
}

.loading-progress .loading-indicator {
    stroke: #5a9dff;
    stroke-linecap: round;
    stroke-dasharray: 300;
    stroke-dashoffset: 75;
}

.loading-progress-text {
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--ink-500);
    white-space: nowrap;
}

@media (max-width: 480px) {
    .loading-shell {
        padding: 1rem;
    }

    .loading-card {
        padding: 1.5rem 1rem;
    }

    .loading-progress-text {
        letter-spacing: 0.1em;
    }
}

.page {
    min-height: 100vh;
    padding: 1.5rem;
    background: radial-gradient(circle at top left, rgba(47,126,255,0.18), transparent 32%), linear-gradient(135deg, #f7fbff 0%, #eef6ff 46%, #f8fbff 100%);
}

.content-page {
    display: flex;
    align-items: center;
    justify-content: center;
}

.shell {
    max-width: 1500px;
    margin: 0 auto;
    min-height: calc(100vh - 3rem);
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    overflow: hidden;
    border-radius: 2rem;
    background: var(--white);
    box-shadow: 0 18px 48px rgba(11, 18, 32, 0.08);
    border: 1px solid #e6edf7;
}

.hero {
    padding: 2.5rem 2.75rem;
    background: radial-gradient(circle at top left, rgba(47,126,255,0.18), transparent 32%), linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 2rem;
}

.hero-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: inherit;
    text-decoration: none;
}

.hero-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 1.1rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.hero-nav a {
    color: var(--ink-700);
    font-weight: 600;
    text-decoration: none;
}

.hero-nav a:hover {
    color: var(--brand-700);
}

.brand-mark {
    width: 3rem;
    height: 3rem;
    border-radius: 1rem;
    display: grid;
    place-items: center;
    background: var(--brand-800);
    color: var(--white);
    box-shadow: 0 10px 30px rgba(16, 58, 133, 0.12);
}

.brand-title {
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.hero-copy {
    margin-top: clamp(2.5rem, 7vh, 4.5rem);
    margin-bottom: auto;
}

.hero-copy h1 {
    font-size: clamp(2rem, 3vw, 3.25rem);
    line-height: 1.05;
    margin: 0 0 1rem;
    letter-spacing: -0.03em;
}

.hero-copy p {
    margin: 0;
    max-width: 36rem;
    font-size: 1.05rem;
    line-height: 1.75;
    color: var(--ink-500);
}

.content-hero-copy h2 {
    margin: 2rem 0 0.75rem;
    font-size: 1.2rem;
    line-height: 1.3;
    color: var(--ink-950);
    font-weight: 700;
}

.content-hero-copy p {
    color: var(--ink-500);
}

.content-hero-copy a {
    color: var(--brand-700);
    text-decoration: none;
}

.content-hero-copy a:hover {
    text-decoration: underline;
}

.panel {
    padding: 2.5rem 2.75rem;
    background: linear-gradient(180deg, var(--brand-950) 0%, #0f2b55 100%);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
}

.card {
    width: 100%;
    max-width: 24rem;
    padding: 1.75rem 2rem 2rem;
    border-radius: 2rem;
    border: 1px solid rgba(255,255,255,0.12);
    background: rgba(255,255,255,0.10);
    backdrop-filter: blur(24px);
    box-shadow: 0 24px 80px rgba(0,0,0,0.25);
}

.pill {
    display: inline-flex;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.10);
    padding: 0.35rem 0.7rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: #dcecff;
}

.card h2 {
    margin: 1rem 0 0.65rem;
    font-size: 1.9rem;
    line-height: 1.15;
}

.card p {
    margin: 0;
    color: rgba(255,255,255,0.82);
    line-height: 1.65;
}

.signin-error {
    display: grid;
    gap: 0.35rem;
    margin-top: 1.25rem;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(254, 202, 202, 0.55);
    border-radius: 0.75rem;
    background: rgba(127, 29, 29, 0.42);
    color: #fee2e2;
    font-size: 0.875rem;
    line-height: 1.5;
}

.signin-error strong {
    color: #ffffff;
}

.button {
    margin-top: 1.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    gap: 0.75rem;
    border: 0;
    border-radius: 1rem;
    padding: 0.95rem 1rem;
    background: var(--white);
    color: var(--ink-950);
    text-decoration: none;
    font-weight: 700;
    transition: transform 0.2s ease, background 0.2s ease;
}

.button:hover {
    transform: translateY(-1px);
    background: var(--brand-50);
}

.content-shell {
    width: 100%;
    max-width: 1500px;
    display: block;
    background: radial-gradient(circle at top left, rgba(47,126,255,0.18), transparent 32%), linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.content-hero {
    min-height: 100%;
    gap: 0;
    background: transparent;
}

.content-hero .hero-copy {
    margin-top: clamp(2.2rem, 5vh, 3.4rem);
    margin-bottom: 0;
    max-width: 980px;
}

.content-hero .hero-copy h1 {
    margin: 0 0 0.75rem;
    font-size: clamp(2rem, 3vw, 3.25rem);
    line-height: 1.05;
    letter-spacing: -0.03em;
    font-weight: inherit;
    color: inherit;
}

.content-hero .hero-copy p {
    max-width: 42rem;
    font-size: 1rem;
    margin-bottom: 1rem;
}

.content-hero .hero-copy h2 {
    margin: 0 0 0.45rem;
    font-size: clamp(1.4rem, 2vw, 1.75rem);
    line-height: 1.15;
    letter-spacing: -0.025em;
    color: var(--ink-950);
    font-weight: 400;
}

.content-hero .hero-copy p + h2 {
    margin-top: 2rem;
}

.content-hero .hero-copy p,
.content-hero .hero-copy li {
    color: var(--ink-700);
    line-height: 1.75;
}

.content-hero .hero-copy a {
    color: #154cae;
}

.content-hero .hero-copy ul {
    padding-left: 1.2rem;
}

.terms-muted {
    color: var(--ink-500);
}

@media (max-width: 900px) {
    .shell { grid-template-columns: 1fr; }
    .panel { min-height: 18rem; }
}

@media (max-width: 600px) {
    .page { padding: 0.5rem; }
    .hero { padding: 1.5rem; }
    .panel { padding: 1.3rem; }
    .card { padding: 1.15rem 1.3rem 1.3rem; }
    .hero-topbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.15rem;
    }
    .hero-nav {
        margin-left: 0;
        justify-content: flex-start;
    }
    .hero-copy {
        margin-top: 1rem;
    }
    .content-shell { min-height: auto; }
}

@keyframes loading-spin {
    to {
        transform: rotate(360deg);
    }
}
