/* ============================================================================
 * LoliCode Product Release Homepage — "Lovely Studio · Eye-Comfort Edition"
 * Visually aligned with the community palette, typography, cards, and motion.
 * ============================================================================ */

:root {
  color-scheme: light;

  /* 1. Velvet Cherry Stage */
  --cherry-stage-top: #8b223f;
  --cherry-stage-mid: #751b35;
  --cherry-stage-deep: #5d142a;
  --cherry: #8e2240;
  --cherry-deep: #6e1831;
  --cherry-soft: #b23b5c;
  --cherry-tint: rgba(142, 34, 64, 0.08);
  --cherry-tint-strong: rgba(142, 34, 64, 0.14);

  /* 2. Warm Cream & Champagne Gold */
  --cream: #fff6ea;
  --cream-soft: rgba(255, 246, 234, 0.86);
  --cream-muted: rgba(255, 246, 234, 0.66);
  --gold-accent: #f1ba76;
  --gold-soft: rgba(241, 186, 118, 0.28);

  /* 3. Eye-Comfort Warm Paper Canvas & Ivory Cards */
  --paper: #f6f1e8;
  --paper-warm: #efe8dc;
  --paper-card: #fffdf9;
  --paper-card-hover: #ffffff;
  --paper-elevated: rgba(255, 253, 249, 0.95);
  --paper-subtle: #faf6ee;

  /* 4. Neutral Warm-Charcoal Reading Ink */
  --ink-heading: #2a2426;
  --ink-body: #373033;
  --ink-soft: #6c6064;
  --ink-faint: #918388;

  /* 5. Borders & Soft Architectural Shadows */
  --line-paper: rgba(117, 27, 53, 0.10);
  --line-paper-strong: rgba(117, 27, 53, 0.20);
  --line-stage: rgba(255, 244, 228, 0.16);
  --shadow-card: 0 4px 18px rgba(58, 22, 35, 0.045), 0 1px 3px rgba(58, 22, 35, 0.03);
  --shadow-card-hover: 0 12px 28px rgba(88, 24, 45, 0.09), 0 3px 8px rgba(88, 24, 45, 0.04);
  --shadow-float: 0 18px 42px rgba(58, 18, 32, 0.14);

  /* 6. Typography & Layout Metrics */
  --font-serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong", Georgia, serif;
  --font-sans: "Plus Jakarta Sans", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", "Fira Code", Consolas, ui-monospace, monospace;

  --radius-xl: 20px;
  --radius-lg: 15px;
  --radius-md: 11px;
  --radius-sm: 8px;
  --radius-pill: 999px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --header: 68px;
  --gutter: clamp(18px, 4vw, 40px);

  scrollbar-color: rgba(142, 34, 64, 0.42) var(--paper);
}

/* Keyframes matching community motion */
@keyframes stageOrbit {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes satelliteOrbitOne {
  from {
    transform: rotate(-16deg) scaleY(0.46) rotate(0deg);
  }
  to {
    transform: rotate(-16deg) scaleY(0.46) rotate(360deg);
  }
}

@keyframes satelliteOrbitTwo {
  from {
    transform: rotate(24deg) scaleY(0.52) rotate(360deg);
  }
  to {
    transform: rotate(24deg) scaleY(0.52) rotate(0deg);
  }
}

@keyframes companionBreathe {
  0%, 100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(0, -6px, 0) scale(1.016);
  }
}

@keyframes sealBreathe {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotate(-3deg);
  }
  50% {
    transform: translate3d(0, -3px, 0) rotate(0deg);
  }
}

@keyframes ribbonDrift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-50%, 0, 0);
  }
}

/* Global Reset & Warm Paper Canvas */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header) + 18px);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  background-color: var(--paper);
  background-image:
    radial-gradient(circle at 18% 12%, rgba(142, 34, 64, 0.04), transparent 38%),
    radial-gradient(circle at 86% 24%, rgba(241, 186, 118, 0.075), transparent 36%),
    linear-gradient(180deg, #f8f4ec 0%, var(--paper) 420px, var(--paper) 100%);
  color: var(--ink-body);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.7;
  overflow-x: hidden;
}

h1, h2, h3, h4, figure, p, ul, ol {
  margin: 0;
}

h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 800;
  letter-spacing: 0.01em;
}

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

button {
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
  font: inherit;
}

