/* ==========================================================================
   BizOnline Daily — Design System
   A modern editorial layout: warm off-white canvas, serif display type,
   crimson accent, generous whitespace. Mobile-first, built for H5.
   ========================================================================== */

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

button { font: inherit; color: inherit; }

h1, h2, h3, h4, h5 { margin: 0; font-family: var(--font-display); font-weight: 600; letter-spacing: -0.015em; line-height: 1.15; }

p { margin: 0; }

ul, ol { margin: 0; padding: 0; }

/* ----------------------------------------------------------------- tokens */
:root {
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-ui: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --bg: #ffffff;
  --bg-subtle: #f7f5f2;
  --bg-elev: #ffffff;
  --ink: #121215;
  --ink-soft: #3d3d44;
  --muted: #6d6d76;
  --line: #e7e4de;
  --line-strong: #d5d1c9;

  --accent: #d62828;
  --accent-ink: #b41f1f;
  --accent-soft: #fdeceb;

  --radius-s: 8px;
  --radius-m: 14px;
  --radius-l: 22px;

  --shadow-s: 0 1px 2px rgba(18, 18, 21, .05), 0 2px 8px rgba(18, 18, 21, .04);
  --shadow-m: 0 4px 12px rgba(18, 18, 21, .07), 0 16px 40px rgba(18, 18, 21, .07);
  --shadow-l: 0 12px 32px rgba(18, 18, 21, .10), 0 40px 80px rgba(18, 18, 21, .10);

  --maxw: 1240px;
  --gap: 28px;
  --header-h: 62px;
}

[data-theme="dark"] {
  --bg: #0d0d10;
  --bg-subtle: #141418;
  --bg-elev: #17171c;
  --ink: #f4f3f0;
  --ink-soft: #c9c8c4;
  --muted: #92929b;
  --line: #26262d;
  --line-strong: #34343d;
  --accent: #ff5252;
  --accent-ink: #ff6b6b;
  --accent-soft: #2a1618;
  --shadow-s: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow-m: 0 8px 28px rgba(0, 0, 0, .5);
  --shadow-l: 0 24px 60px rgba(0, 0, 0, .6);
}

/* -------------------------------------------------------------- utilities */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

.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-link {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--accent); color: #fff; padding: 10px 18px; border-radius: 0 0 var(--radius-s) 0;
}
.skip-link:focus { left: 0; }

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

/* ----------------------------------------------------------------- header */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.header-utility {
  border-bottom: 1px solid var(--line);
  font-size: 12px; color: var(--muted);
  letter-spacing: .04em;
}
.header-utility .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 34px; gap: 16px;
}
.header-utility .u-left { display: flex; gap: 16px; align-items: center; white-space: nowrap; overflow: hidden; }
.header-utility .u-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); display: inline-block; animation: pulse 2.4s infinite; }
@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: .35 } }

.header-main { display: flex; align-items: center; gap: 18px; height: var(--header-h); }

.brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px; flex-shrink: 0;
  background: linear-gradient(150deg, var(--accent), #8e1717);
  color: #fff; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 18px;
  box-shadow: 0 4px 14px rgba(214, 40, 40, .28);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font-family: var(--font-display); font-weight: 700; font-size: 21px; letter-spacing: -0.02em; }
.brand-sub { font-size: 9.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); font-weight: 600; }

.header-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }

.icon-btn {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid transparent;
  background: transparent; display: grid; place-items: center; cursor: pointer;
  color: var(--ink-soft); transition: background .18s ease, color .18s ease, border-color .18s ease;
}
.icon-btn:hover { background: var(--bg-subtle); color: var(--ink); border-color: var(--line); }
.icon-btn svg { width: 19px; height: 19px; }

.menu-toggle { display: none; }

/* -------------------------------------------------------------------- nav */
.site-nav { border-top: 1px solid var(--line); }
.nav-scroll {
  display: flex; align-items: center; gap: 4px;
  overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none;
  height: 46px;
}
.nav-scroll::-webkit-scrollbar { display: none; }

