/* ==========================================================================
   Lineola homepage (site/)
   Role variables of the approved static page (design/v2/site-home/styles.css).
   Colors, radii, spacing and strokes are wired to site/public/app-tokens.css,
   which scripts/gen-tokens.mjs generates from design/tokens.json. Values with
   no matching token (type scale, shadows, layout sizes, motion) stay here as
   local roles; they are listed in the task report.
   ========================================================================== */

:root {
  /* Surface & background roles */
  --bg-canvas: var(--l-color-canvas);
  --bg-surface: var(--l-color-paper);
  --bg-grouped: var(--l-color-surface-group);
  --bg-elevated: var(--l-color-paper);
  --bg-subtle: var(--l-color-surface-sub);
  --bg-hover: var(--l-color-surface-hover);
  --bg-active: var(--l-color-surface-pressed);
  --bg-header-glass: color-mix(in srgb, var(--l-color-canvas) 88%, transparent);
  --bg-code: color-mix(in srgb, var(--l-color-ink) 5.5%, transparent);
  --bg-parchment: var(--l-color-review);
  --bg-save-pill-active: color-mix(in srgb, var(--l-color-on-accent) 22%, transparent);

  /* Text & ink roles */
  --text-primary: var(--l-color-ink);
  --text-secondary: var(--l-color-ink-soft);
  --text-muted: var(--l-color-ink-muted);
  --text-on-accent: var(--l-color-on-accent);

  /* Brand & accent roles */
  --accent-primary: var(--l-color-accent);
  --accent-hover: var(--l-color-accent-pressed);
  --accent-subtle: var(--l-color-accent-tint);
  --accent-border: color-mix(in srgb, var(--l-color-accent) 26%, transparent);
  --accent-focus-ring: color-mix(in srgb, var(--l-color-accent) 22%, transparent);
  --accent-warm: var(--l-color-logo-mark);
  --accent-warm-subtle: color-mix(in srgb, var(--l-color-logo-mark) 12%, transparent);

  /* Semantic status roles */
  --status-success: var(--l-color-ok-ink);
  --status-success-bg: var(--l-color-ok-tint);
  --status-success-border: color-mix(in srgb, var(--l-color-ok-ink) 28%, transparent);
  --status-warning: var(--l-color-review-ink);
  --status-warning-bg: var(--l-color-review);
  --status-warning-border: color-mix(in srgb, var(--l-color-review-line) 30%, transparent);
  --status-danger: var(--l-color-danger-ink);
  --status-danger-bg: var(--l-color-danger-tint);
  --status-danger-border: color-mix(in srgb, var(--l-color-danger-ink) 28%, transparent);
  --diff-added-bg: var(--l-color-ok-tint);
  --diff-conflict-bg: var(--l-color-review);

  /* Border & divider roles */
  --border-hairline: var(--l-color-line);
  --border-subtle: var(--l-color-edge);
  --border-strong: var(--l-color-edge-field);

  /* Elevation & shadow roles (color from --l-color-shadow) */
  --shadow-xs: 0 1px 2px color-mix(in srgb, var(--l-color-shadow) 5%, transparent);
  --shadow-sm: 0 2px 8px color-mix(in srgb, var(--l-color-shadow) 7%, transparent),
    0 1px 2px color-mix(in srgb, var(--l-color-shadow) 5%, transparent);
  --shadow-md: 0 12px 32px color-mix(in srgb, var(--l-color-shadow) 10%, transparent),
    0 2px 6px color-mix(in srgb, var(--l-color-shadow) 6%, transparent);
  --shadow-lg: 0 24px 56px color-mix(in srgb, var(--l-color-shadow) 13%, transparent),
    0 4px 14px color-mix(in srgb, var(--l-color-shadow) 7%, transparent);
  --shadow-focus: 0 0 0 3px var(--accent-focus-ring);

  /* Typography families */
  --font-sans: var(--l-font-sans);
  --font-mono: var(--l-font-mono);

  /* Typography scale */
  --code-inline-size: 0.875em;
  --text-2xs: 0.6875rem;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-md: 1.0625rem;
  --text-lg: 1.1875rem;
  --text-xl: 1.375rem;
  --text-2xl: 1.75rem;
  --text-3xl: clamp(1.875rem, 3vw, 2.5rem);
  --text-display: clamp(2.375rem, 4.5vw, 3.625rem);
  --text-price: clamp(2.25rem, 3.6vw, 3rem);

  /* Line heights & tracking */
  --leading-tight: 1.12;
  --leading-snug: 1.28;
  --leading-normal: 1.55;
  --leading-relaxed: 1.65;
  --tracking-tight: -0.025em;
  --tracking-snug: -0.015em;
  --tracking-normal: 0em;
  --tracking-wide: 0.04em;
  --tracking-eyebrow: 0.07em;

  /* Font weights */
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;
  --weight-extrabold: 800;

  /* Spacing scale (token steps where the token set has one) */
  --space-0: var(--l-space-s0);
  --space-0-5: 0.125rem;
  --space-1: var(--l-space-s1);
  --space-1-5: 0.375rem;
  --space-2: var(--l-space-s2);
  --space-2-5: 0.625rem;
  --space-3: var(--l-space-s3);
  --space-3-5: 0.875rem;
  --space-4: var(--l-space-s4);
  --space-5: var(--l-space-s5);
  --space-6: var(--l-space-s6);
  --space-7: 1.75rem;
  --space-8: var(--l-space-s8);
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-14: 3.5rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Border radius scale */
  --radius-xs: var(--l-radius-small);
  --radius-sm: var(--l-radius-field);
  --radius-md: var(--l-radius-card);
  --radius-lg: var(--l-radius-group);
  --radius-xl: var(--l-radius-share-sheet);
  --radius-2xl: var(--l-radius-sheet);
  --radius-pill: var(--l-radius-pill);

  /* Stroke & layout dimensions */
  --stroke-thin: var(--l-stroke-hairline);
  --stroke-medium: var(--l-stroke-radio);
  --stroke-thick: var(--l-stroke-thick);
  --container-max: 74rem;
  --container-narrow: 48rem;
  --prose-measure: 62ch;
  --prose-compact: 50ch;
  --header-height: 4.25rem;
  --icon-xs: 0.875rem;
  --icon-sm: 1rem;
  --icon-md: 1.125rem;
  --icon-lg: 1.25rem;
  --icon-xl: 1.5rem;
  --dot-sm: 0.5rem;
  --dot-md: 0.625rem;
  --control-height: 2.875rem;
  --control-height-sm: 2.25rem;
  --turnstile-width: 18.75rem;
  --checkbox-size: 1.125rem;
  --lockup-width: 8.5rem;
  --lockup-height: 2.25rem;
  --lockup-font-size: 43px;
  --lockup-tracking: -1px;
  --sidebar-width: 12.5rem;
  --notelist-width: 16.5rem;
  --showcase-min-height: 27rem;

  /* Motion & layering */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --duration-fast: 140ms;
  --duration-normal: 220ms;
  --z-base: 1;
  --z-sticky: 40;
  --z-popover: 60;
}