summary {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

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

::selection {
  background: rgba(142, 34, 64, 0.18);
  color: var(--ink-heading);
}

:focus-visible {
  outline: 2.5px solid var(--gold-accent);
  outline-offset: 3px;
}

.wrap {
  width: min(100% - 2 * var(--gutter), 1160px);
  margin-inline: auto;
}

.section-pad {
  padding-block: clamp(52px, 6.2vw, 84px);
}

.plain-link {
  color: var(--cherry);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: rgba(142, 34, 64, 0.35);
  transition: color 0.18s ease, text-decoration-color 0.18s ease;
}

.plain-link:hover {
  color: var(--cherry-deep);
  text-decoration-color: currentColor;
}

.skip-link {
  position: fixed;
  z-index: 1200;
  top: 10px;
  left: 14px;
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  background: var(--paper-card);
  color: var(--ink-heading);
  font-weight: 600;
  box-shadow: var(--shadow-float);
  transform: translateY(-200%);
}

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

/* Reading Progress Bar */
.reading-progress {
  position: fixed;
  z-index: 1100;
  inset: 0 0 auto;
  height: 3px;
  pointer-events: none;
  background: linear-gradient(90deg, var(--gold-accent) 0%, #ffd89b 48%, var(--cherry-soft) 100%);
  box-shadow: 0 0 10px rgba(241, 186, 118, 0.45);
  transform: scaleX(var(--reading-progress, 0));
  transform-origin: left center;
}

/* Studio Eyebrow Pill */
.overline {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 12px;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  font-family: var(--font-sans);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.4;
  background: var(--cherry-tint);
  border: 1px solid rgba(142, 34, 64, 0.18);
  color: var(--cherry);
}

.overline::before {
  content: "✦";
  font-size: 10px;
  color: var(--cherry-soft);
}

.cover .overline,
.screening .overline {
  background: rgba(255, 246, 234, 0.11);
  border: 1px solid rgba(241, 186, 118, 0.36);
  color: var(--gold-accent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.cover .overline::before,
.screening .overline::before {
  color: var(--gold-accent);
}

/* ============================================================================
 * Sticky Top Header (.masthead)
 * ============================================================================ */
.masthead {
  position: sticky;
  top: 0;
  z-index: 900;
  color: var(--cream);
  background: linear-gradient(135deg, rgba(139, 34, 63, 0.96) 0%, rgba(117, 27, 53, 0.96) 56%, rgba(93, 20, 42, 0.97) 100%);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-stage);
  box-shadow: 0 6px 24px rgba(48, 12, 24, 0.14);
}

.masthead-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: var(--header);
}

.brand {
  order: 1;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  flex-shrink: 0;
  color: var(--cream);
  transition: transform 0.22s var(--ease-out);
}

.brand:hover {
  transform: translateY(-1px);
}

.brand-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  object-fit: cover;
  border: 1.5px solid rgba(255, 243, 224, 0.45);
  box-shadow: 0 6px 14px rgba(32, 6, 15, 0.25);
  background: rgba(255, 246, 234, 0.14);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-word {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.brand-word i {
  font-style: normal;
  color: var(--gold-accent);
}

.brand-sub {
  font-size: 11px;
  color: var(--cream-muted);
  letter-spacing: 0.04em;
  margin-top: 2px;
}

.site-nav {
  order: 2;
  display: flex;
  align-items: center;
  gap: 6px;
}

.site-nav a {
  padding: 7px 13px;
  border-radius: var(--radius-pill);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--cream-soft);
  white-space: nowrap;
  transition: background-color 0.2s var(--ease-out), color 0.2s var(--ease-out);
}

.site-nav a:hover {
  background: rgba(255, 246, 234, 0.12);
  color: #ffffff;
}

.site-nav a[aria-current="location"] {
  background: rgba(255, 246, 234, 0.16);
  color: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(241, 186, 118, 0.36);
}

.nav-download {
  order: 3;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 15px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #fffaf2 0%, #fbead3 100%);
  color: var(--cherry-deep);
  border: 1px solid rgba(255, 250, 242, 0.68);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(36, 7, 17, 0.22);
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out), background 0.2s ease;
}

.nav-download:hover {
  transform: translateY(-1px);
  background: linear-gradient(135deg, #ffffff 0%, #fff1dc 100%);
  box-shadow: 0 10px 22px rgba(36, 7, 17, 0.28);
}

.menu-toggle {
  order: 4;
  flex-shrink: 0;
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 246, 234, 0.28);
  background: rgba(255, 246, 234, 0.12);
  color: var(--cream);
  font-size: 13px;
  font-weight: 600;
}

/* ============================================================================
 * Velvet Cherry Hero Stage (.cover)
 * ============================================================================ */
.cover {
  position: relative;
  overflow: clip;
  color: var(--cream);
  background:
    radial-gradient(circle at 78% 26%, rgba(241, 186, 118, 0.20), transparent 36%),
    radial-gradient(circle at 14% 20%, rgba(255, 230, 200, 0.10), transparent 38%),
    linear-gradient(138deg, var(--cherry-stage-top) 0%, var(--cherry-stage-mid) 54%, var(--cherry-stage-deep) 100%);
}

.cover::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 245, 230, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 245, 230, 0.045) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(circle at 50% 42%, rgba(0, 0, 0, 0.78), transparent 90%);
  -webkit-mask-image: radial-gradient(circle at 50% 42%, rgba(0, 0, 0, 0.78), transparent 90%);
}

.cover-wrap {
  position: relative;
  z-index: 2;
  padding-block: clamp(24px, 3vw, 40px) clamp(20px, 2.5vw, 32px);
  display: flex;
  flex-direction: column;
  gap: clamp(18px, 2.2vw, 26px);
}

.cover-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
  align-items: center;
  gap: clamp(24px, 4vw, 56px);
}

.cover-copy,
.cover-download {
  min-width: 0;
}

.cover h1 {
  font-family: var(--font-serif);
  font-size: clamp(2.3rem, 4.1vw, 3.65rem);
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: 0.01em;
  color: var(--cream);
  text-shadow: 0 4px 20px rgba(36, 6, 17, 0.25);
}

.cover h1 span {
  display: block;
}

.hero-hand {
  margin-top: 10px;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 13.5px;
  color: var(--gold-accent);
  letter-spacing: 0.03em;
  opacity: 0.94;
}

.cover-description {
  margin-top: 14px;
  max-width: 34rem;
  color: var(--cream-soft);
  font-size: 15.5px;
  line-height: 1.72;
  text-wrap: pretty;
}

