/*
Theme Name: Alueposti Wire
Theme URI: https://alueposti.fi/
Author: Alueposti
Description: Alueposti - itsenainen suomalainen julkaisu. Aluearki-ilme: lampimä paperivari, serif-masthead, tiivis uutiswire, arkipalvelujen palvelurivit. Rehelliset signaalit, ei reaktio- tai lukijalaskureita.
Version: 1.0.0
Requires at least: 6.2
Requires PHP: 7.4
Tested up to: 6.6
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: alueposti-wire
Tags: news, editorial, custom-logo, accessibility-ready, translation-ready
*/

/* ==========================================================================
   1. Design tokens - Aluearki
   ========================================================================== */
:root {
  --ink: #0D1512;
  --paper: #FCFBF7;
  --surface: #F1F0E8;
  --line: #D8DCD2;
  --muted: #5B6459;
  --brand: #1F6B4A;
  --signal: #8FAF3E;
  --alert: #C0452F;

  --topic-tiedot: #1F6B4A;
  --topic-raha: #2F6E52;
  --topic-arki: #4C7A3A;
  --topic-digi: #27675C;
  --topic-matkailu: #5C7A33;

  --display: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  --shell: 1200px;
  --gutter: 22px;
  --measure: 720px;
  --breakout: 940px;

  --radius: 4px;
  --radius-sm: 2px;
  --line-hair: 1px;

  --t-fast: 120ms;
  --t-base: 160ms;
  --t-slow: 180ms;
  --ease: cubic-bezier(.2, .6, .2, 1);
}

/* ==========================================================================
   2. Local webfont (article prose)
   ========================================================================== */
