@font-face {
  font-family: "Literata";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/fonts/literata-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "Literata";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/fonts/literata-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light;
  --z-primary: #0b7a53;
  --z-primary-hover: #086341;
  --z-primary-active: #064f35;
  --z-primary-soft: #e9f6ef;
  --z-primary-line: #bfe5d2;
  --z-canvas: #f5f7f5;
  --z-surface: #ffffff;
  --z-surface-muted: #eef2ef;
  --z-ink: #172019;
  --z-muted: #5f6b64;
  --z-muted-strong: #465149;
  --z-line: #dce3de;
  --z-line-strong: #b8c5bc;
  --z-danger: #b42318;
  --z-danger-soft: #fff0ee;
  --z-warning: #a05a00;
  --z-warning-soft: #fff7e8;
  --z-success: #086341;
  --z-radius-sm: 6px;
  --z-radius-md: 8px;
  --z-radius-lg: 12px;
  --z-overlay-shadow: 0 16px 48px rgba(23, 32, 25, 0.16);
  --z-page: 1180px;
  --z-app: 1480px;
  --z-space-1: 4px;
  --z-space-2: 8px;
  --z-space-3: 12px;
  --z-space-4: 16px;
  --z-space-5: 24px;
  --z-space-6: 32px;
  --z-space-7: 48px;
  --z-space-8: 64px;
  --z-motion-fast: 120ms;
  --z-motion-base: 180ms;
  --z-motion-slow: 220ms;
  --z-ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --z-focus: 0 0 0 3px rgba(11, 122, 83, 0.24);
  --z-display-font: "Literata", Georgia, "Times New Roman", serif;

  /* Compatibility aliases for the legacy component stylesheet. */
  --bg: var(--z-canvas);
  --paper: var(--z-surface);
  --panel: var(--z-surface);
  --ink: var(--z-ink);
  --muted: var(--z-muted);
  --line: var(--z-line);
  --line-strong: var(--z-line-strong);
  --brand: var(--z-primary);
  --brand-dark: var(--z-primary-hover);
  --brand-deep: var(--z-primary-active);
  --brand-soft: var(--z-primary-soft);
  --mint: var(--z-primary-soft);
  --mint-strong: var(--z-primary-line);
  --teal: var(--z-primary);
  --teal-dark: var(--z-primary-hover);
  --blue: var(--z-primary);
  --rose: var(--z-danger);
  --amber: var(--z-warning);
  --green-soft: var(--z-primary-soft);
  --blue-soft: var(--z-primary-soft);
  --rose-soft: var(--z-danger-soft);
  --amber-soft: var(--z-warning-soft);
  --shadow: none;
  --shadow-soft: none;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  scroll-behavior: smooth;
  scroll-padding-top: 76px;
}

body {
  min-width: 320px;
  margin: 0;
  background: var(--z-canvas);
  color: var(--z-ink);
  font-family: "Segoe UI Variable Text", "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.marketing-page,
body.app-page {
  background: var(--z-canvas);
  background-image: none;
}

body.app-page {
  background: var(--z-surface-muted);
}

button,
input,
textarea,
select {
  font: inherit;
  letter-spacing: 0;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  touch-action: manipulation;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
  max-width: 100%;
}

::selection {
  background: #bfe5d2;
  color: var(--z-ink);
}

:where(a, button, input, textarea, select, summary):focus-visible {
  outline: 3px solid var(--z-primary-line);
  outline-offset: 2px;
}

.skip-link {
  position: fixed;
  z-index: 200;
  top: 10px;
  left: 10px;
  padding: 10px 14px;
  border-radius: var(--z-radius-md);
  background: var(--z-ink);
  color: #fff;
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.app-shell {
  min-height: 100svh;
  background: transparent;
}

.site-header {
  position: sticky;
  z-index: 60;
  top: 0;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  width: 100%;
  max-width: none;
  min-height: 64px;
  margin: 0;
  padding: 10px max(24px, calc((100vw - var(--z-page)) / 2));
  border: 0;
  border-bottom: 1px solid var(--z-line);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: none;
}

.brand {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-width: 0;
}

.brand-mark {
  display: inline-flex;
  width: auto;
  min-width: 108px;
  height: 38px;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  border: 0;
  border-radius: var(--z-radius-sm);
  background: var(--z-primary);
  box-shadow: none;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
}

.brand-mark::before,
.brand-mark::after,
.brand::after {
  display: none;
  content: none;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  min-width: 0;
}

.nav-links a {
  position: relative;
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--z-muted);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--z-ink);
}

.nav-links a[aria-current="page"]::after {
  position: absolute;
  right: 0;
  bottom: 2px;
  left: 0;
  height: 2px;
  background: var(--z-primary);
  content: "";
}

.header-cta,
.primary-button,
.small-button,
.ghost-button,
.link-button,
.trainer-answer-button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  box-shadow: none;
  font-size: 15px;
  font-weight: 650;
  line-height: 1.2;
  text-align: center;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease;
}

.header-cta,
.primary-button,
.trainer-answer-button {
  border-color: var(--z-primary);
  background: var(--z-primary);
  color: #fff;
}

.header-cta:hover,
.primary-button:hover,
.trainer-answer-button:hover:not(:disabled) {
  border-color: var(--z-primary-hover);
  background: var(--z-primary-hover);
}

.small-button,
.ghost-button {
  background: var(--z-surface);
  color: var(--z-ink);
}

.small-button:hover,
.ghost-button:hover {
  border-color: var(--z-primary);
  color: var(--z-primary-hover);
}

.primary-button:disabled,
.small-button:disabled,
.trainer-answer-button:disabled {
  border-color: var(--z-line);
  background: #e7ece8;
  color: #849087;
  cursor: not-allowed;
}

.status-pill {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--z-primary-line);
  border-radius: var(--z-radius-sm);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
  font-size: 13px;
  font-weight: 650;
}

.marketing-page main {
  overflow: hidden;
}

.landing-hero,
.landing-band,
.page-hero,
.feature-matrix,
.pricing-page-grid,
.pricing-notes,
.payment-readiness,
.legal-layout,
.legal-document {
  width: min(calc(100% - 48px), var(--z-page));
  max-width: var(--z-page);
  margin-inline: auto;
}

.landing-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(420px, 0.85fr);
  gap: clamp(40px, 6vw, 78px);
  align-items: center;
  min-height: calc(100svh - 132px);
  padding: 32px 0 36px;
  border: 0;
  background: none;
}

.landing-copy {
  max-width: 650px;
}

.eyebrow,
.section-kicker {
  display: block;
  width: fit-content;
  margin: 0 0 16px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--z-primary-hover);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
}

.landing-copy h1 {
  max-width: 620px;
  margin: 0;
  color: var(--z-ink);
  font-size: clamp(54px, 7vw, 82px);
  font-weight: 760;
  line-height: 0.98;
  letter-spacing: 0;
  text-wrap: balance;
}

.hero-lead {
  max-width: 610px;
  margin: 22px 0 0;
  color: var(--z-muted);
  font-size: clamp(18px, 1.7vw, 21px);
  line-height: 1.55;
}

.landing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.landing-actions .link-button {
  box-shadow: none;
}

.landing-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 22px;
}

.landing-proof span {
  position: relative;
  padding: 0 0 0 18px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--z-muted);
  font-size: 13px;
  font-weight: 600;
  box-shadow: none;
}

.landing-proof span::before {
  position: absolute;
  top: 0.55em;
  left: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--z-primary);
  content: "";
}

.hero-product-card,
.hero-trainer-card {
  width: 100%;
  min-height: 470px;
  padding: 20px;
  overflow: hidden;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
  box-shadow: none;
}

.trainer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 700;
}

.trainer-top strong {
  color: var(--z-muted);
  font-size: 12px;
}

.trainer-progress {
  height: 6px;
  margin: 10px 0 16px;
  overflow: hidden;
  border-radius: 3px;
  background: var(--z-surface-muted);
}

.trainer-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--z-primary);
  transition: width 200ms ease;
}

.trainer-question {
  display: grid;
  gap: 10px;
}

.trainer-question small {
  color: var(--z-muted);
  font-size: 13px;
  font-weight: 600;
}

.trainer-question h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: clamp(25px, 2.2vw, 32px);
  font-weight: 720;
  line-height: 1.12;
  text-wrap: balance;
}

.trainer-options {
  display: grid;
  gap: 6px;
}

.trainer-options button {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
  color: var(--z-ink);
  text-align: left;
}

.trainer-options button:hover {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.trainer-options button:first-child {
  border-color: var(--z-line);
  background: var(--z-surface);
}

.trainer-options span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: var(--z-radius-sm);
  background: var(--z-surface-muted);
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 700;
}

.trainer-feedback {
  margin: 0;
  padding: 10px 12px;
  border-left: 3px solid var(--z-primary);
  background: var(--z-primary-soft);
  color: var(--z-ink);
  font-size: 14px;
}

.trainer-feedback-source {
  margin: -2px 0 0;
  color: var(--z-muted-strong);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.4;
}

.trainer-answer-button {
  width: 100%;
}

.trainer-mini-pack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.trainer-mini-pack span {
  padding: 5px 8px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-sm);
  background: var(--z-surface);
  color: var(--z-muted);
  font-size: 12px;
  font-weight: 600;
}

.landing-band {
  padding: 76px 0;
  border-top: 1px solid var(--z-line);
  background: transparent;
}

.section-heading,
.preview-copy {
  max-width: 760px;
}

.section-heading h2,
.preview-copy h2,
.landing-cta h2,
.page-hero h1 {
  margin: 0;
  color: var(--z-ink);
  font-size: clamp(34px, 4.2vw, 56px);
  font-weight: 720;
  line-height: 1.08;
  letter-spacing: 0;
  text-wrap: balance;
}

.section-heading p,
.preview-copy p,
.landing-cta p,
.page-hero p {
  max-width: 72ch;
  margin: 18px 0 0;
  color: var(--z-muted);
  font-size: 18px;
  line-height: 1.6;
}

.product-story-grid,
.signature-grid,
.landing-step-grid,
.flow-demo-grid {
  display: grid;
  gap: 0;
  margin-top: 40px;
  border-top: 1px solid var(--z-line);
  border-bottom: 1px solid var(--z-line);
}

.product-story-grid,
.signature-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.landing-step-grid,
.flow-demo-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.product-story-grid article,
.signature-grid article,
.landing-step-grid article,
.flow-demo-grid article {
  min-width: 0;
  min-height: 190px;
  padding: 26px 24px;
  border: 0;
  border-right: 1px solid var(--z-line);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.product-story-grid article:last-child,
.signature-grid article:last-child,
.landing-step-grid article:last-child,
.flow-demo-grid article:last-child {
  border-right: 0;
}

.feature-icon,
.landing-step-grid article > span:first-child {
  display: inline-flex;
  width: auto;
  min-width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  border: 0;
  border-radius: var(--z-radius-sm);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 700;
}

.product-story-grid h3,
.landing-step-grid h3,
.signature-grid strong,
.flow-demo-grid strong {
  display: block;
  margin: 18px 0 0;
  color: var(--z-ink);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.25;
}

.product-story-grid p,
.landing-step-grid p,
.signature-grid p,
.flow-demo-grid span {
  display: block;
  margin: 10px 0 0;
  color: var(--z-muted);
  font-size: 15px;
  line-height: 1.55;
}

.preview-section {
  display: grid;
  grid-template-columns: minmax(260px, 0.38fr) minmax(0, 0.62fr);
  gap: 52px;
  align-items: center;
}

.product-preview-frame,
.live-product-preview {
  min-width: 0;
  min-height: 440px;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
  box-shadow: none;
}

.real-product-preview {
  min-height: 0;
  aspect-ratio: 16 / 10;
  background: #edf3ef;
}

.real-product-preview img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.preview-window {
  height: 100%;
  min-height: 440px;
  background: var(--z-surface);
}

.preview-sidebar,
.preview-main,
.preview-upload-card,
.preview-side-card,
.preview-content-grid article {
  border-color: var(--z-line);
  background: var(--z-surface);
  box-shadow: none;
}

.preview-side-card,
.preview-upload-card,
.preview-content-grid article {
  border-radius: var(--z-radius-md);
}

.page-hero {
  padding: 84px 0 58px;
}

.page-hero h1 {
  max-width: 920px;
  font-size: clamp(42px, 5.4vw, 68px);
}

.page-hero p {
  max-width: 780px;
  font-size: 20px;
}

.feature-matrix {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 0 0 76px;
}

.feature-matrix article {
  min-height: 245px;
  padding: 24px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.feature-matrix h2 {
  margin: 20px 0 0;
  color: var(--z-ink);
  font-size: 21px;
  font-weight: 700;
  line-height: 1.25;
}

.feature-matrix p {
  margin: 10px 0 0;
  color: var(--z-muted);
  font-size: 15px;
  line-height: 1.55;
}

.feature-flow {
  width: 100%;
  max-width: none;
  padding-inline: max(24px, calc((100vw - var(--z-page)) / 2));
  background: var(--z-surface);
}

.feature-flow .section-heading,
.feature-flow .flow-demo-grid {
  width: 100%;
  max-width: var(--z-page);
  margin-inline: auto;
}

.flow-demo-grid article {
  display: flex;
  min-height: 250px;
  flex-direction: column;
}

.flow-ui-fragment {
  min-height: 68px;
  margin-top: auto;
  padding: 12px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-sm);
  background: var(--z-surface);
  color: var(--z-ink);
}

.flow-ui-fragment small,
.flow-ui-fragment b,
.flow-ui-fragment i,
.flow-ui-fragment strong {
  font-size: 11px;
  line-height: 1.3;
}

.flow-upload-fragment {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.flow-upload-fragment b {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 4px;
  background: var(--z-primary);
  color: #fff;
}

.flow-upload-fragment i,
.flow-queue-fragment i {
  color: var(--z-primary-hover);
  font-style: normal;
  font-weight: 700;
}

.flow-topic-fragment {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr);
  gap: 8px;
  align-content: center;
}

.flow-topic-fragment i {
  width: 7px;
  height: 7px;
  margin-top: 3px;
  border-radius: 50%;
  background: var(--z-primary);
}

.flow-question-fragment {
  display: grid;
  grid-template-columns: minmax(0, 1fr) repeat(3, 24px);
  gap: 6px;
  align-items: center;
}

.flow-question-fragment b {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border: 1px solid var(--z-line-strong);
  border-radius: 4px;
  color: var(--z-primary-hover);
}

.flow-queue-fragment {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3px 10px;
  align-content: center;
}

.flow-queue-fragment strong {
  grid-column: 1;
  color: var(--z-ink);
  font-size: 15px;
}

.flow-queue-fragment i {
  grid-column: 2;
  grid-row: 1 / 3;
  align-self: center;
}

.student-results-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 40px;
  border-top: 1px solid var(--z-line);
  border-bottom: 1px solid var(--z-line);
}

.student-results-grid article {
  min-width: 0;
  padding: 26px 24px;
  border-right: 1px solid var(--z-line);
}

.student-results-grid article:last-child {
  border-right: 0;
}

.student-results-grid article > span {
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 750;
}

.student-results-grid h3 {
  margin: 18px 0 0;
  color: var(--z-ink);
  font-size: 20px;
  line-height: 1.25;
}

.student-results-grid p {
  margin: 10px 0 0;
  color: var(--z-muted);
  font-size: 15px;
  line-height: 1.55;
}

@media (max-width: 780px) {
  .student-results-grid {
    grid-template-columns: 1fr;
  }

  .student-results-grid article {
    border-right: 0;
    border-bottom: 1px solid var(--z-line);
  }

  .student-results-grid article:last-child {
    border-bottom: 0;
  }
}

.billing-switch-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(calc(100% - 48px), var(--z-page));
  max-width: var(--z-page);
  margin: 0 auto 20px;
  padding: 18px 20px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.billing-switch-panel h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
}

.billing-switch-panel p {
  margin: 4px 0 0;
  color: var(--z-muted);
  font-size: 14px;
}

.billing-toggle {
  display: grid;
  grid-template-columns: repeat(2, minmax(132px, 1fr));
  min-width: 316px;
  padding: 4px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface-muted);
}

.billing-toggle button {
  min-height: 48px;
  padding: 7px 12px;
  border: 0;
  border-radius: var(--z-radius-sm);
  background: transparent;
  box-shadow: none;
  color: var(--z-muted);
  font-size: 14px;
  font-weight: 650;
  cursor: pointer;
}

.billing-toggle button span {
  display: block;
  margin-top: 1px;
  color: inherit;
  font-size: 11px;
  font-weight: 600;
}

.billing-toggle button.active {
  background: var(--z-primary);
  box-shadow: none;
  color: #fff;
}

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

.pricing-grid-four,
.home-pricing-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.pricing-page-grid {
  padding: 8px 0 76px;
}

.pricing-choice-guide {
  display: grid;
  grid-template-columns: minmax(220px, 0.34fr) minmax(0, 0.66fr);
  gap: 32px;
  align-items: end;
  width: min(calc(100% - 48px), var(--z-page));
  max-width: var(--z-page);
  margin: 22px auto 20px;
  padding: 24px 0;
  border-top: 1px solid var(--z-line);
  border-bottom: 1px solid var(--z-line);
}

