/* PrismTabs marketing site — shared styles */

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

:root {
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial,
    sans-serif;
  --font-display: "Sora", var(--font-sans);
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono",
    monospace;
  --bg: #0a0b0d;
  --bg-elevated: #111318;
  --bg-card: #15171c;
  --bg-card-hover: #1a1d23;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #eef0f3;
  --text-muted: #a1a8b3;
  --text-dim: #6b7280;
  --accent-blue: #7fb1f7;
  --accent-purple: #b58cf2;
  --accent-pink: #f090c3;
  --accent-green: #6fcf9a;
  --focus-ring: #7fb1f7;
  --on-bright: #0a0b0d;
  --nav-bg: rgba(10, 11, 13, 0.82);
  --headline-from: #f5c451;
  --headline-via: #f28b6b;
  --headline-to: #ef86bd;
  --button-from: #f5c451;
  --button-to: #ef86bd;
  --warm-glow: rgba(242, 139, 107, 0.14);
  --warm-wash-from: rgba(245, 196, 81, 0.1);
  --warm-wash-to: rgba(239, 134, 189, 0.08);

  --preset-grey-l: #dadce0;
  --preset-grey-d: #5f6368;
  --preset-blue-l: #aecbfa;
  --preset-blue-d: #2e5c9c;
  --preset-red-l: #f6aea9;
  --preset-red-d: #9c3333;
  --preset-yellow-l: #fde293;
  --preset-yellow-d: #8a6d1d;
  --preset-green-l: #a8dab5;
  --preset-green-d: #2d6a4f;
  --preset-pink-l: #f7a8d2;
  --preset-pink-d: #9c3372;
  --preset-purple-l: #d3b3f5;
  --preset-purple-d: #5c3c9c;
  --preset-cyan-l: #99e3f5;
  --preset-cyan-d: #1d6e7a;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --shadow-card: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 12px 32px -16px rgba(0, 0, 0, 0.6);
  --max-width: 1120px;

  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg: #fafafa;
  --bg-elevated: #ffffff;
  --bg-card: #f2f3f5;
  --bg-card-hover: #e9eaed;
  --border: rgba(15, 17, 21, 0.08);
  --border-strong: rgba(15, 17, 21, 0.14);
  --text: #16181d;
  --text-muted: #52586a;
  --text-dim: #7b8191;
  --accent-blue: #2e6fd9;
  --accent-purple: #7c4fd6;
  --accent-pink: #c94b8e;
  --accent-green: #1f8f5f;
  --focus-ring: #2e6fd9;

  --shadow-card: 0 1px 0 rgba(255, 255, 255, 0.6) inset, 0 12px 32px -18px rgba(15, 17, 21, 0.22);
  --on-bright: #ffffff;
  --nav-bg: rgba(250, 250, 250, 0.82);
  --headline-from: #b26f0a;
  --headline-via: #cf4a34;
  --headline-to: #c23c86;
  --button-from: #b8481f;
  --button-to: #c23c86;
  --warm-glow: rgba(245, 196, 81, 0.14);
  --warm-wash-from: rgba(245, 196, 81, 0.16);
  --warm-wash-to: rgba(239, 134, 189, 0.1);

  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  margin: 0;
  overflow-x: clip;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
.brand {
  font-family: var(--font-display);
}

h1,
h2 {
  line-height: 1.2;
}

.mono {
  font-family: var(--font-mono);
}

a {
  color: inherit;
}

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

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Nav ---------- */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--border);
}

/*
 * Blur lives on a pseudo-element rather than .site-nav itself: backdrop-filter
 * establishes a containing block for fixed-position descendants, which would
 * trap the mobile .nav-links panel inside this 68px header instead of the
 * viewport.
 */
.site-nav::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.site-nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: var(--text);
}

.brand-mark {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}

.brand-logo {
  height: 28px;
  width: auto;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  font-size: 15px;
}

.nav-links a:not(.btn) {
  position: relative;
  font-weight: 500;
  text-decoration: none;
  color: var(--text-muted);
  transition: color 0.15s ease;
}

/* Amber-to-pink underline, drawn from the left on hover and kept on the current page. */
.nav-links a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--headline-from), var(--headline-to));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

.nav-links a:not(.btn):hover,
.nav-links a:not(.btn):focus-visible,
.nav-links a[aria-current="page"] {
  color: var(--text);
}

