/* ============================================================
   The Gibraltar Journal — blog layer.
   Extends the site palette in /style.css (OKLCH sun-bleached
   Mediterranean). No inline styles anywhere (strict CSP): all
   colour, including SVG charts + art, is set here via classes.
   ============================================================ */

:root {
  --sun: oklch(0.72 0.15 65);
  --sky: oklch(0.86 0.06 230);
  --rock: oklch(0.50 0.03 60);
  --chip-bg: oklch(0.955 0.016 82);
  --shadow-card: 0 18px 44px -28px oklch(0.40 0.05 55 / 0.38);
  --shadow-soft: 0 10px 26px -18px oklch(0.40 0.05 55 / 0.34);
  --maxw-prose: 72ch;

  /* chart / data palette */
  --c-sun: oklch(0.72 0.15 62);
  --c-sea: oklch(0.60 0.10 232);
  --c-temp: oklch(0.68 0.15 55);
  --c-rain: oklch(0.66 0.08 235);
  --c-1: oklch(0.62 0.13 45);
  --c-2: oklch(0.62 0.10 205);
  --c-3: oklch(0.68 0.13 140);
  --c-4: oklch(0.75 0.14 85);
  --c-5: oklch(0.58 0.12 300);
  --c-6: oklch(0.60 0.11 20);
  --c-direct: oklch(0.60 0.12 150);
  --c-ota: oklch(0.72 0.02 70);
}

/* ---------- accessibility helpers ---------- */
.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: 12px; top: -60px; z-index: 100;
  background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 10px;
  font-size: 14px; font-weight: 600; transition: top 0.15s;
}
.skip-link:focus { top: 12px; }
:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; border-radius: 3px; }

.container-wide { max-width: 1280px; margin: 0 auto; padding: 0 28px; }

/* ============================================================ NAV */
.bnav {
  position: sticky; top: 0; z-index: 50;
  background: oklch(0.972 0.013 85 / 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.bnav__inner { display: flex; align-items: center; gap: 24px; height: 66px; }
.bnav__brand { display: flex; align-items: center; gap: 11px; text-decoration: none; margin-right: auto; }
.bnav__mark {
  width: 36px; height: 36px; border: 1.5px solid var(--accent); border-radius: 50%;
  display: grid; place-items: center; font-family: var(--font-display);
  font-size: 11px; font-weight: 700; color: var(--accent);
}
.bnav__wordmark { display: flex; flex-direction: column; line-height: 1.1; }
.bnav__name { font-family: var(--font-display); font-weight: 700; font-size: 16px; }
.bnav__sub { font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); }
.bnav__links { display: flex; gap: 22px; }
.bnav__links a {
  text-decoration: none; font-size: 13px; font-weight: 600; letter-spacing: 0.04em;
  color: var(--ink-soft); transition: color 0.15s;
}
.bnav__links a:hover, .bnav__links a[aria-current="page"] { color: var(--accent); }
.bnav__toggle { display: none; flex-direction: column; gap: 4px; width: 42px; height: 38px; border: 1px solid var(--line); border-radius: 10px; background: transparent; cursor: pointer; align-items: center; justify-content: center; }
.bnav__toggle span:not(.sr-only) { width: 18px; height: 2px; background: var(--ink); border-radius: 2px; }
.bnav__menu { display: none; }
.bnav__menu[hidden] { display: none; }
.rprogress {
  position: absolute; left: 0; bottom: -1px; width: 100%; height: 3px;
  appearance: none; border: 0; background: transparent; color: var(--accent);
}
.rprogress::-webkit-progress-bar { background: transparent; }
.rprogress::-webkit-progress-value { background: var(--accent); }
.rprogress::-moz-progress-bar { background: var(--accent); }

/* ============================================================ BREADCRUMBS */
.crumbs { border-bottom: 1px solid var(--line); background: var(--bg); }
.crumbs__list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding-top: 14px; padding-bottom: 14px; font-size: 13px; }
.crumbs__item { display: flex; align-items: center; gap: 8px; color: var(--ink-faint); }
.crumbs__item + .crumbs__item::before { content: "›"; color: var(--ink-faint); }
.crumbs__item a { color: var(--ink-soft); text-decoration: none; }
.crumbs__item a:hover { color: var(--accent); }
.crumbs__item [aria-current="page"] { color: var(--ink); font-weight: 600; }

