/* ==========================================================================
   Anthropic-style local site — design tokens + components
   Original implementation. Palette & typography evoke the reference brand.
   ========================================================================== */

:root {
  /* Surfaces */
  --paper:        #faf9f5;
  --paper-2:      #f0eee6;
  --paper-3:      #e5e3d9;
  --dark:         #191919;
  --dark-2:       #232322;
  --dark-3:       #2e2e2c;

  /* Ink */
  --ink:          #141413;
  --ink-2:        #3d3d3a;
  --muted:        #87867f;
  --muted-dark:   #a3a29a;

  /* Accents */
  --clay:         #d97757;
  --clay-deep:    #c2603f;
  --clay-soft:    #e9c6b7;
  --sky:          #6a9bcc;
  --sage:         #788c5d;

  /* Lines */
  --line:         rgba(20, 20, 19, 0.12);
  --line-strong:  rgba(20, 20, 19, 0.24);
  --line-dark:    rgba(250, 249, 245, 0.14);

  /* Radii */
  --r-xs: 6px;
  --r-sm: 10px;
  --r:    16px;
  --r-lg: 24px;
  --r-xl: 32px;
  --r-pill: 999px;

  /* Metrics */
  --maxw: 1200px;
  --maxw-wide: 1360px;
  --gutter: clamp(20px, 4.5vw, 40px);
  --header-h: 64px;
  --promo-h: 38px;
  /* Full height of the fixed header; main.js keeps this in sync with the real
     measured height so anchor offsets and the mobile drawer clear it exactly. */
  --header-total: calc(var(--promo-h) + var(--header-h));

  /* Motion */
  --ease: cubic-bezier(0.22, 0.68, 0.24, 1);
  --dur: 0.45s;

  /* Type stacks */
  --serif: "Newsreader", "Tiempos Text", "Iowan Old Style", Georgia,
           "Songti SC", "Noto Serif SC", "Source Han Serif SC", SimSun,
           "Times New Roman", serif;
  --sans:  "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
           "Helvetica Neue", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  --mono:  "JetBrains Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo,
           Consolas, monospace;
}

/* --------------------------------------------------------------- reset -- */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-total) + 20px);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.is-locked { overflow: hidden; }

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

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

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

ul, ol { margin: 0; padding: 0; list-style: none; }

h1, h2, h3, h4, h5 {
  margin: 0;
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.022em;
  text-wrap: balance;
}

p { margin: 0; }

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 0;
}

::selection { background: var(--clay-soft); color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--clay);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ------------------------------------------------------------ typography -- */

.display {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.02;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.eyebrow--clay { color: var(--clay-deep); }

.lede {
  font-size: clamp(17px, 1.4vw, 20px);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 62ch;
  text-wrap: pretty;
}

.small { font-size: 14px; line-height: 1.5; }

.muted { color: var(--muted); }

.ink-2 { color: var(--ink-2); }

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

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

.container--wide { max-width: var(--maxw-wide); }

.section { padding-block: clamp(64px, 9vw, 128px); }
.section--tight { padding-block: clamp(44px, 6vw, 72px); }
.section--paper2 { background: var(--paper-2); }
.section--dark { background: var(--dark); color: var(--paper); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: clamp(28px, 4vw, 48px);
}

.section-head h2 {
  font-family: var(--serif);
  font-size: clamp(30px, 4vw, 46px);
  letter-spacing: -0.028em;
}

.stack { display: grid; gap: 16px; }
.stack--lg { gap: 28px; }

.rule { border-top: 1px solid var(--line); }

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

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

/* -------------------------------------------------------------- buttons -- */

.btn {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: var(--r-pill);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  border: 1px solid transparent;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease),
              border-color var(--dur) var(--ease), transform 0.2s var(--ease);
  white-space: nowrap;
}

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

.btn--primary {
  --btn-bg: var(--ink);
  --btn-fg: var(--paper);
}
.btn--primary:hover { --btn-bg: var(--clay-deep); }

.btn--clay {
  --btn-bg: var(--clay);
  --btn-fg: #fff;
}
.btn--clay:hover { --btn-bg: var(--clay-deep); }

.btn--outline {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  border-color: var(--line-strong);
}
.btn--outline:hover { --btn-bg: var(--ink); --btn-fg: var(--paper); border-color: var(--ink); }

.btn--ghost { --btn-fg: var(--ink-2); padding-inline: 12px; }
.btn--ghost:hover { --btn-fg: var(--clay-deep); }

.btn--on-dark { --btn-fg: var(--paper); border-color: var(--line-dark); }
.btn--on-dark:hover { --btn-bg: var(--paper); --btn-fg: var(--dark); border-color: var(--paper); }

.btn--lg { padding: 14px 26px; font-size: 16px; }

/* Text link with arrow */
.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 15px;
  font-weight: 500;
  color: var(--clay-deep);
}
.arrow-link svg { transition: transform 0.3s var(--ease); }
.arrow-link:hover svg { transform: translateX(4px); }

.arrow-link--ink { color: var(--ink); }
.arrow-link--ink:hover { color: var(--clay-deep); }

/* --------------------------------------------------------------- header -- */

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  background: rgba(250, 249, 245, 0.82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
  background: rgba(250, 249, 245, 0.94);
}

.site-header.is-open { background: var(--paper); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 0 0 var(--r-sm) 0;
}
.skip-link:focus { left: 0; }