.nav-links a:not(.btn):hover::after,
.nav-links a:not(.btn):focus-visible::after,
.nav-links a[aria-current="page"]::after {
  transform: scaleX(1);
}

.nav-links .btn {
  margin-left: 8px;
  padding: 5px 14px;
  font-size: 14px;
}

.site-nav a:focus-visible,
.site-nav button:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 4px;
  border-radius: var(--radius-sm);
}

/* Wide enough offset that the underline sits inside the ring instead of crossing it. */
.nav-links a:not(.btn):focus-visible {
  outline-offset: 8px;
}

.nav-links .btn:focus-visible {
  border-radius: 999px;
}

@media (prefers-reduced-motion: reduce) {
  .nav-links a:not(.btn),
  .nav-links a:not(.btn)::after {
    transition: none;
  }
}

.nav-toggle {
  display: none;
}

/* ---------- Theme toggle ---------- */

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin-left: 16px;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  flex-shrink: 0;
}

.theme-toggle:hover {
  color: var(--text);
  background: var(--bg-card);
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
  display: none;
}

:root[data-theme="dark"] .theme-toggle .icon-sun,
:root:not([data-theme]) .theme-toggle .icon-sun {
  display: block;
}

:root[data-theme="light"] .theme-toggle .icon-moon {
  display: block;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--button-from), var(--button-to));
  color: var(--on-bright);
}

.btn-primary:hover {
  opacity: 0.92;
}

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

.btn-secondary:hover {
  background: var(--bg-card);
}

/* ---------- Hero ---------- */

.hero {
  padding: 96px 0 72px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -220px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 500px;
  background: radial-gradient(closest-side, var(--warm-glow), transparent 70%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
}

.hero-grid > div:first-child {
  max-width: 640px;
}

.hero h1 {
  font-size: clamp(2.4rem, 4.4vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 20px;
}

.hero h1 .grad {
  background: linear-gradient(135deg, var(--headline-from), var(--headline-via) 55%, var(--headline-to));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p.lead {
  font-size: 18px;
  color: var(--text-muted);
  max-width: 46ch;
  margin: 0 0 32px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.hero-note {
  font-size: 13.5px;
  color: var(--text-dim);
}

.hero-note code {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 12.5px;
}

/* ---------- Screenshots ---------- */

.hero-shot {
  margin-top: 52px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.hero-shot img {
  width: 100%;
  height: auto;
}

/* Theme-matched screenshot: dark by default, light only when the light
   theme is explicitly set. The inline <head> script always stamps
   data-theme before first paint, so only one ever renders. */
.hero-shot img.hero-shot-dark {
  display: block;
}

.hero-shot img.hero-shot-light {
  display: none;
}

:root[data-theme="light"] .hero-shot img.hero-shot-dark {
  display: none;
}

:root[data-theme="light"] .hero-shot img.hero-shot-light {
  display: block;
}

.section-shot {
  margin: 44px auto 0;
  max-width: 820px;
}

.section-shot img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
}

.section-shot figcaption {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-dim);
  text-align: center;
}

/* ---------- Sections ---------- */

section {
  padding: 88px 0;
}

section.tight {
  padding: 64px 0;
}

/* The closing CTA band follows directly, so the section's own bottom padding would double up. */
#pricing {
  padding-bottom: 32px;
}

.section-head {
  max-width: 640px;
  margin: 0 0 48px;
}

.section-head .kicker {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-blue);
  margin-bottom: 10px;
}

.section-head h2 {
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  letter-spacing: -0.015em;
  margin: 0 0 12px;
  text-wrap: balance;
}

.section-head--center {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.section-head--center .kicker {
  justify-content: center;
}

.section-head p {
  color: var(--text-muted);
  font-size: 16.5px;
  margin: 0;
}

.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 0;
}

/* ---------- Feature grid ---------- */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.feature-card:hover {
  border-color: var(--border-strong);
  background: var(--bg-card-hover);
}

.feature-card h3 {
  font-size: 16.5px;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tier-tag {
  display: inline-block;
  vertical-align: middle;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: 999px;
  margin-left: 4px;
}

.tier-tag--free {
  background: rgba(111, 207, 154, 0.15);
  color: var(--accent-green);
}

.tier-tag--pro {
  background: rgba(181, 140, 242, 0.15);
  color: var(--accent-purple);
}

.feature-card p {
  font-size: 14.5px;
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Palette strip ---------- */

.palette-strip {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.palette-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  font-size: 13px;
  color: var(--text-muted);
}

.palette-chip .dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.3);
}

/* ---------- Steps ---------- */

.steps {
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.step {
  position: relative;
  padding-top: 8px;
}

.step::before {
  counter-increment: step;
  content: counter(step);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-blue);
  margin-bottom: 16px;
}

.step h3 {
  font-size: 15.5px;
  margin: 0 0 8px;
}

.step p {
  font-size: 14.5px;
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Pricing ---------- */

.pricing-card {
  max-width: 460px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 36px;
  text-align: center;
  box-shadow: var(--shadow-card);
}

.pricing-card .plan-name {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-purple);
  font-weight: 700;
  margin-bottom: 10px;
}

.pricing-card .plan-price {
  font-size: 2.4rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.pricing-card .plan-price small {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dim);
}

.pricing-card .plan-price-split {
  display: flex;
  flex-direction: column;
  margin-bottom: 4px;
}

.plan-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 2px;
  border-bottom: 1px solid var(--border-strong);
}

