/* trailhub.org — marketing site, docs and blog
   Design tokens first; everything else uses them. */

:root {
  --ink: #12222b;
  --ink-soft: #3b4a53;
  --muted: #65757e;
  --line: #dfe7ec;
  --paper: #ffffff;
  --snow: #f4f8fa;
  --snow-deep: #e8f0f4;
  --night: #0b2430;
  --teal: #0a5c72;
  --teal-deep: #084a5c;
  --sky: #4bb0dc;
  --sky-soft: #dff2fa;
  --open: #2e8b57;
  --caution: #e0a100;
  --closed: #c8372d;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(11, 36, 48, .06), 0 8px 24px rgba(11, 36, 48, .08);
  --shadow-lg: 0 2px 4px rgba(11, 36, 48, .08), 0 24px 60px rgba(11, 36, 48, .16);
  --max: 1180px;
  --font-display: "Manrope", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #eaf2f6;
    --ink-soft: #c2d0d8;
    --muted: #8ea0aa;
    --line: #22343e;
    --paper: #0f1d25;
    --snow: #0b171e;
    --snow-deep: #132430;
    --night: #06141b;
    --teal: #4bb0dc;
    --teal-deep: #7cc9ea;
    --sky: #4bb0dc;
    --sky-soft: #10323f;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.4);
    --shadow-lg: 0 2px 4px rgba(0,0,0,.5), 0 24px 60px rgba(0,0,0,.6);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .reveal.is-visible { animation: none; } }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; letter-spacing: -0.015em; margin: 0 0 .5em; color: var(--ink); }