/* ==========================================================================
   Self-hosted variable fonts (Nunito Sans + IBM Plex Mono)
   ========================================================================== */

@font-face {
  font-family: "Nunito Sans";
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url("/fonts/nunito-sans-vietnamese-wght-normal.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}

@font-face {
  font-family: "Nunito Sans";
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url("/fonts/nunito-sans-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2");
}

@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2");
}

/* ==========================================================================
   Base & Reset
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  color-scheme: light;
}

html[data-theme="light"] {
  color-scheme: light;
}

html[data-theme="dark"] {
  color-scheme: dark;
}

body {
  margin: var(--space-0);
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  font-weight: var(--weight-regular);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

a {
  color: var(--accent-primary);
  text-decoration: underline;
  text-underline-offset: var(--space-1);
  transition: color var(--duration-fast) var(--ease-out);
}

a:hover {
  color: var(--accent-hover);
}

button,
input {
  font: inherit;
  color: inherit;
}

code {
  font-family: var(--font-mono);
  font-size: var(--code-inline-size);
  background-color: var(--bg-code);
  padding: var(--space-0-5) var(--space-1-5);
  border-radius: var(--radius-xs);
  border: var(--stroke-thin) solid var(--border-hairline);
}

:focus-visible {
  outline: var(--stroke-thick) solid var(--accent-primary);
  outline-offset: var(--space-0-5);
}

[hidden] {
  display: none !important;
}

.skip-link {
  position: absolute;
  top: var(--space-2);
  left: var(--space-4);
  z-index: var(--z-popover);
  padding: var(--space-2) var(--space-4);
  background: var(--bg-surface);
  color: var(--text-primary);
  border: var(--stroke-thin) solid var(--border-strong);
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: var(--weight-semibold);
  transform: translateY(-200%);
  transition: transform var(--duration-fast) var(--ease-out);
}

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

/* ==========================================================================
   Icons (Material Symbols Rounded inline SVGs)
   ========================================================================== */

.icon {
  width: var(--icon-md);
  height: var(--icon-md);
  fill: currentColor;
  flex-shrink: 0;
}

.icon-xs {
  width: var(--icon-xs);
  height: var(--icon-xs);
}

.icon-sm {
  width: var(--icon-sm);
  height: var(--icon-sm);
}

.icon-lg {
  width: var(--icon-lg);
  height: var(--icon-lg);
}

.icon-xl {
  width: var(--icon-xl);
  height: var(--icon-xl);
}

/* ==========================================================================
   Layout Containers & Section Rhythm
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-6);
}

.section {
  padding-block: var(--space-20);
  border-top: var(--stroke-thin) solid var(--border-hairline);
}

.section-tinted {
  background-color: var(--bg-grouped);
}

.section-header {
  max-width: var(--prose-measure);
  margin-bottom: var(--space-12);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin: var(--space-0) var(--space-0) var(--space-3);
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--accent-primary);
}

.section-title {
  margin: var(--space-0) var(--space-0) var(--space-4);
  font-size: var(--text-3xl);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.section-lead {
  margin: var(--space-0);
  font-size: var(--text-lg);
  line-height: var(--leading-relaxed);
  color: var(--text-secondary);
  max-width: var(--prose-measure);
}

/* ==========================================================================
   Sticky Header & Navigation
   ========================================================================== */

.site-header {
  position: sticky;
  top: var(--space-0);
  z-index: var(--z-sticky);
  height: var(--header-height);
  background-color: var(--bg-header-glass);
  backdrop-filter: blur(var(--space-3));
  -webkit-backdrop-filter: blur(var(--space-3));
  border-bottom: var(--stroke-thin) solid var(--border-hairline);
}

.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

.brand-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--text-primary);
}