/* promo strip */
.promo {
  background: var(--dark);
  color: var(--paper);
  font-size: 13.5px;
}
.promo__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 38px;
  max-width: var(--maxw-wide);
  margin-inline: auto;
  padding: 6px var(--gutter);
  text-align: center;
}
.promo a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--paper);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  text-decoration-color: rgba(250, 249, 245, 0.4);
}
.promo a:hover { color: var(--clay-soft); }
.promo__close {
  position: absolute;
  right: var(--gutter);
  padding: 6px;
  color: var(--muted-dark);
  border-radius: var(--r-xs);
}
.promo__close:hover { color: var(--paper); }
.promo__inner { position: relative; }

.header-inner {
  display: flex;
  align-items: center;
  gap: 18px;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
  font-weight: 500;
  letter-spacing: -0.02em;
  font-size: 18px;
}
.brand-mark { width: 22px; height: 22px; color: var(--clay-deep); }
.brand-mark circle { transition: opacity 0.4s var(--ease); transform-origin: center; }
.brand:hover .brand-mark circle { opacity: 1; }

/* primary nav */
.primary-nav { margin-inline: auto; }
.primary-nav > ul { display: flex; align-items: center; gap: 2px; }

.nav-link,
.nav-trigger {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 12px;
  border-radius: var(--r-sm);
  font-size: 15px;
  color: var(--ink-2);
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
}
.nav-link:hover,
.nav-trigger:hover { color: var(--ink); background: rgba(20, 20, 19, 0.05); }

.nav-link.is-active,
.nav-trigger.is-active,
.nav-link[data-active],
.nav-trigger[data-active] { color: var(--ink); }

.nav-trigger .chev {
  width: 9px;
  height: 9px;
  transition: transform 0.3s var(--ease);
}
.nav-trigger[aria-expanded="true"] .chev { transform: rotate(180deg); }

.header-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

/* mega menu */
.mega {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  background: var(--paper);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 24px 48px -24px rgba(20, 20, 19, 0.22);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.28s var(--ease), transform 0.28s var(--ease), visibility 0.28s;
}
.mega.is-open { opacity: 1; visibility: visible; transform: none; }

.mega__inner {
  max-width: var(--maxw-wide);
  margin-inline: auto;
  padding: 36px var(--gutter) 40px;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 40px;
}

.mega__intro .eyebrow { display: block; margin-bottom: 10px; }
.mega__intro p { font-size: 14.5px; color: var(--muted); max-width: 30ch; }

.mega__cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 28px 36px;
}

.mega__col h3 {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}

.mega__col li + li { margin-top: 2px; }

.mega__link {
  display: block;
  padding: 7px 10px;
  margin-left: -10px;
  border-radius: var(--r-sm);
  font-size: 15px;
  color: var(--ink-2);
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.mega__link:hover { background: var(--paper-2); color: var(--ink); }
.mega__link span { display: block; font-size: 13px; color: var(--muted); }

/* burger */
.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  align-items: center;
  justify-content: center;
}
.nav-toggle:hover { background: rgba(20, 20, 19, 0.06); }
.nav-toggle span {
  position: relative;
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--ink);
  transition: background 0.2s var(--ease);
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s var(--ease);
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

/* mobile drawer */
.drawer {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: var(--paper);
  padding: calc(var(--header-total) + 32px) var(--gutter) 48px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
}
.drawer.is-open { opacity: 1; visibility: visible; transform: none; }

.drawer__group + .drawer__group { margin-top: 28px; }
.drawer__group h3 {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}
.drawer__link {
  display: block;
  padding: 12px 0;
  font-size: 19px;
  font-family: var(--serif);
  border-bottom: 1px solid var(--line);
}
.drawer__cta { display: grid; gap: 10px; margin-top: 32px; }
.drawer__cta .btn { justify-content: center; }

/* ---------------------------------------------------------------- hero -- */

.hero {
  padding-top: calc(var(--header-h) + clamp(56px, 9vw, 120px));
  padding-bottom: clamp(56px, 8vw, 104px);
  position: relative;
  overflow: hidden;
}

.hero--tall { padding-bottom: clamp(72px, 11vw, 150px); }

.hero__glow {
  position: absolute;
  z-index: 0;
  width: min(900px, 110vw);
  aspect-ratio: 1;
  right: -22%;
  top: -32%;
  background:
    radial-gradient(closest-side, rgba(217, 119, 87, 0.30), rgba(217, 119, 87, 0.06) 62%, transparent 72%),
    radial-gradient(closest-side at 62% 58%, rgba(106, 155, 204, 0.16), transparent 70%);
  filter: blur(10px);
  pointer-events: none;
}

.hero__inner { position: relative; z-index: 1; }

.hero h1 {
  font-family: var(--serif);
  font-size: clamp(40px, 7.4vw, 92px);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1.01;
  max-width: 18ch;
}

.hero h1 a {
  color: var(--clay-deep);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.08em;
  text-decoration-color: rgba(217, 119, 87, 0.45);
  transition: text-decoration-color 0.3s var(--ease);
}
.hero h1 a:hover { text-decoration-color: var(--clay); }

.hero__body {
  margin-top: 28px;
  max-width: 60ch;
  font-size: clamp(17px, 1.5vw, 21px);
  line-height: 1.5;
  color: var(--ink-2);
  text-wrap: pretty;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  margin-top: 44px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--muted);
}
.hero__meta strong { color: var(--ink); font-weight: 500; }

