/* ==========================================================================
   4FILMMAKERS | Filmmaking Gear & News
   Design notes
   - Paper white page, near-black ink: long reads are easier on light.
     Black is kept for "screens" only: the hero frame and the diagrams,
     which sit in dark monitor panels like a camera display.
   - Glass: translucent white panels with a lit rim and a soft cool shadow.
     Soft light leaks in the category colours sit behind the page, so the
     glass always has colour to blur and never reads as flat grey.
   - Category colours come from the false-colour exposure scale used on set
     monitors. They only ever mean "category", never decoration.
   - Type: The Bold Font for titles, Futura for every text. Futura is a paid
     face, so it is used where installed (all Apple devices) and Jost, a
     free Futura revival, is served to everyone else.
   - Articles are built for reading: 66ch measure, justified text with
     hyphenation, generous rhythm, the summary right after the intro.
   ========================================================================== */

@font-face {
  font-family: "The Bold Font";
  src: url("../fonts/TheBoldFont.woff2") format("woff2");
  font-weight: 100 900; /* one weight only: the range stops faux bold */
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("../fonts/Jost-var-latin.woff2") format("woff2");
  font-weight: 300 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("../fonts/Jost-italic-var-latin.woff2") format("woff2");
  font-weight: 300 800;
  font-style: italic;
  font-display: swap;
}

:root {
  /* Base palette */
  --page: #ffffff;
  --ink: #0d0d0f;
  --text: #26272b;
  --muted: #696b72;
  --soft: #f3f3f1;
  --hair: rgba(13, 13, 15, 0.09);
  --screen: #0e0f11;
  --screen-text: #e9e8e4;

  /* False-colour categories, deepened to read on white */
  --fc-cameras: #3d6cf2;
  --fc-lenses: #0f9e8b;
  --fc-software: #c2459f;
  --fc-accessories: #d39a00;
  --fc-tips: #4ba42c;
  --tally: #ff3b30;
  --tally-deep: #d7261b;

  /* Glass */
  --glass-fill: linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.30));
  --glass-blur: blur(22px) saturate(185%);
  --glass-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 1px 1px rgba(13, 13, 15, 0.04),
    0 18px 44px -18px rgba(28, 36, 72, 0.24);
  --rim: linear-gradient(150deg, #ffffff, rgba(255, 255, 255, 0.6) 30%, rgba(13, 13, 15, 0.05) 62%, rgba(13, 13, 15, 0.13));

  /* Type */
  --sans: Futura, "Futura PT", "Jost", "Century Gothic", sans-serif;
  --display: "The Bold Font", Futura, "Jost", sans-serif;

  --t-xs: 0.8125rem;   /* 13 */
  --t-sm: 0.9375rem;   /* 15 */
  --t-base: 1.0625rem; /* 17 */
  --t-md: 1.25rem;     /* 20 */
  --t-lg: 1.5rem;      /* 24 */
  --t-xl: 2rem;        /* 32 */
  --t-2xl: clamp(2.25rem, 1.5rem + 2.8vw, 3.5rem);
  --t-display: clamp(3.25rem, 0.8rem + 8.6vw, 9.5rem);

  /* Layout */
  --gutter: clamp(1rem, 0.4rem + 2.6vw, 2.5rem);
  --max: 1440px;
  --header-h: 84px;
  --r-xl: 34px;
  --r-lg: 26px;
  --r-md: 18px;
  --r-sm: 12px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --spring: cubic-bezier(0.34, 1.4, 0.5, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 20px);
  background: var(--page);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  position: relative;
  margin: 0;
  min-height: 100vh;
  background: transparent; /* the page colour lives on <html>, so the light leaks show */
  color: var(--text);
  font-family: var(--sans);
  font-size: var(--t-base);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body.is-locked { overflow: hidden; }

/* Light leaks behind everything: what the glass refracts */
body::before {
  content: "";
  position: fixed;
  inset: -12vmax;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(34vmax 26vmax at 8% 10%, rgba(109, 147, 255, 0.30), transparent 70%),
    radial-gradient(30vmax 26vmax at 96% 28%, rgba(240, 138, 210, 0.24), transparent 70%),
    radial-gradient(36vmax 26vmax at 78% 100%, rgba(67, 211, 191, 0.22), transparent 70%),
    radial-gradient(24vmax 20vmax at 2% 82%, rgba(255, 215, 94, 0.22), transparent 70%);
  filter: blur(24px);
}
/* paper grain, barely there: keeps the white from feeling digital */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.7 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; color: var(--ink); font-weight: 700; line-height: 1.05; text-wrap: balance; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }

::selection { background: var(--ink); color: #fff; }

:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 6px;
}

.visually-hidden {
  position: absolute !important;
  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: var(--gutter);
  top: -100px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--ink);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  border-radius: 999px;
}
.skip-link:focus-visible { top: 12px; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* --------------------------------------------------------------------------
   Glass surfaces. One recipe, shared: translucent fill, lit rim, soft shadow.
   -------------------------------------------------------------------------- */
.site-header__inner,
.mobile-menu nav,
.hero__intro,
.filters,
.post__link,
.frame,
.about__list,
.follow,
.site-footer__panel,
.to-top,
.callout,
.table-scroll,
.toc,
.article-aside .share,
.faq,
.preloader__core,
.glass {
  position: relative;
  isolation: isolate;
  background: var(--glass-fill);
  -webkit-backdrop-filter: var(--glass-blur);
  backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-shadow);
}
.site-header__inner::before,
.mobile-menu nav::before,
.hero__intro::before,
.filters::before,
.post__link::before,
.frame::before,
.about__list::before,
.follow::before,
.site-footer__panel::before,
.to-top::before,
.callout::before,
.table-scroll::before,
.toc::before,
.article-aside .share::before,
.faq::before,
.preloader__core::before,
.glass::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
  padding: 1px;
  background: var(--rim);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  pointer-events: none;
}