.brand-lockup {
  width: var(--lockup-width);
  height: var(--lockup-height);
  overflow: visible;
  color: var(--text-primary);
}

.logo-ring {
  display: none;
}

:root[data-theme="dark"] .logo-ring {
  display: inline;
}

.brand-lockup-wordmark {
  fill: var(--text-primary);
  font-family: var(--font-sans);
  font-size: var(--lockup-font-size);
  font-weight: var(--weight-extrabold);
  letter-spacing: var(--lockup-tracking);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-6);
}

.nav-link {
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
  text-decoration: none;
  padding: var(--space-1-5) var(--space-2);
  border-radius: var(--radius-xs);
  transition: color var(--duration-fast) var(--ease-out), background-color var(--duration-fast) var(--ease-out);
}

.nav-link:hover {
  color: var(--text-primary);
  background-color: var(--bg-hover);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  padding: var(--space-0-5);
  background-color: var(--bg-subtle);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-pill);
}

.theme-btn {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  padding: var(--space-1) var(--space-2-5);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: background-color var(--duration-fast) var(--ease-out), color var(--duration-fast) var(--ease-out);
}

.theme-btn:hover {
  color: var(--text-primary);
}

.theme-btn[aria-pressed="true"] {
  background-color: var(--bg-surface);
  color: var(--text-primary);
  box-shadow: var(--shadow-xs);
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: var(--control-height);
  padding: var(--space-2-5) var(--space-5);
  border-radius: var(--radius-pill);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  text-decoration: none;
  cursor: pointer;
  border: var(--stroke-thin) solid transparent;
  transition: background-color var(--duration-fast) var(--ease-out), border-color var(--duration-fast) var(--ease-out), color var(--duration-fast) var(--ease-out), transform var(--duration-fast) var(--ease-out);
}

.btn:active {
  transform: translateY(var(--stroke-thin));
}

.btn-sm {
  min-height: var(--control-height-sm);
  padding: var(--space-1-5) var(--space-4);
  font-size: var(--text-xs);
}

.btn-primary {
  background-color: var(--accent-primary);
  color: var(--text-on-accent);
  box-shadow: var(--shadow-xs);
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  color: var(--text-on-accent);
}

.btn-secondary {
  background-color: var(--bg-surface);
  color: var(--text-primary);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  background-color: var(--bg-hover);
  color: var(--text-primary);
}

.btn-subtle {
  background-color: var(--accent-subtle);
  color: var(--accent-primary);
  border-color: var(--accent-border);
}

.btn-subtle:hover {
  background-color: var(--bg-hover);
  color: var(--accent-hover);
}

.btn-block {
  width: 100%;
}

/* ==========================================================================
   Hero Section & Dual-Screen App Showcase
   ========================================================================== */

.hero {
  padding-top: var(--space-14);
  padding-bottom: var(--space-20);
}

.hero-top {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: var(--space-10);
  align-items: end;
  margin-bottom: var(--space-12);
}

.hero-status-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-3-5);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
  margin-bottom: var(--space-5);
  box-shadow: var(--shadow-xs);
}

.status-dot {
  width: var(--dot-sm);
  height: var(--dot-sm);
  border-radius: var(--radius-pill);
  background-color: var(--accent-warm);
}

.status-dot-online {
  background-color: var(--status-success);
}

.hero-title {
  margin: var(--space-0);
  font-size: var(--text-display);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.hero-summary-col {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.hero-lead {
  margin: var(--space-0);
  font-size: var(--text-lg);
  line-height: var(--leading-relaxed);
  color: var(--text-secondary);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

.hero-meta-note {
  margin: var(--space-0);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* ==========================================================================
   Hero Desktop Application Showcase (Accurate Lineola v2 Design)
   ========================================================================== */

.app-showcase-frame {
  margin: var(--space-0);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  transition: box-shadow var(--duration-normal) var(--ease-out);
}

.app-showcase-img {
  width: 100%;
  height: auto;
  display: block;
  user-select: none;
  -webkit-user-select: none;
}

:root[data-theme="dark"] .app-showcase-img {
  content: url("/app-desktop-dark.png");
  content: image-set(url("/app-desktop-dark.png") 1x, url("/app-desktop-dark@2x.png") 2x);
}

:root[data-theme="light"] .app-showcase-img {
  content: url("/app-desktop-light.png");
  content: image-set(url("/app-desktop-light.png") 1x, url("/app-desktop-light@2x.png") 2x);
}

.app-showcase {
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.showcase-window-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-5);
  background-color: var(--bg-grouped);
  border-bottom: var(--stroke-thin) solid var(--border-hairline);
}

.showcase-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2-5);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  color: var(--text-primary);
}

.showcase-brand-icon {
  width: var(--icon-lg);
  height: var(--icon-lg);
  border-radius: var(--radius-xs);
}

.showcase-sync-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  background-color: var(--status-success-bg);
  border: var(--stroke-thin) solid var(--status-success-border);
  color: var(--status-success);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
}