/* page hero (inner pages) */
.page-hero { padding-top: calc(var(--header-h) + clamp(48px, 7vw, 96px)); }
.page-hero h1 {
  font-family: var(--serif);
  font-size: clamp(36px, 5.6vw, 68px);
  letter-spacing: -0.032em;
  max-width: 22ch;
}
.page-hero .lede { margin-top: 22px; }

.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  margin-top: 22px;
}

.breadcrumbs {
  display: flex;
  gap: 8px;
  align-items: center;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 20px;
}
.breadcrumbs a:hover { color: var(--ink); }

/* --------------------------------------------------------------- cards -- */

.card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 28px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  transition: border-color 0.35s var(--ease), transform 0.35s var(--ease),
              box-shadow 0.35s var(--ease);
}
.card:hover {
  border-color: var(--line-strong);
  transform: translateY(-3px);
  box-shadow: 0 20px 40px -28px rgba(20, 20, 19, 0.35);
}
.card h3 {
  font-family: var(--serif);
  font-size: 24px;
  letter-spacing: -0.02em;
}
.card p { color: var(--ink-2); font-size: 15.5px; }
.card__foot { margin-top: auto; padding-top: 10px; }

.card--dark {
  background: var(--dark-2);
  border-color: var(--line-dark);
  color: var(--paper);
}
.card--dark p { color: var(--muted-dark); }

/* model callout */
.callout {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 0;
  background: var(--dark);
  color: var(--paper);
  border-radius: var(--r-xl);
  overflow: hidden;
}
.callout__copy { padding: clamp(32px, 5vw, 64px); }
.callout__copy h2 {
  font-family: var(--serif);
  font-size: clamp(30px, 3.8vw, 50px);
  letter-spacing: -0.03em;
  margin-top: 14px;
}
.callout__copy p { color: var(--muted-dark); margin-top: 18px; max-width: 46ch; }
.callout__copy .arrow-link { margin-top: 28px; color: var(--clay-soft); }
.callout__viz {
  position: relative;
  min-height: 320px;
  background:
    radial-gradient(120% 90% at 80% 15%, rgba(217, 119, 87, 0.42), transparent 60%),
    radial-gradient(90% 80% at 12% 90%, rgba(106, 155, 204, 0.24), transparent 62%),
    var(--dark-3);
  display: grid;
  place-items: center;
  padding: 32px;
}
.callout__viz svg { width: min(320px, 78%); color: rgba(250, 249, 245, 0.9); }

@media (max-width: 860px) {
  .callout { grid-template-columns: 1fr; }
  .callout__viz { min-height: 220px; order: -1; }
}

/* release list */
.release {
  display: grid;
  grid-template-columns: 150px 1fr auto;
  gap: 24px;
  align-items: baseline;
  padding: 26px 0;
  border-top: 1px solid var(--line);
  transition: background 0.3s var(--ease);
}
.release:last-child { border-bottom: 1px solid var(--line); }
.release:hover { background: rgba(20, 20, 19, 0.02); }
.release__date { font-family: var(--mono); font-size: 12.5px; color: var(--muted); letter-spacing: 0.04em; }
.release__title { font-family: var(--serif); font-size: clamp(21px, 2.2vw, 28px); letter-spacing: -0.02em; }
.release__title + p { margin-top: 8px; color: var(--ink-2); font-size: 15.5px; max-width: 62ch; }
.release__meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.release__cta { white-space: nowrap; }

@media (max-width: 800px) {
  .release { grid-template-columns: 1fr; gap: 12px; }
  .release__cta { justify-self: start; }
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.chip--clay { color: var(--clay-deep); border-color: rgba(217, 119, 87, 0.4); }

/* link tiles */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.tile {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 36px;
  min-height: 190px;
  padding: 26px;
  background: var(--paper);
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}
.tile:hover { background: var(--paper-2); }
.tile__cat { font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.tile__title { font-family: var(--serif); font-size: 23px; letter-spacing: -0.02em; }
.tile__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tile__arrow { color: var(--clay-deep); transform: translateX(-4px); opacity: 0; transition: all 0.3s var(--ease); }
.tile:hover .tile__arrow { transform: none; opacity: 1; }

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

/* ------------------------------------------------------------ editorial -- */

.mission {
  text-align: center;
  padding-block: clamp(72px, 11vw, 148px);
}
.mission p {
  font-family: var(--serif);
  font-size: clamp(28px, 4.4vw, 58px);
  line-height: 1.12;
  letter-spacing: -0.03em;
  max-width: 24ch;
  margin-inline: auto;
  text-wrap: balance;
}
.mission p em { font-style: italic; color: var(--clay-deep); }

.prose { max-width: 68ch; }
.prose h2 {
  font-family: var(--serif);
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -0.026em;
  margin-top: 56px;
}
.prose h3 {
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.012em;
  margin-top: 36px;
}
.prose p { margin-top: 16px; color: var(--ink-2); text-wrap: pretty; }
.prose ul { margin-top: 16px; display: grid; gap: 10px; }
.prose ul li {
  position: relative;
  padding-left: 22px;
  color: var(--ink-2);
}
.prose ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0.68em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--clay);
}
.prose blockquote {
  margin: 32px 0 0;
  padding-left: 24px;
  border-left: 2px solid var(--clay);
  font-family: var(--serif);
  font-size: 23px;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.sidebar-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.side-nav { position: sticky; top: calc(var(--header-h) + 32px); }
.side-nav h4 {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}
.side-nav a {
  display: block;
  padding: 7px 0;
  font-size: 15px;
  color: var(--ink-2);
}
.side-nav a:hover, .side-nav a.is-active { color: var(--clay-deep); }

@media (max-width: 900px) {
  .sidebar-layout { grid-template-columns: 1fr; }
  .side-nav { position: static; }
}

/* stat row */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border-block: 1px solid var(--line); }
.stat { background: var(--paper); padding: 28px 24px; }
.stat dt { font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.stat dd { margin: 12px 0 0; font-family: var(--serif); font-size: clamp(30px, 3.4vw, 44px); letter-spacing: -0.03em; }
.stat dd span {
  display: block;
  margin-top: 8px;
  font-family: var(--sans);
  font-size: 14px;
  letter-spacing: -0.005em;
  line-height: 1.5;
  color: var(--muted);
}
@media (max-width: 900px) { .stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .stats { grid-template-columns: 1fr; } }

/* timeline */
.timeline { display: grid; gap: 0; }
.timeline__item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 28px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
}
.timeline__item:last-child { border-bottom: 1px solid var(--line); }
.timeline__year { font-family: var(--mono); font-size: 13px; color: var(--clay-deep); letter-spacing: 0.08em; }
.timeline__item h3 { font-family: var(--serif); font-size: 22px; letter-spacing: -0.02em; }
.timeline__item p { margin-top: 8px; color: var(--ink-2); font-size: 15.5px; max-width: 60ch; }
@media (max-width: 700px) { .timeline__item { grid-template-columns: 1fr; gap: 10px; } }