.cover-download {
  position: relative;
  z-index: 8;
  margin-top: 22px;
}

.cover-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 14.5px;
  line-height: 1.3;
  transition: transform 0.22s var(--ease-out), box-shadow 0.22s var(--ease-out), background 0.2s ease, border-color 0.2s ease;
}

.action-light {
  background: linear-gradient(135deg, #fffaf2 0%, #fbead3 100%);
  color: var(--cherry-deep);
  border: 1px solid rgba(255, 250, 242, 0.7);
  box-shadow: 0 10px 24px rgba(36, 7, 17, 0.24);
}

.action-light:hover {
  transform: translateY(-1.5px);
  background: linear-gradient(135deg, #ffffff 0%, #fff2df 100%);
  box-shadow: 0 14px 28px rgba(36, 7, 17, 0.32);
}

.action-quiet {
  color: var(--cream);
  border: 1px solid rgba(255, 246, 234, 0.28);
  background: rgba(255, 246, 234, 0.11);
}

.action-quiet:hover {
  transform: translateY(-1.5px);
  background: rgba(255, 246, 234, 0.18);
  border-color: rgba(241, 186, 118, 0.55);
}

.window-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  background: conic-gradient(currentColor 0 0) 0 0 / 44% 44% space;
}

.download-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-top: 14px;
  font-size: 13px;
  color: var(--cream-soft);
}

.version-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  background: rgba(255, 246, 234, 0.10);
  border: 1px solid rgba(255, 246, 234, 0.20);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--cream);
}

.version-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold-accent);
  box-shadow: 0 0 8px var(--gold-accent);
}

.more-downloads {
  position: relative;
}

.more-downloads summary {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  border: 1px dashed rgba(255, 246, 234, 0.28);
  color: var(--cream);
  font-size: 12.5px;
  font-weight: 600;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.more-downloads summary:hover {
  background: rgba(255, 246, 234, 0.12);
  border-color: var(--gold-accent);
}

.download-options {
  position: absolute;
  z-index: 30;
  top: calc(100% + 8px);
  left: 0;
  width: min(272px, 82vw);
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  background: var(--paper-card);
  color: var(--ink-body);
  border: 1px solid var(--line-paper-strong);
  box-shadow: var(--shadow-float);
}

.download-options a {
  display: block;
  padding: 6px 8px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--cherry);
  transition: background-color 0.16s ease;
}

.download-options a:hover {
  background: var(--cherry-tint);
}

.download-options p {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line-paper);
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 1.55;
}

.download-options p a {
  display: inline;
  padding: 0;
  text-decoration: underline;
}

.release-status {
  margin-top: 8px;
  font-size: 13px;
  color: var(--cream-soft);
}

.release-status:is([data-state="ready"], [data-state="loading"]) {
  position: absolute;
  width: 1px;
  height: 1px;
  clip-path: inset(50%);
  overflow: hidden;
}

#retry {
  margin-top: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 246, 234, 0.34);
  background: rgba(255, 246, 234, 0.12);
  color: var(--cream);
  font-size: 13px;
}

/* ============================================================================
 * Right-Side Celestial Astrolabe & Companion Stage (.studio-stage)
 * ============================================================================ */
.press-art.studio-stage {
  position: relative;
  width: 100%;
  min-height: 360px;
  aspect-ratio: 1.08;
  display: flex;
  align-items: center;
  justify-content: center;
  isolation: isolate;
}

.stage-disc {
  position: absolute;
  width: min(72%, 330px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(255, 236, 206, 0.30) 0%, rgba(241, 186, 118, 0.12) 48%, transparent 72%),
    conic-gradient(
      from 0deg,
      rgba(255, 246, 234, 0.16),
      rgba(241, 186, 118, 0.04),
      rgba(255, 246, 234, 0.18),
      rgba(241, 186, 118, 0.04),
      rgba(255, 246, 234, 0.16)
    );
  border: 1.5px dashed rgba(241, 186, 118, 0.42);
  box-shadow: 0 0 60px rgba(241, 186, 118, 0.14);
}

.stage-orbit {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255, 242, 222, 0.28);
  pointer-events: none;
}

.stage-orbit::after {
  content: "";
  position: absolute;
  top: -4px;
  left: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-accent);
  box-shadow: 0 0 12px var(--gold-accent), 0 0 22px rgba(241, 186, 118, 0.55);
}

.stage-orbit.orbit-one {
  width: min(94%, 430px);
  aspect-ratio: 1;
  transform: rotate(-16deg) scaleY(0.46);
}

.stage-orbit.orbit-two {
  width: min(82%, 376px);
  aspect-ratio: 1;
  border-style: dashed;
  border-color: rgba(241, 186, 118, 0.38);
  transform: rotate(24deg) scaleY(0.52);
}

.stage-star {
  position: absolute;
  color: var(--gold-accent);
  font-size: 20px;
  line-height: 1;
  text-shadow: 0 0 14px rgba(241, 186, 118, 0.8);
  pointer-events: none;
}

.stage-star-top {
  top: 10%;
  right: 12%;
}

.stage-star-bottom {
  bottom: 18%;
  left: 10%;
  font-size: 16px;
}

.press-mascot {
  position: relative;
  z-index: 2;
  width: auto;
  height: min(84%, 365px);
  max-width: 86%;
  object-fit: contain;
  filter: drop-shadow(0 18px 28px rgba(32, 5, 15, 0.42));
  transform: translate3d(calc(var(--pointer-x, 0px) * 0.45), calc(var(--pointer-y, 0px) * 0.35), 0);
  transition: transform 0.25s ease-out;
}