.showcase-workspace {
  display: grid;
  grid-template-columns: var(--sidebar-width) var(--notelist-width) 1fr;
  min-height: var(--showcase-min-height);
}

/* Pane 1: Navigation Rail / Tags */

.showcase-sidebar {
  background-color: var(--bg-grouped);
  border-right: var(--stroke-thin) solid var(--border-hairline);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-6);
}

.sidebar-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.sidebar-heading {
  margin: var(--space-3) var(--space-2) var(--space-1);
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  text-transform: uppercase;
  letter-spacing: var(--tracking-eyebrow);
  color: var(--text-muted);
}

.sidebar-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-2-5);
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
}

.sidebar-item-active {
  background-color: var(--accent-subtle);
  color: var(--accent-primary);
}

.sidebar-item-nested {
  padding-left: var(--space-6);
}

.sidebar-count {
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  color: var(--text-muted);
}

.sidebar-device-card {
  padding: var(--space-2-5) var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-hairline);
  font-size: var(--text-2xs);
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.sidebar-device-title {
  font-weight: var(--weight-bold);
  color: var(--text-primary);
}

/* Pane 2: Notes List (L01) */

.showcase-notelist {
  background-color: var(--bg-canvas);
  border-right: var(--stroke-thin) solid var(--border-hairline);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.notelist-search-bar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.notelist-chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1-5);
}

.mini-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-0-5) var(--space-2);
  border-radius: var(--radius-pill);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  color: var(--text-secondary);
}

.mini-chip-active {
  background-color: var(--accent-primary);
  border-color: var(--accent-primary);
  color: var(--text-on-accent);
}

.notelist-section-label {
  display: flex;
  align-items: center;
  gap: var(--space-1-5);
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  text-transform: uppercase;
  letter-spacing: var(--tracking-eyebrow);
  color: var(--text-muted);
  margin-top: var(--space-1);
}

.note-preview-card {
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-hairline);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.note-preview-card-selected {
  border-color: var(--accent-border);
  background-color: var(--bg-surface);
  box-shadow: var(--shadow-xs);
}

.note-preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
}

.note-preview-title {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  color: var(--text-primary);
}

.note-preview-time {
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  color: var(--text-muted);
}

.note-preview-snippet {
  margin: var(--space-0);
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: var(--leading-snug);
}

.note-preview-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
  margin-top: var(--space-1);
}

.tag-pill {
  display: inline-flex;
  align-items: center;
  padding: var(--space-0-5) var(--space-2);
  border-radius: var(--radius-pill);
  background-color: var(--accent-subtle);
  color: var(--accent-primary);
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
}

/* Pane 3: Editor (E02 / E04) */

.showcase-editor {
  background-color: var(--bg-surface);
  padding: var(--space-6) var(--space-8);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-6);
}

.editor-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding-bottom: var(--space-3);
  border-bottom: var(--stroke-thin) solid var(--border-hairline);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.editor-status-group {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  color: var(--text-secondary);
}

.editor-document {
  display: flex;
  flex-direction: column;
  gap: var(--space-3-5);
}

.editor-heading-row {
  display: flex;
  align-items: baseline;
  gap: var(--space-2-5);
}

.md-gutter-mark {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  color: var(--text-muted);
  background-color: var(--bg-subtle);
  padding: var(--space-0-5) var(--space-1-5);
  border-radius: var(--radius-xs);
  flex-shrink: 0;
}

.editor-doc-title {
  margin: var(--space-0);
  font-size: var(--text-xl);
  font-weight: var(--weight-extrabold);
  letter-spacing: var(--tracking-snug);
  color: var(--text-primary);
}

.editor-doc-p {
  margin: var(--space-0);
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: var(--text-secondary);
}

.wikilink-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-0-5) var(--space-2);
  border-radius: var(--radius-xs);
  background-color: var(--accent-subtle);
  border: var(--stroke-thin) solid var(--accent-border);
  color: var(--accent-primary);
  font-weight: var(--weight-semibold);
  font-size: var(--text-xs);
}

.editor-checklist {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-canvas);
  border: var(--stroke-thin) solid var(--border-hairline);
}

.check-row {
  display: flex;
  align-items: center;
  gap: var(--space-2-5);
  font-size: var(--text-xs);
  color: var(--text-primary);
}

.check-row-done {
  color: var(--text-muted);
  text-decoration: line-through;
}

.check-box {
  width: var(--icon-sm);
  height: var(--icon-sm);
  border-radius: var(--radius-xs);
  border: var(--stroke-medium) solid var(--border-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.check-box-checked {
  background-color: var(--accent-primary);
  border-color: var(--accent-primary);
  color: var(--text-on-accent);
}

.editor-attachment-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-2-5) var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-grouped);
  border: var(--stroke-thin) solid var(--border-subtle);
  font-size: var(--text-xs);
}