/* job list */
.job {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 0;
  border-top: 1px solid var(--line);
  transition: padding-left 0.3s var(--ease), color 0.3s var(--ease);
}
.job:last-of-type { border-bottom: 1px solid var(--line); }
.job:hover { padding-left: 10px; color: var(--clay-deep); }
.job h3 { font-size: 18px; font-weight: 500; letter-spacing: -0.012em; }
.job__dept { font-family: var(--mono); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }

/* --------------------------------------------------------------- table -- */

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--paper);
}

.table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  font-size: 15px;
  text-align: left;
}

.table th,
.table td {
  padding: 18px 22px;
  vertical-align: top;
  text-align: left;
}

.table thead th {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--paper-2);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.table tbody tr + tr th,
.table tbody tr + tr td { border-top: 1px solid var(--line); }

.table tbody th {
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
}

.table tbody td { color: var(--ink-2); }
.table tbody tr { transition: background 0.25s var(--ease); }
.table tbody tr:hover { background: rgba(20, 20, 19, 0.02); }

.tier {
  display: inline-grid;
  place-items: center;
  min-width: 26px;
  height: 22px;
  margin-right: 10px;
  padding-inline: 7px;
  border-radius: var(--r-xs);
  background: var(--clay);
  color: #fff;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.04em;
}

/* ---------------------------------------------------------------- note -- */

.note {
  max-width: 78ch;
  padding: 22px 26px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-left: 3px solid var(--clay);
  border-radius: var(--r-sm);
  font-size: 15.5px;
  color: var(--ink-2);
}
.note strong { color: var(--ink); font-weight: 600; }

/* --------------------------------------------------------- spec list -- */

.spec {
  display: grid;
  gap: 0;
  margin: 4px 0 0;
  border-top: 1px solid var(--line);
}
.spec > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.spec dt { color: var(--muted); }
.spec dd { margin: 0; color: var(--ink); text-align: right; }

/* ---------------------------------------------------------- code block -- */

.codeblock {
  border: 1px solid var(--line-dark);
  border-radius: var(--r);
  overflow: hidden;
  background: var(--dark);
  box-shadow: 0 28px 56px -32px rgba(20, 20, 19, 0.5);
}
.codeblock__bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-dark);
  background: var(--dark-2);
}
.codeblock__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(250, 249, 245, 0.16);
}
.codeblock__dot:first-child { background: var(--clay); }
.codeblock__name {
  margin-left: 8px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted-dark);
}
.codeblock pre {
  margin: 0;
  padding: 22px;
  overflow-x: auto;
}
.codeblock code {
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.75;
  color: #e8e6dc;
  white-space: pre;
}

/* ------------------------------------------------------------- filters -- */

.filters { display: flex; flex-wrap: wrap; gap: 8px; }

.filter {
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  font-size: 14px;
  color: var(--ink-2);
  transition: background 0.25s var(--ease), color 0.25s var(--ease),
              border-color 0.25s var(--ease);
}
.filter:hover { border-color: var(--line-strong); }
.filter.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.feed { margin-top: 4px; }

/* --------------------------------------------------------------- forms -- */

.field { display: grid; gap: 8px; }
.field + .field { margin-top: 18px; }

