:root {
    --bg: #eef2f9;
    --bg-elev: #f9fbff;
    --surface: #ffffff;
    --surface-soft: #f5f8ff;
    --ink: #0f1f33;
    --ink-soft: #5a6e87;
    --line: #d7e0ec;
    --line-strong: #c4d1e2;
    --primary: #1d4ed8;
    --primary-strong: #143da9;
    --primary-soft: #eaf1ff;
    --accent: #0ea5a6;
    --accent-soft: #e6faf7;
    --success: #146c43;
    --success-soft: #e7f8ef;
    --danger: #b42337;
    --danger-soft: #feecef;
    --warning: #7f4f02;
    --warning-soft: #fff7e7;
    --radius-xs: 10px;
    --radius-sm: 14px;
    --radius: 20px;
    --radius-lg: 28px;
    --space-1: 6px;
    --space-2: 10px;
    --space-3: 14px;
    --space-4: 18px;
    --space-5: 24px;
    --space-6: 32px;
    --space-7: 42px;
    --shadow-sm: 0 10px 24px rgba(12, 24, 43, 0.08);
    --shadow: 0 20px 48px rgba(12, 24, 43, 0.12);
    --shadow-lg: 0 28px 58px rgba(12, 24, 43, 0.14);
    --panel-border-premium: rgba(168, 191, 223, 0.9);
    --focus-ring: 0 0 0 4px rgba(29, 78, 216, 0.2);
}

* {
    box-sizing: border-box;
}

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

body {
    margin: 0;
    font-family: "Manrope", sans-serif;
    color: var(--ink);
    line-height: 1.55;
    background:
        radial-gradient(circle at 8% -10%, rgba(29, 78, 216, 0.2), transparent 34%),
        radial-gradient(circle at 90% 0%, rgba(14, 165, 166, 0.14), transparent 28%),
        linear-gradient(180deg, #f6f9ff 0%, var(--bg) 100%);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 150ms ease;
}

a:hover {
    color: var(--primary-strong);
}

h1,
h2,
h3,
h4 {
    margin: 0;
    font-family: "Sora", sans-serif;
    line-height: 1.2;
    letter-spacing: -0.01em;
}

p,
ul,
li,
ol {
    margin: 0;
}

.site-body {
    position: relative;
}

.page-shell {
    width: min(1140px, 100%);
    margin: 0 auto;
    padding: 20px 18px 52px;
}

.content-wrap {
    display: grid;
    gap: var(--space-5);
}

.site-footer {
    margin-top: var(--space-6);
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    border-top: 1px solid var(--line);
    padding-top: var(--space-3);
}

.site-footer a {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #f8fbff;
    color: #466484;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 6px 10px;
}

.top-nav {
    position: sticky;
    top: 12px;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: var(--space-3);
    flex-wrap: wrap;
    margin-bottom: var(--space-4);
    padding: 12px;
    border: 1px solid rgba(199, 212, 230, 0.8);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
}

.brand-wrap {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--ink);
    font-family: "Sora", sans-serif;
    font-weight: 700;
    font-size: 1.2rem;
}

.brand:hover {
    color: var(--ink);
}

.brand-dot {
    width: 11px;
    height: 11px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--primary) 100%);
    box-shadow: 0 0 0 4px rgba(14, 165, 166, 0.15);
}

.plan-pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.plan-pill-free {
    background: #eef3ff;
    border: 1px solid #cddbff;
    color: #204ca5;
}

.plan-pill-premium {
    background: #e9fcf7;
    border: 1px solid #b6efe4;
    color: #0d6656;
}

.nav-toggle {
    display: none;
    margin-left: auto;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    padding: 8px 12px;
    font-weight: 700;
    color: var(--ink);
    cursor: pointer;
}

.nav-toggle:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

.top-nav nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.top-nav nav a,
.button-link {
    border: 1px solid transparent;
    border-radius: 999px;
    background: transparent;
    padding: 8px 12px;
    color: var(--ink);
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
}

.top-nav nav a:hover,
.button-link:hover {
    border-color: var(--line);
    background: var(--surface-soft);
    color: var(--ink);
    text-decoration: none;
}

.top-nav nav .pill-link {
    color: #ffffff;
    border-color: transparent;
    background: linear-gradient(140deg, var(--primary) 0%, #2f6df0 100%);
}

.top-nav nav .pill-link:hover {
    background: linear-gradient(140deg, var(--primary-strong) 0%, #255ac7 100%);
    color: #ffffff;
}

.inline-form,
.nav-form {
    margin: 0;
}

.usage-strip {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-3);
    flex-wrap: wrap;
    border: 1px solid #cfe0f7;
    border-radius: var(--radius-sm);
    background: linear-gradient(180deg, #f8fbff 0%, #eef5ff 100%);
    padding: 12px 14px;
    margin-bottom: var(--space-2);
}

.usage-title {
    font-size: 0.9rem;
    font-weight: 800;
    color: #1f3e77;
    margin-bottom: 3px;
}

.usage-copy {
    color: #3f5878;
    font-size: 0.92rem;
}

.usage-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 800;
    font-size: 0.74rem;
    color: rgba(15, 31, 51, 0.65);
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-4);
}

.hero-landing {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.25);
    background:
        radial-gradient(circle at 90% 8%, rgba(255, 255, 255, 0.2), transparent 34%),
        radial-gradient(circle at 8% 100%, rgba(14, 165, 166, 0.25), transparent 40%),
        linear-gradient(132deg, #122a62 0%, #1d4ed8 52%, #0b8694 100%);
    color: #ffffff;
    padding: clamp(24px, 4vw, 40px);
    box-shadow: var(--shadow);
}

.hero-landing::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(220deg, transparent 12%, rgba(255, 255, 255, 0.08) 92%);
}

.hero-content {
    position: relative;
    z-index: 1;
    display: grid;
    gap: var(--space-4);
    max-width: 780px;
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3.3rem);
}

.hero .subtitle {
    max-width: 70ch;
    opacity: 0.95;
}

.hero .eyebrow {
    color: rgba(255, 255, 255, 0.86);
}

.hero-badges,
.hero-actions,
.action-pair,
.inline-row,
.form-actions,
.meta-chips {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2);
}

.badge-chip,
.meta-chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
}

.badge-chip {
    border: 1px solid rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    padding: 8px 11px;
}

.meta-chip {
    border: 1px solid var(--line);
    background: #f8fbff;
    color: #35506f;
    padding: 6px 10px;
}

.hero-side {
    position: relative;
    z-index: 1;
    max-width: 380px;
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.26);
    color: #ffffff;
}

.hero-side h3 {
    margin-bottom: var(--space-2);
}

.hero-side .compact-list li {
    border-color: rgba(255, 255, 255, 0.28);
}

.split-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--space-4);
    flex-wrap: wrap;
}

.section-intro {
    display: grid;
    gap: var(--space-2);
    max-width: 76ch;
}

.section-intro h1 {
    font-size: clamp(1.65rem, 4vw, 2.5rem);
}

.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: clamp(16px, 2.3vw, 24px);
    box-shadow: var(--shadow-sm);
}

.panel h2,
.panel h3,
.panel h4 {
    margin-bottom: var(--space-2);
}

.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    margin-bottom: var(--space-2);
}

.panel-headline {
    display: grid;
    gap: 6px;
    margin-bottom: var(--space-3);
}

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

.feature-grid,
.stat-row,
.settings-grid,
.result-grid,
.cards-grid,
.quiz-list,
.steps-grid,
.pack-grid,
.pricing-grid {
    display: grid;
    gap: var(--space-4);
}