.stage-seal {
  position: absolute;
  z-index: 3;
  bottom: 8%;
  left: 8%;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 13px;
  border-radius: var(--radius-pill);
  background: rgba(88, 18, 40, 0.88);
  border: 1px solid rgba(241, 186, 118, 0.48);
  color: var(--cream);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.12em;
  box-shadow: 0 8px 18px rgba(28, 4, 13, 0.28);
}

.stage-seal strong {
  color: var(--gold-accent);
  font-size: 12px;
}

.motion-toggle {
  position: absolute;
  z-index: 4;
  right: 0;
  bottom: 4%;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: rgba(54, 12, 26, 0.72);
  border: 1px solid rgba(255, 246, 234, 0.24);
  color: var(--cream-soft);
  font-size: 12px;
  font-weight: 600;
  backdrop-filter: blur(8px);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.motion-toggle:hover {
  border-color: var(--gold-accent);
  background: rgba(88, 18, 40, 0.86);
  color: #ffffff;
}

[data-effects="active"][data-page-visible="true"] .press-art[data-scene-visible="true"] .stage-disc {
  animation: stageOrbit 56s linear infinite;
}

[data-effects="active"][data-page-visible="true"] .press-art[data-scene-visible="true"] .stage-orbit.orbit-one {
  animation: satelliteOrbitOne 26s linear infinite;
}

[data-effects="active"][data-page-visible="true"] .press-art[data-scene-visible="true"] .stage-orbit.orbit-two {
  animation: satelliteOrbitTwo 34s linear infinite;
}

[data-effects="active"][data-page-visible="true"] .press-art[data-scene-visible="true"] .stage-star {
  animation: stageOrbit 18s linear infinite;
}

[data-effects="active"][data-page-visible="true"] .press-art[data-scene-visible="true"] .stage-seal {
  animation: sealBreathe 4.6s ease-in-out infinite;
}

/* ============================================================================
 * Full-Width CLI Install Dock (#terminal-install)
 * ============================================================================ */
.console {
  position: relative;
  z-index: 5;
  width: 100%;
  border-radius: 16px;
  background: rgba(54, 12, 26, 0.52);
  border: 1px solid rgba(255, 244, 228, 0.20);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 14px 34px rgba(32, 6, 15, 0.24);
  overflow: hidden;
}

.console-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255, 244, 228, 0.14);
  background: rgba(42, 8, 20, 0.34);
}

.console-title-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.console-title-group h2 {
  font-family: var(--font-sans);
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--cream);
}

.console-req {
  padding: 2px 9px;
  border-radius: var(--radius-pill);
  background: rgba(255, 246, 234, 0.10);
  border: 1px solid rgba(255, 246, 234, 0.16);
  font-size: 11.5px;
  color: var(--cream-soft);
}

.console-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.terminal-tabs {
  display: inline-flex;
  padding: 3px;
  border-radius: var(--radius-pill);
  background: rgba(34, 6, 16, 0.55);
  border: 1px solid rgba(255, 246, 234, 0.14);
  gap: 3px;
}

.terminal-tabs button {
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--cream-soft);
  transition: background-color 0.18s ease, color 0.18s ease;
}

.terminal-tabs button:hover {
  color: #ffffff;
}

.terminal-tabs [aria-selected="true"] {
  background: linear-gradient(135deg, #fffaf2 0%, #fbead3 100%);
  color: var(--cherry-deep);
  box-shadow: 0 2px 8px rgba(24, 4, 12, 0.25);
}

.console-manual {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--gold-accent);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: rgba(241, 186, 118, 0.45);
}

.console-manual:hover {
  color: #ffe3b8;
  text-decoration-color: currentColor;
}

.console-shell {
  padding: 12px 18px 14px;
}

.terminal-platform {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px 16px;
}

.terminal-platform + .terminal-platform {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 244, 228, 0.12);
}

.terminal-platform[hidden] + .terminal-platform {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.platform-label {
  grid-column: 1 / -1;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--gold-accent);
}

[data-enhanced] .platform-label {
  display: none;
}

.terminal-platform pre {
  margin: 0;
  padding: 4px 2px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 246, 234, 0.25) transparent;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.65;
  color: #fff6e8;
}

.terminal-platform code {
  font: inherit;
}

.copy-command {
  padding: 8px 15px;
  border-radius: var(--radius-sm);
  background: rgba(255, 246, 234, 0.14);
  border: 1px solid rgba(255, 246, 234, 0.26);
  color: var(--cream);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 0.18s ease, border-color 0.18s ease;
}

.copy-command:hover {
  background: rgba(255, 246, 234, 0.24);
  border-color: var(--gold-accent);
}

.console-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 0 18px 12px;
  font-size: 12px;
  color: var(--gold-accent);
}

.console-foot:empty,
.console-foot:has(> [data-install-status]:empty) {
  display: none;
}

/* ============================================================================
 * Studio Marquee Ribbon (.studio-ribbon) — Matches /all .lc-studio-ribbon
 * ============================================================================ */
