  :root {
    color-scheme: light;
    --bg: #f4efe4;
    --surface: rgba(255, 250, 242, 0.92);
    --surface-strong: #fff8ef;
    --ink: #231a12;
    --muted: #6a5d50;
    --line: rgba(53, 35, 18, 0.12);
    --accent: #b24d2e;
    --accent-deep: #7f2f18;
    --accent-soft: rgba(178, 77, 46, 0.12);
    --success: #2b6a54;
    --warning: #8a5b13;
    --theater-plum: #5f2b45;
    --forest-glow: #355b4c;
    --gold: #b89445;
    --gold-soft: rgba(184, 148, 69, 0.18);
    --paper-edge: #ead7b4;
    --shadow: 0 18px 60px rgba(73, 43, 17, 0.12);
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --max-width: 1440px;
    --font-display: Georgia, "Times New Roman", serif;
    --font-body: "Segoe UI", sans-serif;
  }

  * {
    box-sizing: border-box;
  }

  body {
    margin: 0;
    min-height: 100vh;
    background:
      radial-gradient(circle at top left, rgba(178, 77, 46, 0.18), transparent 28%),
      radial-gradient(circle at right 20%, rgba(72, 123, 115, 0.16), transparent 24%),
      linear-gradient(180deg, #f9f4eb 0%, var(--bg) 100%);
    color: var(--ink);
    font-family: var(--font-body);
  }

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

  .page-shell {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 32px 20px 56px;
  }

  .hero {
    display: grid;
    gap: 24px;
    grid-template-columns: 1fr;
    align-items: start;
    margin-bottom: 28px;
  }

  .eyebrow {
    margin: 0 0 12px;
    font-size: 0.86rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--accent-deep);
  }

  .hero h1 {
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(2.4rem, 4vw, 4.4rem);
    line-height: 0.95;
  }

  .hero-copy {
    max-width: 60ch;
    margin: 18px 0 0;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.6;
  }

  .hero-status {
    display: grid;
    gap: 12px;
  }

  .status-card,
  .panel,
  .sidebar,
  .question-card,
  .review-item,
  .result-card,
  .metric,
  .callout {
    background: var(--surface);
    backdrop-filter: blur(20px);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
  }

  .status-card {
    padding: 18px 20px;
  }

  .status-label {
    display: block;
    margin-bottom: 8px;
    color: var(--muted);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
  }

  .status-card strong {
    display: block;
    word-break: break-word;
    font-size: 1rem;
  }

  .app-shell {
    display: grid;
    gap: 18px;
  }

  .panel {
    padding: 28px;
  }

  .loading-panel,
  .error-panel {
    text-align: center;
  }

  .layout {
    display: grid;
    gap: 18px;
    grid-template-columns: 320px 1fr;
    align-items: start;
  }

  .sidebar {
    position: sticky;
    top: 20px;
    padding: 20px;
  }

  .sidebar h2,
  .content-panel h2,
  .review-panel h2,
  .results-panel h2 {
    margin: 0 0 14px;
    font-family: var(--font-display);
    font-size: 1.55rem;
  }

  .sidebar-copy,
  .part-meta,
  .question-meta,
  .review-item p,
  .result-card p,
  .callout p {
    color: var(--muted);
    line-height: 1.55;
  }

  .nav-list {
    display: grid;
    gap: 10px;
    margin: 18px 0 24px;
  }

  .nav-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.48);
    color: var(--ink);
    cursor: pointer;
    text-align: left;
    transition: transform 120ms ease, border-color 120ms ease, background 120ms ease;
  }

  .nav-button:hover,
  .nav-button:focus-visible {
    transform: translateY(-1px);
    border-color: rgba(178, 77, 46, 0.28);
    background: rgba(255, 255, 255, 0.82);
  }

  .nav-button.active {
    background: linear-gradient(135deg, rgba(178, 77, 46, 0.18), rgba(178, 77, 46, 0.08));
    border-color: rgba(178, 77, 46, 0.35);
  }

  .nav-title {
    font-weight: 600;
  }

  .nav-meta {
    display: block;
    color: var(--muted);
    font-size: 0.82rem;
  }

  .metric-grid,
  .result-grid,
  .landing-grid {
    display: grid;
    gap: 16px;
  }

  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 20px;
  }

  .metric {
    padding: 16px;
  }

  .metric strong,
  .metric span {
    display: block;
  }

  .metric span {
    color: var(--muted);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
  }

  .metric strong {
    margin-top: 8px;
    font-size: 1.25rem;
  }

  .content-panel,
  .review-panel,
  .results-panel {
    padding: 24px;
  }

  .part-header {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: end;
    margin-bottom: 18px;
  }

  .section-group {
    margin-top: 24px;
  }

  .section-group h3 {
    margin: 0 0 14px;
    font-family: var(--font-display);
    font-size: 1.2rem;
  }

  .question-grid {
    display: grid;
    gap: 14px;
  }

  .question-card,
  .review-item,
  .result-card,
  .callout {
    padding: 18px;
  }

  .question-card h4,
  .review-item h3,
  .result-card h3 {
    margin: 0 0 10px;
    font-size: 1.02rem;
  }

  .question-id {
    display: inline-block;
    margin-bottom: 8px;
    padding: 5px 9px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent-deep);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  .question-meta {
    margin: 8px 0 14px;
    font-size: 0.92rem;
  }

  .field,
  .field-stack {
    display: grid;
    gap: 10px;
  }

  .field input,
  .field textarea,
  .field select {
    width: 100%;
    border: 1px solid rgba(53, 35, 18, 0.16);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.88);
    padding: 12px 14px;
    color: var(--ink);
  }

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

  .option-list {
    display: grid;
    gap: 10px;
  }

  .option-row {
    display: flex;
    gap: 10px;
    align-items: start;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.78);
  }

  .option-row input {
    margin-top: 2px;
  }

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

  .scale-button {
    border: 1px solid rgba(53, 35, 18, 0.12);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.8);
    padding: 12px 0;
    cursor: pointer;
  }

  .scale-button.selected,
  .ghost-button:hover,
  .ghost-button:focus-visible,
  .secondary-button:hover,
  .secondary-button:focus-visible {
    border-color: rgba(178, 77, 46, 0.35);
  }

  .scale-button.selected {
    background: linear-gradient(180deg, rgba(178, 77, 46, 0.18), rgba(178, 77, 46, 0.08));
    color: var(--accent-deep);
    font-weight: 700;
  }

  .action-row,
  .review-actions,
  .result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
  }

  .primary-button,
  .secondary-button,
  .ghost-button {
    border-radius: 999px;
    padding: 12px 18px;
    cursor: pointer;
    transition: transform 120ms ease, opacity 120ms ease, border-color 120ms ease;
  }

  .primary-button {
    border: 0;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-deep) 100%);
    color: white;
  }

  .secondary-button,
  .ghost-button {
    border: 1px solid rgba(53, 35, 18, 0.14);
    background: rgba(255, 255, 255, 0.72);
    color: var(--ink);
  }

  .primary-button:hover,
  .secondary-button:hover,
  .ghost-button:hover {
    transform: translateY(-1px);
  }

  .review-grid,
  .result-grid {
    margin-top: 20px;
  }

  .review-grid {
    display: grid;
    gap: 14px;
  }

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

  .result-card ul,
  .callout ul {
    margin: 12px 0 0;
    padding-left: 20px;
  }

  .theme-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
  }

  .theme-chip {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(43, 106, 84, 0.12);
    color: var(--success);
    font-size: 0.88rem;
    font-weight: 600;
  }

  .callout {
    margin-top: 18px;
  }

  .mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.9rem;
  }

  @media (max-width: 1080px) {
    .hero,
    .layout,
    .result-grid {
      grid-template-columns: 1fr;
    }

    .sidebar {
      position: static;
    }
  }

  @media (max-width: 720px) {
    .page-shell {
      padding: 20px 14px 40px;
    }

    .panel,
    .sidebar,
    .content-panel,
    .review-panel,
    .results-panel {
      padding: 18px;
    }

    .metric-grid,
    .scale-grid {
      grid-template-columns: 1fr;
    }

    .part-header {
      flex-direction: column;
      align-items: start;
    }
  }

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

  .narrative-rail {
    margin: 18px 0 24px;
    padding: 16px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.62);
  }

  .rail-header {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
  }

  .rail-list {
    display: grid;
    gap: 10px;
  }

  .rail-item {
    display: grid;
    grid-template-columns: 38px 1fr;
    gap: 12px;
    align-items: center;
    width: 100%;
    border: 1px solid rgba(53, 35, 18, 0.1);
    border-radius: var(--radius-md);
    padding: 12px;
    background: rgba(255, 255, 255, 0.74);
    color: var(--ink);
    text-align: left;
    cursor: pointer;
  }

  .rail-item.active {
    border-color: rgba(178, 77, 46, 0.4);
    background: linear-gradient(135deg, rgba(178, 77, 46, 0.16), rgba(255, 255, 255, 0.84));
  }

  .rail-item.created .rail-count {
    background: rgba(43, 106, 84, 0.16);
    color: var(--success);
  }

  .rail-item.ready .rail-count {
    background: rgba(178, 77, 46, 0.14);
    color: var(--accent-deep);
  }

  .rail-item.pending .rail-count {
    background: rgba(53, 35, 18, 0.08);
    color: var(--muted);
  }

  .rail-count {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    font-weight: 700;
  }

  .rail-copy strong,
  .rail-copy small {
    display: block;
  }

  .rail-copy small {
    margin-top: 4px;
    color: var(--muted);
  }

  .chapter-banner {
    margin-bottom: 18px;
    padding: 18px;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(178, 77, 46, 0.2);
    background: linear-gradient(135deg, rgba(178, 77, 46, 0.12), rgba(255, 255, 255, 0.9));
  }

  .chapter-banner strong {
    display: block;
    margin-bottom: 8px;
    font-size: 1.05rem;
  }

  .chapter-banner p {
    margin: 0;
    color: var(--muted);
    line-height: 1.55;
  }

  .chapter-page,
  .storybook-finale {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(95, 43, 69, 0.16);
    background:
      radial-gradient(circle at top center, rgba(184, 148, 69, 0.18), transparent 30%),
      radial-gradient(circle at 0% 30%, rgba(95, 43, 69, 0.14), transparent 32%),
      radial-gradient(circle at 100% 70%, rgba(53, 91, 76, 0.12), transparent 28%),
      linear-gradient(180deg, rgba(255, 250, 243, 0.98), rgba(248, 239, 224, 0.98));
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, 0.5),
      inset 0 0 0 10px rgba(234, 215, 180, 0.18),
      0 22px 70px rgba(59, 31, 23, 0.18);
  }

  .chapter-page::before,
  .storybook-finale::before {
    content: "";
    position: absolute;
    inset: 14px;
    border: 1px solid rgba(184, 148, 69, 0.28);
    border-radius: 24px;
    pointer-events: none;
  }

  .chapter-summary {
    max-width: 58ch;
    font-size: 1.02rem;
  }

  .chapter-masthead,
  .finale-heading {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 14px;
    margin-bottom: 24px;
  }

  .chapter-title-lockup h2,
  .finale-heading h2 {
    margin: 0;
    font-size: clamp(2.2rem, 4vw, 3.6rem);
    line-height: 0.95;
  }

  .chapter-kicker {
    display: inline-block;
    margin-bottom: 4px;
    color: var(--theater-plum);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.28em;
    text-transform: uppercase;
  }

  .chapter-ornament {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 4px 0 24px;
  }

  .chapter-ornament span {
    display: block;
    height: 10px;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(184, 148, 69, 0.2), rgba(184, 148, 69, 0.95), rgba(184, 148, 69, 0.2));
  }

  .chapter-ornament span:nth-child(1),
  .chapter-ornament span:nth-child(3) {
    width: 72px;
  }

  .chapter-ornament span:nth-child(2) {
    position: relative;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    box-shadow: 0 0 0 4px rgba(184, 148, 69, 0.14);
  }

  .chapter-stamp {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    margin: 2px 0 10px;
    padding: 10px 16px;
    border: 1px solid rgba(184, 148, 69, 0.34);
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(95, 43, 69, 0.1), rgba(255, 255, 255, 0.66));
    color: var(--theater-plum);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.04em;
  }

  .chapter-body-wrap {
    position: relative;
    margin-bottom: 24px;
    padding: 26px 24px;
    border: 1px solid rgba(184, 148, 69, 0.22);
    border-radius: 22px;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(255, 248, 238, 0.8)),
      repeating-linear-gradient(180deg, rgba(90, 61, 40, 0.03), rgba(90, 61, 40, 0.03) 1px, transparent 1px, transparent 36px);
  }

  .chapter-body {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 18px;
  }

  .chapter-body p {
    margin: 0;
    color: #26170f;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.08rem;
    line-height: 1.95;
  }

  .chapter-opening-paragraph::first-letter {
    float: left;
    margin: 0.08em 0.14em 0 0;
    color: var(--theater-plum);
    font-size: 3.6rem;
    font-weight: 700;
    line-height: 0.82;
  }

  .chapter-quote {
    position: relative;
    margin: 0 0 24px;
    padding: 22px 28px;
    border: 1px solid rgba(184, 148, 69, 0.26);
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(95, 43, 69, 0.1), rgba(255, 255, 255, 0.8));
    color: var(--ink);
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-style: italic;
    line-height: 1.7;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.45);
  }

  .chapter-quote::before,
  .chapter-quote::after {
    position: absolute;
    color: rgba(95, 43, 69, 0.24);
    font-size: 3rem;
    line-height: 1;
  }

  .chapter-quote::before {
    content: "\201C";
    top: 10px;
    left: 12px;
  }

  .chapter-quote::after {
    content: "\201D";
    right: 16px;
    bottom: 4px;
  }

  .chapter-grid {
    margin-top: 22px;
    grid-template-columns: 1fr;
  }

  .chapter-grid .result-card {
    width: 100%;
    max-width: none;
  }

  .chapter-grid .result-card,
  .storybook-finale .result-card,
  .storybook-finale .callout,
  .chapter-library-card {
    border: 1px solid rgba(184, 148, 69, 0.22);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(251, 244, 231, 0.96));
  }

  .chapter-grid .result-card h3,
  .storybook-finale .result-card h3,
  .chapter-library h3 {
    font-family: var(--font-display);
  }

  .storybook-finale .result-grid {
    margin-top: 10px;
  }

  .storybook-finale .callout {
    background: linear-gradient(180deg, rgba(255, 249, 238, 0.9), rgba(246, 236, 219, 0.92));
  }

  .chapter-library {
    position: relative;
    z-index: 1;
    margin-top: 28px;
  }

  .chapter-library h3 {
    margin: 0 0 14px;
    font-size: 1.3rem;
  }

  .chapter-library-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .chapter-library-card {
    display: grid;
    gap: 10px;
    width: 100%;
    padding: 20px;
    border-radius: 20px;
    text-align: left;
    cursor: pointer;
    color: var(--ink);
    transition: transform 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
  }

  .chapter-library-card strong {
    font-family: var(--font-display);
    font-size: 1.08rem;
  }

  .chapter-library-card:hover,
  .rail-item:hover {
    transform: translateY(-1px);
  }

  .chapter-library-card:hover {
    border-color: rgba(95, 43, 69, 0.26);
    box-shadow: 0 18px 36px rgba(59, 31, 23, 0.12);
  }

  @media (max-width: 720px) {
    .chapter-library-grid,
    .compact-grid {
      grid-template-columns: 1fr;
    }

    .chapter-title-lockup h2,
    .finale-heading h2 {
      font-size: 2rem;
    }

    .chapter-body-wrap {
      padding: 18px 16px;
    }

    .chapter-opening-paragraph::first-letter {
      font-size: 3rem;
    }
  }

  .primary-button:disabled,
  .secondary-button:disabled,
  .ghost-button:disabled {
    opacity: 0.48;
    cursor: not-allowed;
    transform: none;
  }

  .primary-button:disabled:hover,
  .secondary-button:disabled:hover,
  .ghost-button:disabled:hover {
    transform: none;
  }


  .storybook-shell {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(95, 43, 69, 0.16);
    background:
      radial-gradient(circle at top center, rgba(184, 148, 69, 0.18), transparent 30%),
      radial-gradient(circle at 0% 30%, rgba(95, 43, 69, 0.14), transparent 32%),
      radial-gradient(circle at 100% 70%, rgba(53, 91, 76, 0.12), transparent 28%),
      linear-gradient(180deg, rgba(255, 250, 243, 0.98), rgba(248, 239, 224, 0.98));
    box-shadow:
      inset 0 0 0 1px rgba(255, 255, 255, 0.5),
      inset 0 0 0 10px rgba(234, 215, 180, 0.18),
      0 22px 70px rgba(59, 31, 23, 0.18);
  }

  .storybook-header,
  .storybook-controls,
  .storybook-page-meta {
    display: flex;
    gap: 16px;
  }

  .storybook-header,
  .storybook-controls {
    align-items: center;
    justify-content: space-between;
  }

  .storybook-header {
    margin-bottom: 20px;
  }

  .storybook-page-meta {
    flex-direction: column;
    align-items: flex-end;
    color: var(--muted);
    text-align: right;
  }

  .storybook-frame {
    position: relative;
    margin: 0 84px 22px;
  }

  .storybook-stage {
    perspective: 1800px;
  }