/* ============================================================ CHIPS */
.chip {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12.5px; font-weight: 600; letter-spacing: 0.02em;
  padding: 6px 13px; border-radius: 999px; text-decoration: none;
  background: var(--chip-bg); color: var(--ink-soft); border: 1px solid var(--line);
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
a.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip .emblem { width: 15px; height: 15px; }
.chip--cat { color: var(--accent); background: var(--accent-soft); border-color: transparent; }
.chip--series { color: var(--sea); background: oklch(0.60 0.09 230 / 0.12); border-color: transparent; }
.chip--on { background: var(--accent); color: #fff; border-color: transparent; }
.chip--tag { background: transparent; }

/* ============================================================ CARDS + GRID */
.cardgrid { margin: 56px 0; }
.cardgrid__head { margin-bottom: 26px; }
.cardgrid__head h2 { font-size: clamp(24px, 3vw, 32px); }
.cardgrid__head p { color: var(--ink-soft); margin-top: 6px; }
.cardgrid__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 26px; }

.pcard {
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  box-shadow: var(--shadow-soft); transition: transform 0.18s, box-shadow 0.18s;
}
.pcard:hover { transform: translateY(-4px); box-shadow: var(--shadow-card); }
.pcard__media { display: block; aspect-ratio: 16 / 9; overflow: hidden; }
.pcard__media .art { width: 100%; height: 100%; }
.pcard__body { display: flex; flex-direction: column; gap: 11px; padding: 20px 22px 22px; }
.pcard__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.pcard__title { font-size: 20px; line-height: 1.2; }
.pcard__title a { text-decoration: none; }
.pcard__title a:hover { color: var(--accent); }
.pcard__excerpt { font-size: 14.5px; color: var(--ink-soft); line-height: 1.55; margin-top: -2px; }
.pcard__meta { margin-top: auto; font-size: 12.5px; color: var(--ink-faint); display: flex; align-items: center; gap: 8px; padding-top: 6px; }
.pcard__meta .dot { color: var(--line); }

.pcard--featured { border-color: transparent; box-shadow: var(--shadow-card); }
@media (min-width: 860px) {
  .pcard--featured { flex-direction: row; }
  .pcard--featured .pcard__media { flex: 1 1 52%; aspect-ratio: auto; }
  .pcard--featured .pcard__body { flex: 1 1 48%; justify-content: center; padding: 34px 36px; gap: 14px; }
  .pcard--featured .pcard__title { font-size: clamp(26px, 3vw, 36px); }
  .pcard--featured .pcard__excerpt { font-size: 16px; }
}

/* ============================================================ ARTICLE LAYOUT */
.post__header { padding-top: 46px; }
.post__header, .post__heromedia, .post__layout { max-width: 1140px; }
.post__chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.post__title { font-size: clamp(32px, 5vw, 54px); letter-spacing: -0.015em; max-width: 20ch; }
.post__dek { font-size: clamp(17px, 2vw, 21px); color: var(--ink-soft); line-height: 1.5; max-width: 60ch; margin-top: 16px; text-wrap: pretty; }
.post__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 20px; font-size: 13.5px; color: var(--ink-faint); }
.post__meta .dot { color: var(--line); }
.post__by { font-weight: 600; color: var(--ink-soft); }

.post__heromedia { margin: 30px auto 0; }
.figure--hero { margin: 0; }
.figure--hero .art { aspect-ratio: 21 / 8; width: 100%; border-radius: var(--radius-photo); }

.post__layout {
  margin: 40px auto 0; display: grid; gap: 52px; align-items: start;
  grid-template-columns: 250px minmax(0, 1fr);
}
.post__rail { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 22px; }
.post__body { max-width: var(--maxw-prose); }

