/* antibiowar.com — international editorial */
:root {
  --paper: #f3eee4;
  --paper-2: #e9e2d5;
  --card: #fbf8f1;
  --ink: #12151a;
  --ink-soft: #3c3f45;
  --muted: #6a6660;
  --rule: #d8d0c3;
  --rule-strong: #1a1f25;
  --header: #0c1014;
  --navy: #141a20;
  --navy-2: #222a32;
  --ivory: #f6f1e8;
  --accent: #b0894f;
  --gold: #c4a46a;
  --link: #7a3f2a;
  --oxblood: #7a3f2a;
  --oxblood-soft: #9a5a48;
  --teal: #1d4a45;
  --focus: #b0894f;
  --danger: #7a3f2a;
  --ok: #1d4a45;
  --shadow: 0 1px 0 rgba(12, 16, 20, 0.04), 0 18px 40px rgba(12, 16, 20, 0.06);
  --font-serif: "Source Serif 4", "Noto Serif SC", "Songti SC", "STSong", "Times New Roman", serif;
  --font-sans: "Source Sans 3", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  --max: 74rem;
  --narrow: 44rem;
}

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

html { scroll-behavior: smooth; }

html[lang="en"] body { font-size: 1.05rem; }
html[lang="zh-Hans"] body { font-size: 1.02rem; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  line-height: 1.65;
  min-height: 100vh;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover { color: var(--navy); }

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

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -3rem;
  background: var(--header);
  color: var(--ivory);
  padding: 0.5rem 0.8rem;
  z-index: 1000;
}
.skip-link:focus { top: 0.75rem; }

/* Header — dark masthead */
.site-header {
  background: var(--header);
  color: var(--ivory);
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(196, 164, 106, 0.28);
}
.masthead {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.85rem 1.5rem 0.55rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: inherit;
}
.brand img, .brand svg {
  width: 2.55rem;
  height: 2.55rem;
  flex-shrink: 0;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name {
  font-family: var(--font-serif);
  font-weight: 700;
  letter-spacing: 0.06em;
  font-size: 1.2rem;
  color: var(--ivory);
  font-variation-settings: "opsz" 28;
}
.brand-tag {
  font-size: 0.72rem;
  color: rgba(246, 241, 232, 0.62);
  letter-spacing: 0.04em;
}
.header-tools {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.lang-toggle {
  display: inline-flex;
  border: 1px solid rgba(246, 241, 232, 0.35);
  background: transparent;
  padding: 0;
  border-radius: 999px;
  overflow: hidden;
}
.lang-toggle button {
  appearance: none;
  border: 0;
  background: transparent;
  color: rgba(246, 241, 232, 0.8);
  font: inherit;
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  padding: 0.26rem 0.7rem;
  cursor: pointer;
}
.lang-toggle button[aria-pressed="true"] {
  background: var(--ivory);
  color: var(--header);
}
.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid rgba(246, 241, 232, 0.45);
  color: var(--ivory);
  padding: 0.3rem 0.55rem;
  font: inherit;
  font-size: 0.8rem;
  cursor: pointer;
}
.site-nav {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.5rem 0;
}
.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav a {
  display: inline-block;
  padding: 0.45rem 0.9rem 0.7rem;
  color: rgba(246, 241, 232, 0.78);
  text-decoration: none;
  font-size: 0.86rem;
  letter-spacing: 0.02em;
  border-bottom: 1px solid transparent;
}
.site-nav a:hover { color: var(--ivory); }
.site-nav a[aria-current="page"] {
  color: var(--ivory);
  border-bottom-color: var(--gold);
}

/* Layout */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.5rem;
}
.wrap-narrow { max-width: var(--narrow); margin: 0 auto; padding: 0 1.5rem; }
main { padding: 0 0 5rem; }

.page-body { padding-top: 2.2rem; }
.page-body-narrow { padding-top: 2.2rem; max-width: var(--narrow); }

.kicker,
.page-kicker,
.section-kicker {
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 0.55rem;
  font-weight: 600;
}
.page-title {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(1.85rem, 3.2vw, 2.7rem);
  line-height: 1.18;
  margin: 0 0 0.85rem;
  color: var(--navy);
  font-variation-settings: "opsz" 48;
}
.lede {
  font-size: 1.12rem;
  color: var(--ink-soft);
  max-width: 46rem;
  margin: 0 0 1.5rem;
  line-height: 1.7;
}
.callout, .disclaimer, .note {
  background: var(--card);
  border: 1px solid var(--rule);
  border-inline-start: 2px solid var(--gold);
  padding: 1rem 1.15rem;
  margin: 1.35rem 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}
