/*
 * cohowork.ai (MT-I102; laid out anew in MT-I108 from key-design-docs/landing).
 * Every colour, shadow, radius and spacing step is a token from
 * packages/ui-tokens/src/theme.css, served beside this file as
 * /_gen/theme.css, under data-theme="geek" — the app's orange theme, the one
 * the sign-in page and the rail already wear. Nothing here names a colour;
 * the dark band mixes the same ink and canvas the rest of the page uses.
 *
 * The type sizes are the site's own: the token scale stops at 22px, because
 * it was made for an app. A display heading is not a second copy of anything.
 * Headings here are the sans at its heaviest, as the design draws them; the
 * serif stays on the wordmark.
 *
 * Sides are logical (inline-start / inline-end), never left and right: three
 * of the languages the page ships read right to left.
 *
 * Widths: the three of INVARIANTS U3 — below 520, 520–899, 900 and up.
 */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body.site {
  /* One page width and one gutter, so a full-bleed region's content lines up with the rest. */
  --page: 1280px;
  --gutter: clamp(var(--ar-space-4), 5vw, calc(var(--ar-space-8) * 2));
  --region: calc(var(--ar-space-8) * 3);
  --bleed: max(var(--gutter), calc((100% - var(--page)) / 2 + var(--gutter)));
  /* On the dark band: the canvas as ink, in three strengths. */
  --on-dark: var(--ar-canvas);
  --on-dark-muted: color-mix(in srgb, var(--ar-canvas) 68%, transparent);
  --on-dark-line: color-mix(in srgb, var(--ar-canvas) 14%, transparent);
  margin: 0;
  background: var(--ar-canvas);
  color: var(--ar-fg);
  font-family: var(--ar-font-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
a { color: inherit; }
img { display: block; }
.accent { color: var(--ar-accent); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.icon { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon--accent { color: var(--ar-accent); }
.icon--large { width: 30px; height: 30px; stroke-width: 1.6; }
.icon--small { width: 14px; height: 14px; }
[dir="rtl"] .icon--dir { transform: scaleX(-1); }
/* A square of the accent's tint with the icon in it: every "what is this" mark on the page. */
.tile { flex: none; display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: var(--ar-radius-md); background: var(--ar-accent-soft); color: var(--ar-accent); }
.tile .icon { width: 22px; height: 22px; }
.tile--large { width: 56px; height: 56px; }
.tile--large .icon { width: 26px; height: 26px; }

/* ── brand lockup: the fish and the wordmark, as on the sign-in page ── */
.brand { text-decoration: none; display: inline-flex; }
.brand__lockup { display: inline-flex; align-items: center; gap: var(--ar-space-2); direction: ltr; }
.brand__fish { height: 22px; width: auto; }
.brand__word { font-family: var(--ar-font-display); font-weight: 700; font-size: 24px; letter-spacing: -0.02em; }

/* ── buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--ar-space-2);
  padding: var(--ar-space-3) var(--ar-space-5);
  border-radius: var(--ar-radius-md);
  font: inherit; font-weight: 600; font-size: 15px; text-decoration: none; white-space: nowrap;
  border: 1px solid transparent; cursor: pointer;
}
.btn--primary { background: var(--ar-accent); color: var(--ar-on-accent); box-shadow: var(--ar-shadow-accent); }
.btn--primary:hover { background: var(--ar-accent-hover); }
.btn--ghost { background: var(--ar-surface); color: var(--ar-fg); box-shadow: var(--ar-shadow-card); }
.btn--ghost:hover { background: var(--ar-hover); }
.btn--small { padding: var(--ar-space-2) var(--ar-space-4); font-size: 14px; }
.btn--large { padding: var(--ar-space-4) var(--ar-space-8); font-size: 17px; }
.btn--large .icon { width: 20px; height: 20px; }

/* ── nav ── */
.nav {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: calc(var(--ar-space-8) * 1.5);
  padding: var(--ar-space-4) var(--gutter);
  /* Nearly opaque: the dark band slides under it, and at 88% the bar turned grey. */
  background: color-mix(in srgb, var(--ar-canvas) 96%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--ar-hairline);
}
.nav__links { display: flex; gap: var(--ar-space-8); font-size: 15px; font-weight: 500; }
.nav__links a { text-decoration: none; white-space: nowrap; }
.nav__links a:hover { color: var(--ar-accent); }
.nav__end { margin-inline-start: auto; display: flex; align-items: center; gap: var(--ar-space-3); }

/* The language menu: one button naming the language you are reading, a list of all of them in their own words. */
.langs { position: relative; font-size: 14px; }
.langs summary {
  display: inline-flex; align-items: center; gap: var(--ar-space-2); list-style: none; cursor: pointer;
  padding: var(--ar-space-2) var(--ar-space-3); border-radius: var(--ar-radius-md); color: var(--ar-fg-muted); white-space: nowrap;
}
.langs summary::-webkit-details-marker { display: none; }
.langs summary:hover, .langs[open] summary { background: var(--ar-hover); color: var(--ar-fg); }
.langs ul {
  position: absolute; inset-inline-end: 0; top: calc(100% + var(--ar-space-2));
  list-style: none; margin: 0; padding: var(--ar-space-2);
  display: grid; grid-template-columns: repeat(2, minmax(150px, 1fr)); gap: 2px;
  background: var(--ar-surface); border-radius: var(--ar-radius-card); box-shadow: var(--ar-shadow-pop), var(--ar-shadow-card);
  max-height: 70vh; overflow-y: auto;
}
.langs a { display: block; padding: var(--ar-space-2) var(--ar-space-3); border-radius: var(--ar-radius-sm); text-decoration: none; }
.langs a:hover { background: var(--ar-hover); }
.langs a[aria-current] { background: var(--ar-accent-soft); color: var(--ar-accent); font-weight: 600; }

/* ── regions ── */
.hero, .region, .footer { max-width: var(--page); margin-inline: auto; }
.region { padding: var(--region) var(--gutter) 0; }
/* Full-bleed backgrounds, content on the same line as every other region. */
.region--band, .region--dark {
  max-width: none; margin-top: var(--region);
  padding: var(--region) var(--bleed);
}
.region--band { background: var(--ar-surface-sunken); }
.region--center { text-align: center; padding-bottom: var(--region); }
.region__head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--ar-space-6); }
.region__head .btn, .more { flex: none; }

.display {
  font-family: var(--ar-font-sans); font-weight: 800;
  font-size: clamp(32px, min(3.3vw, 5.6vh), 48px); line-height: 1.1; letter-spacing: -0.03em;
  margin: 0;
}
.display .line { display: block; }
@media (min-width: 900px) { .display .line { white-space: nowrap; } }
.display--section { font-size: clamp(28px, min(3.2vw, 5.2vh), 42px); line-height: 1.1; letter-spacing: -0.03em; text-wrap: balance; }
.display--small { font-size: 40px; }
.eyebrow { margin: 0 0 var(--ar-space-3); font-size: 14px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ar-accent); }
.lead { margin: var(--ar-space-4) 0 0; max-width: 64ch; font-size: 19px; line-height: 1.55; color: var(--ar-fg-muted); }
.more { display: inline-flex; align-items: center; gap: var(--ar-space-2); color: var(--ar-accent); font-weight: 600; text-decoration: none; }
/* Scripts without letter case or with joined letters: no tracking. */
:lang(zh) .display, :lang(ja) .display, :lang(ko) .display, :lang(ar) .display, :lang(fa) .display, :lang(he) .display, :lang(lo) .display { letter-spacing: 0; }
:lang(zh) .eyebrow, :lang(ja) .eyebrow, :lang(ko) .eyebrow, :lang(ar) .eyebrow, :lang(fa) .eyebrow, :lang(he) .eyebrow, :lang(lo) .eyebrow { letter-spacing: 0.04em; }

/* ── hero: the words and the box on one side, the laptop on the other, the four points under both ── */
.hero {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  column-gap: calc(var(--ar-space-8) * 1.5); row-gap: var(--ar-space-8);
  align-items: center;
  padding: calc(var(--ar-space-8) * 1.25) var(--gutter) 0;
  position: relative;
}
/* The warm light behind the laptop, where the design has its sunlit desk. */
.hero::before {
  content: ''; position: absolute; z-index: -1; inset-block: 0; inset-inline: 30% 0;
  background: radial-gradient(60% 60% at 60% 45%, var(--ar-accent-soft), transparent 70%);
}
.hero__text .lead { font-size: 18px; max-width: 46ch; }
.points { grid-column: 1 / -1; }

.ask {
  margin-top: var(--ar-space-6);
  background: var(--ar-surface); border-radius: var(--ar-radius-card);
  box-shadow: var(--ar-shadow-float), var(--ar-shadow-card);
  padding: var(--ar-space-5);
}
.ask:focus-within { box-shadow: var(--ar-shadow-float), 0 0 0 2px var(--ar-accent); }
.ask textarea {
  display: block; width: 100%; resize: none; border: 0; outline: none; background: transparent;
  font: inherit; font-size: 17px; line-height: 1.5; color: var(--ar-fg);
}
.ask textarea::placeholder { color: var(--ar-fg-muted); }
.ask__foot { display: flex; align-items: center; gap: var(--ar-space-3); margin-top: var(--ar-space-3); }
.ask__foot small { flex: 1; color: var(--ar-fg-subtle); font-size: 13px; }
.ask__attach {
  flex: none; display: inline-flex; align-items: center; gap: var(--ar-space-2);
  padding: var(--ar-space-2) var(--ar-space-3); border: 0; border-radius: var(--ar-radius-md);
  background: var(--ar-surface); box-shadow: var(--ar-shadow-card); color: var(--ar-fg); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
}
.ask__attach:hover { background: var(--ar-hover); }
.no-js .ask__attach { display: none; }
/* A file dragged over the box: the box says it will take it. */
.ask.is-drop { box-shadow: var(--ar-shadow-float), 0 0 0 2px var(--ar-accent); background: var(--ar-accent-soft); }
.ask__files { list-style: none; margin: var(--ar-space-3) 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--ar-space-2); }
.ask__files li {
  display: inline-flex; align-items: center; gap: var(--ar-space-2); max-width: 100%;
  padding: var(--ar-space-1) var(--ar-space-1) var(--ar-space-1) var(--ar-space-3); border-radius: var(--ar-radius-pill);
  background: var(--ar-surface-sunken); font-size: 13px;
}
.ask__files .icon { width: 14px; height: 14px; color: var(--ar-accent); }
.ask__files span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ask__files button { flex: none; display: grid; place-items: center; width: 22px; height: 22px; border: 0; border-radius: var(--ar-radius-pill); background: transparent; color: var(--ar-fg-muted); cursor: pointer; font: inherit; line-height: 1; }
.ask__files button:hover { background: var(--ar-hover); color: var(--ar-fg); }
.ask__status { margin: var(--ar-space-2) 0 0; font-size: 13px; color: var(--ar-fg-muted); }
.ask__status.is-bad { color: var(--ar-bad-fg); }
.ask__send {
  display: grid; place-items: center; width: 52px; height: 52px; border: 0; border-radius: var(--ar-radius-md);
  background: var(--ar-accent); color: var(--ar-on-accent); box-shadow: var(--ar-shadow-accent); cursor: pointer;
}
.ask__send:hover { background: var(--ar-accent-hover); }
.ask__send .icon { width: 24px; height: 24px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--ar-space-4); margin-top: var(--ar-space-5); }