.studio-ribbon {
  position: relative;
  z-index: 2;
  overflow: hidden;
  background: linear-gradient(90deg, #efe6d7 0%, #f6efe3 50%, #efe6d7 100%);
  border-top: 1px solid rgba(241, 186, 118, 0.35);
  border-bottom: 1px solid var(--line-paper);
  padding: 9px 0;
  color: var(--cherry-deep);
  user-select: none;
}

.ribbon-track {
  display: flex;
  align-items: center;
  width: max-content;
}

[data-effects="active"][data-page-visible="true"] .studio-ribbon[data-scene-visible="true"] .ribbon-track {
  animation: ribbonDrift 38s linear infinite;
}

.ribbon-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 20px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #6a2439;
  white-space: nowrap;
}

.ribbon-item b {
  color: #c27b2b;
  font-weight: 800;
}

/* ============================================================================
 * Section Headings
 * ============================================================================ */
.section-intro {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: clamp(24px, 3vw, 38px);
}

.section-intro h2,
.screening-copy h2,
.first-task h2 {
  font-size: clamp(1.85rem, 3.1vw, 2.55rem);
  line-height: 1.24;
  color: var(--ink-heading);
}

.screening-copy h2 {
  color: var(--cream);
}

.section-intro > p {
  max-width: 28rem;
  color: var(--ink-soft);
  font-size: 15px;
}

/* ============================================================================
 * Interactive Workspace Showcase (#features)
 * ============================================================================ */
.gallery-spread {
  display: grid;
  grid-template-columns: minmax(0, 1.56fr) minmax(260px, 0.86fr);
  gap: clamp(20px, 3vw, 34px);
  align-items: stretch;
}

.gallery-figure,
.projector,
.journal-spread > * {
  min-width: 0;
}

.showcase-window {
  display: flex;
  flex-direction: column;
  padding: 12px;
  border-radius: var(--radius-xl);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  box-shadow: var(--shadow-float);
}

.window-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 8px 12px;
}

.window-dots {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.window-dots i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(142, 34, 64, 0.18);
}

.window-dots i:first-child {
  background: rgba(142, 34, 64, 0.42);
}

.window-dots i:nth-child(2) {
  background: rgba(241, 186, 118, 0.72);
}

.window-title {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-soft);
}

.preview-hint {
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--paper-subtle);
  border: 1px solid var(--line-paper);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--ink-soft);
}

.preview-open {
  display: block;
  cursor: zoom-in;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line-paper);
  background: var(--paper-warm);
}

.preview-open img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: transform 0.32s var(--ease-out);
}

.preview-open:hover img {
  transform: scale(1.012);
}

.preview-tabs {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
}

.preview-tabs button {
  position: relative;
  width: 100%;
  padding: 15px 18px 15px 22px;
  text-align: left;
  border-radius: var(--radius-lg);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  box-shadow: var(--shadow-card);
  transition: transform 0.24s var(--ease-out), box-shadow 0.24s var(--ease-out), border-color 0.24s var(--ease-out), background-color 0.24s ease;
}

.preview-tabs button::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  bottom: 14px;
  width: 3.5px;
  border-radius: 0 4px 4px 0;
  background: linear-gradient(180deg, var(--cherry) 0%, var(--gold-accent) 100%);
  opacity: 0;
  transform: scaleY(0.3);
  transition: opacity 0.24s var(--ease-out), transform 0.24s var(--ease-out);
}

.preview-tabs button:hover {
  transform: translateY(-2px);
  background: var(--paper-card-hover);
  border-color: var(--line-paper-strong);
  box-shadow: var(--shadow-card-hover);
}

.preview-tabs button[aria-selected="true"] {
  background: var(--paper-card-hover);
  border-color: rgba(142, 34, 64, 0.34);
  box-shadow: var(--shadow-card-hover);
}

.preview-tabs button:hover::before,
.preview-tabs button[aria-selected="true"]::before {
  opacity: 1;
  transform: scaleY(1);
}

.preview-tabs strong {
  display: block;
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink-heading);
  transition: color 0.18s ease;
}

.preview-tabs button:hover strong,
.preview-tabs button[aria-selected="true"] strong {
  color: var(--cherry);
}

.preview-tabs button span {
  display: block;
  margin-top: 4px;
  color: var(--ink-soft);
  font-size: 13.5px;
  line-height: 1.55;
}

.capabilities {
  margin-top: 24px;
  border-radius: var(--radius-lg);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  box-shadow: var(--shadow-card);
  padding: 0 20px;
}

.capabilities summary {
  padding: 15px 0;
  font-weight: 700;
  font-size: 14.5px;
  color: var(--ink-heading);
}

.capabilities summary:hover {
  color: var(--cherry);
}

.capability-copy {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  gap: 18px;
  padding-bottom: 20px;
}

.capability-copy article {
  padding: 18px 20px;
  border-radius: var(--radius-md);
  background: var(--paper-subtle);
  border: 1px solid var(--line-paper);
}

.detail-label {
  display: inline-block;
  margin-bottom: 6px;
  padding: 2px 9px;
  border-radius: var(--radius-pill);
  background: var(--cherry-tint);
  color: var(--cherry);
  font-size: 11.5px;
  font-weight: 700;
}

.capability-copy h3 {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink-heading);
  margin-bottom: 8px;
}

.capability-copy p {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.68;
}

.capability-copy p + p {
  margin-top: 8px;
}

.capability-copy .plain-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 13.5px;
}

/* ============================================================================
 * 54s Live Demo Stage (#film) — Velvet Cherry Stage
 * ============================================================================ */