.nav-link {
  position: relative; flex-shrink: 0;
  padding: 8px 13px; border-radius: 999px;
  font-size: 13.5px; font-weight: 600; letter-spacing: .01em;
  color: var(--ink-soft); white-space: nowrap;
  transition: color .16s ease, background .16s ease;
}
.nav-link:hover { color: var(--ink); background: var(--bg-subtle); }
.nav-link.active { color: #fff; background: var(--ink); }
[data-theme="dark"] .nav-link.active { background: var(--accent); }

/* ----------------------------------------------------------------- ticker */
.ticker {
  display: flex; align-items: center; gap: 14px;
  background: var(--bg-subtle); border-bottom: 1px solid var(--line);
  height: 40px; overflow: hidden;
}
.ticker-label {
  flex-shrink: 0; display: inline-flex; align-items: center; gap: 7px;
  background: var(--accent); color: #fff; font-size: 11px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  padding: 5px 12px; border-radius: 999px;
}
.ticker-viewport { flex: 1; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.ticker-track { display: flex; gap: 40px; width: max-content; animation: ticker 42s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes ticker { from { transform: translateX(0) } to { transform: translateX(-50%) } }
.ticker-item { font-size: 13px; color: var(--ink-soft); white-space: nowrap; display: inline-flex; align-items: center; gap: 9px; }
.ticker-item::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--accent); }

/* ------------------------------------------------------------------ hero */
main { display: block; padding-bottom: 10px; }

.section { padding: 46px 0; }
.section-tight { padding: 32px 0; }

.section-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 20px; margin-bottom: 26px;
}
.section-head h2 { font-size: clamp(24px, 3vw, 34px); }
.section-head .eyebrow {
  font-size: 11px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 7px; display: block;
}
.section-head p { color: var(--muted); font-size: 14.5px; margin-top: 8px; max-width: 60ch; }
.section-more { font-size: 13.5px; font-weight: 600; color: var(--accent); white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.section-more:hover { color: var(--accent-ink); }

.hero { padding: 34px 0 10px; }
.hero-grid { display: grid; grid-template-columns: 1.55fr 1fr; gap: var(--gap); }

/* ------------------------------------------------------------------ cards */
.card { position: relative; display: flex; flex-direction: column; background: var(--bg-elev); }

.card-media {
  position: relative; overflow: hidden; border-radius: var(--radius-m);
  background: var(--bg-subtle); aspect-ratio: 16 / 9;
}
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .55s cubic-bezier(.2,.7,.3,1); }
.card:hover .card-media img { transform: scale(1.045); }

.card-cat {
  position: absolute; left: 12px; top: 12px; z-index: 2;
  font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: #fff; background: rgba(18, 18, 21, .72);
  backdrop-filter: blur(8px); padding: 5px 10px; border-radius: 999px;
}

.card-body { padding: 16px 2px 0; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.card-title { font-size: 19px; line-height: 1.24; }
.card-title a { transition: color .16s ease; }
.card-title a:hover { color: var(--accent); }
.card-excerpt { color: var(--ink-soft); font-size: 14.5px; line-height: 1.6; }

.card-meta {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 12.5px; color: var(--muted); margin-top: auto; padding-top: 4px;
}
.card-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--line-strong); }

/* hero feature */
.feature { position: relative; border-radius: var(--radius-l); overflow: hidden; min-height: 440px; display: flex; align-items: flex-end; background: #101014; }
.feature img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .7s cubic-bezier(.2,.7,.3,1); }
.feature:hover img { transform: scale(1.04); }
.feature::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(8,8,10,.92) 4%, rgba(8,8,10,.55) 42%, rgba(8,8,10,.05) 78%);
}
.feature-inner { position: relative; z-index: 2; padding: 34px 32px 32px; color: #fff; }
.feature-inner .card-cat { position: static; display: inline-block; margin-bottom: 14px; background: var(--cat, var(--accent)); }
.feature-title { font-size: clamp(26px, 3.4vw, 42px); line-height: 1.1; margin-bottom: 12px; }
.feature-title a:hover { color: #ffd9d9; }
.feature-excerpt { color: rgba(255,255,255,.82); font-size: 15.5px; max-width: 62ch; margin-bottom: 16px; }
.feature .card-meta { color: rgba(255,255,255,.72); margin: 0; padding: 0; }
.feature .card-meta .dot { background: rgba(255,255,255,.4); }

.hero-side { display: grid; grid-template-rows: 1fr 1fr; gap: var(--gap); }
.hero-side .card { flex-direction: row; gap: 16px; }
.hero-side .card-media { width: 42%; flex-shrink: 0; aspect-ratio: 4 / 3; }
.hero-side .card-body { padding: 2px 0 0; }
.hero-side .card-title { font-size: 17.5px; }
.hero-side .card-excerpt { display: none; }

/* ------------------------------------------------------------------- grid */
.grid { display: grid; gap: 34px 28px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* category strip */
.cat-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cat-tile {
  position: relative; border-radius: var(--radius-m); padding: 20px;
  background: var(--bg-subtle); border: 1px solid var(--line); overflow: hidden;
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.cat-tile::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
  background: var(--cat, var(--accent));
}
.cat-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-m); border-color: var(--line-strong); }
.cat-tile h3 { font-size: 17px; margin-bottom: 5px; }
.cat-tile p { font-size: 13px; color: var(--muted); line-height: 1.5; }
.cat-tile .count { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--cat); margin-bottom: 10px; display: block; }