.points { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.points li, .facts li { display: flex; gap: var(--ar-space-3); align-items: flex-start; }
.points li + li { border-inline-start: 1px solid var(--ar-hairline); padding-inline-start: var(--ar-space-5); }
.points .icon { width: 28px; height: 28px; }
.points strong, .facts strong { display: block; font-size: 15px; }
.points small, .facts small { display: block; color: var(--ar-fg-muted); font-size: 14px; line-height: 1.45; }

/* ── the laptop: a specialist's screen, drawn ── */
.laptop { position: relative; }
.laptop__screen { background: var(--ar-fg); padding: 10px; border-radius: 18px 18px 6px 6px; box-shadow: var(--ar-shadow-float); }
.laptop__base { height: 14px; margin: 0 -5%; background: var(--ar-hairline); border-radius: 0 0 16px 16px; box-shadow: var(--ar-shadow-float); }
.app { display: grid; grid-template-columns: 116px minmax(0, 1fr); background: var(--ar-surface); border-radius: 8px; overflow: hidden; font-size: 11px; line-height: 1.35; min-height: 380px; }
.app small { color: var(--ar-fg-subtle); font-size: 10px; display: block; }
.app__side { background: var(--ar-canvas); border-inline-end: 1px solid var(--ar-hairline); padding: var(--ar-space-3) var(--ar-space-2); }
.app__brand .brand__fish { height: 12px; }
.app__brand .brand__word { font-size: 13px; }
.app__nav { list-style: none; margin: var(--ar-space-4) 0 0; padding: 0; display: grid; gap: 2px; }
.app__nav li { display: flex; align-items: center; gap: var(--ar-space-2); padding: 6px var(--ar-space-2); border-radius: var(--ar-radius-sm); color: var(--ar-fg-muted); }
.app__nav li.is-on { background: var(--ar-accent-soft); color: var(--ar-accent); font-weight: 600; }
.app__nav .icon { width: 13px; height: 13px; }
.app__main { padding: var(--ar-space-3) var(--ar-space-4); display: grid; gap: var(--ar-space-3); align-content: start; }
.app__bar { display: flex; }
.app__address { display: inline-flex; align-items: center; gap: var(--ar-space-1); padding: 4px var(--ar-space-3); border-radius: var(--ar-radius-pill); background: var(--ar-surface-sunken); color: var(--ar-fg-subtle); font-size: 10px; min-width: 50%; direction: ltr; }
.app__address .icon { width: 11px; height: 11px; }
.app__head { display: flex; align-items: center; gap: var(--ar-space-3); }
.app__head .tile { width: 34px; height: 34px; }
.app__head .tile .icon { width: 18px; height: 18px; }
.app__title { flex: 1; min-width: 0; }
.app__title strong { font-size: 15px; display: block; }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 5px var(--ar-space-2); border-radius: var(--ar-radius-sm); box-shadow: var(--ar-shadow-card); font-weight: 600; white-space: nowrap; }
.chip .icon { width: 12px; height: 12px; }
.chip--solid { background: var(--ar-accent); color: var(--ar-on-accent); box-shadow: none; }
.app__tabs { list-style: none; margin: 0; padding: 0; display: flex; gap: var(--ar-space-5); border-bottom: 1px solid var(--ar-hairline); color: var(--ar-fg-muted); white-space: nowrap; overflow: hidden; }
.app__tabs li { padding-bottom: var(--ar-space-2); }
.app__tabs li.is-on { color: var(--ar-accent); font-weight: 600; box-shadow: inset 0 -2px 0 var(--ar-accent); }
.app__body { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: var(--ar-space-3); }
.app__col { display: grid; gap: var(--ar-space-2); align-content: start; }
.app__more { padding-inline-start: var(--ar-space-2); }
.bubble { margin: 0; padding: var(--ar-space-3); border-radius: var(--ar-radius-md); background: var(--ar-surface-sunken); font-size: 11.5px; }
.bubble--me { background: var(--ar-accent-soft); justify-self: end; max-width: 92%; }
.rows, .outs { list-style: none; margin: 0; padding: 0; display: grid; }
.rows li { display: flex; gap: var(--ar-space-2); align-items: flex-start; padding: var(--ar-space-2); border-bottom: 1px solid var(--ar-hairline); }
.rows .icon, .outs .icon { width: 14px; height: 14px; color: var(--ar-accent); margin-top: 1px; }
.rows strong { display: block; font-weight: 600; }
.panel { border-radius: var(--ar-radius-md); box-shadow: var(--ar-shadow-card); padding: var(--ar-space-3); display: grid; gap: var(--ar-space-2); }
.panel__title { font-size: 11.5px; }
.sched { display: flex; align-items: center; gap: var(--ar-space-2); }
.sched > span:nth-child(2) { flex: 1; min-width: 0; }
.sched .icon { width: 14px; height: 14px; color: var(--ar-fg-muted); }
.switch { width: 24px; height: 14px; border-radius: var(--ar-radius-pill); background: var(--ar-accent); position: relative; flex: none; }
.switch::after { content: ''; position: absolute; inset-inline-end: 2px; top: 2px; width: 10px; height: 10px; border-radius: var(--ar-radius-pill); background: var(--ar-surface); }
.outs li { display: flex; align-items: center; gap: var(--ar-space-2); padding: 3px 0; }
.pill { display: inline-flex; align-items: center; gap: var(--ar-space-1); justify-self: start; padding: var(--ar-space-1) var(--ar-space-3); border-radius: var(--ar-radius-pill); font-size: 11px; font-weight: 600; background: var(--ar-accent-soft); color: var(--ar-rail-active-fg); }
.pill .icon { width: 12px; height: 12px; stroke-width: 2.4; }
.pill--ok { background: var(--ar-ok-bg); color: var(--ar-ok-fg); }