.attachment-meta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
}

.attachment-size {
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  color: var(--text-muted);
}

.editor-toolbar {
  display: flex;
   flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding-top: var(--space-3);
  border-top: var(--stroke-thin) solid var(--border-hairline);
}

.toolbar-tools {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1-5);
}

.toolbar-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2-5);
  border-radius: var(--radius-xs);
  background-color: var(--bg-grouped);
  border: var(--stroke-thin) solid var(--border-hairline);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
}

/* ==========================================================================
   Three Core Promises Ledger Strip
   ========================================================================== */

.promises-strip {
  padding-block: var(--space-12);
  background-color: var(--bg-grouped);
  border-top: var(--stroke-thin) solid var(--border-subtle);
  border-bottom: var(--stroke-thin) solid var(--border-subtle);
}

.promises-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-8);
}

.promise-item {
  display: flex;
  flex-direction: column;
  gap: var(--space-2-5);
  padding-right: var(--space-4);
}

.promise-index {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--accent-primary);
}

.promise-title {
  margin: var(--space-0);
  font-size: var(--text-lg);
  font-weight: var(--weight-extrabold);
  letter-spacing: var(--tracking-snug);
  color: var(--text-primary);
}

.promise-body {
  margin: var(--space-0);
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: var(--text-secondary);
}

/* ==========================================================================
   Four Feature Rows (01 Write, 02 Find, 03 Connect, 04 Keep)
   ========================================================================== */

.feature-rows {
  display: flex;
  flex-direction: column;
  gap: var(--space-16);
}

.feature-row {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: var(--space-12);
  align-items: center;
  padding-top: var(--space-12);
  border-top: var(--stroke-thin) solid var(--border-hairline);
}

.feature-row:first-child {
  padding-top: var(--space-0);
  border-top: none;
}

.feature-copy {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  max-width: var(--prose-compact);
}

.feature-title {
  margin: var(--space-0);
  font-size: var(--text-2xl);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-tight);
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.feature-body {
  margin: var(--space-0);
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: var(--text-secondary);
}

.feature-points {
  margin: var(--space-2) var(--space-0) var(--space-0);
  padding: var(--space-0);
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-2-5);
}

.feature-point {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2-5);
  font-size: var(--text-sm);
  color: var(--text-primary);
}

.feature-point .icon {
  color: var(--accent-primary);
  margin-top: var(--space-0-5);
}

.scene-card {
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.scene-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-bottom: var(--space-3);
  border-bottom: var(--stroke-thin) solid var(--border-hairline);
}

.scene-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1) var(--space-2-5);
  border-radius: var(--radius-pill);
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  background-color: var(--bg-subtle);
  color: var(--text-secondary);
  border: var(--stroke-thin) solid var(--border-hairline);
  white-space: nowrap;
  flex-shrink: 0;
}

.badge-accent {
  background-color: var(--accent-subtle);
  color: var(--accent-primary);
  border-color: var(--accent-border);
}

.badge-success {
  background-color: var(--status-success-bg);
  color: var(--status-success);
  border-color: var(--status-success-border);
}

.badge-warning {
  background-color: var(--status-warning-bg);
  color: var(--status-warning);
  border-color: var(--status-warning-border);
}

/* Scene 01: Offline writing + Trash notice */

.scene-trash-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-2-5) var(--space-3-5);
  border-radius: var(--radius-md);
  background-color: var(--bg-grouped);
  border: var(--stroke-thin) solid var(--border-hairline);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}

/* Scene 02: Interactive Search & Accent-Insensitive Matching */

.search-demo-controls {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.search-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input-icon {
  position: absolute;
  left: var(--space-3-5);
  color: var(--text-muted);
  pointer-events: none;
}

.search-demo-input {
  width: 100%;
  height: var(--control-height);
  padding-left: var(--space-10);
  padding-right: var(--space-16);
  border-radius: var(--radius-md);
  border: var(--stroke-medium) solid var(--border-strong);
  background-color: var(--bg-canvas);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-primary);
}

.search-demo-input:focus {
  border-color: var(--accent-primary);
  outline: none;
  box-shadow: var(--shadow-focus);
}

.search-clear-btn {
  position: absolute;
  right: var(--space-2);
  appearance: none;
  border: var(--stroke-thin) solid var(--border-subtle);
  background-color: var(--bg-surface);
  color: var(--text-secondary);
  border-radius: var(--radius-xs);
  padding: var(--space-1) var(--space-2);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  cursor: pointer;
}

.search-preset-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1-5);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.preset-btn {
  appearance: none;
  border: var(--stroke-thin) solid var(--border-subtle);
  background-color: var(--bg-grouped);
  color: var(--text-primary);
  border-radius: var(--radius-xs);
  padding: var(--space-0-5) var(--space-2);
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  cursor: pointer;
  transition: background-color var(--duration-fast) var(--ease-out), border-color var(--duration-fast) var(--ease-out);
}