/* Specular light that follows the pointer on the cards you can open */
.post__link::after,
.frame::after,
.follow::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
  background: radial-gradient(480px circle at var(--mx, 50%) var(--my, -30%), rgba(255, 255, 255, 0.85), transparent 45%);
  opacity: 0;
  transition: opacity 0.5s var(--ease);
  pointer-events: none;
}
@media (hover: hover) {
  .post__link:hover::after,
  .frame:hover::after,
  .follow:hover::after { opacity: 1; }
}
.post__link > *,
.frame > *,
.follow > * { position: relative; z-index: 2; }

/* --------------------------------------------------------------------------
   Logo lockup (mark + wordmark), shared by header, preloader and footer
   -------------------------------------------------------------------------- */
.lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  color: var(--ink);
  text-decoration: none;
  line-height: 1;
}
.lockup__mark {
  width: auto;
  height: 1.6em;
  flex: none;
}
.lockup__word {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: 0.05em;
  font-size: 1em;
  white-space: nowrap;
  transform: translateY(0.04em);
}

/* --------------------------------------------------------------------------
   Preloader: a focus ring. The arc fills with real progress while the
   distance scale turns, then the ring opens like an iris.
   -------------------------------------------------------------------------- */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 34px;
  background:
    radial-gradient(50vmax 40vmax at 30% 30%, rgba(109, 147, 255, 0.22), transparent 65%),
    radial-gradient(50vmax 40vmax at 75% 70%, rgba(240, 138, 210, 0.18), transparent 65%),
    var(--page);
  transition: opacity 0.7s var(--ease) 0.15s, visibility 0s linear 0.85s;
}
.preloader__ring {
  --p: 0;
  position: relative;
  width: clamp(190px, 46vw, 240px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  transition: transform 0.9s var(--ease), opacity 0.6s var(--ease);
}
/* distance scale: fine ticks on an outer band */
.preloader__ring::before {
  content: "";
  position: absolute;
  inset: -16px;
  border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, rgba(13, 13, 15, 0.45) 0 0.5deg, transparent 0.5deg 6deg);
  -webkit-mask: radial-gradient(circle, transparent 0 calc(50% - 9px), #000 calc(50% - 9px) calc(50% - 1px), transparent calc(50% - 1px));
  mask: radial-gradient(circle, transparent 0 calc(50% - 9px), #000 calc(50% - 9px) calc(50% - 1px), transparent calc(50% - 1px));
  transform: rotate(calc(var(--p) * 120deg));
  opacity: 0.7;
}
.preloader__svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
  overflow: visible;
}
.preloader__track,
.preloader__fill {
  fill: none;
  stroke-width: 2.5;
}
.preloader__track { stroke: rgba(13, 13, 15, 0.08); }
.preloader__fill {
  stroke: url(#preloader-grad);
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
}
.preloader__core {
  width: 74%;
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
}
.preloader__mark { width: auto; height: 46px; position: relative; z-index: 2; }
.preloader__pct {
  position: relative;
  z-index: 2;
  font-family: var(--display);
  font-size: 1.125rem;
  letter-spacing: 0.06em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.preloader__word {
  font-family: var(--display);
  font-size: clamp(15px, 3.6vw, 19px);
  letter-spacing: 0.32em;
  padding-left: 0.32em; /* optical centring of tracked type */
  color: var(--muted);
  transition: opacity 0.4s var(--ease);
}
.preloader.is-done { opacity: 0; visibility: hidden; }
.preloader.is-done .preloader__ring { transform: scale(1.9); opacity: 0; }
.preloader.is-done .preloader__word { opacity: 0; }
.no-js .preloader { display: none; }

/* --------------------------------------------------------------------------
   Header: a floating glass capsule
   -------------------------------------------------------------------------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding-top: 12px;
  pointer-events: none;
}
.site-header__inner {
  pointer-events: auto;
  height: 60px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding: 0 8px 0 22px;
  border-radius: 999px;
}
.site-header .lockup { font-size: 15px; justify-self: start; }

.nav-pill {
  display: flex;
  gap: 2px;
}
.nav-pill a {
  padding: 9px 18px;
  border-radius: 999px;
  font-size: var(--t-sm);
  font-weight: 500;
  text-decoration: none;
  color: var(--text);
  transition: color 0.25s, background-color 0.25s;
}
.nav-pill a:hover { color: var(--ink); background: rgba(13, 13, 15, 0.05); }
.nav-pill a[aria-current="page"],
.nav-pill a.is-active {
  color: var(--ink);
  background: rgba(13, 13, 15, 0.08);
}

.header-actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* News: the most important link, lit like a tally light */
.nav-news {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 20px 0 16px;
  border-radius: 999px;
  font-size: var(--t-sm);
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fff;
  text-decoration: none;
  background: linear-gradient(180deg, #ff5d52, var(--tally-deep));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.45),
    0 8px 22px -8px rgba(215, 38, 27, 0.65);
  transition: box-shadow 0.3s var(--ease), transform 0.3s var(--spring);
}
.nav-news:hover {
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55), 0 12px 28px -8px rgba(215, 38, 27, 0.8);
}
.nav-news__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.8);
  animation: live 2s var(--ease) infinite;
}
@keyframes live {
  0%   { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.75); }
  70%  { box-shadow: 0 0 0 8px rgba(255, 255, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}
.nav-news[aria-current="page"],
.nav-news.is-active { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), 0 0 0 3px rgba(255, 59, 48, 0.22), 0 8px 22px -8px rgba(215, 38, 27, 0.65); }

.icon-link {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  color: var(--ink);
  transition: background-color 0.2s;
}
.icon-link:hover { background: rgba(13, 13, 15, 0.06); }
.icon-link svg { width: 20px; height: 20px; }

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: rgba(13, 13, 15, 0.06);
  cursor: pointer;
  place-items: center;
}
.menu-toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--ink);
  box-shadow: 0 5px 0 var(--ink);
  transform: translateY(-2.5px);
}

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: calc(var(--header-h) + 12px) var(--gutter) 28px;
  background: rgba(255, 255, 255, 0.45);
  -webkit-backdrop-filter: blur(28px) saturate(170%);
  backdrop-filter: blur(28px) saturate(170%);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s var(--ease), visibility 0s linear 0.35s;
}
.mobile-menu.is-open { opacity: 1; visibility: visible; transition-delay: 0s; }
.mobile-menu__close {
  position: absolute;
  top: 20px;
  right: calc(var(--gutter) + 8px);
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: rgba(13, 13, 15, 0.07);
  color: var(--ink);
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}
.mobile-menu nav {
  display: grid;
  padding: 8px 22px;
  border-radius: var(--r-lg);
  transform: translateY(12px) scale(0.98);
  transition: transform 0.5s var(--spring);
}
.mobile-menu.is-open nav { transform: none; }
.mobile-menu nav a {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  font-family: var(--display);
  font-size: clamp(2rem, 9vw, 3rem);
  color: var(--ink);
  text-decoration: none;
  line-height: 1;
}
.mobile-menu nav a + a { border-top: 1px solid var(--hair); }
.mobile-menu nav .mobile-menu__news { color: var(--tally-deep); }
.mobile-menu nav .mobile-menu__news .nav-news__dot { width: 12px; height: 12px; background: var(--tally); animation: none; }
.mobile-menu__foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: var(--t-sm);
}
.mobile-menu__foot a { color: var(--ink); }