@font-face {
  font-family: "Source Serif 4";
  src: url("assets/fonts/source-serif-4-latin.woff2") format("woff2-variations"),
       url("assets/fonts/source-serif-4-latin.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ==========================================================================
   3. Base and reset
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body.ap-site {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img, svg, video, iframe { max-width: 100%; height: auto; }
img { border: 0; }
figure { margin: 0; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 0 0 .5em;
  text-wrap: balance;
}

h1 { font-size: clamp(31px, 4.2vw, 43px); line-height: 1.12; }
h2 { font-size: clamp(23px, 2.5vw, 30px); line-height: 1.18; }
h3 { font-size: 23px; line-height: 1.22; }
h4 { font-size: 19px; line-height: 1.32; }

p { margin: 0 0 1em; }

a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }

time { font-variant-numeric: tabular-nums; }
hr { border: 0; border-top: var(--line-hair) solid var(--line); margin: 30px 0; }
::selection { background: var(--brand); color: #fff; }

:focus-visible,
a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  z-index: 200;
  padding: 12px 18px;
  background: var(--ink);
  color: var(--paper);
  font: 700 14px/1.3 var(--sans);
  text-decoration: none;
  border-radius: 0 0 var(--radius) var(--radius);
}
.skip-link:focus { left: 12px; }

.shell {
  width: 100%;
  max-width: calc(var(--shell) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ==========================================================================
   4. Header
   ========================================================================== */
.ap-header {
  background: var(--paper);
  border-bottom: var(--line-hair) solid var(--line);
}

.header-top {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  padding-top: 18px;
  padding-bottom: 14px;
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 0;
  text-decoration: none;
  color: var(--ink);
  min-height: 44px;
}
.brand-word {
  display: inline-flex;
  align-items: baseline;
  font-size: 31px;
  line-height: 1;
  letter-spacing: -0.03em;
}
.brand-word .w-1 { font-family: var(--display); font-weight: 700; color: var(--ink); }
.brand-word .w-2 { font-family: var(--sans); font-weight: 600; color: var(--ink); }
.brand-word .w-sep {
  display: inline-block;
  width: 2px;
  height: 26px;
  margin: 0 6px;
  background: var(--brand);
  transform: translateY(4px);
}
.brand--footer .brand-word .w-1,
.brand--footer .brand-word .w-2 { color: var(--paper); }

.header-tagline {
  margin: 0;
  font: 600 12.5px/1.35 var(--sans);
  letter-spacing: .02em;
  color: var(--muted);
  padding-left: 14px;
  border-left: var(--line-hair) solid var(--line);
}
.header-search { margin-left: auto; min-width: 220px; flex: 1 1 220px; max-width: 340px; }
.header-tools { display: flex; align-items: center; gap: 10px; }

.menu-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 9px 14px;
  background: var(--paper);
  border: var(--line-hair) solid var(--line);
  border-radius: var(--radius);
  font: 700 14px/1.3 var(--sans);
  color: var(--ink);
  cursor: pointer;
}
.menu-toggle:hover { border-color: var(--brand); color: var(--brand); }
.menu-lines { position: relative; width: 16px; height: 2px; background: currentColor; }
.menu-lines::before,
.menu-lines::after { content: ""; position: absolute; left: 0; width: 16px; height: 2px; background: currentColor; }
.menu-lines::before { top: -5px; }
.menu-lines::after { top: 5px; }

.ap-nav { border-top: var(--line-hair) solid var(--line); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.nav-topics { display: flex; flex-wrap: wrap; align-items: stretch; gap: 0; }
.nav-topics a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 14px;
  font: 700 14px/1.3 var(--sans);
  color: var(--ink);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.nav-topics a:first-child { padding-left: 0; }
.nav-topics a:hover { color: var(--brand); }
.nav-topics a[aria-current="page"] { color: var(--brand); border-bottom-color: var(--brand); }

.header-author {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-end;
  min-height: 44px;
  justify-content: center;
  text-decoration: none;
  color: var(--ink);
}
.header-author span { font: 700 14px/1.2 var(--sans); }
.header-author small { font: 600 11.5px/1.4 var(--sans); color: var(--muted); }
.header-author:hover span { color: var(--brand); }

.menu-panel { background: var(--surface); border-bottom: var(--line-hair) solid var(--line); }
.menu-panel .shell { padding-top: 20px; padding-bottom: 24px; }
.menu-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.menu-top h2 { font-size: 19px; margin: 0; }
.menu-close {
  min-height: 44px;
  padding: 9px 16px;
  background: var(--paper);
  border: var(--line-hair) solid var(--line);
  border-radius: var(--radius);
  font: 700 14px/1.3 var(--sans);
  cursor: pointer;
}
.menu-close:hover { border-color: var(--brand); color: var(--brand); }
.menu-topics { display: grid; gap: 0; margin: 16px 0; border-top: var(--line-hair) solid var(--line); }
.menu-topics a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 48px;
  padding: 10px 2px;
  border-bottom: var(--line-hair) solid var(--line);
  font: 700 16px/1.3 var(--display);
  color: var(--ink);
  text-decoration: none;
}
.menu-topics a:hover { color: var(--brand); }
.menu-topics span { font: 400 13px/1.4 var(--sans); color: var(--muted); }
.menu-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.menu-links a { min-height: 44px; display: inline-flex; align-items: center; font: 600 14px/1.4 var(--sans); color: var(--ink); text-decoration: none; }
.menu-links a:hover { color: var(--brand); text-decoration: underline; }

/* ==========================================================================
   5. Search form
   ========================================================================== */
.search-form label {
  display: block;
  font: 700 11.5px/1.5 var(--sans);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 5px;
}
.search-row { display: flex; gap: 8px; }
.search-row input[type="search"] {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 44px;
  padding: 9px 13px;
  border: var(--line-hair) solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
  font: 400 15px/1.4 var(--sans);
}
.search-row input[type="search"]::placeholder { color: #7A8278; }
.search-row button {
  flex: none;
  min-height: 44px;
  padding: 9px 18px;
  border: var(--line-hair) solid var(--brand);
  border-radius: var(--radius);
  background: var(--brand);
  color: #fff;
  font: 700 14px/1.3 var(--sans);
  cursor: pointer;
  transition: background var(--t-fast) var(--ease);
}
.search-row button:hover { background: #17553A; }

/* ==========================================================================
   6. Shared editorial primitives
   ========================================================================== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: 700 11.5px/1.5 var(--sans);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.signal-rule { display: inline-block; width: 20px; height: 3px; background: var(--signal); }

.signal-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  padding: 11px 0;
  border-bottom: var(--line-hair) solid var(--line);
  font: 600 13px/1.5 var(--sans);
  color: var(--muted);
}
.signal-row .signal-date { font-weight: 700; color: var(--ink); }
.signal-row a { margin-left: auto; color: var(--brand); text-decoration: none; }
.signal-row a:hover { text-decoration: underline; }
.signal-sep { color: var(--line); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 18px;
  padding: 0 0 14px;
  margin-bottom: 22px;
  border-bottom: 2px solid var(--ink);
}
.section-head h2 { margin: 0; }
.section-head p { margin: 0; font: 400 14px/1.5 var(--sans); color: var(--muted); }
.section-more {
  margin-left: auto;
  font: 700 13.5px/1.4 var(--sans);
  color: var(--brand);
  text-decoration: none;
  white-space: nowrap;
}
.section-more:hover { text-decoration: underline; }

.home-main { padding-bottom: 40px; }
.home-block { margin: 40px 0; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 20px;
  background: var(--brand);
  color: #fff;
  border: var(--line-hair) solid var(--brand);
  border-radius: var(--radius);
  font: 700 14.5px/1.3 var(--sans);
  text-decoration: none;
  transition: background var(--t-base) var(--ease);
}
.button:hover { background: #17553A; color: #fff; }
.button--ghost { background: transparent; color: var(--paper); border-color: #4A5A4E; }
.button--ghost:hover { background: rgba(255,255,255,.08); color: #fff; }
.text-link { font: 700 13.5px/1.4 var(--sans); color: var(--brand); text-decoration: none; }
.text-link:hover { text-decoration: underline; }

/* ==========================================================================
   7. Homepage: lead desk and wire rail
   ========================================================================== */
.hero-desk {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 1fr);
  gap: 34px;
  align-items: start;
  padding: 26px 0 8px;
}
.hero-lead .story--lead h1 { font-size: clamp(31px, 4vw, 42px); }
.hero-rail { border-top: 3px solid var(--ink); padding-top: 12px; min-width: 0; }
.hero-rail-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: var(--line-hair) solid var(--line);
}
.hero-rail-head strong { font: 700 15px/1.3 var(--display); }
.hero-rail-head span { font: 600 12px/1.4 var(--sans); color: var(--muted); }

.wire-list { list-style: none; margin: 0; padding: 0; }
.wire-list li { border-bottom: var(--line-hair) solid var(--line); }
.wire-list li:last-child { border-bottom: 0; }
.wire-list a {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
  min-height: 44px;
  padding: 10px 0;
  text-decoration: none;
  color: var(--ink);
}
.wire-list a:hover .wire-title { color: var(--brand); text-decoration: underline; }
.wire-list time { font: 700 12.5px/1.5 var(--sans); color: var(--signal); }
.wire-title { font: 600 15px/1.42 var(--sans); }

/* ==========================================================================
   8. Homepage: follow-up grid, service strip, modules
   ========================================================================== */
.follow-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 24px; }
.now-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 22px; }
.now-cell { min-width: 0; }

.service-strip { margin: 40px 0; }
.service-list { list-style: none; margin: 0; padding: 0; border-top: var(--line-hair) solid var(--line); }
.service-row { border-bottom: var(--line-hair) solid var(--line); }
.service-row a {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) 24px;
  gap: 16px;
  align-items: center;
  min-height: 58px;
  padding: 10px 0;
  text-decoration: none;
  color: var(--ink);
}
.service-row a:hover strong { color: var(--brand); }
.service-stamp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 3px 8px;
  background: var(--signal);
  color: var(--ink);
  font: 700 12.5px/1.2 var(--sans);
  border-radius: var(--radius-sm);
}
.service-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.service-body strong { font: 700 16px/1.35 var(--display); }
.service-note { font: 600 12.5px/1.4 var(--sans); color: var(--muted); }
.service-arrow { color: var(--brand); font-weight: 700; text-align: right; }

