/* ================================================================
   AI 编年史 — editorial layout
   Warm paper, one accent, typographic hierarchy instead of card soup.
   ================================================================ */

:root{
  color-scheme:light;
  --bg:#fbfaf7;
  --surface:#ffffff;
  --ink:#171512;
  --ink-2:#3b3630;
  --muted:#7a746b;
  --line:#e8e3d9;
  --line-2:#f1ede5;
  --accent:#b23a1b;
  --accent-ink:#8e2c12;
  --accent-soft:#f8ede7;
  --green:#2f7d5c;
  --red:#b3261e;
  --amber:#9a6700;
  --radius:10px;
  --radius-sm:6px;
  --maxw:1080px;
  --font-sans:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Hiragino Sans GB","Microsoft YaHei","Helvetica Neue",sans-serif;
  --font-serif:"Songti SC","Noto Serif SC","Source Han Serif SC",Georgia,"Times New Roman",serif;
  --font-mono:"SF Mono",ui-monospace,"JetBrains Mono",monospace;
  font:16px/1.6 var(--font-sans);
  font-synthesis:none;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
}

*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
/* Phones (and in-app webviews such as WeChat) otherwise inflate body text on
   their own, which turns an 18px headline into a 2–3 line block nobody asked
   for. 100% keeps the size the stylesheet states. */