.disclaimer { border-inline-start-color: var(--accent); }
.grid-4, .grid-2, .grid-3 {
  display: grid;
  gap: 1.25rem;
}
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--card);
  border: 1px solid var(--rule);
  padding: 1.25rem 1.3rem 1.35rem;
  box-shadow: var(--shadow);
}
.card h2, .card h3 {
  font-family: var(--font-serif);
  margin: 0 0 0.5rem;
  color: var(--navy);
  line-height: 1.3;
  font-variation-settings: "opsz" 28;
}
.card p { margin: 0 0 0.7rem; color: var(--ink-soft); }
.card .more {
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-decoration: none;
  color: var(--link);
}
.card .more:hover { text-decoration: underline; }

.stat-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin: 0;
  padding: 1.75rem 0 0.25rem;
  border-top: 1px solid var(--rule);
}
.stat { padding: 0.2rem 0 0.2rem; }
.stat b {
  display: block;
  font-family: var(--font-serif);
  font-size: 2rem;
  line-height: 1.05;
  color: var(--navy);
  font-variation-settings: "opsz" 36;
  font-weight: 700;
}
.stat span { font-size: 0.84rem; color: var(--muted); }

.rule {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 2.2rem 0;
}
.section-title {
  font-family: var(--font-serif);
  font-size: 1.65rem;
  margin: 0 0 1rem;
  color: var(--navy);
  font-variation-settings: "opsz" 36;
  font-weight: 700;
}

/* Photographic heroes */
.photo-hero {
  position: relative;
  color: var(--ivory);
  min-height: 28rem;
  overflow: hidden;
  background: #0a0d10;
}
.photo-hero--home { min-height: min(78vh, 42rem); }
.photo-hero--page { min-height: min(52vh, 30rem); }
.photo-hero picture,
.photo-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.photo-hero img {
  object-fit: cover;
  object-position: center 45%;
  max-width: none;
}
.photo-hero__shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(8, 11, 14, 0.28) 0%, rgba(8, 11, 14, 0.22) 35%, rgba(8, 11, 14, 0.72) 78%, rgba(8, 11, 14, 0.9) 100%),
    linear-gradient(90deg, rgba(8, 11, 14, 0.45) 0%, rgba(8, 11, 14, 0.12) 55%, rgba(8, 11, 14, 0.2) 100%);
  pointer-events: none;
}
.photo-hero__inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: inherit;
  padding-top: 5.5rem;
  padding-bottom: 3.2rem;
}
.photo-hero .kicker {
  color: var(--gold);
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.35);
}
.photo-hero h1 {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(2.15rem, 5.4vw, 3.85rem);
  line-height: 1.12;
  margin: 0;
  max-width: 18ch;
  color: var(--ivory);
  font-variation-settings: "opsz" 60;
  text-wrap: balance;
}
.photo-hero--page h1 {
  font-size: clamp(1.85rem, 4vw, 3rem);
  max-width: 22ch;
}
.photo-caption {
  position: relative;
  z-index: 1;
  margin: 0;
  padding: 0.55rem 1.5rem 0.7rem;
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: rgba(246, 241, 232, 0.72);
  line-height: 1.45;
}

/* Editorial tiles */
.ed-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.15rem;
}
.ed-tile {
  position: relative;
  display: block;
  min-height: 22rem;
  overflow: hidden;
  color: var(--ivory);
  text-decoration: none;
  background: #0a0d10;
  isolation: isolate;
}
.ed-tile picture,
.ed-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-width: none;
  transition: transform 0.6s ease;
}
.ed-tile:hover img { transform: scale(1.03); }
.ed-tile__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8,11,14,0.1) 0%, rgba(8,11,14,0.25) 35%, rgba(8,11,14,0.86) 100%);
}
.ed-tile__body {
  position: relative;
  z-index: 1;
  height: 100%;
  min-height: 22rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem 1.4rem 1.35rem;
}
.ed-tile .kicker { color: var(--gold); }
.ed-tile h2 {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  line-height: 1.25;
  margin: 0 0 0.45rem;
  color: var(--ivory);
  font-variation-settings: "opsz" 32;
}
.ed-tile p {
  margin: 0 0 0.85rem;
  color: rgba(246, 241, 232, 0.86);
  font-size: 0.95rem;
  max-width: 38rem;
}
.ed-tile .more {
  color: var(--gold);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
  text-decoration: none;
}
.ed-tile .tile-cap {
  margin: 0.7rem 0 0;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: rgba(246, 241, 232, 0.55);
}