.plan-price-row:first-child {
  border-top: 1px solid var(--border-strong);
}

.plan-price-row .ppr-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-dim);
}

.plan-price-row .ppr-amount {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  white-space: nowrap;
  text-align: right;
}

.plan-price-row .ppr-amount small {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-dim);
  letter-spacing: 0;
}

.pricing-card .plan-note {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 28px;
}

.plan-features {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.plan-features li {
  display: flex;
  gap: 10px;
  font-size: 14.5px;
  color: var(--text);
}

.plan-features li svg {
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--accent-green);
}

/* ---------- Trial timeline ---------- */

.trial-timeline {
  list-style: none;
  padding: 0;
  margin: 0 auto 44px;
  max-width: 940px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.trial-timeline li {
  position: relative;
}

.trial-timeline li::after {
  content: "";
  position: absolute;
  top: 6px;
  left: 20px;
  right: -24px;
  height: 1px;
  background: var(--border-strong);
}

.trial-timeline li:last-child::after {
  display: none;
}

.tl-dot {
  display: block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  margin-bottom: 16px;
}

.tl-dot--pro {
  background: var(--accent-purple);
  border-color: var(--accent-purple);
  box-shadow: 0 0 0 4px rgba(181, 140, 242, 0.18);
}

.tl-when {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--accent-blue);
  margin-bottom: 6px;
}

.trial-timeline h3 {
  font-size: 15.5px;
  margin: 0 0 6px;
  letter-spacing: -0.01em;
}

.trial-timeline p {
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  max-width: 820px;
  margin: 0 auto;
  align-items: stretch;
}

.pricing-grid .pricing-card {
  max-width: none;
  margin: 0;
}

/* The feature list is the card's last child, so it needs no bottom margin of its own. */
.pricing-grid .plan-features {
  margin-bottom: 0;
}

.pricing-card-featured {
  position: relative;
  border-color: var(--accent-purple);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 16px 40px -18px rgba(181, 140, 242, 0.35);
}

.plan-badge {
  position: absolute;
  top: -11px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  background: var(--accent-purple);
  color: var(--on-bright);
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.03em;
  padding: 6px 12px;
  border-radius: 999px;
}

.pricing-fineprint {
  max-width: 620px;
  margin: 32px auto 0;
  text-align: center;
  font-size: 13.5px;
  color: var(--text-dim);
}

.pricing-fineprint + .pricing-fineprint {
  margin-top: 12px;
}

/* ---------- Compat / logos row ---------- */

.compat-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.compat-pill {
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  font-size: 13.5px;
  color: var(--text-muted);
}

/* ---------- CTA band ---------- */

.cta-band {
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--warm-wash-from), var(--warm-wash-to));
  padding: 56px;
  text-align: center;
}

.cta-band h2 {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  margin: 0 0 12px;
  letter-spacing: -0.015em;
}

.cta-band p {
  color: var(--text-muted);
  margin: 0 0 28px;
}

.cta-band .hero-actions {
  justify-content: center;
  margin-bottom: 0;
}

/* ---------- Footer ---------- */

footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
}

.footer-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
  font-size: 13.5px;
}