.preset-btn:hover {
  background-color: var(--accent-subtle);
  border-color: var(--accent-border);
  color: var(--accent-primary);
}

.search-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
}

.filter-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1-5);
}

.filter-chip-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2-5);
  border-radius: var(--radius-pill);
  border: var(--stroke-thin) solid var(--border-subtle);
  background-color: var(--bg-canvas);
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  cursor: pointer;
}

.filter-chip-btn[aria-pressed="true"] {
  background-color: var(--accent-primary);
  border-color: var(--accent-primary);
  color: var(--text-on-accent);
}

.search-count-label {
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  color: var(--text-muted);
}

.search-results-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-2-5);
}

.search-result-item {
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-canvas);
  border: var(--stroke-thin) solid var(--border-hairline);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.search-result-title {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  color: var(--text-primary);
}

.search-result-snippet {
  margin: var(--space-0);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}

.search-empty-state {
  padding: var(--space-6);
  text-align: center;
  border-radius: var(--radius-md);
  background-color: var(--bg-canvas);
  border: var(--stroke-thin) dashed var(--border-subtle);
  font-size: var(--text-sm);
  color: var(--text-secondary);
}

/* Scene 03: Wiki-links [[ & Backlinks */

.link-suggestion-box {
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-elevated);
  border: var(--stroke-thin) solid var(--border-strong);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: var(--space-1-5);
}

.suggestion-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-1-5) var(--space-2-5);
  border-radius: var(--radius-xs);
  font-size: var(--text-xs);
}

.suggestion-row-active {
  background-color: var(--accent-subtle);
  color: var(--accent-primary);
  font-weight: var(--weight-bold);
}

.backlinks-panel {
  padding: var(--space-3-5);
  border-radius: var(--radius-md);
  background-color: var(--bg-grouped);
  border: var(--stroke-thin) solid var(--border-hairline);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.backlinks-title {
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  text-transform: uppercase;
  letter-spacing: var(--tracking-eyebrow);
  color: var(--text-muted);
}

.backlink-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-2-5);
  border-radius: var(--radius-xs);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-hairline);
  font-size: var(--text-xs);
}

/* Scene 04: Conflict Copy Side-by-Side */

.conflict-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
}

.conflict-pane {
  padding: var(--space-3-5);
  border-radius: var(--radius-md);
  background-color: var(--bg-canvas);
  border: var(--stroke-thin) solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.conflict-pane-copy {
  border-color: var(--status-warning-border);
  background-color: var(--diff-conflict-bg);
}

.conflict-meta {
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  color: var(--text-muted);
}

.diff-line {
  padding: var(--space-1-5) var(--space-2);
  border-radius: var(--radius-xs);
  background-color: var(--diff-added-bg);
  font-size: var(--text-xs);
  color: var(--text-primary);
  font-weight: var(--weight-medium);
}

/* ==========================================================================
   Section 05: Ownership & AI Agents (Import, Export, MCP Controls)
   ========================================================================== */

.ownership-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: var(--space-8);
  align-items: stretch;
}

.ownership-stack {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.ownership-card {
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-7);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.ownership-card-mcp {
  border-color: var(--accent-border);
  box-shadow: var(--shadow-md);
  justify-content: space-between;
}

.card-title {
  margin: var(--space-0);
  font-size: var(--text-xl);
  font-weight: var(--weight-extrabold);
  letter-spacing: var(--tracking-snug);
  color: var(--text-primary);
}

.card-body {
  margin: var(--space-0);
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: var(--text-secondary);
}

.source-pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.source-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1-5) var(--space-3);
  border-radius: var(--radius-sm);
  background-color: var(--bg-grouped);
  border: var(--stroke-thin) solid var(--border-subtle);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
}

.mcp-preview-box {
  background-color: var(--bg-canvas);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.mcp-rule-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-2-5) var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-hairline);
  font-size: var(--text-xs);
}

.mcp-agent-name {
  font-weight: var(--weight-bold);
  color: var(--text-primary);
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}

.mcp-rule-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1-5);
}

.mcp-policy-guard {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2-5) var(--space-3);
  border-radius: var(--radius-md);
  background-color: var(--status-warning-bg);
  border: var(--stroke-thin) solid var(--status-warning-border);
  color: var(--status-warning);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
}

.mcp-activity-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-top: var(--space-2);
  border-top: var(--stroke-thin) solid var(--border-hairline);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}

/* ==========================================================================
   Section 06: Pricing (Two Plans Only: Free & Pro + Planned Strip)
   ========================================================================== */

.pricing-header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-6);
  margin-bottom: var(--space-10);
}

.billing-switch {
  display: inline-flex;
  align-items: center;
  padding: var(--space-1);
  border-radius: var(--radius-pill);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-strong);
  box-shadow: var(--shadow-xs);
}

.billing-option {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-pill);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  transition: background-color var(--duration-fast) var(--ease-out), color var(--duration-fast) var(--ease-out);
}

.billing-option[aria-pressed="true"] {
  background-color: var(--accent-primary);
  color: var(--text-on-accent);
}

.billing-save-pill {
  padding: var(--space-0-5) var(--space-2);
  border-radius: var(--radius-pill);
  background-color: var(--bg-parchment);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
}