/* Tables */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--rule);
  background: var(--card);
  margin: 1rem 0 1.5rem;
}
table.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  min-width: 48rem;
}
table.data th, table.data td {
  text-align: start;
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
table.data th {
  background: var(--navy);
  color: var(--ivory);
  font-weight: 600;
  position: sticky;
  top: 0;
  white-space: nowrap;
  letter-spacing: 0.02em;
}
table.data th button {
  appearance: none;
  background: transparent;
  color: inherit;
  border: 0;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}
table.data tbody tr:hover { background: #f3ece0; }
table.data td.num { font-variant-numeric: tabular-nums; text-align: end; white-space: nowrap; unicode-bidi: isolate; direction: ltr; }
table.data th.num { text-align: end; unicode-bidi: isolate; direction: ltr; }
.neg { color: var(--oxblood); }
.muted { color: var(--muted); }
.small { font-size: 0.86rem; }

/* Filters / toolbar */
.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem 1rem;
  align-items: end;
  margin: 1rem 0;
}
.field { display: flex; flex-direction: column; gap: 0.2rem; }
.field label { font-size: 0.74rem; color: var(--muted); letter-spacing: 0.08em; text-transform: uppercase; }
.field input, .field select {
  font: inherit;
  padding: 0.4rem 0.55rem;
  border: 1px solid var(--rule-strong);
  background: var(--card);
  color: var(--ink);
  min-width: 10rem;
}
.btn {
  appearance: none;
  font: inherit;
  font-size: 0.88rem;
  letter-spacing: 0.04em;
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--navy);
  background: var(--navy);
  color: var(--ivory);
  cursor: pointer;
}
.btn.secondary {
  background: transparent;
  color: var(--navy);
}
.btn:hover { background: var(--navy-2); color: #fff; }
.btn.secondary:hover { background: var(--paper-2); color: var(--navy); }

/* Map */
#lab-map {
  height: 32rem;
  width: 100%;
  border: 1px solid var(--rule);
  background: #d5dbd6;
  margin: 0.5rem 0 1rem;
}
.lab-popup h3 { margin: 0 0 0.3rem; font-family: var(--font-serif); font-size: 1rem; }
.lab-popup p { margin: 0.15rem 0; font-size: 0.88rem; }
.lab-popup a { font-size: 0.84rem; }
#lab-count { font-size: 0.9rem; color: var(--muted); }

/* Charts */
.chart-card { background: var(--card); border: 1px solid var(--rule); padding: 1.1rem 1.1rem 0.4rem; }
.chart-card h3 { margin: 0 0 0.4rem; font-family: var(--font-serif); font-size: 1.05rem; }
.chart-wrap { position: relative; height: 22rem; }

/* Network */
#network-canvas, #network-svg {
  width: 100%;
  height: 38rem;
  border: 1px solid var(--rule);
  background: var(--card);
  display: block;
}
.network-layout {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 1rem;
}
#edge-detail {
  background: var(--card);
  border: 1px solid var(--rule);
  padding: 1.1rem;
  min-height: 12rem;
}
#edge-detail h3 { margin: 0 0 0.4rem; font-family: var(--font-serif); }
.source-list { padding-inline-start: 1.1rem; margin: 0.4rem 0 0; }
.source-list li { margin: 0.25rem 0; font-size: 0.88rem; }
.legend { display: flex; flex-wrap: wrap; gap: 0.6rem 1rem; font-size: 0.84rem; color: var(--muted); margin: 0.4rem 0 0.8rem; }
.legend i {
  display: inline-block;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  margin-inline-end: 0.3rem;
  vertical-align: -0.05rem;
}

/* Archive */
.doc {
  background: var(--card);
  border: 1px solid var(--rule);
  padding: 1.35rem 1.45rem;
  margin: 0 0 1.1rem;
}
.doc h2 { font-family: var(--font-serif); font-size: 1.28rem; margin: 0 0 0.35rem; }
.doc .meta { font-size: 0.84rem; color: var(--muted); margin: 0 0 0.7rem; letter-spacing: 0.02em; }
blockquote.excerpt {
  margin: 0.8rem 0;
  padding: 0.7rem 0;
  padding-inline-start: 1rem;
  border-inline-start: 1px solid var(--gold);
  color: var(--ink-soft);
  font-family: var(--font-serif);
  font-size: 1.05rem;
}

