/* PassForAI .org demo: bulletin direction. Colours are the locked P2 palette from brand/README.md. */

:root {
  color-scheme: light dark;
  /* Interface accents. The logo keeps the exact P2 values; on dark surfaces the accents are a step lighter. */
  --blue: light-dark(#0077B6, #46A6DE); --teal: light-dark(#00A896, #23C4AE); --amber: light-dark(#F9A03F, #F9AC55); --coral: light-dark(#EF476F, #F2668A);
  /* Dark mode: a neutral near-black page, surfaces one step lighter, white hairlines at low opacity. */
  --bg: light-dark(#FFFFFF, #0C0E12);
  --sunk: light-dark(#F3F5F6, #15181E);
  --ink: light-dark(#0F172A, #F0F2F5);
  --ink-2: light-dark(#3A455A, #B4BAC4);
  --ink-3: light-dark(#647087, #868D99);
  --line: light-dark(rgb(15 23 42 / .13), rgb(255 255 255 / .1));
  --line-2: light-dark(rgb(15 23 42 / .3), rgb(255 255 255 / .22));
  --focus: light-dark(#0077B6, #74C7EF);
  --latin: "Plus Jakarta Sans";
  --cjk: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei";
  --font: var(--latin), var(--cjk), system-ui, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, var(--cjk), monospace;
  --gutter: clamp(20px, 5vw, 72px);
  --max: 1400px;
  --label: 11rem;                      /* width of the section label column */
  --col-gap: clamp(24px, 3.4vw, 48px);  /* gap between label and content */
  --sec: clamp(40px, 4.4vw, 64px);      /* vertical padding of a section */

  &:has(> head > meta[name="color-scheme"][content="dark"]) { color-scheme: dark; }
  &:has(> head > meta[name="color-scheme"][content="light"]) { color-scheme: light; }
  &:lang(zh-Hans) { --cjk: "Noto Sans SC", "PingFang SC", "Microsoft YaHei"; }
}

@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
  html { scroll-behavior: smooth; }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 20px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1rem/1.55 var(--font); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p, ul, ol, dl, dd, figure, pre { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .22em; }
button, input { font: inherit; color: inherit; }
svg { display: block; }
p, dd, li { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
[tabindex="-1"]:focus { outline: 0; }

.wrap { max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.ph { display: inline-block; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: var(--gutter); top: -4rem; z-index: 10; background: var(--ink); color: var(--bg); padding: .6em 1em; border-radius: 999px; }
.skip:focus { top: 12px; }
.ico { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.ext { display: inline; width: .68em; height: .68em; margin-inline-start: .35em; fill: none; stroke: currentColor; stroke-width: 1.4; }
.peb { width: .8em; height: .8em; flex: none; }
.btn { display: inline-flex; align-items: center; justify-content: center; padding: .9em 1.5em; border: 0; border-radius: 999px; background: var(--ink); color: var(--bg); font-weight: 600; font-size: .9375rem; line-height: 1; cursor: pointer; }
.btn:hover { background: var(--blue); color: light-dark(#fff, #0C0E12); }

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

.head { position: relative; z-index: 5; border-bottom: 1px solid var(--line); }
.head-row { display: flex; align-items: center; gap: clamp(16px, 3.4vw, 52px); min-height: 72px; }
.brand { display: inline-flex; color: var(--ink); }
.logo { height: 32px; width: auto; }
.nav { display: flex; gap: clamp(16px, 2.4vw, 34px); }
.nav a { padding-block: .5em; font-size: .9375rem; font-weight: 500; color: var(--ink-2); text-decoration: none; }
.nav a:hover, .nav a[aria-current] { color: var(--ink); }
.nav a[aria-current] { font-weight: 700; }
.utils { display: flex; align-items: center; gap: 2px; margin-inline-start: auto; }
.util { display: inline-flex; align-items: center; gap: .5em; min-height: 40px; padding: 0 .7em; border: 0; border-radius: 999px; background: none; color: var(--ink-2); font-size: .875rem; font-weight: 500; text-decoration: none; cursor: pointer; }
.util:hover { background: var(--sunk); color: var(--ink); }
.menu { display: none; }

.prefs { background: light-dark(#fff, #1B1F27); }
.prefs { position: fixed; inset: 64px max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter))) auto auto; margin: 0; width: 15.5rem; padding: 16px; border: 1px solid var(--line-2); border-radius: 20px; color: var(--ink); box-shadow: 0 16px 48px rgb(0 0 0 / .18); }
.prefs h2 { padding: 4px 10px 6px; font-size: .75rem; font-weight: 600; color: var(--ink-3); }
.prefs h2:not(:first-child) { margin-top: 12px; }
.pref-langs a { display: flex; justify-content: space-between; padding: 8px 10px; border-radius: 10px; font-size: .9375rem; text-decoration: none; }
.pref-langs a:hover { background: var(--sunk); }
.pref-langs a[aria-current] { font-weight: 700; }
.pref-langs a[aria-current]::after { content: ""; width: .5em; height: .5em; align-self: center; border-radius: 50%; background: var(--teal); }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); padding: 3px; border: 1px solid var(--line); border-radius: 999px; }
.seg button { padding: .5em .2em; border: 0; border-radius: 999px; background: none; font-size: .8125rem; font-weight: 500; color: var(--ink-2); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

.lang-bar { background: var(--sunk); font-size: .9375rem; }
.lang-bar .wrap { display: flex; align-items: center; gap: 14px; padding-block: 8px; }
.lang-bar a { font-weight: 600; }
.lang-bar button { margin-inline-start: auto; padding: 6px; border: 0; border-radius: 50%; background: none; cursor: pointer; }

@media (max-width: 760px) {
  .menu { display: inline-flex; }
  .pref-btn span { display: none; }
  .nav { display: none; position: absolute; inset: 100% 0 auto; padding: 4px var(--gutter) 16px; background: var(--bg); border-bottom: 1px solid var(--line); }
  .head[data-open] .nav { display: grid; }
  .nav a { padding-block: .75em; font-size: 1.125rem; border-top: 1px solid var(--line); }
  .nav a:first-child { border-top: 0; }
  .logo { height: 28px; }
}

/* ---------- feed rows ---------- */

.rows { border-top: 1px solid var(--ink); }
.row { display: grid; grid-template-columns: 7.75rem minmax(0, 1fr) auto; gap: 4px 24px; align-items: start; padding: 16px 0; border-bottom: 1px solid var(--line); }
.ty { display: inline-flex; align-items: center; gap: .55em; padding-top: .2em; font-size: .8125rem; font-weight: 600; color: var(--ink-2); white-space: nowrap; }
.ti { font-size: 1.125rem; font-weight: 600; line-height: 1.35; text-wrap: pretty; }
.su { margin-top: 4px; max-width: 44rem; font-size: .9375rem; line-height: 1.5; color: var(--ink-2); }
.rm { display: grid; gap: 4px; justify-items: end; max-width: 15rem; padding-top: .2em; font-size: .8125rem; color: var(--ink-3); text-align: end; }
.rm time { white-space: nowrap; }
.src { color: var(--ink-2); text-decoration-color: var(--line-2); overflow-wrap: anywhere; }
.src span { font-weight: 600; color: var(--ink); }
.src:hover { color: var(--ink); text-decoration-color: currentColor; }
@media (max-width: 720px) {
  .row { grid-template-columns: minmax(0, 1fr); }
  .rm { grid-auto-flow: column; justify-content: space-between; justify-items: start; max-width: none; text-align: start; }
  .rm time { order: 2; }
}

/* ---------- home ---------- */

.hero { padding-block: clamp(40px, 4.4vw, 64px) clamp(40px, 4.4vw, 64px); }
.lede { max-width: 22em; font-size: clamp(1.75rem, 3.5vw, 3rem); font-weight: 600; line-height: 1.12; letter-spacing: -.04em; text-wrap: balance; }
.more { display: inline-block; font-size: .9375rem; font-weight: 600; text-decoration-color: var(--line-2); }
.more:hover { text-decoration-color: currentColor; }

/* Entrances: a tinted surface in both modes, one step lighter than the page in dark mode. No borders; the colour lives in the illustration. */
.doors { display: grid; grid-template-columns: repeat(var(--doors, 4), minmax(0, 1fr)); gap: 12px; margin-top: clamp(28px, 3.2vw, 44px); }
.door { --door: light-dark(color-mix(in oklab, var(--c) 13%, #fff), color-mix(in oklab, var(--c) 24%, #15181E)); display: grid; grid-template-rows: 6.25rem auto auto; gap: 2px; padding: 20px; border-radius: 20px; background: var(--door); color: var(--ink); text-decoration: none; }
.door-blue { --c: var(--blue); } .door-teal { --c: var(--teal); } .door-amber { --c: var(--amber); } .door-coral { --c: var(--coral); }
.art { width: 100%; height: 100%; min-height: 0; overflow: visible; fill: var(--c); transition: transform .5s cubic-bezier(.2, .8, .2, 1); transform-origin: 30% 60%; }
.art .t { fill: light-dark(color-mix(in oklab, var(--c) 36%, #fff), color-mix(in oklab, var(--c) 52%, #15181E)); }
.ln { fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.ln.dash { stroke-dasharray: 1 6; }
.d-t { margin-top: 16px; font-size: 1.25rem; font-weight: 600; line-height: 1.3; letter-spacing: -.02em; }
.d-s { font-size: .875rem; line-height: 1.45; color: var(--ink-2); }
.door:hover .art { transform: scale(1.05) rotate(-2deg); }
.door:hover .d-t { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .18em; }
@media (prefers-reduced-motion: reduce) { .art { transition: none; } }

/* Sections: a narrow label column and a wide content column, the same on every page. */
.strip { position: relative; display: grid; grid-template-columns: var(--label) minmax(0, 1fr); gap: 16px var(--col-gap); align-items: start; padding-block: var(--sec); }
.strip::before { content: ""; position: absolute; inset: 0 var(--gutter) auto; border-top: 1px solid var(--line); }
.strip > h2, .strip-h h2 { font-size: 1.25rem; font-weight: 600; letter-spacing: -.02em; line-height: 1.3; }
.strip h2 a { text-decoration: none; }
.strip h2 a:hover { text-decoration: underline; text-decoration-thickness: 1px; }
.strip-h { display: grid; gap: 4px; justify-items: start; }
.strip-h p { font-size: .875rem; color: var(--ink-3); }
.strip-h .more { margin-top: 8px; }

.kinds { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kind-n { display: grid; gap: 8px; padding-inline: 24px; border-left: 1px solid var(--line); text-decoration: none; }
.kind-n:first-child { padding-inline-start: 0; border-left: 0; }
.kind-n b { font-size: clamp(2.25rem, 4.4vw, 3.75rem); font-weight: 600; line-height: 1; letter-spacing: -.05em; }
.kind-n span { font-size: .9375rem; font-weight: 500; color: var(--ink-2); }
.kind-n:hover span { color: var(--ink); text-decoration: underline; }

.guide-list { border-top: 1px solid var(--ink); }
.guide-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 24px; align-items: baseline; padding: 16px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.g-title { font-size: 1.125rem; font-weight: 600; line-height: 1.35; letter-spacing: -.015em; text-wrap: pretty; }
.g-deck { grid-column: 1; max-width: 44rem; font-size: .9375rem; line-height: 1.5; color: var(--ink-2); }
.g-meta { grid-column: 2; grid-row: 1; display: flex; gap: 16px; font-size: .8125rem; color: var(--ink-3); white-space: nowrap; }
.guide-row:hover .g-title { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .16em; }
.guides-page { padding-bottom: var(--sec); }
.guide-list-l .guide-row { padding-block: 24px; }
.guide-list-l .g-title { font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.2; letter-spacing: -.035em; }
.guide-list-l .g-deck { margin-top: 4px; font-size: 1.0625rem; }

.sub-box { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }
.sub { display: flex; flex: 1 1 24rem; flex-wrap: wrap; gap: 8px; max-width: 34rem; }
.sub input, .field { flex: 1 1 13rem; min-width: 0; padding: .8em 1.2em; border: 1px solid var(--line-2); border-radius: 999px; background: var(--bg); }
.sub input::placeholder, .field::placeholder { color: var(--ink-3); }
.tg { display: inline-flex; align-items: center; gap: .55em; padding: .7em 1.2em; border: 1px solid var(--line-2); border-radius: 999px; font-size: .9375rem; font-weight: 600; text-decoration: none; }
.tg:hover { border-color: var(--ink); }

.welcome { display: grid; justify-items: start; gap: 16px; padding-block: clamp(48px, 8vw, 112px); }
.w-art { width: 11rem; overflow: visible; }
.welcome h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 600; line-height: 1; letter-spacing: -.045em; }
.welcome p { max-width: 40rem; font-size: 1.125rem; color: var(--ink-2); }
.w-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 8px !important; }

@media (max-width: 760px) {
  .doors { grid-template-columns: 1fr 1fr; }
  .door { grid-template-rows: 4.5rem auto auto; padding: 16px; }
  .strip { grid-template-columns: minmax(0, 1fr); }
  .strip-h { grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; }
  .strip-h h2 { grid-column: 1; } .strip-h p { grid-column: 1; } .strip-h .more { grid-column: 2; grid-row: 1; margin: 0; }
  .kinds { grid-template-columns: 1fr 1fr; gap: 24px 0; }
  .kind-n:nth-child(odd) { padding-inline-start: 0; border-left: 0; }
  .guide-row { grid-template-columns: minmax(0, 1fr); }
  .g-meta { grid-column: 1; grid-row: auto; }
}

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

.foot { padding-block: 48px 32px; border-top: 1px solid var(--ink); font-size: .9375rem; }
.foot-grid { display: grid; grid-template-columns: minmax(0, 2.4fr) repeat(3, minmax(0, 1fr)); gap: 32px var(--col-gap); }
.foot-name { margin-top: 16px; font-weight: 600; }
.foot-facts { margin-top: 8px; font-size: .875rem; }
.foot-facts div { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr); gap: 0 16px; padding: 3px 0; }
.foot-facts dt { color: var(--ink-3); }
.foot-facts dd { color: var(--ink-2); }
.foot h2 { margin-bottom: 8px; font-size: .8125rem; font-weight: 600; color: var(--ink-3); }
.foot li a { display: inline-block; padding: 4px 0; text-decoration: none; }
.foot li a:hover { text-decoration: underline; }
.foot-legal { position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 32px; margin-top: 32px; padding-top: 16px; font-size: .8125rem; color: var(--ink-3); }
.foot-legal::before { content: ""; position: absolute; inset: 0 var(--gutter) auto; border-top: 1px solid var(--line); }
@media (max-width: 760px) { .foot-grid { grid-template-columns: 1fr 1fr; } .foot-org { grid-column: 1 / -1; } }

/* ---------- page head, chips ---------- */

.page-head { padding-block: var(--sec) 32px; }
.page-head h1 { font-size: clamp(2.75rem, 5.6vw, 4.5rem); font-weight: 600; line-height: 1; letter-spacing: -.045em; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.page-head > .chips { margin-top: 32px; }
.chip { display: inline-flex; align-items: baseline; gap: .5em; padding: .55em 1.05em; border: 1px solid var(--line-2); border-radius: 999px; background: none; font-size: .9375rem; font-weight: 600; cursor: pointer; }
.chip b { font-weight: 500; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip[aria-pressed="true"] b { color: inherit; opacity: .7; }
.chip-s { padding: .4em .85em; font-size: .8125rem; font-weight: 500; color: var(--ink-2); }
.tools { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-top: 16px; }
.field { flex: 0 1 15rem; }

/* feed page */
.feed { padding-bottom: var(--sec); }
.day { display: grid; grid-template-columns: var(--label) minmax(0, 1fr); gap: 8px var(--col-gap); align-items: start; padding-top: 32px; }
.day h2 { position: sticky; top: 16px; display: grid; gap: 2px; font-size: .875rem; font-weight: 500; color: var(--ink-3); }
.day h2 time { font-size: 1.25rem; font-weight: 600; letter-spacing: -.02em; color: var(--ink); }
@media (max-width: 640px) { .day { grid-template-columns: minmax(0, 1fr); } .day h2 { position: static; display: flex; align-items: baseline; gap: 12px; } }

/* catalog page */
.entries { margin-bottom: var(--sec); border-top: 1px solid var(--ink); }
.entry { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 2.6fr) minmax(0, 1fr); gap: 8px 32px; align-items: start; padding: 16px 0; border-bottom: 1px solid var(--line); }
.e-id h3 { font-size: 1.125rem; font-weight: 600; line-height: 1.35; letter-spacing: -.015em; overflow-wrap: anywhere; }
.e-id p, .e-meta > span { font-size: .8125rem; color: var(--ink-3); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tags li { padding: .1em .7em; border: 1px solid var(--line); border-radius: 999px; font-size: .75rem; color: var(--ink-2); white-space: nowrap; }
.e-info { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 28px; }
.e-info dt { font-size: .8125rem; font-weight: 600; color: var(--ink-3); }
.e-info dd { font-size: .9375rem; line-height: 1.5; }
.e-meta { display: grid; gap: 3px; justify-items: start; font-size: .8125rem; }
.e-meta a { font-weight: 600; overflow-wrap: anywhere; text-decoration-color: var(--line-2); }
.e-guide { margin-top: 6px; }
.empty { padding-block: 32px 80px; font-size: 1.25rem; font-weight: 600; }
.empty button { padding: 0; border: 0; background: none; text-decoration: underline; cursor: pointer; }
@media (max-width: 860px) { .entry { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) { .e-info { grid-template-columns: minmax(0, 1fr); } }

/* ---------- guide ---------- */

.crumb { margin-bottom: 16px; font-size: .9375rem; font-weight: 600; }
.crumb a { text-decoration-color: var(--line-2); }
.guide-head h1 { max-width: 18em; font-size: clamp(2.25rem, 4.6vw, 3.75rem); line-height: 1.04; letter-spacing: -.04em; text-wrap: balance; }
.deck { max-width: 40rem; margin-top: 18px; font-size: clamp(1.125rem, 1.8vw, 1.375rem); line-height: 1.45; color: var(--ink-2); }
.facts-row { display: flex; flex-wrap: wrap; margin-top: 32px; border-top: 1px solid var(--ink); }
.facts-row div { padding: 12px 48px 0 0; }
.facts-row dt { font-size: .8125rem; color: var(--ink-3); }
.facts-row dd { font-size: .9375rem; font-weight: 600; }
.article { display: grid; grid-template-columns: var(--label) minmax(0, 1fr); gap: 32px var(--col-gap); padding-block: 32px var(--sec); }
.toc { position: sticky; top: 20px; align-self: start; font-size: .875rem; }
.toc ol { scroll-target-group: auto; counter-reset: toc; }
.toc a { display: block; padding: .42em 0 .42em 14px; border-left: 1px solid var(--line); color: var(--ink-3); line-height: 1.35; text-decoration: none; }
.toc a:hover { color: var(--ink); }
.toc a:is(:target-current, .target-current) { padding-left: 13px; border-left: 2px solid var(--ink); color: var(--ink); font-weight: 700; }
.prose { max-width: 42rem; font-size: 1.0625rem; line-height: 1.7; }
.prose > * + *, .prose section > * + * { margin-top: 1em; }
.prose > section { margin-top: 2.4em; }
.lead { font-size: clamp(1.25rem, 2vw, 1.5rem); font-weight: 500; line-height: 1.42; letter-spacing: -.015em; }
.prose h2 { display: grid; grid-template-columns: 2.2rem minmax(0, 1fr); font-size: 1.5rem; font-weight: 700; line-height: 1.2; letter-spacing: -.025em; }
.prose h2 .num { font-weight: 500; color: var(--ink-3); }
.prose h2.plain { display: block; }
.prompt { border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.prompt figcaption { display: flex; align-items: center; justify-content: space-between; padding: 8px 10px 8px 18px; border-bottom: 1px solid var(--line); font-size: .8125rem; font-weight: 600; color: var(--ink-2); }
.copy { min-height: 32px; padding: 0 1em; border: 1px solid var(--line-2); border-radius: 999px; background: none; font-size: .8125rem; font-weight: 600; cursor: pointer; }
.copy:hover { border-color: var(--ink); }
.prompt pre { padding: 16px 18px; background: var(--sunk); font: 400 .875rem/1.7 var(--mono); white-space: pre-wrap; }
.checks li { padding: 10px 0; border-top: 1px solid var(--line); }
.checks li:last-child { border-bottom: 1px solid var(--line); }
.levels { width: 100%; border-collapse: collapse; font-size: .9375rem; line-height: 1.5; }
.levels th, .levels td { padding: 11px 16px 11px 0; border-top: 1px solid var(--line); text-align: start; vertical-align: top; }
.levels thead th { border-top: 0; border-bottom: 1px solid var(--ink); font-size: .8125rem; font-weight: 600; color: var(--ink-2); }
.levels tbody th { font-weight: 700; white-space: nowrap; }
.prose a { text-decoration-color: var(--line-2); }
.prose a:hover { text-decoration-color: currentColor; }

/* guide components: step flow, annotated screen, comparison, pitfall */
.flow { display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); counter-reset: flow; padding: 20px 0 16px; border-block: 1px solid var(--line); }
.flow li { position: relative; counter-increment: flow; padding: 52px 12px 0 0; margin: 0 !important; }
.flow li:not(:last-child)::before { content: ""; position: absolute; top: 20px; inset-inline: 48px 8px; border-top: 1.6px dotted var(--ink-3); }
.node { position: absolute; top: 0; left: 0; width: 40px; height: 40px; }
.flow b { display: block; font-size: .9375rem; font-weight: 600; line-height: 1.3; }
.flow b::before { content: counter(flow); margin-inline-end: .5em; font-weight: 500; color: var(--ink-3); }
.shot-win { border: 1px solid var(--line-2); border-radius: 16px; overflow: hidden; background: var(--bg); }
.m-top { display: flex; gap: 6px; padding: 11px 14px; border-bottom: 1px solid var(--line); background: var(--sunk); }
.m-top i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-2); }
.m-body { display: grid; gap: 4px; padding: 14px 16px; font-size: .9375rem; line-height: 1.5; }
.m-row { display: flex; align-items: center; gap: 10px; margin: 0 !important; padding: 7px 0; }
.m-row > span:first-child, .m-row > code { flex: 0 1 auto; min-width: 0; }
.m-tag, .m-btn { padding: .1em .7em; border: 1px solid var(--line-2); border-radius: 999px; font-size: .8125rem; white-space: nowrap; }
.m-btn { border-radius: 8px; background: var(--sunk); font-weight: 600; }
.m-warn { border-color: var(--coral); }
.m-input { flex: 1 1 auto !important; padding: .45em .9em; border: 1px solid var(--line-2); border-radius: 12px; color: var(--ink-3); }
.shot-term .m-body { background: var(--sunk); }
.shot code { font: 400 .875rem/1.6 var(--mono); overflow-wrap: anywhere; }
.pin, .shot figcaption li::before { display: inline-grid; place-items: center; flex: none; width: 1.5rem; height: 1.5rem; border-radius: 50%; background: var(--ink); color: var(--bg); font-size: .75rem; font-weight: 700; line-height: 1; }
.pin { margin-inline-start: auto; }
.shot figcaption ol { counter-reset: pin; margin-top: 12px; }
.shot figcaption li { counter-increment: pin; display: grid; grid-template-columns: 1.5rem minmax(0, 1fr); gap: 12px; align-items: start; margin: 0 !important; padding: 6px 0; font-size: .9375rem; line-height: 1.5; }
.shot figcaption li::before { content: counter(pin); }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.compare > div { padding: 16px 18px; border: 1px solid var(--line-2); border-radius: 16px; }
.compare b { display: flex; align-items: center; gap: .5em; margin-bottom: 6px; font-size: .8125rem; font-weight: 700; }
.compare .bad { border-style: dashed; color: var(--ink-2); }
.compare .bad b::before, .compare .good b::before { content: ""; width: .7em; height: .7em; border-radius: 50%; }
.compare .bad b::before { border: 1.6px solid var(--ink-3); }
.compare .good { border: 1.6px solid var(--ink); }
.compare .good b::before { background: var(--teal); }
.compare p, .compare li { margin: 0 !important; font-size: 1rem; line-height: 1.5; }
.compare-even li { padding: 6px 0; border-top: 1px solid var(--line); }
.pitfall { padding: 16px 20px; border-radius: 16px; background: light-dark(color-mix(in oklab, var(--coral) 9%, #fff), color-mix(in oklab, var(--coral) 18%, #15181E)); }
.pitfall h3 { display: flex; align-items: center; gap: .5em; font-size: .9375rem; font-weight: 700; }
.pitfall li { margin: 0 !important; padding: 8px 0 0; font-size: 1rem; line-height: 1.55; }
@media (max-width: 820px) { .article { grid-template-columns: minmax(0, 1fr); } .toc { position: static; } }
@media (max-width: 640px) {
  .flow { grid-template-columns: minmax(0, 1fr); padding-block: 12px; }
  .flow li { padding: 10px 0 10px 54px; min-height: 52px; }
  .flow li:not(:last-child)::before { top: 48px; bottom: -6px; inset-inline: 19px auto; border-top: 0; border-left: 1.6px dotted var(--ink-3); }
  .node { top: 6px; }
  .compare { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- about ---------- */

.mission { max-width: 44rem; margin-top: 24px; font-size: clamp(1.25rem, 2vw, 1.625rem); font-weight: 500; line-height: 1.4; letter-spacing: -.02em; }
.certs { display: grid; grid-template-columns: repeat(auto-fill, minmax(13rem, 15rem)); gap: 24px; }
.cert-frame { display: grid; place-items: center; aspect-ratio: 8.5 / 11; margin-bottom: 12px; border: 1px solid var(--line-2); border-radius: 12px; background: var(--sunk); overflow: hidden; }
.cert-frame svg { width: 34%; overflow: visible; }
.cert-frame img { width: 100%; height: 100%; object-fit: cover; }
.cert h3 { font-size: 1rem; font-weight: 700; line-height: 1.35; }
.cert p { font-size: .875rem; color: var(--ink-2); }
.cert-st { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin-top: 8px; }
.cert-st a { font-weight: 600; color: var(--ink); text-decoration-color: var(--line-2); }
.st { padding: .1em .8em; border: 1px solid var(--line-2); border-radius: 999px; font-size: .8125rem; color: var(--ink); white-space: nowrap; }
.updated { margin-top: 16px; font-size: .9375rem; color: var(--ink-3); }
.policy { max-width: 42rem; font-size: 1.0625rem; line-height: 1.7; }
.policy > * + * { margin-top: .7em; }
.policy ul { padding-inline-start: 1.2em; list-style: disc; }
.policy li + li { margin-top: .35em; }
.policy a { text-decoration-color: var(--line-2); }
.table > div, .plain-list li { display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); gap: 2px 24px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.table > div:first-child, .plain-list li:first-child { border-top: 1px solid var(--ink); }
.table dt, .plain-list span { color: var(--ink-2); }
.table dd, .plain-list a { font-weight: 600; }
.plain-list a { text-decoration-color: var(--line-2); }
.rules { counter-reset: rule; margin-top: 32px; border-top: 1px solid var(--ink); }
.rules li { counter-increment: rule; display: grid; grid-template-columns: 2.2rem minmax(0, 1fr); padding: 13px 0; border-bottom: 1px solid var(--line); font-weight: 500; }
.rules li::before { content: counter(rule); color: var(--ink-3); font-variant-numeric: tabular-nums; }
@media (max-width: 560px) { .table > div, .plain-list li { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Chinese ---------- */

:lang(zh) body, body:lang(zh) { line-height: 1.7; }
:lang(zh) :is(.page-head h1, .kind-n b, .welcome h1) { letter-spacing: -.02em; }
:lang(zh) :is(.page-head h1, .welcome h1) { font-weight: 700; line-height: 1.15; }
:lang(zh) :is(.g-title, .d-t, .strip h2, .lead, .mission, .prose h2, .day h2 time, .e-id h3) { letter-spacing: 0; }
:lang(zh) :is(.g-title, .e-id h3) { font-weight: 500; }
:lang(zh) .lede { font-weight: 700; line-height: 1.3; letter-spacing: -.01em; }
:lang(zh) .guide-head h1 { line-height: 1.2; letter-spacing: -.01em; }
:lang(zh) .prose { line-height: 1.9; }
:lang(zh) :is(.lead, .mission) { line-height: 1.6; }
:lang(zh) .ti { font-weight: 500; }
[lang="zh-Hant"] { font-family: var(--latin), "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif; }
[lang="zh-Hans"] { font-family: var(--latin), "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif; }
:lang(zh) :is(.table dd, .plain-list a, .rules li) { font-weight: 500; }
.d-s, .g-deck, .su { text-wrap: pretty; }
.d-s { text-wrap: balance; }

/* ---------- about and editorial: plain text pages, no images ---------- */

.text-head h1 { max-width: 17em; font-size: clamp(2.5rem, 5.2vw, 4.25rem); line-height: 1.05; letter-spacing: -.045em; text-wrap: balance; }
.text-page .prose h2 { display: block; font-size: 1.25rem; font-weight: 600; letter-spacing: -.02em; }
.text-page .prose > section { margin-top: 3em; }
.text-page .prose > section:first-child { margin-top: 0; }
.text-page .lead { font-size: clamp(1.375rem, 2.2vw, 1.75rem); line-height: 1.36; }
.text-page .rules { margin-top: 1em; }
.text-page .table dd, :lang(zh) .text-page .table dd { font-weight: 400; color: var(--ink); }
.text-page .table > div { grid-template-columns: minmax(0, 17rem) minmax(0, 1fr); }
.text-page .rules li, :lang(zh) :lang(zh) .text-head h1 { font-weight: 700; line-height: 1.18; letter-spacing: -.02em; }
:lang(zh) .text-page .prose h2 { letter-spacing: 0; }
:lang(zh) .text-page .lead { line-height: 1.55; }
@media (max-width: 640px) { .text-page .table > div { grid-template-columns: minmax(0, 1fr); } }
.hp { position: absolute; left: -200vw; width: 1px; height: 1px; opacity: 0; }
@media (max-width: 760px) { .doors[style*="--doors:3"] { grid-template-columns: 1fr 1fr 1fr; } .doors[style*="--doors:3"] .door { padding: 14px; } }
@media (max-width: 480px) { .doors[style*="--doors:3"] { grid-template-columns: minmax(0, 1fr); } .doors[style*="--doors:3"] .door { grid-template-rows: auto; grid-template-columns: 4.5rem minmax(0, 1fr); column-gap: 14px; align-items: center; } .doors[style*="--doors:3"] .art { grid-row: 1 / 3; height: 3.5rem; } .doors[style*="--doors:3"] .d-t { margin-top: 0; } }