.pricing-choice-guide h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 24px;
  line-height: 1.2;
}

.pricing-choice-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.pricing-choice-list span,
.pricing-choice-list strong {
  display: block;
}

.pricing-choice-list span {
  color: var(--z-primary-hover);
  font-size: 13px;
  font-weight: 700;
}

.pricing-choice-list strong {
  margin-bottom: 5px;
  color: var(--z-muted);
  font-size: 11px;
  font-weight: 600;
}

.pricing-card {
  display: flex;
  min-width: 0;
  min-height: 500px;
  flex-direction: column;
  padding: 24px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
  transform: none;
}

.pricing-card.featured {
  border: 2px solid var(--z-primary);
  background: var(--z-surface);
  box-shadow: none;
  transform: none;
}

.plan-heading-row {
  display: flex;
  min-height: 30px;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
  justify-content: space-between;
}

.plan-recommendation {
  color: var(--z-primary-hover);
  font-size: 10px;
  font-weight: 750;
}

.pricing-card > .plan-fit {
  min-height: 42px;
  margin: 10px 0 0;
  color: var(--z-ink);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.4;
}

.plan-label {
  display: inline-flex;
  width: fit-content;
  min-height: 28px;
  align-items: center;
  padding: 0 9px;
  border: 1px solid var(--z-primary-line);
  border-radius: var(--z-radius-sm);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 700;
}

.pricing-card h3,
.plan-price h2 {
  margin: 18px 0 0;
  color: var(--z-ink);
  font-size: 38px;
  font-weight: 740;
  line-height: 1.05;
}

.plan-price {
  display: grid;
  min-height: 106px;
  align-content: start;
  margin-top: 0;
}

.plan-price h2 {
  display: grid;
  gap: 6px;
}

.plan-price .old-price {
  grid-row: 1;
  color: #7b8580;
  font-size: 15px;
  font-weight: 650;
  text-decoration: line-through;
}

.plan-price .current-price {
  grid-row: 2;
  color: var(--z-ink);
  font-size: clamp(32px, 3vw, 42px);
  font-weight: 740;
  line-height: 1.05;
  white-space: nowrap;
}

.price-note {
  min-height: 24px;
  margin: 8px 0 0;
  color: var(--z-muted);
  font-size: 13px;
  line-height: 1.4;
}

.price-note span {
  display: inline-flex;
  min-height: 22px;
  align-items: center;
  margin-left: 5px;
  padding: 0 6px;
  border-radius: var(--z-radius-sm);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
  font-size: 11px;
  font-weight: 700;
}

.pricing-card > p {
  margin: 18px 0 0;
  color: var(--z-muted);
  font-size: 15px;
  line-height: 1.5;
}

.pricing-card ul {
  display: grid;
  gap: 10px;
  margin: 22px 0 24px;
  padding: 0;
  list-style: none;
}

.pricing-card li {
  position: relative;
  padding-left: 21px;
  color: var(--z-ink);
  font-size: 14px;
  line-height: 1.45;
}

.pricing-card li::before {
  position: absolute;
  top: 0;
  left: 0;
  margin: 0;
  color: var(--z-primary);
  content: "✓";
  font-weight: 800;
}

.pricing-card .link-button {
  width: 100%;
  margin-top: auto;
}

.pricing-notes {
  grid-template-columns: 1fr;
  padding: 0 0 60px;
}

.pricing-notes article,
.payment-readiness-grid article,
.legal-card,
.legal-document article {
  padding: 24px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.usage-notes article {
  border-left: 3px solid var(--z-primary);
  background: #f5f9f6;
}

.usage-notes article > p {
  max-width: 740px;
}

.usage-rate-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.usage-rate-grid p {
  margin: 0;
  padding-top: 14px;
  border-top: 1px solid var(--z-primary-line);
}

.usage-rate-grid strong,
.usage-rate-grid span {
  display: block;
}

.usage-rate-grid strong {
  color: var(--z-ink);
  font-size: 18px;
}

.usage-rate-grid span {
  margin-top: 5px;
  color: var(--z-muted);
  font-size: 13px;
  line-height: 1.45;
}

@media (max-width: 780px) {
  .pricing-choice-guide {
    grid-template-columns: 1fr;
    width: calc(100% - 28px);
    gap: 22px;
  }

  .pricing-choice-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 12px;
  }

  .usage-rate-grid {
    grid-template-columns: 1fr;
  }
}

.payment-readiness {
  padding: 64px 0;
  border-top: 1px solid var(--z-line);
}

.payment-readiness-grid,
.legal-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 32px;
}

.landing-cta {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 68px max(24px, calc((100vw - var(--z-page)) / 2));
  border: 0;
  border-radius: 0;
  background: #123f31;
  box-shadow: none;
  color: #fff;
}

.landing-cta .section-kicker {
  color: #aee6c9;
}

.landing-cta h2,
.landing-cta p {
  max-width: 760px;
  color: #fff;
}

.landing-cta p {
  color: #d9e9e1;
}

.landing-cta .primary-button {
  margin-top: 26px;
  border-color: #fff;
  background: #fff;
  color: #123f31;
}

.landing-cta .primary-button:hover {
  background: #e9f6ef;
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: start;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 34px max(24px, calc((100vw - var(--z-page)) / 2));
  border: 0;
  border-top: 1px solid var(--z-line);
  background: var(--z-surface);
}

.site-footer div {
  display: grid;
  gap: 5px;
}

.site-footer strong {
  color: var(--z-ink);
  font-size: 16px;
}

.site-footer span,
.site-footer a {
  color: var(--z-muted);
  font-size: 13px;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px 20px;
}

.site-footer a:hover {
  color: var(--z-primary-hover);
}

.legal-hero {
  padding-bottom: 42px;
}

.legal-layout,
.legal-document {
  padding-bottom: 76px;
}

.legal-document {
  display: grid;
  gap: 12px;
}

.legal-note {
  padding: 18px 20px;
  border-left: 3px solid var(--z-primary);
  background: var(--z-primary-soft);
  color: var(--z-ink);
}

.legal-card h2,
.legal-document h2,
.payment-readiness-grid h3,
.pricing-notes h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 21px;
  font-weight: 700;
  line-height: 1.3;
}

.legal-card p,
.legal-document p,
.payment-readiness-grid p,
.pricing-notes p {
  margin: 10px 0 0;
  color: var(--z-muted);
  line-height: 1.6;
}

.legal-details {
  margin: 18px 0 0;
}

.legal-details div {
  padding: 10px 0;
  border-bottom: 1px solid var(--z-line);
}

/* Product workspace */
.app-page {
  background: var(--z-surface-muted);
}

.app-page .site-header {
  padding-inline: max(20px, calc((100vw - var(--z-app)) / 2));
}

.product-app {
  width: min(calc(100% - 32px), var(--z-app));
  max-width: var(--z-app);
  margin: 0 auto;
  padding: 18px 0 40px;
}

.app-console {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.app-side-panel {
  position: static;
  display: grid;
  gap: 12px;
  min-width: 0;
}

.app-main-column {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.side-card,
.tool-panel,
.flow-panel,
.result-panel,
.study-panel {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
  box-shadow: none;
}

.product-app .side-card,
.product-app .tool-panel,
.product-app .flow-panel,
.product-app .result-panel,
.product-app .study-panel,
.product-app .import-panel {
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
  box-shadow: none;
}

.product-app .today-card {
  background: var(--z-primary-soft);
}

.today-card {
  background: var(--z-primary-soft);
}

.today-card h1 {
  margin: 0;
  color: var(--z-ink);
  font-size: 28px;
  font-weight: 720;
  line-height: 1.1;
}

.today-card > p {
  margin: 10px 0 0;
  color: var(--z-muted);
  font-size: 14px;
  line-height: 1.5;
}

.today-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin-top: 16px;
  overflow: hidden;
  border: 1px solid rgba(11, 122, 83, 0.16);
  border-radius: var(--z-radius-md);
  background: #fff;
}

.today-metrics div {
  min-width: 0;
  padding: 10px;
  border: 0;
  border-right: 1px solid var(--z-line);
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}

.today-metrics div:last-child {
  border-right: 0;
}

.today-metrics strong {
  display: block;
  color: var(--z-ink);
  font-size: 22px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.today-metrics span {
  display: block;
  margin-top: 5px;
  color: var(--z-muted);
  font-size: 10px;
  white-space: nowrap;
}

.today-actions,
.quick-actions {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.today-actions button,
.quick-actions button {
  width: 100%;
}

.side-card-title,
.library-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.side-card-title strong,
.library-heading h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 18px;
  font-weight: 700;
}

.side-card-title span,
.library-heading span {
  color: var(--z-muted);
  font-size: 12px;
}

.usage-meter {
  display: grid;
  gap: 6px;
  margin-top: 14px;
}

.usage-meter > div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--z-muted);
  font-size: 12px;
}

.usage-meter > span,
.flow-meter,
.loader-bar,
.practice-progress-track {
  height: 6px;
  overflow: hidden;
  border-radius: 3px;
  background: var(--z-surface-muted);
}

.usage-meter > span > span,
.flow-meter > span,
.loader-bar > span,
.practice-progress-track > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--z-primary);
}

.library-search {
  display: block;
  margin-top: 14px;
}

input,
textarea,
select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
  color: var(--z-ink);
}

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

input::placeholder,
textarea::placeholder {
  color: #8a958e;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--z-primary);
  outline: 3px solid var(--z-primary-soft);
}

.library-list {
  display: grid;
  gap: 8px;
  max-height: min(48vh, 430px);
  margin-top: 10px;
  padding-right: 4px;
  overflow: auto;
  scrollbar-color: #aab5ae transparent;
  scrollbar-width: thin;
}

.library-item {
  padding: 12px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.library-item.active,
.library-item.due {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.panel-heading {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin: 0 0 16px;
}

.panel-heading h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 21px;
  font-weight: 720;
  line-height: 1.2;
}

.panel-heading p {
  margin: 3px 0 0;
  color: var(--z-muted);
  font-size: 13px;
  line-height: 1.4;
}

.step-badge {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: var(--z-radius-sm);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
  font-size: 13px;
  font-weight: 750;
}

.import-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 10px;
}

.dropzone {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 130px;
  padding: 20px;
  border: 1px dashed var(--z-primary-line);
  border-radius: var(--z-radius-md);
  background: #fbfdfb;
  cursor: pointer;
}

.dropzone:hover,
.dropzone.dragover {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
}

.dropzone-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: var(--z-radius-md);
  background: var(--z-primary);
  color: #fff;
  font-size: 24px;
  line-height: 1;
}

.dropzone strong,
.mic-copy strong {
  color: var(--z-ink);
  font-size: 15px;
  font-weight: 700;
}

.dropzone small,
.mic-copy small {
  display: block;
  margin-top: 4px;
  color: var(--z-muted);
  font-size: 12px;
  line-height: 1.45;
}

.mic-recorder {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 130px;
  padding: 18px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface-muted);
  box-shadow: none;
}

.mic-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.url-import-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  margin-top: 10px;
}

.text-import-panel {
  margin-top: 10px;
  padding: 0;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
}

.text-import-panel summary {
  padding: 12px;
  color: var(--z-ink);
  font-size: 14px;
  font-weight: 650;
  cursor: pointer;
}

.text-import-panel[open] {
  padding: 0 12px 12px;
}

.source-ready,
.source-files-list,
.language-choice,
.generation-scope,
.generation-loader {
  margin-top: 10px;
  padding: 12px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.generation-scope {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  border: 0;
  padding: 4px 0;
}

.generation-scope span,
.tabs button,
.practice-mode-pill {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 0 10px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-sm);
  background: var(--z-surface);
  color: var(--z-muted);
  font-size: 13px;
  font-weight: 650;
}

.check-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 12px 0;
  color: var(--z-ink);
  font-size: 14px;
}

.check-row input {
  width: 18px;
  min-height: 18px;
  margin: 0;
  accent-color: var(--z-primary);
}

#generateButton {
  width: 100%;
}

.status-line {
  margin: 8px 0 0;
  color: var(--z-muted);
  font-size: 12px;
}

.app-flow-panel {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
}

.app-flow-panel .flow-panel-copy {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.app-flow-panel .section-kicker {
  display: none;
}

.app-flow-panel h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 15px;
  font-weight: 720;
  line-height: 1.3;
}

.app-flow-panel p {
  max-width: 650px;
  margin: 0;
  color: var(--z-muted);
  font-size: 12px;
  line-height: 1.4;
  text-align: right;
}