.field label {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.field input,
.field select,
.field textarea,
.subscribe input {
  width: 100%;
  padding: 13px 15px;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

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

.field input:focus,
.field select:focus,
.field textarea:focus,
.subscribe input:focus {
  outline: none;
  border-color: var(--clay);
  box-shadow: 0 0 0 3px rgba(217, 119, 87, 0.16);
}

.field input::placeholder,
.field textarea::placeholder,
.subscribe input::placeholder { color: var(--muted); }

.contact-form .btn { margin-top: 22px; }

.subscribe {
  display: flex;
  gap: 10px;
  margin-top: 22px;
  max-width: 460px;
}
.subscribe input { flex: 1; }
.subscribe .btn { flex-shrink: 0; }

@media (max-width: 520px) {
  .subscribe { flex-direction: column; }
}

/* --------------------------------------------------------------- footer -- */

.site-footer {
  background: var(--dark);
  color: var(--muted-dark);
  padding-top: clamp(56px, 7vw, 88px);
  font-size: 14.5px;
}
.site-footer a:hover { color: var(--paper); }

.footer__top {
  display: grid;
  grid-template-columns: 1.2fr repeat(4, minmax(0, 1fr));
  gap: 36px 28px;
  padding-bottom: 56px;
}
.footer__brand { color: var(--paper); }
.footer__brand .brand-mark { color: var(--clay); }
.footer__brand p { margin-top: 16px; max-width: 30ch; font-size: 14px; color: var(--muted); }

.footer__col h4 {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--paper);
  margin-bottom: 14px;
}
.footer__col li + li { margin-top: 9px; }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 28px 0 40px;
  border-top: 1px solid var(--line-dark);
  font-size: 13.5px;
}
.footer__legal { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.footer__social { display: flex; gap: 6px; }
.footer__social a {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line-dark);
  border-radius: 50%;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}
.footer__social a:hover { background: var(--paper); color: var(--dark); border-color: var(--paper); }

.footer__wordmark {
  font-family: var(--serif);
  font-size: clamp(60px, 17vw, 260px);
  line-height: 0.82;
  letter-spacing: -0.05em;
  color: rgba(250, 249, 245, 0.06);
  text-align: center;
  padding-bottom: 12px;
  user-select: none;
  pointer-events: none;
}

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

/* --------------------------------------------------------- cookie modal -- */

.cookie {
  position: fixed;
  z-index: 120;
  left: var(--gutter);
  bottom: var(--gutter);
  width: min(440px, calc(100vw - var(--gutter) * 2));
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-lg);
  box-shadow: 0 32px 64px -32px rgba(20, 20, 19, 0.45);
  padding: 26px;
  transform: translateY(16px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease), visibility 0.4s;
}
.cookie.is-open { opacity: 1; visibility: visible; transform: none; }
.cookie h2 { font-family: var(--serif); font-size: 22px; }
.cookie p { margin-top: 10px; font-size: 14px; color: var(--ink-2); }

.cookie__rows { margin-top: 18px; display: grid; gap: 12px; }
.cookie__row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
}
.cookie__row strong { font-size: 14px; font-weight: 500; display: block; }
.cookie__row span { font-size: 13px; color: var(--muted); }
.cookie__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.cookie__actions .btn { padding: 9px 16px; font-size: 14px; }

.switch { position: relative; flex-shrink: 0; width: 38px; height: 22px; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.switch span {
  position: absolute;
  inset: 0;
  background: var(--paper-3);
  border-radius: var(--r-pill);
  transition: background 0.3s var(--ease);
  pointer-events: none;
}
.switch span::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
  transition: transform 0.3s var(--ease);
}
.switch input:checked + span { background: var(--clay); }
.switch input:checked + span::after { transform: translateX(16px); }
.switch input:disabled + span { opacity: 0.65; }
.switch input:focus-visible + span { outline: 2px solid var(--clay); outline-offset: 2px; }

/* ------------------------------------------------------------ to-top -- */

.to-top {
  position: fixed;
  right: var(--gutter);
  bottom: var(--gutter);
  z-index: 80;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
  box-shadow: 0 12px 28px -14px rgba(20, 20, 19, 0.6);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease), visibility 0.35s, background 0.3s;
}
.to-top.is-open { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--clay-deep); }

/* The cookie dialog occupies the same bottom corner on narrow screens. */
body.cookie-open .to-top { opacity: 0; visibility: hidden; transform: translateY(10px); }

/* --------------------------------------------------------------- toast -- */

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--gutter) + 6px);
  z-index: 130;
  max-width: min(440px, calc(100vw - var(--gutter) * 2));
  padding: 12px 20px;
  background: var(--ink);
  color: var(--paper);
  border-radius: var(--r-pill);
  box-shadow: 0 20px 44px -20px rgba(20, 20, 19, 0.6);
  font-size: 14px;
  line-height: 1.4;
  text-align: center;
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 14px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
}
.toast.is-open { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* --------------------------------------------------------- reveal anim -- */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  will-change: opacity, transform;
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
}

/* ---------------------------------------------------------------- misc -- */

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.spotlight {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
@media (max-width: 900px) { .spotlight { grid-template-columns: 1fr; } }

.person { display: grid; gap: 14px; }
.person__photo {
  aspect-ratio: 4 / 5;
  border-radius: var(--r);
  background:
    linear-gradient(160deg, var(--paper-3), var(--paper-2));
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 40px;
  color: var(--muted);
  border: 1px solid var(--line);
}
.person h3 { font-size: 17px; font-weight: 500; letter-spacing: -0.012em; }
.person p { font-size: 14px; color: var(--muted); }

/* responsive nav breakpoint */
@media (max-width: 1080px) {
  .primary-nav { display: none; }
  .nav-toggle { display: inline-flex; }
  .header-actions .btn--ghost { display: none; }
}
@media (max-width: 560px) {
  .header-actions .btn--primary { display: none; }
  .promo { font-size: 12.5px; }
}

/* ------------------------------------------------------- language toggle -- */

/* Always visible — including mobile, where the other header actions collapse
   into the drawer. Must not inherit the .btn ghost/primary hiding rules. */
.lang-toggle {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  padding: 8px 13px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-pill);
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.05em;
  color: var(--ink-2);
  transition: background 0.25s var(--ease), color 0.25s var(--ease),
              border-color 0.25s var(--ease);
}
.lang-toggle:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