@media (max-width: 900px) {
  .nav-pill { display: none; }
  .menu-toggle { display: inline-grid; }
  .site-header__inner { grid-template-columns: 1fr auto; padding-left: 18px; }
}
@media (max-width: 420px) {
  .header-actions .icon-link { display: none; }
  .site-header .lockup { font-size: 13px; }
  .nav-news { padding: 0 16px 0 14px; }
}

/* Reading progress on articles (added by main.js) */
.progress {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 120;
  height: 3px;
  background: var(--cat, var(--ink));
  transform-origin: left center;
  transform: scaleX(0);
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Hero: a letterboxed frame; the headline lives on the image and the intro
   sits on it as a pane of glass.
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  padding: calc(var(--header-h) + 16px) 0 clamp(24px, 4vw, 48px);
}
.hero__stage { position: relative; }
.hero__frame {
  position: relative;
  width: 100%;
  height: clamp(440px, calc(100svh - var(--header-h) - 48px), 62vw);
  max-height: 900px;
  overflow: hidden;
  border-radius: var(--r-xl);
  background: var(--screen);
  box-shadow: 0 40px 80px -40px rgba(28, 36, 72, 0.45);
}
.hero__frame picture,
.hero__frame img {
  width: 100%;
  height: 100%;
}
.hero__frame img { object-fit: cover; }
/* shade under the headline */
.hero__frame::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.18) 0%, transparent 22%, transparent 48%, rgba(0, 0, 0, 0.62) 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

/* Monitor overlay: rounded frame lines, tally + timecode on glass chips */
.monitor {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  font-size: var(--t-xs);
  font-weight: 600;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, 0.95);
}
.monitor__corner {
  position: absolute;
  width: clamp(20px, 2.6vw, 38px);
  aspect-ratio: 1;
  border-color: rgba(255, 255, 255, 0.75);
  border-style: solid;
  border-width: 0;
}
.monitor__corner--tl { top: 5%; left: 2.6%; border-top-width: 1.5px; border-left-width: 1.5px; border-top-left-radius: 14px; }
.monitor__corner--tr { top: 5%; right: 2.6%; border-top-width: 1.5px; border-right-width: 1.5px; border-top-right-radius: 14px; }
.monitor__corner--bl { bottom: 5%; left: 2.6%; border-bottom-width: 1.5px; border-left-width: 1.5px; border-bottom-left-radius: 14px; }
.monitor__corner--br { bottom: 5%; right: 2.6%; border-bottom-width: 1.5px; border-right-width: 1.5px; border-bottom-right-radius: 14px; }
.monitor__rec,
.monitor__tc {
  position: absolute;
  top: calc(5% + 10px);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 13px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  -webkit-backdrop-filter: blur(14px) saturate(170%);
  backdrop-filter: blur(14px) saturate(170%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}
.monitor__rec { left: calc(2.6% + 14px); }
.monitor__tc { right: calc(2.6% + 14px); }
.monitor__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--tally);
  box-shadow: 0 0 10px rgba(255, 59, 48, 0.9);
  animation: tally 1.6s steps(1) infinite;
}
@keyframes tally { 50% { opacity: 0.25; } }

.hero__title {
  position: absolute;
  z-index: 3;
  left: clamp(20px, 4%, 56px);
  bottom: clamp(20px, 6%, 56px);
  font-family: var(--display);
  font-size: var(--t-display);
  font-weight: 400;
  line-height: 0.86;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 2px 40px rgba(0, 0, 0, 0.3);
}
.hero__title span { display: block; white-space: nowrap; }

.hero__intro {
  position: absolute;
  z-index: 4;
  right: clamp(20px, 3%, 44px);
  bottom: clamp(20px, 5%, 48px);
  width: min(27rem, 34%);
  display: grid;
  gap: 18px;
  padding: 24px 26px;
  border-radius: var(--r-lg);
  /* clearer glass than the rest: the photo must show through */
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.28));
}
.hero__intro > * { position: relative; z-index: 2; }
.hero__intro p {
  font-size: var(--t-base);
  line-height: 1.5;
  color: var(--ink);
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  border: 0;
  background: var(--ink);
  color: #fff;
  font-size: var(--t-sm);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 10px 24px -12px rgba(13, 13, 15, 0.6);
  transition: transform 0.3s var(--spring), box-shadow 0.3s var(--ease);
}
.btn:hover { transform: translateY(-1px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 14px 30px -12px rgba(13, 13, 15, 0.7); }
.btn--ghost {
  background: var(--glass-fill);
  color: var(--ink);
  -webkit-backdrop-filter: var(--glass-blur);
  backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-shadow), inset 0 0 0 1px rgba(13, 13, 15, 0.08);
}
.btn--ghost:hover { box-shadow: var(--glass-shadow), inset 0 0 0 1px rgba(13, 13, 15, 0.16); }
.btn svg { width: 18px; height: 18px; }