/* filters */
.chip-row { display: flex; gap: 9px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.chip-row::-webkit-scrollbar { display: none; }
.chip {
  flex-shrink: 0; cursor: pointer; border: 1px solid var(--line-strong);
  background: var(--bg); color: var(--ink-soft);
  padding: 8px 16px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
  transition: all .16s ease;
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* list rows */
.row-item { display: flex; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.row-item:first-child { border-top: 1px solid var(--line); }
.row-index { font-family: var(--font-display); font-size: 26px; font-weight: 700; color: var(--line-strong); line-height: 1; width: 40px; flex-shrink: 0; }
.row-body { display: flex; flex-direction: column; gap: 6px; }
.row-title { font-family: var(--font-display); font-size: 17px; font-weight: 600; line-height: 1.3; }
.row-title:hover { color: var(--accent); }

/* -------------------------------------------------------------- newsletter */
.newsletter {
  position: relative; overflow: hidden;
  background: linear-gradient(140deg, #1a1a20, #101014 60%);
  border-radius: var(--radius-l); padding: 48px 42px; color: #fff;
}
[data-theme="dark"] .newsletter { background: linear-gradient(140deg, #1f1f27, #141418 60%); border: 1px solid var(--line); }
.newsletter::before {
  content: ""; position: absolute; right: -80px; top: -80px; width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(214,40,40,.5), transparent 68%);
}
.newsletter-inner { position: relative; z-index: 2; max-width: 560px; }
.newsletter h2 { font-size: clamp(24px, 3vw, 34px); margin-bottom: 12px; }
.newsletter p { color: rgba(255,255,255,.75); font-size: 15px; margin-bottom: 22px; }
.newsletter-form { display: flex; gap: 10px; flex-wrap: wrap; }
.newsletter-form input {
  flex: 1; min-width: 220px; height: 48px; border-radius: 999px; border: 1px solid rgba(255,255,255,.2);
  background: rgba(255,255,255,.08); color: #fff; padding: 0 20px; font-size: 15px;
}
.newsletter-form input::placeholder { color: rgba(255,255,255,.5); }
.newsletter-form input:focus { outline: none; border-color: var(--accent); background: rgba(255,255,255,.12); }
.newsletter-note { font-size: 12.5px; color: rgba(255,255,255,.5); margin-top: 12px; }

/* ----------------------------------------------------------------- button */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 26px; border-radius: 999px; border: 0; cursor: pointer;
  font-size: 14.5px; font-weight: 600; letter-spacing: .01em;
  background: var(--accent); color: #fff; transition: background .18s ease, transform .12s ease;
}
.btn:hover { background: var(--accent-ink); }
.btn:active { transform: scale(.98); }
.btn-ghost { background: transparent; border: 1px solid var(--line-strong); color: var(--ink); }
.btn-ghost:hover { background: var(--bg-subtle); border-color: var(--ink); }
.btn-block { width: 100%; }

/* ------------------------------------------------------------------- load */
.load-more-wrap { display: flex; justify-content: center; margin-top: 42px; }

/* ----------------------------------------------------------------- footer */
.site-footer { margin-top: 60px; background: var(--bg-subtle); border-top: 1px solid var(--line); padding: 56px 0 0; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 38px; }
.footer-brand .brand { margin-bottom: 16px; }
.footer-brand p { color: var(--muted); font-size: 14px; max-width: 38ch; line-height: 1.65; }
.footer-social { display: flex; gap: 8px; margin-top: 20px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong);
  display: grid; place-items: center; color: var(--ink-soft); transition: all .18s ease;
}
.footer-social a:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.footer-social svg { width: 17px; height: 17px; }
.footer-col h4 { font-size: 12px; letter-spacing: .13em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px; font-family: var(--font-ui); font-weight: 700; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 14px; color: var(--ink-soft); transition: color .16s ease; }
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  margin-top: 46px; border-top: 1px solid var(--line); padding: 22px 0;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 13px; color: var(--muted);
}
.footer-bottom .legal { display: flex; gap: 20px; flex-wrap: wrap; }

/* ---------------------------------------------------------------- article */
.progress-bar { position: fixed; top: 0; left: 0; height: 3px; width: 0; background: var(--accent); z-index: 200; transition: width .1s linear; }

.article-hero { padding: 30px 0 0; }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 22px; flex-wrap: wrap; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb .sep { opacity: .5; }

.article-tag {
  display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: #fff; background: var(--cat, var(--accent)); padding: 6px 13px; border-radius: 999px; margin-bottom: 18px;
}
.article-title { font-size: clamp(30px, 4.6vw, 54px); line-height: 1.06; max-width: 20ch; margin-bottom: 18px; }
.article-standfirst { font-size: clamp(17px, 2vw, 21px); color: var(--ink-soft); line-height: 1.55; max-width: 66ch; font-family: var(--font-ui); font-weight: 400; }

.article-byline { display: flex; align-items: center; gap: 14px; margin: 26px 0 30px; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.avatar { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(150deg, var(--accent), #8e1717); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 17px; flex-shrink: 0; }
.byline-text { display: flex; flex-direction: column; gap: 2px; }
.byline-name { font-size: 14px; font-weight: 600; }
.byline-sub { font-size: 12.5px; color: var(--muted); }
.byline-share { margin-left: auto; display: flex; gap: 8px; }
.share-btn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong); background: transparent; display: grid; place-items: center; cursor: pointer; color: var(--ink-soft); transition: all .18s ease; }
.share-btn:hover { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.share-btn svg { width: 16px; height: 16px; }

.article-figure { margin: 0 0 40px; }
.article-figure img { width: 100%; border-radius: var(--radius-m); aspect-ratio: 16 / 9; object-fit: cover; }
.article-figure figcaption { font-size: 13px; color: var(--muted); margin-top: 10px; padding-left: 14px; border-left: 2px solid var(--accent); }

/* prose */
.prose { max-width: 720px; font-size: 18px; line-height: 1.78; color: var(--ink-soft); }
.prose > * + * { margin-top: 24px; }
.prose h2 { font-size: clamp(23px, 2.6vw, 30px); color: var(--ink); margin-top: 44px; }
.prose h3 { font-size: clamp(19px, 2.1vw, 23px); color: var(--ink); margin-top: 34px; }
.prose strong { color: var(--ink); font-weight: 650; }
.prose > p:first-of-type::first-letter {
  font-family: var(--font-display); float: left; font-size: 62px; line-height: .82;
  font-weight: 700; color: var(--accent); padding: 6px 12px 0 0;
}
.prose ul, .prose ol { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.prose ul li, .prose ol li { position: relative; padding-left: 30px; }
.prose ul li::before { content: ""; position: absolute; left: 6px; top: 12px; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.prose ol { counter-reset: n; }
.prose ol li::before { counter-increment: n; content: counter(n); position: absolute; left: 0; top: 2px; font-family: var(--font-display); font-weight: 700; color: var(--accent); }
.prose blockquote {
  font-family: var(--font-display); font-size: clamp(21px, 2.4vw, 27px); line-height: 1.4;
  color: var(--ink); font-weight: 500; font-style: italic;
  border-left: 4px solid var(--accent); padding: 6px 0 6px 26px; margin: 40px 0;
}
.prose blockquote cite { display: block; font-family: var(--font-ui); font-size: 13.5px; font-style: normal; color: var(--muted); margin-top: 14px; font-weight: 500; }
.prose .callout {
  background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent);
  border-radius: var(--radius-m); padding: 22px 24px; margin: 34px 0;
}
.prose .callout strong { display: block; font-family: var(--font-ui); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 8px; font-weight: 700; }
.prose .callout p { font-size: 16.5px; line-height: 1.65; color: var(--ink-soft); }
.prose .callout > * + * { margin-top: 0; }

/* tags + related */
.tag-row { display: flex; gap: 9px; flex-wrap: wrap; margin: 44px 0 0; }
.tag-pill { font-size: 12.5px; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 7px 15px; transition: all .16s ease; }
.tag-pill:hover { border-color: var(--accent); color: var(--accent); }

.related { margin-top: 64px; padding-top: 44px; border-top: 1px solid var(--line); }

/* -------------------------------------------------------------- page body */
.page-hero { padding: 54px 0 8px; }
.page-hero .eyebrow { font-size: 11.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); display: block; margin-bottom: 14px; }
.page-hero h1 { font-size: clamp(32px, 5vw, 52px); line-height: 1.05; margin-bottom: 16px; }
.page-hero .lede { font-size: clamp(16px, 1.9vw, 19px); color: var(--muted); max-width: 66ch; line-height: 1.6; }

.page-layout { display: grid; grid-template-columns: 240px 1fr; gap: 48px; padding: 44px 0 24px; }
.page-toc { position: sticky; top: calc(var(--header-h) + 70px); align-self: start; }
.page-toc h4 { font-family: var(--font-ui); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; font-weight: 700; }
.page-toc ul { list-style: none; display: flex; flex-direction: column; gap: 4px; border-left: 1px solid var(--line); }
.page-toc a { display: block; padding: 7px 0 7px 16px; margin-left: -1px; border-left: 2px solid transparent; font-size: 14px; color: var(--muted); transition: all .16s ease; }
.page-toc a:hover { color: var(--ink); border-left-color: var(--accent); }

.doc { max-width: 760px; }
.doc h2 { font-size: clamp(21px, 2.4vw, 27px); margin-top: 44px; margin-bottom: 14px; scroll-margin-top: 130px; }
.doc h3 { font-size: 18px; margin-top: 28px; margin-bottom: 10px; font-family: var(--font-ui); font-weight: 650; }
.doc p { font-size: 16.5px; line-height: 1.8; color: var(--ink-soft); }
.doc > * + * { margin-top: 16px; }
.doc ul, .doc ol { list-style: none; display: flex; flex-direction: column; gap: 10px; margin-top: 16px; }
.doc ul li { position: relative; padding-left: 26px; font-size: 16px; color: var(--ink-soft); line-height: 1.7; }
.doc ul li::before { content: ""; position: absolute; left: 4px; top: 11px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.doc .doc-note { background: var(--bg-subtle); border-left: 3px solid var(--accent); padding: 18px 22px; border-radius: 0 var(--radius-s) var(--radius-s) 0; font-size: 15.5px; color: var(--ink-soft); }
.doc a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.doc .updated { font-size: 13.5px; color: var(--muted); margin-top: 8px; }

/* contact */
.contact-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; padding: 44px 0; }
.form-field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.form-field label { font-size: 13.5px; font-weight: 600; }
.form-field input, .form-field textarea, .form-field select {
  border: 1px solid var(--line-strong); border-radius: var(--radius-s);
  padding: 13px 15px; font-size: 15px; background: var(--bg); color: var(--ink);
  font-family: inherit; transition: border-color .16s ease, box-shadow .16s ease;
}
.form-field textarea { min-height: 140px; resize: vertical; }
.form-field input:focus, .form-field textarea:focus, .form-field select:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 16%, transparent);
}
.form-note { font-size: 13px; color: var(--muted); margin-top: 6px; }
.form-status { margin-top: 16px; font-size: 14px; padding: 13px 16px; border-radius: var(--radius-s); display: none; }
.form-status.ok { display: block; background: #e8f6ee; color: #17603a; border: 1px solid #b7e2c9; }
[data-theme="dark"] .form-status.ok { background: #12271c; color: #7fd6a4; border-color: #235237; }

.info-card { background: var(--bg-subtle); border: 1px solid var(--line); border-radius: var(--radius-m); padding: 26px; }
.info-card h3 { font-size: 17px; margin-bottom: 6px; }
.info-card p { font-size: 14.5px; color: var(--muted); line-height: 1.6; }
.info-card + .info-card { margin-top: 16px; }
.info-card .k { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); display: block; margin-bottom: 8px; }

/* stat strip */
.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding: 34px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 30px 0; }
.stat { text-align: center; }
.stat .num { font-family: var(--font-display); font-size: clamp(26px, 3.4vw, 40px); font-weight: 700; color: var(--accent); line-height: 1; }
.stat .lbl { font-size: 12.5px; color: var(--muted); margin-top: 8px; letter-spacing: .04em; }

/* team */
.team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 30px; }
.team-member { text-align: center; }
.team-member .avatar { width: 72px; height: 72px; font-size: 26px; margin: 0 auto 14px; }
.team-member h3 { font-size: 16px; margin-bottom: 4px; }
.team-member p { font-size: 13px; color: var(--muted); }

/* ------------------------------------------------------------------- 404 */
.e404 { min-height: 62vh; display: grid; place-items: center; text-align: center; padding: 60px 20px; }
.e404 .code { font-family: var(--font-display); font-size: clamp(80px, 16vw, 160px); font-weight: 700; line-height: 1; color: var(--accent); letter-spacing: -.04em; }
.e404 h1 { font-size: clamp(24px, 3vw, 34px); margin: 12px 0 14px; }
.e404 p { color: var(--muted); max-width: 46ch; margin: 0 auto 28px; }

/* ------------------------------------------------------------- empty/util */
.empty { text-align: center; padding: 60px 20px; color: var(--muted); }

.reveal { opacity: 0; transform: translateY(16px); }
.reveal.in { opacity: 1; transform: none; transition: opacity .55s ease, transform .55s cubic-bezier(.2,.7,.3,1); }

/* -------------------------------------------------------------- responsive */
@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-side { grid-template-rows: auto; grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .cat-strip { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
  .page-layout { grid-template-columns: 1fr; gap: 20px; }
  .page-toc { position: static; }
  .page-toc ul { flex-direction: row; flex-wrap: wrap; border-left: 0; }
  .page-toc a { border-left: 0; border-bottom: 2px solid transparent; padding: 6px 12px; }
}

@media (max-width: 768px) {
  :root { --gap: 22px; }
  .header-utility { display: none; }
  .menu-toggle { display: grid; }
  .site-nav { position: fixed; inset: var(--header-h) 0 auto 0; background: var(--bg); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); display: none; box-shadow: var(--shadow-m); }
  .site-nav.open { display: block; }
  .nav-scroll { height: auto; flex-direction: column; align-items: stretch; padding: 10px 16px 16px; gap: 2px; }
  .nav-link { border-radius: var(--radius-s); padding: 13px 14px; font-size: 15px; }

  .section { padding: 34px 0; }
  .feature { min-height: 340px; }
  .feature-inner { padding: 24px 20px 22px; }
  .hero-side { grid-template-columns: 1fr; }
  .hero-side .card-media { width: 34%; }
  .grid-3, .grid-4, .grid-2 { grid-template-columns: 1fr; gap: 28px; }
  .cat-strip { grid-template-columns: 1fr; }
  .stat-strip { grid-template-columns: 1fr 1fr; gap: 26px 16px; }
  .team-grid { grid-template-columns: 1fr 1fr; }
  .newsletter { padding: 34px 22px; }
  .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .prose { font-size: 17px; }
  .prose > p:first-of-type::first-letter { font-size: 52px; }
  .page-hero { padding: 34px 0 4px; }
}

@media (max-width: 480px) {
  .brand-name { font-size: 18px; }
  .hero-side .card-media { width: 40%; }
  .byline-share { margin-left: 0; width: 100%; }
}

/* ------------------------------------------------------------ transitions */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ------------------------------------------------------------------ print */
@media print {
  .site-header, .site-footer, .newsletter, .related, .progress-bar { display: none !important; }
  .prose { max-width: 100%; }
}
