/* =========================================================
   Butter Labs — styles
   White page, black ink, butter accents. Product tiles
   carry each product's own brand colour.
   ========================================================= */

:root {
  --bg: #ffffff;
  --cream: #fffbe0;
  --cream-2: #fff1ad;
  --milk: #fffdf2;
  --butter: #ffd83d;
  --ink: #121008;
  --ink-2: #4a4433;
  --ink-3: #6f6950;
  --line: rgba(18, 16, 8, .12);
  --line-strong: rgba(18, 16, 8, .22);

  --swoo: #dee04b;
  --swoo-ink: #0d0d0d;
  --blueprnt: #1b33e6;
  --naia: #f65002;

  --display: "Satoshi", "Helvetica Neue", Arial, sans-serif;
  --body: "Satoshi", "Helvetica Neue", Arial, sans-serif;

  --container: 1120px;
  --gutter: 24px;
  --nav-h: 68px;
  --radius: 22px;
  --radius-sm: 12px;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 12px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
h1, h2, h3, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
::selection { background: var(--butter); color: var(--ink); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 48px; padding: 0 22px; border-radius: 999px;
  font-weight: 700; font-size: 15px; white-space: nowrap;
  transition: transform .25s var(--ease-out), background .2s;
}
.btn--ink { background: var(--ink); color: var(--cream); }
.btn--ink:hover { background: #2a2614; }
.btn:active { transform: scale(.97); }
.btn--sm { height: 40px; padding: 0 16px; font-size: 14px; }
.btn--lg { height: 56px; padding: 0 28px; font-size: 16px; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.nav.is-scrolled { border-bottom-color: var(--line); }
.nav__inner {
  max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter);
  height: var(--nav-h); display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.nav__brand img { width: 112px; height: auto; }
.nav__links { display: flex; gap: 28px; font-size: 15px; color: var(--ink-2); }
.nav__links a:hover { color: var(--ink); }

/* ---------- layout ---------- */
.section { max-width: var(--container); margin: 0 auto; padding: 72px var(--gutter) 0; }
.label { font-family: var(--body); font-size: 13px; font-weight: 500; color: var(--ink-3); margin-bottom: 16px; letter-spacing: .02em; }
.section__title { font-family: var(--display); font-weight: 700; font-size: clamp(28px, 4vw, 40px); line-height: 1.05; letter-spacing: -.025em; }
.section__sub { color: var(--ink-2); margin-top: 10px; max-width: 520px; }

/* ---------- hero ---------- */
.hero { max-width: 720px; margin: 0 auto; padding: 88px var(--gutter) 40px; text-align: center; }
.hero__logo { width: min(440px, 80vw); margin: 0 auto; color: var(--ink); }
.hero__logo svg { width: 100%; height: auto; overflow: visible; }
.hero__sub { font-size: clamp(16px, 1.7vw, 18px); line-height: 1.55; max-width: 580px; margin: 32px auto 0; text-wrap: balance; }
.hero__note { font-size: 13px; color: var(--ink-3); margin-top: 10px; }
.hero__note a { color: var(--ink); font-weight: 700; margin-left: 6px; white-space: nowrap; border-bottom: 1px solid currentColor; }

.subscribe { display: flex; gap: 8px; max-width: 440px; margin: 28px auto 0; }
.subscribe input {
  flex: 1; min-width: 0; height: 48px; padding: 0 18px;
  border: 1px solid var(--line-strong); border-radius: 999px; background: var(--bg);
}
.subscribe input::placeholder { color: var(--ink-3); }
.subscribe input:focus { outline: none; border-color: var(--ink); }
.subscribe--compact { margin: 0; flex: 0 1 400px; }

/* logo letters drop in, then the rest of the hero rises */
.js .hero__logo .l { opacity: 0; transform: translateY(-28px) scale(.92); transform-box: fill-box; transform-origin: 50% 100%; animation: drop .7s var(--ease-out) forwards; animation-delay: calc(var(--i) * 55ms + 120ms); }
.hero__logo .l1 { --i: 0 } .hero__logo .l2 { --i: 1 } .hero__logo .l3 { --i: 2 } .hero__logo .l4 { --i: 3 } .hero__logo .l5 { --i: 4 }
.hero__logo .l6 { --i: 5 } .hero__logo .l8 { --i: 6 } .hero__logo .l9 { --i: 7 } .hero__logo .l10 { --i: 8 } .hero__logo .l11 { --i: 9 }
@keyframes drop { to { opacity: 1; transform: none; } }
.js .hero__in { opacity: 0; animation: fade-up .8s var(--ease-out) forwards; }
.js .hero__sub.hero__in { animation-delay: .75s; }
.js .subscribe.hero__in { animation-delay: .85s; }
.js .hero__note.hero__in { animation-delay: .95s; }
@keyframes fade-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* scroll reveal (only when JS is running) */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- why butter (pull quote) ---------- */
.quote { max-width: 640px; margin: 0 auto; padding: 64px var(--gutter) 8px; text-align: center; }
.quote__text { margin: 0; }
.quote__text p {
  font-family: "Instrument Serif", Georgia, "Times New Roman", serif; font-style: italic; font-weight: 400;
  font-size: clamp(22px, 2.8vw, 30px); line-height: 1.25; letter-spacing: -.005em; text-wrap: balance;
}
.quote__hl { background: linear-gradient(transparent 60%, var(--butter) 60%, var(--butter) 92%, transparent 92%); padding: 0 .06em; }
.quote__by { margin-top: 18px; font-size: 14px; font-weight: 500; color: var(--ink-3); }
.quote__by::before { content: ""; display: inline-block; width: 22px; height: 1px; background: currentColor; vertical-align: middle; margin-right: 10px; }

/* ---------- product tiles ---------- */
.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.tile {
  position: relative; aspect-ratio: 1; border-radius: var(--radius); padding: 26px;
  display: flex; flex-direction: column; justify-content: space-between; overflow: hidden;
  background: var(--bg); color: var(--ink); border: 1px solid var(--line-strong);
  transition: transform .45s var(--ease-out), background-color .35s, color .35s, border-color .35s;
}
a.tile:hover { transform: translateY(-4px); }
.tile__logo { height: auto; filter: brightness(0) invert(0); transition: filter .35s; }
.tile__logo--swoo { width: 96px; }
.tile__logo--blueprnt { width: 150px; }
.tile__logo--naia { width: 92px; }
.tile__text { display: flex; flex-direction: column; gap: 4px; }
.tile__name { font-family: var(--display); font-weight: 700; font-size: 24px; line-height: 1.1; }
.tile__tag { font-size: 15px; line-height: 1.4; color: var(--ink-2); transition: color .35s; }
.tile__go { position: absolute; top: 22px; right: 24px; font-size: 22px; line-height: 1; transition: transform .35s var(--ease-out); }
a.tile:hover .tile__go { transform: translate(3px, -3px); }
/* each card fills with its brand colour; logos are drawn black at rest and flip to white where the colour is dark */
.tile--swoo:is(:hover, :focus-visible, :active) { background: var(--swoo); border-color: var(--swoo); color: var(--swoo-ink); }
.tile--swoo:is(:hover, :focus-visible, :active) .tile__tag { color: #3a3b12; }
.tile--blueprnt:is(:hover, :focus-visible, :active) { background: var(--blueprnt); border-color: var(--blueprnt); color: #fff; }
.tile--blueprnt:is(:hover, :focus-visible, :active) .tile__tag { color: #c9d2ff; }
.tile--naia:is(:hover, :focus-visible, :active) { background: var(--naia); border-color: var(--naia); color: #fff; }
.tile--naia:is(:hover, :focus-visible, :active) .tile__tag { color: #fff; }
:is(.tile--blueprnt, .tile--naia):is(:hover, :focus-visible, :active) .tile__logo { filter: brightness(0) invert(1); }

/* ---------- idea decision kit ---------- */
.kit {
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 40px; align-items: center;
  background: var(--milk); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px;
}
.kit__main { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--line); background: #f7f6f2; }
.kit__thumbs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.kit__thumb { padding: 0; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); opacity: .6; transition: opacity .2s, border-color .2s; }
.kit__thumb img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.kit__thumb:hover { opacity: .9; }
.kit__thumb[aria-pressed="true"] { opacity: 1; border-color: var(--ink); }
.kit__title { font-family: var(--display); font-weight: 700; font-size: clamp(28px, 3.4vw, 38px); line-height: 1.05; }
.kit__sub { color: var(--ink-2); margin-top: 10px; font-size: 18px; }
.kit__list { margin-top: 20px; display: grid; gap: 10px; font-size: 15px; }
.kit__list li { position: relative; padding-left: 20px; }
.kit__list li::before { content: ""; position: absolute; left: 0; top: .55em; width: 8px; height: 8px; border-radius: 50%; background: var(--butter); box-shadow: 0 0 0 1px var(--ink); }
.kit__buy { display: flex; align-items: center; gap: 18px; margin-top: 26px; }
.kit__price { font-family: var(--display); font-weight: 700; font-size: 32px; }
.kit__meta { font-size: 13px; color: var(--ink-3); margin-top: 12px; }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 48px; align-items: start; }
.about__photo { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: var(--radius); background: #2a2629; }
.about__title { font-family: var(--display); font-weight: 700; font-size: clamp(30px, 4.2vw, 46px); line-height: 1.02; letter-spacing: -.025em; }
.about__lede { font-size: 19px; color: var(--ink-2); margin-top: 14px; max-width: 520px; }
.xp { margin-top: 28px; border-top: 1px solid var(--line-strong); }
.xp__row { display: flex; gap: 20px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.xp__co { flex: none; width: 110px; font-weight: 700; }
.xp__role { color: var(--ink-2); }
.portfolio {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-top: 22px; padding: 18px 22px; border-radius: var(--radius-sm);
  background: var(--cream-2); transition: background .2s;
}
.portfolio:hover { background: var(--butter); }
.portfolio__text { display: flex; flex-direction: column; gap: 2px; }
.portfolio__name { font-weight: 700; }
.portfolio__meta { font-size: 14px; color: var(--ink-2); }
.portfolio__go { font-size: 20px; transition: transform .35s var(--ease-out); }
.portfolio:hover .portfolio__go { transform: translate(3px, -3px); }
/* hidden until a real Figma link replaces "#" in index.html */
.portfolio[href="#"] { display: none; }

/* ---------- writing ---------- */
.writing__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px 40px; flex-wrap: wrap; margin-bottom: 28px; }
.posts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px 20px; }
.post { display: flex; flex-direction: column; gap: 6px; }
.post__img { display: block; aspect-ratio: 1456 / 1048; border-radius: var(--radius-sm); overflow: hidden; background: var(--cream-2); border: 1px solid var(--line); }
.post__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease-out); }
.post:hover .post__img img { transform: scale(1.03); }
.post__date { font-size: 13px; color: var(--ink-3); margin-top: 8px; }
.post__title { font-family: var(--display); font-weight: 700; font-size: 20px; line-height: 1.15; }
.post__title::first-letter { text-transform: uppercase; }
.post__blurb { font-size: 14px; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.more { display: inline-block; margin-top: 28px; font-weight: 700; font-size: 15px; border-bottom: 1.5px solid var(--ink); padding-bottom: 2px; }

/* ---------- work with me ---------- */
.work { margin-top: 96px; background: var(--ink); color: #fff; }
.work__inner { max-width: var(--container); margin: 0 auto; padding: 88px var(--gutter); }
.work .label { color: #fff; }
.work__title { font-family: var(--display); font-weight: 700; font-size: clamp(32px, 5vw, 56px); line-height: 1.02; letter-spacing: -.03em; max-width: 720px; }
.work__lede { color: #fff; font-size: 18px; margin-top: 18px; max-width: 620px; }
.ways { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 40px 0 36px; }
.way { border: 1px solid rgba(255, 255, 255, .28); border-radius: var(--radius); padding: 28px; }
.way__kicker { font-size: 13px; color: #fff; font-weight: 700; }
.way__name { font-family: var(--display); font-weight: 700; font-size: 26px; line-height: 1.1; margin-top: 14px; }
.way__body { color: #fff; margin-top: 10px; font-size: 16px; }
.work .btn--ink { background: #fff; color: var(--ink); }
.work .btn--ink:hover { background: var(--cream-2); }

/* ---------- footer ---------- */
.foot {
  max-width: var(--container); margin: 0 auto; padding: 36px var(--gutter) 48px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  font-size: 14px; color: var(--ink-2);
}
.foot img { width: 92px; height: auto; }
.foot__links { display: flex; gap: 22px; flex-wrap: wrap; }
.foot__links a:hover { color: var(--ink); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .nav__links { display: none; }
  .kit { grid-template-columns: 1fr; gap: 28px; padding: 20px; }
  .about { grid-template-columns: 1fr; gap: 28px; }
  .about__photo { max-width: 320px; }
  .posts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  :root { --gutter: 16px; --nav-h: 60px; }
  .section { padding-top: 56px; }
  .hero { padding-top: 48px; }
  /* product tiles become a swipeable row of squares */
  .tiles {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 76%;
    overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 4px; scroll-padding: 0 var(--gutter);
  }
  .tiles::-webkit-scrollbar { display: none; }
  .tile { scroll-snap-align: start; padding: 22px; }
  .ways { grid-template-columns: 1fr; }
  .work { margin-top: 72px; }
  .work__inner { padding: 64px var(--gutter); }
}
@media (max-width: 560px) {
  .subscribe { flex-direction: column; }
  .subscribe input { flex: none; width: 100%; height: 52px; }
  .subscribe .btn { width: 100%; height: 52px; }
  .subscribe--compact { flex-basis: 100%; }
  .posts { grid-template-columns: 1fr; }
  .xp__co { width: 92px; }
  .work .btn--lg { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .hero__logo .l, .js .hero__in, .js .reveal { opacity: 1; transform: none; }
}

/* =========================================================
   Resources card (homepage) and /trends page
   ========================================================= */
.res { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 16px; }
.res__card {
  display: flex; flex-direction: column; justify-content: space-between; gap: 18px;
  border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 24px; background: var(--bg);
  transition: transform .45s var(--ease-out), border-color .3s;
}
a.res__card:hover { transform: translateY(-3px); border-color: var(--ink); }
.res__card--feature { background: var(--cream-2); border-color: var(--cream-2); }
.res__badge { align-self: flex-start; font-size: 12px; font-weight: 700; border-radius: 999px; padding: 4px 10px; background: var(--ink); color: #fff; }
.res__big { font-size: clamp(56px, 8vw, 84px); font-weight: 700; line-height: .9; letter-spacing: -.04em; }
.res__name { font-size: 22px; font-weight: 700; line-height: 1.15; letter-spacing: -.015em; }
.res__line { color: var(--ink-2); font-size: 15px; margin-top: 6px; }
.res__cta { font-weight: 700; font-size: 15px; }
.res__side { display: grid; gap: 16px; }

/* /trends */
.t-main { max-width: 760px; margin: 0 auto; padding: 48px var(--gutter) 24px; }
.t-hero { padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.t-title { font-size: clamp(32px, 5.4vw, 52px); font-weight: 700; line-height: 1.02; letter-spacing: -.03em; }
.t-by { font-size: 13px; color: var(--ink-3); margin-top: 12px; }
.t-intro, .t-outro { padding: 28px 0; border-bottom: 1px solid var(--line); }
.t-intro h2, .t-outro h2 { font-size: 20px; font-weight: 700; margin: 18px 0 8px; }
.t-intro h2:first-child, .t-outro h2:first-child { margin-top: 0; }
.t-intro ul, .t-outro ul, .inf__row ul { list-style: disc; padding-left: 20px; }
.t-intro li, .t-outro li { margin: 4px 0; }
.t-stack { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; margin-top: 10px; }
.t-stack > div { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px; font-size: 14px; }
.t-stack ul { margin-top: 6px; }
.inf-group { font-size: 13px; font-weight: 700; color: var(--ink-3); letter-spacing: .04em; text-transform: uppercase; margin: 34px 0 4px; }
.inf { padding: 22px 0; border-bottom: 1px solid var(--line); scroll-margin-top: calc(var(--nav-h) + 12px); }
.inf__num { font-size: 13px; font-weight: 700; color: var(--ink-3); }
.inf__title { font-size: 23px; font-weight: 700; line-height: 1.15; letter-spacing: -.015em; margin-top: 2px; }
.inf__tags { margin: 8px 0 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.tag { display: inline-block; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 3px 9px; }
.tag--technology { background: #e6ebff; color: #1b2a8a; }
.tag--behavior { background: #fff1ad; color: #5a4a00; }
.tag--economic { background: #e5f4e8; color: #1f5a2e; }
.tag--regulatory { background: #f1e8ff; color: #4d2a85; }
.tag--societal { background: #ffe7dc; color: #7a2e10; }
.inf__row { font-size: 15px; margin: 8px 0; }
.inf__row b { font-weight: 700; margin-right: 4px; }
.inf__row ul { margin-top: 4px; }
.inf__row li { margin: 3px 0; }
.inf__stack { font-size: 13px; color: var(--ink-3); margin-top: 10px; }
.inf__stack a { color: var(--ink-2); text-decoration: underline; text-underline-offset: 2px; }
.t-sources { padding: 24px 0; font-size: 13px; color: var(--ink-2); }
.t-sources summary { cursor: pointer; font-weight: 700; color: var(--ink); }
.t-sources ul { margin-top: 10px; display: grid; gap: 4px; }
.t-sources a { text-decoration: underline; text-underline-offset: 2px; word-break: break-word; }

/* gate: only active when JS runs; without JS the full list stays readable */
.gate { margin: 26px 0 8px; }
.gate__card, .welcome { border-radius: var(--radius); padding: 26px; }
.gate__card { background: var(--cream-2); }
.gate__title { font-size: 26px; font-weight: 700; letter-spacing: -.02em; }
.gate__sub { color: var(--ink-2); margin-top: 4px; }
.gate__form { display: grid; grid-template-columns: 1fr 1.4fr auto; gap: 8px; margin-top: 16px; }
.gate__form input { height: 48px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--bg); min-width: 0; }
.gate__form input:focus { outline: none; border-color: var(--ink); }
.gate__err { grid-column: 1 / -1; color: #9b2c10; font-size: 14px; }
.gate__fine { font-size: 12px; color: var(--ink-2); margin-top: 12px; }
.gate__fine a { text-decoration: underline; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.js .trends:not(.is-unlocked) [data-gated] { display: none; }
.js .trends:not(.is-unlocked) .gate::before {
  content: ""; display: block; height: 90px; margin: -90px 0 0;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0), var(--bg));
  position: relative; pointer-events: none;
}
.welcome { border: 1px solid var(--line-strong); }
.welcome__hi { font-size: 24px; font-weight: 700; letter-spacing: -.02em; }
.welcome__sub { color: var(--ink-2); margin: 4px 0 16px; }
.ask { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.ask__q { font-weight: 700; margin-bottom: 10px; }
.ask__opts { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { border: 1px solid var(--line-strong); border-radius: 999px; padding: 9px 15px; font-size: 14px; font-weight: 500; transition: background .2s, color .2s; }
.pill:hover { border-color: var(--ink); }
.pill[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.ask__next { margin-top: 14px; display: grid; gap: 10px; justify-items: start; }
.ask__next p { color: var(--ink-2); font-size: 15px; }
.btn--line { border: 1.5px solid var(--ink); background: var(--bg); color: var(--ink); }
.btn--line:hover { background: var(--ink); color: #fff; }
.trends .nav__inner { max-width: 760px; }

@media (max-width: 720px) {
  .res { grid-template-columns: 1fr; }
  .gate__form { grid-template-columns: 1fr; }
  .gate__form .btn { width: 100%; height: 52px; }
  .gate__form input { height: 52px; }
  .t-main { padding-top: 32px; }
}
@media print {
  .trends--print .t-main { max-width: none; padding: 0; }
  .trends--print .inf__stack a { text-decoration: none; }
}

/* ---- inflection cards: scannable layout ---- */
.t-lead { font-size: 18px; line-height: 1.5; }
.t-key { list-style: none; padding: 0; counter-reset: k; display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 18px 0 10px; font-size: 13px; line-height: 1.4; color: var(--ink-2); }
.t-key > li { counter-increment: k; border-top: 2px solid var(--ink); padding-top: 8px; }
.t-key > li::before { content: counter(k); display: block; font-size: 11px; font-weight: 700; color: var(--ink-3); margin-bottom: 2px; }
.t-key__k { display: block; font-weight: 700; color: var(--ink); }
@media (max-width: 720px) { .t-key { grid-template-columns: 1fr 1fr; } }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-strong); border-radius: 999px; padding: 7px 13px; font-size: 13px; font-weight: 500; background: #fff; color: var(--ink); cursor: pointer; transition: background .15s, color .15s; }
.chip span { color: var(--ink-3); font-weight: 400; }
.chip::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--dot, transparent); }
.chip[data-filter="all"]::before { display: none; }
.chip--technology { --dot: #1b2a8a; } .chip--behavior { --dot: #c9a300; } .chip--economic { --dot: #1f5a2e; } .chip--regulatory { --dot: #4d2a85; } .chip--societal { --dot: #7a2e10; }
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip[aria-pressed="true"] span { color: rgba(255, 255, 255, .7); }
@media (max-width: 720px) {
  .chips { flex-wrap: nowrap; overflow-x: auto; margin: 18px calc(-1 * var(--gutter)) 4px; padding: 0 var(--gutter) 4px; scrollbar-width: none; }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex: none; }
}
.t-stackbox { margin-top: 18px; }
.t-stackbox__k { font-weight: 700; margin-bottom: 8px; }
.t-stack > div { display: flex; flex-direction: column; gap: 2px; }
.t-stack span { color: var(--ink-2); font-size: 13px; }
.inf__top { display: flex; align-items: center; gap: 10px; }
.inf__top .inf__num { width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; }
.inf__top .inf__tags { margin: 0; }
.inf__title { font-size: clamp(24px, 3.4vw, 30px); line-height: 1.12; margin-top: 12px; }
.inf__open { font-size: 18px; line-height: 1.4; margin-top: 8px; }
.inf__open b { background: linear-gradient(transparent 55%, var(--butter) 55%); font-weight: 700; padding: 0 2px; }
.inf { padding: 30px 0; }
/* one label style for every section of a card */
.inf__k, .inf__why dt { font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-3); }
/* proof: quiet, not the loudest thing on the card */
.inf__proof { list-style: none; padding: 0; margin: 14px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 24px; font-size: 14px; line-height: 1.4; color: var(--ink-2); }
.inf__proof b { display: block; font-size: 20px; line-height: 1.15; color: var(--ink); letter-spacing: -.01em; }
/* the problem, as two labelled lines */
.inf__why { margin: 18px 0 0; display: grid; gap: 8px; font-size: 15px; line-height: 1.45; }
.inf__why > div { display: grid; grid-template-columns: 124px 1fr; gap: 14px; }
.inf__why dt { padding-top: 3px; }
.inf__why dd { margin: 0; }
/* the only box: where you could come in */
.inf__ways { margin-top: 18px; background: var(--cream); border-radius: var(--radius-sm); padding: 16px 18px; font-size: 15px; line-height: 1.45; }
.inf__ways ul { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 6px; }
.inf__ways li { padding-left: 16px; position: relative; }
.inf__ways li::before { content: ""; position: absolute; left: 0; top: .55em; width: 6px; height: 6px; border-radius: 50%; background: var(--butter); box-shadow: 0 0 0 1px var(--ink); }
.inf__ways .inf__k--test { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.inf__test { margin-top: 6px; }
@media (max-width: 720px) {
  .inf__proof { grid-template-columns: 1fr; }
  .inf__why > div { grid-template-columns: 1fr; gap: 2px; }
}

/* ---- /trends deck: one slide at a time. Only with JS, and only on the page (the PDF print stays a list) ---- */
.js .trends--deck .t-main { padding-bottom: 0; overflow-x: clip; }
/* chips + slide + bar fill the screen under the nav, so the bar always sits at the bottom */
.js .trends--deck .deck { display: flex; flex-direction: column; min-height: calc(100vh - var(--nav-h)); min-height: calc(100svh - var(--nav-h)); }
.js .trends--deck .chips { margin-top: 12px; }
.js .trends--deck .t-hero { border-bottom: 0; padding-bottom: 0; }
.js .trends--deck [data-slide]:not(.is-on), .js .trends--deck .inf-sec:not(.has-on) { display: none; }
.js .trends--deck:not(.deck-ready) .t-intro { display: block; } /* before the script runs, show the cover, not 38 cards */
.js .trends--deck .t-intro { border-bottom: 0; padding-bottom: 16px; }
.js .trends--deck .inf { border-bottom: 0; padding: 10px 0 24px; }
.js .trends--deck .inf-group { margin-top: 16px; }
.js .trends--deck .gate { margin: 18px 0 24px; }
.js .trends.trends--deck .gate::before { display: none; }
.js .trends--deck .t-end { padding-bottom: 8px; }
.t-end__pdf { margin-top: 14px; font-weight: 700; }
.t-end__pdf a { border-bottom: 1.5px solid var(--ink); padding-bottom: 1px; }
.js .trends--deck.deck-moved [data-slide].is-on { animation: deck-in .34s var(--ease-out); } /* only once someone moves, not on load */
.js .trends--deck.deck-moved [data-slide].is-on.is-back { animation-name: deck-back; }
@keyframes deck-in { from { opacity: 0; transform: translateX(32px); } }
@keyframes deck-back { from { opacity: 0; transform: translateX(-32px); } }

/* each card: the title on the front, the details once you flip it. Only in the deck; the PDF and the no-JS page show everything */
.inf__flip { display: none; }
.js .trends--deck .inf__card {
  position: relative; display: flex; flex-direction: column;
  min-height: clamp(300px, calc(100svh - var(--nav-h) - 330px), 540px); /* fills the screen under the chips, the small cards and the bar */
  padding: 22px 22px 20px; border: 1.5px solid var(--ink); border-radius: var(--radius);
  background: var(--cream); cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.js .trends--deck .inf:not(.is-flipped) .inf__back { display: none; }
.js .trends--deck .inf:not(.is-flipped) .inf__title { margin-top: auto; font-size: clamp(30px, 8.4vw, 42px); line-height: 1.06; letter-spacing: -.025em; }
.js .trends--deck .inf__flip { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; margin-top: 20px; padding: 10px 16px; border: 1px solid var(--line-strong); border-radius: 999px; background: #fff; font-size: 14px; font-weight: 500; color: var(--ink); }
.js .trends--deck .inf__flip-back { display: none; }
.js .trends--deck .is-flipped .inf__card { background: #fff; cursor: auto; }
.js .trends--deck .is-flipped .inf__top { padding-right: 48px; }
.js .trends--deck .is-flipped .inf__flip { position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; margin: 0; padding: 0; justify-content: center; }
.js .trends--deck .is-flipped .inf__flip-front { display: none; }
.js .trends--deck .is-flipped .inf__flip-back { display: block; position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 720px) {
  .js .trends--deck .inf__card { padding: 18px 16px 18px; }
}

/* small cards under the chips: every shift of the chosen type. Tap one to open it */
.minis { display: none; }
.js .trends--deck .minis {
  position: relative; display: flex; gap: 8px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity;
  margin: 4px calc(-1 * var(--gutter)) 0; padding: 4px var(--gutter) 8px; scroll-padding: 0 var(--gutter); scrollbar-width: thin;
}
@media (hover: none) {
  .js .trends--deck .minis { scrollbar-width: none; }
  .minis::-webkit-scrollbar { display: none; }
}
.mini {
  flex: none; scroll-snap-align: start; display: flex; flex-direction: column; gap: 6px; width: 136px; height: 92px; padding: 9px 10px;
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm); background: var(--cream); color: var(--ink); transition: background-color .15s, border-color .15s;
}
.mini[hidden] { display: none; }
.mini:hover { border-color: var(--ink); }
.mini[aria-current] { background: var(--butter); border-color: var(--ink); box-shadow: inset 0 0 0 .5px var(--ink); }
.mini__n { flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--ink); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; }
.mini__t { font-size: 12px; line-height: 1.3; font-weight: 500; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.mini__lock { display: none; }
body:not(.is-unlocked) .mini--locked { background: #fff; border-style: dashed; color: var(--ink-3); }
body:not(.is-unlocked) .mini--locked .mini__n { background: var(--line); color: var(--ink-3); }
body:not(.is-unlocked) .mini--locked .mini__t { display: none; }
body:not(.is-unlocked) .mini--locked .mini__lock { display: block; margin-top: auto; }

.deck-bar {
  position: sticky; bottom: 0; z-index: 5;
  display: flex; align-items: center; gap: 12px;
  margin: auto calc(-1 * var(--gutter)) 0;
  padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-top: 1px solid var(--line);
}
.deck-bar[hidden], .deck-bar__next[hidden] { display: none; }
.deck-bar__fill { position: absolute; left: 0; right: 0; top: -1px; height: 2px; background: var(--ink); transform-origin: 0 50%; transform: scaleX(var(--p, 0)); transition: transform .4s var(--ease-out); }
.deck-bar__back { flex: none; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line-strong); display: inline-flex; align-items: center; justify-content: center; color: var(--ink); transition: border-color .15s; }
.deck-bar__back:hover { border-color: var(--ink); }
.deck-bar__back:disabled { visibility: hidden; }
.deck-bar__count { flex: 1; text-align: center; font-size: 14px; font-weight: 500; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.deck-bar__next { flex: none; min-width: 128px; gap: 4px; padding: 0 18px 0 24px; }
@media (prefers-reduced-motion: reduce) {
  .js .trends--deck.deck-moved [data-slide].is-on { animation: none; }
  .deck-bar__fill { transition: none; }
}