.footer-links {
  display: flex;
  gap: 22px;
  font-size: 13.5px;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-legal {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  max-width: 78ch;
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.65;
}

.footer-legal a {
  color: inherit;
  text-decoration: underline;
}

.footer-legal a:hover {
  color: var(--text);
}

/* ---------- Docs layout ---------- */

.docs-shell {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  padding: 48px 24px 96px;
  align-items: start;
}

.docs-toc {
  position: sticky;
  top: 92px;
  font-size: 13.5px;
}

.docs-toc .toc-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-dim);
  margin-bottom: 12px;
}

.docs-toc nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.docs-toc a {
  padding: 7px 10px;
  border-radius: 7px;
  color: var(--text-muted);
  text-decoration: none;
  border-left: 2px solid transparent;
}

.docs-toc a:hover {
  color: var(--text);
  background: var(--bg-card);
}

.docs-content h1 {
  font-size: 2rem;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}

.docs-content > .lead {
  color: var(--text-muted);
  font-size: 16.5px;
  margin: 0 0 48px;
}

.docs-content > .lead.legal-lead {
  margin-bottom: 24px;
}

.legal-meta {
  color: var(--text-dim);
  font-size: 12.5px;
  letter-spacing: 0.02em;
  margin: 0 0 20px;
}

.callout.legal-accept {
  margin: 0 0 48px;
}

.docs-section {
  margin-bottom: 52px;
  padding: 0;
  scroll-margin-top: 90px;
}

.docs-section h2 {
  font-size: 1.4rem;
  letter-spacing: -0.015em;
  margin: 0 0 6px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.docs-section:first-of-type h2 {
  border-top: none;
  padding-top: 0;
}

.docs-section h3 {
  font-size: 1.05rem;
  margin: 28px 0 10px;
}

.docs-section p {
  color: var(--text-muted);
  font-size: 15.5px;
}

.docs-section ul,
.docs-section ol {
  color: var(--text-muted);
  font-size: 15.5px;
  padding-left: 22px;
}

.docs-section li {
  margin-bottom: 8px;
}

.docs-section li strong {
  color: var(--text);
}

.callout {
  border: 1px solid var(--border-strong);
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  font-size: 14.5px;
  color: var(--text-muted);
  margin: 20px 0;
}

.callout strong {
  color: var(--text);
}

.kbd-path {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 13px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 3px 8px;
  border-radius: 6px;
  color: var(--text);
}

table.docs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.5px;
  margin: 16px 0;
}

table.docs-table th,
table.docs-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
}

table.docs-table th {
  color: var(--text-dim);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

table.docs-table td:first-child,
table.docs-table th:first-child {
  color: var(--text);
}

.faq-item {
  margin-bottom: 22px;
}

.faq-item h3 {
  font-size: 15.5px;
  margin: 0 0 6px;
}

.faq-item p {
  margin: 0;
}

/* ---------- Manual ---------- */

/*
 * The manual is split into four chapters, each coloured with one of the plugin's
 * own presets the way PrismTabs tints a group's tabs: the dark-theme preset as the
 * tab fill on a dark page, the light-theme preset on a light one. --chapter-ink is
 * the opposite variant, used for the dot and for accents drawn on the page itself.
 */
[data-chapter="setup"] {
  --chapter-fill: var(--preset-blue-d);
  --chapter-ink: var(--preset-blue-l);
}

[data-chapter="groups"] {
  --chapter-fill: var(--preset-green-d);
  --chapter-ink: var(--preset-green-l);
}

[data-chapter="tools"] {
  --chapter-fill: var(--preset-purple-d);
  --chapter-ink: var(--preset-purple-l);
}

[data-chapter="reference"] {
  --chapter-fill: var(--preset-yellow-d);
  --chapter-ink: var(--preset-yellow-l);
}

:root[data-theme="light"] [data-chapter="setup"] {
  --chapter-fill: var(--preset-blue-l);
  --chapter-ink: var(--preset-blue-d);
}

:root[data-theme="light"] [data-chapter="groups"] {
  --chapter-fill: var(--preset-green-l);
  --chapter-ink: var(--preset-green-d);
}

:root[data-theme="light"] [data-chapter="tools"] {
  --chapter-fill: var(--preset-purple-l);
  --chapter-ink: var(--preset-purple-d);
}

:root[data-theme="light"] [data-chapter="reference"] {
  --chapter-fill: var(--preset-yellow-l);
  --chapter-ink: var(--preset-yellow-d);
}

.chapter-dot {
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--chapter-ink);
}