h1 { font-size: clamp(2rem, 5vw, 3.4rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.3rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }
h4 { font-size: .95rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
p { margin: 0 0 1em; }
code, pre { font-family: var(--font-mono); font-size: .9em; }
.wrap { width: min(var(--max), 100% - 32px); margin-inline: auto; }
.wrap--narrow { width: min(760px, 100% - 32px); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--teal); color: #fff; padding: 8px 12px; border-radius: 6px; z-index: 100; }
.skip:focus { left: 8px; }
.lede { font-size: 1.2rem; color: var(--ink-soft); max-width: 62ch; }
.eyebrow { font-family: var(--font-display); font-weight: 700; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; color: var(--sky); margin-bottom: .6em; }
.muted { color: var(--muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  background: var(--teal); color: #fff; font-weight: 600; font-family: var(--font-display);
  padding: .8em 1.4em; border-radius: 999px; border: 2px solid var(--teal);
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
}
.btn:hover { background: var(--teal-deep); border-color: var(--teal-deep); text-decoration: none; transform: translateY(-1px); box-shadow: var(--shadow); }
.btn--ghost { background: transparent; color: var(--teal); }
.btn--ghost:hover { background: var(--sky-soft); color: var(--teal-deep); }
.btn--light { background: #fff; color: var(--night); border-color: #fff; }
.btn--light:hover { background: var(--sky-soft); border-color: var(--sky-soft); }
.btn--small { padding: .5em 1.1em; font-size: .92rem; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--paper) 86%, transparent); backdrop-filter: saturate(160%) blur(12px); border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s; }
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 2px 12px rgba(11,36,48,.05); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; }
.brand:hover { text-decoration: none; }
.brand img { border-radius: 50%; width: 36px; height: 36px; }
.brand strong { font-weight: 800; color: var(--teal); }
.site-nav { display: flex; align-items: center; gap: 26px; font-weight: 500; font-size: .98rem; }
.site-nav a { color: var(--ink-soft); }
.site-nav a:hover, .site-nav a.is-active { color: var(--teal); text-decoration: none; }
.site-nav .btn { color: #fff; }
.site-nav .btn:hover { color: #fff; }
.site-nav__secondary { color: var(--muted) !important; }
.nav-toggle { display: none; background: none; border: 0; width: 44px; height: 44px; padding: 10px; cursor: pointer; }
.nav-toggle span { display: block; height: 2px; background: var(--ink); margin: 5px 0; border-radius: 2px; transition: transform .2s, opacity .2s; }
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 68px; flex-direction: column; align-items: stretch; gap: 0; background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg); padding: 8px 16px 16px; }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .site-nav .btn { margin-top: 12px; justify-content: center; border-bottom: 0; }
  .nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* Footer */
.site-footer { margin-top: 96px; background: var(--snow); border-top: 1px solid var(--line); padding: 56px 0 28px; font-size: .95rem; }
.site-footer__grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
.site-footer__grid a { display: block; color: var(--ink-soft); margin-bottom: .5em; }
.site-footer__grid a:hover { color: var(--teal); }
.brand--footer { margin-bottom: 14px; }
.site-footer__tag { color: var(--muted); max-width: 34ch; }
.site-footer__by { color: var(--muted); }
.site-footer__by a { display: inline; }
.site-footer__legal { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: .88rem; }
@media (max-width: 860px) { .site-footer__grid { grid-template-columns: 1fr 1fr; } .site-footer__grid > :first-child { grid-column: 1 / -1; } }

/* Sections */
.section { padding: 88px 0; }
.section--snow { background: var(--snow); }
.section--night { background: var(--night); color: #d8e6ee; }
.section--night h2, .section--night h3 { color: #fff; }
.section--night .lede, .section--night p { color: #b8cad5; }
.section__head { max-width: 720px; margin-bottom: 44px; }
/* Elements are visible by default; .is-visible (added when scrolled into
   view) only plays a short entrance animation. Nothing depends on JS. */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.reveal.is-visible { animation: rise .6s ease both; }

/* Hero */
.hero { padding: 72px 0 40px; position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: -40% -20% auto -20%; height: 120%; background: radial-gradient(60% 50% at 20% 30%, var(--sky-soft) 0%, transparent 70%), radial-gradient(40% 40% at 85% 20%, color-mix(in srgb, var(--sky) 18%, transparent) 0%, transparent 70%); z-index: -1; }
.hero__grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.hero h1 { max-width: 14ch; }
.hero .lede { margin-bottom: 1.6em; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 20px; }
.hero__note { color: var(--muted); font-size: .92rem; }
.hero__proof { display: flex; gap: 28px; margin-top: 36px; flex-wrap: wrap; }
.hero__proof div strong { display: block; font-family: var(--font-display); font-size: 1.5rem; color: var(--ink); }
.hero__proof div span { color: var(--muted); font-size: .9rem; }
.device { background: var(--paper); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg); overflow: hidden; }
.device__bar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--snow); font-size: .8rem; color: var(--muted); }
.device__bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); display: inline-block; }
.device__bar span { margin-left: auto; font-family: var(--font-mono); }
.device iframe { display: block; width: 100%; height: 520px; border: 0; background: var(--snow-deep); }
.device__caption { padding: 10px 14px; font-size: .85rem; color: var(--muted); border-top: 1px solid var(--line); }
@media (max-width: 960px) { .hero__grid { grid-template-columns: 1fr; } .device iframe { height: 440px; } .hero { padding-top: 40px; } }

/* Status chips */
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: .82rem; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: var(--snow-deep); color: var(--ink-soft); }
.chip::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.chip--open { color: var(--open); background: color-mix(in srgb, var(--open) 12%, transparent); }
.chip--caution { color: var(--caution); background: color-mix(in srgb, var(--caution) 14%, transparent); }
.chip--closed { color: var(--closed); background: color-mix(in srgb, var(--closed) 12%, transparent); }