.ig-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--t-sm);
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
.ig-link svg { width: 20px; height: 20px; }
.ig-link:hover span { text-decoration: underline; text-underline-offset: 4px; }

/* Rack focus: one orchestrated moment once the preloader lifts */
.js .hero__title,
.js .hero__frame img {
  filter: blur(14px);
  opacity: 0.35;
}
.js .hero__frame img { filter: blur(6px); transform: scale(1.04); }
.js .hero__intro { opacity: 0; transform: translateY(14px); }
.is-ready .hero__title {
  animation: rack-focus 1.5s var(--ease) 0.15s forwards;
}
.is-ready .hero__frame img {
  animation: rack-focus-img 1.8s var(--ease) forwards;
}
.is-ready .hero__intro {
  transition: opacity 0.9s var(--ease) 1.1s, transform 0.9s var(--spring) 1.1s;
  opacity: 1;
  transform: none;
}
@keyframes rack-focus {
  0%   { filter: blur(14px); opacity: 0.35; }
  55%  { filter: blur(0.8px); opacity: 1; }
  70%  { filter: blur(2.2px); }          /* focus breathing: overshoot and settle */
  100% { filter: blur(0); opacity: 1; }
}
@keyframes rack-focus-img {
  0%   { filter: blur(6px); opacity: 0.35; transform: scale(1.04); }
  100% { filter: blur(0); opacity: 1; transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .js .hero__title,
  .js .hero__frame img,
  .js .hero__intro { filter: none; opacity: 1; transform: none; animation: none; transition: none; }
  .monitor__dot,
  .nav-news__dot { animation: none; }
}

/* below 1100px the intro leaves the image and sits under it */
@media (max-width: 1100px) {
  .hero__frame { height: auto; aspect-ratio: 16 / 10; }
  .hero__intro {
    position: relative;
    right: auto;
    bottom: auto;
    width: auto;
    max-width: 40rem;
    margin: -48px clamp(12px, 3vw, 32px) 0 auto;
    background: var(--glass-fill);
  }
  .hero__intro p { font-size: var(--t-md); }
}
@media (max-width: 640px) {
  .hero { padding-top: calc(var(--header-h) + 4px); }
  .hero__frame { aspect-ratio: 4 / 5; border-radius: var(--r-lg); }
  .hero__title { font-size: clamp(3.25rem, 17vw, 5.5rem); bottom: 64px; left: 20px; }
  .hero__intro { margin: -40px 10px 0; padding: 20px; border-radius: var(--r-md); }
  .hero__intro p { font-size: var(--t-base); }
  .monitor__corner--tl, .monitor__corner--tr { top: 3.5%; }
  .monitor__corner--bl, .monitor__corner--br { bottom: 3.5%; }
  .monitor__rec, .monitor__tc { top: calc(3.5% + 8px); padding: 6px 11px; }
}

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */
.section { padding-block: clamp(64px, 8vw, 120px); }
.section--tight { padding-top: clamp(40px, 6vw, 72px); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 16px 40px;
  margin-bottom: clamp(28px, 4vw, 48px);
}
.section-head h2 {
  font-family: var(--display);
  font-size: var(--t-2xl);
  font-weight: 400;
  line-height: 0.95;
  text-transform: uppercase;
}
.section-head p {
  max-width: 44ch;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Category tags and filters
   -------------------------------------------------------------------------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: var(--t-xs);
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-decoration: none;
}
.tag::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cat, var(--muted));
}
a.tag:hover { text-decoration: underline; text-underline-offset: 3px; }
[data-cat="cameras"],     .tag--cameras     { --cat: var(--fc-cameras); }
[data-cat="lenses"],      .tag--lenses      { --cat: var(--fc-lenses); }
[data-cat="software"],    .tag--software    { --cat: var(--fc-software); }
[data-cat="accessories"], .tag--accessories { --cat: var(--fc-accessories); }
[data-cat="tips"],        .tag--tips        { --cat: var(--fc-tips); }

/* a glass segmented control */
.filters {
  display: flex;
  width: fit-content;
  max-width: 100%;
  gap: 4px;
  padding: 5px;
  margin-bottom: clamp(24px, 3vw, 40px);
  border-radius: 999px;
  overflow-x: auto;
  scrollbar-width: none;
}
.filters::-webkit-scrollbar { display: none; }
.filter {
  position: relative;
  z-index: 2;
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 40px;
  padding: 0 17px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-size: var(--t-sm);
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: color 0.25s, background-color 0.25s;
}
.filter:hover { color: var(--ink); background: rgba(13, 13, 15, 0.05); }
.filter__swatch {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--cat, conic-gradient(var(--fc-cameras) 0 20%, var(--fc-lenses) 0 40%, var(--fc-software) 0 60%, var(--fc-accessories) 0 80%, var(--fc-tips) 0));
}
.filter[aria-pressed="true"] {
  color: #fff;
  background: var(--ink);
  box-shadow: 0 4px 12px -4px rgba(13, 13, 15, 0.5);
}
.filter__count {
  font-size: var(--t-xs);
  font-variant-numeric: tabular-nums;
  opacity: 0.6;
}

/* --------------------------------------------------------------------------
   Feed and post cards
   -------------------------------------------------------------------------- */
.feed {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 28px);
}
.post { position: relative; }
.post[hidden] { display: none; }
.post__link {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
  height: 100%;
  padding: 10px 10px 24px;
  border-radius: var(--r-lg);
  text-decoration: none;
  color: inherit;
  transition: transform 0.5s var(--spring), box-shadow 0.5s var(--ease);
}
@media (hover: hover) {
  .post__link:hover { transform: translateY(-4px); box-shadow: var(--glass-shadow), 0 34px 60px -30px rgba(28, 36, 72, 0.35); }
}
.post__media {
  position: relative;
  margin: 0;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: var(--soft);
  border-radius: var(--r-md);
}
.post__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1s var(--ease);
}
/* category colour, like a clip label in a timeline */
.post__media::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 -3px 0 var(--cat, var(--muted)), inset 0 0 0 1px rgba(13, 13, 15, 0.06);
  pointer-events: none;
}
.post__link:hover .post__media img { transform: scale(1.04); }
.post__body { display: grid; gap: 12px; align-content: start; padding-inline: 12px; }
.post__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 16px;
  font-size: var(--t-xs);
  color: var(--muted);
}
.post__title {
  font-family: var(--display);
  font-size: var(--t-lg);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: 0.005em;
  text-transform: uppercase;
}
.post__excerpt { color: var(--muted); max-width: 60ch; }