/* Page head: the title and a strip of chapter tabs sitting on the page's baseline. */

.manual-head {
  position: relative;
  overflow: hidden;
  padding: 64px 0 0;
  border-bottom: 1px solid var(--border);
}

.manual-head::before {
  content: "";
  position: absolute;
  top: -260px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 480px;
  background: radial-gradient(closest-side, var(--warm-glow), transparent 70%);
  pointer-events: none;
}

.manual-head .wrap {
  position: relative;
}

.manual-head h1 {
  font-size: clamp(2.4rem, 4.4vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}

.manual-head .lead {
  font-size: 18px;
  color: var(--text-muted);
  margin: 0 0 40px;
}

.chapter-strip {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}

.chapter-strip a {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
  padding: 8px 16px 8px 13px;
  border-radius: 10px 10px 0 0;
  background: color-mix(in srgb, var(--chapter-fill) 45%, transparent);
  box-shadow: inset 0 -2px 0 var(--chapter-ink);
  color: var(--text);
  font-family: var(--font-display);
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s ease;
}

.chapter-strip a:hover {
  background: color-mix(in srgb, var(--chapter-fill) 80%, transparent);
}

.chapter-strip a:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: -2px;
}

/* Layout: a readable measure for the prose column. */

.manual.docs-shell {
  padding-top: 56px;
}

.manual .docs-content {
  min-width: 0;
  max-width: 46rem;
}

.docs-toc {
  max-height: calc(100vh - 116px);
  overflow-y: auto;
}

/* Table of contents, drawn as the PrismTabs tool window's tree. */

.toc-toggle {
  display: none;
}