.billing-option[aria-pressed="true"] .billing-save-pill {
  background-color: var(--bg-save-pill-active);
  color: var(--text-on-accent);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-8);
  align-items: stretch;
}

.plan-card {
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: var(--space-8);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-6);
}

.plan-card-pro {
  border-width: var(--stroke-thick);
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.plan-top {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.plan-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}

.plan-name {
  margin: var(--space-0);
  font-size: var(--text-2xl);
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.plan-price-block {
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
}

.plan-price {
  font-size: var(--text-price);
  font-weight: var(--weight-extrabold);
  letter-spacing: var(--tracking-tight);
  line-height: var(--leading-tight);
  color: var(--text-primary);
}

.plan-period {
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
}

.plan-billing-caption {
  margin: var(--space-0);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.plan-trial-box {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background-color: var(--accent-subtle);
  border: var(--stroke-thin) solid var(--accent-border);
  font-size: var(--text-xs);
  line-height: var(--leading-normal);
  color: var(--text-primary);
}

.plan-list-lead {
  margin: var(--space-0);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  color: var(--text-muted);
}

.plan-features {
  margin: var(--space-0);
  padding: var(--space-0);
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.plan-feature-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2-5);
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  color: var(--text-primary);
}

.plan-feature-item .icon {
  color: var(--accent-primary);
  margin-top: var(--space-0-5);
}

.pricing-footnote {
  margin: var(--space-6) var(--space-0) var(--space-0);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* Planned After Launch Horizontal Strip (Distinct from Pricing Cards) */

.planned-strip {
  margin-top: var(--space-10);
  padding: var(--space-6) var(--space-7);
  border-radius: var(--radius-xl);
  background-color: var(--bg-canvas);
  border: var(--stroke-thin) dashed var(--border-strong);
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: var(--space-8);
  align-items: center;
}

.planned-strip-intro {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.planned-strip-title {
  margin: var(--space-0);
  font-size: var(--text-lg);
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.planned-strip-sub {
  margin: var(--space-0);
  font-size: var(--text-sm);
  color: var(--text-secondary);
}

.planned-items-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
}

.planned-item-card {
  padding: var(--space-4);
  border-radius: var(--radius-lg);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-hairline);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.planned-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
}

.planned-item-name {
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  color: var(--text-primary);
}

.planned-item-desc {
  margin: var(--space-0);
  font-size: var(--text-xs);
  line-height: var(--leading-normal);
  color: var(--text-secondary);
}

/* ==========================================================================
   Section 07: Platforms Strip
   ========================================================================== */

.platforms-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-4);
}

.platform-card {
  padding: var(--space-5);
  border-radius: var(--radius-xl);
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-4);
}

.platform-card-planned {
  background-color: var(--bg-grouped);
  border-style: dashed;
}

.platform-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
}

.platform-name {
  margin: var(--space-0);
  font-size: var(--text-base);
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.platform-desc {
  margin: var(--space-1) var(--space-0) var(--space-0);
  font-size: var(--text-xs);
  line-height: var(--leading-normal);
  color: var(--text-secondary);
}

/* ==========================================================================
   Section 08: Waitlist Form
   ========================================================================== */

.waitlist-shell {
  max-width: var(--container-narrow);
  margin-inline: auto;
  background-color: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: var(--space-10);
  box-shadow: var(--shadow-md);
}

.waitlist-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
  margin-top: var(--space-6);
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  border: none;
  padding: var(--space-0);
  margin: var(--space-0);
}

.field-label {
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  color: var(--text-primary);
}

.field-hint {
  margin: var(--space-0);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.text-input {
  width: 100%;
  height: var(--control-height);
  padding-inline: var(--space-4);
  border-radius: var(--radius-md);
  border: var(--stroke-medium) solid var(--border-strong);
  background-color: var(--bg-canvas);
  font-size: var(--text-base);
  color: var(--text-primary);
}

.text-input:focus {
  border-color: var(--accent-primary);
  outline: none;
  box-shadow: var(--shadow-focus);
}

.platform-checkbox-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-2-5);
  margin-top: var(--space-1);
}

.checkbox-tile {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2-5) var(--space-3);
  border-radius: var(--radius-md);
  border: var(--stroke-thin) solid var(--border-strong);
  background-color: var(--bg-canvas);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  color: var(--text-primary);
  cursor: pointer;
  user-select: none;
  transition: border-color var(--duration-fast) var(--ease-out), background-color var(--duration-fast) var(--ease-out);
}

.checkbox-tile:hover {
  border-color: var(--accent-primary);
}

.checkbox-tile:has(.checkbox-input:checked) {
  border-color: var(--accent-primary);
  background-color: var(--accent-subtle);
}

.checkbox-input {
  width: var(--checkbox-size);
  height: var(--checkbox-size);
  accent-color: var(--accent-primary);
  margin: var(--space-0);
  cursor: pointer;
}

.turnstile-slot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background-color: var(--bg-grouped);
  border: var(--stroke-thin) dashed var(--border-strong);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}

.turnstile-slot-left {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
}