/* Lead story: the newest post in the "All" view takes the full width */
.post--lead { grid-column: 1 / -1; }
.post--lead .post__link {
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  grid-template-rows: auto;
  align-items: center;
  gap: clamp(24px, 4vw, 56px);
  padding: 12px clamp(12px, 3vw, 44px) 12px 12px;
  border-radius: var(--r-xl);
}
.post--lead .post__media { aspect-ratio: 2.39 / 1; border-radius: calc(var(--r-xl) - 10px); }
.post--lead .post__body { padding-inline: 0; gap: 16px; }
.post--lead .post__title {
  font-size: clamp(1.75rem, 1.1rem + 1.6vw, 2.625rem);
  line-height: 1;
}
.post--lead .post__excerpt { font-size: var(--t-md); line-height: 1.45; }
.post__new {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 10px 4px 8px;
  border-radius: 999px;
  color: var(--tally-deep);
  font-weight: 700;
  background: rgba(255, 59, 48, 0.1);
}
.post__new::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--tally);
}

.feed__empty {
  padding: 40px;
  border-radius: var(--r-lg);
  background: var(--glass-fill);
  box-shadow: var(--glass-shadow);
  color: var(--muted);
  max-width: 52ch;
}
.feed__empty strong { color: var(--ink); font-weight: 700; }
.feed__empty a { color: var(--ink); }
.feed__more { margin-top: 48px; display: flex; justify-content: center; }

@media (max-width: 1080px) {
  .feed { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .post--lead .post__link { grid-template-columns: 1fr; padding: 10px 10px 26px; border-radius: var(--r-lg); }
  .post--lead .post__media { aspect-ratio: 16 / 9; border-radius: var(--r-md); }
  .post--lead .post__body { padding-inline: 12px; }
}
@media (max-width: 760px) {
  .feed { grid-template-columns: 1fr; }
  .filters { -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); }
}

/* --------------------------------------------------------------------------
   Topics: one glass frame per category
   -------------------------------------------------------------------------- */
.strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(12px, 1.4vw, 18px);
  list-style: none;
}
.frame {
  color: inherit;
  display: grid;
  align-content: start;
  gap: 14px;
  width: 100%;
  height: 100%;
  padding: 8px 8px 22px;
  border: 0;
  border-radius: var(--r-lg);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.5s var(--spring), box-shadow 0.5s var(--ease);
}
@media (hover: hover) {
  .frame:hover {
    transform: translateY(-6px);
    box-shadow: var(--glass-shadow), 0 30px 60px -30px color-mix(in srgb, var(--cat) 70%, transparent);
  }
}
.frame__img {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: var(--r-md);
  background: var(--soft);
}
.frame__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1s var(--ease);
}
.frame:hover .frame__img img { transform: scale(1.06); }
.frame__name {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-inline: 10px;
  font-family: var(--display);
  font-size: var(--t-md);
  text-transform: uppercase;
  line-height: 1;
  color: var(--ink);
}
.frame__name::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--cat);
}
.frame__desc {
  padding-inline: 10px;
  font-size: var(--t-sm);
  color: var(--muted);
  line-height: 1.45;
}
.frame__count {
  padding-inline: 10px;
  font-size: var(--t-xs);
  font-weight: 600;
  color: var(--ink);
}
@media (max-width: 1100px) {
  .strip {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: minmax(230px, 34%);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    margin-inline: calc(var(--gutter) * -1);
    padding: 10px var(--gutter) 28px;
    scroll-padding-inline: var(--gutter);
  }
  .strip::-webkit-scrollbar { display: none; }
  .strip li { scroll-snap-align: start; }
}
@media (max-width: 640px) {
  .strip { grid-auto-columns: 72%; }
}

/* --------------------------------------------------------------------------
   About + Instagram
   -------------------------------------------------------------------------- */
.about {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
.about h2 {
  font-family: var(--display);
  font-size: var(--t-2xl);
  font-weight: 400;
  line-height: 0.95;
  text-transform: uppercase;
  margin-bottom: 26px;
}
.about__text { display: grid; gap: 18px; max-width: 58ch; }
.about__text p { color: var(--text); font-size: var(--t-md); line-height: 1.55; }
.about__list {
  list-style: none;
  display: grid;
  margin-top: 12px;
  padding: 6px 24px;
  border-radius: var(--r-md);
}
.about__list li {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 8rem 1fr;
  gap: 16px;
  padding: 16px 0;
  font-size: var(--t-sm);
  color: var(--muted);
}
.about__list li + li { border-top: 1px solid var(--hair); }
.about__list strong { color: var(--ink); font-weight: 700; }

.follow {
  display: grid;
  gap: 20px;
  padding: clamp(28px, 4vw, 48px);
  border-radius: var(--r-xl);
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 100% 100%, rgba(240, 138, 210, 0.28), transparent 60%),
    radial-gradient(90% 80% at 0% 0%, rgba(109, 147, 255, 0.26), transparent 60%),
    var(--glass-fill);
}
.follow__mark {
  position: absolute !important;
  z-index: 0 !important;
  right: -40px;
  bottom: -60px;
  width: 280px;
  opacity: 0.07;
  pointer-events: none;
}
.follow__handle {
  font-family: var(--display);
  font-size: clamp(2rem, 1.1rem + 3.2vw, 3.5rem);
  line-height: 1;
  color: var(--ink);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.follow__handle:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; }
.follow p { color: var(--text); max-width: 38ch; }

@media (max-width: 900px) {
  .about { grid-template-columns: 1fr; }
  .about__list li { grid-template-columns: 7rem 1fr; }
}