.storybook-side-button {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: auto;
  height: auto;
  border: none;
  outline: none;
  padding: 0;
  background: transparent;
  color: rgba(95, 43, 69, 0.58);
  box-shadow: none;
  cursor: pointer;
  transform: translateY(-50%);
  transition: color 140ms ease, transform 140ms ease;
}

.storybook-side-button-prev {
  left: -38px;
}

.storybook-side-button-next {
  right: -38px;
}

.storybook-side-arrow {
  font-size: 2.35rem;
  line-height: 1;
  font-weight: 700;
}

.storybook-side-button:hover,
.storybook-side-button:focus-visible {
  border: none;
  outline: none;
  background: transparent;
  color: var(--theater-plum);
  box-shadow: none;
}

.storybook-side-button:focus-visible {
  transform: translateY(-50%) scale(1.08);
}

.storybook-side-button:disabled {
  color: rgba(95, 43, 69, 0.2);
  cursor: default;
}

  .storybook-spread {
    padding: 18px;
    border-radius: 26px;
    border: 1px solid rgba(184, 148, 69, 0.24);
    background: linear-gradient(135deg, rgba(255, 250, 243, 0.96), rgba(247, 237, 220, 0.96));
    box-shadow: 0 24px 46px rgba(63, 35, 23, 0.14);
    transform-origin: left center;
  }

  .storybook-page {
    position: relative;
    padding: 28px;
    border-radius: 22px;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(251, 244, 231, 0.96)),
      repeating-linear-gradient(180deg, rgba(90, 61, 40, 0.03), rgba(90, 61, 40, 0.03) 1px, transparent 1px, transparent 36px);
  }

  .page-flip-forward .storybook-spread {
    animation: pageFlipForward 420ms ease;
  }

  .page-flip-backward .storybook-spread {
    animation: pageFlipBackward 420ms ease;
  }

  @keyframes pageFlipForward {
    from { opacity: 0; transform: rotateY(-16deg) translateX(22px); }
    to { opacity: 1; transform: rotateY(0deg) translateX(0); }
  }

  @keyframes pageFlipBackward {
    from { opacity: 0; transform: rotateY(16deg) translateX(-22px); }
    to { opacity: 1; transform: rotateY(0deg) translateX(0); }
  }

  .storybook-index {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
  }

  .chapter-jump-button {
    border: 1px solid rgba(53, 35, 18, 0.14);
    border-radius: 999px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.72);
    color: var(--ink);
    cursor: pointer;
  }

  .chapter-jump-button.active {
    background: linear-gradient(135deg, rgba(178, 77, 46, 0.18), rgba(178, 77, 46, 0.08));
    border-color: rgba(178, 77, 46, 0.35);
    color: var(--accent-deep);
    font-weight: 700;
  }

  .storybook-lead {
    max-width: 56ch;
    margin: 0 0 22px;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.7;
  }

  .cover-page h3,
  .storybook-finale h3,
  .chapter-title-lockup h3 {
    margin-top: 0;
    font-family: var(--font-display);
    font-size: clamp(2rem, 3vw, 3rem);
    line-height: 1;
  }

  @media (max-width: 900px) {
    .storybook-header,
    .storybook-controls {
      flex-direction: column;
      align-items: stretch;
    }

    .storybook-frame {
      margin: 0 0 22px;
      display: grid;
      gap: 14px;
    }

    .storybook-side-button {
      position: static;
      width: auto;
      height: auto;
      min-height: 0;
      transform: none;
      justify-self: center;
    }

    .storybook-page-meta {
      align-items: flex-start;
      text-align: left;
    }
  }

  @media (prefers-reduced-motion: reduce) {
    .page-flip-forward .storybook-spread,
    .page-flip-backward .storybook-spread {
      animation: none;
    }
  }