.turnstile-slot .cf-turnstile {
  flex: 1 1 var(--turnstile-width);
  min-width: 0;
  max-width: 100%;
}

.form-error {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background-color: var(--status-danger-bg);
  border: var(--stroke-thin) solid var(--status-danger-border);
  color: var(--status-danger);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
}

.consent-note {
  margin: var(--space-0);
  font-size: var(--text-xs);
  line-height: var(--leading-relaxed);
  color: var(--text-muted);
}

.waitlist-success {
  margin-top: var(--space-6);
  padding: var(--space-6);
  border-radius: var(--radius-xl);
  background-color: var(--status-success-bg);
  border: var(--stroke-thin) solid var(--status-success-border);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-3);
}

.waitlist-success-title {
  margin: var(--space-0);
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-lg);
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.waitlist-success-title .icon {
  color: var(--status-success);
}

.waitlist-success-body {
  margin: var(--space-0);
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: var(--text-primary);
}

.waitlist-success-meta {
  margin: var(--space-0);
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  color: var(--text-secondary);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  padding-block: var(--space-12);
  border-top: var(--stroke-thin) solid var(--border-subtle);
  background-color: var(--bg-grouped);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
}

.footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-tagline {
  margin: var(--space-0);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-5);
  font-size: var(--text-sm);
}

.footer-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: var(--weight-semibold);
}

.footer-link:hover {
  color: var(--text-primary);
  text-decoration: underline;
}

.footer-year {
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* ==========================================================================
   Responsive Breakpoints (1024px, 768px, 360px)
   ========================================================================== */

@media (max-width: 1080px) {
  .hero-top {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }

  .showcase-workspace {
    grid-template-columns: var(--notelist-width) 1fr;
  }

  .showcase-sidebar {
    display: none;
  }

  .feature-row,
  .ownership-grid,
  .planned-strip {
    grid-template-columns: 1fr;
  }

  .platforms-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 780px) {
  .site-nav {
    display: none;
  }

  .section {
    padding-block: var(--space-14);
  }

  .showcase-workspace {
    grid-template-columns: 1fr;
  }

  .showcase-notelist {
    border-right: none;
    border-bottom: var(--stroke-thin) solid var(--border-hairline);
  }

  .showcase-editor {
    padding: var(--space-5);
  }

  .promises-grid,
  .pricing-grid,
  .planned-items-grid,
  .search-results-grid,
  .conflict-grid {
    grid-template-columns: 1fr;
  }

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

  .platform-checkbox-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .waitlist-shell {
    padding: var(--space-6);
  }
}

@media (max-width: 640px) {
  /* Phones: cards and the app screenshot frame take the tightest field radius. */
  :root {
    --radius-xl: var(--l-radius-field);
    --radius-2xl: var(--l-radius-field);
  }

  .theme-toggle {
    display: none;
  }
}

@media (max-width: 480px) {
  .container {
    padding-inline: var(--space-4);
  }

  .platforms-grid,
  .platform-checkbox-grid {
    grid-template-columns: 1fr;
  }

  .plan-card {
    padding: var(--space-6);
  }
}

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

  *,
  *::before,
  *::after {
    transition-duration: 0ms !important;
    animation-duration: 0ms !important;
  }
}

/* ==========================================================================
   Privacy and waitlist result pages (same shell as the home page)
   ========================================================================== */

.header-link {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  text-decoration: none;
}

.header-link:hover {
  color: var(--accent-primary);
}

.page-head {
  max-width: var(--container-narrow);
  margin: var(--space-16) auto var(--space-8);
}

.page-head h1 {
  margin: var(--space-2) 0 0;
  font-family: var(--font-sans);
  font-size: var(--text-display);
  font-weight: var(--weight-extrabold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--text-primary);
}

.page-head .meta {
  margin: var(--space-3) 0 0;
  color: var(--text-muted);
  font-size: var(--text-sm);
}

.result-lead {
  margin: var(--space-4) 0 0;
  max-width: var(--prose-measure);
  color: var(--text-secondary);
  font-size: var(--text-lg);
  line-height: var(--leading-normal);
}

.prose {
  max-width: var(--container-narrow);
  margin: 0 auto var(--space-20);
  padding: var(--space-8);
  background: var(--bg-surface);
  border: var(--stroke-thin) solid var(--border-subtle);
  border-radius: var(--radius-2xl);
}

.prose h2 {
  margin: var(--space-8) 0 var(--space-2);
  font-size: var(--text-xl);
  font-weight: var(--weight-bold);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-snug);
  color: var(--text-primary);
}

.prose h2:first-child {
  margin-top: 0;
}

.prose p {
  margin: 0 0 var(--space-4);
  color: var(--text-secondary);
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
}

.prose p:last-child {
  margin-bottom: 0;
}

.prose a {
  color: var(--accent-primary);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.prose a:hover {
  color: var(--accent-hover);
}

.result-actions {
  max-width: var(--container-narrow);
  margin: 0 auto var(--space-20);
}

@media (max-width: 640px) {
  .prose {
    padding: var(--space-6);
  }

  .page-head {
    margin-top: var(--space-10);
  }
}