/* --------------------------------------------------------------------------
   Footer: a glass slab
   -------------------------------------------------------------------------- */
.site-footer {
  padding-block: 24px 28px;
  font-size: var(--t-sm);
  color: var(--muted);
}
.site-footer__panel {
  padding: clamp(28px, 4vw, 48px);
  border-radius: var(--r-xl);
}
.site-footer__panel > * { position: relative; z-index: 2; }
.site-footer__top {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
  gap: 32px;
}
.site-footer .lockup { font-size: 16px; margin-bottom: 16px; }
.site-footer h3 {
  font-size: var(--t-sm);
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 14px;
}
.site-footer ul { list-style: none; display: grid; gap: 8px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
  margin-top: 44px;
  padding-top: 20px;
  border-top: 1px solid var(--hair);
  font-size: var(--t-xs);
}
@media (max-width: 760px) {
  .site-footer__top { grid-template-columns: 1fr 1fr; }
  .site-footer__brand { grid-column: 1 / -1; }
  .site-footer__panel { border-radius: var(--r-lg); }
}

/* Back to top */
.to-top {
  position: fixed;
  right: var(--gutter);
  bottom: 24px;
  z-index: 90;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: var(--ink);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.3s, transform 0.4s var(--spring), visibility 0s linear 0.3s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.to-top svg { width: 18px; height: 18px; position: relative; z-index: 2; }

/* ==========================================================================
   Article page
   ========================================================================== */
.article-hero {
  padding-top: calc(var(--header-h) + clamp(32px, 6vw, 72px));
}
.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  font-size: var(--t-xs);
  color: var(--muted);
  margin-bottom: 28px;
}
.crumbs li + li::before { content: "/"; margin-right: 8px; color: #b3b4b8; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }

.article-hero__head {
  display: grid;
  gap: 22px;
  max-width: 60rem;
}
.article-hero h1 {
  font-family: var(--display);
  font-size: clamp(2.25rem, 1.2rem + 3.8vw, 4.5rem);
  font-weight: 400;
  line-height: 1;
  text-transform: uppercase;
}
.article-hero__dek {
  font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.45rem);
  line-height: 1.5;
  color: var(--text);
  max-width: 50ch;
}
.byline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
  padding-top: 6px;
  font-size: var(--t-sm);
  color: var(--muted);
}
.byline strong { color: var(--ink); font-weight: 700; }
.byline__updated { color: var(--text); }
.byline a { text-decoration: none; }
.byline a:hover { text-decoration: underline; text-underline-offset: 3px; }
.article-cover {
  margin: clamp(36px, 5vw, 60px) 0 0;
}
.article-cover__frame {
  position: relative;
  aspect-ratio: 2.39 / 1;
  overflow: hidden;
  border-radius: var(--r-xl);
  background: var(--soft);
  box-shadow: 0 40px 80px -44px rgba(28, 36, 72, 0.45);
}
.article-cover__frame::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(13, 13, 15, 0.06);
  pointer-events: none;
}
.article-cover img { width: 100%; height: 100%; object-fit: cover; }
.article-cover figcaption,
.figure figcaption {
  margin-top: 12px;
  font-size: var(--t-xs);
  line-height: 1.5;
  color: var(--muted);
}
.article-cover figcaption { padding-inline: 12px; }

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 15.5rem;
  gap: clamp(40px, 7vw, 120px);
  padding-block: clamp(56px, 7vw, 96px) clamp(72px, 9vw, 120px);
}
.article-aside {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  align-self: start;
  display: grid;
  gap: 20px;
  font-size: var(--t-sm);
}
.article-aside h2 {
  position: relative;
  z-index: 2;
  font-size: var(--t-xs);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-bottom: 10px;
}
.toc {
  padding: 18px 18px 14px;
  border-radius: var(--r-md);
}
.toc ol {
  position: relative;
  z-index: 2;
  list-style: none;
  display: grid;
  gap: 2px;
  counter-reset: toc;
}
.toc a {
  display: block;
  padding: 7px 10px;
  border-radius: 10px;
  color: var(--text);
  text-decoration: none;
  line-height: 1.35;
  transition: color 0.2s, background-color 0.2s;
}
.toc a:hover { color: var(--ink); background: rgba(13, 13, 15, 0.04); }
.toc a.is-current {
  color: var(--ink);
  font-weight: 700;
  background: color-mix(in srgb, var(--cat, var(--ink)) 12%, transparent);
}

.article-aside .share {
  padding: 8px;
  border-radius: 999px;
  width: fit-content;
}
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.share a,
.share button {
  position: relative;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: rgba(13, 13, 15, 0.05);
  color: var(--ink);
  cursor: pointer;
  transition: background-color 0.2s, transform 0.3s var(--spring);
}
.share a:hover,
.share button:hover { background: rgba(13, 13, 15, 0.1); transform: translateY(-1px); }
.share svg { width: 17px; height: 17px; }
.share__status { flex-basis: 100%; min-height: 1.2em; font-size: var(--t-xs); color: var(--muted); }
.article-aside .share .share__status { padding-inline: 10px; position: relative; z-index: 2; }
.article-aside .share .share__status:empty { display: none; }