/* Pill linking back to the desktop hub, styled like the language toggle. */
.hub-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-pill);
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--ink-2);
  transition: background 0.25s var(--ease), color 0.25s var(--ease),
              border-color 0.25s var(--ease);
}
.hub-link:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}
.hub-link svg { flex-shrink: 0; }

/* ==========================================================================
   HUB — the Neurok desktop launcher. A deliberately different visual
   language from the Studio Classic desktop: near-black ground, cool
   electric accents, grotesk display type, chat-input hero.
   Scoped under body.hub so it never leaks into the classic pages.
   ========================================================================== */

body.hub {
  --hub-bg:      #0a0c10;
  --hub-bg-2:    #10131a;
  --hub-panel:   #141821;
  --hub-line:    rgba(232, 234, 240, 0.12);
  --hub-line-2:  rgba(232, 234, 240, 0.22);
  --hub-text:    #e8eaf0;
  --hub-muted:   #8b93a7;
  --hub-cyan:    #7dd3fc;
  --hub-violet:  #a78bfa;
  --hub-pink:    #f0abfc;
  --hub-display: "Space Grotesk", var(--sans);

  background: var(--hub-bg);
  color: var(--hub-text);
  font-size: 16.5px;
}

body.hub ::selection { background: rgba(167, 139, 250, 0.35); color: #fff; }
body.hub a { color: inherit; text-decoration: none; }

/* ------------------------------------------------------------- top bar -- */

.hub-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 12, 16, 0.78);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--hub-line);
}

.hub-bar {
  max-width: 1160px;
  margin-inline: auto;
  padding: 14px var(--gutter);
  display: flex;
  align-items: center;
  gap: 22px;
}

.hub-brand {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  flex-shrink: 0;
}
.hub-mark { width: 26px; height: 26px; align-self: center; }
.hub-brand-name {
  font-family: var(--hub-display);
  font-weight: 700;
  font-size: 19px;
  letter-spacing: 0.01em;
}
.hub-brand-zh {
  font-size: 13px;
  color: var(--hub-muted);
  letter-spacing: 0.2em;
}

.hub-nav {
  margin-inline: auto;
  display: flex;
  gap: 4px;
}
.hub-nav a {
  padding: 8px 13px;
  border-radius: var(--r-xs);
  font-size: 14.5px;
  color: var(--hub-muted);
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}
.hub-nav a:hover { color: var(--hub-text); background: rgba(232, 234, 240, 0.06); }

.hub-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.hub-pill {
  padding: 8px 13px;
  border: 1px solid var(--hub-line-2);
  border-radius: var(--r-pill);
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--hub-muted);
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease),
              background 0.25s var(--ease);
}
.hub-pill:hover {
  color: var(--hub-text);
  border-color: var(--hub-cyan);
  background: rgba(125, 211, 252, 0.08);
}

.hub-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: var(--r-pill);
  background: linear-gradient(120deg, var(--hub-cyan), var(--hub-violet));
  color: #0a0c10;
  font-weight: 600;
  font-size: 14.5px;
  transition: transform 0.2s var(--ease), box-shadow 0.25s var(--ease);
}
.hub-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 28px -12px rgba(125, 211, 252, 0.55);
}

@media (max-width: 760px) {
  .hub-nav { display: none; }
  .hub-cta span { display: none; }
  .hub-brand-zh { display: none; }
}

/* --------------------------------------------------------------- hero -- */

.hub-hero {
  position: relative;
  max-width: 980px;
  margin-inline: auto;
  padding: clamp(72px, 12vw, 150px) var(--gutter) clamp(44px, 6vw, 80px);
  text-align: center;
  overflow: hidden;
}

.hub-glow {
  position: absolute;
  inset: -40% -20% auto;
  height: 130%;
  z-index: 0;
  background:
    radial-gradient(42% 38% at 30% 22%, rgba(125, 211, 252, 0.16), transparent 70%),
    radial-gradient(46% 40% at 72% 30%, rgba(167, 139, 250, 0.16), transparent 70%),
    radial-gradient(30% 30% at 55% 70%, rgba(240, 171, 252, 0.09), transparent 70%);
  filter: blur(6px);
  pointer-events: none;
  animation: hub-drift 18s var(--ease) infinite alternate;
}
@keyframes hub-drift {
  from { transform: translate3d(-2%, -1%, 0) scale(1); }
  to   { transform: translate3d(2%, 2%, 0) scale(1.08); }
}
@media (prefers-reduced-motion: reduce) {
  .hub-glow { animation: none; }
}

.hub-hero > * { position: relative; z-index: 1; }

.hub-eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--hub-cyan);
}