/* ── how it works: four steps strung on one line, not four more boxes ── */
.steps {
  list-style: none; margin: calc(var(--ar-space-8) * 1.5) 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--ar-space-8);
  position: relative;
}
.steps::before {
  content: ''; position: absolute; top: 28px; inset-inline: 28px calc(25% - 28px);
  border-top: 2px dashed color-mix(in srgb, var(--ar-accent) 35%, transparent);
}
.step { position: relative; }
.step__mark { display: inline-flex; padding: var(--ar-space-1); border-radius: var(--ar-radius-card); background: var(--ar-canvas); margin: calc(var(--ar-space-1) * -1); }
.step .tile--large { box-shadow: var(--ar-shadow-card); background: var(--ar-surface); }
.step__n { margin: var(--ar-space-5) 0 var(--ar-space-1); font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ar-accent); }
.step h3 { margin: 0 0 var(--ar-space-2); font-size: 20px; line-height: 1.25; }
.step p:last-child { margin: 0; color: var(--ar-fg-muted); font-size: 15px; max-width: 28ch; }

/* ── grids of cards ── */
.grid { display: grid; gap: var(--ar-space-6); margin-top: calc(var(--ar-space-8) * 1.25); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.feature { border-radius: var(--ar-radius-card); padding: var(--ar-space-6); }
.feature h3 { margin: var(--ar-space-4) 0 var(--ar-space-2); font-size: 18px; }
.feature p { margin: 0; font-size: 15px; }

/* ── an example specialist and its slice of screen ── */
.example { background: var(--ar-surface); border-radius: var(--ar-radius-card); box-shadow: var(--ar-shadow-card); padding: var(--ar-space-5); display: grid; gap: var(--ar-space-4); align-content: start; transition: transform 200ms ease, box-shadow 200ms ease; }
.example:hover { transform: translateY(-3px); box-shadow: var(--ar-shadow-float), var(--ar-shadow-card); }
@media (prefers-reduced-motion: reduce) { .example { transition: none; } .example:hover { transform: none; } }
.example__head { display: flex; gap: var(--ar-space-4); align-items: flex-start; }
.example__head .tile { width: 52px; height: 52px; }
.example__head .tile .icon { width: 26px; height: 26px; }
.example h3 { margin: 0; font-size: 19px; }
.example__head p { margin: var(--ar-space-1) 0 0; color: var(--ar-fg-muted); font-size: 14px; line-height: 1.45; }
.mini { display: grid; grid-template-columns: 68px minmax(0, 1fr); border-radius: var(--ar-radius-md); box-shadow: var(--ar-shadow-card); overflow: hidden; font-size: 11px; line-height: 1.35; min-height: 190px; }
.mini__nav { list-style: none; margin: 0; padding: var(--ar-space-2); background: var(--ar-canvas); border-inline-end: 1px solid var(--ar-hairline); display: grid; gap: 2px; align-content: start; color: var(--ar-fg-muted); }
.mini__nav li { padding: 5px var(--ar-space-1); border-radius: var(--ar-radius-sm); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini__nav li.is-on { background: var(--ar-accent-soft); color: var(--ar-accent); font-weight: 600; }
.mini__main { padding: var(--ar-space-2); display: grid; gap: var(--ar-space-3); align-content: start; }
.mini__out { border-radius: var(--ar-radius-sm); box-shadow: var(--ar-shadow-card); padding: var(--ar-space-2) var(--ar-space-3); }
.mini__out strong { display: block; margin-bottom: var(--ar-space-1); }
.mini__out ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
.mini__out li { display: flex; align-items: center; gap: var(--ar-space-2); }
.mini__out .icon { width: 12px; height: 12px; color: var(--ar-accent); }

/* ── Discovery ── */
.ways { gap: var(--ar-space-4); }
.way { border-inline-start: 3px solid var(--ar-accent); padding-inline-start: var(--ar-space-4); }
.way h3 { margin: 0 0 var(--ar-space-1); font-size: 16px; }
.way p { margin: 0; font-size: 14px; color: var(--ar-fg-muted); }
.listing { background: var(--ar-surface); border-radius: var(--ar-radius-card); box-shadow: var(--ar-shadow-card); padding: var(--ar-space-5); display: grid; gap: var(--ar-space-2); align-content: start; }
.listing__title { margin: 0; font-size: 17px; }
.listing__text { margin: 0; font-size: 14px; color: var(--ar-fg-muted); }
.listing__ref { margin: 0; font-family: var(--ar-font-mono); font-size: 12px; color: var(--ar-fg-subtle); }

/* ── creators: what publishing means, beside the card a creator sees ── */
.creators { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: calc(var(--ar-space-8) * 2); align-items: center; }
.note {
  display: inline-flex; align-items: center; gap: var(--ar-space-3);
  margin: var(--ar-space-6) 0 0; padding: var(--ar-space-3) var(--ar-space-5);
  background: var(--ar-accent-soft); border-radius: var(--ar-radius-md);
  font-size: 15px;
}
.note .icon { width: 22px; height: 22px; }
.facts { list-style: none; margin: var(--ar-space-8) 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--ar-space-6) var(--ar-space-8); }
.facts .icon { width: 24px; height: 24px; margin-top: 2px; }

.publish {
  background: var(--ar-surface); border-radius: var(--ar-radius-card);
  box-shadow: var(--ar-shadow-float), var(--ar-shadow-card);
  padding: var(--ar-space-6); display: grid; gap: var(--ar-space-4);
  transform: rotate(1.5deg);
}
[dir="rtl"] .publish { transform: rotate(-1.5deg); }
.publish__head { display: flex; align-items: center; gap: var(--ar-space-3); }
.publish__head strong { display: block; font-size: 18px; }
.publish__head small { color: var(--ar-fg-subtle); font-size: 13px; }
.segmented { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 3px; border-radius: var(--ar-radius-md); background: var(--ar-surface-sunken); font-size: 13px; text-align: center; }
.segmented span { padding: var(--ar-space-2); border-radius: var(--ar-radius-sm); color: var(--ar-fg-muted); }
.segmented .is-on { background: var(--ar-surface); color: var(--ar-fg); font-weight: 600; box-shadow: var(--ar-shadow-card); }
.publish .pill { font-size: 12px; }
.publish__stats { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: var(--ar-space-3); }
.publish__stats div { padding: var(--ar-space-3) var(--ar-space-4); border-radius: var(--ar-radius-md); background: var(--ar-canvas); }
.publish__stats dt { font-size: 12px; color: var(--ar-fg-muted); }
.publish__stats dd { margin: var(--ar-space-1) 0 0; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.split { display: flex; gap: 3px; height: 8px; }
.split span { border-radius: var(--ar-radius-pill); background: var(--ar-accent); }
.split span:nth-child(1) { flex: 70; }
.split span:nth-child(2) { flex: 20; background: color-mix(in srgb, var(--ar-accent) 55%, transparent); }
.split span:nth-child(3) { flex: 10; background: var(--ar-hairline); }
.publish__split { color: var(--ar-fg-muted); font-size: 12px; }

/* ── trust: the one dark band on the page ── */
.region--dark { background: var(--ar-fg); color: var(--on-dark); }
.region--dark .lead { color: var(--on-dark-muted); }
.trust { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: calc(var(--ar-space-8) * 1.5); align-items: center; }
.trust .grid { margin-top: 0; }
.trust .display--section { font-size: clamp(30px, min(3.6vw, 5.6vh), 48px); }
/* The accented half on its own line: left to wrap, it broke inside the phrase ("从 / 设计开始"). */
.trust .display--section .accent, .creators .display--section .accent { display: block; }
.trust .feature { background: color-mix(in srgb, var(--ar-canvas) 5%, transparent); box-shadow: inset 0 0 0 1px var(--on-dark-line); }
.trust .feature p { color: var(--on-dark-muted); }

/* ── developers: the one command, to copy ── */
.developers { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: calc(var(--ar-space-8) * 1.5); align-items: center; }
.developers .display--section { max-width: 16ch; }
.terminal {
  background: var(--ar-fg); color: var(--on-dark); border-radius: var(--ar-radius-card);
  padding: var(--ar-space-5) var(--ar-space-6) var(--ar-space-6); box-shadow: var(--ar-shadow-float);
  display: grid; gap: var(--ar-space-4);
}
.terminal__bar { display: flex; gap: 6px; }
.terminal__bar span { width: 10px; height: 10px; border-radius: var(--ar-radius-pill); background: var(--on-dark-line); }
.terminal__line { display: flex; align-items: center; gap: var(--ar-space-3); padding: var(--ar-space-4); border-radius: var(--ar-radius-md); background: color-mix(in srgb, var(--ar-canvas) 6%, transparent); direction: ltr; }
.terminal code { flex: 1; min-width: 0; font-family: var(--ar-font-mono); font-size: 14px; overflow-wrap: anywhere; }
.terminal__prompt { color: var(--ar-accent); user-select: none; }
.terminal__copy {
  flex: none; display: inline-flex; align-items: center; gap: var(--ar-space-1);
  padding: var(--ar-space-2) var(--ar-space-3); border: 0; border-radius: var(--ar-radius-sm);
  background: var(--on-dark-line); color: var(--on-dark); font: inherit; font-size: 13px; cursor: pointer;
}
.terminal__copy:hover { background: color-mix(in srgb, var(--ar-canvas) 22%, transparent); }
.terminal__copy .icon { width: 14px; height: 14px; }
.terminal__who { margin: 0; color: var(--on-dark-muted); font-size: 14px; }
.terminal .more { justify-self: start; }

/* ── footer ── */
.footer {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.4fr); gap: var(--ar-space-8);
  margin-top: var(--region);
  padding: calc(var(--ar-space-8) * 1.5) var(--gutter) var(--ar-space-8);
  border-top: 1px solid var(--ar-hairline);
  color: var(--ar-fg-muted); font-size: 14px;
}
.footer__brand p { margin: var(--ar-space-3) 0 0; max-width: 24ch; }
.footer__cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--ar-space-6); }
.footer__cols div { display: grid; gap: var(--ar-space-2); align-content: start; }
.footer__cols strong { color: var(--ar-fg); font-size: 15px; margin-bottom: var(--ar-space-1); }
.footer__cols a { text-decoration: none; }
.footer__cols a:hover { color: var(--ar-accent); }
.footer__rights { grid-column: 1 / -1; padding-top: var(--ar-space-6); border-top: 1px solid var(--ar-hairline); }