/* Long-form prose: built for reading */
.prose {
  min-width: 0;
  max-width: 41rem; /* about 66 characters a line */
  font-size: clamp(1.125rem, 1.06rem + 0.3vw, 1.25rem);
  line-height: 1.78;
  color: var(--text);
  hyphens: auto;
  -webkit-hyphens: auto;
}
.prose > * + * { margin-top: 1.35em; }
.prose p {
  text-align: justify;
  text-wrap: pretty;
  hyphenate-limit-chars: 7 3 3;
}
.prose h2 {
  margin-top: 2.6em;
  font-family: var(--display);
  font-size: clamp(1.75rem, 1.4rem + 1vw, 2.25rem);
  font-weight: 400;
  line-height: 1.02;
  text-transform: uppercase;
  color: var(--ink);
  hyphens: manual;
  scroll-margin-top: calc(var(--header-h) + 28px);
}
.prose h2 + * { margin-top: 0.9em; }
.prose h3 {
  margin-top: 2em;
  font-size: var(--t-md);
  font-weight: 700;
  color: var(--ink);
  hyphens: manual;
}
.prose h3 + * { margin-top: 0.6em; }
.prose strong { color: var(--ink); font-weight: 700; }
.prose a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--cat, var(--ink)) 70%, transparent);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  transition: text-decoration-color 0.2s;
}
.prose a:hover { text-decoration-color: var(--ink); }
.prose ul, .prose ol { padding-left: 1.25em; }
.prose li { padding-left: 0.2em; }
.prose li + li { margin-top: 0.6em; }
.prose li::marker { color: var(--cat, var(--muted)); }
.prose .lede {
  font-size: 1.14em;
  line-height: 1.65;
  color: var(--ink);
}
.prose .lede::first-letter {
  float: left;
  font-family: var(--display);
  font-size: 3.5em;
  line-height: 0.8;
  margin: 0.08em 0.12em 0 0;
  color: var(--ink);
}

.figure { margin-block: 2.4em; }
.figure--wide { margin-inline: 0; }
.figure img { width: 100%; border-radius: var(--r-md); }
/* diagrams sit on a dark monitor panel, like a camera display */
.figure--diagram {
  padding: clamp(20px, 3vw, 32px);
  border-radius: var(--r-lg);
  background: var(--screen);
  box-shadow: 0 30px 60px -36px rgba(13, 13, 15, 0.6), inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}
.figure--diagram figcaption { color: #a3a5ab; margin-top: 16px; }

.table-scroll {
  overflow-x: auto;
  border-radius: var(--r-md);
  padding: 6px 18px 10px;
}
.data-table {
  position: relative;
  z-index: 2;
  width: 100%;
  border-collapse: collapse;
  font-size: var(--t-sm);
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
}
.data-table caption {
  text-align: left;
  font-size: var(--t-xs);
  font-weight: 700;
  color: var(--muted);
  padding: 12px 0 8px;
}
.data-table th,
.data-table td {
  padding: 12px 16px 12px 0;
  border-bottom: 1px solid var(--hair);
  text-align: left;
  vertical-align: top;
}
.data-table tr:last-child th,
.data-table tr:last-child td { border-bottom: 0; }
.data-table thead th { color: var(--ink); font-weight: 700; border-bottom-color: rgba(13, 13, 15, 0.2); }
.data-table td { color: var(--text); white-space: normal; }
.data-table tbody th { color: var(--muted); font-weight: 600; padding-right: 24px; white-space: nowrap; }
.data-table thead ~ tbody td { white-space: nowrap; }

/* "In short": the summary, read first */
.callout {
  padding: clamp(22px, 3vw, 30px) clamp(22px, 3vw, 32px);
  border-radius: var(--r-md);
  font-size: var(--t-base);
  line-height: 1.6;
  background:
    linear-gradient(120deg, color-mix(in srgb, var(--cat, #ffffff) 14%, transparent), transparent 60%),
    var(--glass-fill);
}
.callout > * { position: relative; z-index: 2; }
.callout h2,
.callout h3 {
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--sans);
  font-size: var(--t-md);
  font-weight: 700;
  text-transform: none;
}
.callout h2::before,
.callout h3::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--cat, var(--ink));
}
.callout ul { padding-left: 1.1em; }
.callout li + li { margin-top: 0.45em; }

.faq {
  padding: 6px 24px;
  border-radius: var(--r-md);
}
.faq details { position: relative; z-index: 2; }
.faq details + details { border-top: 1px solid var(--hair); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  font-size: var(--t-base);
  font-weight: 700;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  flex: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(13, 13, 15, 0.06);
  font-weight: 400;
  font-size: 1.15em;
  line-height: 1;
  color: var(--ink);
  transition: transform 0.3s var(--spring), background-color 0.2s;
}
.faq details[open] summary::after { transform: rotate(45deg); background: color-mix(in srgb, var(--cat, var(--ink)) 16%, transparent); }
.faq details p { padding: 0 0 20px; color: var(--text); font-size: var(--t-base); line-height: 1.65; text-align: left; }

.prose .sources { font-size: var(--t-sm); color: var(--muted); line-height: 1.55; }
.prose .sources a { color: var(--text); text-decoration-thickness: 1px; }

.article-end {
  display: grid;
  gap: 24px;
  margin-top: 3em;
  padding-top: 28px;
  border-top: 1px solid var(--hair);
}
.article-end__tags { display: flex; flex-wrap: wrap; gap: 8px; }
.prose .article-end__tags a {
  padding: 8px 15px;
  border-radius: 999px;
  background: var(--glass-fill);
  box-shadow: var(--glass-shadow), inset 0 0 0 1px var(--hair);
  font-size: var(--t-xs);
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
.prose .article-end__tags a:hover { box-shadow: var(--glass-shadow), inset 0 0 0 1px rgba(13, 13, 15, 0.2); }

@media (max-width: 1000px) {
  .article-layout { grid-template-columns: minmax(0, 1fr); gap: 28px; padding-top: 32px; }
  .article-aside { position: static; order: -1; gap: 14px; }
  .article-aside > div { display: none; } /* share lives in the native share sheet on phones */
  .toc { padding: 14px; }
  .toc ol {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent);
    mask-image: linear-gradient(90deg, #000 85%, transparent);
  }
  .toc ol::-webkit-scrollbar { display: none; }
  .toc a { white-space: nowrap; background: rgba(13, 13, 15, 0.05); border-radius: 999px; padding: 8px 14px; }
  .prose { max-width: 44rem; }
}
@media (max-width: 640px) {
  .article-cover__frame { aspect-ratio: 16 / 10; border-radius: var(--r-lg); }
  .prose p { hyphenate-limit-chars: 6 3 2; }
}

/* Simple pages (404, credits, about) */
.page {
  padding-top: calc(var(--header-h) + clamp(48px, 8vw, 120px));
  padding-bottom: clamp(72px, 10vw, 140px);
  min-height: 70vh;
}
.page h1 {
  font-family: var(--display);
  font-size: clamp(2.75rem, 1.6rem + 5vw, 6rem);
  font-weight: 400;
  line-height: 0.95;
  text-transform: uppercase;
  margin-bottom: 24px;
}
.page > .wrap > p { color: var(--text); max-width: 56ch; }
.page .btn { margin-top: 28px; }
.credits-list { list-style: none; display: grid; margin-top: 32px; border-top: 1px solid var(--hair); max-width: 60rem; }
.credits-list li {
  display: grid;
  grid-template-columns: 12rem 1fr;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--hair);
  font-size: var(--t-sm);
  color: var(--muted);
}
.credits-list strong { color: var(--ink); font-weight: 700; }
@media (max-width: 640px) { .credits-list li { grid-template-columns: 1fr; gap: 4px; } }
.about-page { margin-top: 12px; }
/* a drop cap would split the brand name */
.about-page .lede::first-letter { float: none; font: inherit; margin: 0; color: inherit; }

/* News archive and topic pages */
.page-news { padding-top: calc(var(--header-h) + clamp(32px, 6vw, 72px)); }
.page-title,
.section-head .page-title {
  font-family: var(--display);
  font-size: clamp(3rem, 1.6rem + 6vw, 7rem);
  font-weight: 400;
  line-height: 0.9;
  text-transform: uppercase;
}

.text-link {
  color: var(--ink);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 4px;
}
.text-link:hover { text-decoration-thickness: 2.5px; }

.topic__head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 36rem);
  align-items: end;
  gap: 24px 56px;
  margin-bottom: 28px;
}
.topic__head .page-title { white-space: nowrap; }
.topic__dot {
  display: inline-block;
  width: 0.3em;
  height: 0.3em;
  margin-right: 0.2em;
  border-radius: 50%;
  vertical-align: 0.2em;
  background: var(--cat);
}
.topic__intro { display: grid; gap: 14px; }
.topic__intro p { color: var(--text); font-size: var(--t-md); line-height: 1.55; }
.topic__intro p + p { font-size: var(--t-base); color: var(--muted); }
.topic__covers {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin-bottom: clamp(48px, 6vw, 80px);
}
.topic__covers li {
  padding: 8px 15px;
  border-radius: 999px;
  font-size: var(--t-sm);
  color: var(--ink);
  background: linear-gradient(90deg, color-mix(in srgb, var(--cat) 14%, transparent), rgba(255, 255, 255, 0.5));
  box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px var(--hair);
}
.topic__latest h2 { font-size: var(--t-xl); }
@media (max-width: 900px) {
  .topic__head { grid-template-columns: 1fr; }
}