.hub-hero h1 {
  margin-top: 22px;
  font-family: var(--hub-display);
  font-weight: 700;
  font-size: clamp(40px, 8vw, 84px);
  line-height: 1.04;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.hub-hero h1 em {
  font-style: normal;
  background: linear-gradient(100deg, var(--hub-cyan) 10%, var(--hub-violet) 55%, var(--hub-pink) 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hub-sub {
  margin: 22px auto 0;
  max-width: 56ch;
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.65;
  color: var(--hub-muted);
  text-wrap: pretty;
}

/* chat input */
.hub-input {
  margin: 40px auto 0;
  max-width: 640px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 10px 10px 18px;
  background: rgba(20, 24, 33, 0.9);
  border: 1px solid var(--hub-line-2);
  border-radius: var(--r-pill);
  box-shadow: 0 24px 64px -32px rgba(0, 0, 0, 0.8),
              0 0 0 1px rgba(125, 211, 252, 0.06);
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.hub-input:focus-within {
  border-color: rgba(125, 211, 252, 0.55);
  box-shadow: 0 24px 64px -28px rgba(0, 0, 0, 0.85),
              0 0 0 4px rgba(125, 211, 252, 0.1);
}

.hub-model {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  padding: 5px 11px;
  border: 1px solid var(--hub-line-2);
  border-radius: var(--r-pill);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.05em;
  color: var(--hub-muted);
}
.hub-model i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(120deg, var(--hub-cyan), var(--hub-violet));
}

.hub-input input {
  flex: 1;
  min-width: 0;
  background: none;
  border: 0;
  outline: none;
  font: inherit;
  color: var(--hub-text);
}
.hub-input input::placeholder { color: var(--hub-muted); opacity: 0.75; }

.hub-send {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(120deg, var(--hub-cyan), var(--hub-violet));
  color: #0a0c10;
  transition: transform 0.2s var(--ease);
}
.hub-send:hover { transform: scale(1.06); }
.hub-send:active { transform: scale(0.96); }

@media (max-width: 560px) {
  .hub-model { display: none; }
}

/* suggestion chips */
.hub-chips {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.hub-chip {
  padding: 8px 15px;
  border: 1px solid var(--hub-line);
  border-radius: var(--r-pill);
  font-size: 13.5px;
  color: var(--hub-muted);
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease),
              background 0.2s var(--ease);
}
.hub-chip:hover {
  color: var(--hub-text);
  border-color: var(--hub-line-2);
  background: rgba(232, 234, 240, 0.05);
}

/* ---------------------------------------------------------- desktops -- */

.hub-desktops {
  max-width: 1160px;
  margin-inline: auto;
  padding: clamp(20px, 4vw, 48px) var(--gutter) clamp(72px, 9vw, 120px);
}

.hub-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: clamp(26px, 4vw, 40px);
}
.hub-section-head h2 {
  font-family: var(--hub-display);
  font-weight: 700;
  font-size: clamp(26px, 3.6vw, 40px);
  letter-spacing: -0.02em;
}
.hub-section-head p {
  margin: 0;
  max-width: 46ch;
  color: var(--hub-muted);
  font-size: 15.5px;
}

.hub-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 900px) { .hub-grid { grid-template-columns: 1fr; } }

.hub-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--hub-line);
  border-radius: var(--r-lg);
  background: var(--hub-panel);
  overflow: hidden;
  transition: border-color 0.3s var(--ease), transform 0.3s var(--ease),
              box-shadow 0.3s var(--ease);
}
a.hub-card:hover {
  border-color: rgba(125, 211, 252, 0.4);
  transform: translateY(-4px);
  box-shadow: 0 28px 56px -30px rgba(0, 0, 0, 0.9);
}

/* miniature style preview inside each card */
.hub-swatch {
  position: relative;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: flex-end;
  padding: 16px;
  border-bottom: 1px solid var(--hub-line);
}
.hub-swatch-title {
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1;
  letter-spacing: -0.02em;
}
.hub-swatch i {
  position: absolute;
  border-radius: 4px;
  opacity: 0.5;
}