.screening {
  position: relative;
  color: var(--cream);
  background:
    radial-gradient(circle at 86% 18%, rgba(241, 186, 118, 0.16), transparent 38%),
    radial-gradient(circle at 12% 84%, rgba(255, 230, 200, 0.08), transparent 40%),
    linear-gradient(142deg, var(--cherry-stage-top) 0%, var(--cherry-stage-mid) 56%, var(--cherry-stage-deep) 100%);
  border-block: 1px solid var(--line-stage);
}

.screening::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 245, 230, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 245, 230, 0.04) 1px, transparent 1px);
  background-size: 28px 28px;
}

.screening-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(250px, 0.84fr) minmax(0, 1.56fr);
  align-items: center;
  gap: clamp(24px, 4vw, 48px);
}

.screening-copy > p:not(.overline) {
  margin-top: 14px;
  color: var(--cream-soft);
  font-size: 15px;
  line-height: 1.72;
}

.chapter-list {
  display: grid;
  gap: 8px;
  margin-top: 22px;
}

.chapter-list a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: var(--radius-md);
  background: rgba(255, 246, 234, 0.08);
  border: 1px solid rgba(255, 246, 234, 0.14);
  font-size: 14px;
  font-weight: 600;
  color: var(--cream-soft);
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s var(--ease-out);
}

.chapter-list a span {
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  background: rgba(44, 8, 20, 0.45);
  color: var(--gold-accent);
  font-family: var(--font-mono);
  font-size: 12px;
}

.chapter-list a:hover {
  background: rgba(255, 246, 234, 0.14);
  color: #ffffff;
  transform: translateX(3px);
}

.chapter-list a[aria-current="step"] {
  background: rgba(255, 246, 234, 0.18);
  border-color: rgba(241, 186, 118, 0.55);
  color: #ffffff;
  box-shadow: inset 3px 0 0 var(--gold-accent);
}

.harness-film {
  padding: 10px;
  border-radius: var(--radius-xl);
  background: rgba(46, 10, 22, 0.58);
  border: 1px solid rgba(255, 244, 228, 0.18);
  box-shadow: 0 20px 44px rgba(24, 4, 12, 0.34);
}

.film-player {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #2b0b16;
}

.film-player video {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
}

.film-play {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, #fffaf2 0%, #fbead3 100%);
  color: var(--cherry-deep);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 12px 28px rgba(24, 4, 12, 0.36);
}

.film-caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 14px;
  padding: 10px 6px 4px;
  font-size: 12.5px;
  color: var(--cream-soft);
}

.film-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.film-actions button {
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  background: rgba(255, 246, 234, 0.12);
  border: 1px solid rgba(255, 246, 234, 0.24);
  font-size: 12px;
  font-weight: 600;
}

.film-actions button:hover {
  background: rgba(255, 246, 234, 0.22);
  border-color: var(--gold-accent);
}

.film-actions a {
  color: var(--gold-accent);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.film-error {
  margin-top: 8px;
  font-size: 13px;
  color: var(--gold-accent);
}

.film-note {
  margin-top: 12px;
  padding: 0 16px;
  border-radius: var(--radius-md);
  background: rgba(46, 10, 22, 0.40);
  border: 1px solid rgba(255, 244, 228, 0.14);
  color: var(--cream-soft);
}

.film-note summary {
  padding: 11px 0;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--cream);
}

.film-note ol {
  padding: 0 0 14px 20px;
  font-size: 13.5px;
  line-height: 1.7;
}

.film-note li + li {
  margin-top: 4px;
}

.film-note code {
  padding: 1px 6px;
  border-radius: 5px;
  background: rgba(255, 246, 234, 0.14);
  font-family: var(--font-mono);
  font-size: 12px;
}

/* ============================================================================
 * Quick Start & FAQ (#start)
 * ============================================================================ */
.setup-spread {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(24px, 4.5vw, 52px);
  align-items: start;
}

.setup-steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin-top: 22px;
  display: grid;
  gap: 12px;
}

.setup-steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 14px;
  align-items: start;
  padding: 16px 18px;
  border-radius: var(--radius-lg);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  box-shadow: var(--shadow-card);
}

.setup-steps li::before {
  content: counter(step, decimal-leading-zero);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--cherry-tint);
  border: 1px solid rgba(142, 34, 64, 0.16);
  color: var(--cherry);
  font-family: var(--font-serif);
  font-weight: 800;
  font-size: 15px;
}

.setup-steps h3 {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink-heading);
}

.setup-steps p {
  margin-top: 4px;
  font-size: 14px;
  color: var(--ink-soft);
}

.faq {
  padding: clamp(22px, 3vw, 32px);
  border-radius: var(--radius-xl);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  box-shadow: var(--shadow-card);
}

.faq h2 {
  font-size: clamp(1.5rem, 2.3vw, 1.95rem);
  color: var(--ink-heading);
  margin-bottom: 14px;
}

.faq details {
  border-top: 1px solid var(--line-paper);
}

.faq details:last-child {
  border-bottom: 1px solid var(--line-paper);
}

.faq summary {
  padding: 15px 0;
  font-weight: 700;
  font-size: 15px;
  color: var(--ink-heading);
}

.faq summary:hover {
  color: var(--cherry);
}

.faq details p {
  padding: 0 0 16px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.7;
}

.faq code {
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--cherry-tint);
  color: var(--cherry-deep);
  font-family: var(--font-mono);
  font-size: 12.5px;
}

/* ============================================================================
 * Guides Shelf (#guides)
 * ============================================================================ */