/* ---------- prose typography ---------- */
.prose { font-size: 18px; line-height: 1.75; color: var(--ink); }
.prose > p { margin: 0 0 22px; text-wrap: pretty; }
.prose .lead { font-size: clamp(19px, 2.1vw, 23px); line-height: 1.55; color: var(--ink); margin-bottom: 28px; }
.prose__h2 { font-size: clamp(24px, 3vw, 34px); margin: 48px 0 16px; letter-spacing: -0.01em; scroll-margin-top: 92px; position: relative; }
.prose__h3 { font-size: clamp(19px, 2.2vw, 24px); margin: 34px 0 12px; scroll-margin-top: 92px; }
.prose a:not(.btn):not(.chip) { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 2.5px; text-decoration-color: oklch(0.60 0.13 45 / 0.4); }
.prose a:not(.btn):not(.chip):hover { text-decoration-color: var(--accent); }
.prose strong { font-weight: 700; }
.prose__list { margin: 0 0 22px; padding-left: 4px; list-style: none; display: grid; gap: 10px; }
.prose__list li { position: relative; padding-left: 26px; }
.prose__list li::before { content: ""; position: absolute; left: 4px; top: 11px; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.prose__list--ol { counter-reset: li; }
.prose__list--ol li::before { counter-increment: li; content: counter(li); width: auto; height: auto; top: 0; left: 0; background: none; color: var(--accent); font-family: var(--font-display); font-weight: 700; font-size: 15px; }
.anchor { position: absolute; left: -22px; color: var(--line); text-decoration: none; opacity: 0; transition: opacity 0.15s; font-weight: 400; }
.prose__h2:hover .anchor, .prose__h3:hover .anchor { opacity: 1; color: var(--accent); }
.pullquote { font-family: var(--font-display); font-size: clamp(22px, 2.6vw, 30px); line-height: 1.3; font-weight: 500; color: var(--ink); border-left: 3px solid var(--accent); padding: 6px 0 6px 24px; margin: 32px 0; }
.prose__quote { margin: 30px 0; padding: 22px 26px; background: var(--card); border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 12px; font-size: 18px; }
.prose__quote cite { display: block; margin-top: 10px; font-style: normal; font-size: 13.5px; color: var(--ink-faint); font-weight: 600; }
.rule { border: 0; border-top: 1px solid var(--line); margin: 40px 0; }
.post__tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 36px 0 8px; }

/* ---------- TOC ---------- */
.toc { border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; background: var(--card); }
.toc__title { font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 12px; }
.toc__list { list-style: none; display: grid; gap: 8px; }
.toc__list a { text-decoration: none; color: var(--ink-soft); font-size: 13.5px; line-height: 1.35; transition: color 0.15s; display: block; border-left: 2px solid transparent; padding-left: 12px; margin-left: -2px; }
.toc__list a:hover, .toc__list a.is-active { color: var(--accent); border-color: var(--accent); }
.toc__l3 { padding-left: 14px; }
.toc__l3 a { font-size: 13px; color: var(--ink-faint); }

/* ============================================================ KEY FACTS */
.keyfacts { border: 1px solid var(--accent-soft); background: var(--accent-soft); border-radius: 16px; padding: 22px 24px; margin: 0 0 30px; }
.keyfacts__title { display: flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 700; font-size: 16px; margin-bottom: 14px; color: var(--ink); }
.keyfacts__title .emblem { width: 18px; height: 18px; color: var(--accent); }
.keyfacts dl { display: grid; gap: 0; }
.keyfacts__row { display: grid; grid-template-columns: 40% 1fr; gap: 14px; padding: 10px 0; border-top: 1px solid oklch(0.60 0.13 45 / 0.18); }
.keyfacts__row:first-child { border-top: 0; }
.keyfacts__row dt { font-weight: 600; color: var(--ink-soft); font-size: 14px; }
.keyfacts__row dd { font-size: 14.5px; color: var(--ink); }