.toc-tree {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.toc-group {
  display: flex;
  flex-direction: column;
}

.toc-chapter {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 6px;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.docs-toc .toc-group a {
  margin-left: 4px;
  padding: 6px 10px 6px 16px;
  border-left: 2px solid color-mix(in srgb, var(--chapter-fill) 70%, transparent);
  border-radius: 0 7px 7px 0;
}

.docs-toc .toc-group a:hover {
  color: var(--text);
  background: color-mix(in srgb, var(--chapter-fill) 22%, transparent);
}

.docs-toc .toc-group a[aria-current="location"] {
  color: var(--text);
  font-weight: 500;
  border-left-color: var(--chapter-ink);
  background: color-mix(in srgb, var(--chapter-fill) 38%, transparent);
}

/* A tree without chapters, as on the licence page, takes the brand accent instead. */

.toc-tree > a {
  padding: 6px 10px 6px 14px;
  border-left: 2px solid var(--border-strong);
  border-radius: 0 7px 7px 0;
}

.toc-tree > a[aria-current="location"] {
  color: var(--text);
  font-weight: 500;
  border-left-color: var(--headline-via);
  background: var(--bg-card);
}

.docs-toc a:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: -2px;
}

/* Sections: each heading is a tinted tab, and a permalink to its section. */

.manual .docs-section {
  margin-bottom: 72px;
  scroll-margin-top: 92px;
}

.manual .docs-section h2,
.manual .docs-section:first-of-type h2 {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin: 0 0 24px;
  padding: 0;
  border-top: none;
  border-bottom: 1px solid color-mix(in srgb, var(--chapter-fill) 70%, transparent);
  font-size: 1.05rem;
}

.section-tab {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 12px;
  border-radius: 10px 10px 0 0;
  background: color-mix(in srgb, var(--chapter-fill) 45%, transparent);
  box-shadow: inset 0 -2px 0 var(--chapter-ink);
  color: var(--text);
  text-decoration: none;
}

.section-tab::after {
  content: "#";
  content: "#" / "";
  margin-left: -4px;
  color: var(--text-dim);
  font-weight: 500;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.section-tab:hover::after,
.section-tab:focus-visible::after {
  opacity: 1;
}

.section-tab:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

.manual .docs-section h2 .tier-tag {
  margin-left: 0;
}

.manual .docs-section p,
.manual .docs-section ul,
.manual .docs-section ol,
.manual .docs-section dd {
  font-size: 16px;
  line-height: 1.7;
}

.manual .docs-section p a,
.manual .docs-section li a,
.manual .docs-section dd a,
.manual .callout a {
  color: var(--text);
  text-decoration-color: var(--chapter-ink);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

.manual .docs-section p a:hover,
.manual .docs-section li a:hover,
.manual .docs-section dd a:hover,
.manual .callout a:hover {
  text-decoration-thickness: 2.5px;
}

.manual .callout {
  border: none;
  border-left: 3px solid var(--chapter-ink);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: color-mix(in srgb, var(--chapter-fill) 16%, var(--bg));
  padding: 16px 20px;
  font-size: 15px;
  line-height: 1.65;
  margin: 28px 0;
}

.manual .callout strong:first-child {
  display: block;
  margin-bottom: 4px;
}

/* Licensing stages: a vertical timeline. */

.stage-list {
  list-style: none;
  margin: 24px 0 32px;
  padding: 0;
}

.manual .docs-section .stage-list {
  padding-left: 0;
}

.stage {
  position: relative;
  padding: 0 0 24px 32px;
  margin: 0;
}

.stage::before {
  content: "";
  position: absolute;
  top: 6px;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
}

.stage::after {
  content: "";
  position: absolute;
  top: 24px;
  bottom: 2px;
  left: 6px;
  width: 1px;
  background: var(--border-strong);
}

.stage:last-child {
  padding-bottom: 0;
}

.stage:last-child::after {
  display: none;
}

.stage--pro::before {
  background: var(--accent-purple);
  border-color: var(--accent-purple);
  box-shadow: 0 0 0 4px rgba(181, 140, 242, 0.18);
}

.stage-when {
  display: block;
  font-family: var(--font-display);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--chapter-ink);
  margin-bottom: 2px;
}

.manual .docs-section .stage p {
  margin: 0;
}

/* Free and Pro, side by side. */

.tier-compare {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 20px 0 8px;
}

.tier-col {
  padding: 18px 20px 6px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
}

.tier-col--pro {
  border-color: rgba(181, 140, 242, 0.35);
}

.manual .docs-section .tier-col h3 {
  margin: 0 0 10px;
}

.tier-col .tier-tag {
  margin-left: 0;
  font-size: 11.5px;
  padding: 3px 10px;
}

.manual .docs-section .tier-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 15px;
}

.tier-col li {
  position: relative;
  padding-left: 18px;
}

.tier-col li::before {
  content: "";
  position: absolute;
  top: 0.68em;
  left: 2px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-green);
}

.tier-col--pro li::before {
  background: var(--accent-purple);
}

/* IDE commands and what each one does. */

.command-list {
  margin: 20px 0 28px;
  border-top: 1px solid var(--border);
}

.command-list dt {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 16px;
}

.command-list dd {
  margin: 8px 0 0;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
}

.command {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 4px 11px;
  border-radius: 6px;
  border: 1px solid var(--border-strong);
  background: var(--bg-elevated);
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text);
}

.command-list dt .tier-tag {
  margin-left: 0;
}

.swatch-row {
  display: inline-flex;
  gap: 4px;
}

.swatch-row i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--c);
}

/* Palette table with real swatches. */

.palette-table td {
  font-family: var(--font-mono);
  font-size: 13.5px;
}

table.palette-table tbody th {
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text);
}

.palette-table .swatch {
  display: inline-block;
  width: 28px;
  height: 18px;
  margin-right: 12px;
  vertical-align: -4px;
  border-radius: 5px;
  background: var(--c);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
}

/* The licence page shares the manual's layout; its tabs and callout take the brand's pink. */

.legal {
  --chapter-fill: var(--preset-pink-d);
  --chapter-ink: var(--preset-pink-l);
  position: relative;
}

:root[data-theme="light"] .legal {
  --chapter-fill: var(--preset-pink-l);
  --chapter-ink: var(--preset-pink-d);
}

.legal::before {
  content: "";
  position: absolute;
  top: -300px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 480px;
  background: radial-gradient(closest-side, var(--warm-glow), transparent 70%);
  pointer-events: none;
}

.legal .docs-content h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.1;
}

.legal .callout.legal-accept {
  margin: 0 0 56px;
}

.legal .legal-meta {
  margin-bottom: 28px;
}

.legal .docs-section h3 {
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  margin: 32px 0 8px;
}