.feed--related { margin-bottom: clamp(40px, 5vw, 64px); }
.strip-title {
  font-family: var(--display);
  font-weight: 400;
  font-size: var(--t-lg);
  text-transform: uppercase;
  margin-bottom: 20px;
}

/* Failsafe: if the script never runs, nothing stays hidden or blurred */
.js .preloader { animation: preloader-failsafe 0.4s linear 6s forwards; }
@keyframes preloader-failsafe { to { opacity: 0; visibility: hidden; } }
.js:not(.is-ready) .hero__title { animation: rack-focus 1.2s var(--ease) 6.2s forwards; }
.js:not(.is-ready) .hero__frame img { animation: rack-focus-img 1.2s var(--ease) 6.2s forwards; }
.js:not(.is-ready) .hero__intro { animation: intro-failsafe 0.6s var(--ease) 6.6s forwards; }
@keyframes intro-failsafe { to { opacity: 1; transform: none; } }

/* Diagrams keep readable labels on phones: they scroll sideways instead of shrinking */
@media (max-width: 640px) {
  .figure--diagram { overflow-x: auto; padding-inline: 14px; }
  .figure--diagram svg { min-width: 560px; }
  .figure--diagram figcaption { position: sticky; left: 0; max-width: calc(100vw - 2 * var(--gutter) - 30px); }
}

/* Browsers without backdrop-filter get a solid, still-clean panel */
@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .site-header__inner, .mobile-menu nav, .hero__intro, .filters, .post__link, .frame,
  .about__list, .follow, .site-footer__panel, .to-top, .callout, .table-scroll, .toc,
  .article-aside .share, .faq, .preloader__core, .glass { background-color: rgba(255, 255, 255, 0.94); }
  .mobile-menu { background: rgba(255, 255, 255, 0.96); }
}

/* A soft light in the category colour behind every card: the glass blurs it,
   so each card reads as a pane, not a white box */
.post,
.strip li { position: relative; isolation: isolate; }
.post::before,
.strip li::before {
  content: "";
  position: absolute;
  inset: 58% 4% -6% 22%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--cat, #6d93ff) 70%, transparent), transparent);
  filter: blur(22px);
  opacity: 0.7;
  pointer-events: none;
  transition: opacity 0.5s var(--ease);
}
.post:hover::before,
.strip li:hover::before { opacity: 1; }
.post--lead::before { inset: 10% -2% 10% 58%; }
@media (max-width: 960px) { .post--lead::before { inset: 58% 4% -6% 22%; } }

/* Article composition: text column and side panel centred as one block,
   with the headline aligned to the text */
@media (min-width: 1001px) {
  .article-layout {
    grid-template-columns: minmax(0, 41rem) 15.5rem;
    justify-content: center;
    column-gap: clamp(56px, 6vw, 104px);
  }
  .article-hero > .wrap > nav,
  .article-hero__head {
    max-width: calc(41rem + 15.5rem + clamp(56px, 6vw, 104px));
    margin-inline: auto;
  }
}
.prose .lede { text-align: left; }
.figure { margin: 2.4em 0; }
.article-aside .share { border-radius: var(--r-md); width: auto; }
.article-aside .share a,
.article-aside .share button { width: 38px; height: 38px; }
.article-aside .share { gap: 4px; padding: 6px; }
/* on phones a line holds ~35 characters: justified text would open rivers,
   so it falls back to a clean left edge */
@media (max-width: 640px) {
  .prose p { text-align: left; }
}