/* ============================================================ CALLOUTS */
.callout { border: 1px solid var(--line); border-left: 3px solid var(--ink-faint); border-radius: 12px; padding: 18px 22px; margin: 28px 0; background: var(--card); }
.callout__title { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 15px; margin-bottom: 8px; font-family: var(--font-display); }
.callout__title .emblem { width: 18px; height: 18px; }
.callout__body > :last-child { margin-bottom: 0; }
.callout__body p { margin: 0 0 10px; font-size: 15.5px; }
.callout--tip { border-left-color: var(--ok); background: oklch(0.60 0.11 150 / 0.07); }
.callout--tip .callout__title, .callout--tip .emblem { color: var(--ok); }
.callout--warn { border-left-color: var(--accent); background: oklch(0.60 0.13 45 / 0.07); }
.callout--warn .callout__title, .callout--warn .emblem { color: var(--accent); }
.callout--info { border-left-color: var(--sea); background: oklch(0.60 0.09 230 / 0.08); }
.callout--info .callout__title, .callout--info .emblem { color: var(--sea); }
.callout--key { border-left-color: var(--sun); background: oklch(0.72 0.15 65 / 0.10); }
.callout--key .callout__title, .callout--key .emblem { color: var(--sun); }
.callout--note { border-left-color: var(--ink-faint); }

/* ============================================================ TABLES */
.tablewrap { overflow-x: auto; margin: 28px 0; border: 1px solid var(--line); border-radius: 14px; }
.data-table { width: 100%; border-collapse: collapse; font-size: 14.5px; min-width: 460px; }
.data-table caption { text-align: left; padding: 14px 18px 0; font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-faint); }
.data-table th, .data-table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.data-table thead th { background: var(--bg-sand); font-family: var(--font-display); font-weight: 700; font-size: 13px; color: var(--ink); border-bottom: 2px solid var(--line); }
.data-table tbody tr:last-child td, .data-table tbody tr:last-child th { border-bottom: 0; }
.data-table tbody tr:nth-child(even) { background: oklch(0.97 0.012 85 / 0.5); }
.ta-center { text-align: center !important; }
.ta-right { text-align: right !important; }
.table__src { font-size: 12px; color: var(--ink-faint); padding: 4px 4px 0; }

/* ============================================================ STEPS (HowTo) */
.steps { list-style: none; counter-reset: step; display: grid; gap: 16px; margin: 28px 0; padding: 0; }
.steps__item { display: grid; grid-template-columns: 40px 1fr; gap: 16px; align-items: start; }
.steps__n { width: 40px; height: 40px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; }
.steps__title { font-weight: 700; margin-bottom: 4px; }
.steps__text p { margin: 0; font-size: 15.5px; color: var(--ink-soft); }

/* ============================================================ STAT GRID */
.statgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin: 28px 0; }
.stat { border: 1px solid var(--line); border-radius: 14px; padding: 20px; background: var(--card); text-align: center; }
.stat__ico { display: block; margin: 0 auto 8px; color: var(--accent); }
.stat__ico .emblem { width: 22px; height: 22px; }
.stat__value { display: block; font-family: var(--font-display); font-weight: 700; font-size: clamp(26px, 4vw, 36px); color: var(--ink); line-height: 1; }
.stat__label { display: block; font-size: 13px; color: var(--ink-faint); margin-top: 6px; }

/* ============================================================ LINK LIST */
.linklist { margin: 26px 0; }
.linklist__title { font-family: var(--font-display); font-weight: 700; font-size: 16px; margin-bottom: 12px; }
.linklist ul { list-style: none; display: grid; gap: 2px; }
.linklist__item a { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; text-decoration: none; padding: 12px 14px; border-radius: 10px; transition: background 0.15s; }
.linklist__item a:hover { background: var(--accent-soft); }
.linklist__t { font-weight: 600; color: var(--accent); }
.linklist__note { font-size: 14px; color: var(--ink-faint); }