.feature-grid {
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.feature-card {
    min-height: 160px;
    display: grid;
    gap: var(--space-2);
}

.landing-page {
    position: relative;
    isolation: isolate;
    display: grid;
    gap: clamp(22px, 3.6vw, 38px);
}

.landing-page::before {
    content: "";
    position: absolute;
    inset: -70px 30px auto;
    height: clamp(280px, 48vh, 440px);
    z-index: -1;
    pointer-events: none;
    clip-path: inset(0);
    background:
        radial-gradient(circle at 22% 20%, rgba(29, 78, 216, 0.22), transparent 50%),
        radial-gradient(circle at 76% 0%, rgba(14, 165, 166, 0.18), transparent 42%);
    filter: blur(30px);
    opacity: 0.86;
}

.landing-hero {
    position: relative;
    overflow: hidden;
    border-radius: clamp(24px, 3.6vw, 40px);
    border: 1px solid rgba(176, 198, 232, 0.68);
    min-height: clamp(430px, 69svh, 650px);
    display: grid;
    place-items: center;
    text-align: center;
    padding: clamp(28px, 6.6vw, 86px) clamp(20px, 4.5vw, 42px);
    background:
        radial-gradient(circle at 18% 16%, rgba(147, 197, 253, 0.56), transparent 40%),
        radial-gradient(circle at 86% 8%, rgba(129, 140, 248, 0.3), transparent 35%),
        radial-gradient(circle at 84% 84%, rgba(45, 212, 191, 0.24), transparent 38%),
        linear-gradient(156deg, #f9fbff 0%, #e8f0ff 48%, #eef9f7 100%);
    box-shadow: 0 30px 62px rgba(24, 45, 79, 0.16);
}

.landing-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.36), rgba(255, 255, 255, 0.04));
}

.landing-hero-glow {
    position: absolute;
    width: min(620px, 95vw);
    aspect-ratio: 1 / 1;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(29, 78, 216, 0.22) 0%, rgba(29, 78, 216, 0) 68%);
    filter: blur(4px);
    animation: landing-float 7200ms ease-in-out infinite;
}

.landing-hero-content {
    position: relative;
    z-index: 1;
    display: grid;
    justify-items: center;
    gap: clamp(9px, 2vw, 18px);
    max-width: 780px;
}

.landing-hero-content > * {
    opacity: 0;
    animation: landing-fade-up 620ms cubic-bezier(0.21, 0.9, 0.24, 1) both;
}

.landing-hero-content > *:nth-child(1) {
    animation-delay: 70ms;
}

.landing-hero-content > *:nth-child(2) {
    animation-delay: 150ms;
}

.landing-hero-content > *:nth-child(3) {
    animation-delay: 230ms;
}

.landing-hero-content > *:nth-child(4) {
    animation-delay: 300ms;
}

.landing-kicker {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.78rem;
    font-weight: 800;
    color: #234d92;
}

#landing-title {
    margin: 0;
    font-size: clamp(2.65rem, 9.3vw, 6rem);
    line-height: 0.95;
    letter-spacing: -0.035em;
    color: #0d2445;
    text-wrap: balance;
}

.landing-tagline {
    margin: 0;
    max-width: 56ch;
    font-size: clamp(1.08rem, 2.75vw, 1.38rem);
    line-height: 1.58;
    color: #2a4a6c;
    text-wrap: balance;
}

.landing-cta-wrap {
    margin-top: clamp(4px, 1.1vw, 10px);
    display: grid;
    justify-items: center;
    gap: 12px;
}

.landing-cta.btn-primary {
    position: relative;
    isolation: isolate;
    min-width: min(332px, 90vw);
    padding: 15px 30px;
    font-size: 1.06rem;
    font-weight: 800;
    letter-spacing: 0.01em;
    border-radius: 16px;
    background: linear-gradient(136deg, #1d4ed8 0%, #2463eb 52%, #0ea5a6 100%);
    box-shadow:
        0 20px 38px rgba(29, 78, 216, 0.34),
        inset 0 1px 0 rgba(255, 255, 255, 0.44);
    transition: transform 200ms ease, box-shadow 200ms ease, filter 200ms ease;
}

.landing-cta::before {
    content: "";
    position: absolute;
    inset: -8px -10px;
    z-index: -1;
    border-radius: 20px;
    background: radial-gradient(circle, rgba(29, 78, 216, 0.4) 0%, rgba(29, 78, 216, 0) 70%);
    opacity: 0.56;
    transform: scale(0.96);
    transition: transform 200ms ease, opacity 200ms ease;
}

.landing-cta.btn-primary:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow:
        0 24px 44px rgba(29, 78, 216, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    filter: saturate(1.07);
}

.landing-cta:hover::before {
    opacity: 0.78;
    transform: scale(1.02);
}

.landing-cta:active {
    transform: translateY(1px) scale(0.992);
}

.landing-auth-link {
    margin: 0;
    color: #36506a;
    font-size: 0.92rem;
    font-weight: 600;
}

.landing-auth-link a {
    font-weight: 800;
    color: #1d4ed8;
}

.landing-features {
    display: grid;
    gap: clamp(14px, 2vw, 22px);
}

.landing-features h2 {
    margin: 0 auto;
    max-width: 28ch;
    text-align: center;
    line-height: 1.2;
    letter-spacing: -0.012em;
    font-size: clamp(1.24rem, 4.7vw, 1.9rem);
    color: #1a3758;
}

.landing-feature-grid {
    display: grid;
    gap: 14px;
}

.landing-feature-card {
    display: grid;
    gap: 10px;
    align-content: start;
    border-radius: 22px;
    border: 1px solid rgba(185, 205, 230, 0.84);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(247, 252, 255, 0.9));
    backdrop-filter: blur(6px);
    padding: clamp(18px, 2.3vw, 24px);
    box-shadow:
        0 14px 30px rgba(16, 37, 70, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.94);
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
    animation: landing-fade-up 540ms ease both;
}

.landing-feature-card:nth-child(2) {
    animation-delay: 90ms;
}

.landing-feature-card:nth-child(3) {
    animation-delay: 180ms;
}

.landing-feature-card:hover {
    transform: translateY(-4px);
    border-color: rgba(127, 158, 201, 0.84);
    box-shadow:
        0 20px 34px rgba(16, 37, 70, 0.14),
        inset 0 1px 0 rgba(255, 255, 255, 0.96);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(245, 250, 255, 0.94));
}

.landing-feature-card h3 {
    margin: 0;
    font-size: 1.08rem;
    color: #12395f;
    line-height: 1.24;
}

.landing-feature-card p {
    margin: 0;
    color: #3d5a78;
    font-size: 0.95rem;
    line-height: 1.54;
}

.landing-feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #1f58c2;
    background: linear-gradient(160deg, rgba(29, 78, 216, 0.16), rgba(45, 212, 191, 0.1));
}