.guide-shelf {
  background: linear-gradient(180deg, rgba(239, 232, 220, 0.58) 0%, rgba(246, 241, 232, 0.92) 100%);
  border-block: 1px solid var(--line-paper);
}

.book-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2.4vw, 26px);
}

.book-list a {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 14px;
  border-radius: var(--radius-xl);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  box-shadow: var(--shadow-card);
  transition: transform 0.24s var(--ease-out), box-shadow 0.24s var(--ease-out), border-color 0.24s ease;
}

.book-list a:hover {
  transform: translateY(-4px);
  background: var(--paper-card-hover);
  border-color: var(--line-paper-strong);
  box-shadow: var(--shadow-card-hover);
}

.book-art {
  display: grid;
  place-items: center;
  aspect-ratio: 1.48;
  border-radius: var(--radius-lg);
  background: #f4ead8;
  border: 1px solid rgba(117, 27, 53, 0.08);
  overflow: hidden;
}

.book-art img {
  width: auto;
  height: 100%;
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
  transition: transform 0.35s var(--ease-out);
}

.book-list a:hover .book-art img {
  transform: scale(1.03);
}

.book-list h3 {
  margin: 14px 6px 6px;
  font-family: var(--font-sans);
  font-size: 16.5px;
  font-weight: 700;
  color: var(--ink-heading);
  transition: color 0.18s ease;
}

.book-list a:hover h3 {
  color: var(--cherry);
}

.book-list p {
  margin: 0 6px 12px;
  color: var(--ink-soft);
  font-size: 13.5px;
  line-height: 1.62;
}

.guide-cue {
  margin: auto 6px 4px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--cherry);
}

/* ============================================================================
 * Release Notes & Community Feed (.journal)
 * ============================================================================ */
.journal-spread {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 32px);
}

.journal-card {
  padding: clamp(22px, 3vw, 30px);
  border-radius: var(--radius-xl);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  box-shadow: var(--shadow-card);
}

.journal-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line-paper);
}

.journal-heading h2 {
  font-size: clamp(1.5rem, 2.2vw, 1.9rem);
  color: var(--ink-heading);
}

.journal-heading a {
  font-size: 13.5px;
  white-space: nowrap;
}

.release-edition {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0 12px;
}

.release-edition strong {
  display: inline-flex;
  align-items: center;
  padding: 4px 13px;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, var(--cherry-stage-top) 0%, var(--cherry-deep) 100%);
  color: var(--cream);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
}

.release-edition time {
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--paper-subtle);
  border: 1px solid var(--line-paper);
  color: var(--ink-soft);
  font-size: 12.5px;
}

#notes {
  overflow-wrap: anywhere;
  font-size: 14px;
  color: var(--ink-body);
  line-height: 1.72;
}

#notes h3 {
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink-heading);
  margin: 10px 0 4px;
}

#notes ul {
  padding-left: 18px;
  margin: 6px 0;
}

.release-notes-extra {
  margin: 10px 0;
}

.release-notes-extra summary {
  font-size: 13px;
  font-weight: 700;
  color: var(--cherry);
}

.release-help {
  margin-top: 16px;
  padding: 11px 14px;
  border-radius: var(--radius-md);
  background: var(--paper-subtle);
  border: 1px solid var(--line-paper);
  color: var(--ink-soft);
  font-size: 13px;
}

.discussion-list {
  padding: 0;
  margin-top: 16px;
  list-style: none;
  display: grid;
  gap: 10px;
}

.discussion-list li {
  position: relative;
}

.discussion-list a {
  position: relative;
  display: flex;
  gap: 6px 12px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 13px 15px 13px 18px;
  border-radius: var(--radius-md);
  background: var(--paper-subtle);
  border: 1px solid var(--line-paper);
  transition: transform 0.22s var(--ease-out), background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.discussion-list a::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: linear-gradient(180deg, var(--cherry) 0%, var(--gold-accent) 100%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.discussion-list a:hover {
  transform: translateY(-1.5px);
  background: var(--paper-card-hover);
  border-color: var(--line-paper-strong);
  box-shadow: var(--shadow-card);
}

.discussion-list a:hover::before {
  opacity: 1;
}

.discussion-title {
  flex: 1 1 13rem;
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink-heading);
  transition: color 0.18s ease;
}

.discussion-list a:hover .discussion-title {
  color: var(--cherry);
}

.discussion-meta {
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--paper-card);
  border: 1px solid var(--line-paper);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.community-status {
  margin-top: 14px;
  font-size: 13.5px;
  color: var(--ink-soft);
}

/* ============================================================================
 * Footer (.colophon) — Velvet Cherry Studio Footer
 * ============================================================================ */
.colophon {
  position: relative;
  color: var(--cream);
  background:
    radial-gradient(circle at 14% 18%, rgba(241, 186, 118, 0.12), transparent 36%),
    linear-gradient(155deg, var(--cherry-stage-top) 0%, var(--cherry-stage-mid) 48%, var(--cherry-stage-deep) 100%);
  border-top: 1px solid var(--line-stage);
}

.colophon-top {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) 1fr 1fr;
  gap: 28px;
  align-items: start;
  padding: clamp(42px, 5vw, 68px) 0 34px;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.footer-brand-icon {
  width: 48px;
  height: 48px;
  border-radius: 13px;
  object-fit: cover;
  border: 1.5px solid rgba(255, 243, 224, 0.45);
  box-shadow: 0 8px 20px rgba(32, 6, 15, 0.28);
}

.footer-wordmark {
  display: block;
  font-family: var(--font-serif);
  font-size: clamp(2.1rem, 3.6vw, 3rem);
  font-weight: 800;
  letter-spacing: 0.01em;
  line-height: 1.05;
  color: var(--cream);
}

.footer-wordmark i {
  font-style: normal;
  color: var(--gold-accent);
}

.colophon-top p {
  margin-top: 12px;
  color: var(--cream-soft);
  font-size: 14px;
}

.colophon nav {
  display: grid;
  justify-items: start;
  gap: 8px;
}

.colophon nav h2 {
  font-family: var(--font-sans);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--gold-accent);
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}