/* ── get it: held at the bottom of the window all the way down, at rest under the footer ── */
.get {
  position: sticky; bottom: var(--ar-space-3); z-index: 9;
  display: flex; align-items: center; gap: var(--ar-space-6);
  max-width: calc(var(--page) + 2 * var(--ar-space-8)); width: calc(100% - 2 * var(--ar-space-3));
  margin: 0 auto var(--ar-space-3);
  background: color-mix(in srgb, var(--ar-surface) 94%, transparent); backdrop-filter: blur(10px);
  border-radius: var(--ar-radius-card); box-shadow: var(--ar-shadow-pop), var(--ar-shadow-card);
  padding-block: var(--ar-space-3); padding-inline: var(--ar-space-8) var(--ar-space-3);
}
.get__text { flex: none; display: grid; }
.get__text strong { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.get__text span { color: var(--ar-fg-muted); font-size: 14px; }
.get__list { flex: 1; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: var(--ar-space-2); }
.platform {
  display: flex; align-items: center; gap: var(--ar-space-3); min-width: 0;
  padding: var(--ar-space-2) var(--ar-space-4); border-radius: var(--ar-radius-md);
  box-shadow: var(--ar-shadow-card); background: var(--ar-surface); text-decoration: none;
}
.platform:hover { background: var(--ar-hover); }
.platform .icon { width: 26px; height: 26px; stroke-width: 1.5; }
.platform span { min-width: 0; }
.platform strong { display: block; font-size: 15px; }
.platform small { display: block; color: var(--ar-fg-muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── regular: 520–899 ── */
@media (max-width: 899px) {
  .nav__links { display: none; }
  .hero, .creators, .developers, .trust { grid-template-columns: minmax(0, 1fr); }
  .hero::before { inset-block: 40% 0; inset-inline: 0; }
  .points, .grid--4, .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: minmax(0, 1fr); }
  .points { row-gap: var(--ar-space-6); }
  .points li:nth-child(odd) { border-inline-start: 0; padding-inline-start: 0; }
  .steps { grid-template-columns: minmax(0, 1fr); gap: var(--ar-space-6); }
  .steps::before { inset-inline: 27px auto; top: 28px; bottom: 28px; border-top: 0; border-inline-start: 2px dashed color-mix(in srgb, var(--ar-accent) 35%, transparent); }
  .step { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: var(--ar-space-5); }
  .step__mark { grid-row: span 3; align-self: start; }
  .step__n { margin-top: var(--ar-space-1); }
  .creators, .developers, .trust { gap: calc(var(--ar-space-8) * 1.25); }
  .publish { transform: none; }
  [dir="rtl"] .publish { transform: none; }
  .region__head { flex-direction: column; align-items: flex-start; }
  .get__text span, .platform small { display: none; }
  .get { padding-block: var(--ar-space-2); padding-inline: var(--ar-space-5) var(--ar-space-2); gap: var(--ar-space-4); }
  .get__text strong { font-size: 16px; }
  .footer { grid-template-columns: minmax(0, 1fr); }
  .footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ── compact: below 520 ── */
@media (max-width: 519px) {
  body.site { --region: calc(var(--ar-space-8) * 2); }
  .nav { gap: var(--ar-space-3); }
  /* The hero carries the same action a screen below; in the bar it pushed the page wider than the phone. */
  .nav__cta, .nav__signin { display: none; }
  .langs summary span { display: none; }
  .langs ul { grid-template-columns: minmax(150px, 1fr); }
  .hero { padding-top: var(--ar-space-8); }
  .hero__text .lead, .lead { font-size: 17px; }
  .btn--large { flex: 1; padding: var(--ar-space-4); }
  .points, .grid--4, .grid--2, .facts { grid-template-columns: minmax(0, 1fr); }
  .points li + li { border-inline-start: 0; padding-inline-start: 0; }
  .app { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .app__side { display: none; }
  .app__body { grid-template-columns: minmax(0, 1fr); }
  .app__tabs { gap: var(--ar-space-3); }
  .chip:not(.chip--solid) { display: none; }
  .note { display: flex; }
  /* At the bottom of a phone: the ways in, as icons with a name, nothing else. */
  .get__text { display: none; }
  .get { padding: var(--ar-space-2); }
  .platform { flex-direction: column; gap: 2px; padding: var(--ar-space-2) var(--ar-space-1); text-align: center; }
  .platform strong { font-size: 12px; font-weight: 600; }
  .platform .icon { width: 22px; height: 22px; }
}

/* ── one screen at a time ──
   Where a window is big enough to hold a whole region, each region is exactly
   one window tall — under the nav, above the bar at the bottom — and the page
   moves a screen at a time: the snap here, one turn of the wheel in site.js.
   Smaller than that (a phone, a short laptop window) the page scrolls as
   usual: a region that does not fit would be cut off by a snap. */
@media (min-width: 900px) and (min-height: 640px) {
  /* On html, not body: scroll-padding is read from the root, and a variable set lower down never reaches it. */
  html { --nav-h: 73px; --bar-h: 108px; --room: clamp(var(--ar-space-4), 4vh, calc(var(--ar-space-8) * 1.5)); scroll-snap-type: y mandatory; scroll-padding-top: var(--nav-h); }
  .screen {
    min-height: calc(100svh - var(--nav-h));
    margin-top: 0;
    padding-top: var(--room);
    padding-bottom: calc(var(--bar-h) + var(--room));
    align-content: center;
    scroll-snap-align: start;
  }
  .region--band.screen, .region--dark.screen { margin-top: 0; }
  .footer { margin-top: 0; scroll-snap-align: end; padding-bottom: calc(var(--bar-h) + var(--ar-space-6)); }
  /* Heights come from the window, so a short one tightens the spaces before anything is cut. */
  .hero { row-gap: min(var(--ar-space-8), 4vh); }
  .ask { margin-top: min(var(--ar-space-6), 3vh); }
  .hero__actions { margin-top: min(var(--ar-space-5), 2.4vh); }
  .lead { margin-top: min(var(--ar-space-4), 2vh); }
  .grid, .steps, .facts { margin-top: min(calc(var(--ar-space-8) * 1.25), 5vh); }
  .mini { min-height: 0; }
  .facts { row-gap: var(--ar-space-5); }
}
@media (min-width: 900px) and (min-height: 640px) and (max-height: 820px) {
  /* A laptop-height window: the examples' screens and the section leads give way first. */
  #examples .lead, #how .lead { display: none; }
  .hero .display { font-size: clamp(32px, min(3.3vw, 5.2vh), 48px); }
  .ask { padding: var(--ar-space-4); }
  .ask textarea { font-size: 16px; }
  .ask__send { width: 44px; height: 44px; }
  .btn--large { padding: var(--ar-space-3) var(--ar-space-6); font-size: 16px; }
  .laptop .app { min-height: 0; }
}
