/* Gavin Oakes — brand stylesheet
   Colour = state of mind: Peat (grounded) · Mist (clear) · Lough (recovery) · Ember (effort) · Dawn (growth) */

:root {
  --peat: #16201C;
  --peat-2: #1F2B26;
  --peat-line: #34413B;
  --mist: #ECEFEA;
  --paper: #FFFFFF;
  --lough: #2F6F6A;
  --lough-light: #8FC1BB;
  --ember: #E8572A;
  --dawn: #F2C14E;
  --ink-soft: #33403A;
  --ink-muted: #4A5650;
  --on-dark-soft: #D3DAD5;
  --on-dark-muted: #A9B5AD;
  --line: #D5DBD6;

  --display: "Bricolage Grotesque", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;

  --wrap: 1240px;
  --gutter: 24px;
  --radius: 20px;
  --ease-settle: cubic-bezier(.2,.7,.2,1);
  --ease-travel: cubic-bezier(.65,0,.35,1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--mist);
  color: var(--peat);
  font-family: var(--display);
  font-size: 18px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--lough); text-underline-offset: 3px; }
a:hover { color: var(--ember); }
:focus-visible { outline: 2px solid var(--ember); outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--ember); color: var(--peat); padding: 10px 16px; border-radius: 999px; z-index: 50; }
.skip:focus { left: 16px; }

/* ---------- type ---------- */
.mono { font-family: var(--mono); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; }
.label { color: var(--ink-muted); }
.dark .label, .on-dark .label { color: var(--on-dark-muted); }
h1, h2, h3 { margin: 0; font-weight: 800; letter-spacing: -.035em; line-height: 1; }
.h-hero { font-size: clamp(56px, 10vw, 140px); line-height: .9; letter-spacing: -.045em; }
.h-section { font-size: clamp(36px, 5.2vw, 68px); }
.h-card { font-size: clamp(24px, 2.4vw, 30px); line-height: 1.1; letter-spacing: -.02em; }
.lede { font-size: clamp(19px, 2vw, 24px); line-height: 1.45; }
.ember { color: var(--ember); }

/* ---------- surfaces ---------- */
.dark { background: var(--peat); color: var(--mist); }
.dark a { color: var(--mist); }
.dark a:hover { color: var(--ember); }
.teal { background: var(--lough); color: var(--mist); }
.white { background: var(--paper); }
.section { padding: clamp(80px, 11vw, 136px) 0; }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(22,32,28,.92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: var(--mist); }
.nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--mist); min-height: 44px; }
.brand:hover { color: var(--mist); }
.brand span { font-size: 20px; font-weight: 800; letter-spacing: -.02em; }
.brand svg { width: 34px; height: 34px; transition: transform .6s var(--ease-travel); }
.brand:hover svg { transform: rotate(-20deg); }
.nav-links { display: flex; flex-wrap: wrap; gap: 0 22px; }
.nav-links a { font-family: var(--mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; color: var(--mist); padding: 12px 0; position: relative; }
.nav-links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 6px; height: 2px; background: var(--ember); transform: scaleX(0); transform-origin: left; transition: transform .4s var(--ease-travel); }
.nav-links a:hover::after, .nav-links a[aria-current="page"]::after { transform: scaleX(1); }
.nav-links a:hover { color: var(--mist); }
.nav-links .cta { color: var(--ember); }