/* ============================================================ NEARBY BUSINESSES */
.bizlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; margin: 28px 0; }
.biz { border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; background: var(--card); box-shadow: var(--shadow-soft); }
.biz__head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.biz__name { font-size: 17px; }
.biz__name a { text-decoration: none; }
.biz__name a:hover { color: var(--accent); }
.biz__price { font-family: var(--font-display); font-weight: 700; color: var(--ok); font-size: 14px; white-space: nowrap; }
.biz__meta { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--ink-faint); margin: 6px 0 10px; }
.biz__meta .emblem { width: 15px; height: 15px; color: var(--accent); }
.biz__why { font-size: 14.5px; color: var(--ink-soft); line-height: 1.5; }

/* ============================================================ FAQ */
.faq { margin: 40px 0; }
.faq__item { border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; background: var(--card); overflow: hidden; }
.faq__item summary { cursor: pointer; padding: 16px 20px; font-weight: 600; font-size: 16px; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: "+"; font-family: var(--font-display); font-size: 22px; color: var(--accent); line-height: 1; }
.faq__item[open] summary::after { content: "−"; }
.faq__a { padding: 0 20px 18px; color: var(--ink-soft); font-size: 15.5px; }
.faq__a p { margin: 0; }

/* ============================================================ FIGURES + CHARTS */
.figure { margin: 30px 0; }
.figure figcaption { font-size: 13px; color: var(--ink-faint); margin-top: 10px; text-align: center; }
.figure__src { display: block; font-style: normal; font-size: 12px; opacity: 0.85; margin-top: 2px; }
.figure--chart { border: 1px solid var(--line); border-radius: 16px; padding: 22px 22px 16px; background: var(--card); }
.figure__art .art { width: 100%; aspect-ratio: 16/7; border-radius: var(--radius-photo); }

.chart__svg { width: 100%; height: auto; display: block; font-family: var(--font-body); }
.chart__svg--donut { max-width: 300px; }
.chart__grid { stroke: var(--line); stroke-width: 1; }
.chart__tick, .chart__axis { fill: var(--ink-faint); font-size: 12px; }
.chart__val { fill: var(--ink-soft); font-size: 12px; font-weight: 600; font-family: var(--font-display); }
.chart__rowlabel { fill: var(--ink); font-size: 13.5px; font-weight: 600; }
.chart__track { fill: var(--bg-sand); }
.chart__line { fill: none !important; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.chart__area { opacity: 0.14; stroke: none; }
.chart__dot { stroke: var(--card); stroke-width: 1.5; }
.chart__center { fill: var(--ink); font-family: var(--font-display); font-weight: 700; font-size: 30px; }
.chart__centersub { fill: var(--ink-faint); font-size: 12px; }
.chart__slice { stroke: var(--card); stroke-width: 2; }
.chart__donutwrap { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; justify-content: center; }
.chart__legend { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0 0 14px; padding: 0; }
.chart__key { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-soft); }
.chart__swatch { width: 13px; height: 13px; border-radius: 4px; display: inline-block; }

/* combined fill + background so one class colours SVG shapes and HTML swatches */
.c-sun { fill: var(--c-sun); background: var(--c-sun); }
.c-sea { fill: var(--c-sea); background: var(--c-sea); }
.c-temp { fill: var(--c-temp); background: var(--c-temp); }
.c-rain { fill: var(--c-rain); background: var(--c-rain); }
.c-1 { fill: var(--c-1); background: var(--c-1); }
.c-2 { fill: var(--c-2); background: var(--c-2); }
.c-3 { fill: var(--c-3); background: var(--c-3); }
.c-4 { fill: var(--c-4); background: var(--c-4); }
.c-5 { fill: var(--c-5); background: var(--c-5); }
.c-6 { fill: var(--c-6); background: var(--c-6); }
.c-direct { fill: var(--c-direct); background: var(--c-direct); }
.c-ota { fill: var(--c-ota); background: var(--c-ota); }
.chart__line.c-sea { stroke: var(--c-sea); }
.chart__line.c-sun { stroke: var(--c-sun); }
.chart__line.c-1 { stroke: var(--c-1); }