.storybook-cover .cover-page {
  position: relative;
  overflow: hidden;
  min-height: 720px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 72px 70px 54px;
  background:
    radial-gradient(
      circle at 50% 20%,
      rgba(255, 255, 255, 0.72),
      transparent 36%
    ),
    linear-gradient(
      145deg,
      #fffaf2 0%,
      #f8eddf 50%,
      #f2dfd5 100%
    );
}

.cover-content {
  position: relative;
  z-index: 2;
  width: min(100%, 820px);
  text-align: center;
}

.cover-frame {
  position: absolute;
  inset: 22px;
  z-index: 1;
  pointer-events: none;
  border: 1px solid rgba(95, 43, 69, 0.14);
}

.cover-frame::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid rgba(201, 168, 76, 0.2);
}

.cover-glow {
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.28;
  pointer-events: none;
}

.cover-glow-left {
  top: -180px;
  left: -160px;
  background: rgba(122, 62, 93, 0.4);
}

.cover-glow-right {
  right: -180px;
  bottom: -180px;
  background: rgba(214, 164, 99, 0.42);
}

.cover-ornament {
  margin: 0 auto 22px;
}

.cover-kicker {
  margin-bottom: 18px;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(95, 43, 69, 0.68);
}

.cover-pretitle {
  display: block;
  margin-bottom: 10px;
  font-family: inherit;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(95, 43, 69, 0.52);
}