.topic-module .module-split {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(260px, 1fr);
  gap: 28px;
  align-items: start;
}
.module-stack { display: grid; gap: 0; }
.module-ledger { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 22px; }

.topic-nav-block { margin: 46px 0; padding: 26px 0; border-top: 3px solid var(--ink); border-bottom: var(--line-hair) solid var(--line); }
.topic-nav-head { margin-bottom: 20px; }
.topic-nav-head h2 { margin: 0 0 6px; }
.topic-nav-head p { margin: 0; font: 400 14.5px/1.6 var(--sans); color: var(--muted); max-width: 60ch; }
.topic-nav-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 0 26px; }
.topic-nav-grid a {
  display: grid;
  gap: 4px;
  padding: 14px 0;
  border-top: var(--line-hair) solid var(--line);
  text-decoration: none;
  color: var(--ink);
}
.topic-nav-grid a:hover strong { color: var(--brand); }
.topic-nav-grid strong { font: 700 17px/1.3 var(--display); }
.topic-nav-grid strong::before { content: ""; display: inline-block; width: 12px; height: 3px; margin-right: 9px; background: var(--cat, var(--brand)); vertical-align: middle; }
.topic-nav-grid span { font: 400 13px/1.5 var(--sans); color: var(--muted); }
.topic-nav-grid em { font: 700 12px/1.4 var(--sans); font-style: normal; color: var(--brand); }