/* ============================================================ CTA + BOOK CARD */
.ctaband { background: oklch(0.27 0.025 55); color: oklch(0.95 0.015 80); margin: 64px 0 0; padding: 56px 0; }
.ctaband__inner { display: grid; grid-template-columns: 1.4fr auto; gap: 32px; align-items: center; }
.ctaband__kicker { font-size: 12px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: oklch(0.82 0.08 65); margin-bottom: 12px; }
.ctaband h2 { font-size: clamp(24px, 3.2vw, 36px); color: #fff; margin-bottom: 12px; }
.ctaband__text p:last-child { color: oklch(0.86 0.02 80); max-width: 56ch; }
.ctaband__actions { display: flex; flex-direction: column; gap: 12px; }
.ctaband .btn--ghost { border-color: oklch(1 0 0 / 0.3); color: #fff; }
.ctaband .btn--ghost:hover { border-color: #fff; background: oklch(1 0 0 / 0.08); }

.cta-inline { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; background: var(--accent-soft); border: 1px solid transparent; border-radius: 16px; padding: 22px 26px; margin: 32px 0; }
.cta-inline__title { font-family: var(--font-display); font-weight: 700; font-size: 18px; margin-bottom: 4px; }
.cta-inline p { margin: 0; font-size: 15px; color: var(--ink-soft); max-width: 50ch; }

.bookcard { border: 1px solid var(--line); border-radius: 16px; padding: 22px; background: var(--card); box-shadow: var(--shadow-soft); }
.bookcard__kicker { font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.bookcard__title { font-family: var(--font-display); font-weight: 700; font-size: 18px; margin-bottom: 14px; }
.bookcard__facts { list-style: none; display: grid; gap: 10px; margin-bottom: 18px; }
.bookcard__facts li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--ink-soft); }
.bookcard__facts .emblem { width: 17px; height: 17px; color: var(--accent); flex: none; }
.bookcard__btn { width: 100%; }
.bookcard__note { font-size: 12px; color: var(--ink-faint); text-align: center; margin-top: 10px; }

/* ============================================================ AUTHOR + SERIES NAV */
.authorbox { display: flex; gap: 18px; align-items: flex-start; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 26px 0; margin: 40px 0; }
.authorbox__avatar { width: 52px; height: 52px; flex: none; border-radius: 50%; background: var(--accent-soft); display: grid; place-items: center; color: var(--accent); }
.authorbox__avatar .emblem { width: 24px; height: 24px; }
.authorbox__name { font-family: var(--font-display); font-weight: 700; font-size: 17px; }
.authorbox__role { font-size: 13px; color: var(--ink-faint); margin-bottom: 8px; }
.authorbox__bio { font-size: 14.5px; color: var(--ink-soft); }

.seriesrail { border: 1px solid var(--line); border-radius: 16px; padding: 20px; background: var(--card); }
.seriesrail__kicker { display: flex; align-items: center; gap: 7px; font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--sea); margin-bottom: 6px; }
.seriesrail__kicker .emblem { width: 15px; height: 15px; }
.seriesrail__title { font-family: var(--font-display); font-weight: 700; font-size: 16px; margin-bottom: 14px; }
.seriesrail__title a { text-decoration: none; }
.seriesrail__list { list-style: none; display: grid; gap: 4px; counter-reset: sr; }
.seriesrail__item a, .seriesrail__item.is-current { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 10px; text-decoration: none; font-size: 14px; color: var(--ink-soft); }
.seriesrail__item a:hover { background: var(--accent-soft); }
.seriesrail__n { width: 24px; height: 24px; flex: none; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-size: 12px; font-weight: 700; font-family: var(--font-display); }
.seriesrail__item.is-current { background: var(--accent-soft); color: var(--ink); font-weight: 600; }
.seriesrail__item.is-current .seriesrail__n { background: var(--accent); color: #fff; border-color: transparent; }

.seriesnav { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 36px 0; }
.seriesnav__link { border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; text-decoration: none; display: flex; flex-direction: column; gap: 4px; background: var(--card); transition: border-color 0.15s; }
.seriesnav__link:hover { border-color: var(--accent); }
.seriesnav__link--next { text-align: right; }
.seriesnav__dir { font-size: 12px; color: var(--ink-faint); font-weight: 600; }
.seriesnav__t { font-family: var(--font-display); font-weight: 600; color: var(--ink); }
.seriesnav__link.is-empty { border: 0; background: none; }

/* ============================================================ SHARE */
.share { display: flex; align-items: center; gap: 10px; margin-top: 24px; flex-wrap: wrap; }
.share__label { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-faint); }
.share__btn { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--ink-soft); font-size: 13px; font-weight: 600; text-decoration: none; cursor: pointer; transition: border-color 0.15s, color 0.15s; }
.share__btn:hover { border-color: var(--accent); color: var(--accent); }