/* ---------- buttons ---------- */
.btns { display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 12px 24px; border-radius: 999px; font-weight: 600; font-size: 17px; text-decoration: none; transition: transform .3s var(--ease-settle), background .3s; }
.btn:hover { transform: translateY(-2px); }
.btn-ember { background: var(--ember); color: var(--peat) !important; }
.btn-ghost { box-shadow: inset 0 0 0 1.5px #4C5A53; color: var(--mist); }
.btn-ghost-light { box-shadow: inset 0 0 0 1.5px #B9C3BC; color: var(--peat); }
.link-arrow { font-weight: 600; text-decoration: none; display: inline-flex; gap: 8px; padding: 10px 0; }
.link-arrow span { transition: transform .4s var(--ease-travel); }
.link-arrow:hover span { transform: translateX(6px); }

/* ---------- hero ---------- */
.hero { display: flex; flex-wrap: wrap; align-items: center; gap: 48px; padding-top: clamp(48px, 7vw, 88px); padding-bottom: clamp(56px, 8vw, 96px); }
.hero-copy { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 28px; }
.hero-copy .lede { color: var(--on-dark-soft); max-width: 600px; margin: 0; }
.hero-mark { flex: 1 1 300px; display: flex; flex-direction: column; align-items: center; gap: 20px; }
.hero-mark svg { width: min(300px, 70vw); height: auto; }
.breath-cue { display: grid; color: var(--lough-light); text-align: center; }
.breath-cue span { grid-area: 1 / 1; }

@keyframes breathe { 0%,100% { transform: scale(.86); } 50% { transform: scale(1); } }
@keyframes inhale { 0%,45% { opacity: 1; } 50%,95% { opacity: 0; } 100% { opacity: 1; } }
@keyframes exhale { 0%,45% { opacity: 0; } 50%,95% { opacity: 1; } 100% { opacity: 0; } }
.breathe { animation: breathe 8s ease-in-out infinite; transform-origin: 50% 50%; }
.inhale { animation: inhale 8s ease-in-out infinite; }
.exhale { animation: exhale 8s ease-in-out infinite; }

/* ---------- photo treatment: duotone + grain, colour on hover ---------- */
.photo { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--tint, var(--mist)); isolation: isolate; }
.photo img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.15); mix-blend-mode: multiply; transition: filter .8s var(--ease-settle), transform 1.2s var(--ease-settle), mix-blend-mode .8s; }
.photo::after { content: ""; position: absolute; inset: 0; background: var(--shade, var(--peat)); mix-blend-mode: lighten; pointer-events: none; transition: opacity .8s var(--ease-settle); }
.photo::before { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; opacity: .22; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"); }
.photo:hover img, a:focus-visible .photo img, .card:hover .photo img { filter: none; mix-blend-mode: normal; transform: scale(1.04); }
.photo:hover::after, .card:hover .photo::after { opacity: 0; }
.tint-mist { --tint: #E4ECE6; --shade: var(--peat); }
.tint-ember { --tint: #F6A27F; --shade: #3A1A0E; }
.tint-lough { --tint: #A9D3CD; --shade: #0F2A27; }
.tint-dawn { --tint: #F7D888; --shade: #2E2410; }
.photo-tag { position: absolute; z-index: 3; left: 16px; bottom: 16px; right: 16px; display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; pointer-events: none; }
.chip { display: inline-flex; align-items: center; gap: 8px; background: rgba(22,32,28,.82); color: var(--mist); padding: 7px 12px 7px 9px; border-radius: 999px; font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; backdrop-filter: blur(6px); }
.chip svg { width: 18px; height: 18px; }

/* ---------- film strip marquee ---------- */
.strip { overflow: hidden; padding: 28px 0; border-top: 1px solid var(--peat-line); }
.strip-track { display: flex; gap: 16px; width: max-content; animation: drift 70s linear infinite; }
.strip:hover .strip-track { animation-play-state: paused; }
.strip .photo { width: clamp(180px, 22vw, 280px); aspect-ratio: 4 / 5; flex-shrink: 0; border-radius: 14px; }
.strip .photo:nth-child(odd) { transform: rotate(-1.5deg); }
.strip .photo:nth-child(even) { transform: rotate(1.5deg) translateY(10px); }
@keyframes drift { to { transform: translateX(-50%); } }

/* ---------- layout helpers ---------- */
.split { display: flex; flex-wrap: wrap; gap: 32px 48px; }
.split > .side { flex: 1 1 260px; }
.split > .main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.head-row { display: flex; flex-wrap: wrap; gap: 20px 32px; justify-content: space-between; align-items: flex-end; margin-bottom: 48px; }
.head-row > div { display: flex; flex-direction: column; gap: 16px; max-width: 760px; }
.head-row p { margin: 0; max-width: 430px; }
.prose p { margin: 0 0 1.1em; font-size: 20px; line-height: 1.6; color: var(--ink-soft); max-width: 720px; }
.prose p:last-child { margin-bottom: 0; }

/* ---------- pillars ---------- */
.pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.pillar { background: var(--mist); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; gap: 40px; transition: transform .5s var(--ease-settle); }
.pillar:hover { transform: translateY(-4px); }
.pillar svg { width: 40px; height: 40px; }
.pillar h3 { font-size: 26px; letter-spacing: -.02em; margin-bottom: 8px; }
.pillar p { margin: 0; font-size: 16px; line-height: 1.5; color: var(--ink-muted); }
.pillar.is-dark { background: var(--peat); color: var(--mist); }
.pillar.is-dark p { color: var(--on-dark-soft); }

/* ---------- notes grid (mind) ---------- */
.notes { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1px; background: #4F8984; border-radius: var(--radius); overflow: hidden; }
.note { background: var(--lough); padding: 32px; display: flex; flex-direction: column; gap: 48px; justify-content: space-between; text-decoration: none; color: var(--mist); transition: background .4s; }
.note:hover { background: #2A6560; color: var(--mist); }
.note .mono { color: var(--dawn); font-size: 12px; }
.note h3 { font-size: 26px; line-height: 1.15; font-weight: 600; letter-spacing: -.015em; }

/* ---------- journal cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 40px 24px; }
.card { display: flex; flex-direction: column; gap: 16px; text-decoration: none; color: var(--peat); }
.card:hover { color: var(--peat); }
.card .photo { aspect-ratio: 4 / 3; }
.card .meta { color: var(--ink-muted); font-size: 12px; }
.card p { margin: 0; font-size: 17px; line-height: 1.5; color: var(--ink-muted); }
.card h3 { transition: color .3s; }
.card:hover h3 { color: var(--ember); }
.card.feature { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px 48px; align-items: center; }
.card.feature .photo { aspect-ratio: 16 / 10; }
.card.feature .h-card { font-size: clamp(32px, 4vw, 52px); }
.card.feature .body { display: flex; flex-direction: column; gap: 16px; }

.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 40px; }
.filter { appearance: none; border: 0; cursor: pointer; font: inherit; font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; min-height: 44px; padding: 10px 16px; border-radius: 999px; background: var(--paper); color: var(--peat); box-shadow: inset 0 0 0 1px var(--line); display: inline-flex; align-items: center; gap: 8px; transition: background .3s, color .3s; }
.filter svg { width: 16px; height: 16px; }
.filter[aria-pressed="true"] { background: var(--peat); color: var(--mist); box-shadow: none; }
.card[hidden] { display: none; }

.next-chapter { border-radius: var(--radius); box-shadow: inset 0 0 0 1.5px #C9D1CB; padding: 28px; display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; margin-top: 48px; }
.next-chapter > div { display: flex; align-items: center; gap: 16px; font-size: 20px; font-weight: 600; }

/* ---------- story page ---------- */
.portrait-stack { position: relative; aspect-ratio: 4 / 5; max-width: 460px; width: 100%; }
.portrait-stack .photo { position: absolute; inset: 0; }
.portrait-stack .behind { transform: rotate(-5deg) translate(-14px, 10px); background: var(--ember); border-radius: var(--radius); position: absolute; inset: 0; }
.portrait-stack .behind-2 { transform: rotate(4deg) translate(12px, 6px); background: var(--lough); border-radius: var(--radius); position: absolute; inset: 0; }
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; border-top: 1px solid var(--line); }
.timeline li { display: grid; grid-template-columns: minmax(90px, 160px) 1fr; gap: 16px 32px; padding: 24px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.timeline .when { color: var(--ember); }
.timeline .what { font-size: 22px; font-weight: 600; letter-spacing: -.01em; line-height: 1.3; }
.timeline .what small { display: block; font-size: 16px; font-weight: 400; color: var(--ink-muted); margin-top: 4px; letter-spacing: 0; }

/* ---------- mind articles ---------- */
.article { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; padding: 72px 0; border-top: 1px solid rgba(236,239,234,.18); }
.article:first-of-type { border-top: 0; padding-top: 0; }
.article .when { color: var(--dawn); }
.article h2 { font-size: clamp(34px, 4.6vw, 60px); }
.article p { margin: 0 0 1em; font-size: 20px; line-height: 1.6; color: #E2ECEA; max-width: 700px; }
.article ul { margin: 0 0 1.2em; padding: 0; list-style: none; display: grid; gap: 10px; max-width: 700px; }
.article li { font-size: 20px; line-height: 1.45; padding-left: 34px; position: relative; color: #E2ECEA; }
.article li::before { content: ""; position: absolute; left: 0; top: .5em; width: 18px; height: 2px; background: var(--ember); }
.article .pull { font-size: clamp(26px, 3vw, 36px); line-height: 1.2; font-weight: 600; letter-spacing: -.02em; color: var(--mist); max-width: 760px; padding-left: 24px; border-left: 3px solid var(--dawn); margin: 8px 0 24px; }
.article .then-now { display: inline-flex; gap: 10px; align-items: center; color: var(--lough-light); }

/* ---------- footer ---------- */
.site-footer { padding: clamp(88px, 11vw, 120px) 0 40px; }
.footer-top { display: flex; flex-wrap: wrap; gap: 32px; justify-content: space-between; align-items: flex-end; margin-bottom: 72px; }
.footer-top h2 { font-size: clamp(48px, 8vw, 112px); line-height: .9; letter-spacing: -.045em; }
.footer-top .cta { display: flex; flex-direction: column; gap: 16px; max-width: 380px; }
.footer-top p { margin: 0; color: var(--on-dark-soft); }
.footer-bottom { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; border-top: 1px solid var(--peat-line); padding-top: 24px; color: var(--on-dark-muted); font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.footer-bottom a { color: var(--on-dark-muted); text-decoration: none; }

/* ---------- reveal on scroll (only when JS runs) ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease-settle), transform .6s var(--ease-settle); transition-delay: var(--d, 0ms); }
.js .reveal.is-in { opacity: 1; transform: none; }

@media (max-width: 640px) {
  body { font-size: 17px; }
  .timeline li { grid-template-columns: 1fr; gap: 6px; }
  .strip .photo:nth-child(even) { transform: rotate(1.5deg); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .breathe, .inhale, .strip-track { animation: none; }
  .exhale { animation: none; opacity: 0; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .strip { overflow-x: auto; }
  * { transition-duration: 0s !important; }
}

/* ---------- journal post pages ---------- */
.progress { position: fixed; left: 0; top: 0; height: 3px; width: 100%; background: var(--ember); transform-origin: 0 50%; transform: scaleX(0); z-index: 30; }

.post-hero { padding-top: clamp(40px, 6vw, 80px); }
.post-hero-inner { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; padding-bottom: clamp(36px, 5vw, 56px); }
.post-hero .back { color: var(--on-dark-muted); font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; text-decoration: none; justify-self: start; padding: 10px 0; }
.post-hero .back:hover { color: var(--ember); }
.post-kicker { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; color: var(--on-dark-muted); font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; }
.post-kicker .chip { background: transparent; box-shadow: inset 0 0 0 1px #4C5A53; color: var(--ember); }
.post-title { font-size: clamp(46px, 8vw, 116px); line-height: .9; letter-spacing: -.05em; max-width: 14ch; text-wrap: balance; }
.post-dek { margin: 0; color: var(--on-dark-soft); max-width: 46ch; font-size: clamp(19px, 1.9vw, 24px); line-height: 1.45; text-wrap: pretty; }

.post-cover-wrap { position: relative; }
.post-cover-wrap::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 50%; background: var(--mist); }
.post-cover { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; aspect-ratio: 16 / 9; background: var(--peat-2); box-shadow: 0 30px 60px -30px rgba(0,0,0,.45); }
.post-cover img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; display: block; }

/* two-column reading layout: meta rail + text */
.post-layout { display: grid; grid-template-columns: minmax(180px, 220px) minmax(0, 680px); justify-content: center; gap: 0 clamp(32px, 6vw, 96px); padding-top: clamp(56px, 7vw, 96px); padding-bottom: clamp(56px, 7vw, 96px); }
.post-rail { position: relative; }
.post-rail-inner { position: sticky; top: 96px; display: flex; flex-direction: column; gap: 22px; padding-top: 6px; }
.rail-item { display: flex; flex-direction: column; gap: 4px; border-top: 1px solid var(--line); padding-top: 12px; }
.rail-item .mono { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-muted); }
.rail-item strong { font-weight: 600; font-size: 16px; letter-spacing: -.01em; }
.rail-item .lens { display: inline-flex; align-items: center; gap: 8px; color: var(--ember); font-weight: 600; }
.series-dots { display: flex; gap: 6px; flex-wrap: wrap; }
.series-dots a { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; text-decoration: none; font-family: var(--mono); font-size: 13px; color: var(--peat); box-shadow: inset 0 0 0 1px var(--line); background: var(--paper); transition: background .3s, color .3s, box-shadow .3s; }
.series-dots a:hover { box-shadow: inset 0 0 0 1.5px var(--ember); color: var(--peat); }
.series-dots a.on { background: var(--peat); color: var(--mist); box-shadow: none; }
@media (max-width: 900px) {
  .post-layout { grid-template-columns: minmax(0, 1fr); }
  .post-rail-inner { position: static; flex-direction: row; flex-wrap: wrap; gap: 12px 28px; margin-bottom: 40px; }
  .rail-item { border-top: 0; padding-top: 0; }
}

.post-body { min-width: 0; }
.post-body > p { font-size: 19px; line-height: 1.75; color: var(--ink-soft); margin: 0 0 1.15em; text-wrap: pretty; }
.post-body > p.lead { font-size: clamp(21px, 2vw, 24px); line-height: 1.55; color: var(--peat); }
.post-body > p.lead::first-letter { float: left; font-size: 3.4em; line-height: .82; font-weight: 800; margin: .06em .1em 0 0; color: var(--ember); }
.post-body a { color: var(--lough); overflow-wrap: anywhere; text-decoration-thickness: 1px; }
.post-body a:hover { color: var(--ember); }
.post-h { font-size: clamp(26px, 2.8vw, 34px); letter-spacing: -.03em; line-height: 1.1; margin: 2.2em 0 .7em; display: flex; align-items: center; gap: 14px; }
.post-h::before { content: ""; width: 22px; height: 3px; border-radius: 2px; background: var(--ember); flex-shrink: 0; }

.post-quote { margin: 0 0 2.6em; padding: 0; }
.post-quote p { font-size: clamp(26px, 3vw, 38px); line-height: 1.2; font-weight: 600; letter-spacing: -.025em; color: var(--peat); margin: 0 0 .6em; text-wrap: balance; }
.post-quote p::before { content: "“"; display: block; font-size: 2.2em; line-height: .6; color: var(--ember); font-weight: 800; margin-bottom: .1em; }
.post-quote cite { font-style: normal; font-family: var(--mono); color: var(--ink-muted); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.post-quote cite::before { content: "— "; }

.post-body .pull { margin: 1.8em 0 2em; padding: 4px 0 4px 24px; border-left: 3px solid var(--dawn); font-size: clamp(23px, 2.6vw, 30px); line-height: 1.3; font-weight: 600; letter-spacing: -.02em; color: var(--peat); text-wrap: balance; }

.event { background: var(--paper); border-radius: 16px; box-shadow: inset 0 0 0 1px var(--line); padding: 8px 20px; margin: 0 0 1.6em; }
.event div { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 16px; line-height: 1.45; }
.event div:last-child { border-bottom: 0; }
.event .mono { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-muted); padding-top: 3px; }

/* photos: never stretched, never awkwardly cropped */
.gallery { margin: 2.4em 0 2.6em; }
.g-item { margin: 0; break-inside: avoid; }
.g-item button { appearance: none; border: 0; padding: 0; background: var(--line); display: block; width: 100%; border-radius: 14px; overflow: hidden; cursor: zoom-in; }
.g-item img { display: block; width: 100%; height: auto; transition: transform 1.2s var(--ease-settle), filter .6s; }
.g-item button:hover img { transform: scale(1.025); }
.g-item figcaption { font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-muted); padding: 10px 2px 0; }
.gallery.n1 .g-item img { max-height: 82vh; object-fit: contain; background: var(--peat); }
.gallery.n1 .g-item.tall { max-width: 520px; margin: 0 auto; }
.gallery.n2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }
.gallery.many { columns: 2; column-gap: 12px; }
.gallery.many .g-item { margin-bottom: 12px; }
@media (min-width: 1100px) {
  .gallery.n1, .gallery.n2, .gallery.many { margin-left: -120px; margin-right: -120px; }
  .gallery.many.big { columns: 3; }
}
@media (max-width: 520px) { .gallery.n2 { grid-template-columns: 1fr; } }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 60; background: rgba(10,14,12,.94); display: none; place-items: center; padding: 24px; }
.lightbox.open { display: grid; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 120px); border-radius: 10px; box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.lightbox p { color: var(--on-dark-soft); font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; margin: 14px 0 0; text-align: center; }
.lightbox button { position: absolute; top: 16px; right: 16px; width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--peat-2); color: var(--mist); font-size: 22px; cursor: pointer; }
.lightbox button:hover { background: var(--ember); color: var(--peat); }

/* training */
.train { background: var(--paper); border-radius: 16px; padding: 18px; margin: 0 0 1.8em; box-shadow: inset 0 0 0 1px var(--line); }
.train ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.train li { display: flex; flex-direction: column; gap: 6px; padding: 12px 6px; border-radius: 10px; background: var(--mist); text-align: center; position: relative; overflow: hidden; }
.train li::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: var(--h, 0%); background: rgba(232,87,42,.14); }
.train li .mono { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-muted); position: relative; z-index: 1; }
.train li strong { font-size: 15px; letter-spacing: -.01em; position: relative; z-index: 1; }
.train li.off { opacity: .45; }
.train .train-total { margin: 14px 2px 0; font-family: var(--mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-muted); display: flex; justify-content: space-between; align-items: baseline; }
.train .train-total strong { color: var(--ember); font-size: 20px; font-family: var(--display); letter-spacing: -.02em; text-transform: none; font-weight: 800; }
@media (max-width: 560px) { .train ul { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.sign { margin-top: 3em; display: flex; align-items: center; gap: 14px; color: var(--ink-muted); font-family: var(--mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.sign svg { width: 34px; height: 34px; }

/* more stories */
.post-more { background: var(--paper); padding: clamp(56px, 7vw, 88px) 0; }
.post-more h2 { font-size: clamp(28px, 3.4vw, 44px); margin: 0 0 28px; }
.post-nav { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.post-nav-card { display: grid; grid-template-columns: 120px 1fr; gap: 18px; align-items: center; padding: 14px; border-radius: var(--radius); background: var(--mist); text-decoration: none; color: var(--peat); transition: transform .5s var(--ease-settle), background .3s; }
.post-nav-card:hover { transform: translateY(-3px); color: var(--peat); background: #E4E9E4; }
.post-nav-card img { width: 120px; height: 96px; object-fit: cover; border-radius: 12px; display: block; }
.post-nav-card .mono { display: block; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-muted); margin-bottom: 6px; }
.post-nav-card strong { font-size: 21px; letter-spacing: -.02em; line-height: 1.15; }
.post-quote.long p { font-size: clamp(22px, 2.3vw, 28px); line-height: 1.3; }
@media (max-width: 900px) { .rail-item.dup { display: none; } .post-rail-inner { margin-bottom: 28px; } }