/* ==========================================================================
   9. Homepage: editor strip and continuation
   ========================================================================== */
.editor-band {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr) auto;
  gap: 26px;
  align-items: center;
  margin: 46px 0;
  padding: 24px 26px;
  background: var(--surface);
  border: var(--line-hair) solid var(--line);
  border-left: 4px solid var(--brand);
  border-radius: var(--radius);
}
.editor-photo img { display: block; width: 132px; height: 132px; object-fit: cover; border-radius: var(--radius); border: var(--line-hair) solid var(--line); }
.editor-band h2 { margin: 2px 0 2px; font-size: 24px; }
.editor-role { margin: 0 0 8px; font: 700 13px/1.4 var(--sans); color: var(--brand); }
.editor-band p { font-size: 15px; line-height: 1.6; }
.editor-facts { display: flex; flex-wrap: wrap; gap: 4px 26px; margin: 12px 0 0; }
.editor-facts dt { font: 700 11px/1.5 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.editor-facts dd { margin: 2px 0 0; font-size: 13.5px; line-height: 1.55; }
.editor-actions { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }

.continuation { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 22px; }

.load-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  margin-top: 26px;
  padding-top: 18px;
  border-top: var(--line-hair) solid var(--line);
}
.load-row p { margin: 0; font: 600 13.5px/1.5 var(--sans); color: var(--muted); }
.load-more {
  min-height: 46px;
  padding: 11px 24px;
  background: var(--ink);
  color: var(--paper);
  border: var(--line-hair) solid var(--ink);
  border-radius: var(--radius);
  font: 700 14.5px/1.3 var(--sans);
  cursor: pointer;
  transition: background var(--t-base) var(--ease);
}
.load-more:hover { background: var(--brand); border-color: var(--brand); }
.load-more:disabled { opacity: .6; cursor: default; }
.archive-fallback { font: 700 13.5px/1.4 var(--sans); color: var(--brand); text-decoration: none; }
.archive-fallback:hover { text-decoration: underline; }
.load-status { flex: 1 1 100%; font-size: 13px; }

/* ==========================================================================
   10. Archive, single and page chrome
   ========================================================================== */
.archive-main, .single-main, .page-main, .not-found { padding-top: 30px; padding-bottom: 46px; }
.archive-heading { margin-bottom: 26px; padding-bottom: 20px; border-bottom: 3px solid var(--ink); }
.archive-heading h1 { margin: 2px 0 10px; }
.archive-description p { margin: 0 0 6px; color: var(--muted); font-size: 14.5px; }
.archive-grid, .three-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 26px; }
.pagination { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 34px; }
.pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 8px 12px;
  border: var(--line-hair) solid var(--line);
  border-radius: var(--radius);
  font: 700 14px/1.3 var(--sans);
  color: var(--ink);
  text-decoration: none;
}
.pagination .page-numbers.current { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.pagination a.page-numbers:hover { border-color: var(--brand); color: var(--brand); }
.empty { padding: 30px 0; }

.profile-top { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; align-items: start; margin-bottom: 30px; }
.compact-profile { margin: 6px 0 26px; padding-bottom: 26px; border-bottom: 3px solid var(--ink); }
.profile-photo img { display: block; width: 100%; max-width: 220px; height: auto; border: var(--line-hair) solid var(--line); border-top: 3px solid var(--brand); border-radius: var(--radius); }
.profile-photo figcaption { margin-top: 9px; font: 600 12.5px/1.5 var(--sans); color: var(--muted); }
.profile-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 16px; }
.standfirst { font-family: var(--serif); font-size: 19px; line-height: 1.62; color: #28312A; }
.topic-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.topic-links a { font: 600 14px/1.4 var(--sans); color: var(--brand); }

.breadcrumbs { display: flex; flex-wrap: wrap; gap: 6px; font: 600 13px/1.5 var(--sans); color: var(--muted); margin-bottom: 18px; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--brand); text-decoration: underline; }