/* ============================================================ HERO / HOME / HUB */
.home__hero, .hub__hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.home__heroart, .hub__heroart { position: absolute; inset: 0; opacity: 0.9; }
.home__heroart .art, .hub__heroart .art { width: 100%; height: 100%; }
.home__hero::after, .hub__hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, var(--bg) 6%, oklch(0.972 0.013 85 / 0.5) 45%, oklch(0.972 0.013 85 / 0.15)); }
.home__herotext, .hub__herotext { position: relative; z-index: 1; padding: clamp(60px, 12vw, 130px) 28px clamp(34px, 6vw, 60px); }
.home__kicker, .hub__kicker { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 16px; }
.home__kicker .emblem, .hub__kicker .emblem { width: 17px; height: 17px; }
.home__herotext h1, .hub__herotext h1 { font-size: clamp(38px, 7vw, 76px); letter-spacing: -0.02em; max-width: 16ch; }
.home__lede, .hub__lede { font-size: clamp(17px, 2.1vw, 21px); color: var(--ink-soft); max-width: 60ch; margin-top: 18px; text-wrap: pretty; }
.home__cats, .hub__chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.home__body, .hub__body { padding-top: 24px; padding-bottom: 8px; }
.home__featured { margin-top: 40px; }
.home__series, .hub__series { margin: 56px 0; }
.home__series .cardgrid__head, .hub__series { margin-bottom: 24px; }
.hub__series h2 { font-size: clamp(22px, 3vw, 30px); margin-bottom: 22px; }
.home__all { text-align: center; margin: 20px 0 10px; }
.archive__head { padding-top: 48px; }
.archive__head h1 { font-size: clamp(34px, 5vw, 56px); }
.pcard--series .pcard__excerpt { color: var(--ink-soft); }

.serieslist { list-style: none; counter-reset: sl; display: grid; gap: 10px; margin: 8px 0 20px; max-width: var(--maxw-prose); }
.serieslist__item a { display: flex; align-items: center; gap: 16px; padding: 16px 20px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); text-decoration: none; transition: border-color 0.15s, transform 0.15s; }
.serieslist__item a:hover { border-color: var(--accent); transform: translateX(3px); }
.serieslist__n { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); white-space: nowrap; }
.serieslist__t { font-family: var(--font-display); font-weight: 600; font-size: 17px; }
.about__prose { max-width: var(--maxw-prose); padding-top: 8px; }