/* FAQ */

.manual .faq-item {
  margin: 0;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}

.manual .faq-item:first-of-type {
  padding-top: 0;
}

.manual .faq-item:last-of-type {
  border-bottom: none;
}

.manual .faq-item h3 {
  font-family: var(--font-display);
  font-size: 16.5px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
}

@media (prefers-reduced-motion: reduce) {
  .chapter-strip a,
  .section-tab::after {
    transition: none;
  }
}

/* ---------- Responsive ---------- */

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

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

  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 460px;
  }

  .trial-timeline {
    grid-template-columns: 1fr;
    max-width: 460px;
    gap: 28px;
  }

  .trial-timeline li::after {
    display: none;
  }

  .docs-shell {
    grid-template-columns: 1fr;
  }

  .docs-toc {
    position: static;
    border-bottom: 1px solid var(--border);
    padding-bottom: 24px;
    margin-bottom: 8px;
  }

  .docs-toc nav {
    flex-direction: row;
    flex-wrap: wrap;
  }

  /* The tree collapses behind an "On this page" button instead of wrapping. */
  .docs-toc {
    max-height: none;
    overflow: visible;
    padding-bottom: 0;
    border-bottom: none;
  }

  .docs-toc .toc-title {
    display: none;
  }

  .toc-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    background: var(--bg-elevated);
    color: var(--text);
    font: inherit;
    font-size: 14.5px;
    font-weight: 600;
    cursor: pointer;
  }

  .toc-toggle:focus-visible {
    outline: 2px solid var(--focus-ring);
    outline-offset: 2px;
  }

  .toc-toggle svg {
    transition: transform 0.15s ease;
  }

  .toc-toggle[aria-expanded="true"] svg {
    transform: rotate(180deg);
  }

  .docs-toc .toc-tree {
    display: none;
    flex-direction: column;
    flex-wrap: nowrap;
    padding: 20px 4px 4px;
  }

  .toc-toggle[aria-expanded="true"] + .toc-title + .toc-tree {
    display: flex;
  }
}

@media (max-width: 920px) and (prefers-reduced-motion: reduce) {
  .toc-toggle svg {
    transition: none;
  }
}

@media (max-width: 560px) {
  .tier-compare {
    grid-template-columns: 1fr;
  }

  .manual-head {
    padding-top: 44px;
  }

  .manual-head .lead {
    margin-bottom: 28px;
  }

  /* Scrolls edge to edge, so a tab cut off at the screen's edge reads as more to come. */
  .chapter-strip {
    margin: 0 -24px;
    padding: 0 24px;
    scroll-padding: 0 24px;
  }

  .manual.docs-shell {
    padding-top: 32px;
  }

  .section-tab {
    padding: 6px 14px 6px 12px;
  }

  .manual .docs-section h2,
  .manual .docs-section:first-of-type h2 {
    font-size: 1rem;
  }
}

@media (max-width: 720px) {
  .nav-links {
    position: fixed;
    inset: 68px 0 0 0;
    background: var(--bg);
    flex-direction: column;
    align-items: flex-start;
    padding: 24px;
    gap: 4px;
    transform: translateX(100%);
    transition: transform 0.2s ease;
  }

  .nav-links a:not(.btn) {
    width: 100%;
    padding: 12px 12px;
  }

  /* A vertical bar replaces the underline, which would span the full row. */
  .nav-links a:not(.btn)::after {
    inset: 10px auto 10px 0;
    width: 2px;
    height: auto;
    transform: scaleY(0);
    transform-origin: top;
  }

  .nav-links a:not(.btn):hover::after,
  .nav-links a:not(.btn):focus-visible::after,
  .nav-links a[aria-current="page"]::after {
    transform: scaleY(1);
  }

  .nav-links .btn {
    width: 100%;
    margin: 16px 0 0;
    padding: 12px 24px;
    font-size: 15px;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin-left: auto;
    border-radius: 8px;
    border: 1px solid var(--border-strong);
    background: transparent;
    color: var(--text);
  }

  .nav-toggle[aria-expanded="true"] + .nav-links,
  body.nav-open .nav-links {
    transform: translateX(0);
  }

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

  .cta-band {
    padding: 36px 24px;
  }
}

@media (min-width: 721px) {
  .nav-toggle {
    display: none;
  }
}