.hub-swatch--paper {
  background:
    radial-gradient(120% 100% at 85% 0%, #f5ecdf, #faf9f5 55%);
  color: #141413;
}
.hub-swatch--paper .hub-swatch-title { font-family: var(--serif); font-weight: 400; }
.hub-swatch--paper i { background: #d97757; }
.hub-swatch--paper i:nth-child(2) { width: 34%; height: 8px; left: 16px; top: 22px; opacity: 0.25; }
.hub-swatch--paper i:nth-child(3) { width: 24%; height: 8px; left: 16px; top: 36px; opacity: 0.18; }
.hub-swatch--paper i:nth-child(4) { width: 8px; height: 8px; border-radius: 50%; right: 16px; top: 16px; }

.hub-swatch--term {
  background: #06080a;
  color: #7dd3fc;
}
.hub-swatch--term .hub-swatch-title { font-family: var(--mono); font-size: clamp(20px, 3vw, 30px); }
.hub-swatch--term .hub-swatch-title::after { content: "_"; animation: hub-blink 1.1s steps(1) infinite; }
@keyframes hub-blink { 50% { opacity: 0; } }
.hub-swatch--term i { background: #22303f; }
.hub-swatch--term i:nth-child(2) { width: 40%; height: 6px; left: 16px; top: 24px; }
.hub-swatch--term i:nth-child(3) { width: 28%; height: 6px; left: 16px; top: 36px; opacity: 0.6; }
.hub-swatch--term i:nth-child(4) { width: 16%; height: 6px; left: 16px; top: 48px; opacity: 0.3; }

.hub-swatch--canvas {
  background:
    linear-gradient(135deg, #1b1440 0%, #3b1d5e 45%, #0e2f4d 100%);
  color: transparent;
}
.hub-swatch--canvas .hub-swatch-title {
  font-family: var(--hub-display);
  background: linear-gradient(100deg, #f0abfc, #7dd3fc);
  -webkit-background-clip: text;
  background-clip: text;
}
.hub-swatch--canvas i { background: rgba(255, 255, 255, 0.25); }
.hub-swatch--canvas i:nth-child(2) { width: 30%; height: 30%; border-radius: 50%; right: 12%; top: 14%; filter: blur(2px); }
.hub-swatch--canvas i:nth-child(3) { width: 18%; height: 18%; border-radius: 50%; right: 32%; top: 38%; opacity: 0.6; filter: blur(2px); }

.hub-swatch--print {
  background: #fdfcf8;
  color: #16150f;
  border-bottom: 2px solid #16150f;
}
.hub-swatch--print .hub-swatch-title {
  font-family: var(--hub-display);
  font-weight: 700;
  font-size: clamp(22px, 3.2vw, 32px);
  letter-spacing: 0.01em;
}
.hub-swatch--print i { background: #16150f; }
.hub-swatch--print i:nth-child(2) { width: 42%; height: 8px; left: 16px; top: 20px; }
.hub-swatch--print i:nth-child(3) { width: 20%; height: 20px; right: 16px; top: 16px; background: #e11d48; }

.hub-swatch--mono {
  background: #ffffff;
  color: #111110;
  border-bottom: 1px solid rgba(17, 17, 16, 0.14);
}
.hub-swatch--mono .hub-swatch-title {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(24px, 3.4vw, 34px);
  letter-spacing: -0.03em;
}
.hub-swatch--mono i { background: rgba(17, 17, 16, 0.16); }
.hub-swatch--mono i:nth-child(2) { width: 36%; height: 1px; left: 16px; top: 24px; }
.hub-swatch--mono i:nth-child(3) { width: 26%; height: 1px; left: 16px; top: 34px; opacity: 0.6; }
.hub-swatch--mono i:nth-child(4) { width: 10px; height: 10px; border-radius: 50%; right: 16px; top: 16px; opacity: 0.4; }

.hub-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px 24px 26px;
  flex: 1;
}

.hub-card-tag {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--hub-cyan);
}
.hub-card--soon .hub-card-tag { color: var(--hub-muted); }

.hub-card-body h3 {
  font-family: var(--hub-display);
  font-weight: 600;
  font-size: 22px;
  letter-spacing: -0.01em;
}

.hub-card-body > p:not(.hub-card-tag) {
  margin: 0;
  color: var(--hub-muted);
  font-size: 14.5px;
  line-height: 1.65;
}

.hub-card-cta {
  margin-top: auto;
  padding-top: 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--hub-text);
}
.hub-card-cta svg { transition: transform 0.25s var(--ease); }
a.hub-card:hover .hub-card-cta svg { transform: translateX(4px); }

.hub-card--soon { opacity: 0.72; }
.hub-card--soon .hub-card-cta {
  color: var(--hub-muted);
  cursor: pointer;
}

/* -------------------------------------------------------------- footer -- */

.hub-footer {
  border-top: 1px solid var(--hub-line);
}
.hub-footer-inner {
  max-width: 1160px;
  margin-inline: auto;
  padding: 30px var(--gutter) 40px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 24px;
  color: var(--hub-muted);
  font-size: 13.5px;
}
.hub-footer-inner p { margin: 0; }
.hub-footer-links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.hub-footer-links a:hover { color: var(--hub-text); }

/* print: hub keeps its dark ground off paper */
@media print {
  body.hub { background: #fff; color: #000; }
  .hub-header, .hub-glow { display: none; }
}

/* ------------------------------------------------------ CJK typography -- */

/* Chinese text carries its own density: negative tracking that sharpens Latin
   display type only cramps CJK, and tight line-heights clip punctuation. */
html[lang^="zh"] .hero h1,
html[lang^="zh"] .page-hero h1,
html[lang^="zh"] .section-head h2,
html[lang^="zh"] .callout__copy h2,
html[lang^="zh"] .mission p,
html[lang^="zh"] .tile__title,
html[lang^="zh"] .release__title,
html[lang^="zh"] .card h3,
html[lang^="zh"] .timeline__item h3,
html[lang^="zh"] .prose h2,
html[lang^="zh"] .prose blockquote {
  letter-spacing: -0.012em;
  line-height: 1.22;
}

html[lang^="zh"] .eyebrow,
html[lang^="zh"] .chip,
html[lang^="zh"] .tile__cat,
html[lang^="zh"] .breadcrumbs,
html[lang^="zh"] .release__date,
html[lang^="zh"] .timeline__year,
html[lang^="zh"] .footer__col h4,
html[lang^="zh"] .side-nav h4,
html[lang^="zh"] .mega__col h3,
html[lang^="zh"] .field label,
html[lang^="zh"] .table thead th,
html[lang^="zh"] .stat dt {
  letter-spacing: 0.08em;
}

html[lang^="zh"] .prose ul li { padding-left: 20px; }
html[lang^="zh"] .lede,
html[lang^="zh"] .prose p,
html[lang^="zh"] .card p { line-height: 1.75; }

/* ---------------------------------------------------------------- print -- */

@media print {
  .site-header,
  .promo,
  .drawer,
  .cookie,
  .toast,
  .to-top,
  .hero__glow,
  .filters { display: none !important; }

  html { scroll-padding-top: 0; }
  body { background: #fff; font-size: 11.5pt; }

  .js [data-reveal] { opacity: 1 !important; transform: none !important; }

  .section,
  .section--tight { padding-block: 16pt; }

  .card, .table-wrap, .codeblock, .release, .stat { break-inside: avoid; }

  h1, h2, h3 { break-after: avoid; }

  /* Show where external links point once the page is on paper. */
  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 9pt;
    color: #555;
  }

  .site-footer {
    background: #fff;
    color: #333;
    border-top: 1px solid #ccc;
  }
  .footer__wordmark { display: none; }
  .footer__col h4 { color: #000; }
}