/* Footer */
.site-footer {
  background: var(--header);
  color: #e6dfd2;
  padding: 2.2rem 0 2.4rem;
  font-size: 0.88rem;
  border-top: 1px solid rgba(196, 164, 106, 0.28);
}
.site-footer a { color: var(--gold); }
.site-footer .wrap {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1.5rem;
}
.site-footer p { margin: 0 0 0.5rem; }
.site-footer .fine { color: #9e9890; }

/* Utilities */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  border: 0;
}
.chips { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.chip {
  font-size: 0.75rem;
  border: 1px solid var(--rule);
  padding: 0.05rem 0.45rem;
  color: var(--ink-soft);
  background: var(--paper);
}
button.linkish {
  appearance: none; background: none; border: 0; padding: 0;
  font: inherit; color: var(--link); text-decoration: underline;
  text-underline-offset: 0.15em; cursor: pointer; text-align: start;
}
details summary { cursor: pointer; color: var(--link); }
.hero-aside {
  color: var(--ink-soft);
  font-size: 0.95rem;
  padding-top: 0.2rem;
}
.intro-band {
  display: grid;
  grid-template-columns: 1.35fr 0.85fr;
  gap: 2rem;
  align-items: start;
  margin-bottom: 1.25rem;
}

@media (max-width: 900px) {
  .network-layout, .site-footer .wrap,
  .grid-4, .grid-3, .stat-strip, .ed-grid, .intro-band { grid-template-columns: 1fr 1fr; }
  #lab-map, #network-svg { height: 24rem; }
  .photo-hero--home { min-height: 28rem; }
  .ed-tile, .ed-tile__body { min-height: 18rem; }
}
@media (max-width: 680px) {
  .nav-toggle { display: inline-block; }
  .site-nav { display: none; }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; padding: 0.3rem 0 0.8rem; }
  .grid-2, .grid-3, .grid-4, .stat-strip, .network-layout, .site-footer .wrap, .ed-grid, .intro-band {
    grid-template-columns: 1fr;
  }
  .masthead { padding: 0.75rem 1.15rem; }
  .brand-name { font-size: 1.08rem; }
  .photo-hero__inner { padding-top: 3.5rem; padding-bottom: 2.2rem; }
  .photo-hero h1 { max-width: none; }
  .ed-tile, .ed-tile__body { min-height: 16.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
@media print {
  .site-header, .site-footer, .toolbar, .lang-toggle, .lang-menu, .nav-toggle, .photo-hero { display: none !important; }
  body { background: #fff; }
  a { color: inherit; text-decoration: none; }
  #lab-map, .chart-wrap, #network-svg { break-inside: avoid; }
}

.photo-hero__inner .photo-caption {
  position: static;
  padding: 1.35rem 0 0;
  margin: 0;
  max-width: 44rem;
}


/* Language menu */
.lang-menu { position: relative; }
.lang-menu__btn {
  appearance: none;
  background: transparent;
  color: var(--ivory);
  border: 1px solid rgba(246, 241, 232, 0.35);
  padding: 0.28rem 0.7rem;
  font: inherit;
  font-size: 0.78rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 2rem;
  max-width: 11.5rem;
  border-radius: 2px;
  line-height: 1.2;
}
.lang-menu__btn:hover,
.lang-menu.is-open .lang-menu__btn {
  border-color: var(--gold);
  color: var(--ivory);
}
.lang-menu__current {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lang-menu__chevron {
  width: 0;
  height: 0;
  border-inline-start: 0.28rem solid transparent;
  border-inline-end: 0.28rem solid transparent;
  border-top: 0.32rem solid rgba(246, 241, 232, 0.75);
  flex-shrink: 0;
}
.lang-menu__list {
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + 0.35rem);
  min-width: 12.5rem;
  margin: 0;
  padding: 0.3rem 0;
  list-style: none;
  background: #141a20;
  border: 1px solid rgba(196, 164, 106, 0.35);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  z-index: 80;
}
.lang-menu__list[hidden] { display: none; }
.lang-menu__list button {
  appearance: none;
  width: 100%;
  text-align: start;
  background: transparent;
  border: 0;
  color: rgba(246, 241, 232, 0.88);
  font: inherit;
  font-size: 0.88rem;
  padding: 0.42rem 0.9rem;
  cursor: pointer;
}
.lang-menu__list button:hover {
  background: rgba(196, 164, 106, 0.16);
  color: var(--ivory);
}
.lang-menu__list button[aria-selected="true"] {
  color: var(--ivory);
  box-shadow: inset 2px 0 0 var(--gold);
}
html[dir="rtl"] .lang-menu__list button[aria-selected="true"] {
  box-shadow: inset -2px 0 0 var(--gold);
}

/* Script-specific stacks (base fonts remain in the document head) */
html[lang="zh-Hant"] {
  --font-serif: "Noto Serif TC", "Source Serif 4", "Songti TC", "PMingLiU", serif;
  --font-sans: "Noto Sans TC", "Source Sans 3", "PingFang TC", "Microsoft JhengHei", sans-serif;
}
html[lang="ja"] {
  --font-serif: "Noto Serif JP", "Source Serif 4", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --font-sans: "Noto Sans JP", "Source Sans 3", "Hiragino Sans", "Yu Gothic", "Meiryo", sans-serif;
}
html[lang="ko"] {
  --font-serif: "Noto Serif KR", "Source Serif 4", "Apple SD Gothic Neo", serif;
  --font-sans: "Noto Sans KR", "Source Sans 3", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
}
html[lang="ar"] {
  --font-serif: "Noto Naskh Arabic", "Noto Sans Arabic", "Source Serif 4", serif;
  --font-sans: "Noto Sans Arabic", "Source Sans 3", "Segoe UI", "Tahoma", sans-serif;
}
html[lang="ru"] {
  --font-serif: "Source Serif 4", "PT Serif", "Noto Serif", serif;
  --font-sans: "Source Sans 3", "PT Sans", "Noto Sans", sans-serif;
}

/* Tracking and uppercase kickers do not suit Arabic or CJK as well as Latin */
html[lang="ar"] .kicker,
html[lang="ar"] .page-kicker,
html[lang="ar"] .section-kicker,
html[lang="ar"] .field label,
html[lang="ar"] .ed-tile .more,
html[lang^="zh"] .kicker,
html[lang^="zh"] .page-kicker,
html[lang^="zh"] .section-kicker,
html[lang^="zh"] .field label,
html[lang^="zh"] .ed-tile .more,
html[lang="ja"] .kicker,
html[lang="ja"] .page-kicker,
html[lang="ja"] .section-kicker,
html[lang="ja"] .field label,
html[lang="ja"] .ed-tile .more,
html[lang="ko"] .kicker,
html[lang="ko"] .page-kicker,
html[lang="ko"] .section-kicker,
html[lang="ko"] .field label,
html[lang="ko"] .ed-tile .more {
  letter-spacing: 0.06em;
  text-transform: none;
}
html[lang="ar"] {
  letter-spacing: 0;
}
html[lang="ar"] .photo-hero h1,
html[lang="ar"] .page-title,
html[lang="ar"] .ed-tile h2,
html[lang="ar"] .doc h2 {
  line-height: 1.35;
}
html[lang="ar"] .brand-tag,
html[lang="ar"] .photo-caption {
  letter-spacing: 0;
}

/* Mirror the cinematic side-shade so Arabic hero type still sits in the darker area */
html[dir="rtl"] .photo-hero__shade {
  background:
    linear-gradient(180deg, rgba(8, 11, 14, 0.28) 0%, rgba(8, 11, 14, 0.22) 35%, rgba(8, 11, 14, 0.72) 78%, rgba(8, 11, 14, 0.9) 100%),
    linear-gradient(270deg, rgba(8, 11, 14, 0.45) 0%, rgba(8, 11, 14, 0.12) 55%, rgba(8, 11, 14, 0.2) 100%);
}

/* Leaflet popups inherit page direction; keep map tiles LTR */
#lab-map { direction: ltr; }
#lab-map .lab-popup { direction: inherit; }
html[dir="rtl"] #lab-map .lab-popup { direction: rtl; text-align: start; }

/* Network graph labels stay visually near nodes; numbers stay LTR */
.num, .stat b {
  font-variant-numeric: tabular-nums;
  unicode-bidi: isolate;
}

@media print {
  .lang-menu { display: none !important; }
}