.cover-title {
  max-width: 700px;
  margin: 0 auto;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.045em;
  font-weight: 500;
  color: #5f2b45;
  text-wrap: balance;
}

.cover-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 220px;
  margin: 28px auto;
  color: rgba(163, 111, 72, 0.75);
}

.cover-divider span {
  flex: 1;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(95, 43, 69, 0.28)
  );
}

.cover-divider span:last-child {
  background: linear-gradient(
    90deg,
    rgba(95, 43, 69, 0.28),
    transparent
  );
}

.cover-divider i {
  font-size: 12px;
  font-style: normal;
}

.cover-lead {
  max-width: 620px;
  margin: 0 auto;
  font-size: 18px;
  line-height: 1.75;
  color: rgba(71, 51, 56, 0.76);
}

.cover-insights {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 48px;
  text-align: left;
}

.cover-insight {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  padding: 22px 24px;

  border: 1px solid rgba(95, 43, 69, 0.1);
  border-radius: 20px;

  background: rgba(255, 252, 246, 0.52);

  box-shadow:
    0 18px 48px rgba(67, 38, 30, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);

  backdrop-filter: blur(12px);
}

.cover-insight-number {
  padding-top: 2px;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: rgba(163, 111, 72, 0.7);
}

.cover-insight-label {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #5f2b45;
}

.cover-insight p {
  margin: 0;
  font-size: 14px;
  line-height: 1.65;
  color: rgba(71, 51, 56, 0.72);
}

.cover-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 38px;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(95, 43, 69, 0.44);
}

.cover-footer-mark {
  color: rgba(163, 111, 72, 0.72);
}

@media (max-width: 720px) {
  .storybook-cover .cover-page {
    min-height: auto;
    padding: 58px 28px 42px;
  }

  .cover-title {
    font-size: clamp(38px, 11vw, 56px);
  }

  .cover-insights {
    grid-template-columns: 1fr;
    margin-top: 36px;
  }

  .cover-footer {
    flex-wrap: wrap;
  }
}