/* ============================================================ FOOTER */
.bfooter { background: oklch(0.24 0.022 55); color: oklch(0.86 0.02 80); padding: 64px 0 40px; margin-top: 0; }
.bfooter__top { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid oklch(1 0 0 / 0.12); }
.bfooter__brand .footer__mark { margin: 0 0 18px; }
.bfooter__tag { font-family: var(--font-display); font-size: 18px; color: oklch(0.92 0.02 80); margin-bottom: 18px; max-width: 30ch; }
.bfooter__col h3 { font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: oklch(0.72 0.03 70); margin-bottom: 14px; }
.bfooter__col ul { list-style: none; display: grid; gap: 9px; }
.bfooter__col a { color: oklch(0.86 0.02 80); text-decoration: none; font-size: 14px; }
.bfooter__col a:hover { color: oklch(0.85 0.07 65); }
.bfooter__meta { font-size: 13.5px; color: oklch(0.7 0.02 70); line-height: 1.7; padding-top: 26px; }
.bfooter__meta a { color: oklch(0.85 0.07 65); }
.bfooter__copy { font-size: 12.5px; color: oklch(0.6 0.02 70); margin-top: 14px; }
.bfooter__copy a { color: oklch(0.78 0.04 70); }

/* ============================================================ ART (SVG scenes) */
.art-sky-0 { stop-color: oklch(0.86 0.06 230); }
.art-sky-1 { stop-color: oklch(0.95 0.03 88); }
.art-sun-0 { stop-color: oklch(0.96 0.08 88); }
.art-sun-1 { stop-color: oklch(0.80 0.14 62); }
.art-sea-0 { stop-color: oklch(0.66 0.09 225); }
.art-sea-1 { stop-color: oklch(0.52 0.10 236); }
.art-rock { fill: oklch(0.50 0.03 60); }
.art-rock-far { fill: oklch(0.63 0.03 72); }
.art-bird { stroke: oklch(0.34 0.02 60); stroke-width: 2; opacity: 0.5; }
.art-wave-1 { fill: oklch(0.74 0.07 220 / 0.5); }
.art-wave-2 { fill: oklch(0.64 0.09 226 / 0.5); }
.art-wave-3 { fill: oklch(0.55 0.10 234 / 0.6); }
.art-sail { fill: oklch(0.98 0.01 90); }
.art-sail-2 { fill: oklch(0.90 0.03 80); }
.art-hull { fill: oklch(0.34 0.03 55); }
.art--marina .art-sea-1 { stop-color: oklch(0.47 0.11 240); }
.art--dining .art-sky-1 { stop-color: oklch(0.93 0.06 72); }
.art--dining .art-sun-1 { stop-color: oklch(0.72 0.15 48); }
.art--rock .art-rock { fill: oklch(0.46 0.03 55); }
.art--sea .art-rock, .art--sea .art-rock-far { opacity: 0.25; }
.emblem { width: 1.15em; height: 1.15em; stroke: currentColor; stroke-width: 1.7; fill: none; stroke-linecap: round; stroke-linejoin: round; vertical-align: -0.15em; }

/* ============================================================ RESPONSIVE */
@media (max-width: 980px) {
  .bnav__links, .bnav__cta { display: none; }
  .bnav__toggle { display: flex; }
  .bnav__menu { display: block; }
  .bnav__menu:not([hidden]) { display: flex; flex-direction: column; gap: 4px; padding: 14px 28px 20px; border-top: 1px solid var(--line); background: var(--bg); }
  .bnav__menu a { text-decoration: none; color: var(--ink); padding: 10px 0; font-weight: 600; border-bottom: 1px solid var(--line); }
  .bnav__menu a:last-of-type { border-bottom: 0; }
  .post__layout { grid-template-columns: 1fr; gap: 8px; }
  .post__rail { position: static; order: 2; margin-top: 30px; }
  .toc { display: none; }
  .ctaband__inner { grid-template-columns: 1fr; gap: 22px; }
  .ctaband__actions { flex-direction: row; flex-wrap: wrap; }
  .bfooter__top { grid-template-columns: 1fr 1fr; gap: 28px; }
}
@media (max-width: 560px) {
  .bfooter__top { grid-template-columns: 1fr; }
  .seriesnav { grid-template-columns: 1fr; }
  .keyfacts__row { grid-template-columns: 1fr; gap: 2px; }
}
@media (prefers-reduced-motion: reduce) {
  .pcard, .serieslist__item a { transition: none; }
}