.landing-feature-icon svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.steps-grid {
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.step-item {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 14px;
    display: grid;
    gap: 8px;
    background: #fbfdff;
}

.step-index {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.82rem;
    font-weight: 800;
    color: #1f4fa8;
    background: #e8f0ff;
}

.pricing-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.pricing-card {
    display: grid;
    gap: var(--space-3);
}

.pricing-card-premium {
    border-color: #b8d9f0;
    background: linear-gradient(180deg, #ffffff 0%, #f2fbff 100%);
}

.compact-list {
    list-style: none;
    padding: 0;
    display: grid;
    gap: 8px;
}

.compact-list li {
    border-left: 2px solid #d3def0;
    padding-left: 10px;
    color: #334c6a;
}

.summary-list li {
    color: #29415f;
}

.dashboard-hero {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--space-4);
    flex-wrap: wrap;
    position: relative;
    overflow: hidden;
}

.dashboard-hero-premium {
    border-color: var(--panel-border-premium);
    border-radius: clamp(24px, 3vw, 34px);
    padding: clamp(20px, 3vw, 32px);
    background:
        radial-gradient(circle at 12% 10%, rgba(29, 78, 216, 0.16), transparent 42%),
        radial-gradient(circle at 88% 8%, rgba(14, 165, 166, 0.14), transparent 38%),
        linear-gradient(162deg, #fcfdff 0%, #eef4ff 54%, #f2fcfb 100%);
    box-shadow:
        var(--shadow-lg),
        inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.dashboard-hero-premium > * {
    position: relative;
    z-index: 1;
}

.dashboard-hero-content {
    max-width: min(70ch, 100%);
}

.dashboard-hero .section-intro h1 {
    font-size: clamp(1.8rem, 4.4vw, 2.85rem);
}

.dashboard-hero-meta .meta-chip {
    border-color: #c5d7f2;
    background: rgba(255, 255, 255, 0.88);
    color: #274a75;
}

.dashboard-hero-actions {
    margin-left: auto;
    width: min(360px, 100%);
    display: grid;
    gap: 10px;
}

.dashboard-hero-actions .btn {
    width: 100%;
}

.dashboard-hero-note {
    font-size: 0.85rem;
    line-height: 1.45;
}

.stat-row {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.dashboard-stat-row {
    grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
}

.stat-card {
    display: grid;
    gap: var(--space-2);
}

.dashboard-card {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    border-color: #d0def0;
    background: linear-gradient(180deg, #ffffff 0%, #f7faff 100%);
    box-shadow: 0 16px 30px rgba(16, 33, 60, 0.09);
}

.dashboard-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 82px;
    pointer-events: none;
    background:
        radial-gradient(circle at 8% -2%, rgba(29, 78, 216, 0.12), transparent 44%),
        radial-gradient(circle at 92% 0%, rgba(14, 165, 166, 0.1), transparent 40%);
}

.dashboard-card > * {
    position: relative;
    z-index: 1;
}

.stat-label {
    font-size: 0.86rem;
    font-weight: 800;
    color: var(--ink-soft);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.stat-value {
    font-size: clamp(1.45rem, 3.2vw, 2rem);
    letter-spacing: -0.02em;
}

.usage-meter {
    height: 9px;
    width: 100%;
    border-radius: 999px;
    background: #e8eef8;
    overflow: hidden;
}

.usage-meter span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(140deg, var(--accent) 0%, var(--primary) 100%);
}

.stacked-actions {
    display: grid;
    gap: 8px;
}

.dashboard-card-actions .stacked-actions {
    gap: 9px;
}

.dashboard-card-actions .btn-secondary,
.dashboard-card-actions .btn-quiet {
    justify-content: flex-start;
}

.dashboard-continue-panel {
    border-color: #c7d7ee;
    border-radius: clamp(22px, 2.8vw, 30px);
    background:
        radial-gradient(circle at 12% 10%, rgba(29, 78, 216, 0.08), transparent 40%),
        radial-gradient(circle at 86% 6%, rgba(14, 165, 166, 0.08), transparent 36%),
        linear-gradient(162deg, #fdfefe 0%, #f2f7ff 58%, #f6fcfb 100%);
    box-shadow: 0 18px 34px rgba(18, 36, 65, 0.1);
}

.dashboard-continue-card {
    display: grid;
    gap: var(--space-4);
    grid-template-columns: minmax(0, 1.45fr) minmax(220px, 0.8fr);
    align-items: start;
}

.dashboard-continue-main h3 {
    margin-bottom: 8px;
}

.dashboard-pack-meta-chips .meta-chip {
    border-color: #cadef7;
    background: rgba(255, 255, 255, 0.86);
}

.dashboard-review-again {
    margin-top: 10px;
    display: grid;
    gap: 10px;
}

.dashboard-continue-actions {
    width: 100%;
    display: grid;
    gap: 10px;
}

.dashboard-continue-actions .btn {
    width: 100%;
}

.btn-disabled-link {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.dashboard-card-activity {
    display: grid;
    gap: 10px;
}

.dashboard-activity-list {
    margin: 0;
    display: grid;
    gap: 8px;
}

.dashboard-activity-item {
    margin: 0;
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: baseline;
    border-top: 1px solid #dce6f5;
    padding-top: 8px;
}

.dashboard-activity-item dt {
    margin: 0;
    color: #456183;
    font-size: 0.9rem;
}

.dashboard-activity-item dd {
    margin: 0;
    font-weight: 800;
    font-size: 1.08rem;
    color: #1e3b5f;
}

.pack-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.dashboard-recent-panel {
    border-color: var(--panel-border-premium);
    border-radius: clamp(22px, 2.8vw, 30px);
    background: linear-gradient(180deg, #ffffff 0%, #f9fcff 100%);
    box-shadow: 0 18px 34px rgba(18, 36, 65, 0.1);
}

.dashboard-recent-panel .panel-header {
    margin-bottom: var(--space-3);
}

.pack-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: #fcfdff;
    padding: 14px;
    display: grid;
    gap: var(--space-2);
}

.dashboard-pack-card {
    border-color: #ceddef;
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    box-shadow: 0 12px 26px rgba(20, 38, 66, 0.08);
}

.dashboard-pack-card .meta-chip {
    border-color: #cadbf4;
    background: #eff5ff;
}

.dashboard-review-chip {
    color: #24496f;
}

.dashboard-pack-meta {
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 12px;
}

.dashboard-pack-meta div {
    display: grid;
    gap: 3px;
}

.dashboard-pack-meta dt {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #5d7695;
    font-weight: 700;
}

.dashboard-pack-meta dd {
    margin: 0;
    font-size: 0.9rem;
    color: #223d60;
    font-weight: 600;
}

.dashboard-review-note {
    margin: 0;
    font-size: 0.84rem;
}

.dashboard-pack-actions {
    margin-top: auto;
}

.pack-card-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
}

.pack-card-head h4 {
    margin: 0;
    font-size: 1rem;
}

.pack-time {
    font-size: 0.84rem;
}

.pack-preview {
    color: #334f6f;
    font-size: 0.93rem;
    min-height: 2.8em;
}

.study-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: clamp(16px, 2.4vw, 26px);
    align-items: start;
}

.study-form-hero {
    position: relative;
    overflow: hidden;
    align-items: stretch;
    border-color: var(--panel-border-premium);
    border-radius: clamp(24px, 3vw, 34px);
    padding: clamp(20px, 3vw, 32px);
    background:
        radial-gradient(circle at 8% 8%, rgba(29, 78, 216, 0.16), transparent 44%),
        radial-gradient(circle at 92% 0%, rgba(14, 165, 166, 0.14), transparent 36%),
        linear-gradient(162deg, #fcfdff 0%, #eef4ff 54%, #f2fbfa 100%);
    box-shadow:
        var(--shadow-lg),
        inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.study-form-hero > * {
    position: relative;
    z-index: 1;
}

.study-form-hero-content {
    max-width: min(70ch, 100%);
}

.study-form-hero .section-intro h1 {
    font-size: clamp(1.75rem, 4.1vw, 2.65rem);
}

.study-form-hero-meta .meta-chip {
    border-color: #c8d7ed;
    background: rgba(255, 255, 255, 0.88);
    color: #27486e;
}

.study-form-hero-actions {
    margin-left: auto;
    width: min(360px, 100%);
    display: grid;
    gap: 10px;
}

.study-form-hero-actions .btn {
    width: 100%;
}

.study-form-hero-note {
    font-size: 0.85rem;
    line-height: 1.45;
}

.onboarding-banner {
    display: grid;
    gap: 8px;
    border-color: #c3d8fa;
    border-radius: 18px;
    background: linear-gradient(180deg, #fcfeff 0%, #edf4ff 100%);
    box-shadow: 0 14px 28px rgba(18, 40, 72, 0.08);
}

.form-grid {
    display: grid;
    gap: var(--space-3);
}

.form-grid.two-col {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.study-workspace {
    position: relative;
    overflow: hidden;
    border-color: var(--panel-border-premium);
    border-radius: clamp(22px, 2.8vw, 30px);
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    box-shadow:
        0 20px 38px rgba(18, 37, 66, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.study-workspace::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 120px;
    pointer-events: none;
    background:
        radial-gradient(circle at 10% 12%, rgba(29, 78, 216, 0.11), transparent 46%),
        radial-gradient(circle at 96% 0%, rgba(14, 165, 166, 0.09), transparent 42%);
}

.study-workspace > * {
    position: relative;
    z-index: 1;
}

.study-form {
    gap: clamp(14px, 2.2vw, 22px);
}

.study-form-section {
    border: 1px solid #d2dff1;
    border-radius: 18px;
    background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
    padding: clamp(14px, 2.2vw, 20px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.auto-detection-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid #b9d6cd;
    border-radius: 12px;
    background: #f1fbf7;
    color: #23564b;
    padding: 11px 12px;
    font-size: 0.9rem;
}

.auto-detection-note strong {
    flex: 0 0 auto;
    color: #17483d;
}

.study-advanced-options {
    border: 1px solid #d2dff1;
    border-radius: 16px;
    background: #f8fbff;
    overflow: hidden;
}

.study-advanced-options summary {
    cursor: pointer;
    padding: 13px 16px;
    color: #24466f;
    font-size: 0.92rem;
    font-weight: 800;
    list-style-position: inside;
}

.study-advanced-options[open] summary {
    border-bottom: 1px solid #d2dff1;
    background: #f2f7ff;
}

.study-advanced-options-body {
    display: grid;
    gap: 16px;
    padding: 16px;
}

.form-section-heading {
    display: grid;
    gap: 4px;
}

.form-section-heading h2 {
    font-size: 1.02rem;
    color: #173a69;
    margin: 0;
}

.form-section-heading .muted {
    font-size: 0.9rem;
}

.mode-grid {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.mode-option {
    border: 1px solid var(--line);
    border-radius: 14px;
    background: linear-gradient(180deg, #ffffff 0%, #f4f8ff 100%);
    padding: 12px;
    display: grid;
    gap: 6px;
    cursor: pointer;
    transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease, transform 140ms ease;
}

.mode-option:hover {
    border-color: #97b5e8;
    transform: translateY(-1px);
}

.mode-option:has(input:checked) {
    border-color: #3e71d7;
    background: linear-gradient(180deg, #f9fbff 0%, #e8f0ff 100%);
    box-shadow:
        0 0 0 3px rgba(47, 109, 240, 0.14),
        0 12px 24px rgba(25, 48, 82, 0.1);
}

.mode-option input {
    width: auto;
    margin: 0;
    accent-color: var(--primary);
}

.mode-option span {
    font-size: 0.9rem;
    font-weight: 700;
    color: #1f3f6a;
}

.mode-option input:checked + span {
    color: #133f81;
}

.mode-option small {
    color: #2f5e9a;
    font-size: 0.76rem;
    font-weight: 700;
}

.mode-option.is-locked {
    opacity: 0.72;
    border-style: dashed;
    background: #f9fbff;
}

.difficulty-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.difficulty-pill {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 8px 13px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    font-weight: 700;
    color: #1e436f;
    transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease, transform 140ms ease;
}

.difficulty-pill:hover {
    border-color: #9bb8e8;
    transform: translateY(-1px);
}

.difficulty-pill:has(input:checked) {
    border-color: #3e71d7;
    background: #eaf2ff;
    color: #16437f;
    box-shadow: 0 0 0 3px rgba(47, 109, 240, 0.14);
}

.difficulty-pill input {
    width: auto;
    margin: 0;
    accent-color: var(--primary);
}

.difficulty-pill.premium-toggle {
    border-style: dashed;
    border-color: #bfd2ef;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.difficulty-pill.premium-toggle small {
    border-radius: 999px;
    padding: 2px 6px;
    background: #ebf3ff;
    color: #1f4a87;
    font-size: 0.72rem;
    font-weight: 800;
}

.quality-inline-warning {
    margin: 0;
    padding: 8px 10px;
}

.image-extract-field {
    border: 1px solid #d6e3f7;
    border-radius: var(--radius-sm);
    background: #f8fbff;
    padding: 14px;
}

.study-input-surface {
    border-color: #cadbf4;
    border-radius: 16px;
    background:
        radial-gradient(circle at 95% 6%, rgba(29, 78, 216, 0.11), transparent 34%),
        linear-gradient(180deg, #fbfdff 0%, #f2f7ff 100%);
}

.camera-action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.camera-upload-label {
    cursor: pointer;
}

.image-upload-button {
    width: fit-content;
    cursor: pointer;
}

.visually-hidden-file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.image-extract-hints {
    margin-bottom: 0;
}

.camera-upload-input {
    border-style: dashed;
    border-color: #bdd1ee;
    background: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    padding: 9px 11px;
}

.camera-panel {
    display: grid;
    gap: 10px;
    border: 1px solid #bed1ed;
    border-radius: 16px;
    background:
        radial-gradient(circle at 8% -12%, rgba(29, 78, 216, 0.11), transparent 48%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(245, 250, 255, 0.98) 100%);
    padding: 12px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.84);
}

.camera-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.camera-panel-head h3 {
    margin: 0;
    font-size: 0.98rem;
    color: #163962;
}

.camera-panel-subtitle {
    margin: 0;
    color: #476586;
    font-size: 0.88rem;
}

.camera-close-btn {
    margin-left: auto;
}

.camera-preview-shell {
    position: relative;
    width: min(100%, 420px);
    aspect-ratio: 3 / 4;
    border: 1px solid #bad0ef;
    border-radius: 14px;
    overflow: hidden;
    background:
        linear-gradient(180deg, rgba(15, 31, 51, 0.26), rgba(15, 31, 51, 0.5)),
        #0f1f33;
}

.camera-preview-video,
.camera-preview-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.camera-preview-image {
    background: #f5f9ff;
}

.camera-frame-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.camera-frame-overlay::before {
    content: "";
    position: absolute;
    inset: 8%;
    border: 2px dashed rgba(232, 241, 255, 0.88);
    border-radius: 14px;
    box-shadow:
        0 0 0 999px rgba(7, 17, 32, 0.3),
        inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

.camera-frame-overlay span {
    position: absolute;
    left: 50%;
    bottom: 12px;
    transform: translateX(-50%);
    border-radius: 999px;
    background: rgba(9, 20, 36, 0.75);
    border: 1px solid rgba(192, 216, 248, 0.36);
    color: #eef5ff;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    padding: 5px 10px;
    white-space: nowrap;
}

.camera-shutter-flash {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: #ffffff;
    opacity: 0;
}

.camera-shutter-flash.is-active {
    animation: camera-shutter-flash 260ms ease-out;
}

.camera-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.camera-controls .btn {
    flex: 1 1 140px;
}

.camera-primary-btn {
    min-height: 44px;
}

.camera-panel-message {
    margin: 0;
}

.camera-orientation-hint {
    margin: 0;
}

.image-preview {
    border: 1px solid var(--line);
    border-radius: var(--radius-xs);
    background: #ffffff;
    padding: 8px;
    max-width: 380px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.image-preview img {
    width: 100%;
    height: auto;
    max-height: 220px;
    object-fit: contain;
    border-radius: 8px;
    display: block;
}

.ocr-preview-queue {
    border: 1px solid #cddcf3;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.88);
    padding: 10px;
    display: grid;
    gap: 8px;
}

.ocr-preview-title {
    margin: 0;
    font-size: 0.86rem;
    font-weight: 800;
    color: #244264;
}

.ocr-preview-list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 8px;
}

.ocr-preview-item {
    display: grid;
    grid-template-columns: auto 64px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    border: 1px solid #d5e2f6;
    border-radius: 10px;
    background: #ffffff;
    padding: 8px;
}

.ocr-preview-index {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    border: 1px solid #aac3ea;
    background: #edf4ff;
    color: #16437f;
    font-size: 0.78rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.ocr-preview-thumb {
    width: 64px;
    height: 64px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid #d0def4;
    background: #f5f9ff;
}

.ocr-preview-details {
    min-width: 0;
    display: grid;
    gap: 2px;
}

.ocr-preview-name {
    margin: 0;
    font-size: 0.84rem;
    font-weight: 700;
    color: #1f3f64;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ocr-preview-source {
    margin: 0;
    font-size: 0.74rem;
    color: #4f6a8a;
}

.ocr-preview-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
}

.ocr-preview-actions .btn {
    min-width: 50px;
}

.insert-mode-fieldset {
    border: 1px dashed #c9d9f3;
    border-radius: var(--radius-xs);
    padding: 10px;
    margin: 0;
    background: rgba(255, 255, 255, 0.72);
}

.insert-mode-fieldset legend {
    color: #2a486f;
    font-size: 0.83rem;
    font-weight: 800;
    padding: 0 4px;
}

.insert-mode-options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
}

.insert-mode-options label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 1px solid #d3e0f4;
    border-radius: 999px;
    background: #ffffff;
    padding: 6px 10px;
    font-weight: 700;
    font-size: 0.88rem;
    color: #244264;
}

.insert-mode-options label:has(input:checked) {
    border-color: #93b0e4;
    background: #ecf4ff;
}

.insert-mode-options input {
    width: auto;
    margin: 0;
    accent-color: var(--primary);
}

.image-extract-hints {
    margin-top: 4px;
}

.image-extract-field .error-text,
.image-extract-field .success-text,
.image-extract-field .warning-text {
    margin-bottom: 0;
}

.input-example-card {
    border: 1px solid #cfe0fb;
    border-radius: 16px;
    background: #f6faff;
    padding: 14px;
    display: grid;
    gap: 6px;
}

.input-example-card.weak {
    border-color: #f0d6b0;
    background: #fff8ec;
}

.input-example-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 800;
    color: #1f4b8d;
}

.guidance-panel {
    display: grid;
    gap: var(--space-3);
    align-content: start;
    position: sticky;
    top: 88px;
    border-color: #d0def1;
    border-radius: clamp(20px, 2.8vw, 28px);
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    box-shadow: 0 18px 34px rgba(19, 38, 68, 0.1);
}

.callout-box {
    border: 1px solid #cfe0fb;
    border-radius: 16px;
    background: linear-gradient(180deg, #f8fbff 0%, #edf5ff 100%);
    padding: 14px;
    display: grid;
    gap: 10px;
}

.callout-title {
    font-weight: 800;
    color: #1f4687;
}

.paywall-inline-card {
    border-color: #bfd3f2;
    background: linear-gradient(180deg, #ffffff 0%, #f2f8ff 100%);
}

.paywall-inline-actions {
    align-items: stretch;
}

.auth-shell {
    position: relative;
    display: grid;
    justify-items: center;
    padding-block: clamp(6px, 1.2vw, 14px);
}

.auth-card {
    width: min(560px, 100%);
}

.auth-shell-entry {
    isolation: isolate;
}

.auth-shell-entry::before,
.auth-shell-entry::after {
    content: "";
    position: absolute;
    z-index: -1;
    pointer-events: none;
    border-radius: 999px;
}

.auth-shell-entry::before {
    width: clamp(240px, 42vw, 460px);
    height: clamp(240px, 42vw, 460px);
    left: clamp(-140px, -10vw, -52px);
    top: -56px;
    background: radial-gradient(circle, rgba(29, 78, 216, 0.24) 0%, rgba(29, 78, 216, 0) 72%);
}

.auth-shell-entry::after {
    width: clamp(220px, 34vw, 360px);
    height: clamp(220px, 34vw, 360px);
    right: clamp(-120px, -9vw, -38px);
    bottom: -118px;
    background: radial-gradient(circle, rgba(14, 165, 166, 0.22) 0%, rgba(14, 165, 166, 0) 72%);
}

.auth-card-entry {
    position: relative;
    overflow: hidden;
    border-radius: clamp(22px, 3vw, 30px);
    border: 1px solid rgba(175, 198, 230, 0.9);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 252, 255, 0.94)),
        linear-gradient(156deg, #f9fbff 0%, #ebf2ff 54%, #eef9f7 100%);
    box-shadow:
        0 24px 44px rgba(24, 45, 79, 0.14),
        inset 0 1px 0 rgba(255, 255, 255, 0.92);
    padding: clamp(20px, 3vw, 30px);
    animation: landing-fade-up 460ms cubic-bezier(0.21, 0.9, 0.24, 1) both;
}

.auth-card-entry::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 140px;
    pointer-events: none;
    background:
        radial-gradient(circle at 12% 14%, rgba(29, 78, 216, 0.18), transparent 44%),
        radial-gradient(circle at 88% 0%, rgba(14, 165, 166, 0.16), transparent 45%);
}

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

.auth-card-entry .panel-headline {
    gap: 8px;
    margin-bottom: clamp(14px, 2.1vw, 20px);
}

.auth-card-entry .eyebrow {
    color: #25508d;
    letter-spacing: 0.14em;
}

.auth-card-entry h1 {
    font-size: clamp(1.72rem, 4.8vw, 2.35rem);
    letter-spacing: -0.02em;
    color: #0f2d52;
    text-wrap: balance;
}

.auth-card-entry .muted {
    color: #486380;
}

.auth-form {
    gap: var(--space-4);
}

.auth-card-entry .form-field {
    gap: 8px;
}

.auth-card-entry label {
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #2d4f79;
}

.auth-card-entry input {
    border-color: #c8d8ee;
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.95);
    padding: 13px 14px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.auth-card-entry input::placeholder {
    color: #748cac;
}

.auth-card-entry input:focus {
    border-color: #7ea5e9;
    box-shadow: 0 0 0 4px rgba(41, 93, 209, 0.18), 0 10px 24px rgba(29, 78, 216, 0.16);
}

.auth-card-entry .btn-primary {
    background: linear-gradient(136deg, #1d4ed8 0%, #2463eb 52%, #0ea5a6 100%);
    box-shadow:
        0 16px 30px rgba(29, 78, 216, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.auth-card-entry .btn-primary:hover {
    background: linear-gradient(136deg, #1843be 0%, #1e55d2 52%, #0b8a92 100%);
    box-shadow:
        0 18px 32px rgba(29, 78, 216, 0.34),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.auth-card-entry .btn-primary:active {
    transform: translateY(0);
}

.auth-meta {
    margin-top: var(--space-3);
    display: grid;
    gap: 8px;
}

.auth-card-entry .foot-note {
    margin-top: 0;
    font-size: 0.9rem;
}

.auth-card-entry .foot-note a {
    font-weight: 700;
    color: #1b4ea8;
}

.auth-card-entry .foot-note a:hover {
    color: #143f87;
}

.auth-card-entry .error-text,
.auth-card-entry .success-text {
    border-radius: 12px;
}

.settings-grid {
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
}

.support-email-card {
    display: grid;
    gap: 10px;
    padding: clamp(14px, 2vw, 18px);
    margin-bottom: var(--space-4);
    border: 1px solid var(--panel-border-premium);
    border-radius: var(--radius-sm);
    background:
        radial-gradient(circle at 10% 5%, rgba(29, 78, 216, 0.11), transparent 42%),
        radial-gradient(circle at 92% 0%, rgba(14, 165, 166, 0.1), transparent 36%),
        linear-gradient(166deg, #fcfdff 0%, #eff5ff 56%, #f2fbfa 100%);
}

.support-email-title {
    margin: 0;
}

.support-email-body {
    margin: 0;
    color: #365476;
}

.support-email-address {
    font-size: clamp(1rem, 2.4vw, 1.08rem);
    font-weight: 800;
    color: #174a90;
    text-decoration-thickness: 2px;
    text-underline-offset: 2px;
    word-break: break-word;
}

.support-email-address:hover {
    color: #133f79;
}

.stacked-form {
    display: grid;
    gap: var(--space-3);
}

.form-field {
    display: grid;
    gap: 6px;
}

label {
    color: #213a58;
    font-weight: 800;
    font-size: 0.9rem;
}

.field-hint {
    color: var(--ink-soft);
    font-size: 0.84rem;
}

input,
textarea,
select,
button {
    font-family: inherit;
}

input,
textarea,
select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: var(--radius-xs);
    background: #ffffff;
    color: var(--ink);
    font-size: 0.96rem;
    padding: 12px 13px;
    transition: border-color 140ms ease, box-shadow 140ms ease;
}

textarea {
    resize: vertical;
    min-height: 120px;
}

.study-form textarea {
    min-height: 240px;
}

.study-text-field {
    border: 1px solid #d2dff2;
    border-radius: 16px;
    padding: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
    transition: border-color 280ms ease, box-shadow 280ms ease, background 280ms ease;
}

.study-text-field textarea {
    min-height: 260px;
    border-color: #c7d8ef;
}

.study-text-field.is-image-text-updated {
    border-color: #9fbced;
    background: linear-gradient(180deg, #ffffff 0%, #eef6ff 100%);
    box-shadow:
        0 0 0 2px rgba(29, 78, 216, 0.12),
        0 10px 22px rgba(18, 57, 95, 0.1);
}

.study-text-field .char-counter {
    border: 1px solid #d1dff4;
    border-radius: 999px;
    background: #edf4ff;
    color: #24476f;
    padding: 3px 10px;
}

.study-text-field .char-counter-danger {
    border-color: #f2c5cf;
    background: #fff0f4;
}

.study-form-actions {
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding-top: 4px;
}

.study-form-actions .btn-primary {
    min-width: 240px;
    padding: 12px 18px;
    background: linear-gradient(136deg, #1d4ed8 0%, #2463eb 52%, #0ea5a6 100%);
    box-shadow:
        0 16px 30px rgba(29, 78, 216, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.study-form-actions .btn-primary:hover {
    background: linear-gradient(136deg, #1843be 0%, #1e55d2 52%, #0b8a92 100%);
    box-shadow:
        0 18px 32px rgba(29, 78, 216, 0.34),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #8eb0f5;
    box-shadow: var(--focus-ring);
}

input:disabled,
textarea:disabled,
select:disabled {
    background: #f3f7fd;
    color: #7184a0;
}

.compact-row {
    justify-content: space-between;
    align-items: center;
    gap: var(--space-3);
}

.char-counter {
    color: #3d5574;
    font-size: 0.85rem;
    font-weight: 700;
}

.char-counter-danger {
    color: var(--danger);
}

.btn {
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 10px 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.92rem;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease;
}

.btn:hover {
    text-decoration: none;
    transform: translateY(-1px);
}

.btn:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

.btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    transform: none;
}

.btn-link-loading {
    pointer-events: none;
    opacity: 0.72;
}

.btn-primary {
    background: linear-gradient(140deg, var(--primary) 0%, #2f6df0 100%);
    color: #ffffff;
    box-shadow: 0 12px 26px rgba(29, 78, 216, 0.26);
}

.btn-primary:hover {
    background: linear-gradient(140deg, var(--primary-strong) 0%, #215fdd 100%);
}

.btn-secondary {
    background: var(--primary-soft);
    color: #1f4fa8;
    border-color: #cbdafd;
}

.btn-secondary:hover {
    background: #deebff;
}

.btn-quiet {
    background: #f8fbff;
    color: #567093;
    border-color: var(--line);
}

.btn-sm {
    padding: 7px 10px;
    font-size: 0.82rem;
}

.full {
    width: 100%;
}

.button-link {
    margin: 0;
    padding: 8px 12px;
}

.loading-note {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--ink-soft);
    font-size: 0.9rem;
    font-weight: 700;
}

.loading-note::before {
    content: "";
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: linear-gradient(140deg, var(--accent) 0%, var(--primary) 100%);
    animation: pulse 1000ms ease-in-out infinite;
}

.loading-note[hidden] {
    display: none;
}

.btn-spinner {
    width: 14px;
    height: 14px;
    border-radius: 999px;
    border: 2px solid rgba(255, 255, 255, 0.34);
    border-top-color: #ffffff;
    animation: spin 820ms linear infinite;
}

.error-text,
.success-text,
.warning-text {
    border-radius: var(--radius-xs);
    border: 1px solid transparent;
    padding: 10px 12px;
    font-weight: 700;
    margin-bottom: var(--space-3);
}

.error-text {
    color: var(--danger);
    background: var(--danger-soft);
    border-color: #f7bdc8;
}

.success-text {
    color: var(--success);
    background: var(--success-soft);
    border-color: #bce6cd;
}

.warning-text {
    color: var(--warning);
    background: var(--warning-soft);
    border-color: #efd58a;
}

.result-grid {
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
}

.result-card {
    display: grid;
    gap: var(--space-2);
}

.section-card-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--space-3);
    flex-wrap: wrap;
}

.result-card-wide {
    grid-column: 1 / -1;
}

.grounded-note {
    border-color: #c8d9f7;
    background: linear-gradient(180deg, #f8fbff 0%, #f0f6ff 100%);
}

.export-actions {
    display: grid;
    gap: var(--space-3);
}

.web-research-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.web-research-toggle input {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    margin: 0;
    accent-color: var(--primary);
}

.study-report > summary {
    cursor: pointer;
    font-weight: 700;
}

.study-report[open] > summary {
    margin-bottom: var(--space-3);
}

.export-primary-actions {
    align-items: stretch;
}

.export-upgrade-callout {
    margin: 0;
    display: grid;
    gap: 8px;
}

.section-actions {
    width: 100%;
    align-items: flex-start;
}

.section-actions .feedback-wrap {
    width: 100%;
}

.share-actions {
    display: grid;
    gap: var(--space-2);
}

.share-inline {
    display: grid;
    gap: 6px;
}

.share-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.share-row input {
    flex: 1 1 280px;
}

.section-nav {
    position: sticky;
    top: 84px;
    z-index: 8;
    display: flex;
    gap: 8px;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
}

.section-nav a {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #ffffff;
    color: #294c7f;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 7px 11px;
    white-space: nowrap;
}

.section-nav a:hover {
    background: #f2f7ff;
    text-decoration: none;
}

.text-pre {
    margin: 0;
    white-space: pre-wrap;
    color: #263e5e;
}

.cards-grid {
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.flashcard {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 13px;
    display: grid;
    gap: 7px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.flashcard-question {
    color: #173154;
    font-size: 0.98rem;
}

.flashcard-answer {
    color: #466181;
    font-size: 0.92rem;
}

.quiz-list {
    gap: var(--space-3);
}

.quiz-item {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: #fcfdff;
    overflow: hidden;
}

.quiz-item summary {
    cursor: pointer;
    list-style: none;
    padding: 12px 14px;
}

.quiz-item summary::-webkit-details-marker {
    display: none;
}

.quiz-item[open] summary {
    border-bottom: 1px solid var(--line);
    background: #f9fcff;
}

.quiz-item ol,
.quiz-item .answer-line,
.quiz-item .muted {
    margin: 12px 14px;
}

.quiz-item ol {
    padding-left: 22px;
    color: #2b4567;
}

.quiz-question {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #16365e;
}

.question-index {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 800;
    color: #2456aa;
    background: #e8f0ff;
}

.answer-line {
    color: #183a66;
    font-size: 0.92rem;
}

.test-me-box {
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 14px;
    display: grid;
    gap: var(--space-3);
    background: linear-gradient(180deg, #ffffff 0%, #f4f8ff 100%);
}

.test-actions {
    gap: 8px;
}

.test-progress,
.test-score {
    font-size: 0.86rem;
}

.test-score {
    color: #294f8a;
    font-weight: 700;
}

.test-prompt {
    font-size: 1.03rem;
    font-weight: 700;
    color: #17365d;
}

.test-answer-panel {
    border-radius: var(--radius-sm);
    border: 1px solid #cadbf4;
    background: #f8fbff;
    padding: 10px 12px;
    display: grid;
    gap: 6px;
}

.test-answer-panel.is-hidden {
    border-style: dashed;
    background: #fbfcff;
}

.test-answer-panel.is-revealed {
    border-color: #b7e8d9;
    background: #eafaf4;
}

.test-answer-label {
    margin: 0;
    font-size: 0.84rem;
    font-weight: 700;
    color: #27548a;
}

.test-answer-text {
    margin: 0;
    color: #123a67;
    font-size: 0.95rem;
    line-height: 1.45;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.feedback-row {
    display: inline-flex;
    gap: 6px;
}

.feedback-wrap {
    display: grid;
    gap: 6px;
}

.feedback-reason-panel {
    display: grid;
    gap: 6px;
    padding: 8px;
    border: 1px solid #d7e3f4;
    border-radius: 10px;
    background: #f8fbff;
}

.feedback-reason-row {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
}

.feedback-reason-row select {
    flex: 1 1 220px;
    min-width: 180px;
    padding: 8px 10px;
}

.feedback-row .is-active {
    border-color: #8db2ef;
    background: #e7f0ff;
    color: #184280;
}

.feedback-regenerate-hint {
    margin: 0;
    color: #466181;
    font-size: 0.82rem;
}

.admin-reason-breakdown-card {
    padding: 12px;
}

.history-toolbar {
    display: grid;
    gap: 6px;
    margin-bottom: var(--space-3);
}

.pack-card-locked {
    border-style: dashed;
    background: linear-gradient(180deg, #fbfcff 0%, #f4f8ff 100%);
}

.pack-card-locked .pack-preview {
    color: #5a6f8f;
}

.history-lock-summary {
    border-color: #c6d8f5;
    background: linear-gradient(180deg, #ffffff 0%, #f2f7ff 100%);
}

.history-lock-chip {
    border-color: #d8c89c;
    background: #fff7df;
    color: #81550a;
}

.history-search-label {
    font-weight: 800;
    font-size: 0.86rem;
    color: #2a4465;
}

.empty-state {
    display: grid;
    justify-items: center;
    text-align: center;
    gap: var(--space-2);
    position: relative;
    overflow: hidden;
    border: 1px dashed #bfd1e8;
    border-radius: 18px;
    padding: clamp(24px, 4.5vw, 36px);
    background: linear-gradient(180deg, #fcfeff 0%, #f3f8ff 100%);
}

.empty-state::before {
    content: "";
    width: 44px;
    height: 44px;
    border-radius: 13px;
    background: linear-gradient(140deg, rgba(29, 78, 216, 0.18) 0%, rgba(14, 165, 166, 0.2) 100%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.65),
        0 12px 24px rgba(17, 39, 71, 0.14);
}

.empty-state > * {
    position: relative;
    z-index: 1;
}

.empty-state h3 {
    font-size: clamp(1.08rem, 2.5vw, 1.3rem);
}

.plan-list {
    margin: 0;
    padding-left: 20px;
    display: grid;
    gap: 8px;
    color: #385173;
}

.comparison-grid {
    align-items: stretch;
}

.legal-panel {
    display: grid;
    gap: var(--space-3);
}

.legal-panel h2 {
    margin-top: var(--space-3);
}

.legal-panel p,
.legal-panel li,
.legal-table td {
    line-height: 1.65;
}

.legal-table {
    min-width: 760px;
}

.legal-table td {
    vertical-align: top;
}

.legal-table th:first-child {
    width: 23%;
}

.comparison-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 480px;
    background: #ffffff;
}

.comparison-table th,
.comparison-table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    font-size: 0.92rem;
}

.comparison-table th {
    font-family: "Sora", sans-serif;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #325379;
    background: #f5f9ff;
}

.plan-cta {
    margin-top: var(--space-3);
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.plan-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    padding: 6px 12px;
    font-weight: 800;
    font-size: 0.82rem;
    border: 1px solid transparent;
}

.plan-badge-free {
    color: #275084;
    background: #eef5ff;
    border-color: #cddcf2;
}

.plan-badge-premium {
    color: #0b5b45;
    background: #ecfaf2;
    border-color: #bde8d0;
}

.plan-usage-grid {
    display: grid;
    gap: 8px;
    margin: 10px 0 16px;
}

.plan-usage-line {
    margin: 0;
    padding: 10px 12px;
    border-radius: 10px;
    background: #f7faff;
    border: 1px solid #d9e4f4;
    color: #244a79;
    font-size: 0.9rem;
}

.plan-cta-grid {
    display: grid;
    gap: 10px;
    margin-top: 12px;
}

.checkout-note {
    margin: 0;
}

.plan-price-line {
    margin: 0;
    font-size: 1.06rem;
    font-weight: 800;
    color: #1f4d85;
}

.pricing-card-highlight {
    border-width: 2px;
    border-color: #8fc0db;
    box-shadow: 0 10px 24px rgba(24, 73, 118, 0.08);
}

.best-value-badge {
    margin: 0;
    display: inline-flex;
    width: fit-content;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    color: #0f4e3f;
    background: #dff8e8;
    border: 1px solid #a9e4c0;
}

.pricing-page {
    display: grid;
    gap: var(--space-4);
}

.pricing-hero-panel {
    display: grid;
    gap: var(--space-3);
    border-radius: clamp(22px, 3vw, 30px);
    border-color: #b9d0f2;
    background:
        radial-gradient(circle at 8% 8%, rgba(29, 78, 216, 0.14), transparent 38%),
        radial-gradient(circle at 90% 10%, rgba(14, 165, 166, 0.12), transparent 36%),
        linear-gradient(160deg, #ffffff 0%, #f2f8ff 60%, #f4fcfb 100%);
    box-shadow: var(--shadow);
}

.pricing-hero-copy {
    display: grid;
    gap: 8px;
    max-width: 72ch;
}

.pricing-hero-panel h1 {
    font-size: clamp(1.8rem, 4.3vw, 2.7rem);
}

.pricing-hero-subtitle {
    font-size: 1.02rem;
}

.pricing-hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.pricing-hero-actions .form-actions {
    margin: 0;
}

.pricing-hero-actions .btn {
    min-width: 170px;
}

.pricing-hero-note {
    margin: 0;
}

.pricing-toggle-panel {
    display: grid;
    gap: 12px;
}

.pricing-toggle-header {
    display: grid;
    gap: 4px;
}

.billing-toggle {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
}

.billing-toggle-option {
    border: 1px solid #c8d8ed;
    border-radius: 999px;
    background: #f5f9ff;
    color: #284e79;
    font-weight: 800;
    padding: 10px 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease, background 120ms ease;
}

.billing-toggle-option:hover {
    transform: translateY(-1px);
}

.billing-toggle-option.is-selected {
    border-color: #8eaee3;
    background: #e7f0ff;
    box-shadow: 0 8px 16px rgba(26, 64, 112, 0.12);
}

.billing-toggle-option:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

.pricing-grid-enhanced {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    align-items: stretch;
}

.pricing-card {
    border-color: #cfddf0;
    display: grid;
    gap: 12px;
    align-content: start;
}

.pricing-card-free {
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.pricing-card-premium {
    border-color: #bad2ea;
    background: linear-gradient(180deg, #ffffff 0%, #f1f8ff 100%);
}

.pricing-card-founder {
    border-style: dashed;
    background: linear-gradient(180deg, #fffefb 0%, #f8fbff 100%);
}

.pricing-card-highlight {
    border-width: 2px;
    border-color: #7daed8;
    box-shadow: 0 20px 32px rgba(23, 66, 109, 0.12);
}

.pricing-card.is-emphasized {
    border-color: #6f9bcc;
    box-shadow: 0 18px 28px rgba(24, 72, 124, 0.16);
    transform: translateY(-2px);
}

.plan-price-line {
    min-height: 1.5em;
}

.comparison-mobile-cards {
    margin-top: 12px;
    display: none;
    gap: 10px;
}

.comparison-mobile-card {
    border: 1px solid #d2dff2;
    border-radius: 14px;
    padding: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    display: grid;
    gap: 6px;
}

.comparison-mobile-card h4 {
    margin: 0;
    font-size: 0.95rem;
}

.pricing-faq-panel {
    display: grid;
    gap: 10px;
}

.faq-item {
    border: 1px solid #d6e2f2;
    border-radius: 12px;
    background: #f9fcff;
    padding: 10px 12px;
}

.faq-item summary {
    cursor: pointer;
    font-weight: 800;
    color: #1f4676;
}

.faq-item p {
    margin-top: 8px;
    color: #375677;
}

.pricing-trust-panel ul {
    margin: 0;
}

.billing-state-panel {
    display: grid;
    gap: 12px;
}

.chart-list {
    display: grid;
    gap: 9px;
}

.chart-row {
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr) 44px;
    gap: 10px;
    align-items: center;
}

.chart-label {
    font-size: 0.84rem;
    color: #385274;
    font-weight: 700;
}

.chart-track {
    height: 10px;
    border-radius: 999px;
    background: #e8eef8;
    overflow: hidden;
}

.chart-track span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(140deg, var(--accent) 0%, var(--primary) 100%);
}

.chart-count {
    text-align: right;
    font-size: 0.84rem;
    color: #305074;
    font-weight: 800;
}

.print-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--space-3);
    flex-wrap: wrap;
}

.print-section {
    break-inside: avoid;
    page-break-inside: avoid;
}

.print-quiz-item {
    padding: 10px;
}

.foot-note {
    margin-top: var(--space-3);
}

.hidden {
    display: none !important;
}

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

@keyframes pulse {
    0%,
    100% {
        transform: scale(0.85);
        opacity: 0.65;
    }
    50% {
        transform: scale(1.12);
        opacity: 1;
    }
}

@keyframes landing-fade-up {
    from {
        opacity: 0;
        transform: translateY(14px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes landing-float {
    0%,
    100% {
        transform: translate3d(-1%, -1%, 0) scale(1);
    }
    50% {
        transform: translate3d(2%, 1%, 0) scale(1.02);
    }
}

@keyframes camera-shutter-flash {
    0% {
        opacity: 0;
    }
    25% {
        opacity: 0.72;
    }
    100% {
        opacity: 0;
    }
}

@media (min-width: 920px) {
    .hero-landing {
        grid-template-columns: minmax(0, 1fr) minmax(280px, 350px);
        align-items: end;
    }
}

@media (max-width: 980px) {
    .page-shell {
        padding: 18px 14px 44px;
    }

    .study-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .guidance-panel {
        position: static;
        top: auto;
    }

    .form-grid.two-col {
        grid-template-columns: 1fr;
    }

    .section-nav {
        top: 74px;
    }

    .dashboard-continue-card {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 760px) {
    .top-nav {
        top: 8px;
        padding: 10px;
    }

    .nav-toggle {
        display: inline-flex;
    }

    .top-nav nav {
        width: 100%;
        margin-left: 0;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .top-nav nav.is-open {
        display: flex;
    }

    .top-nav nav a,
    .button-link {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    .usage-strip {
        align-items: stretch;
    }

    .split-header,
    .dashboard-hero {
        align-items: stretch;
    }

    .dashboard-hero-actions,
    .study-form-hero-actions {
        width: 100%;
        margin-left: 0;
    }

    .action-pair,
    .hero-actions,
    .pricing-hero-actions,
    .inline-row,
    .form-actions,
    .share-row {
        width: 100%;
    }

    .action-pair .btn,
    .hero-actions .btn,
    .inline-row .btn,
    .form-actions .btn,
    .usage-actions .btn,
    .share-row .btn {
        width: 100%;
    }

    .share-row input {
        width: 100%;
    }

    .pricing-hero-actions .form-actions {
        width: 100%;
    }

    .study-form-actions {
        align-items: stretch;
    }

    .section-actions .feedback-row .btn,
    .section-actions .feedback-reason-row .btn {
        width: auto;
    }

    .section-actions .feedback-row {
        flex-wrap: wrap;
    }

    .camera-action-row {
        width: 100%;
    }

    .camera-action-row .btn,
    .camera-action-row .camera-upload-label {
        width: 100%;
    }

    .image-upload-button {
        width: 100%;
    }

    .camera-preview-shell {
        width: 100%;
    }

    .camera-controls .btn {
        flex: 1 1 100%;
    }

    .ocr-preview-item {
        grid-template-columns: auto 56px minmax(0, 1fr);
    }

    .ocr-preview-actions {
        grid-column: 1 / -1;
        justify-content: flex-start;
    }

    .section-nav {
        top: 70px;
        margin-bottom: 4px;
    }

    .comparison-table-wrap {
        display: none;
    }

    .comparison-mobile-cards {
        display: grid;
    }

    .pricing-card.is-emphasized {
        transform: none;
    }
}

@media (max-width: 560px) {
    .hero-landing {
        padding: 22px 16px;
    }

    .landing-hero {
        min-height: 70svh;
        padding-top: clamp(26px, 9vh, 42px);
    }

    #landing-title {
        font-size: clamp(2.18rem, 13.5vw, 3.3rem);
    }

    .landing-tagline {
        font-size: clamp(1rem, 4.7vw, 1.17rem);
    }

    .landing-cta.btn-primary {
        min-width: min(300px, 92vw);
        padding: 14px 22px;
    }

    .panel {
        padding: 15px;
    }

    .auth-shell-entry::before {
        left: -130px;
        top: -86px;
    }

    .auth-shell-entry::after {
        right: -136px;
        bottom: -126px;
    }

    .auth-card-entry {
        border-radius: 22px;
        padding: 18px 16px;
    }

    .auth-card-entry h1 {
        font-size: clamp(1.56rem, 8vw, 2rem);
    }

    .study-form-section {
        padding: 13px;
    }

    .auto-detection-note {
        display: grid;
        gap: 3px;
    }

    .study-text-field {
        padding: 10px;
    }

    .study-text-field textarea {
        min-height: 220px;
    }

    .section-intro h1 {
        font-size: clamp(1.35rem, 7vw, 2rem);
    }

    .hero h1 {
        font-size: clamp(1.75rem, 9vw, 2.4rem);
    }

    .pack-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-pack-meta {
        grid-template-columns: 1fr;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .billing-toggle {
        display: grid;
        width: 100%;
        grid-template-columns: 1fr;
    }

    .billing-toggle-option {
        width: 100%;
        justify-content: space-between;
    }
}

@media (min-width: 760px) {
    .landing-feature-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (prefers-reduced-motion: reduce) {
    .landing-hero-glow,
    .landing-hero-content > *,
    .landing-feature-card,
    .auth-card-entry {
        animation: none !important;
        opacity: 1 !important;
    }

    .landing-cta,
    .landing-cta::before,
    .landing-feature-card,
    .auth-card-entry .btn-primary,
    .auth-card-entry input,
    .study-text-field {
        transition: none !important;
    }
}

@media print {
    body {
        background: #ffffff;
    }

    .top-nav,
    .usage-strip,
    .no-print,
    .section-nav {
        display: none !important;
    }

    .page-shell {
        width: 100%;
        padding: 0;
    }

    .content-wrap {
        gap: 12px;
    }

    .panel,
    .flashcard,
    .quiz-item {
        box-shadow: none;
        border-color: #d5dbe5;
    }
}
