/* Inter (variable, latin) is bundled so text has a solid, even weight on every device. */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("../fonts/inter-latin-wght-normal.woff2") format("woff2"); }

/* Knowbrook: public site theme. Dark-green masthead, light page, white content panels, ad-ready zones. Mobile-first. */
:root {
  --ink: #070d13;
  --ink-soft: #141d26;
  --muted: #2a343e;
  --brand: #0b5d4b;
  --brand-dark: #08453a;
  --masthead: #0a3d33;
  --brand-tint: #e8f3ee;
  --accent: #f2b32d;
  --page: #f0f3f1;
  --card: #ffffff;
  --line: #dde4e0;
  --link: #08498a;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 2px rgba(14, 22, 32, .06);
  --shadow-md: 0 8px 24px rgba(14, 22, 32, .10);
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --tone: var(--brand);
  --tone-bg: var(--brand-tint);
  --bs-body-font-family: var(--sans);
  --bs-body-color: var(--ink);
  --bs-body-bg: var(--page);
  --bs-link-color: var(--link);
  --bs-link-color-rgb: 8, 73, 138;
  --bs-link-hover-color: #06366a;
  --bs-link-hover-color-rgb: 6, 54, 106;
  --header-h: 62px;
}
.tone-wallet { --tone: #0a7a5a; --tone-bg: #e0f3eb; }
.tone-briefcase { --tone: #2456b5; --tone-bg: #e6edfb; }
.tone-home { --tone: #a05a10; --tone-bg: #fbeedc; }
.tone-car { --tone: #bc3f0d; --tone-bg: #fde8df; }
.tone-graduation { --tone: #7a34dd; --tone-bg: #efe8fc; }
.tone-laptop { --tone: #0c6b80; --tone-bg: #dcf1f6; }

html { scroll-padding-top: calc(var(--header-h) + 16px); }
body { font-family: var(--sans); font-weight: 450; color: var(--ink); background: var(--page); line-height: 1.6; -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4 { font-family: var(--sans); font-weight: 700; letter-spacing: -.015em; line-height: 1.22; color: var(--ink); }
a { text-underline-offset: 3px; }
img { max-width: 100%; height: auto; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--brand); color: #fff; padding: .7rem 1.1rem; z-index: 3000; border-radius: 0 0 var(--radius-sm) 0; }
.skip-link:focus { left: 0; color: #fff; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.container { --bs-gutter-x: 2rem; }
@media (min-width: 1200px) { .container { max-width: 1200px; } }
.row { --bs-gutter-x: 1.5rem; }
.g-5, .gx-5, .g-4, .gx-4, .g-lg-4, .g-3 { --bs-gutter-x: 1.5rem; }
.row.g-5, .row.gx-5 { --bs-gutter-x: 2rem; }
@media (max-width: 575.98px) { .container, .row, .row.g-5, .row.gx-5, .row.g-4, .row.g-3 { --bs-gutter-x: 1.25rem; } }
html, body { overflow-x: clip; }
.muted { color: var(--muted); }
::placeholder { color: #47525d !important; opacity: 1; }
.form-text, .text-muted { color: var(--muted) !important; }

/* Panels: white content areas on the light page */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem 1.75rem; box-shadow: var(--shadow-sm); }
.panel > :last-child { margin-bottom: 0; }
@media (max-width: 575.98px) { .panel { padding: 1.1rem; border-radius: 12px; } }

.read-progress { position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 2000; pointer-events: none; }
.read-progress span { display: block; height: 100%; width: 0; background: var(--accent); transition: width .1s linear; }

/* ================================ Masthead / header ================================ */
.site-header { background: var(--masthead); position: sticky; top: 0; z-index: 1020; box-shadow: 0 1px 0 rgba(255, 255, 255, .06), 0 4px 14px rgba(0, 0, 0, .14); }
.header-row { display: flex; align-items: center; gap: 1.25rem; height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 800; font-size: 1.13rem; color: #fff; text-decoration: none; letter-spacing: -.02em; white-space: nowrap; }
.brand:hover { color: #fff; opacity: .92; }
.brand-mark { display: inline-block; width: 34px; height: 34px; flex: none; line-height: 0; }
.brand-mark svg { width: 100%; height: 100%; display: block; }

.nav-wrap { display: none; height: 100%; }
.main-nav { display: flex; list-style: none; margin: 0 0 0 .5rem; padding: 0; align-items: stretch; gap: .1rem; height: 100%; }
.main-nav > li { position: relative; display: flex; }
.main-nav > li > a { display: flex; align-items: center; padding: 0 .8rem; font-weight: 600; font-size: .94rem; color: rgba(255, 255, 255, .9); text-decoration: none; border-bottom: 3px solid transparent; margin-top: 3px; }
.main-nav > li > a:hover, .main-nav > li:focus-within > a { color: #fff; border-bottom-color: var(--accent); }
.main-nav > li > a[aria-current="page"] { color: #fff; border-bottom-color: var(--accent); }
.nav-panel { position: absolute; left: 0; top: 100%; min-width: 260px; padding: .5rem; background: #fff; border-radius: 0 0 var(--radius) var(--radius); box-shadow: var(--shadow-md); display: none; z-index: 10; }
.main-nav > li:hover > .nav-panel, .main-nav > li:focus-within > .nav-panel { display: block; }
.nav-panel a { display: block; padding: .5rem .75rem; border-radius: var(--radius-sm); color: var(--ink-soft); text-decoration: none; font-size: .92rem; }
.nav-panel a:hover { background: var(--tone-bg); color: var(--tone); }
.nav-panel .all { font-weight: 700; color: var(--tone); border-bottom: 1px solid var(--line); border-radius: 0; margin-bottom: .25rem; }

.header-search { margin-left: auto; display: none; position: relative; width: 250px; }
.header-search .form-control { height: 40px; border-radius: 999px; border: 0; background: #fff; padding: 0 2.8rem 0 1.05rem; font-size: .93rem; }
.header-search button { position: absolute; right: 4px; top: 4px; width: 32px; height: 32px; border: 0; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; }
.header-search button svg { width: 16px; height: 16px; }
.header-actions { margin-left: auto; display: flex; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 0; background: transparent; color: #fff; border-radius: 50%; }
.icon-btn:hover { background: rgba(255, 255, 255, .14); color: #fff; }
.icon-btn svg { width: 22px; height: 22px; }
@media (min-width: 1024px) { .nav-wrap { display: flex; } .header-search { display: block; } .header-actions { display: none; } }
@media (max-width: 420px) { .brand { font-size: 1rem; } }

/* Mobile menu */
.offcanvas { --bs-offcanvas-width: min(88vw, 360px); }
.mnav details { border-bottom: 1px solid var(--line); }
.mnav summary { list-style: none; display: flex; align-items: center; gap: .8rem; padding: .85rem .25rem; font-weight: 600; cursor: pointer; }
.mnav summary::-webkit-details-marker { display: none; }
.mnav summary .ico { width: 34px; height: 34px; border-radius: 9px; background: var(--tone-bg); color: var(--tone); display: grid; place-items: center; flex: none; }
.mnav summary .ico svg { width: 18px; height: 18px; }
.mnav summary::after { content: "›"; margin-left: auto; font-size: 1.5rem; color: var(--muted); transition: transform .2s; }
.mnav details[open] summary::after { transform: rotate(90deg); }
.mnav .subs { padding: 0 0 .7rem 2.9rem; display: grid; }
.mnav .subs a { padding: .4rem 0; color: var(--ink-soft); text-decoration: none; font-size: .95rem; }
.mnav .plain a { display: block; padding: .65rem .25rem; color: var(--ink-soft); text-decoration: none; }

/* ================================ Layout helpers ================================ */
.section { padding-block: 1.75rem; }
@media (max-width: 767.98px) { .section { padding-block: 1.25rem; } }
.section-title { font-size: 1.3rem; margin-bottom: 1rem; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.section-head .section-title { margin: 0; }
.eyebrow { display: inline-block; text-transform: uppercase; letter-spacing: .06em; font-size: .7rem; font-weight: 700; color: var(--tone); text-decoration: none; }
a.eyebrow:hover { text-decoration: underline; }

.crumbs { font-size: .84rem; padding-top: .9rem; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .1rem .4rem; }
.crumbs li + li::before { content: "›"; margin-right: .4rem; color: #7b8590; }
.crumbs a { color: #1c2630; text-decoration: none; }
.crumbs a:hover { color: var(--tone); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 500; }

/* Colour band at the top of inner pages: category / subcategory / author / static / search */
.page-head { background: var(--tone); color: #fff; padding-bottom: 1.2rem; }
.page-head .crumbs a, .page-head .crumbs li + li::before { color: #fff; font-weight: 500; }
.page-head .crumbs a:hover { color: #fff; }
.page-head .crumbs [aria-current] { color: #fff; }
.page-head .head-row { display: flex; align-items: center; gap: .9rem; margin-top: .55rem; }
.page-head .head-ico { width: 46px; height: 46px; border-radius: 12px; background: rgba(255, 255, 255, .18); color: #fff; display: grid; place-items: center; flex: none; }
.page-head .head-ico svg { width: 24px; height: 24px; }
.page-head h1 { font-size: clamp(1.5rem, 3.4vw, 2rem); margin: 0; color: #fff; }
.page-head .lead { font-size: 1.02rem; font-weight: 500; color: #fff; margin: .2rem 0 0; max-width: 46rem; }
.page-head .muted { color: #fff; }
.page-head .search-hero .form-control { border: 0; }

/* ================================= Home ================================= */
.hero { background: linear-gradient(180deg, var(--masthead) 0%, #0d6a55 100%); color: #fff; padding: 1.6rem 0 2.1rem; }
.hero h1 { color: #fff; font-size: clamp(1.65rem, 4.2vw, 2.4rem); max-width: 30ch; margin-bottom: .5rem; line-height: 1.14; }
.hero p.lead { font-size: 1.05rem; font-weight: 500; color: #fff; max-width: 40rem; margin-bottom: 1.1rem; }
.hero-search { position: relative; max-width: 580px; }
.hero-search .form-control { height: 52px; border: 0; border-radius: 999px; padding: 0 7.5rem 0 1.4rem; font-size: 1rem; box-shadow: 0 6px 20px rgba(0, 0, 0, .22); }
.hero-search .btn { position: absolute; right: 5px; top: 5px; bottom: 5px; padding: 0 1.5rem; border-radius: 999px; font-weight: 700; background: var(--accent); border-color: var(--accent); color: #2a1d00; }
.hero-search .btn:hover { background: #ffc44a; }
.hero-chips { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .9rem; align-items: center; font-size: .86rem; font-weight: 500; color: #fff; }
.hero-chips a { padding: .25rem .8rem; border-radius: 999px; background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .22); color: #fff; text-decoration: none; }
.hero-chips a:hover { background: rgba(255, 255, 255, .26); }

.tile { display: flex; gap: .9rem; align-items: flex-start; height: 100%; padding: 1.05rem 1.15rem; border: 1px solid var(--line); border-top: 4px solid var(--tone); border-radius: var(--radius); background: var(--card); color: var(--ink); text-decoration: none; box-shadow: var(--shadow-sm); transition: box-shadow .15s, transform .15s; }
.tile:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); color: var(--ink); }
.tile .ico { width: 46px; height: 46px; border-radius: 12px; background: var(--tone-bg); color: var(--tone); display: grid; place-items: center; flex: none; }
.tile .ico svg { width: 24px; height: 24px; }
.tile h3 { font-size: 1.05rem; margin: 0 0 .15rem; }
.tile p { font-size: .88rem; color: var(--muted); margin: 0 0 .3rem; line-height: 1.4; }
.tile .count { font-size: .8rem; font-weight: 700; color: var(--tone); }

.sub-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .45rem; }
.sub-links a, .chip { display: inline-flex; align-items: center; gap: .4rem; padding: .35rem .85rem; border: 1px solid var(--line); border-radius: 999px; font-size: .88rem; color: var(--ink-soft); text-decoration: none; background: #fff; }
.sub-links a:hover, .chip:hover { border-color: var(--tone); color: var(--tone); background: var(--tone-bg); }
.sub-links .n { color: var(--muted); font-size: .78rem; }

/* ============================ Article cards / lists ============================ */
.thumb { display: block; position: relative; aspect-ratio: 16 / 9; background: var(--tone-bg); overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb .ph { position: absolute; inset: 0; display: grid; place-items: center; color: var(--tone); background: linear-gradient(135deg, var(--tone-bg), color-mix(in srgb, var(--tone) 14%, #fff)); }
.thumb .ph svg { width: 34%; max-width: 56px; min-width: 22px; opacity: .55; }
.a-card { display: flex; flex-direction: column; height: 100%; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--card); box-shadow: var(--shadow-sm); transition: box-shadow .15s; }
.a-card:hover { box-shadow: var(--shadow-md); }
.a-card .body { padding: .9rem 1rem 1rem; display: flex; flex-direction: column; flex: 1; }
.a-card h3 { font-size: 1.05rem; line-height: 1.3; margin: .3rem 0 .4rem; }
.a-card h3 a, .a-row h3 a { color: var(--ink); text-decoration: none; }
.a-card h3 a:hover, .a-row h3 a:hover { color: var(--tone); text-decoration: underline; }
.a-card p { font-size: .9rem; color: #1a232c; margin-bottom: .6rem; line-height: 1.5; }
.meta { margin-top: auto; display: flex; flex-wrap: wrap; gap: .1rem .55rem; font-size: .78rem; color: var(--muted); }
.meta span + span::before { content: "·"; margin-right: .55rem; }

.a-row { display: grid; grid-template-columns: 148px 1fr; gap: 1.1rem; padding: 1.1rem 0; border-bottom: 1px solid var(--line); }
.a-row:first-child { padding-top: 0; }
.a-row:last-child { border-bottom: 0; padding-bottom: 0; }
.a-row .thumb { border-radius: var(--radius-sm); align-self: start; }
.a-row h3 { font-size: 1.15rem; margin: .2rem 0 .3rem; line-height: 1.3; }
.a-row p { font-size: .93rem; color: #1a232c; margin: 0 0 .4rem; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 575.98px) { .a-row { grid-template-columns: 88px 1fr; gap: .8rem; } .a-row h3 { font-size: 1rem; } .a-row p { display: none; } }

.rank-list { counter-reset: rank; list-style: none; padding: 0; margin: 0; }
.rank-list li { counter-increment: rank; display: flex; gap: .75rem; padding: .65rem 0; border-bottom: 1px solid var(--line); }
.rank-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.rank-list li::before { content: counter(rank); font-weight: 800; font-size: 1.15rem; color: #c98a00; width: 1.3rem; flex: none; line-height: 1.2; }
.rank-list a { color: var(--ink); font-weight: 600; text-decoration: none; line-height: 1.35; display: block; font-size: .95rem; }
.rank-list a:hover { color: var(--brand); text-decoration: underline; }
.rank-list small { display: block; color: var(--muted); font-weight: 400; margin-top: .1rem; }
.box { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; background: var(--card); box-shadow: var(--shadow-sm); }
.box h2, .box h3 { font-size: 1rem; margin-bottom: .6rem; }
.lead-text { font-size: 1rem; color: var(--ink-soft); line-height: 1.6; margin: 0 0 1.1rem; }

/* ================================ Article ================================ */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; padding-top: .9rem; }
@media (min-width: 992px) { .article-layout { grid-template-columns: minmax(0, 1fr) 320px; gap: 1.5rem; } }
.article-head .cats { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0 0 .6rem; }
.article-head .cats a { padding: .18rem .65rem; border-radius: 999px; background: var(--tone-bg); color: var(--tone); font-size: .72rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; text-decoration: none; }
.article-head .cats a:hover { background: var(--tone); color: #fff; }
.article-head h1 { font-size: clamp(1.65rem, 3.6vw, 2.3rem); margin: 0 0 .6rem; line-height: 1.18; }
.article-head .intro { font-size: 1.1rem; line-height: 1.55; color: var(--ink-soft); margin-bottom: .9rem; }
.byline { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1.1rem; font-size: .88rem; color: var(--muted); padding: .7rem 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-bottom: 1.25rem; }
.byline .who { display: flex; align-items: center; gap: .55rem; }
.byline .av { width: 30px; height: 30px; border-radius: 50%; background: var(--tone); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .8rem; overflow: hidden; flex: none; }
.byline .av img { width: 100%; height: 100%; object-fit: cover; }
.byline a { color: var(--ink); font-weight: 600; text-decoration: none; }
.byline a:hover { text-decoration: underline; }
.byline .when { display: flex; flex-wrap: wrap; gap: .1rem 1rem; }
.article-figure { margin: 0 0 1.4rem; }
.article-figure img { width: 100%; border-radius: var(--radius-sm); background: var(--tone-bg); }
.article-figure figcaption, .prose figcaption { font-size: .84rem; color: var(--muted); margin-top: .4rem; }

.prose { font-family: var(--sans); font-size: 1.0625rem; font-weight: 450; line-height: 1.75; color: #05090e; max-width: 46rem; overflow-wrap: anywhere; }
@media (min-width: 768px) { .prose { font-size: 1.125rem; } }
.prose > * + * { margin-top: 1.05em; }
.prose h2 { font-size: 1.55rem; margin-top: 1.9em; padding-top: .3em; }
.prose h3 { font-size: 1.25rem; margin-top: 1.6em; }
.prose h4 { font-size: 1.08rem; margin-top: 1.4em; }
.prose h2 + *, .prose h3 + *, .prose h4 + * { margin-top: .5em; }
.prose ul, .prose ol { padding-left: 1.4rem; }
.prose li + li { margin-top: .35em; }
.prose li::marker { color: var(--tone); font-weight: 700; }
.prose a { color: var(--link); text-decoration: underline; text-decoration-thickness: 1px; }
.prose a:hover { text-decoration-thickness: 2px; }
.prose blockquote { margin-left: 0; padding: .8rem 1.1rem; border-left: 4px solid var(--tone); background: var(--tone-bg); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.prose blockquote p { margin: 0; }
.prose img { border-radius: var(--radius-sm); height: auto; }
.prose figure { margin-left: 0; margin-right: 0; }
.prose table { font-size: .95rem; margin: 0; }
.prose th { background: #f1f4f2; color: var(--ink); }
.prose hr { margin: 2rem 0; }
.article-table { margin: 1.4rem 0; }

.toc { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; padding: .9rem 1rem; box-shadow: var(--shadow-sm); }
.toc summary, .toc strong { font-weight: 700; font-size: .95rem; }
.toc summary { cursor: pointer; }
.toc ol { list-style: none; margin: .5rem 0 0; padding: 0; font-size: .9rem; }
.toc li.l3 { padding-left: .9rem; }
.toc a { display: block; padding: .3rem .6rem; color: var(--ink-soft); text-decoration: none; border-left: 2px solid var(--line); line-height: 1.35; }
.toc a:hover { color: var(--tone); border-left-color: var(--tone); }
.toc a.active { color: var(--tone); border-left-color: var(--tone); font-weight: 600; background: var(--tone-bg); border-radius: 0 6px 6px 0; }
.sidebar-sticky { position: sticky; top: calc(var(--header-h) + 14px); }
.mini-list { list-style: none; margin: 0; padding: 0; }
.mini-list li { padding: .6rem 0; border-bottom: 1px solid var(--line); }
.mini-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.mini-list a { display: block; font-weight: 600; font-size: .93rem; line-height: 1.35; color: var(--ink); text-decoration: none; }
.mini-list a:hover { color: var(--tone); text-decoration: underline; }
.mini-list small { display: block; color: var(--muted); margin-top: .1rem; font-size: .8rem; }

.share { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin: 1.75rem 0 0; }
.share > span { font-size: .85rem; font-weight: 700; color: var(--ink-soft); margin-right: .2rem; }
.share a, .share button { display: inline-flex; align-items: center; padding: .35rem .8rem; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink-soft); font-size: .84rem; font-weight: 600; text-decoration: none; cursor: pointer; }
.share a:hover, .share button:hover { border-color: var(--tone); color: var(--tone); }
.also-read { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .7rem; font-size: 1rem; padding: .8rem 1rem; margin: 1.5em 0 !important; background: var(--tone-bg); border-left: 4px solid var(--tone); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.also-read strong { text-transform: uppercase; letter-spacing: .07em; font-size: .7rem; color: var(--tone); }
.also-read a { font-weight: 700; color: var(--ink); text-decoration: none; }
.also-read a:hover { text-decoration: underline; color: var(--tone); }
.pn { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.pn a { display: block; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; text-decoration: none; color: var(--ink); }
.pn a:hover { border-color: var(--tone); }
.pn small { display: block; color: var(--tone); font-weight: 700; margin-bottom: .2rem; font-size: .76rem; }
.pn span { font-weight: 600; line-height: 1.35; display: block; font-size: .95rem; }
.pn-next { text-align: right; grid-column: 2; }
.pn-prev { grid-column: 1; }
@media (max-width: 575.98px) { .pn { grid-template-columns: 1fr; } .pn-next, .pn-prev { grid-column: auto; text-align: left; } }
.review-note { display: flex; gap: .7rem; padding: .85rem 1rem; background: var(--brand-tint); border: 1px solid #cfe6dc; border-radius: var(--radius); font-size: .9rem; }
.review-note svg { width: 20px; height: 20px; flex: none; color: var(--brand); margin-top: 1px; }
.review-note a { color: #084a86; font-weight: 600; }
.faq details { border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; margin-bottom: .5rem; }
.faq summary { cursor: pointer; font-weight: 600; padding: .8rem 1rem; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.3rem; line-height: 1; color: var(--tone); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0; padding: 0 1rem 1rem; color: var(--ink-soft); }
.author-box { display: flex; gap: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: var(--radius); background: #f6f8f7; }
.author-box .avatar { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex: none; background: var(--line); }
.author-box .avatar.avatar-fallback { display: grid; place-items: center; font-weight: 700; color: #fff; background: var(--tone); font-size: 1.3rem; }
.preview-bar { background: #fff3cd; border-bottom: 1px solid #ecd58a; padding: .5rem 0; font-size: .9rem; text-align: center; }

/* ================================ Ad zones ================================
   Every ad sits in a fixed, labeled frame with reserved height, so nothing jumps when an ad loads,
   and ads never touch article text. Use ?ad-preview=1 (logged in) to see every zone. */
.ad-slot { margin: 1.4rem 0; padding: .35rem .5rem .5rem; text-align: center; background: #f7f9f8; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; clear: both; max-width: 100%; }
.ad-slot .ad-label { display: block; font-size: .66rem; letter-spacing: .1em; text-transform: uppercase; color: #3a454f; font-weight: 600; margin-bottom: .25rem; }
.ad-slot ins { display: block; width: 100%; }
.ad-slot.ad-header { margin: 1rem 0 0; }
.ad-slot.ad-sidebar { margin: 0; }
.ad-slot.ad-in_feed { margin: 1rem 0; }
.ad-preview-box .ad-fake { display: grid; place-items: center; min-height: inherit; border: 2px dashed #9aa8a1; border-radius: 6px; background: repeating-linear-gradient(45deg, #f2f5f3, #f2f5f3 10px, #e9eeeb 10px, #e9eeeb 20px); color: #26323d; font-weight: 700; font-size: .85rem; padding: .5rem; }
.ad-preview-box .ad-fake small { display: block; font-weight: 500; margin-top: .15rem; color: #45515d; }

/* ================================= Footer ================================= */
.site-footer { background: var(--masthead); color: #dbe8e2; margin-top: 2.5rem; padding: 2rem 0 1rem; font-size: .9rem; }
.site-footer a { color: #e9f2ee; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.site-footer h2 { font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: #d2e6dd; margin-bottom: .7rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .4rem; }
.site-footer .brand { color: #fff; }
.footer-blurb { max-width: 24rem; margin: .8rem 0 0; color: #e6f0eb; line-height: 1.55; font-size: .88rem; }
.footer-bottom { border-top: 1px solid #1c5245; margin-top: 1.5rem; padding-top: 1rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: .4rem 1.5rem; font-size: .8rem; color: #d6e5de; }

/* ============================ Forms, buttons, misc ============================ */
.btn-brand { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; border-radius: 999px; padding-left: 1.4rem; padding-right: 1.4rem; }
.btn-brand:hover, .btn-brand:focus { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn-outline-brand { border-color: var(--brand); color: var(--brand); font-weight: 600; border-radius: 999px; }
.btn-outline-brand:hover { background: var(--brand); color: #fff; }
.form-control, .form-select { border-color: #b7c0ba; border-radius: var(--radius-sm); color: var(--ink); }
.form-label { color: var(--ink); font-weight: 600; font-size: .92rem; }
.form-control:focus, .form-select:focus { border-color: var(--brand); box-shadow: 0 0 0 .2rem rgba(11, 93, 75, .18); }
.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.pagination { --bs-pagination-active-bg: var(--brand); --bs-pagination-active-border-color: var(--brand); --bs-pagination-color: var(--brand); --bs-pagination-hover-color: var(--brand-dark); gap: .3rem; flex-wrap: wrap; }
.pagination .page-link { border-radius: 999px !important; min-width: 38px; text-align: center; }
.empty-state { text-align: center; padding: 2.5rem 1rem; color: var(--muted); background: #f6f8f7; border: 1px dashed #c5cec8; border-radius: var(--radius); }
.error-code { font-size: clamp(3.5rem, 12vw, 6rem); font-weight: 800; color: var(--brand); line-height: 1; letter-spacing: -.04em; }
.search-hero { position: relative; max-width: 560px; }
.search-hero .form-control { height: 48px; border-radius: 999px; padding: 0 6.5rem 0 1.2rem; }
.search-hero .btn { position: absolute; right: 4px; top: 4px; bottom: 4px; padding: 0 1.2rem; }
.static-page { max-width: 50rem; }
@media print { .site-header, .site-footer, .ad-slot, .sidebar, .toc, .share, .read-progress { display: none !important; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; animation: none !important; } }

/* Subcategory list (sidebar) */
.sub-list { list-style: none; margin: 0; padding: 0; }
.sub-list li + li { border-top: 1px solid var(--line); }
.sub-list a, .sub-list .soon { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .6rem .5rem; border-radius: var(--radius-sm); font-weight: 600; font-size: .94rem; color: var(--ink); text-decoration: none; }
.sub-list a:hover { background: var(--tone-bg); color: var(--tone); }
.sub-list a.active { background: var(--tone-bg); color: var(--tone); box-shadow: inset 3px 0 0 var(--tone); }
.sub-list .n { min-width: 1.7rem; text-align: center; padding: .05rem .5rem; border-radius: 999px; background: #eef2f0; color: var(--ink-soft); font-size: .78rem; font-weight: 700; }
.sub-list a.active .n, .sub-list a:hover .n { background: var(--tone); color: #fff; }
.sub-list .soon { color: #2f3b46; font-weight: 600; }

/* Readability boosts */
.meta, .byline, .rank-list small, .mini-list small, .tile p, .section-head .muted, .lead-text { font-weight: 500; }
.sub-links a, .chip, .nav-panel a, .hero-chips a { font-weight: 500; }
.sub-list a, .sub-list .n { font-weight: 700; }
.article-head .intro { font-weight: 500; color: #0d1620; }

/* =====================================================================================
   PHONE APP MODE (below 992px): bottom tab bar, slide-up sheets, edge-to-edge cards
   ===================================================================================== */
a, button, summary, .tile, .a-row, .a-card { -webkit-tap-highlight-color: transparent; }
a, button, summary, input, select, textarea { touch-action: manipulation; }

/* Topic chips (phone) */
.chip-nav { display: flex; gap: .5rem; padding: .65rem 1.25rem; background: #fff; border-bottom: 1px solid var(--line); overflow-x: auto; white-space: nowrap; scroll-snap-type: x proximity; scroll-padding-inline: 1.25rem; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.chip-nav::-webkit-scrollbar { display: none; }
.chip-nav a { flex: none; scroll-snap-align: start; padding: .42rem 1rem; border-radius: 999px; border: 1px solid var(--line); background: #f6f8f7; color: var(--ink); font-weight: 600; font-size: .9rem; text-decoration: none; }
.chip-nav a.active { background: var(--brand); border-color: var(--brand); color: #fff; }

/* Bottom tab bar */
.app-tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1030; display: flex; background: rgba(255, 255, 255, .97); backdrop-filter: blur(12px); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); box-shadow: 0 -4px 16px rgba(14, 22, 32, .07); }
.app-tabbar > * { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; height: 58px; padding: 0; border: 0; background: none; color: #33404b; font-size: .69rem; font-weight: 600; text-decoration: none; position: relative; transition: transform .1s, color .15s; }
.app-tabbar svg { width: 24px; height: 24px; }
.app-tabbar > *:active { transform: scale(.92); }
.app-tabbar .active { color: var(--brand); }
.app-tabbar .active::before { content: ""; position: absolute; top: 0; width: 34px; height: 3px; border-radius: 0 0 3px 3px; background: var(--brand); }

/* Slide-up sheets */
.app-sheet { height: auto !important; max-height: 82vh; border-radius: 22px 22px 0 0; border: 0; padding-bottom: env(safe-area-inset-bottom); }
.app-sheet .offcanvas-header { padding-top: .25rem; }
.sheet-handle { width: 42px; height: 5px; border-radius: 3px; background: #c8d0cb; margin: .6rem auto .2rem; }
.app-sheet .mnav summary { padding: 1rem .25rem; }
.app-sheet .plain a { display: block; padding: .85rem .25rem; font-weight: 600; border-bottom: 1px solid var(--line); }

@media (max-width: 991.98px) {
  :root { --header-h: 54px; }
  body { padding-bottom: calc(58px + env(safe-area-inset-bottom)); background: #eef1ef; }
  .site-header { padding-top: env(safe-area-inset-top); }
  .header-row { height: var(--header-h); }
  .brand { font-size: 1.05rem; }
  .brand-mark { width: 30px; height: 30px; }

  /* cards run edge to edge like app screens */
  .panel, .box, .toc { margin-inline: calc(var(--bs-gutter-x) * -.5); border-radius: 0; border-inline: 0; box-shadow: none; padding-inline: 1.25rem; }
  .panel { padding-block: 1.1rem; }
  .article-layout { gap: .6rem; }
  .article-layout .sidebar { margin-top: 0; }
  .page-head { padding-bottom: 1rem; }
  .page-head .head-ico { width: 40px; height: 40px; }
  .section { padding-block: 1rem; }
  .hero { padding: 1.1rem 0 1.4rem; }
  .hero h1 { font-size: 1.5rem; margin-bottom: .35rem; }
  .hero p.lead { font-size: .95rem; margin-bottom: .8rem; }
  .hero-search .form-control { height: 48px; }
  .site-footer { margin-top: 1rem; padding-bottom: 5.5rem; }

  /* touch feedback and bigger tap targets */
  .tile:active, .a-row:active, .a-card:active, .sub-list a:active, .mini-list li:active, .chip-nav a:active, .rank-list li:active { opacity: .85; transform: scale(.985); }
  .sub-list a, .sub-list .soon { padding-block: .8rem; }
  .mini-list li, .rank-list li { padding-block: .8rem; }
  .btn { min-height: 44px; }
  .share a, .share button { padding: .55rem 1rem; }
  .faq summary { padding-block: 1rem; }
}

@media (max-width: 575.98px) {
  .row.g-3 { --bs-gutter-x: .75rem; --bs-gutter-y: .75rem; }
  /* home topics: 2-up launcher tiles */
  .tile { flex-direction: column; gap: .55rem; padding: .85rem .9rem; border-top-width: 3px; }
  .tile .ico { width: 42px; height: 42px; }
  .tile h3 { font-size: .98rem; }
  .tile p { display: none; }
  .a-row { padding-block: .9rem; }
  .article-head h1 { font-size: 1.55rem; }
  .prose { font-size: 1.06rem; }
}

/* Installed app (standalone): hide the site footer, it lives in the More sheet */
@media (display-mode: standalone) and (max-width: 991.98px) {
  .site-footer { display: none; }
  body { padding-bottom: calc(58px + env(safe-area-inset-bottom)); }
}
@media (min-width: 992px) { .app-tabbar, .app-sheet, .chip-nav { display: none !important; } }
.section-head .muted { white-space: nowrap; }
.section-head .section-title { min-width: 0; }

/* ---- Home refresh: two-column hero, subtopic tiles ---- */
.hero { padding: 2.2rem 0 2.6rem; }
.hero-kicker { display: inline-flex; align-items: center; gap: .4rem; font-size: .8rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #ffe08a; margin-bottom: .6rem; }
.hero-kicker svg { width: 16px; height: 16px; }
.hero h1 { max-width: 20ch; }
.hero-chips > span { color: #d6efe6; }
.hero-card { background: rgba(255, 255, 255, .97); color: var(--ink); border-radius: 18px; padding: 1.1rem 1.2rem .6rem; box-shadow: 0 18px 40px rgba(0, 0, 0, .25); }
.hero-card h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--brand); margin: 0 0 .4rem; }
.hero-card-item { display: block; padding: .8rem 0; border-top: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.hero-card-item:first-of-type { border-top: 0; }
.hero-card-item small { display: block; font-size: .72rem; font-weight: 700; color: var(--brand); text-transform: uppercase; letter-spacing: .04em; }
.hero-card-item strong { display: block; font-size: 1.02rem; line-height: 1.3; margin: .1rem 0; }
.hero-card-item span { font-size: .8rem; color: var(--muted); }
.hero-card-item:hover strong { text-decoration: underline; }
.tile { align-items: center; }
.tile p.subs { font-size: .84rem; color: var(--ink-2, #33404b); margin: 0 0 .35rem; font-weight: 500; }
@media (max-width: 991.98px) { .hero { padding: 1.1rem 0 1.4rem; } .hero-kicker { font-size: .7rem; } .tile p.subs { display: none; } }
@media (max-width: 991.98px) { .hero-chips { display: none; } }

/* Search page */
.search-head { padding-top: 1.4rem; padding-bottom: 1.5rem; }
.search-head h1 { font-size: clamp(1.4rem, 3vw, 1.9rem); }
.search-head .hero-search { max-width: 640px; }
.topic-pills { display: flex; flex-wrap: wrap; gap: .5rem; }
.topic-pills a { padding: .45rem 1rem; border-radius: 999px; border: 1px solid var(--line); background: #f6f8f7; color: var(--ink); font-weight: 600; font-size: .92rem; text-decoration: none; }
.topic-pills a:hover { background: var(--brand-tint); border-color: var(--brand); }
.empty-state { text-align: center; padding: 1.5rem .5rem; }

/* Hero topic launcher (shown beside the intro until there are articles to feature) */
.hero h1 { max-width: 26ch; font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
.hero-art { position: relative; height: 330px; }
.hero-art .waves { position: absolute; inset: 0; width: 100%; height: 100%; fill: none; stroke: rgba(255, 255, 255, .16); stroke-width: 2; stroke-linecap: round; }
.hero-art .waves path:nth-child(2) { stroke: rgba(255, 255, 255, .11); }
.hero-art .waves path:nth-child(3) { stroke: rgba(255, 255, 255, .08); }
.hero-art .waves path:nth-child(4) { stroke: rgba(255, 255, 255, .05); }
.orb { position: absolute; width: 118px; display: flex; flex-direction: column; align-items: center; gap: .4rem; padding: .85rem .5rem .7rem; border-radius: 18px; background: #fff; color: var(--ink); font-weight: 700; font-size: .92rem; text-decoration: none; box-shadow: 0 14px 30px rgba(0, 0, 0, .22); transition: transform .2s, box-shadow .2s; }
.orb svg { width: 34px; height: 34px; padding: 7px; box-sizing: content-box; border-radius: 12px; background: var(--tone-bg); color: var(--tone); }
.orb:hover { transform: translateY(-4px); box-shadow: 0 18px 36px rgba(0, 0, 0, .3); color: var(--ink); }
.orb.o0 { left: 4%; top: 14%; } .orb.o1 { left: 38%; top: 0; } .orb.o2 { left: 68%; top: 12%; }
.orb.o3 { left: 12%; top: 58%; } .orb.o4 { left: 46%; top: 50%; } .orb.o5 { left: 72%; top: 60%; }
@media (prefers-reduced-motion: no-preference) {
  .orb { animation: orb-float 6s ease-in-out infinite; }
  .orb.o1, .orb.o4 { animation-delay: -2s; } .orb.o2, .orb.o5 { animation-delay: -4s; }
}
@keyframes orb-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -7px; } }