.page-heading { margin-bottom: 24px; padding-bottom: 18px; border-bottom: 3px solid var(--ink); }
.page-heading h1 { margin: 2px 0 0; }
.page-content { max-width: var(--measure); }
.team-member {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  padding: 22px 0;
  border-top: var(--line-hair) solid var(--line);
}
.team-member:first-of-type { border-top: 0; }
.team-photo img { display: block; width: 132px; height: 132px; object-fit: cover; border-radius: var(--radius); border: var(--line-hair) solid var(--line); border-top: 3px solid var(--brand); }
.team-member h2 { margin: 0 0 3px; font-size: 22px; }
.team-role { margin: 0 0 10px; font: 700 13px/1.4 var(--sans); color: var(--brand); }
.team-meta { font-size: 13.5px; color: var(--muted); margin: 6px 0 0; }

/* ==========================================================================
   11. Footer
   ========================================================================== */
.ap-footer { background: var(--ink); color: #C8D0C7; margin-top: 40px; }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 34px;
  padding: 44px 0 30px;
}
.footer-brand p { margin: 14px 0 12px; font-size: 13.5px; line-height: 1.65; color: #A9B3A9; max-width: 34ch; }
.footer-contact { display: inline-flex; align-items: center; min-height: 44px; font: 700 13.5px/1.4 var(--sans); color: var(--paper); text-decoration: none; }
.footer-contact:hover { color: var(--signal); }
.footer-badge { display: inline-flex; align-items: center; gap: 8px; margin-top: 6px; font: 700 11.5px/1.5 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: #8C978C; }
.ap-footer h2 { font-family: var(--sans); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: #8C978C; margin: 0 0 12px; }
.footer-list, .footer-headlines { display: grid; }
.footer-list a, .footer-headlines a {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-height: 44px;
  justify-content: center;
  padding: 6px 0;
  font: 600 14px/1.45 var(--sans);
  color: #D3DAD2;
  text-decoration: none;
  border-bottom: 1px solid #1E2A23;
}
.footer-list a:last-child, .footer-headlines a:last-child { border-bottom: 0; }
.footer-list a:hover, .footer-headlines a:hover { color: #fff; text-decoration: underline; }
.footer-headlines time { font: 600 11.5px/1.4 var(--sans); color: #8C978C; }
.footer-tip { margin-top: 16px; }
.footer-tip p { font-size: 13.5px; line-height: 1.55; color: #A9B3A9; margin: 0 0 10px; }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 22px;
  padding: 18px 0 26px;
  border-top: 1px solid #1E2A23;
  font: 600 12.5px/1.5 var(--sans);
  color: #8C978C;
}
.footer-bottom nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.footer-bottom a { display: inline-flex; align-items: center; min-height: 44px; color: #A9B3A9; text-decoration: none; }
.footer-bottom a:hover { color: #fff; text-decoration: underline; }

/* ==========================================================================
   12. Responsive
   ========================================================================== */
@media (max-width: 1040px) {
  .hero-desk { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .topic-module .module-split { grid-template-columns: minmax(0, 1fr); }
  .editor-band { grid-template-columns: 116px minmax(0, 1fr); }
  .editor-photo img { width: 116px; height: 116px; }
  .editor-actions { grid-column: 1 / -1; flex-direction: row; }
}

@media (max-width: 900px) {
  .menu-toggle { display: inline-flex; }
  .ap-nav .nav-topics { display: none; }
  .header-search { display: none; }
  .header-author { margin-left: auto; }
  .profile-top { grid-template-columns: minmax(0, 1fr); }
  .profile-photo img { max-width: 180px; }
}

@media (max-width: 720px) {
  .signal-row { font-size: 12.5px; }
  .signal-row a { margin-left: 0; }
  .editor-band { grid-template-columns: minmax(0, 1fr); padding: 20px; }
  .editor-photo img { width: 96px; height: 96px; }
  .team-member { grid-template-columns: 96px minmax(0, 1fr); gap: 16px; }
  .team-photo img { width: 96px; height: 96px; }
  .service-row a { grid-template-columns: 70px minmax(0, 1fr) 20px; gap: 12px; }
}

@media (max-width: 560px) {
  :root { --gutter: 16px; }
  .header-top { padding-top: 14px; }
  .brand-word { font-size: 26px; }
  .brand-word .w-sep { height: 22px; }
  .header-tagline { display: none; }
  .follow-grid, .now-grid, .module-ledger, .continuation, .archive-grid, .three-grid { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { padding-top: 32px; gap: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