/* Feature grids */
.grid { display: grid; gap: 22px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 960px) { .grid--4 { grid-template-columns: repeat(2, 1fr); } .grid--3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .grid--4, .grid--3, .grid--2 { grid-template-columns: 1fr; } }
.card { display: block; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; color: inherit; transition: transform .15s, box-shadow .15s, border-color .15s; }
a.card:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--sky) 50%, var(--line)); }
.card h3 { margin-bottom: .35em; }
.card p { color: var(--ink-soft); margin: 0; font-size: .97rem; }
.card__count { display: inline-block; margin-top: 12px; font-size: .82rem; color: var(--muted); }
.card--post time { display: block; font-size: .85rem; color: var(--muted); margin-bottom: 8px; }
.feature { padding: 0; border: 0; background: transparent; }
.feature__icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--sky-soft); color: var(--teal); margin-bottom: 14px; font-size: 1.3rem; }
.feature__icon svg { width: 22px; height: 22px; }
.section--night .feature__icon { background: rgba(75,176,220,.16); color: var(--sky); }
.section--night .feature p { color: #b8cad5; }

/* Flow (one update, everywhere) */
.flow { display: grid; grid-template-columns: 1fr auto 1fr; gap: 28px; align-items: center; }
.flow__arrow { font-size: 2rem; color: var(--sky); text-align: center; }
.flow__out { display: grid; gap: 12px; }
.flow__item { display: flex; gap: 14px; align-items: flex-start; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px 16px; }
.flow__item strong { display: block; }
.flow__item span { color: var(--muted); font-size: .92rem; }
.flow__in { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.flow__in .form-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: .95rem; }
.flow__in .form-row:last-child { border-bottom: 0; }
@media (max-width: 860px) { .flow { grid-template-columns: 1fr; } .flow__arrow { transform: rotate(90deg); } }

/* Chat demo */
.chat { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 22px; display: grid; gap: 14px; max-width: 560px; }
.section--night .chat { background: #102b38; border-color: #1f4151; }
.msg { padding: 12px 16px; border-radius: 14px; max-width: 92%; font-size: .96rem; line-height: 1.5; }
.msg--user { background: var(--teal); color: #fff; justify-self: end; border-bottom-right-radius: 4px; }
.msg--ai { background: var(--snow-deep); color: var(--ink); border-bottom-left-radius: 4px; }
.section--night .msg--ai { background: #183a4a; color: #e6f1f6; }
.msg--tool { font-family: var(--font-mono); font-size: .8rem; color: var(--sky); background: transparent; padding: 0 4px; }
.msg code { background: rgba(255,255,255,.12); padding: 1px 5px; border-radius: 4px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
@media (max-width: 960px) { .split { grid-template-columns: 1fr; } }
.check-list { list-style: none; padding: 0; margin: 0 0 1.5em; display: grid; gap: 10px; }
.check-list li { padding-left: 30px; position: relative; }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--sky); font-weight: 800; }

/* Audience */
.audience { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.audience div { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.audience h3 { font-size: 1.05rem; }
.audience p { color: var(--muted); font-size: .93rem; margin: 0; }
@media (max-width: 960px) { .audience { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .audience { grid-template-columns: 1fr; } }

/* Pricing */
.pricing__controls { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 36px; align-items: center; }
.switch { display: inline-flex; align-items: center; gap: 10px; background: var(--paper); border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px 8px 10px; cursor: pointer; font: inherit; color: var(--ink); font-weight: 500; }
.switch i { width: 38px; height: 22px; border-radius: 999px; background: var(--line); position: relative; transition: background .2s; }
.switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.switch[aria-pressed="true"] i { background: var(--teal); }
.switch[aria-pressed="true"] i::after { transform: translateX(16px); }
.switch small { color: var(--open); font-weight: 600; }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; align-items: stretch; }
@media (max-width: 960px) { .plans { grid-template-columns: 1fr; max-width: 520px; } }
.plan { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; position: relative; }
.plan--featured { border-color: var(--sky); box-shadow: var(--shadow-lg); }
.plan__badge { position: absolute; top: -12px; left: 24px; background: var(--sky); color: #fff; font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; }
.plan__name { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 800; font-size: 1.25rem; }
.plan__size { color: var(--muted); font-size: .92rem; margin: 2px 0 14px; }
.plan__price { font-family: var(--font-display); font-weight: 800; font-size: 2.3rem; letter-spacing: -0.02em; }
.plan__price small { font-size: 1rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.plan__alt { color: var(--muted); font-size: .9rem; min-height: 1.4em; margin-bottom: 16px; }
.plan ul { list-style: none; padding: 0; margin: 0 0 22px; display: grid; gap: 8px; font-size: .95rem; }
.plan li { padding-left: 26px; position: relative; color: var(--ink-soft); }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--open); font-weight: 800; }
.plan li.no { color: var(--muted); text-decoration: line-through; opacity: .7; }
.plan li.no::before { content: "–"; color: var(--muted); }
.plan .btn { margin-top: auto; justify-content: center; }
/* price/name visibility driven by data attributes on #pricing */
[data-period="annual"] .p-monthly, [data-period="monthly"] .p-annual { display: none; }
[data-audience="business"] .a-nonprofit, [data-audience="nonprofit"] .a-business { display: none; }
.marker { width: 18px; height: 18px; display: inline-block; flex: none; }
.marker--square { background: var(--teal); }
.marker--diamond { background: var(--ink); transform: rotate(45deg) scale(.8); }
.marker--double { background: var(--ink); transform: rotate(45deg) scale(.8); box-shadow: 22px 0 0 var(--ink); margin-right: 20px; }
.marker--circle { background: var(--open); border-radius: 50%; }
.marker--triangle { width: 0; height: 0; background: none; border-left: 10px solid transparent; border-right: 10px solid transparent; border-bottom: 18px solid var(--caution); }
.marker--star { color: var(--sky); font-size: 1.3rem; line-height: 1; width: auto; height: auto; }
.pricing__foot { margin-top: 28px; color: var(--muted); font-size: .95rem; }

/* CTA band */
.cta-band { text-align: center; padding: 96px 0; background: linear-gradient(135deg, var(--teal) 0%, #0d7a93 60%, var(--sky) 100%); color: #fff; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.85); max-width: 56ch; margin-inline: auto; }
.cta-band .btn--light { margin-top: 8px; }
.cta-band .btn--ghost { color: #fff; border-color: rgba(255,255,255,.6); margin-top: 8px; }
.cta-band .btn--ghost:hover { background: rgba(255,255,255,.12); color: #fff; }

/* Markdown content */
.md { font-size: 1.03rem; line-height: 1.7; }
.md > :first-child { margin-top: 0; }
.md h2 { font-size: 1.55rem; margin: 2.2em 0 .6em; padding-top: .4em; }
.md h3 { font-size: 1.2rem; margin: 1.8em 0 .5em; }
.md h4 { text-transform: none; letter-spacing: 0; color: var(--ink); font-size: 1.02rem; margin: 1.4em 0 .4em; }
.md .anchor { float: left; margin-left: -1.1em; width: 1.1em; opacity: 0; color: var(--sky); font-weight: 600; }
.md h2:hover .anchor, .md h3:hover .anchor { opacity: 1; text-decoration: none; }
.md ul, .md ol { padding-left: 1.4em; }
.md li { margin-bottom: .35em; }
.md li > p { margin-bottom: .4em; }
.md blockquote { margin: 1.2em 0; padding: .6em 1.2em; border-left: 4px solid var(--sky); background: var(--snow); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; color: var(--ink-soft); }
.md blockquote p:last-child { margin-bottom: 0; }
.md hr { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }
.md code { background: var(--snow-deep); padding: .12em .4em; border-radius: 5px; font-size: .88em; }
.md pre code { background: none; padding: 0; font-size: .86rem; }
.code-block { position: relative; margin: 1.3em 0; }
.code-block pre { margin: 0; background: var(--night); color: #dbe8ef; padding: 18px 20px; border-radius: var(--radius-sm); overflow-x: auto; line-height: 1.55; }
.code-copy { position: absolute; top: 8px; right: 8px; font: 600 .75rem var(--font-body); background: rgba(255,255,255,.1); color: #cfe3ed; border: 1px solid rgba(255,255,255,.18); border-radius: 6px; padding: 4px 9px; cursor: pointer; }
.code-copy:hover { background: rgba(255,255,255,.2); }
.md-figure { margin: 1.5em 0; }
.md-figure img { border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow); background: #fff; }
.md-figure figcaption { font-size: .88rem; color: var(--muted); margin-top: .5em; text-align: center; }
.table-wrap { overflow-x: auto; margin: 1.3em 0; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.md table { border-collapse: collapse; width: 100%; font-size: .93rem; }
.md th, .md td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.md th { background: var(--snow); font-weight: 600; }
.md tr:last-child td { border-bottom: 0; }
.video { position: relative; aspect-ratio: 16 / 9; margin: 1.4em 0; border-radius: var(--radius-sm); overflow: hidden; background: var(--night); }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.md iframe:not(.video iframe) { max-width: 100%; border-radius: var(--radius-sm); border: 1px solid var(--line); }
.md kbd { font: .85em var(--font-mono); background: var(--snow); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px; }

/* Docs layout */
.page-docs .site-footer { margin-top: 64px; }
.docs { display: grid; grid-template-columns: 250px minmax(0, 1fr) 210px; gap: 48px; padding: 36px 0 56px; align-items: start; }
.docs-sidebar, .docs-aside { position: sticky; top: 88px; max-height: calc(100vh - 100px); overflow: auto; font-size: .93rem; }
.docs-aside { padding-top: 6px; }
.docs-nav__home { display: block; font-family: var(--font-display); font-weight: 800; color: var(--ink); margin-bottom: 12px; }
.docs-nav ul { list-style: none; padding: 0; margin: 0; }
.docs-nav__section { margin-bottom: 6px; }
.docs-nav__section > a { display: block; padding: 7px 10px; border-radius: 6px; font-weight: 600; color: var(--ink); }
.docs-nav__section > ul { display: none; margin: 2px 0 8px 10px; border-left: 1px solid var(--line); }
.docs-nav__section.is-open > ul { display: block; }
.docs-nav__section > ul a { display: block; padding: 5px 12px; color: var(--ink-soft); border-left: 2px solid transparent; margin-left: -1px; }
.docs-nav a:hover { color: var(--teal); text-decoration: none; background: var(--snow); }
.docs-nav a.is-current { color: var(--teal); font-weight: 600; background: var(--sky-soft); }
.docs-nav__section > ul a.is-current { background: none; border-left-color: var(--teal); }
.docs-search { position: relative; margin-bottom: 16px; }
.docs-search input { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--snow); color: var(--ink); font: inherit; font-size: .93rem; }
.docs-search input:focus { outline: 2px solid var(--sky); outline-offset: 1px; background: var(--paper); }
.docs-search__results { position: absolute; z-index: 20; top: calc(100% + 6px); left: 0; width: min(520px, 90vw); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg); max-height: 70vh; overflow: auto; }
.docs-search__results a { display: block; padding: 10px 14px; border-bottom: 1px solid var(--line); color: var(--ink); }
.docs-search__results a:hover { background: var(--snow); text-decoration: none; }
.docs-search__results a:last-child { border-bottom: 0; }
.docs-search__results strong { display: block; }
.docs-search__results small { display: block; color: var(--muted); font-size: .82rem; line-height: 1.4; margin-top: 2px; }
.docs-search__section { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--sky); font-weight: 700; }
.docs-search__empty { padding: 14px; color: var(--muted); margin: 0; }
.docs-article { min-width: 0; max-width: 760px; }
.docs-article h1 { font-size: clamp(1.8rem, 3.5vw, 2.5rem); margin-bottom: .3em; }
.docs-article .lede { font-size: 1.1rem; margin-bottom: 1.6em; }
.breadcrumbs { font-size: .88rem; color: var(--muted); margin-bottom: 14px; }
.breadcrumbs span { margin: 0 6px; }
.docs-toc h4 { margin-bottom: 10px; }
.docs-toc ul { list-style: none; padding: 0; margin: 0; border-left: 1px solid var(--line); }
.docs-toc a { display: block; padding: 4px 12px; color: var(--ink-soft); font-size: .9rem; border-left: 2px solid transparent; margin-left: -1px; }
.docs-toc a:hover { color: var(--teal); text-decoration: none; }
.docs-footer { margin-top: 48px; border-top: 1px solid var(--line); padding-top: 20px; }
.docs-footer__meta { display: flex; justify-content: space-between; font-size: .88rem; color: var(--muted); margin-bottom: 24px; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.pager__link { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 16px; color: var(--ink); font-weight: 600; }
.pager__link span { display: block; font-size: .78rem; color: var(--muted); font-weight: 500; text-transform: uppercase; letter-spacing: .06em; }
.pager__link:hover { border-color: var(--sky); text-decoration: none; }
.pager__link--next { text-align: right; }
.section-list { list-style: none; padding: 0; display: grid; gap: 10px; }
.section-list li { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 16px; }
.section-list a { font-weight: 600; }
.section-list p { margin: 2px 0 0; color: var(--muted); font-size: .92rem; }
.card-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin: 28px 0; }
.quick-links { display: grid; gap: 10px; margin-bottom: 8px; }
.quick-links a { background: var(--sky-soft); border-radius: var(--radius-sm); padding: 12px 16px; font-weight: 600; }
.docs-help { color: var(--muted); }
@media (max-width: 1100px) { .docs { grid-template-columns: 230px minmax(0, 1fr); } .docs-aside { display: none; } }
@media (max-width: 860px) {
  .docs { grid-template-columns: 1fr; gap: 24px; }
  .docs-sidebar { position: static; max-height: none; }
  .docs-nav__section > ul { display: block; }
  .docs-nav { display: none; }
  .docs--home .docs-nav { display: block; }
  .card-grid { grid-template-columns: 1fr; }
}

/* Blog */
.blog-hero { padding: 56px 0 24px; }
.blog-feed { font-size: .9rem; }
.blog-list { display: grid; gap: 28px; padding-bottom: 40px; }
.post-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; background: var(--paper); }
.post-card__meta, .post__meta { font-size: .88rem; color: var(--muted); margin-bottom: 8px; }
.post-card h2 { font-size: 1.5rem; margin-bottom: .4em; }
.post-card h2 a { color: var(--ink); }
.post-card p { color: var(--ink-soft); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { font-size: .78rem; font-weight: 600; background: var(--snow-deep); color: var(--ink-soft); padding: 3px 10px; border-radius: 999px; }
.tag:hover { background: var(--sky-soft); color: var(--teal); text-decoration: none; }
.post { padding: 56px 0 24px; }
.post__header { margin-bottom: 32px; }
.post__header h1 { font-size: clamp(2rem, 4.5vw, 3rem); }
.post__author { color: var(--muted); margin-bottom: 14px; }
.post-cover { margin: 0 0 32px; }
.post-cover img { border-radius: var(--radius); box-shadow: var(--shadow); }
.post__body { font-size: 1.08rem; }
.post__footer { margin-top: 56px; }
.cta-box { background: var(--snow); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; margin-bottom: 40px; }
.cta-box .btn { margin-right: 8px; margin-top: 6px; }
.related h3 { margin-bottom: 16px; }
.related .post-card { margin-bottom: 16px; }

/* Generic content pages (contact, 404) */
.page { padding: 72px 0 32px; }
.page h1 { margin-bottom: .4em; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 32px; }
@media (max-width: 760px) { .contact-grid { grid-template-columns: 1fr; } }