.flow-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.flow-step {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 8px;
  align-items: center;
  min-width: 0;
  min-height: 58px;
  padding: 8px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.flow-step.current,
.flow-step.complete {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.flow-step > span {
  grid-row: span 2;
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: var(--z-radius-sm);
  background: var(--z-surface-muted);
  color: var(--z-muted);
  font-size: 12px;
  font-weight: 700;
}

.flow-step.current > span,
.flow-step.complete > span {
  background: var(--z-primary);
  color: #fff;
}

.flow-step strong {
  min-width: 0;
  overflow: hidden;
  color: var(--z-ink);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.flow-step small {
  min-width: 0;
  overflow: hidden;
  color: var(--z-muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace,
.app-main-column > .workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}

.result-panel,
.study-panel {
  min-height: 0;
}

.result-heading {
  margin-bottom: 12px;
}

.tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 0 0 10px;
  border-bottom: 1px solid var(--z-line);
  scrollbar-width: none;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tabs button {
  flex: 0 0 auto;
  cursor: pointer;
}

.tabs button.active {
  border-color: var(--z-primary);
  background: var(--z-primary);
  color: #fff;
}

.empty-state,
.study-empty {
  display: grid;
  min-height: 250px;
  place-items: center;
  align-content: center;
  padding: 32px;
  border: 1px dashed var(--z-line);
  border-radius: var(--z-radius-md);
  background: #fbfdfb;
  color: var(--z-muted);
  text-align: center;
}

.empty-state h3,
.study-empty strong {
  margin: 0;
  color: var(--z-ink);
  font-size: 22px;
  font-weight: 700;
}

.empty-state p,
.study-empty p {
  max-width: 580px;
  margin: 8px 0 0;
}

.study-stage {
  min-height: 0;
}

.practice-launch-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.practice-launch-card {
  display: flex;
  min-width: 0;
  min-height: 240px;
  flex-direction: column;
  padding: 20px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.practice-launch-card.recommended {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.practice-launch-card strong {
  font-size: 22px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.practice-launch-card p {
  color: var(--z-muted);
}

.practice-launch-card .primary-button {
  width: 100%;
  margin-top: auto;
}

.manual-deck-modal,
.practice-overlay {
  background: rgba(23, 32, 25, 0.56);
  overscroll-behavior: contain;
}

.manual-deck-card,
.practice-shell {
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
  box-shadow: var(--z-overlay-shadow);
}

.manual-deck-card {
  padding: 26px;
}

.modal-close-button,
.practice-icon-button {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--z-line);
  border-radius: 50%;
  background: var(--z-surface);
  box-shadow: none;
  color: var(--z-ink);
  font-size: 22px;
}

.practice-topbar {
  border-bottom: 1px solid var(--z-line);
  background: var(--z-surface);
}

.practice-progress-card {
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
  box-shadow: none;
}

.practice-card,
.quiz-question-card,
.flashcard-scene {
  border-color: var(--z-line);
  border-radius: var(--z-radius-lg);
  box-shadow: none;
}

.practice-question-card {
  padding: clamp(24px, 4vw, 40px);
  border: 1px solid var(--z-primary);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
  box-shadow: none;
}

.practice-question-card h2 {
  margin: 12px 0 0;
  color: var(--z-ink);
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 720;
  line-height: 1.18;
  text-wrap: balance;
}

.practice-options {
  display: grid;
  gap: 10px;
}

.practice-option-button {
  min-height: 66px;
  padding: 14px 18px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
  color: var(--z-ink);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  text-align: left;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease;
}

.practice-option-button:hover:not(:disabled),
.practice-option-button.selected {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
}

.practice-option-button.correct {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.practice-option-button.incorrect {
  border-color: #efc4bf;
  background: var(--z-danger-soft);
  color: var(--z-danger);
}

.practice-primary-button {
  width: 100%;
  min-height: 52px;
  padding: 12px 18px;
  border: 1px solid var(--z-primary);
  border-radius: var(--z-radius-md);
  background: var(--z-primary);
  box-shadow: none;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
}

.practice-primary-button:hover:not(:disabled) {
  border-color: var(--z-primary-hover);
  background: var(--z-primary-hover);
}

.practice-primary-button:disabled,
.practice-primary-button.muted {
  border-color: var(--z-line);
  background: var(--z-surface-muted);
  color: #849087;
  box-shadow: none;
}

.source-box {
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
}

.flip-card-title,
.quiz-question-card,
.practice-card {
  hyphens: none;
  overflow-wrap: break-word;
  word-break: normal;
}

.app-footer {
  margin-top: 24px;
}

.danger {
  border-color: #efc4bf;
  background: var(--z-danger-soft);
  color: var(--z-danger);
}

.hidden {
  display: none !important;
}

@media (max-width: 1180px) {
  .landing-hero {
    grid-template-columns: minmax(0, 0.9fr) minmax(380px, 0.8fr);
  }

  .pricing-grid-four,
  .home-pricing-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .app-console {
    grid-template-columns: 1fr;
  }

  .app-side-panel {
    position: static;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .app-side-panel .library-panel {
    grid-column: 1 / -1;
  }

  .library-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    max-height: 340px;
  }
}

@media (max-width: 980px) {
  .landing-hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero-product-card,
  .hero-trainer-card {
    max-width: 720px;
  }

  .preview-section {
    grid-template-columns: 1fr;
  }

  .feature-matrix {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .landing-step-grid,
  .flow-demo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .landing-step-grid article:nth-child(2),
  .flow-demo-grid article:nth-child(2) {
    border-right: 0;
  }

  .landing-step-grid article:nth-child(-n + 2),
  .flow-demo-grid article:nth-child(-n + 2) {
    border-bottom: 1px solid var(--z-line);
  }

  .billing-switch-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .billing-toggle {
    width: 100%;
  }

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

  .app-flow-panel .flow-panel-copy {
    display: grid;
  }

  .app-flow-panel p {
    text-align: left;
  }
}

@media (max-width: 780px) {
  html {
    scroll-padding-top: 0;
  }

  .site-header {
    position: relative;
    grid-template-columns: 1fr auto;
    gap: 10px;
    padding: 12px 14px;
  }

  .nav-links {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    order: 3;
    gap: 4px;
    width: 100%;
  }

  .nav-links a {
    min-width: 0;
    min-height: 38px;
    justify-content: center;
    padding: 0 6px;
    border: 1px solid var(--z-line);
    border-radius: var(--z-radius-sm);
    background: var(--z-surface);
    font-size: 12px;
    white-space: normal;
  }

  .nav-links a[aria-current="page"] {
    border-color: var(--z-primary-line);
    background: var(--z-primary-soft);
    color: var(--z-primary-hover);
  }

  .nav-links a[aria-current="page"]::after {
    display: none;
  }

  .header-cta {
    min-height: 38px;
    padding-inline: 12px;
    font-size: 13px;
  }

  .app-page .status-pill {
    display: none;
  }

  .landing-hero,
  .landing-band,
  .page-hero,
  .feature-matrix,
  .pricing-page-grid,
  .pricing-notes,
  .payment-readiness,
  .legal-layout,
  .legal-document {
    width: min(calc(100% - 28px), var(--z-page));
  }

  .landing-hero {
    gap: 22px;
    padding: 30px 0 34px;
  }

  .landing-copy h1 {
    font-size: clamp(48px, 14vw, 56px);
  }

  .landing-copy {
    padding-bottom: 0;
  }

  .hero-lead {
    margin-top: 16px;
    font-size: 17px;
  }

  .landing-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 20px;
  }

  .landing-actions .link-button {
    width: 100%;
    min-height: 50px;
    padding-inline: 10px;
    font-size: 13px;
    white-space: normal;
  }

  .landing-proof {
    display: none;
  }

  .hero-product-card,
  .hero-trainer-card {
    min-height: 0;
    padding: 16px;
  }

  .hero-trainer-card .trainer-options,
  .hero-trainer-card .trainer-feedback,
  .hero-trainer-card .trainer-answer-button,
  .hero-trainer-card .trainer-mini-pack {
    display: none;
  }

  .trainer-question h2 {
    font-size: 24px;
  }

  .landing-band {
    padding: 56px 0;
  }

  .section-heading h2,
  .preview-copy h2,
  .landing-cta h2,
  .page-hero h1 {
    font-size: clamp(34px, 10vw, 46px);
  }

  .section-heading p,
  .preview-copy p,
  .landing-cta p,
  .page-hero p {
    font-size: 16px;
  }

  .product-story-grid,
  .signature-grid,
  .landing-step-grid,
  .flow-demo-grid,
  .feature-matrix,
  .pricing-grid-four,
  .home-pricing-grid,
  .payment-readiness-grid,
  .legal-layout {
    grid-template-columns: 1fr;
  }

  .product-story-grid article,
  .signature-grid article,
  .landing-step-grid article,
  .flow-demo-grid article,
  .landing-step-grid article:nth-child(2),
  .flow-demo-grid article:nth-child(2) {
    min-height: 0;
    border-right: 0;
    border-bottom: 1px solid var(--z-line);
  }

  .product-story-grid article:last-child,
  .signature-grid article:last-child,
  .landing-step-grid article:last-child,
  .flow-demo-grid article:last-child {
    border-bottom: 0;
  }

  .feature-flow {
    width: 100%;
    padding-inline: 14px;
  }

  .feature-matrix article {
    min-height: 0;
  }

  .page-hero {
    padding: 54px 0 40px;
  }

  .billing-switch-panel {
    width: calc(100% - 28px);
    margin-inline: auto;
    padding: 16px;
  }

  .billing-toggle {
    min-width: 0;
  }

  .pricing-card {
    min-height: 0;
  }

  .landing-cta {
    padding: 54px 14px;
  }

  .site-footer {
    grid-template-columns: 1fr;
    padding: 28px 14px;
  }

  .site-footer nav {
    justify-content: flex-start;
  }

  .product-app {
    width: calc(100% - 20px);
    padding-top: 10px;
  }

  .app-console {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .app-side-panel {
    display: contents;
  }

  .app-main-column {
    display: contents;
  }

  .today-card {
    order: 1;
  }

  .import-panel {
    order: 2;
  }

  .app-flow-panel {
    order: 3;
  }

  .workspace {
    order: 4;
  }

  .quick-actions {
    order: 5;
  }

  .usage-card {
    order: 6;
  }

  .library-panel {
    order: 7;
  }

  .app-side-panel .library-panel {
    grid-column: auto;
  }

  .library-list {
    grid-template-columns: 1fr;
    max-height: 430px;
  }

  .side-card,
  .tool-panel,
  .flow-panel,
  .result-panel,
  .study-panel {
    padding: 14px;
    border-radius: var(--z-radius-md);
  }

  .panel-heading {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .panel-heading > :last-child:not(:nth-child(2)) {
    grid-column: 1 / -1;
  }

  .mic-recorder,
  .url-import-row {
    grid-template-columns: 1fr;
  }

  .mic-controls {
    justify-content: stretch;
  }

  .mic-controls button,
  .url-import-row button {
    width: 100%;
  }

  .flow-steps,
  .practice-launch-grid {
    grid-template-columns: 1fr;
  }

  .flow-step strong,
  .flow-step small {
    white-space: normal;
  }

  .empty-state,
  .study-empty {
    min-height: 200px;
    padding: 24px 16px;
  }

  .manual-deck-card {
    width: calc(100% - 20px);
    padding: 20px;
  }

  .practice-shell {
    border-radius: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* 2026-07-01: repetition scoring, single progress indicator and optical controls. */
.practice-topbar {
  grid-template-columns: 44px minmax(280px, 760px) auto;
}

.practice-toolbar {
  display: flex;
  align-items: center;
  gap: 6px;
}

.practice-shuffle-button::before {
  font-size: 21px;
}

.practice-card {
  width: min(100%, 900px);
}

.flashcard-practice-frame {
  grid-template-columns: 48px minmax(0, 720px) 48px;
}

.practice-source-row {
  width: min(100%, 720px);
}

.flip-card-title,
.flip-card-explanation {
  overflow-wrap: anywhere;
}

.card-nav-button {
  position: relative;
  font-size: 0;
}

.card-nav-button::before {
  content: "";
  display: block;
  width: 11px;
  height: 11px;
  border-top: 3px solid currentColor;
  border-right: 3px solid currentColor;
}

.card-nav-button[data-study-action="prev-card"]::before {
  transform: rotate(-135deg);
}

.card-nav-button[data-study-action="next-card"]::before {
  transform: rotate(45deg);
}

.card-nav-button:hover:not(:disabled) {
  border-color: var(--z-primary);
  background: var(--z-primary);
  color: #fff;
}

.field-hint {
  display: block;
  margin-top: 5px;
  color: var(--z-muted);
  font-size: 12px;
  line-height: 1.35;
}

.practice-result-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  margin: 20px 0 0;
}

.practice-result-stats div {
  display: grid;
  gap: 4px;
  padding: 14px 12px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
}

.practice-result-stats dt {
  color: var(--z-muted-strong);
  font-size: 13px;
  font-weight: 650;
}

.practice-result-stats dd {
  margin: 0;
  color: var(--z-ink);
  font-size: 26px;
  font-weight: 720;
  line-height: 1;
}

.practice-result-stats .known {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.practice-result-stats .almost {
  border-color: #e6c58e;
  background: var(--z-warning-soft);
}

.practice-result-stats .unknown {
  border-color: #efc4bf;
  background: var(--z-danger-soft);
}

.practice-quiz-result {
  width: 100%;
  margin: 14px 0 0;
  color: var(--z-muted-strong);
  text-align: center;
}

.practice-complete .practice-actions {
  width: 100%;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.practice-complete .practice-actions > :first-child:nth-last-child(3) {
  grid-column: 1 / -1;
}

@media (max-width: 780px) {
  .flashcard-practice-frame {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .flashcard-card-stack {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .card-nav-button:first-child {
    grid-column: 1;
    grid-row: 2;
  }

  .card-nav-button:last-child {
    grid-column: 2;
    grid-row: 2;
  }
}

@media (max-width: 620px) {
  .practice-topbar {
    grid-template-columns: 44px minmax(0, 1fr) auto;
  }

  .practice-toolbar {
    gap: 4px;
  }

  .practice-toolbar .practice-icon-button {
    width: 40px;
  }

  .practice-result-stats {
    gap: 5px;
  }

  .practice-result-stats div {
    padding: 12px 8px;
  }

  .practice-result-stats dt {
    font-size: 12px;
  }

  .practice-result-stats dd {
    font-size: 22px;
  }

  .practice-complete .practice-actions {
    grid-template-columns: 1fr;
  }

  .practice-complete .practice-actions > :first-child:nth-last-child(3) {
    grid-column: auto;
  }
}

/* 2026-06 editorial marketing layer: expressive outside, functional inside. */
.marketing-page {
  --z-page: 1280px;
  background: #f4f7f4;
}

.marketing-page .marketing-header {
  background: rgba(244, 247, 244, 0.97);
}

.marketing-page :is(.landing-copy h1, .section-heading h2, .preview-copy h2, .landing-cta h2, .page-hero h1, .trainer-demo-copy h2) {
  font-family: var(--z-display-font);
  font-weight: 560;
  letter-spacing: -0.025em;
}

.marketing-page .landing-hero {
  grid-template-columns: minmax(0, 0.78fr) minmax(560px, 1.22fr);
  gap: clamp(44px, 5vw, 84px);
  min-height: calc(100svh - 64px);
  align-items: center;
  padding-block: clamp(52px, 7vw, 92px);
}

.marketing-page .landing-copy {
  max-width: 600px;
}

.hero-note {
  margin: 0 0 22px;
  color: var(--z-primary-hover);
  font-size: 14px;
  font-weight: 700;
}

.marketing-page .landing-copy h1 {
  max-width: 660px;
  font-size: clamp(46px, 5.35vw, 78px);
  line-height: 1.02;
  text-wrap: balance;
}

.marker-underline {
  position: relative;
  display: inline;
  z-index: 0;
}

.marker-underline::after {
  position: absolute;
  z-index: -1;
  right: -0.02em;
  bottom: 0.04em;
  left: -0.02em;
  height: 0.12em;
  border-radius: 2px;
  background: #efd35b;
  content: "";
  transform: scaleX(1);
  transform-origin: left center;
}

.marketing-page.motion-ready .marker-underline::after {
  animation: marker-draw 720ms 220ms var(--z-ease-out) both;
}

@keyframes marker-draw {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

.marketing-page .hero-lead {
  max-width: 58ch;
  color: var(--z-muted-strong);
}

.assembly-demo {
  --assembly-accent: var(--z-primary);
  position: relative;
  width: 100%;
  min-width: 0;
  padding: 18px 0 10px;
  border-block: 1px solid var(--z-line-strong);
}

.assembly-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding: 0 4px 16px;
  border-bottom: 1px solid var(--z-line);
}

.assembly-heading p,
.assembly-heading span {
  margin: 0;
}

.assembly-heading p {
  color: var(--z-ink);
  font-size: 15px;
  font-weight: 700;
}

.assembly-heading span {
  color: var(--z-muted);
  font-size: 13px;
}

.assembly-canvas {
  display: grid;
  grid-template-columns: minmax(170px, 0.86fr) 88px minmax(220px, 1fr);
  gap: 18px;
  align-items: stretch;
  min-height: 498px;
  padding: 24px 0 12px;
}

.source-fragments,
.pack-results {
  display: grid;
  align-content: space-between;
  gap: 14px;
}

.source-fragment {
  position: relative;
  min-height: 94px;
  padding: 13px 15px;
  border: 1px solid var(--z-line-strong);
  border-radius: var(--z-radius-sm);
  background: rgba(255, 255, 255, 0.74);
  color: var(--z-ink);
  transform: rotate(-0.7deg);
  transition: border-color 260ms var(--z-ease-out), background-color 260ms var(--z-ease-out), opacity 260ms ease, transform 520ms var(--z-ease-out);
}

.source-fragment:nth-child(2) { transform: translateX(12px) rotate(0.5deg); }
.source-fragment:nth-child(3) { transform: translateX(2px) rotate(0.8deg); }
.source-fragment:nth-child(4) { transform: translateX(16px) rotate(-0.4deg); }

.source-fragment > span {
  display: block;
  margin-bottom: 11px;
  color: var(--z-primary-hover);
  font-size: 11px;
  font-weight: 700;
}

.source-fragment > i {
  display: block;
  width: 92%;
  height: 3px;
  margin-top: 8px;
  border-radius: 2px;
  background: var(--z-line-strong);
}

.source-fragment > i:nth-of-type(2) { width: 72%; }
.source-fragment > i:nth-of-type(3) { width: 84%; }

.waveform {
  display: flex;
  height: 28px;
  align-items: center;
  gap: 5px;
}

.waveform i {
  width: 3px;
  height: 45%;
  border-radius: 2px;
  background: var(--z-primary);
}

.waveform i:nth-child(2),
.waveform i:nth-child(5) { height: 82%; }
.waveform i:nth-child(3) { height: 56%; }
.waveform i:nth-child(4) { height: 100%; }

.video-fragment {
  background: #17352a;
  color: #fff;
}

.video-fragment > span { color: #d8eee3; }
.video-fragment strong {
  display: block;
  font-family: var(--z-display-font);
  font-size: 24px;
  font-weight: 500;
}

.note-fragment em {
  display: inline;
  font-family: var(--z-display-font);
  font-size: 18px;
  font-style: normal;
  background: linear-gradient(transparent 68%, rgba(239, 211, 91, 0.72) 68%);
}

.assembly-spine {
  position: relative;
  min-height: 100%;
}

.assembly-spine::before,
.assembly-spine::after {
  position: absolute;
  content: "";
}

.assembly-spine::before {
  top: 5%;
  bottom: 5%;
  left: 50%;
  width: 1px;
  background: var(--z-primary-line);
}

.assembly-spine::after {
  top: 50%;
  right: -18px;
  left: -18px;
  height: 1px;
  background: var(--z-primary);
}

.assembly-node,
.assembly-pulse {
  position: absolute;
  z-index: 1;
  left: 50%;
  border-radius: 50%;
  background: var(--z-primary);
  transform: translate(-50%, -50%);
}

.assembly-node {
  top: 50%;
  width: 13px;
  height: 13px;
  box-shadow: 0 0 0 5px #f4f7f4;
}

.assembly-pulse {
  top: 9%;
  width: 8px;
  height: 8px;
  opacity: 0.2;
  transition: top 620ms var(--z-ease-out), opacity 180ms ease;
}

.assembly-demo[data-phase="1"] .assembly-pulse { top: 36%; }
.assembly-demo[data-phase="2"] .assembly-pulse { top: 64%; }
.assembly-demo[data-phase="3"] .assembly-pulse { top: 91%; }

.pack-results article {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 94px;
  padding: 12px 0;
  border-bottom: 1px solid var(--z-line-strong);
  transition: border-color 260ms ease, opacity 260ms ease, transform 520ms var(--z-ease-out);
}

.pack-results article:first-child { border-top: 1px solid var(--z-line-strong); }

.pack-results article > span {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid var(--z-primary-line);
  border-radius: 50%;
  color: var(--z-primary-hover);
  font-size: 11px;
  font-weight: 700;
}

.pack-results strong,
.pack-results small {
  display: block;
}

.pack-results strong {
  font-family: var(--z-display-font);
  font-size: 21px;
  font-weight: 560;
}

.pack-results small {
  margin-top: 2px;
  color: var(--z-muted);
  font-size: 12px;
}

.assembly-demo.motion-ready .source-fragment:not(.is-current),
.assembly-demo.motion-ready .pack-results article:not(.is-built):not(.is-current) {
  opacity: 0.48;
}

.assembly-demo.motion-ready .source-fragment.is-current {
  border-color: var(--z-primary);
  background: #fff;
  opacity: 1;
  transform: translateX(18px) rotate(0deg);
}

.assembly-demo.motion-ready .pack-results article.is-built,
.assembly-demo.motion-ready .pack-results article.is-current {
  border-color: var(--z-primary);
  opacity: 1;
}

.assembly-demo.motion-ready .pack-results article.is-current {
  transform: translateX(8px);
}

.assembly-demo.motion-ready .assembly-pulse {
  opacity: 1;
}

.trainer-demo-section {
  display: grid;
  grid-template-columns: minmax(260px, 0.58fr) minmax(520px, 1fr);
  gap: clamp(48px, 8vw, 120px);
  align-items: center;
}

.trainer-demo-copy {
  max-width: 430px;
}

.trainer-demo-copy h2 {
  margin: 0;
  font-size: clamp(36px, 4.2vw, 58px);
  line-height: 1.08;
  text-wrap: balance;
}

.trainer-demo-copy > p:last-child {
  margin: 20px 0 0;
  color: var(--z-muted-strong);
  font-size: 17px;
  line-height: 1.62;
}

.trainer-demo-section .hero-trainer-card {
  min-height: 0;
}

.marketing-page .landing-band {
  padding-block: clamp(64px, 7vw, 92px);
}

.marketing-page .product-story {
  display: grid;
  grid-template-columns: minmax(300px, 0.72fr) minmax(0, 1fr);
  gap: clamp(48px, 8vw, 120px);
  align-items: end;
}

.marketing-page .product-story-grid {
  grid-template-columns: 1fr;
  margin-top: 0;
}

.marketing-page .product-story-grid article {
  display: grid;
  grid-template-columns: 52px 150px minmax(0, 1fr);
  gap: 18px;
  align-items: baseline;
  padding: 24px 0;
  border-right: 0;
}

.marketing-page .product-story-grid article h3,
.marketing-page .product-story-grid article p {
  margin: 0;
}

.marketing-page .product-story-grid article h3 {
  font-family: var(--z-display-font);
  font-size: 23px;
  font-weight: 560;
  overflow-wrap: normal;
}

.marketing-page .page-hero {
  padding-block: clamp(72px, 9vw, 128px);
}

@media (max-width: 1060px) {
  .marketing-page .landing-hero {
    grid-template-columns: minmax(0, 0.8fr) minmax(460px, 1.2fr);
    gap: 36px;
  }

  .assembly-canvas {
    grid-template-columns: minmax(150px, 0.8fr) 56px minmax(185px, 1fr);
    gap: 12px;
  }

  .trainer-demo-section {
    grid-template-columns: 0.7fr 1fr;
    gap: 42px;
  }
}

@media (max-width: 900px) {
  .marketing-page .landing-hero,
  .trainer-demo-section,
  .marketing-page .product-story,
  .source-trust-section {
    grid-template-columns: 1fr;
  }

  .marketing-page .landing-hero {
    min-height: auto;
  }

  .assembly-demo {
    max-width: 720px;
  }

  .trainer-demo-copy {
    max-width: 640px;
  }

  .source-trust-section {
    gap: 32px;
  }
}

@media (max-width: 620px) {
  .marketing-page .landing-hero {
    width: min(calc(100% - 32px), var(--z-page));
    padding-block: 40px 56px;
  }

  .marketing-page .landing-copy h1 {
    font-size: clamp(42px, 13vw, 58px);
  }

  .source-proof {
    padding: 22px 0 0;
    border-top: 2px solid var(--z-primary);
    border-left: 0;
  }

  .hero-note {
    margin-bottom: 16px;
  }

  .assembly-heading {
    display: block;
  }

  .assembly-heading span {
    display: block;
    margin-top: 4px;
  }

  .assembly-canvas {
    grid-template-columns: 1fr;
    min-height: 0;
    padding-top: 18px;
  }

  .source-fragments,
  .pack-results {
    gap: 8px;
  }

  .source-fragment {
    min-height: 68px;
    transform: none !important;
  }

  .source-fragment:nth-child(n + 3) {
    display: none;
  }

  .assembly-spine {
    min-height: 54px;
  }

  .assembly-spine::before {
    top: 0;
    bottom: 0;
  }

  .assembly-spine::after {
    top: 50%;
    right: 18%;
    left: 18%;
  }

  .assembly-pulse {
    display: none;
  }

  .pack-results article {
    min-height: 62px;
    padding: 8px 0;
  }

  .trainer-demo-section {
    gap: 30px;
  }

  .marketing-page .product-story-grid article {
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 12px;
  }

  .marketing-page .product-story-grid article p {
    grid-column: 2;
  }
}

@media (prefers-reduced-motion: reduce) {
  .marketing-page.motion-ready .marker-underline::after {
    animation: none;
  }

  .assembly-demo .source-fragment,
  .assembly-demo .pack-results article,
  .assembly-demo .assembly-pulse {
    transition: none;
  }

  .assembly-demo.motion-ready .source-fragment,
  .assembly-demo.motion-ready .pack-results article {
    opacity: 1;
    transform: none;
  }

  .assembly-pulse {
    display: none;
  }
}

/* 2026-06 UX system consolidation */
[hidden] {
  display: none !important;
}

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

#providerPill,
.provider-pill-hidden,
.mobile-nav-cta,
.nav-menu-button {
  display: none;
}

.nav-links .mobile-nav-cta {
  display: none;
}

h1,
h2,
h3,
.brand-mark,
button,
.primary-button,
.small-button,
.header-cta {
  font-family: "Segoe UI Variable Display", "Segoe UI", Arial, sans-serif;
}

h1,
h2,
h3 {
  text-wrap: balance;
}

p,
li {
  text-wrap: pretty;
}

h1,
h2,
h3,
.panel-heading,
.flow-step,
.library-card {
  overflow-wrap: anywhere;
}

button,
[role="button"],
summary,
label[for],
a[href] {
  cursor: pointer;
}

:where(a, button, input, textarea, select, summary):focus-visible {
  outline: 2px solid var(--z-primary);
  outline-offset: 3px;
  box-shadow: var(--z-focus);
}

.primary-button:active:not(:disabled),
.header-cta:active,
.practice-primary-button:active:not(:disabled) {
  background: var(--z-primary-active);
}

.landing-copy {
  position: relative;
  padding-left: 22px;
}

.landing-copy::before {
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 0;
  width: 1px;
  background: var(--z-primary-line);
  content: "";
}

.landing-copy::after {
  position: absolute;
  top: 4px;
  left: -4px;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--z-primary);
  content: "";
}

.landing-copy h1 {
  font-family: "Segoe UI Variable Display", "Segoe UI", Arial, sans-serif;
  font-weight: 720;
}

.landing-copy .eyebrow {
  border: 0;
  background: transparent;
  color: var(--z-primary-hover);
}

.landing-copy .hero-lead {
  color: var(--z-muted);
}

.landing-actions .ghost-button {
  border-color: var(--z-line);
  background: var(--z-surface);
  color: var(--z-ink);
}

.landing-actions .ghost-button:hover {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.product-story {
  padding-top: 48px;
}

.import-panel::before {
  background: var(--z-primary);
}

.page-hero h1 {
  font-size: clamp(40px, 4.6vw, 58px);
}

.signature-section {
  width: 100%;
  max-width: none;
  padding-inline: max(24px, calc((100vw - var(--z-page)) / 2));
  border-top: 0;
  background: #123f31;
  color: #fff;
}

.signature-section .section-heading,
.signature-section .signature-grid {
  width: 100%;
  max-width: var(--z-page);
  margin-inline: auto;
}

.signature-section .section-kicker {
  color: #aee6c9;
}

.signature-section .section-heading h2,
.signature-section .signature-grid strong {
  color: #fff;
}

.signature-section .signature-grid {
  border-color: rgba(255, 255, 255, 0.22);
}

.signature-section .signature-grid article {
  border-color: rgba(255, 255, 255, 0.22);
}

.signature-section .signature-grid p {
  color: #d9e9e1;
}

.source-trust-section {
  display: grid;
  grid-template-columns: minmax(0, 0.62fr) minmax(320px, 0.38fr);
  gap: clamp(48px, 8vw, 112px);
  align-items: center;
  background: #f5f9f6;
}

.source-trust-copy {
  max-width: 680px;
}

.source-trust-copy h2 {
  max-width: 650px;
  margin: 0;
  color: var(--z-ink);
  font-size: clamp(34px, 4.2vw, 56px);
  font-weight: 720;
  line-height: 1.08;
  text-wrap: balance;
}

.source-trust-copy > p:last-child {
  max-width: 62ch;
  margin: 18px 0 0;
  color: var(--z-muted-strong);
  font-size: 17px;
  line-height: 1.6;
}

.source-proof {
  padding: 26px 0 26px 28px;
  border-left: 2px solid var(--z-primary);
}

.source-proof span,
.source-proof strong,
.source-proof p {
  display: block;
}

.source-proof span {
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 750;
  text-transform: uppercase;
}

.source-proof strong {
  margin-top: 9px;
  color: var(--z-ink);
  font-size: 20px;
  line-height: 1.3;
}

.source-proof p {
  margin: 12px 0 0;
  color: var(--z-muted);
  font-size: 14px;
  line-height: 1.55;
}

.source-proof a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  margin-top: 12px;
  color: var(--z-primary-hover);
  font-size: 14px;
  font-weight: 700;
}

@media (max-width: 900px) {
  .source-trust-section {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }
}

@media (max-width: 620px) {
  .source-trust-section {
    width: 100%;
    padding-inline: 14px;
  }

  .source-proof {
    padding: 22px 0 0;
    border-top: 2px solid var(--z-primary);
    border-left: 0;
  }
}

.feature-matrix {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px 24px;
}

.feature-matrix article {
  min-height: 170px;
  padding: 24px 0;
  border: 0;
  border-top: 1px solid var(--z-line);
  border-radius: 0;
  background: transparent;
}

.feature-matrix article:nth-last-child(-n + 3) {
  border-bottom: 1px solid var(--z-line);
}

.feature-matrix .feature-primary {
  min-height: 250px;
  padding: 28px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
}

.feature-matrix .feature-primary h2 {
  max-width: 15ch;
  font-size: 24px;
}

@media (max-width: 980px) {
  .feature-matrix {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .feature-matrix article:nth-last-child(-n + 3) {
    border-bottom: 0;
  }

  .feature-matrix article:nth-last-child(-n + 2) {
    border-bottom: 1px solid var(--z-line);
  }
}

.preview-brand-row,
.preview-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
}

.preview-window {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
}

.preview-sidebar {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 20px 16px;
  border-right: 1px solid var(--z-line);
  background: var(--z-surface-muted);
}

.preview-main {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 24px;
}

.preview-side-card,
.preview-upload-card,
.preview-content-grid article {
  padding: 14px;
  border: 1px solid var(--z-line);
  background: var(--z-surface);
}

.preview-side-card,
.preview-upload-card > div,
.preview-content-grid article {
  display: grid;
  gap: 4px;
}

.preview-side-card small,
.preview-upload-card small,
.preview-content-grid small,
.preview-content-grid span {
  color: var(--z-muted);
  font-size: 12px;
}

.preview-upload-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.preview-upload-card button,
.preview-action-link {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px solid var(--z-primary);
  border-radius: var(--z-radius-md);
  background: var(--z-primary);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.preview-content-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.preview-logo,
.preview-step {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  place-items: center;
  border-radius: var(--z-radius-sm);
  background: var(--z-primary);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.preview-tabs {
  flex-wrap: wrap;
}

.preview-tabs span {
  padding: 6px 9px;
  border-bottom: 2px solid transparent;
  color: var(--z-muted);
  font-size: 12px;
  font-weight: 650;
}

.preview-tabs .active {
  border-bottom-color: var(--z-primary);
  color: var(--z-primary-hover);
}

.offer-document {
  display: grid;
  max-width: 980px;
  gap: 0;
}

.offer-document article {
  padding: 24px 0;
  border: 0;
  border-bottom: 1px solid var(--z-line);
  border-radius: 0;
  background: transparent;
}

.legal-note {
  padding: 18px 20px;
  border: 1px solid var(--z-primary-line);
  border-radius: var(--z-radius-md);
  background: var(--z-primary-soft);
}

.provider-pill-hidden {
  display: none !important;
}

.product-app {
  container-type: inline-size;
}

.app-main-column > .app-flow-panel {
  order: -1;
}

.source-method-switcher {
  display: flex;
  gap: 4px;
  margin-bottom: 12px;
  padding: 4px;
  overflow-x: auto;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface-muted);
  scrollbar-width: none;
}

.source-method-switcher::-webkit-scrollbar {
  display: none;
}

.source-method-tab {
  min-width: 92px;
  min-height: 44px;
  flex: 1 0 auto;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: var(--z-radius-sm);
  background: transparent;
  color: var(--z-muted-strong);
  font-size: 14px;
  font-weight: 650;
  transition: background-color var(--z-motion-fast) var(--z-ease-out), border-color var(--z-motion-fast) var(--z-ease-out), color var(--z-motion-fast) var(--z-ease-out);
}

input::placeholder,
textarea::placeholder {
  color: var(--z-muted);
  opacity: 1;
}

.check-row {
  min-height: 44px;
}

.source-method-tab:hover {
  color: var(--z-ink);
}

.source-method-tab.is-active {
  border-color: var(--z-line);
  background: var(--z-surface);
  color: var(--z-primary-hover);
}

.import-grid {
  display: block;
}

.source-method-panel.is-active.dropzone {
  display: grid;
}

.source-method-panel.is-active.mic-recorder,
.source-method-panel.is-active.url-import-row {
  display: grid;
}

.source-method-panel.is-active.text-import-panel {
  display: block;
}

.url-import-row {
  margin-top: 0;
}

.dropzone,
.mic-recorder {
  min-height: 156px;
}

.dropzone {
  border-color: var(--z-line-strong);
  background: var(--z-surface);
  transition: background-color var(--z-motion-base) var(--z-ease-out), border-color var(--z-motion-base) var(--z-ease-out);
}

.dropzone.drag-over,
.dropzone.dragover {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
}

.dropzone input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.source-loaded .source-method-switcher,
.source-loaded [data-source-panel] {
  display: none !important;
}

.source-ready {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 12px;
  align-items: center;
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.source-ready strong,
.source-ready span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.source-ready span {
  color: var(--z-muted-strong);
  font-size: 13px;
}

.source-ready .small-button {
  grid-column: 2;
  grid-row: 1 / span 2;
}

.source-files-list ol {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  padding-left: 24px;
}

.source-files-list li {
  min-width: 0;
  padding-left: 4px;
}

.source-files-list li span,
.source-files-list li small {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.source-files-list li small {
  color: var(--z-muted);
  font-size: 12px;
}

.generation-scope {
  align-items: center;
  gap: 6px 8px;
}

.generation-scope strong {
  margin-right: 2px;
  color: var(--z-muted-strong);
  font-size: 13px;
}

.generation-scope span {
  min-height: 30px;
  border: 0;
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.generation-loader {
  position: relative;
  overflow: hidden;
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
  animation: z-state-enter var(--z-motion-slow) var(--z-ease-out) both;
}

.generation-loader::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.55), transparent);
  content: "";
  transform: translateX(-100%);
  animation: z-loading-sweep 1.8s linear infinite;
  pointer-events: none;
}

.trainer-options button.is-muted {
  opacity: 0.58;
}

.trainer-options button.is-correct {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.trainer-options button.is-wrong {
  border-color: #efc4bf;
  background: var(--z-danger-soft);
  color: var(--z-danger);
}

.loader-row,
.loader-bar {
  position: relative;
  z-index: 1;
}

.status-line {
  display: flex;
  min-height: 36px;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: var(--z-radius-sm);
  color: var(--z-muted-strong);
  font-size: 13px;
}

.status-line::before {
  width: 18px;
  flex: 0 0 18px;
  color: currentColor;
  content: "i";
  font-weight: 750;
  text-align: center;
}

.status-line.success {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
  color: var(--z-success);
}

.status-line.success::before {
  content: "✓";
}

.status-line.warning {
  border-color: #e6c58e;
  background: var(--z-warning-soft);
  color: #754200;
}

.status-line.warning::before,
.status-line.error::before {
  content: "!";
}

.status-line.error {
  border-color: #efc4bf;
  background: var(--z-danger-soft);
  color: var(--z-danger);
}

.flow-meter > span,
.practice-progress-track > span {
  width: 100%;
  transform: scaleX(var(--progress, 0));
  transform-origin: left center;
  transition: transform var(--z-motion-slow) var(--z-ease-out);
}

.flow-step.done,
.flow-step.current {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.flow-step.done > span,
.flow-step.current > span {
  background: var(--z-primary);
  color: #fff;
}

.flow-step.done > span::after {
  content: "✓";
}

.flow-step.done > span {
  color: transparent;
}

.flow-step.done > span::after {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
}

.flow-step > span {
  position: relative;
}

.result-panel[data-result-state="partial"] .panel-heading {
  padding: 10px;
  border: 1px solid #e6c58e;
  border-radius: var(--z-radius-md);
  background: var(--z-warning-soft);
}

.result-arrived .result-content:not(.hidden) {
  animation: z-state-enter var(--z-motion-slow) var(--z-ease-out) both;
}

.summary-lead {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--z-muted-strong);
}

.bullet-list {
  gap: 10px;
  padding-left: 22px;
  list-style: disc;
}

.bullet-list li {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  line-height: 1.55;
}

.bullet-list li::marker {
  color: var(--z-primary);
}

.preview-card::before {
  display: none;
}

.item-badge {
  border-radius: var(--z-radius-sm);
}

.term-title {
  color: var(--z-primary-hover);
}

.tabs button {
  min-height: 44px;
}

.empty-state,
.study-empty {
  min-height: 190px;
  background: var(--z-surface);
}

.practice-launch-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.practice-launch-card {
  min-height: 170px;
}

.practice-launch-card.recommended {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 20px;
  min-height: 0;
  align-items: center;
}

.practice-launch-card.recommended .practice-launch-label,
.practice-launch-card.recommended strong,
.practice-launch-card.recommended p {
  grid-column: 1;
}

.practice-launch-card.recommended .primary-button {
  grid-column: 2;
  grid-row: 1 / span 3;
  min-width: 180px;
}

.practice-option-button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.practice-option-button > small {
  color: inherit;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.practice-option-button.wrong,
.practice-option-button.incorrect {
  border-color: #efc4bf;
  background: var(--z-danger-soft);
  color: var(--z-danger);
}

.flip-card-inner {
  transition: transform var(--z-motion-slow) var(--z-ease-out);
}

.flip-card-face {
  border: 1px solid var(--z-primary);
  background: var(--z-surface);
  box-shadow: none;
}

.flip-card-back {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.flip-study-card:hover .flip-card-face {
  box-shadow: none;
}

.flip-card-title {
  font-weight: 720;
}

.library-card-top,
.modal-actions,
.manual-first-card {
  display: grid;
  gap: 10px;
}

.library-card-top {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
}

.modal-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.manual-first-card {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@keyframes z-state-enter {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes z-loading-sweep {
  to {
    transform: translateX(100%);
  }
}

@keyframes mic-pulse {
  0%,
  100% {
    opacity: 0.55;
    transform: scaleY(0.65);
  }
  50% {
    opacity: 1;
    transform: scaleY(1.8);
  }
}

@media (max-width: 780px) {
  .site-header {
    position: sticky;
    grid-template-columns: minmax(0, 1fr) auto;
    min-height: 62px;
    padding: 10px 14px;
  }

  .site-header > .header-cta {
    display: none;
  }

  .nav-menu-button {
    display: grid;
    width: 44px;
    height: 44px;
    place-content: center;
    gap: 4px;
    padding: 0;
    border: 1px solid var(--z-line);
    border-radius: var(--z-radius-md);
    background: var(--z-surface);
  }

  .nav-menu-button span {
    display: block;
    width: 18px;
    height: 2px;
    border-radius: 1px;
    background: var(--z-ink);
    transition: transform var(--z-motion-base) var(--z-ease-out), opacity var(--z-motion-fast) linear;
  }

  .nav-open .nav-menu-button span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
  }

  .nav-open .nav-menu-button span:nth-child(2) {
    opacity: 0;
  }

  .nav-open .nav-menu-button span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
  }

  .site-header .nav-links {
    grid-column: 1 / -1;
    display: none;
    grid-template-columns: 1fr;
    gap: 0;
    padding: 8px 0 4px;
    border-top: 1px solid var(--z-line);
  }

  .site-header.nav-open .nav-links {
    display: grid;
    animation: z-state-enter var(--z-motion-base) var(--z-ease-out) both;
  }

  .site-header .nav-links a {
    min-height: 46px;
    justify-content: flex-start;
    padding: 0 10px;
    border: 0;
    border-bottom: 1px solid var(--z-line);
    border-radius: 0;
    background: transparent;
    font-size: 15px;
  }

  .site-header .nav-links a[aria-current="page"] {
    background: var(--z-primary-soft);
  }

  .site-header .nav-links .mobile-nav-cta {
    display: inline-flex;
    justify-content: center;
    margin-top: 8px;
    border: 1px solid var(--z-primary);
    border-radius: var(--z-radius-md);
    background: var(--z-primary);
    color: #fff;
  }

  .landing-copy {
    padding-left: 16px;
  }

  .hero-trainer-card .trainer-options,
  .hero-trainer-card .trainer-feedback,
  .hero-trainer-card .trainer-answer-button,
  .hero-trainer-card .trainer-mini-pack {
    display: grid;
  }

  .feature-matrix {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .feature-matrix article:nth-last-child(-n + 2) {
    border-bottom: 0;
  }

  .feature-matrix article:last-child {
    border-bottom: 1px solid var(--z-line);
  }

  .preview-window {
    grid-template-columns: 1fr;
  }

  .preview-sidebar {
    display: none;
  }

  .preview-main {
    padding: 16px;
  }

  .signature-section {
    width: 100%;
    padding-inline: 14px;
  }

  .app-main-column > .app-flow-panel {
    order: 2;
  }

  .app-console {
    align-items: stretch;
  }

  .side-card,
  .tool-panel,
  .flow-panel,
  .workspace,
  .result-panel,
  .study-panel {
    width: 100%;
  }

  .import-panel {
    order: 1;
  }

  .app-flow-panel {
    order: 2;
  }

  .today-card {
    order: 3;
  }

  .workspace {
    order: 4;
  }

  .quick-actions {
    order: 5;
  }

  .usage-card {
    order: 6;
  }

  .library-panel {
    order: 7;
  }

  .source-method-switcher {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: visible;
  }

  .source-method-tab {
    min-width: 0;
  }

  .source-ready {
    grid-template-columns: 1fr;
  }

  .source-ready .small-button {
    grid-column: 1;
    grid-row: auto;
    width: 100%;
  }

  .flow-steps {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .flow-step {
    display: grid;
    grid-template-columns: 1fr;
    gap: 5px;
    min-height: 70px;
    justify-items: center;
    padding: 8px 4px;
    text-align: center;
  }

  .flow-step > span {
    grid-row: auto;
  }

  .flow-step strong {
    font-size: 11px;
    white-space: normal;
  }

  .flow-step small {
    display: none;
  }

  .practice-launch-grid {
    grid-template-columns: 1fr;
  }

  .practice-launch-card.recommended {
    grid-column: auto;
    grid-template-columns: 1fr;
  }

  .practice-launch-card.recommended .primary-button {
    grid-column: 1;
    grid-row: auto;
    min-width: 0;
  }

  .practice-option-button {
    grid-template-columns: 1fr;
  }

  .practice-option-button > small {
    white-space: normal;
  }

  .flashcard-practice-frame {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .flip-study-card {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .card-nav-button {
    width: 100%;
    height: 48px;
  }

  .card-nav-button:first-child {
    grid-column: 1;
    grid-row: 2;
  }

  .card-nav-button:last-child {
    grid-column: 2;
    grid-row: 2;
  }

  .manual-first-card,
  .modal-actions {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .brand-mark {
    min-width: 102px;
    padding-inline: 14px;
  }

  .landing-copy h1 {
    font-size: 46px;
  }

  .legal-hero h1 {
    font-size: 34px;
    overflow-wrap: normal;
    hyphens: auto;
  }

  .landing-actions {
    grid-template-columns: 1fr;
  }

  .trainer-top {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .trainer-question h2 {
    font-size: 22px;
  }

  .today-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .today-metrics div {
    padding: 8px;
  }

  .today-metrics span {
    white-space: normal;
  }

  .generation-scope strong {
    width: 100%;
  }

  .practice-topbar {
    gap: 6px;
  }

  .practice-progress-card {
    min-width: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .generation-loader,
  .result-arrived .result-content:not(.hidden),
  .site-header.nav-open .nav-links {
    animation: none;
  }

  .generation-loader::after {
    display: none;
  }

  .flow-meter > span,
  .practice-progress-track > span,
  .nav-menu-button span,
  .flip-card-inner {
    transition: none;
  }

  .flip-card-inner,
  .flip-study-card.flipped .flip-card-inner,
  .flip-card-back {
    transform: none !important;
  }

  .flip-card-back {
    display: none;
  }

  .flip-study-card.flipped .flip-card-front {
    display: none;
  }

  .flip-study-card.flipped .flip-card-back {
    display: flex;
  }
}

/* Late conflict guards: keep the marketing composition independent of legacy rules. */
.marketing-page .landing-copy h1 {
  max-width: 690px;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}

.marketing-page .pack-results strong {
  color: var(--z-ink);
}

.marketing-page .pack-results small {
  color: var(--z-muted);
}

.marketing-page .source-fragment.video-fragment.is-current {
  background: #17352a;
  color: #fff;
}

.marketing-page .source-fragment.video-fragment.is-current > span {
  color: #d8eee3;
}

@media (min-width: 901px) {
  .marketing-page .landing-hero {
    grid-template-columns: minmax(480px, 0.9fr) minmax(600px, 1.1fr);
  }

  .marketing-page .landing-copy h1 {
    font-size: clamp(52px, 5.1vw, 72px);
  }
}

@media (max-width: 620px) {
  .marketing-page .landing-copy {
    min-width: 0;
    padding-left: 16px;
  }

  .marketing-page .landing-copy h1 {
    font-size: 37px;
  }

  .marketing-page .landing-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .marketing-page .landing-actions .link-button {
    width: 100%;
  }

  .marketing-page .source-fragment:nth-child(n + 3) {
    display: block;
  }
}

/* Target hero fidelity pass: matches the selected editorial composition. */
.marketing-page .marketing-header {
  min-height: 88px;
  padding-inline: max(80px, calc((100vw - 1345px) / 2));
  border-bottom-color: #c9d8cf;
  background: #f7faf7;
}

.marketing-page .marketing-header .brand-mark {
  min-width: 0;
  height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: var(--z-primary);
  font-family: var(--z-display-font);
  font-size: 38px;
  font-weight: 520;
  line-height: 1;
}

.marketing-page .marketing-header .nav-links {
  gap: clamp(46px, 5vw, 76px);
}

.marketing-page .marketing-header .nav-links a {
  color: #26352d;
  font-size: 16px;
  font-weight: 500;
}

.marketing-page .marketing-header .nav-links a[aria-current="page"]::after {
  display: none;
}

.marketing-page .marketing-header .header-cta {
  min-width: 220px;
  min-height: 46px;
  font-size: 15px;
  font-weight: 500;
}

.marketing-page .landing-hero {
  grid-template-columns: minmax(540px, 0.82fr) minmax(680px, 1.18fr);
  gap: 18px;
  align-items: start;
  min-height: 660px;
  width: min(calc(100% - 160px), 1345px);
  max-width: 1345px;
  padding: 94px 0 28px;
}

.marketing-page .landing-copy {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 22px;
  align-content: start;
  max-width: 580px;
  padding: 0;
}

.marketing-page .landing-copy::before {
  display: none;
}

.marketing-page .landing-copy h1,
.marketing-page .landing-copy .hero-lead {
  grid-column: 1 / -1;
}

.marketing-page .landing-copy h1 {
  max-width: 580px;
  font-size: 59px;
  font-weight: 500;
  line-height: 1.06;
  letter-spacing: -0.03em;
}

.marketing-page .hero-lead {
  max-width: 440px;
  margin-top: 52px;
  color: #38483f;
  font-size: 17px;
  line-height: 1.65;
}

.marketing-page .landing-actions {
  grid-column: 1;
  margin-top: 26px;
}

.marketing-page .landing-actions .primary-button {
  min-width: 268px;
  min-height: 58px;
  font-size: 17px;
  font-weight: 500;
}

.hero-trust-note {
  grid-column: 2;
  display: flex;
  gap: 10px;
  align-items: center;
  align-self: end;
  margin-top: 26px;
  color: #46574e;
}

.hero-trust-note > span {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  place-items: center;
  border: 1px solid var(--z-primary);
  border-radius: 50%;
  color: var(--z-primary);
  font-size: 15px;
  font-weight: 700;
}

.hero-trust-note p {
  margin: 0;
  color: inherit;
  font-size: 12px;
  line-height: 1.35;
}

.marketing-page .marker-underline::after {
  right: -0.08em;
  bottom: -0.06em;
  left: -0.08em;
  height: 0.1em;
}

.target-assembly-visual {
  position: relative;
  width: 100%;
  height: 600px;
  margin: -77px 0 0;
  overflow: hidden;
}

.target-assembly-visual img {
  position: absolute;
  top: -105px;
  left: -640px;
  width: 1504px;
  max-width: none;
  height: auto;
}

.marketing-page .product-story {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 42px;
  align-items: start;
  width: 100%;
  max-width: none;
  padding: 58px max(80px, calc((100vw - 1345px) / 2)) 42px;
  border-top: 1px solid #c9d8cf;
}

.marketing-page .product-story .section-heading h2 {
  max-width: 340px;
  font-size: 31px;
  font-weight: 500;
  line-height: 1.18;
}

.marketing-page .product-story .section-heading {
  padding-top: 13px;
}

.marketing-page .product-story .section-heading::after {
  display: block;
  width: 56px;
  height: 2px;
  margin-top: 24px;
  background: var(--z-primary);
  content: "";
}

.marketing-page .product-story-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 34px;
  margin: 6px 0 0;
  border: 0;
}

.marketing-page .product-story-grid::before {
  position: absolute;
  z-index: 0;
  top: 22px;
  right: 4%;
  left: 4%;
  border-top: 1px dashed var(--z-primary);
  content: "";
}

.marketing-page .product-story-grid article {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  align-items: start;
  justify-items: start;
  padding: 0;
  border: 0;
  background: transparent;
}

.marketing-page .product-story-grid .feature-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  margin: 0 0 18px;
  border: 1px solid var(--z-primary-line);
  border-radius: 50%;
  background: #f7faf7;
  color: var(--z-ink);
  font-family: var(--z-display-font);
  font-size: 20px;
  font-weight: 500;
}

.marketing-page .product-story-grid article > img {
  width: 34px;
  height: 34px;
  margin: 0 0 12px;
  filter: invert(35%) sepia(30%) saturate(1149%) hue-rotate(109deg) brightness(91%) contrast(93%);
}

.marketing-page .product-story-grid article h3 {
  margin: 0;
  font-family: "Segoe UI Variable Text", "Segoe UI", Arial, sans-serif;
  font-size: 15px;
  font-weight: 650;
}

.marketing-page .product-story-grid article p {
  margin: 7px 0 0;
  color: var(--z-muted-strong);
  font-size: 11px;
  line-height: 1.45;
}

@media (max-width: 1180px) {
  .marketing-page .landing-hero {
    grid-template-columns: minmax(440px, 0.8fr) minmax(560px, 1.2fr);
  }

  .target-assembly-visual {
    height: 520px;
  }

  .target-assembly-visual img {
    top: -88px;
    left: -548px;
    width: 1268px;
  }
}

@media (max-width: 900px) {
  .marketing-page .marketing-header {
    min-height: 64px;
    padding-inline: 18px;
  }

  .marketing-page .marketing-header .brand-mark {
    font-size: 27px;
  }

  .marketing-page .marketing-header .nav-links {
    gap: 0;
  }

  .marketing-page .marketing-header .nav-links .mobile-nav-cta {
    color: #fff;
    font-weight: 650;
  }

  .marketing-page .landing-hero {
    grid-template-columns: 1fr;
    width: min(calc(100% - 36px), 680px);
    min-height: 0;
    padding: 48px 0 36px;
  }

  .marketing-page .landing-copy {
    max-width: 620px;
  }

  .marketing-page .landing-copy h1 {
    max-width: 620px;
    font-size: 50px;
  }

  .target-assembly-visual {
    width: 100%;
    height: 470px;
    margin-top: 14px;
  }

  .target-assembly-visual img {
    top: -82px;
    left: -510px;
    width: 1180px;
  }

  .marketing-page .product-story {
    grid-template-columns: 1fr;
    gap: 36px;
    padding-inline: 24px;
  }
}

@media (max-width: 620px) {
  .hero-line-break {
    display: none;
  }

  .hero-copy-break {
    display: none;
  }

  .marketing-page .landing-copy {
    grid-template-columns: 1fr;
    width: 100%;
    max-width: 100%;
    padding: 0;
  }

  .marketing-page .landing-copy h1 {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    font-size: 36px;
    line-height: 1.03;
  }

  .marketing-page .hero-lead {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin-top: 24px;
    font-size: 16px;
    line-height: 1.58;
  }

  .marketing-page .landing-actions,
  .hero-trust-note {
    grid-column: 1;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .marketing-page .landing-actions .primary-button {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    white-space: normal;
  }

  .hero-trust-note {
    margin-top: 16px;
  }

  .target-assembly-visual {
    height: 282px;
    margin-top: 18px;
  }

  .target-assembly-visual img {
    top: -46px;
    left: -286px;
    width: 660px;
  }

  .marketing-page .product-story {
    padding-block: 46px 36px;
  }

  .marketing-page .product-story-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 22px;
  }

  .marketing-page .product-story-grid::before {
    display: none;
  }
}

/* 2026-06-21: responsive marketing composition and compact shared chrome. */
.site-header,
.marketing-page .marketing-header,
.app-page .site-header {
  top: 10px;
  width: min(calc(100% - 32px), 1240px);
  max-width: 1240px;
  min-height: 64px;
  margin: 10px auto 0;
  padding: 8px 18px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: rgba(255, 255, 255, 0.98);
}

.marketing-page .marketing-header .brand-mark {
  font-size: 32px;
}

.marketing-page .marketing-header .nav-links {
  gap: clamp(24px, 3vw, 46px);
}

.marketing-page .marketing-header .header-cta {
  min-width: 190px;
  min-height: 44px;
}

.marketing-page .landing-hero {
  grid-template-columns: minmax(420px, 0.82fr) minmax(0, 1.18fr);
  gap: clamp(28px, 3.5vw, 52px);
  align-items: center;
  width: min(calc(100% - 48px), 1240px);
  max-width: 1240px;
  min-height: 0;
  padding: 46px 0 42px;
}

.marketing-page .landing-copy {
  max-width: 530px;
}

.marketing-page .landing-copy h1 {
  max-width: 530px;
  font-size: clamp(48px, 4.25vw, 58px);
  line-height: 1.04;
  letter-spacing: 0;
}

.marketing-page .hero-lead {
  max-width: 475px;
  margin-top: 34px;
}

.marketing-page .hero-lead > span {
  display: block;
  margin-top: 10px;
  color: var(--z-ink);
  font-weight: 650;
}

.target-assembly-visual {
  position: relative;
  width: 100%;
  height: auto;
  min-width: 0;
  margin: 0;
  overflow: visible;
}

.target-assembly-visual img {
  position: static;
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.preview-copy > .primary-button {
  margin-top: 30px;
}

.preview-brand-row {
  gap: 0;
}

.preview-brand-row .preview-logo {
  display: inline-flex;
  width: auto;
  min-width: 0;
  height: auto;
  flex: 0 1 auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: var(--z-primary);
  font-family: var(--z-display-font);
  font-size: 21px;
  font-weight: 560;
  line-height: 1.1;
}

.home-billing-switch {
  width: 100%;
  max-width: none;
  margin: 28px 0 20px;
}

.home-billing-switch h3 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
}

.home-pricing-grid .plan-price h3 {
  display: grid;
  gap: 6px;
}

.home-pricing-grid .pricing-card {
  min-height: 490px;
}

.app-console {
  grid-template-columns: 320px minmax(0, 1fr);
}

.library-card {
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  overflow-wrap: normal;
  word-break: normal;
}

.library-card-main,
.library-card-top,
.library-card h3,
.library-card p,
.library-card small,
.library-status {
  min-width: 0;
  overflow-wrap: break-word;
  word-break: normal;
  hyphens: auto;
}

.library-card h3 {
  display: -webkit-box;
  overflow: hidden;
  white-space: normal;
  text-overflow: ellipsis;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.library-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 44px;
  gap: 8px;
  width: 100%;
}

.library-actions .small-button,
.library-actions .icon-danger-button {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding-inline: 8px;
  white-space: normal;
}

.library-actions .icon-danger-button {
  height: 44px;
}

@media (max-width: 1180px) {
  .marketing-page .landing-hero {
    grid-template-columns: minmax(390px, 0.82fr) minmax(0, 1.18fr);
  }

  .marketing-page .landing-copy h1 {
    font-size: 48px;
  }

  .pricing-grid-four,
  .home-pricing-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .site-header,
  .marketing-page .marketing-header,
  .app-page .site-header {
    top: 8px;
    width: min(calc(100% - 20px), 760px);
    margin-top: 8px;
    padding-inline: 14px;
  }

  .marketing-page .landing-hero {
    grid-template-columns: 1fr;
    width: min(calc(100% - 36px), 700px);
    padding: 44px 0 36px;
  }

  .marketing-page .landing-copy,
  .marketing-page .landing-copy h1 {
    max-width: 640px;
  }

  .target-assembly-visual {
    width: min(100%, 720px);
    margin: 18px auto 0;
  }

  .app-console {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .marketing-page .landing-hero {
    gap: 12px;
    padding-bottom: 24px;
  }

  .marketing-page .landing-copy h1 {
    font-size: 38px;
  }

  .marketing-page .hero-lead {
    margin-top: 24px;
  }

  .target-assembly-visual {
    height: auto;
    margin-top: 0;
  }

  .billing-switch-panel,
  .home-billing-switch {
    align-items: stretch;
  }

  .billing-toggle {
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pricing-grid-four,
  .home-pricing-grid {
    grid-template-columns: 1fr;
  }
}

/* 2026-06-21: final hero-detail and shared-header pass. */
.site-header.marketing-header .brand-mark {
  min-width: 0;
  height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: var(--z-primary);
  font-family: var(--z-display-font);
  font-size: 32px;
  font-weight: 520;
  line-height: 1;
}

.site-header.marketing-header .nav-links {
  gap: clamp(24px, 3vw, 46px);
}

.site-header.marketing-header .nav-links a {
  color: #26352d;
  font-size: 16px;
  font-weight: 500;
}

.site-header.marketing-header .nav-links a[aria-current="page"]::after {
  display: none;
}

.site-header.marketing-header .header-cta {
  min-width: 190px;
  min-height: 44px;
  font-size: 15px;
  font-weight: 500;
}

.marketing-page .landing-copy {
  display: block;
}

.marketing-page .landing-copy::before,
.marketing-page .landing-copy::after {
  display: none;
  content: none;
}

.marketing-page .marker-underline::after {
  right: -0.1em;
  bottom: -0.12em;
  left: -0.1em;
  height: 0.24em;
  border-radius: 0;
  background: url("/assets/marker-underline.svg") center / 100% 100% no-repeat;
}

.marketing-page .landing-actions {
  margin-top: 28px;
}

.preview-action-link:hover {
  border-color: var(--z-primary-hover);
  background: var(--z-primary-hover);
}

@media (max-width: 900px) {
  .site-header.marketing-header .brand-mark {
    font-size: 27px;
  }

  .site-header.marketing-header .nav-links {
    gap: 0;
  }
}

/* 2026-07-01: focused flashcard practice, inspired by physical study cards. */
.practice-overlay {
  background: var(--z-canvas);
}

.practice-shell {
  min-height: 100dvh;
  padding: 0 0 40px;
  border: 0;
  border-radius: 0;
  background: var(--z-canvas);
  box-shadow: none;
}

.practice-topbar {
  top: 0;
  grid-template-columns: 44px minmax(280px, 680px) 44px;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--z-line);
  background: rgba(255, 255, 255, 0.96);
}

.practice-icon-button {
  width: 44px;
  height: 44px;
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
}

.practice-icon-button::before {
  font-size: 24px;
}

.practice-progress-card {
  grid-template-columns: auto minmax(120px, 1fr) auto;
  min-height: 44px;
  gap: 12px;
  padding: 5px 10px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.practice-mode-pill,
.practice-xp {
  min-height: 32px;
  padding: 0 6px;
  border-radius: 0;
  background: transparent;
  color: var(--z-muted-strong);
  font-size: 14px;
  font-weight: 650;
}

.practice-progress-track {
  height: 5px;
  border-radius: 3px;
  background: var(--z-line);
}

.practice-stage {
  align-content: start;
  padding: clamp(24px, 4vh, 44px) 16px 28px;
}

.practice-card {
  width: min(100%, 820px);
  gap: 12px;
}

.flashcard-practice-frame {
  grid-template-columns: 48px minmax(0, 640px) 48px;
  justify-content: center;
  gap: 14px;
}

.flashcard-card-stack {
  position: relative;
  width: 100%;
  min-width: 0;
  height: clamp(440px, 66vh, 600px);
}

.flip-study-card,
.flip-card-inner {
  width: 100%;
  height: 100%;
  min-height: 0;
}

.flip-study-card {
  border-radius: var(--z-radius-lg);
  perspective: 1400px;
}

.flip-study-card:focus-visible {
  outline: 0;
  box-shadow: var(--z-focus);
}

.flip-card-inner {
  transition: transform 420ms var(--z-ease-out);
}

.flip-card-face {
  justify-content: stretch;
  gap: 0;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--z-line-strong);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
}

.flip-card-back {
  border-color: var(--z-primary-line);
  background: var(--z-surface);
}

.flip-card-header {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 28px 0;
}

.flip-card-side-label {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--z-primary);
  border-radius: var(--z-radius-sm);
  color: var(--z-primary-hover);
  font-size: 14px;
  font-weight: 700;
}

.flip-card-back .flip-card-side-label {
  background: var(--z-primary);
  color: #fff;
}

.flip-card-position {
  color: var(--z-muted);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}

.flip-card-scroll {
  display: flex;
  min-height: 0;
  flex: 1 1 auto;
  flex-direction: column;
  justify-content: flex-start;
  gap: 18px;
  overflow: auto;
  padding: clamp(30px, 6vh, 60px) 28px 28px;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.flip-card-back .flip-card-scroll {
  padding-top: 24px;
  padding-bottom: 86px;
}

.flip-card-title {
  color: var(--z-ink);
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 720;
  line-height: 1.28;
  text-wrap: pretty;
}

.flip-card-title.text-density-md {
  font-size: clamp(22px, 2.6vw, 30px);
}

.flip-card-title.text-density-sm {
  font-size: clamp(19px, 2.2vw, 25px);
  line-height: 1.34;
}

.flip-card-title.text-density-xs {
  font-size: clamp(17px, 1.9vw, 21px);
  line-height: 1.42;
}

.flip-card-explanation {
  max-width: 68ch;
  color: var(--z-muted-strong);
  font-size: 16px;
  line-height: 1.55;
  text-wrap: pretty;
}

.flip-card-reveal-bar {
  display: flex;
  min-height: 52px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--z-primary);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
}

.flip-card-back > .flip-card-hint {
  display: none;
}

.flashcard-actions {
  position: absolute;
  right: 12px;
  bottom: 12px;
  left: 12px;
  z-index: 2;
  visibility: hidden;
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity var(--z-motion-base) var(--z-ease-out),
    transform var(--z-motion-base) var(--z-ease-out),
    visibility 0s linear var(--z-motion-base);
}

.flashcard-actions.is-visible {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
  transition-delay: 100ms, 100ms, 0s;
}

.flashcard-rating {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
}

.flashcard-rating-button {
  display: flex;
  min-width: 0;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-sm);
  background: var(--z-surface);
  color: var(--z-ink);
  font-size: 14px;
  font-weight: 700;
  transition:
    border-color var(--z-motion-fast) ease,
    background-color var(--z-motion-fast) ease,
    transform var(--z-motion-fast) ease;
}

.flashcard-rating-button:hover {
  transform: translateY(-1px);
}

.flashcard-rating-button.rating-unknown:hover,
.flashcard-rating-button.rating-unknown:focus-visible {
  border-color: #efc4bf;
  background: var(--z-danger-soft);
  color: var(--z-danger);
}

.flashcard-rating-button.rating-almost:hover,
.flashcard-rating-button.rating-almost:focus-visible {
  border-color: #e6c58e;
  background: var(--z-warning-soft);
  color: #754200;
}

.flashcard-rating-button.rating-known:hover,
.flashcard-rating-button.rating-known:focus-visible {
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.flashcard-rating-button kbd {
  display: inline-grid;
  min-width: 22px;
  height: 22px;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 4px;
  background: transparent;
  font: inherit;
  font-size: 12px;
  opacity: 0.7;
}

.card-nav-button {
  width: 48px;
  height: 48px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface);
  box-shadow: none;
  color: var(--z-primary-hover);
  font-size: 30px;
  transition:
    border-color var(--z-motion-fast) ease,
    background-color var(--z-motion-fast) ease,
    color var(--z-motion-fast) ease;
}

.card-nav-button:hover:not(:disabled) {
  transform: none;
  border-color: var(--z-primary-line);
  background: var(--z-primary-soft);
}

.card-nav-button:disabled {
  color: var(--z-muted);
  opacity: 0.32;
}

.practice-source-row {
  width: min(100%, 640px);
  justify-self: center;
}

@media (max-width: 780px) {
  .flashcard-practice-frame {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .flashcard-card-stack {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .flip-study-card {
    grid-column: auto;
    grid-row: auto;
  }

  .card-nav-button {
    width: 100%;
    height: 44px;
  }

  .card-nav-button:first-child {
    grid-column: 1;
    grid-row: 2;
  }

  .card-nav-button:last-child {
    grid-column: 2;
    grid-row: 2;
  }
}

@media (max-width: 620px) {
  .practice-shell {
    padding-bottom: 20px;
  }

  .practice-topbar {
    grid-template-columns: 44px minmax(0, 1fr) 44px;
    gap: 6px;
    padding: 8px;
  }

  .practice-progress-card {
    grid-template-columns: auto minmax(48px, 1fr);
    gap: 8px;
    padding-inline: 4px;
  }

  .practice-xp {
    display: none;
  }

  .practice-mode-pill {
    min-width: 0;
    padding: 0;
    overflow: hidden;
    font-size: 13px;
    text-overflow: ellipsis;
  }

  .practice-stage {
    padding: 16px 12px 24px;
  }

  .flashcard-card-stack {
    height: clamp(390px, calc(100dvh - 250px), 520px);
  }

  .flip-card-header {
    padding: 20px 20px 0;
  }

  .flip-card-scroll {
    padding: 26px 20px 22px;
  }

  .flip-card-back .flip-card-scroll {
    padding: 18px 20px 82px;
  }

  .flip-card-title,
  .flip-card-title.text-density-md {
    font-size: 23px;
    line-height: 1.32;
  }

  .flip-card-title.text-density-sm {
    font-size: 19px;
  }

  .flip-card-title.text-density-xs {
    font-size: 16px;
  }

  .flip-card-explanation {
    font-size: 15px;
  }

  .flashcard-actions {
    right: 8px;
    bottom: 8px;
    left: 8px;
  }

  .flashcard-rating {
    gap: 5px;
    padding: 6px;
  }

  .flashcard-rating-button {
    min-height: 44px;
    gap: 4px;
    padding: 6px 4px;
    font-size: 12px;
  }

  .flashcard-rating-button kbd {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .flip-card-inner,
  .flip-study-card.flipped .flip-card-inner,
  .flip-card-back {
    transform: none !important;
  }

  .flip-card-back {
    display: none;
  }

  .flip-study-card.flipped .flip-card-front {
    display: none;
  }

  .flip-study-card.flipped .flip-card-back {
    display: flex;
  }

  .flashcard-actions,
  .flashcard-actions.is-visible {
    transform: none;
    transition: none;
  }
}

/* Final guards for the scored-practice follow-up. */
.practice-topbar {
  grid-template-columns: 44px minmax(280px, 760px) auto;
}

.practice-toolbar {
  display: flex;
  align-items: center;
  gap: 6px;
}

.practice-card {
  width: min(100%, 900px);
}

.flashcard-practice-frame {
  grid-template-columns: 48px minmax(0, 720px) 48px;
}

.practice-source-row {
  width: min(100%, 720px);
}

.card-nav-button {
  font-size: 0;
  line-height: 0;
}

.card-nav-button:hover:not(:disabled) {
  border-color: var(--z-primary);
  background: var(--z-primary);
  color: #fff;
}

@media (max-width: 780px) {
  .flashcard-practice-frame {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .flashcard-card-stack {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .card-nav-button:first-child {
    grid-column: 1;
    grid-row: 2;
  }

  .card-nav-button:last-child {
    grid-column: 2;
    grid-row: 2;
  }
}

@media (max-width: 620px) {
  .practice-topbar {
    grid-template-columns: 44px minmax(0, 1fr) auto;
  }

  .practice-toolbar {
    gap: 4px;
  }

  .practice-toolbar .practice-icon-button {
    width: 40px;
  }
}

/* First-run focus, transparent generation, and local-profile prototype. */
.profile-button {
  display: inline-flex;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 5px 10px 5px 5px;
  border: 1px solid var(--z-line-strong);
  border-radius: 999px;
  background: var(--z-surface);
  color: var(--z-ink);
  font: 650 14px/1 var(--z-ui-font);
  transition: background-color var(--z-motion-base) var(--z-ease-out), border-color var(--z-motion-base) var(--z-ease-out), color var(--z-motion-base) var(--z-ease-out);
}

.profile-button:hover {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.profile-button:focus-visible,
.onboarding-goal button:focus-visible { outline: 3px solid rgba(11, 122, 83, 0.26); outline-offset: 2px; }

.profile-avatar {
  display: inline-grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 50%;
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
  font-weight: 760;
}

.profile-button.is-signed-in .profile-avatar { background: var(--z-primary); color: #fff; }

.magic-start {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin: 18px 0;
  padding: 15px 16px;
  border: 1px solid var(--z-primary-line);
  border-radius: var(--z-radius-md);
  background: linear-gradient(104deg, var(--z-primary-soft), #fff 68%);
}

.magic-start-mark { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 12px; background: var(--z-primary); color: #fff; font-size: 20px; }
.magic-start strong,
.magic-start p { display: block; min-width: 0; overflow-wrap: anywhere; }
.magic-start strong { font-size: 15px; }
.magic-start p { margin: 4px 0 0; color: var(--z-muted-strong); font-size: 13px; line-height: 1.45; }
.magic-start-time { align-self: start; padding: 5px 8px; border-radius: 999px; background: #fff; color: var(--z-primary-hover); font-size: 12px; font-weight: 720; white-space: nowrap; }

.product-app.is-first-run .app-console { grid-template-columns: minmax(0, 860px); justify-content: center; }
.product-app.is-first-run .app-side-panel { display: none; }
.product-app.is-first-run .workspace { display: none; }
.product-app.is-first-run .import-panel { box-shadow: 0 14px 34px rgba(31, 58, 45, 0.08); }

.loader-proof { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 12px; color: var(--z-muted-strong); font-size: 12px; line-height: 1.4; }
.loader-proof span:first-child { color: var(--z-primary-hover); font-weight: 740; }

.onboarding-modal { position: fixed; z-index: 80; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(21, 35, 28, 0.45); }
.onboarding-modal.hidden { display: none; }

.onboarding-card {
  position: relative;
  display: grid;
  width: min(100%, 500px);
  gap: 16px;
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid var(--z-line-strong);
  border-radius: 16px;
  background: var(--z-surface);
  box-shadow: 0 24px 72px rgba(15, 34, 24, 0.24);
  animation: z-state-enter var(--z-motion-slow) var(--z-ease-out) both;
}

.onboarding-card h2 { max-width: 420px; margin: 0; color: var(--z-ink); font-family: var(--z-display-font); font-size: clamp(27px, 4vw, 38px); letter-spacing: -0.035em; line-height: 1.05; }
.onboarding-card > p:not(.local-profile-note) { margin: -8px 0 0; color: var(--z-muted-strong); line-height: 1.55; }
.onboarding-card label { display: grid; gap: 7px; color: var(--z-ink); font-size: 13px; font-weight: 700; }
.onboarding-card label span small { color: var(--z-muted); font-weight: 500; }
.onboarding-card input { min-width: 0; min-height: 46px; padding: 10px 12px; border: 1px solid var(--z-line-strong); border-radius: var(--z-radius-sm); background: #fff; color: var(--z-ink); font: 15px/1.3 var(--z-ui-font); }

.onboarding-goal { display: grid; gap: 8px; color: var(--z-muted-strong); font-size: 13px; font-weight: 700; }
.onboarding-goal > div { display: flex; flex-wrap: wrap; gap: 8px; }
.onboarding-goal button { min-height: 38px; padding: 7px 11px; border: 1px solid var(--z-line-strong); border-radius: 999px; background: #fff; color: var(--z-muted-strong); font: 650 13px/1 var(--z-ui-font); }
.onboarding-goal button:hover,
.onboarding-goal button.is-selected { border-color: var(--z-primary); background: var(--z-primary-soft); color: var(--z-primary-hover); }

.local-profile-note { margin: -2px 0 0; padding-top: 12px; border-top: 1px solid var(--z-line); color: var(--z-muted); font-size: 12px; line-height: 1.5; }
.onboarding-actions { margin-top: 0; }
.profile-signout { justify-self: start; padding: 0; border: 0; background: transparent; color: var(--z-muted-strong); font: 650 13px/1.3 var(--z-ui-font); text-decoration: underline; text-underline-offset: 3px; }
.profile-signout:hover { color: var(--z-danger); }

@media (max-width: 780px) {
  .profile-button { padding: 5px; }
  .profile-button > span:last-child { display: none; }
  .magic-start { grid-template-columns: auto minmax(0, 1fr); }
  .magic-start-time { grid-column: 2; justify-self: start; }
  .onboarding-modal { padding: 12px; align-items: end; }
  .onboarding-card { max-height: calc(100dvh - 24px); overflow: auto; border-radius: 14px; }
}

@media (prefers-reduced-motion: reduce) { .onboarding-card { animation: none; } }

/* 2026-07-10: one clear next step and a proof-first generation result. */
.app-page .site-header.marketing-header {
  grid-template-columns: auto minmax(360px, 1fr) auto auto;
  column-gap: 18px;
}

.app-page .site-header.marketing-header .nav-links {
  gap: clamp(18px, 2vw, 34px);
}

.app-page .site-header.marketing-header .profile-button,
.app-page .site-header.marketing-header .header-cta {
  white-space: nowrap;
}

.focus-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  min-width: 0;
  padding: clamp(20px, 3vw, 28px);
  border: 1px solid var(--z-primary-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-primary-soft);
}

.focus-copy {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  min-width: 0;
}

.focus-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: var(--z-radius-md);
  background: var(--z-primary);
  color: #fff;
  font-size: 22px;
  font-weight: 760;
}

.focus-panel h2 {
  margin: 3px 0 0;
  color: var(--z-ink);
  font-family: var(--z-display-font);
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.025em;
  line-height: 1.08;
}

.focus-panel p {
  max-width: 700px;
  margin: 8px 0 0;
  color: var(--z-muted-strong);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.focus-action {
  display: grid;
  gap: 8px;
  justify-items: stretch;
  min-width: 190px;
}

.focus-action > span {
  color: var(--z-primary-hover);
  font-size: 13px;
  font-weight: 720;
  text-align: center;
}

.product-app.has-focus .today-actions {
  display: none;
}

.generator-toggle {
  justify-self: end;
}

.import-panel.is-collapsed {
  padding-block: 15px;
  border-color: var(--z-primary-line);
}

.import-panel.is-collapsed .panel-heading {
  margin-bottom: 0;
}

.import-panel.is-collapsed .generator-content {
  display: none;
}

.magic-receipt {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin: 0 0 16px;
  padding: 14px;
  border: 1px solid var(--z-primary-line);
  border-radius: var(--z-radius-md);
  background: var(--z-primary-soft);
}

.magic-receipt-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 50%;
  background: var(--z-primary);
  color: #fff;
  font-size: 20px;
  font-weight: 800;
}

.magic-receipt strong,
.magic-receipt p {
  display: block;
  overflow-wrap: anywhere;
}

.magic-receipt p {
  margin: 4px 0 0;
  color: var(--z-muted-strong);
  font-size: 13px;
  line-height: 1.45;
}

.product-app.is-first-run .import-panel {
  box-shadow: none;
}

@media (max-width: 1100px) {
  .app-page .site-header.marketing-header {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .app-page .site-header.marketing-header .header-cta {
    display: none;
  }
}

@media (max-width: 780px) {
  .app-page .site-header.marketing-header {
    grid-template-columns: auto minmax(0, 1fr) auto;
    column-gap: 10px;
  }

  .app-page .site-header.marketing-header .profile-button {
    justify-self: end;
  }

  .focus-panel,
  .magic-receipt {
    grid-template-columns: 1fr;
  }

  .focus-action {
    min-width: 0;
  }

  .focus-action > span {
    text-align: left;
  }

  .magic-receipt-mark {
    width: 38px;
    height: 38px;
  }
}

@media (max-width: 480px) {
  .focus-copy {
    grid-template-columns: 1fr;
  }

  .import-panel.is-collapsed .panel-heading {
    grid-template-columns: 30px minmax(0, 1fr);
  }

  .import-panel.is-collapsed .generator-toggle {
    grid-column: 1 / -1;
    width: 100%;
  }
}

/* 2026-07-10: application workspace rebuilt from the selected dashboard references. */
.app-page {
  background: #f5f7f6;
}

.app-page .app-product-header {
  position: relative;
  top: auto;
  display: grid;
  grid-template-columns: auto minmax(320px, 620px) auto;
  gap: 28px;
  width: 100%;
  max-width: none;
  min-height: 72px;
  margin: 0;
  padding: 10px max(24px, calc((100vw - 1500px) / 2));
  border: 0;
  border-bottom: 1px solid #e1e6e3;
  border-radius: 0;
  background: #fff;
}

.app-product-header .brand {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  color: var(--z-ink);
}

.app-product-header .brand > i {
  color: var(--z-primary);
  font-size: 26px;
}

.app-product-header .brand-mark {
  min-width: 0;
  height: auto;
  padding: 0;
  background: transparent;
  color: var(--z-ink);
  font-family: var(--z-ui-font);
  font-size: 23px;
  font-weight: 760;
}

.app-global-search {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  min-height: 44px;
  padding: 0 11px;
  border: 1px solid #dfe5e1;
  border-radius: 9px;
  background: #fbfcfb;
  color: var(--z-muted);
}

.app-global-search:focus-within {
  border-color: var(--z-primary);
  box-shadow: 0 0 0 3px rgba(11, 122, 83, 0.12);
}

.app-global-search input {
  min-height: 40px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  box-shadow: none;
}

.app-global-search input:focus {
  border: 0;
  outline: 0;
}

.app-global-search kbd {
  padding: 3px 6px;
  border: 1px solid var(--z-line);
  border-radius: 5px;
  background: #fff;
  color: var(--z-muted);
  font: 650 11px/1 var(--z-ui-font);
}

.app-header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
}

.header-icon-button {
  position: relative;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--z-muted-strong);
  font-size: 20px;
}

.header-icon-button:hover {
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.header-icon-button > span {
  position: absolute;
  top: 7px;
  right: 7px;
  width: 7px;
  height: 7px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #e54b4b;
}

.app-product-header .profile-button {
  border: 0;
  background: transparent;
}

.app-product-header .profile-button:hover {
  background: var(--z-primary-soft);
}

.product-app {
  width: min(calc(100% - 28px), 1580px);
  max-width: 1580px;
  padding: 16px 0 36px;
}

.app-console {
  grid-template-columns: 220px minmax(0, 1fr) 310px;
  grid-template-areas: "nav main side";
  gap: 14px;
}

.workspace-nav {
  grid-area: nav;
  display: flex;
  min-width: 0;
  min-height: calc(100vh - 104px);
  flex-direction: column;
  justify-content: space-between;
  padding: 10px;
  border: 1px solid #e0e6e2;
  border-radius: 12px;
  background: #fff;
}

.workspace-nav nav {
  display: grid;
  gap: 4px;
}

.workspace-nav nav a,
.workspace-nav nav button {
  display: flex;
  width: 100%;
  min-height: 46px;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #495950;
  font: 650 14px/1.3 var(--z-ui-font);
  text-align: left;
}

.workspace-nav nav a:hover,
.workspace-nav nav button:hover,
.workspace-nav nav .is-current {
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.workspace-nav nav i {
  flex: 0 0 20px;
  font-size: 20px;
}

.workspace-nav-footer {
  display: grid;
  gap: 10px;
}

.workspace-create-button {
  display: flex;
  width: 100%;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 12px;
  border: 1px solid var(--z-primary);
  border-radius: 8px;
  background: var(--z-primary);
  color: #fff;
  font: 700 14px/1.2 var(--z-ui-font);
}

.workspace-plan-card {
  display: grid;
  gap: 7px;
  padding: 14px;
  border: 1px solid var(--z-primary-line);
  border-radius: 9px;
  background: var(--z-primary-soft);
}

.workspace-plan-card span {
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 750;
}

.workspace-plan-card strong {
  color: var(--z-ink);
  font-size: 14px;
}

.workspace-plan-card small {
  color: var(--z-muted);
  font-size: 11px;
  line-height: 1.45;
}

.workspace-plan-card a {
  width: fit-content;
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 700;
}

.app-main-column {
  grid-area: main;
  gap: 14px;
}

.app-main-column > .workspace-titlebar { order: 1; }
.app-main-column > .import-panel { order: 2; }
.app-main-column > .focus-panel { order: 3; }
.app-main-column > .workspace { order: 4; }

.app-side-panel {
  grid-area: side;
  gap: 12px;
}

.app-side-panel > .today-card { order: 1; }
.app-side-panel > .library-panel { order: 2; }
.app-side-panel > .usage-card { order: 3; }
.app-side-panel > .quick-actions { order: 4; }

.workspace-titlebar {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  justify-content: space-between;
  min-width: 0;
  padding: 6px 2px 2px;
}

.workspace-titlebar .section-kicker {
  margin-bottom: 6px;
}

.workspace-titlebar h1 {
  margin: 0;
  color: var(--z-ink);
  font-family: var(--z-ui-font);
  font-size: clamp(26px, 2.4vw, 36px);
  font-weight: 760;
  letter-spacing: -0.025em;
  line-height: 1.12;
}

.workspace-titlebar p {
  margin: 7px 0 0;
  color: var(--z-muted);
  font-size: 14px;
}

.workspace-titlebar > a {
  flex: 0 0 auto;
  text-decoration: none;
}

.product-app .side-card,
.product-app .tool-panel,
.product-app .result-panel,
.product-app .study-panel,
.product-app .import-panel {
  border-color: #dfe5e1;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 3px 12px rgba(28, 49, 38, 0.035);
}

.focus-panel {
  gap: 20px;
  padding: 18px 20px;
  border-color: var(--z-primary-line);
  border-radius: 12px;
  background: #eff9f4;
}

.focus-panel h2 {
  font-family: var(--z-ui-font);
  font-size: clamp(21px, 2vw, 28px);
  font-weight: 760;
}

.focus-mark {
  width: 40px;
  height: 40px;
  border-radius: 9px;
}

.focus-action {
  min-width: 170px;
}

.import-panel {
  padding: 20px;
}

.import-panel .panel-heading {
  margin-bottom: 14px;
}

.import-panel .step-badge {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: var(--z-primary-soft);
  font-size: 19px;
}

.import-panel .panel-heading h2 {
  font-size: 22px;
}

.generation-stepper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 18px;
  padding: 14px 0 16px;
  border-block: 1px solid var(--z-line);
  list-style: none;
}

.generation-stepper li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  min-width: 0;
  color: var(--z-muted);
}

.generation-stepper li > span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid var(--z-line-strong);
  border-radius: 50%;
  background: #fff;
  color: var(--z-muted-strong);
  font-size: 12px;
  font-weight: 750;
}

.generation-stepper strong,
.generation-stepper small {
  display: block;
  overflow-wrap: anywhere;
}

.generation-stepper strong {
  color: var(--z-muted-strong);
  font-size: 12px;
}

.generation-stepper small {
  margin-top: 3px;
  font-size: 10px;
  line-height: 1.3;
}

.generation-stepper li.is-current > span {
  border-color: var(--z-primary);
  background: var(--z-primary);
  color: #fff;
}

.generation-stepper li.is-current strong {
  color: var(--z-primary-hover);
}

.source-method-switcher {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
}

.source-method-tab {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid var(--z-line);
  border-radius: 8px;
  background: #fff;
}

.source-method-tab:hover,
.source-method-tab.is-active {
  border-color: var(--z-primary);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.import-grid {
  grid-template-columns: 1fr;
  margin-top: 10px;
}

.dropzone {
  min-height: 180px;
  grid-template-columns: 1fr;
  justify-items: center;
  align-content: center;
  padding: 24px;
  border-color: #8bcfb0;
  background: #fbfefc;
  text-align: center;
}

.dropzone-icon {
  width: 48px;
  height: 48px;
  font-size: 28px;
}

.dropzone strong {
  font-size: 16px;
  overflow-wrap: anywhere;
}

.generation-scope {
  gap: 8px;
  padding: 14px 0 4px;
  border: 0;
  background: transparent;
}

.generation-scope span {
  min-height: 38px;
  padding: 9px 11px;
  border: 1px solid var(--z-primary-line);
  border-radius: 7px;
  background: var(--z-primary-soft);
  overflow-wrap: anywhere;
}

.app-main-column > .workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}

.result-panel,
.study-panel {
  padding: 18px;
}

.result-panel .empty-state,
.study-stage {
  min-height: 240px;
}

.result-panel .tabs {
  gap: 5px;
  padding-bottom: 10px;
  overflow-x: auto;
}

.result-panel .tab-button {
  min-height: 40px;
  padding: 8px 11px;
  border-radius: 7px;
  white-space: nowrap;
}

.product-app .today-card {
  padding: 18px;
  background: #fff;
}

.today-card .side-card-title {
  margin-bottom: 18px;
}

.today-card .side-card-title a,
.library-heading a {
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 700;
}

.today-card .section-kicker {
  margin-bottom: 7px;
}

.today-card h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 23px;
  line-height: 1.15;
}

.today-card > p {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.today-metrics {
  margin-top: 14px;
  border-color: var(--z-line);
}

.today-metrics div {
  padding: 12px 8px;
}

.today-metrics strong {
  font-size: 23px;
}

.today-actions {
  grid-template-columns: 1fr;
}

.app-side-panel .library-panel {
  padding: 18px;
}

.app-side-panel .library-heading {
  align-items: center;
}

.app-side-panel .library-heading h2 {
  font-size: 17px;
}

.app-side-panel .library-list {
  grid-template-columns: 1fr;
  max-height: 470px;
  margin-top: 12px;
  padding-right: 2px;
}

.app-side-panel .library-card {
  gap: 8px;
  padding: 11px;
  border-radius: 8px;
  background: #fff;
}

.app-side-panel .library-card.due {
  border-color: #dfe5e1;
  background: #fff;
}

.app-side-panel .library-card h3 {
  font-size: 14px;
}

.app-side-panel .library-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr)) 36px;
}

.app-side-panel .library-actions .small-button,
.app-side-panel .library-actions .icon-danger-button {
  min-height: 36px;
  height: 36px;
  font-size: 11px;
}

.app-side-panel .usage-card,
.app-side-panel .quick-actions {
  padding: 16px;
}

.app-side-panel .quick-actions {
  margin-top: 0;
}

.product-app.is-first-run .app-console {
  grid-template-columns: 220px minmax(0, 1fr);
  grid-template-areas: "nav main";
  justify-content: stretch;
}

.product-app.is-first-run .workspace-nav {
  display: flex;
}

.product-app.is-first-run .app-side-panel {
  display: none;
}

@media (max-width: 1240px) {
  .app-console {
    grid-template-columns: 210px minmax(0, 1fr);
    grid-template-areas: "nav main";
  }

  .app-side-panel {
    display: none;
  }

  .product-app.is-first-run .app-console {
    grid-template-columns: 210px minmax(0, 1fr);
  }
}

@media (max-width: 900px) {
  .app-page .app-product-header {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 14px;
    width: 100%;
    margin: 0;
  }

  .app-console,
  .product-app.is-first-run .app-console {
    grid-template-columns: 1fr;
    grid-template-areas: "nav" "main";
  }

  .workspace-nav {
    min-height: 0;
    padding: 8px;
  }

  .workspace-nav nav {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .workspace-nav nav a,
  .workspace-nav nav button {
    width: auto;
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .workspace-nav-footer {
    display: none;
  }

  .app-main-column > .workspace {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .app-page .app-product-header {
    grid-template-columns: minmax(0, 1fr) auto;
    min-height: 64px;
    padding: 8px 12px;
  }

  .app-global-search,
  .header-icon-button[aria-label="Помощь"] {
    display: none;
  }

  .app-product-header .brand-mark {
    font-size: 21px;
  }

  .app-product-header .profile-button {
    padding: 5px;
  }

  .app-product-header #profileLabel,
  .app-product-header .profile-button > i:last-child {
    display: none;
  }

  .product-app {
    width: min(calc(100% - 16px), 1580px);
    padding-top: 8px;
  }

  .workspace-nav nav a,
  .workspace-nav nav button {
    min-height: 42px;
    padding: 8px 10px;
  }

  .workspace-nav nav span {
    display: none;
  }

  .workspace-nav nav i {
    font-size: 21px;
  }

  .workspace-titlebar {
    display: grid;
    padding-inline: 4px;
  }

  .workspace-titlebar > a {
    width: 100%;
  }

  .focus-panel {
    grid-template-columns: 1fr;
  }

  .focus-copy {
    grid-template-columns: 40px minmax(0, 1fr);
  }

  .generation-stepper {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .source-method-switcher {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dropzone {
    min-height: 160px;
  }

  .import-panel,
  .result-panel,
  .study-panel {
    padding: 14px;
  }
}

/* 2026-07-10: denser marketing heroes, non-sticky app header, and profile dashboard. */
.import-panel::before {
  display: none;
}

.app-page .site-header {
  position: relative;
  top: auto;
}

.profile-button {
  text-decoration: none;
}

.profile-button > span:last-child {
  max-width: 220px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.marketing-page .split-page-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(390px, 0.72fr);
  gap: clamp(40px, 6vw, 92px);
  align-items: center;
  padding-block: clamp(44px, 5vw, 68px) 48px;
}

.split-page-hero .page-hero-copy {
  min-width: 0;
}

.split-page-hero .page-hero-copy h1 {
  max-width: 840px;
  font-size: clamp(44px, 5vw, 68px);
}

.split-page-hero .page-hero-copy p {
  max-width: 700px;
}

.pricing-hero {
  padding-bottom: 32px;
}

.launch-status-note {
  max-width: 760px;
  margin-top: 18px;
  padding: 12px 14px;
  border: 1px solid color-mix(in srgb, var(--accent, #0b7a53) 32%, transparent);
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent, #0b7a53) 7%, white);
  color: var(--ink, #172019);
  font-size: 0.92rem;
  line-height: 1.5;
}

.split-page-hero .page-hero-copy .pricing-hero-note {
  max-width: 650px;
  margin-top: 14px;
  padding-left: 14px;
  border-left: 2px solid var(--z-primary);
  color: var(--z-ink);
  font-size: 15px;
  line-height: 1.5;
}

.page-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  align-items: center;
  margin-top: 28px;
}

.page-hero-actions .text-link {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--z-primary-hover);
  font-size: 14px;
  font-weight: 700;
}

.page-hero-actions .text-link:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.feature-hero-proof,
.pricing-hero-summary {
  min-width: 0;
  padding: clamp(22px, 3vw, 30px);
  border: 1px solid var(--z-primary-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
}

.feature-proof-source {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.feature-proof-source > span {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: var(--z-radius-md);
  background: var(--z-primary);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.feature-proof-source strong,
.feature-proof-source small {
  display: block;
  overflow-wrap: anywhere;
}

.feature-proof-source strong {
  color: var(--z-ink);
  font-size: 17px;
}

.feature-proof-source small {
  margin-top: 4px;
  color: var(--z-muted);
  font-size: 12px;
}

.feature-proof-connector {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 18px 0;
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 720;
}

.feature-proof-connector span {
  width: 28px;
  height: 1px;
  background: var(--z-primary);
}

.feature-proof-results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.feature-proof-results div {
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-md);
  background: var(--z-surface-muted);
}

.feature-proof-results strong,
.feature-proof-results span {
  display: block;
  overflow-wrap: anywhere;
}

.feature-proof-results strong {
  color: var(--z-ink);
  font-size: 14px;
}

.feature-proof-results span {
  margin-top: 4px;
  color: var(--z-muted);
  font-size: 12px;
}

.feature-hero-proof > p {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin: 16px 0 0;
  color: var(--z-muted-strong);
  font-size: 12px;
  line-height: 1.45;
}

.feature-hero-proof > p span {
  color: var(--z-primary);
  font-weight: 800;
}

.pricing-hero-summary-head {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
}

.pricing-hero-summary .section-kicker {
  margin-bottom: 7px;
}

.pricing-hero-summary h2 {
  margin: 0;
  color: var(--z-ink);
  font-family: var(--z-display-font);
  font-size: 32px;
  font-weight: 560;
}

.pricing-fit-badge {
  padding: 7px 9px;
  border-radius: var(--z-radius-sm);
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
  font-size: 12px;
  font-weight: 720;
  white-space: nowrap;
}

.pricing-hero-price {
  display: flex;
  gap: 9px;
  align-items: baseline;
  margin-top: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--z-line);
}

.pricing-hero-price strong {
  color: var(--z-primary-hover);
  font-size: 32px;
}

.pricing-hero-price span {
  color: var(--z-muted);
  font-size: 12px;
}

.pricing-hero-summary dl {
  display: grid;
  gap: 0;
  margin: 10px 0 0;
}

.pricing-hero-summary dl div {
  display: flex;
  gap: 16px;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--z-line);
  font-size: 13px;
}

.pricing-hero-summary dt {
  color: var(--z-muted);
}

.pricing-hero-summary dd {
  margin: 0;
  color: var(--z-ink);
  font-weight: 720;
  text-align: right;
}

.pricing-hero-summary > p {
  margin: 14px 0 0;
  color: var(--z-muted-strong);
  font-size: 13px;
  line-height: 1.45;
}

.profile-main {
  display: grid;
  gap: 16px;
  width: min(calc(100% - 32px), var(--z-app));
  max-width: var(--z-app);
  margin: 0 auto;
  padding: 24px 0 48px;
}

.profile-hero,
.profile-panel,
.profile-stat-grid article {
  min-width: 0;
  border: 1px solid var(--z-line);
  border-radius: var(--z-radius-lg);
  background: var(--z-surface);
}

.profile-hero {
  display: flex;
  gap: 28px;
  align-items: center;
  justify-content: space-between;
  padding: clamp(22px, 4vw, 34px);
}

.profile-identity {
  display: flex;
  gap: 18px;
  align-items: center;
  min-width: 0;
}

.profile-avatar-large {
  display: grid;
  width: 76px;
  height: 76px;
  flex: 0 0 76px;
  place-items: center;
  border-radius: 50%;
  background: var(--z-primary);
  color: #fff;
  font-family: var(--z-display-font);
  font-size: 34px;
  font-weight: 650;
}

.profile-identity .section-kicker {
  margin-bottom: 7px;
}

.profile-identity h1 {
  margin: 0;
  color: var(--z-ink);
  font-family: var(--z-display-font);
  font-size: clamp(32px, 4vw, 46px);
  font-weight: 560;
  letter-spacing: -0.025em;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.profile-identity p {
  margin: 8px 0 0;
  color: var(--z-muted);
  line-height: 1.45;
}

.profile-hero-actions {
  display: grid;
  gap: 10px;
  justify-items: end;
}

.local-account-badge {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  color: var(--z-muted-strong);
  font-size: 12px;
  font-weight: 680;
}

.local-account-badge i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--z-primary);
}

.profile-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.profile-stat-grid article {
  display: grid;
  gap: 5px;
  padding: 18px;
}

.profile-stat-grid span,
.profile-stat-grid small {
  color: var(--z-muted);
  font-size: 12px;
}

.profile-stat-grid strong {
  color: var(--z-ink);
  font-size: 30px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.profile-dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.profile-panel {
  padding: clamp(18px, 3vw, 26px);
}

.profile-panel-heading {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  justify-content: space-between;
}

.profile-panel-heading .section-kicker {
  margin-bottom: 7px;
}

.profile-panel-heading h2 {
  margin: 0;
  color: var(--z-ink);
  font-size: 22px;
  line-height: 1.2;
}

.profile-panel-heading > span,
.profile-panel-heading > a {
  color: var(--z-muted);
  font-size: 13px;
  white-space: nowrap;
}

.activity-scroll {
  margin-top: 26px;
  padding: 4px 2px 8px;
  overflow-x: auto;
  scrollbar-color: var(--z-line-strong) transparent;
  scrollbar-width: thin;
}

.activity-scroll:focus-visible {
  outline: 3px solid rgba(11, 122, 83, 0.24);
  outline-offset: 4px;
}

.activity-heatmap {
  display: grid;
  grid-auto-columns: 14px;
  grid-auto-flow: column;
  grid-template-rows: repeat(7, 14px);
  gap: 4px;
  width: max-content;
  margin-inline: auto;
}

.activity-day {
  width: 14px;
  height: 14px;
  border: 0;
  border-radius: 2px;
  background: #e9eeeb;
}

.activity-day.is-active { background: #2d9e6d; }

.recent-activity-list {
  display: grid;
  margin-top: 18px;
}

.recent-activity-list article {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-width: 0;
  padding: 14px 0;
  border-top: 1px solid var(--z-line);
}

.recent-activity-list strong,
.recent-activity-list small {
  display: block;
  overflow-wrap: anywhere;
}

.recent-activity-list strong {
  color: var(--z-ink);
}

.recent-activity-list small,
.recent-activity-date {
  margin-top: 4px;
  color: var(--z-muted);
  font-size: 12px;
}

.recent-activity-list a,
.profile-panel-heading a {
  color: var(--z-primary-hover);
  font-size: 13px;
  font-weight: 700;
}

.profile-empty-state {
  display: grid;
  gap: 7px;
  padding: 24px 0 4px;
  color: var(--z-muted);
}

.profile-empty-state strong { color: var(--z-ink); }
.profile-empty-state a { width: fit-content; }

@media (max-width: 980px) {
  .marketing-page .split-page-hero {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-block: 42px;
  }

  .feature-hero-proof,
  .pricing-hero-summary {
    width: min(100%, 680px);
  }

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

}

@media (max-width: 780px) {
  .profile-hero {
    display: grid;
  }

  .profile-hero-actions {
    justify-items: stretch;
  }

  .local-account-badge {
    justify-self: start;
  }

  .profile-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .marketing-page .split-page-hero {
    gap: 24px;
    padding-block: 32px 38px;
  }

  .split-page-hero .page-hero-copy h1 {
    font-size: 38px;
  }

  .feature-proof-results {
    grid-template-columns: 1fr;
  }

  .pricing-hero-summary-head,
  .pricing-hero-price {
    align-items: flex-start;
    flex-direction: column;
  }

  .profile-main {
    width: min(calc(100% - 20px), var(--z-app));
    padding-top: 10px;
  }

  .profile-identity {
    align-items: flex-start;
  }

  .profile-avatar-large {
    width: 58px;
    height: 58px;
    flex-basis: 58px;
    font-size: 26px;
  }

  .profile-stat-grid {
    gap: 8px;
  }

  .profile-stat-grid article {
    padding: 14px;
  }

  .recent-activity-list article {
    grid-template-columns: 1fr auto;
  }

  .recent-activity-date {
    grid-column: 1 / -1;
  }
}

/* Keep the reference three-column workspace visible after the first-run dialog. */
@media (min-width: 1241px) {
  .product-app.is-first-run .app-console {
    grid-template-columns: 220px minmax(0, 1fr) 310px;
    grid-template-areas: "nav main side";
    justify-content: stretch;
  }

  .product-app.is-first-run .app-side-panel {
    display: grid;
  }
}

@media (max-width: 620px) {
  .workspace-titlebar #workspaceShareButton:disabled {
    display: none;
  }
}

/* Creation preview: a concrete, non-numeric promise before the first upload. */
.creation-preview-panel {
  display: none;
  gap: 16px;
  padding: 18px;
}

.creation-preview-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.creation-preview-heading h2 {
  margin: 0;
  color: var(--z-ink);
  font: 760 17px/1.25 var(--z-ui-font);
}

.creation-preview-heading span,
.preview-type {
  display: inline-flex;
  width: fit-content;
  border-radius: 6px;
  font: 700 11px/1.2 var(--z-ui-font);
}

.creation-preview-heading span {
  padding: 6px 8px;
  background: var(--z-primary-soft);
  color: var(--z-primary-hover);
}

.creation-preview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 148px;
  gap: 14px;
  align-items: start;
}

.preview-card-stack {
  display: grid;
  gap: 8px;
}

.creation-preview-card {
  position: relative;
  display: grid;
  min-height: 116px;
  align-content: start;
  gap: 9px;
  padding: 14px;
  border: 1px solid var(--z-line);
  border-radius: 10px;
  background: #fff;
}

.creation-preview-card h3 {
  margin: 0;
  color: var(--z-ink);
  font: 700 14px/1.32 var(--z-ui-font);
  overflow-wrap: anywhere;
}

.creation-preview-card small {
  position: absolute;
  right: 14px;
  bottom: 13px;
  color: var(--z-muted);
  font-size: 11px;
}

.preview-type { padding: 5px 7px; }
.preview-type.definition { background: #e9f6ef; color: #08734e; }
.preview-type.formula { background: #eef3ff; color: #3369c6; }
.preview-type.example { background: #f3ecff; color: #7954bf; }

.preview-answer-button {
  width: fit-content;
  min-height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--z-muted);
  font: 650 11px/1.2 var(--z-ui-font);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.preview-answer-button:hover { color: var(--z-primary-hover); }

.preview-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 2px;
}

.preview-pagination button {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid var(--z-line);
  border-radius: 7px;
  background: #fff;
  color: var(--z-ink);
}

.preview-pagination span { display: flex; gap: 6px; align-items: center; }
.preview-pagination span > * { display: block; width: 6px; height: 6px; border-radius: 50%; background: var(--z-line-strong); }
.preview-pagination span > b { background: var(--z-primary); }

.preview-quality-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--z-line);
  border-radius: 10px;
  background: #fbfdfc;
}

.preview-quality-card strong { color: var(--z-ink); font: 750 13px/1.3 var(--z-ui-font); }
.preview-quality-card ul { display: grid; gap: 9px; margin: 0; padding: 0; list-style: none; }
.preview-quality-card li { display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: 6px; color: var(--z-muted-strong); font-size: 11px; line-height: 1.32; }
.preview-quality-card li i { color: var(--z-primary); font-size: 15px; }
.preview-quality-card p { margin: 0; padding-top: 11px; border-top: 1px solid var(--z-line); color: var(--z-muted); font-size: 11px; line-height: 1.38; }
.preview-quality-card p i { margin-right: 4px; color: var(--z-primary); }

@media (min-width: 1241px) {
  .product-app.is-first-run .app-console {
    grid-template-columns: 220px minmax(590px, 1fr) minmax(390px, 0.68fr);
  }

  .product-app.is-first-run .creation-preview-panel { display: grid; }
  .product-app.is-first-run .today-card,
  .product-app.is-first-run .usage-card,
  .product-app.is-first-run .quick-actions,
  .product-app.is-first-run .library-panel { display: none; }
}

@media (max-width: 1320px) and (min-width: 1241px) {
  .creation-preview-grid { grid-template-columns: 1fr; }
  .preview-quality-card { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; }
  .preview-quality-card p { grid-column: 1 / -1; }
}