.colophon nav a {
  font-size: 14px;
  color: var(--cream-soft);
  transition: color 0.18s ease;
}

.colophon nav a:hover {
  color: #ffffff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.colophon-base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 18px;
  padding: 18px 0 26px;
  border-top: 1px solid var(--line-stage);
  color: var(--cream-muted);
  font-size: 13px;
}

.colophon-base a {
  color: var(--cream-soft);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: rgba(255, 246, 234, 0.35);
}

.colophon-base a:hover {
  color: #ffffff;
}

/* ============================================================================
 * Zoom Preview Dialog (#preview-dialog)
 * ============================================================================ */
#preview-dialog {
  margin: auto;
  padding: 16px;
  width: min(94vw, 1180px);
  max-height: 93dvh;
  border-radius: var(--radius-xl);
  background: var(--paper-card);
  color: var(--ink-body);
  border: 1px solid var(--line-paper-strong);
  box-shadow: var(--shadow-float);
}

#preview-dialog::backdrop {
  background: rgba(44, 10, 22, 0.78);
  backdrop-filter: blur(4px);
}

.preview-dialog-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4px 12px;
  font-weight: 700;
  color: var(--ink-heading);
}

.preview-close {
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: var(--paper-subtle);
  border: 1px solid var(--line-paper-strong);
  font-size: 13px;
  font-weight: 600;
}

.preview-close:hover {
  background: var(--cherry);
  color: var(--cream);
  border-color: var(--cherry);
}

#preview-full-image {
  width: 100%;
  height: auto;
  max-height: 74dvh;
  object-fit: contain;
  border-radius: var(--radius-md);
}

#preview-dialog p {
  margin-top: 10px;
  font-size: 13px;
  color: var(--ink-soft);
}

/* ============================================================================
 * Responsive Breakpoints
 * ============================================================================ */
@media (max-width: 980px) {
  .cover-inner {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.85fr);
    gap: 24px;
  }

  .gallery-spread {
    grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.9fr);
  }

  .screening-grid {
    grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.25fr);
  }

  .setup-spread {
    gap: 28px;
  }
}

@media (max-width: 768px) {
  :root {
    --header: 60px;
  }

  .masthead-inner {
    gap: 10px;
  }

  .brand {
    margin-right: auto;
  }

  .brand-sub {
    display: none;
  }

  .site-nav {
    gap: 4px;
  }

  .menu-toggle:not([hidden]) + .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    padding: 12px var(--gutter) 16px;
    background: linear-gradient(165deg, var(--cherry-stage-top) 0%, var(--cherry-stage-deep) 100%);
    border-bottom: 1px solid var(--line-stage);
    box-shadow: 0 14px 30px rgba(32, 6, 15, 0.32);
  }

  .menu-toggle:not([hidden])[aria-expanded="false"] + .site-nav {
    display: none;
  }

  .site-nav a {
    padding: 10px 14px;
    border-radius: var(--radius-sm);
  }

  .nav-download {
    padding: 6px 12px;
    font-size: 12.5px;
  }

  .cover-wrap {
    padding-block: 26px 24px;
    gap: 20px;
  }

  .cover-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .cover h1 {
    font-size: clamp(2.1rem, 9.5vw, 3rem);
  }

  .press-art.studio-stage {
    min-height: 270px;
    aspect-ratio: 1.15;
    max-width: 340px;
    margin-inline: auto;
  }

  .press-mascot {
    height: min(86%, 245px);
  }

  .stage-seal {
    left: 2%;
    bottom: 6%;
  }

  .console-bar {
    padding: 12px 14px;
  }

  .console-shell {
    padding: 10px 14px 12px;
  }

  .terminal-platform {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }

  .copy-command {
    justify-self: start;
  }

  .section-intro {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .gallery-spread,
  .screening-grid,
  .setup-spread,
  .journal-spread,
  .capability-copy {
    grid-template-columns: minmax(0, 1fr);
  }

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

  .preview-tabs button {
    padding: 12px 14px 12px 16px;
  }

  .chapter-list {
    grid-template-columns: 1fr;
  }

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

  .colophon-top {
    grid-template-columns: 1fr 1fr;
  }

  .colophon-top > div {
    grid-column: 1 / -1;
  }
}

@media (max-width: 420px) {
  .preview-tabs {
    grid-template-columns: minmax(0, 1fr);
  }

  .cover-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .download-options {
    left: 0;
    right: 0;
    width: auto;
    min-width: 240px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media (forced-colors: active) {
  .action,
  .nav-download,
  .console,
  .showcase-window,
  .preview-tabs button,
  .faq,
  .book-list a,
  .journal-card,
  .menu-toggle {
    border: 1px solid ButtonText;
  }

  .preview-tabs button[aria-selected="true"],
  .terminal-tabs [aria-selected="true"] {
    outline: 2px solid Highlight;
    outline-offset: -3px;
  }
}