html{scroll-behavior:smooth;scroll-padding-top:84px;-webkit-text-size-adjust:100%;text-size-adjust:100%;background:var(--bg)}
body{
  background:linear-gradient(145deg,#f8eee7 0,var(--bg) 680px,#f5f4ec 100%);
  color:var(--ink);min-height:100vh;overflow-x:clip;
}
::selection{background:var(--accent-soft);color:var(--accent-ink)}
a{color:inherit;text-decoration:none;transition:color .15s ease}
a:hover{color:var(--accent)}
button,input,select{font:inherit;color:inherit}
button,a,summary{-webkit-tap-highlight-color:transparent}
:focus-visible{outline:2px solid var(--accent);outline-offset:3px;border-radius:4px}
h1,h2,h3{text-wrap:balance;letter-spacing:-.015em}
/* News headlines are long sentences, not titles. `balance` equalises the lines
   of a two- or three-line headline in a phone column, which pushes the break
   to the first comma ("GPT-5.4 在 ChatGPT、/ API 与 Codex 上线") and reads like
   a deliberate line break. Natural wrapping keeps the line full, and `pretty`
   only removes a one-word last line where the browser supports it. */
.feed-item h2,.rank-main h3,.article-body h1{text-wrap:wrap}
p{text-wrap:pretty}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.skip{position:absolute;left:-9999px;top:0;z-index:200;padding:10px 16px;background:var(--ink);color:#fff;border-radius:0 0 var(--radius-sm) 0}
.skip:focus{left:0}

/* ===== Header ===== */
.site-header{
  position:sticky;top:0;z-index:50;
  background:rgba(251,250,247,.86);

  border-bottom:1px solid var(--line);
}
.masthead{
  width:min(100%,var(--maxw));
  margin:0 auto;
  padding:0 24px;
  height:54px;
  display:flex;align-items:center;gap:24px;
}
.brand{display:flex;align-items:center;gap:9px;font-weight:700;font-size:15px;white-space:nowrap;flex-shrink:0}
.brand-symbol{width:28px;height:28px;flex:none}
.brand small{display:none}
.main-nav{display:flex;align-items:center;gap:2px;margin-right:auto;min-width:0}
.main-nav a{
  position:relative;
  padding:6px 11px;font-size:14px;color:var(--muted);
  border-radius:var(--radius-sm);white-space:nowrap;
  transition:color .15s ease,background-color .15s ease;
}
.main-nav a:hover{color:var(--ink);background:var(--line-2)}
.main-nav a[aria-current]{color:var(--ink);font-weight:600;background:var(--line-2)}
/* A short accent rule under the current section: the pill alone made the
   active tab look like a hover state that had stuck. */
.main-nav a[aria-current]::after{
  content:'';position:absolute;left:11px;right:11px;bottom:2px;height:2px;
  border-radius:2px;background:var(--accent);
}
.lang-switch{
  display:inline-flex;align-items:center;flex-shrink:0;
  padding:2px;gap:2px;
  border:1px solid var(--line);border-radius:999px;background:var(--surface);
}
.lang-switch a{
  padding:4px 12px;font-size:12px;font-weight:600;line-height:1.6;
  color:var(--muted);border-radius:999px;white-space:nowrap;
}
.lang-switch a:hover{color:var(--ink)}
.lang-switch a[aria-current]{background:var(--ink);color:#fff}
.archive-link{display:none}

/* ===== Hero ===== */
.hero{
  width:min(100%,var(--maxw));
  margin:0 auto;
  padding:28px 24px 18px;
  position:relative;
}
.dateline{
  font-size:12px;font-weight:600;letter-spacing:.09em;
  text-transform:uppercase;color:var(--accent);
}
/* The tagline rides along on the date line instead of taking a row of its
   own. Undo the dateline's uppercase/letter-spacing for this span only. */
.dateline-slogan{
  margin-left:.7em;font-weight:400;letter-spacing:0;
  text-transform:none;color:var(--muted);
}
.dateline-slogan::before{content:"·";margin-right:.7em;color:var(--muted)}
.hero h1{
  font-family:var(--font-serif);
  font-size:44px;line-height:1.16;font-weight:700;
  margin:8px 0 0;letter-spacing:-.02em;
}
.hero--compact{padding:30px 24px 18px}
.hero--compact h1{font-size:34px}

/* ===== Toolbar ===== */
.toolbar{width:min(100%,var(--maxw));margin:0 auto;padding:0 24px}
.searchbar{
  display:flex;align-items:center;gap:6px;
  background:var(--surface);
  border:1px solid var(--line);
  border-radius:var(--radius);
  padding:6px 6px 6px 14px;
  box-shadow:0 1px 2px rgba(23,21,18,.03);
  transition:border-color .2s ease,box-shadow .2s ease;
}
.searchbar:focus-within{
  border-color:rgba(178,58,27,.55);
  box-shadow:0 0 0 3px rgba(178,58,27,.10),0 1px 2px rgba(23,21,18,.04);
}
.searchbar .search-label{flex:1;min-width:0;display:flex}
.searchbar input[type=search]{
  width:100%;border:0;background:transparent;
  padding:7px 0;font-size:15px;min-width:0;
}
.searchbar input[type=search]:focus{outline:none}
.searchbar input[type=search]::placeholder{color:var(--muted)}
.searchbar button{
  border:0;border-radius:var(--radius-sm);
  background:var(--ink);color:#fff;
  padding:7px 16px;font-size:13px;font-weight:600;cursor:pointer;
  flex-shrink:0;
}
.searchbar button:hover{background:var(--ink-2)}
.searchbar .clear-filter{
  font-size:12px;color:var(--muted);padding:0 8px;white-space:nowrap;
}
.searchbar .clear-filter:hover{color:var(--accent)}

/* ===== Layout ===== */
.layout{
  width:min(100%,var(--maxw));
  margin:0 auto;
  padding:26px 24px 40px;
  display:grid;
  grid-template-columns:minmax(0,1fr);
  align-items:start;
}
/* The article column follows the page container instead of being pinned to
   760px; headlines and summaries then wrap at whatever width is available. */
.layout--single{grid-template-columns:minmax(0,1fr)}
.feed{min-width:0}

/* ===== Feed item ===== */
/* One card at every width: a meta row — date, time and the section pill —
   sits at the left above the headline block, which spans the full column
   below it. No side rail, no per-width restructuring. */
.feed-item{
  display:grid;grid-template-columns:auto minmax(0,1fr);gap:4px 10px;
  padding:24px 0;
  border-bottom:1px solid var(--line-2);
  position:relative;
  transition:background-color .25s ease;
}
.item-time{
  grid-column:1;grid-row:1;align-self:center;
  font-family:var(--font-mono);font-size:11px;line-height:1.7;
  color:var(--muted);white-space:nowrap;
}
.item-time time{display:flex;gap:6px;align-items:baseline}
.item-time strong{color:var(--ink-2);font-weight:600;font-size:12px}
/* Only rows from an earlier year carry this: the archive reaches back to
   2022, where "03.05" on its own would be ambiguous. */
.item-year{font-style:normal;font-size:10px;letter-spacing:.02em}
.item-source{
  grid-column:2;grid-row:1;justify-self:start;align-self:center;min-width:0;
  font-size:12px;color:var(--muted);
}
.item-source a{color:var(--accent);font-weight:500}
.item-source a:hover{text-decoration:underline;text-underline-offset:2px}
.item-main{grid-column:1 / -1;grid-row:2;min-width:0;margin-top:4px}
.item-module{
  display:inline-block;padding:2px 8px;border-radius:999px;
  background:var(--accent-soft);color:var(--accent-ink);
  font-size:11px;font-weight:600;line-height:1.6;
}
.item-module:hover{background:var(--accent);color:#fff;text-decoration:none}
.item-module[data-module="models"]{background:#eef1e8;color:#3d5b2c}
.item-module[data-module="ranking"]{background:#eee9f5;color:#57407a}
.item-module[data-module="company"]{background:#eef0f4;color:#3b4a5f}
.item-module[data-module="limits"]{background:#f6eee6;color:#7a4a1f}
.item-module[data-module="papers"]{background:#eaf1f2;color:#2f5459}
.item-module[data-module="digest"]{background:#f5efe2;color:#6b5426}
.item-module[data-module="raw"]{background:#f0f0ee;color:#4a4844}
/* Publisher mark sits before the headline, aligned to the first line. */
.item-logo{
  width:18px;height:18px;object-fit:contain;vertical-align:-3px;
  margin-right:8px;border-radius:4px;background:#fff;
}
.feed-item h2{
  font-size:20px;line-height:1.38;font-weight:600;letter-spacing:-.012em;
  /* break-word, not anywhere: a long Latin word still breaks when it cannot
     fit, but ordinary words are never chopped in half to fill a line. */
  overflow-wrap:break-word;
}
.feed-item h2 a:hover{color:var(--accent)}
.item-summary{
  font-size:15px;line-height:1.62;color:var(--ink-2);
  /* No 64ch cap: the summary fills the same fluid column as the headline. */
  margin-top:7px;max-width:100%;overflow-wrap:break-word;
}
.item-summary details{margin-top:8px}
.item-summary summary{
  cursor:pointer;font-size:12px;color:var(--accent);list-style:none;
}
.item-summary summary::-webkit-details-marker{display:none}
.item-summary summary::before{content:'▸ ';font-size:9px}
.item-summary details[open] summary::before{content:'▾ '}
.item-summary details p{margin-top:6px;font-size:14px;color:var(--ink-2)}
.item-sources{font-size:11px;color:var(--muted);margin-top:8px}
.item-sources a{color:var(--accent)}
.item-sources a:hover{text-decoration:underline}
/* Model metadata: context window and modalities carry a small label, the
   ability tags stand alone. One pill line, wrapping only when it must. */
.item-specs{
  display:flex;flex-wrap:wrap;gap:6px;margin-top:11px;max-width:100%;
}
.item-specs>span{
  display:inline-flex;align-items:baseline;gap:5px;
  padding:2px 9px;border-radius:999px;background:var(--line-2);
  font-family:var(--font-mono);font-size:11px;line-height:1.7;
  color:var(--ink-2);white-space:nowrap;
}
.item-specs i{
  font-style:normal;font-size:10px;letter-spacing:.05em;
  text-transform:uppercase;color:var(--muted);
}
.item-specs .spec-ability{
  font-family:inherit;background:transparent;
  border:1px solid var(--line);padding:1px 8px;
}

/* ===== Pagination ===== */
.pagination{display:flex;gap:8px;justify-content:space-between;padding-top:12px}
.pagination>a{
  display:inline-flex;align-items:baseline;gap:6px;
  padding:5px 11px;border:1px solid var(--line);border-radius:var(--radius-sm);
  font-size:12px;font-weight:500;color:var(--ink-2);background:var(--surface);
}
.pagination>a:hover{border-color:var(--ink);color:var(--ink)}
.pagination>a span{font-size:10px;color:var(--muted);font-family:var(--font-mono)}
.pagination>a:only-child{margin-left:auto}

/* ===== Empty state ===== */
.empty{padding:64px 0;text-align:left;border-top:1px solid var(--line-2)}
.empty-mark{display:none}
.empty h3{font-family:var(--font-serif);font-size:24px;font-weight:700;margin-bottom:8px}
.empty p{font-size:14px;color:var(--muted);margin-bottom:18px;max-width:52ch}
.button{
  display:inline-flex;align-items:center;gap:6px;
  padding:9px 16px;border-radius:var(--radius-sm);
  background:var(--ink);color:#fff;font-size:13px;font-weight:600;
}
.button:hover{background:var(--ink-2);color:#fff}
.button.secondary{background:transparent;color:var(--ink);border:1px solid var(--line)}
.button.secondary:hover{border-color:var(--ink);color:var(--ink)}

/* ===== Secondary archive views ===== */
.edition-intro{display:none}
.archive-date{
  display:flex;align-items:baseline;gap:10px;
  padding:26px 0 10px;font-size:14px;font-weight:700;
}
.archive-date span{font-size:12px;color:var(--muted);font-weight:400}
.reading-note{
  font-size:13px;color:var(--muted);
  padding:0 0 18px;max-width:68ch;
}
/* Tracked accounts, shown when X collection is not connected yet. */
.x-handles{display:flex;flex-wrap:wrap;gap:6px;padding:0 0 22px;max-width:68ch}
.x-handles a{
  padding:2px 9px;border:1px solid var(--line);border-radius:999px;
  background:var(--surface);color:var(--ink-2);font-size:12.5px;line-height:1.8;
}
.x-handles a:hover{border-color:var(--accent);color:var(--accent)}
.outbound{font-size:12px;color:var(--muted);margin-left:2px;white-space:nowrap}

/* ===== Leaderboards (archive counts + external evaluations) ===== */
.ranking-list{list-style:none;display:flex;flex-direction:column}
.rank-row{
  display:grid;grid-template-columns:34px minmax(0,1fr) 92px;
  gap:14px;align-items:start;
  padding:18px 0;border-bottom:1px solid var(--line-2);
}
.rank-no{
  font-family:var(--font-mono);font-size:14px;font-weight:700;
  color:var(--accent);padding-top:2px;
}
.rank-main{min-width:0}
.rank-vendor{font-size:11px;color:var(--muted);margin-bottom:3px}
.rank-vendor time{font-family:var(--font-mono)}
.rank-main h3{font-size:17px;line-height:1.35;font-weight:600;overflow-wrap:break-word}
.rank-main h3 a:hover{color:var(--accent)}
.rank-facts{
  font-size:12px;color:var(--ink-2);line-height:1.6;
  margin-top:5px;overflow-wrap:anywhere;
}
.rank-breakdown{font-size:11px;color:var(--muted);margin-top:3px}
.rank-tie{
  display:inline-block;margin-left:8px;padding:0 6px;border-radius:999px;
  background:var(--line-2);color:var(--muted);font-size:10px;line-height:1.7;
}
.rank-score{text-align:right}
.rank-score strong{
  display:block;font-family:var(--font-serif);font-size:26px;
  line-height:1.1;font-weight:700;
}
.rank-score span{font-size:10px;color:var(--muted)}
.rank-bar{
  display:block;height:3px;margin-top:7px;max-width:100%;
  background:var(--accent);border-radius:2px;
}

/* ===== About / sources ===== */
.sources-section{margin-top:8px;padding-top:22px;border-top:1px solid var(--line)}
.sources-section .section-heading{
  display:flex;align-items:baseline;justify-content:space-between;gap:12px;
  margin-bottom:10px;flex-wrap:wrap;
}
.sources-section .section-heading h2{font-size:17px}
.sources-section .section-heading span{font-size:12px;color:var(--muted)}
.sources-section>p{font-size:13px;color:var(--muted);max-width:68ch;margin-bottom:14px}
.sources-section details>summary{
  cursor:pointer;padding:9px 0;font-size:13px;color:var(--ink-2);
  list-style:none;border-bottom:1px solid var(--line-2);
}
.sources-section details>summary::-webkit-details-marker{display:none}
.sources-section details>summary::before{content:'▸ ';font-size:9px;color:var(--accent)}
.sources-section details[open]>summary::before{content:'▾ '}
.sources-section details>summary span{font-size:11px;color:var(--muted);margin-left:8px}
.source-table{display:grid;gap:0}
.source-row{
  display:grid;grid-template-columns:1fr auto auto;gap:12px;align-items:center;
  padding:7px 0;font-size:13px;border-bottom:1px solid var(--line-2);
}
.source-row strong{font-weight:500;color:var(--ink-2);overflow-wrap:anywhere}
.source-row .health{font-size:12px;font-weight:500}
.source-row .health-ok{color:var(--green)}
.source-row .health-fail{color:var(--red)}
.source-row .health-pending{color:var(--muted)}
.source-row time{font-size:11px;color:var(--muted);font-family:var(--font-mono)}

/* ===== Footer ===== */
footer{
  width:min(100%,var(--maxw));
  margin:0 auto;
  padding:24px 24px 40px;
  border-top:1px solid var(--line);
  display:flex;align-items:baseline;justify-content:space-between;gap:16px;flex-wrap:wrap;
}
.footer-brand{font-size:13px;font-weight:600;color:var(--ink-2)}
.footer-brand span{font-weight:400;color:var(--muted);margin-left:6px}
footer>div{display:flex;gap:16px}
footer a{font-size:12px;color:var(--muted)}
footer a:hover{color:var(--accent)}

/* ===== Legal / article ===== */
.legal{max-width:680px;margin:0 auto;padding:48px 24px 72px}
.legal h1{font-family:var(--font-serif);font-size:30px;line-height:1.25;margin-bottom:18px}
.legal p{font-size:15px;color:var(--ink-2);line-height:1.75;margin-bottom:16px}
.legal a{color:var(--accent);text-decoration:underline;text-underline-offset:3px}
.legal h2{font-size:16px;margin:30px 0 10px;font-weight:700}
.about-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:14px;margin:14px 0 18px}
.about-stats>div{border-top:2px solid var(--ink);padding-top:8px}
.about-stats dt{font-size:11px;color:var(--muted);letter-spacing:.06em;text-transform:uppercase}
.about-stats dd{font-family:var(--font-serif);font-size:22px;font-weight:700;line-height:1.3}
.legal .side-panel{margin:18px 0}
/* ===== Article ===== */
/* Same container as the masthead, hero and feed — no separate 760px cap. */
.article-body{width:min(100%,var(--maxw));margin:0 auto;padding:52px 24px 80px}
.article-body .dateline{margin-bottom:14px}
.article-body .dateline a{color:var(--accent)}
.article-body h1{
  font-family:var(--font-serif);font-size:36px;line-height:1.28;
  letter-spacing:-.02em;margin-bottom:22px;
}
.article-body h1 .item-logo{width:26px;height:26px;vertical-align:-4px;margin-right:10px}
.article-excerpt{font-size:18px;line-height:1.85;color:var(--ink-2)}
/* The publisher's page, fetched and re-flowed: one paragraph per block. */
.article-fulltext{margin-top:2px}
.article-fulltext p{
  font-size:16px;line-height:1.85;color:var(--ink);
  margin-bottom:1em;overflow-wrap:break-word;
}
/* Brief at the top of every article: classification, publisher, time, the
   concrete numbers the source itself states, and the other language when a
   translation exists. */
.article-brief{
  background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);
  padding:16px 18px;margin-bottom:26px;
}
.brief-head{
  display:flex;flex-wrap:wrap;align-items:center;gap:6px 12px;
  font-size:12px;color:var(--muted);margin-bottom:10px;
}
.brief-chip{
  padding:2px 9px;border-radius:999px;background:var(--accent-soft);
  color:var(--accent-ink);font-weight:600;
}
.brief-summary{font-size:15px;line-height:1.72;color:var(--ink-2)}
.brief-bilingual{margin-top:12px;font-size:13.5px;color:var(--muted)}
.brief-bilingual summary{cursor:pointer;color:var(--accent);list-style:none}
.brief-bilingual summary::-webkit-details-marker{display:none}
.brief-bilingual h3{font-size:14px;font-weight:600;color:var(--ink-2);margin:8px 0 4px}
.brief-bilingual p{line-height:1.7}
.article-note{
  font-size:13px;color:var(--muted);
  margin-top:20px;padding-top:14px;border-top:1px solid var(--line-2);
}
.article-body h2{
  font-size:11px;letter-spacing:.09em;text-transform:uppercase;
  color:var(--muted);margin:34px 0 10px;
}
.article-refs{list-style:none;display:flex;flex-direction:column;gap:6px}
.article-refs a{color:var(--accent);font-size:14px}
.article-refs a:hover{text-decoration:underline;text-underline-offset:3px}
.article-return{margin-top:36px}
.button{
  display:inline-block;padding:8px 16px;border-radius:var(--radius-sm);
  background:var(--ink);color:#fff;font-size:13px;font-weight:600;
}
.button:hover{background:var(--ink-2);color:#fff}

/* ===== Legacy sidebar (about status only) ===== */
.side-panel{
  padding:16px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--radius);
}
.panel-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:10px}
.panel-heading h2{font-size:13px;font-weight:700}
.panel-heading a{font-size:12px;color:var(--accent)}
.panel-heading span{font-size:11px;color:var(--muted)}
.panel-intro{font-size:12px;color:var(--muted);margin-bottom:8px}
.panel-footnote{font-size:11px;color:var(--muted);margin-top:8px;padding-top:8px;border-top:1px solid var(--line-2)}
.sync-panel dl,.ai-panel dl{display:flex;flex-direction:column;gap:5px;margin-bottom:8px}
.sync-panel dl>div,.ai-panel dl>div{display:flex;justify-content:space-between;gap:8px}
.sync-panel dt,.ai-panel dt{font-size:12px;color:var(--muted)}
.sync-panel dd,.ai-panel dd{font-size:12px;color:var(--ink-2);text-align:right;overflow-wrap:anywhere;max-width:65%}
.status-dot,.ai-dot{width:7px;height:7px;border-radius:50%;display:inline-block;background:var(--line)}
.status-dot[data-state="ok"],.ai-panel[data-state="ok"] .ai-dot{background:var(--green)}
.status-dot[data-state="error"],.ai-panel[data-state="error"] .ai-dot{background:var(--red)}
.ai-state{display:flex;flex-direction:column;gap:2px;margin:4px 0 10px}
.ai-state strong{font-size:14px}
.ai-state span{font-size:12px;color:var(--muted);overflow-wrap:anywhere}

/* ===== Responsive ===== */
@media(max-width:920px){
  .layout{padding-bottom:56px}
}
/* The single-row header needs ~850px once the English labels are present.
   Below that, keep brand + language on row 1 and the chips on row 2 so nav
   content can never spill over the switch or off the right edge. */
@media(max-width:900px){
  html{scroll-padding-top:66px}
  .masthead{
    display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;
    gap:0 8px;height:auto;padding:5px 12px 3px;overflow:visible;
  }
  .brand{grid-area:1/1;justify-self:start;width:fit-content;font-size:13px}
  .brand-symbol{width:20px;height:20px}
  .lang-switch{grid-area:1/2;justify-self:end;margin:0}
  .lang-switch a{padding:2px 9px;font-size:11px}
  .main-nav{
    grid-area:2/1/3/3;width:auto;margin:0;padding:0 0 2px;
    overflow-x:auto;scrollbar-width:none;
  }
  .main-nav::-webkit-scrollbar{display:none}
}
@media(max-width:680px){
  .main-nav a{padding:6px 8px;font-size:12.5px}

  .hero{padding:18px 16px 14px}
  .hero h1{font-size:32px}
  .hero--compact h1{font-size:26px}
  .dateline-slogan{font-size:11px}
  .toolbar{padding:0 16px}
  /* The search bar is one row on a phone: keyword and button. */
  .searchbar{padding:8px 8px 8px 12px}
  .searchbar .clear-filter{padding:0 6px}
  .layout{padding:20px 16px 48px}
  .feed-item{padding:20px 0}
  .feed-item h2{font-size:18px}
  .item-summary{font-size:14px}
  .item-specs{gap:5px}
  .rank-row{grid-template-columns:26px minmax(0,1fr) 58px;gap:8px}
  .rank-no{font-size:12px}
  .rank-main h3{font-size:15px}
  .rank-score strong{font-size:21px}
  .legal{padding:32px 16px 56px}
  .legal h1{font-size:25px}
  .article-body{padding:36px 16px 56px}
  .article-body h1{font-size:27px}
  .article-excerpt{font-size:16px;line-height:1.8}
  footer{padding:20px 16px 32px}
}
/* Five sections do not fit a phone in English, so the nav swaps to short
   labels (both live in the DOM; the link keeps the full accessible name). */
.nav-short{display:none}
@media(max-width:560px){
  .nav-long{display:none}
  .nav-short{display:inline}
  .main-nav{gap:0}
  .main-nav a{padding:6px 6px;font-size:12.5px}
  .main-nav a:first-child{margin-left:-6px}
}

@media(prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{transition:none!important;animation:none!important}
}

/* Five Chinese labels need the last 16px at 320px; keep this last so it wins
   over the wider breakpoint above. */
@media(max-width:370px){
  .main-nav a{padding:6px 4px;font-size:12px}
  .main-nav a:first-child{margin-left:-4px}
}

/* Ranking: cached real leaderboard tables */
.rank-nav{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 24px}
.rank-nav a{
  display:inline-flex;align-items:center;padding:7px 13px;
  border:1px solid var(--line);border-radius:999px;
  background:rgba(255,255,255,.7);color:var(--ink-2);font-size:13px;
  transition:color .15s ease,border-color .15s ease,background-color .15s ease;
}
.rank-nav a:hover,.rank-nav a:focus-visible{
  color:var(--accent-ink);border-color:var(--accent);background:var(--accent-soft);
}
.rank-section{scroll-margin-top:76px;margin-top:36px}
.lb-meta{font-size:12.5px;line-height:1.75;color:var(--ink-2);margin:6px 0 12px}
.lb-meta span{color:var(--muted);font-size:11.5px}
.lb-meta a{color:var(--accent);text-decoration:underline;text-underline-offset:2px}
.lb-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch}
.lb-table{width:100%;border-collapse:collapse;font-size:13px}
.lb-table th{
  text-align:left;font-size:11px;font-weight:600;letter-spacing:.03em;
  color:var(--muted);padding:8px 10px;border-bottom:1px solid var(--line);
  white-space:nowrap;
}
.lb-table td{padding:10px;border-bottom:1px solid var(--line-2);vertical-align:middle}
.lb-table tbody tr{transition:background-color .18s ease}
@media(hover:hover){.lb-table tbody tr:hover{background-color:rgba(255,255,255,.62)}}
.lb-rank{font:700 12px/1 var(--font-mono);color:var(--accent);width:38px;white-space:nowrap}
.lb-name{font-weight:600;line-height:1.4;overflow-wrap:anywhere;min-width:180px}
.lb-org,.lb-extra{color:var(--muted);font-size:11.5px;white-space:nowrap}
/* On a phone the publisher folds under the model name instead of stealing a
   column, so the score never gets pushed off the right edge. */
.lb-sub{display:none}
.lb-value{text-align:right;white-space:nowrap;min-width:104px}
.lb-value strong{display:block;font:700 15px/1.2 var(--font-mono);color:var(--ink)}
/* Length follows the measured value, so near-equal scores look near-equal. */
.lb-bar{
  display:block;height:3px;margin:6px 0 0 auto;border-radius:2px;
  background:linear-gradient(90deg,var(--accent-soft),var(--accent));
}
@media(max-width:640px){
  .lb-extra,.lb-table th:nth-child(5){display:none}
  .lb-org,.lb-table th:nth-child(3){display:none}
  .lb-sub{display:block;font-size:11px;font-weight:400;color:var(--muted);margin-top:2px}
  .lb-table{font-size:12px}
  .lb-table th{padding:7px 6px}
  .lb-table td{padding:9px 6px}
  .lb-name{min-width:0}
  .lb-rank{width:26px}
  .lb-value{min-width:72px}
  .lb-value strong{font-size:13px}
}

/* ================================================================
   Motion, advertising, finishing touches
   ================================================================ */

/* ---- Entrance ---- */
/* Rows rise once on first paint. The stagger stops after six children: past
   that the delay would outlast the animation, and a list that keeps arriving
   reads as slow rather than sequenced. `both` fills backwards, so a row is
   never painted at its final position and then moved. */
@media(prefers-reduced-motion:no-preference){
  .lb-table tbody tr{animation:rise .46s cubic-bezier(.2,.7,.3,1) both}
.lb-table tbody tr:nth-child(2){animation-delay:.045s}
.lb-table tbody tr:nth-child(3){animation-delay:.09s}
.lb-table tbody tr:nth-child(4){animation-delay:.135s}
.lb-table tbody tr:nth-child(5){animation-delay:.18s}
.lb-table tbody tr:nth-child(6){animation-delay:.225s}
.lb-table tbody tr:nth-child(n+7){animation-delay:.27s}
  /* The bar grows to its score instead of appearing at full width: the
     ranking is the one place where the length carries the meaning. */
  .rank-bar{transform-origin:0 50%;animation:grow .8s cubic-bezier(.2,.7,.3,1) both;animation-delay:.2s}
}
@keyframes rise{from{opacity:0;transform:translateY(7px)}to{opacity:1;transform:none}}
@keyframes grow{from{transform:scaleX(0)}to{transform:scaleX(1)}}

/* ---- Advertising ---- */
/* The box exists whether or not a unit is configured, because a slot that
   appears later pushes the article down under the reader's thumb. Before
   AdSense is live the strip stays short — an empty 280px hole in the middle
   of a feed reads as a broken page, not as a reservation — and takes its
   full format height only once there is something to fill it. */
.ad-slot{
  position:relative;
  display:flex;align-items:center;justify-content:center;
  margin:24px 0;padding:16px 14px;
  min-height:96px;
  border:1px solid var(--line-2);
  border-radius:var(--radius);
  background:rgba(255,255,255,.34);
  overflow:hidden;
}
.ad-slot[data-live="1"][data-ad-kind="leaderboard"]{min-height:104px}
.ad-slot[data-live="1"][data-ad-kind="infeed"]{min-height:284px}
.ad-slot[data-live="1"][data-ad-kind="article"]{min-height:284px}
/* A leaderboard is a page-level band, so it keeps the page's gutters; the
   in-feed and article units already live inside a measured column. */
main>.ad-slot{width:min(100% - 48px,var(--maxw));margin-left:auto;margin-right:auto}
.ad-label{
  position:absolute;top:7px;left:11px;
  font-size:9px;font-weight:600;letter-spacing:.14em;text-transform:uppercase;
  color:var(--muted);opacity:.65;
}
.ad-placeholder{
  font-size:12px;letter-spacing:.06em;color:var(--muted);opacity:.6;
}
.ad-slot .adsbygoogle{width:100%}

/* ---- Finishing touches ---- */
.item-module{transition:background-color .2s ease,color .2s ease}
.button{transition:transform .2s cubic-bezier(.2,.7,.3,1),background-color .15s ease,color .15s ease}
.button:hover{transform:translateY(-1px)}
.pagination>a{transition:border-color .15s ease,color .15s ease,transform .2s cubic-bezier(.2,.7,.3,1)}
.pagination>a:hover{transform:translateY(-1px)}
.lang-switch a{transition:background-color .18s ease,color .18s ease}
footer a{transition:color .15s ease}
@supports (scrollbar-width:thin){
  html{scrollbar-width:thin;scrollbar-color:var(--line) transparent}
}

@media(max-width:680px){
  .ad-slot[data-live="1"][data-ad-kind="infeed"],
  .ad-slot[data-live="1"][data-ad-kind="article"]{min-height:254px}
  main>.ad-slot{width:calc(100% - 32px)}

}

@media(prefers-reduced-motion:reduce){
  body::before{animation:none}
  .dateline::before{animation:none}
  .feed-item,.lb-table tbody tr,.rank-bar{animation:none!important}
  .feed-item:hover,.button:hover,.pagination>a:hover,.brand:hover .brand-symbol{transform:none}
}

/* Card links retain native keyboard, touch and context-menu behavior. */
.feed-item{padding:20px 16px;border-radius:var(--radius);transition:background-color .25s,opacity .65s,transform .65s}
.feed-item h2 a::after{content:"";position:absolute;inset:0;border-radius:var(--radius)}
.feed-item h2 a:focus-visible::after{outline:2px solid var(--accent);outline-offset:-2px}
.feed-item .item-module{position:relative;z-index:1}
/* The aurora background is coloured and textured, so an opaque accent fill
   read as a slab dropped on top of the page. A translucent white lift plus a
   pointer-tracked highlight keeps the card in the same light as its backdrop. */
.feed-item:focus-within,.feed-item:active{background-color:rgba(255,255,255,.55)}
@media(hover:hover){
 .feed-item:hover{
  background-color:rgba(255,255,255,.52);
  background-image:radial-gradient(340px circle at var(--mx,50%) var(--my,50%),rgba(255,255,255,.95),rgba(255,255,255,0) 72%);
  background-repeat:no-repeat;
  box-shadow:0 8px 26px rgba(23,21,18,.055);
  transform:translate3d(var(--dx,0px),var(--dy,0px),0);
  transition:background-color .25s ease,transform .14s ease,box-shadow .25s ease;
 }
}
.feed-item.awaiting-view{opacity:0;transform:translateY(12px)}
.feed-item.awaiting-view:focus-within{opacity:1;transform:none}
.main-nav a:is(:active,:focus-visible),.lang-switch a:active{background:var(--accent-soft);color:var(--accent-ink)}

body{position:relative;isolation:isolate;background:var(--bg)}
/* A faint warm wash under everything, now travelling far enough to be seen. */
body::before{
 content:"";position:fixed;inset:-12%;z-index:-2;pointer-events:none;
 background:radial-gradient(ellipse at 15% 15%,rgba(178,58,27,.14),transparent 62%),
 radial-gradient(ellipse at 85% 70%,rgba(137,146,110,.13),transparent 66%);
 animation:paper-light 26s ease-in-out infinite alternate;
}
@keyframes paper-light{from{transform:translate(-4%,-3%) scale(1);opacity:.45}to{transform:translate(5%,4%) scale(1.14);opacity:1}}

/* ---- Ambient aurora ----
   Four blurred colour fields drift on independent clocks, a masked conic ring
   turns once a minute, a paper grid parallaxes underneath and a soft sheen
   crosses the page. Purely decorative: fixed, behind the content, inert to
   pointer events, and switched off for reduced motion and small screens. */
.ambient{position:fixed;inset:0;z-index:-1;pointer-events:none;overflow:hidden}
.ambient span{position:absolute;display:block;will-change:transform,opacity}
.ambient .glow{width:66vmax;height:66vmax;border-radius:50%;filter:blur(58px);mix-blend-mode:multiply}
.glow-a{left:-22vmax;top:-24vmax;background:radial-gradient(circle,rgba(214,86,42,.40),transparent 68%);animation:drift-a 19s ease-in-out infinite alternate}
.glow-b{right:-24vmax;top:6vmax;background:radial-gradient(circle,rgba(74,124,166,.36),transparent 68%);animation:drift-b 27s ease-in-out infinite alternate}
.glow-c{left:4vmax;bottom:-30vmax;background:radial-gradient(circle,rgba(126,148,86,.36),transparent 70%);animation:drift-c 33s ease-in-out infinite alternate}
.glow-d{right:-12vmax;bottom:-22vmax;background:radial-gradient(circle,rgba(176,86,138,.28),transparent 70%);animation:drift-d 23s ease-in-out infinite alternate}
.ambient .ring{
 width:96vmax;height:96vmax;left:50%;top:50%;margin:-48vmax 0 0 -48vmax;border-radius:50%;
 background:conic-gradient(from 0deg,rgba(178,58,27,.17),rgba(74,124,166,.15),rgba(126,148,86,.15),rgba(176,86,138,.15),rgba(178,58,27,.17));
 -webkit-mask:radial-gradient(circle,transparent 30%,#000 47%,#000 56%,transparent 74%);
 mask:radial-gradient(circle,transparent 30%,#000 47%,#000 56%,transparent 74%);
 animation:aurora-turn 62s linear infinite,aurora-breathe 8s ease-in-out infinite alternate;
}
.ambient .grain{
 inset:-20%;
 background-image:linear-gradient(rgba(23,21,18,.045) 1px,transparent 1px),linear-gradient(90deg,rgba(23,21,18,.045) 1px,transparent 1px);
 background-size:72px 72px;
 -webkit-mask:radial-gradient(ellipse at 50% 38%,#000,transparent 78%);
 mask:radial-gradient(ellipse at 50% 38%,#000,transparent 78%);
 animation:grain-drift 34s ease-in-out infinite alternate;
}
.ambient .sweep{
 inset:0;background:linear-gradient(112deg,transparent 43%,rgba(255,255,255,.42) 50%,transparent 57%);
 background-size:260% 260%;animation:sheen 15s linear infinite;
}
@keyframes drift-a{from{transform:translate3d(-4%,-3%,0) scale(.94);opacity:.55}to{transform:translate3d(12%,9%,0) scale(1.16);opacity:1}}
@keyframes drift-b{from{transform:translate3d(6%,-2%,0) scale(1.12);opacity:1}to{transform:translate3d(-12%,10%,0) scale(.9);opacity:.5}}
@keyframes drift-c{from{transform:translate3d(-8%,6%,0) scale(.92);opacity:.5}to{transform:translate3d(10%,-10%,0) scale(1.18);opacity:1}}
@keyframes drift-d{from{transform:translate3d(4%,8%,0) scale(1.14);opacity:1}to{transform:translate3d(-10%,-8%,0) scale(.92);opacity:.55}}
@keyframes aurora-turn{to{transform:rotate(360deg)}}
@keyframes aurora-breathe{from{opacity:.45}to{opacity:1}}
@keyframes grain-drift{from{transform:translate3d(0,0,0)}to{transform:translate3d(-36px,-28px,0)}}
@keyframes sheen{from{background-position:140% 0}to{background-position:-140% 0}}
@media(max-width:768px){
 .ambient .glow{filter:blur(38px)}
 .ambient .ring,.ambient .sweep{display:none}
}
@media(prefers-reduced-motion:reduce){.ambient{display:none}}
/* A narrow vertical index: years stacked over month links. The grid column
   sizes itself to the labels instead of reserving a fixed 176px rail, so the
   article column keeps its width and reflows with the viewport. */
.layout--archive{grid-template-columns:minmax(0,1fr) auto;gap:16px}
.month-filter{
 grid-column:2;grid-row:1;min-width:0;width:auto;
 /* The bottom padding is the fade's room: without it the last month sits
    flush against the scrollport edge and dissolves into the fade forever. */
 padding:2px 0 54px 10px;border-left:1px solid var(--line);
 position:sticky;top:66px;max-height:min(72vh,620px);
 overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;
 /* The rail scrolls inside a fixed height; a hard cut at the bottom edge
    reads as a clipped list. Masking the scroller dissolves whatever crosses
    the edge, at any scroll position. A sticky backdrop-filter overlay was
    tried first and composited into a white block over the last month. */
 -webkit-mask-image:linear-gradient(to bottom,#000 calc(100% - 52px),transparent);
 mask-image:linear-gradient(to bottom,#000 calc(100% - 52px),transparent);
}
.month-filter h3{font:600 11px/1.4 var(--font-mono);margin:10px 0 3px;color:var(--muted);letter-spacing:.04em}
.month-year>div{display:flex;flex-direction:column;gap:1px}
.month-filter nav>a{margin-bottom:4px;font-size:11px;color:var(--muted)}
.month-filter a{display:block;min-height:0;padding:3px 6px;font-size:12px;line-height:1.5;white-space:nowrap;border-radius:5px}
.month-filter a[aria-current]{background:rgba(178,58,27,.14);color:var(--accent-ink);font-weight:700}
.month-filter a:active{background:rgba(255,255,255,.7);color:var(--accent-ink)}
@media(hover:hover){.month-filter a:hover{background:rgba(255,255,255,.75);color:var(--accent-ink)}}
@media(max-width:900px){
 .masthead{gap:0 8px;padding:5px 12px 3px}
 .main-nav{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:2px;width:100%;padding:0;overflow:visible}
 .main-nav a{display:flex;justify-content:center;align-items:center;min-height:32px;padding:3px 1px;font-size:11px;text-align:center}
 .nav-long{display:none!important}.nav-short{display:inline!important}
 .main-nav::after{display:none}
 .lang-switch a{min-height:28px;display:flex;align-items:center}
 /* On a narrow screen the month rail costs a third of the reading column.
    Drop the rail and give the whole width back to the feed; ?month= still
    filters because the toolbar keeps it in a hidden input. */
 .layout--archive{grid-template-columns:minmax(0,1fr)}
 .month-filter{display:none}
}
@media(max-width:480px){
 /* No per-rail headline/summary widths: the article column is fluid, so the
    text simply wraps to whatever width the viewport leaves it. */
 .item-summary{overflow-wrap:anywhere}
 .item-source{min-width:0}
 .item-module{white-space:normal}
}
@media(hover:none){.feed-item:hover{background:transparent;transform:none}.feed-item:active{background-color:rgba(255,255,255,.55)}}
@media(prefers-reduced-motion:reduce){
  .feed-item.awaiting-view{opacity:1;transform:none}
  .feed-item{transition:none}
}
