/* ==========================================================================
   Optimail — styles
   ========================================================================== */

:root {
  --bg: #050d1f;
  --bg-2: #0a1630;
  --bg-3: #0f1e3d;
  --line: rgba(255, 255, 255, 0.12);
  --line-strong: rgba(255, 255, 255, 0.28);
  --text: #f3f6fb;
  --muted: #9aabc4;
  --brand: #7fb0cc;          /* "MAIL" steel blue from the logo */
  --teal: #2199bf;           /* top of the brand gradient */
  --accent: #9fe6f5;         /* bright highlight band */
  --accent-ink: #04122a;
  --danger: #ff8f7d;

  --font-display: "Inter Tight", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", "Inter Fallback", "Helvetica Neue", Arial, sans-serif;

  --radius: 20px;
  --radius-lg: 28px;
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1320px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 96px; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
strong { font-weight: 600; color: var(--text); }

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

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

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 200;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 16px; border-radius: 999px; font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 16px; }

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

.section { padding: clamp(80px, 12vw, 160px) 0; position: relative; }
.section--tight { padding: clamp(56px, 8vw, 100px) 0; }

/* ---------- Type ---------- */

.display,
.h-xl,
.h-lg,
.h-md {
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 0.92;
  margin: 0;
  text-wrap: balance;
}
.display { font-size: clamp(2.7rem, 7.4vw, 7rem); }
.h-xl { font-size: clamp(2.5rem, 7vw, 6.4rem); }
.h-lg { font-size: clamp(2.1rem, 5vw, 4.4rem); }
.h-md { font-size: clamp(1.6rem, 3vw, 2.4rem); line-height: 1; letter-spacing: -0.03em; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 22px;
}
.eyebrow::before { content: ""; width: 26px; height: 1px; background: currentColor; }

.lead { font-size: clamp(1.15rem, 1.8vw, 1.45rem); line-height: 1.45; color: var(--text); font-weight: 500; letter-spacing: -0.01em; }
.muted { color: var(--muted); }
.text-accent { color: var(--accent); }
.text-brand { color: var(--brand); }

/* ---------- Buttons ---------- */

.btn {
  --bh: 58px;
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: var(--bh);
  padding: 0 30px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600; font-size: 0.95rem; letter-spacing: 0.04em; text-transform: uppercase;
  text-decoration: none;
  background: #fff; color: var(--accent-ink);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .35s var(--ease), color .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease);
  white-space: nowrap;
}
.btn:hover { background: var(--accent); transform: translateY(-2px); box-shadow: 0 14px 40px -12px rgba(159, 230, 245, .55); }
.btn .arrow { width: 18px; height: 18px; transition: transform .35s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

.btn--ghost { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn--ghost:hover { background: #fff; color: var(--accent-ink); box-shadow: none; }

.btn--dark { background: var(--accent-ink); color: #fff; }
.btn--dark:hover { background: var(--bg-3); color: #fff; box-shadow: 0 14px 40px -12px rgba(4, 18, 42, .6); }

.btn--sm { --bh: 44px; padding: 0 20px; font-size: 0.8rem; }

/* ---------- Header ---------- */

.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  transition: background .4s var(--ease), border-color .4s var(--ease), backdrop-filter .4s;
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: rgba(5, 13, 31, 0.78);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom-color: var(--line);
}
.header-inner {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: 84px;
}
.brand { display: inline-flex; align-items: center; justify-self: start; }
.brand img { height: 22px; width: auto; }

.nav-pill {
  display: flex; gap: 4px; padding: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.nav-pill a {
  display: block; padding: 9px 20px; border-radius: 999px;
  font-family: var(--font-display); font-size: 0.82rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  text-decoration: none; color: var(--text);
  transition: background .3s var(--ease), color .3s var(--ease);
}
.nav-pill a:hover { background: rgba(255, 255, 255, 0.1); }
.nav-pill a[aria-current="page"] { background: #fff; color: var(--accent-ink); }

.header-cta { justify-self: end; }

.menu-toggle {
  display: none; justify-self: end;
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid var(--line-strong); background: rgba(255,255,255,.05); color: var(--text);
  cursor: pointer; position: relative;
}
.menu-toggle span,
.menu-toggle span::before,
.menu-toggle span::after {
  position: absolute; left: 50%; width: 18px; height: 1.5px; background: currentColor; border-radius: 2px;
  transform: translateX(-50%); transition: transform .35s var(--ease), opacity .2s;
}
.menu-toggle span { top: 50%; }
.menu-toggle span::before, .menu-toggle span::after { content: ""; left: 0; transform: none; }
.menu-toggle span::before { top: -6px; }
.menu-toggle span::after { top: 6px; }
.menu-open .menu-toggle span { background: transparent; }
.menu-open .menu-toggle span::before { transform: translateY(6px) rotate(45deg); background: var(--text); }
.menu-open .menu-toggle span::after { transform: translateY(-6px) rotate(-45deg); background: var(--text); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 90;
  background: var(--bg);
  padding: 120px var(--gutter) 40px;
  display: flex; flex-direction: column; justify-content: space-between;
  opacity: 0; visibility: hidden;
  transition: opacity .4s var(--ease), visibility .4s;
}
.menu-open .mobile-menu { opacity: 1; visibility: visible; }
.mobile-menu nav { display: flex; flex-direction: column; }
.mobile-menu nav a {
  font-family: var(--font-display); font-weight: 600; text-transform: uppercase; letter-spacing: -0.04em;
  font-size: clamp(2.6rem, 13vw, 4rem); line-height: 1.05; text-decoration: none;
  border-bottom: 1px solid var(--line); padding: 10px 0;
}
.menu-open { overflow: hidden; }

@media (max-width: 960px) {
  .nav-pill, .header-cta { display: none; }
  .menu-toggle { display: block; }
  .header-inner { grid-template-columns: 1fr auto; height: 72px; }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding-top: clamp(132px, 15vw, 176px);
  text-align: center;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(50% 55% at 50% 0%, rgba(33, 153, 191, 0.38), transparent 70%),
    radial-gradient(40% 40% at 50% 100%, rgba(127, 176, 204, 0.16), transparent 70%);
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 64px 64px;
  background-position: center top;
  -webkit-mask-image: radial-gradient(70% 60% at 50% 30%, #000 20%, transparent 75%);
          mask-image: radial-gradient(70% 60% at 50% 30%, #000 20%, transparent 75%);
}
.hero-copy { max-width: 1000px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; }

.badge {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 16px 7px 8px; margin-bottom: 30px;
  border-radius: 999px; border: 1px solid var(--line-strong);
  background: rgba(255,255,255,.05);
  font-size: 0.86rem; font-weight: 500; color: var(--text);
}
.badge .dot {
  width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(159, 230, 245, .15);
}
.badge .dot::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
  box-shadow: 0 0 0 0 rgba(159, 230, 245, .7); animation: pulse 2.2s infinite;
}
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(159, 230, 245, 0); } 100% { box-shadow: 0 0 0 0 rgba(159, 230, 245, 0); } }

.hero-title {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(2.7rem, 6.2vw, 5.7rem); line-height: 1; letter-spacing: -0.045em;
  margin: 0 0 28px; text-wrap: balance;
}
.serif {
  font-family: "Instrument Serif", Georgia, serif; font-style: italic; font-weight: 400;
  letter-spacing: -0.015em;
  background: linear-gradient(90deg, var(--accent), var(--brand) 60%, #4fb6d8);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-right: .06em;
}
.hero .lead { max-width: 40ch; margin-bottom: 16px; }
.hero .body { color: var(--muted); max-width: 60ch; margin-bottom: 36px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: center; }

/* Fan of email designs */
.hero-stage { --w: clamp(150px, 17vw, 250px); position: relative; margin-top: clamp(32px, 4vw, 56px); }
.hero-fan {
  position: relative;
  height: calc(var(--w) * 1.62);
  -webkit-mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
}
.fan-card {
  position: absolute; left: 50%; bottom: calc(var(--w) * -0.12);
  width: var(--w);
  transform-origin: 50% 210%;
  transform: translateX(-50%) rotate(calc(var(--i) * 9deg));
  z-index: var(--z);
  transition: transform .6s var(--ease);
  animation: fan-in 1.3s var(--ease) both;
  animation-delay: var(--d);
}
.fan-card img {
  width: 100%; height: auto; aspect-ratio: 440 / 638; object-fit: cover; object-position: top;
  border-radius: 16px;
  box-shadow: 0 0 0 1px rgba(255,255,255,.1), 0 40px 70px -25px rgba(0,0,0,.9);
}
.fan-card:hover { transform: translateX(-50%) rotate(calc(var(--i) * 9deg)) translateY(-26px); z-index: 20; }
@keyframes fan-in { from { opacity: 0; transform: translateX(-50%) translateY(140px) rotate(0deg); } }

.metric-chip {
  position: absolute; z-index: 30; text-align: left;
  padding: 12px 16px 12px 12px; border-radius: 16px;
  display: flex; align-items: center; gap: 12px;
  background: rgba(10, 22, 48, .78);
  border: 1px solid rgba(159, 230, 245, .25);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 20px 50px -20px rgba(0,0,0,.8);
  animation: chip-in .9s var(--ease) both, float 6s ease-in-out infinite;
}
.metric-chip .ic {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; flex: none;
  background: var(--accent); color: var(--accent-ink);
}
.metric-chip .ic svg { width: 18px; height: 18px; }
.metric-chip small { display: block; font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.metric-chip strong { display: block; font-family: var(--font-display); font-weight: 600; font-size: 0.98rem; letter-spacing: -0.01em; white-space: nowrap; }
.chip-1 { left: 3%; top: 30%; animation-delay: .9s, 0s; }
.chip-2 { right: 4%; top: 12%; animation-delay: 1.05s, -2s; }
.chip-3 { right: 9%; top: 62%; animation-delay: 1.2s, -4s; }
@keyframes chip-in { from { opacity: 0; scale: .94; } }
@keyframes float { 50% { translate: 0 -10px; } }

@media (max-width: 960px) {
  .chip-1 { left: 0; top: 2%; }
  .chip-2 { right: 0; top: 22%; }
  .chip-3 { display: none; }
}
@media (max-width: 560px) {
  .hero-stage { --w: 150px; margin-top: 88px; }
  .chip-1 { left: 50%; top: -64px; transform: translateX(-50%); }
  .chip-2 { display: none; }
  .metric-chip { padding: 8px 12px 8px 8px; }
  .metric-chip .ic { width: 30px; height: 30px; border-radius: 9px; }
  .metric-chip strong { font-size: 0.86rem; }
  .fan-card[style*="--i: -3"], .fan-card[style*="--i: 3"] { display: none; }
}

/* ---------- Clients band (marquee) ---------- */

.clients {
  background: var(--accent);
  color: var(--accent-ink);
  padding: clamp(48px, 7vw, 90px) 0 clamp(40px, 6vw, 72px);
  overflow: hidden;
}
.clients-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; margin-bottom: clamp(32px, 5vw, 56px); }
.clients .h-xl { color: var(--accent-ink); }
.clients-note { font-weight: 500; max-width: 30ch; margin: 0; }

.marquee { display: flex; width: max-content; animation: marquee 45s linear infinite; }
.marquee:hover { animation-play-state: paused; }
.marquee-group { display: flex; align-items: center; gap: clamp(48px, 7vw, 96px); padding-right: clamp(48px, 7vw, 96px); }
.marquee img { height: 38px; width: auto; max-width: 190px; object-fit: contain; filter: brightness(0); opacity: .82; }
.marquee img.logo-tall { height: 58px; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Problem ---------- */

.problem-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(40px, 6vw, 96px);
  margin-top: clamp(48px, 6vw, 80px); align-items: start;
}
.problem-copy p { color: var(--muted); font-size: 1.1rem; }
.problem-copy p:first-child { color: var(--text); }

.chart-card {
  background: linear-gradient(180deg, var(--bg-2), rgba(10, 22, 48, 0.4));
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3vw, 32px);
}
.chart-card header { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.chart-card h3 { font-family: var(--font-display); font-size: 1.05rem; font-weight: 600; margin: 0; letter-spacing: -0.01em; }
.chart-card .tag { font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.chart-card svg { width: 100%; height: auto; overflow: visible; }
.chart-card .axis-label { fill: var(--muted); font-size: 12px; font-family: var(--font-body); }
.chart-card .zone-label { fill: var(--accent); font-size: 13px; font-weight: 600; font-family: var(--font-body); }

.draw { stroke-dasharray: 1; stroke-dashoffset: 1; }
.is-visible .draw, .no-js .draw { animation: draw 2.2s var(--ease) forwards .2s; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.signal-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
.signal {
  border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px;
  background: rgba(255,255,255,.02);
}
.signal .label { font-size: 0.82rem; color: var(--muted); display: block; margin-bottom: 6px; }
.signal .sig-value { font-family: var(--font-display); font-weight: 600; font-size: 1.15rem; display: flex; align-items: center; gap: 8px; }
.signal svg { width: 100%; height: 44px; margin-top: 10px; }
.signal--up .sig-value { color: var(--accent); }
.signal--down .sig-value { color: var(--danger); }

.statement {
  margin-top: clamp(64px, 9vw, 120px);
  padding-top: clamp(40px, 5vw, 64px);
  border-top: 1px solid var(--line);
}
.statement p {
  font-family: var(--font-display); font-weight: 500; letter-spacing: -0.035em; line-height: 1.02;
  font-size: clamp(2rem, 5.2vw, 4.6rem); max-width: 18ch; margin: 0;
}
.statement p em { font-style: normal; color: var(--accent); }

/* ---------- Beliefs ---------- */

.beliefs { background: var(--bg-2); }
.belief-list { list-style: none; margin: clamp(48px, 6vw, 80px) 0 0; padding: 0; counter-reset: belief; }
.belief {
  display: grid; grid-template-columns: 80px minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(16px, 4vw, 56px);
  padding: clamp(26px, 3.4vw, 40px) 0;
  border-top: 1px solid var(--line);
  align-items: baseline;
  transition: padding .5s var(--ease);
}
.belief:last-child { border-bottom: 1px solid var(--line); }
.belief::before {
  counter-increment: belief; content: "0" counter(belief);
  font-family: var(--font-display); font-weight: 500; color: var(--brand); font-size: 0.95rem; letter-spacing: 0.08em;
}
.belief h3 {
  margin: 0; font-family: var(--font-display); font-weight: 600; letter-spacing: -0.03em; line-height: 1.05;
  font-size: clamp(1.5rem, 2.6vw, 2.2rem);
  transition: color .4s var(--ease);
}
.belief p { margin: 0; color: var(--muted); }
.belief:hover h3 { color: var(--accent); }

@media (max-width: 860px) {
  .belief { grid-template-columns: 1fr; gap: 10px; }
}

/* ---------- Fractional team ---------- */

.team-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.team-copy p { color: var(--muted); font-size: 1.1rem; }
.team-copy .h-lg { margin-bottom: 32px; }

.compare { display: grid; gap: 16px; }
.compare-card {
  border-radius: var(--radius-lg); padding: clamp(22px, 3vw, 32px);
  border: 1px solid var(--line);
}
.compare-card h3 { margin: 0 0 18px; font-family: var(--font-display); font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600; color: var(--muted); }
.compare-card--old { background: rgba(255,255,255,.02); }
.compare-card--new {
  background: linear-gradient(135deg, var(--teal) 0%, #0b3c74 55%, #071a3d 100%);
  border-color: rgba(159, 230, 245, .35);
  box-shadow: 0 40px 80px -40px rgba(33, 153, 191, .55);
}
.compare-card--new h3 { color: var(--accent); }
.roles { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; padding: 0; list-style: none; }
.roles li {
  padding: 8px 14px; border-radius: 999px; font-size: 0.88rem; font-weight: 500;
  border: 1px dashed var(--line-strong); color: var(--muted);
}
.compare-card--new .roles li { border-style: solid; border-color: rgba(255,255,255,.3); color: #fff; background: rgba(255,255,255,.08); }
.compare-meta { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 0.92rem; color: var(--muted); }
.compare-card--new .compare-meta { color: rgba(255,255,255,.85); }
.compare-meta span { display: inline-flex; align-items: center; gap: 8px; }
.compare-meta svg { width: 16px; height: 16px; flex: none; }

/* ---------- Retention system (tabs) ---------- */

.system-head { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr); gap: 32px; align-items: end; }
.system-head p { color: var(--muted); font-size: 1.1rem; margin: 0; }

.tablist {
  display: inline-grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  margin: clamp(48px, 6vw, 80px) auto 0;
  padding: 6px; border-radius: 999px;
  background: rgba(255,255,255,.06); border: 1px solid var(--line);
  position: relative;
}
.tabs-center { display: flex; justify-content: center; }
.tab {
  appearance: none; border: 0; background: transparent; color: var(--text);
  padding: 14px clamp(18px, 3vw, 40px); border-radius: 999px; cursor: pointer;
  font-family: var(--font-display); font-weight: 600; font-size: 1rem; letter-spacing: -0.01em;
  position: relative; z-index: 1;
  transition: color .4s var(--ease);
  display: inline-flex; align-items: center; gap: 10px; justify-content: center;
}
.tab .num { font-size: 0.75rem; color: var(--brand); letter-spacing: 0.08em; transition: color .4s; }
.tab[aria-selected="true"] { color: var(--accent-ink); }
.tab[aria-selected="true"] .num { color: var(--teal); }
.tab-indicator {
  position: absolute; z-index: 0; top: 6px; bottom: 6px; left: 6px;
  border-radius: 999px; background: #fff;
  transition: transform .5s var(--ease), width .5s var(--ease);
}

.timeline {
  position: relative; max-width: 760px; margin: 28px auto 0;
  display: grid; grid-template-columns: repeat(3, 1fr);
  font-size: 0.78rem; color: var(--muted); letter-spacing: 0.1em; text-transform: uppercase; text-align: center;
}
.timeline::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--line); border-radius: 2px; }
.timeline-fill { position: absolute; left: 0; top: 0; height: 2px; background: var(--accent); border-radius: 2px; transition: width .7s var(--ease); width: 33.33%; }
.timeline span { padding-top: 12px; }

.tab-panel { margin-top: clamp(48px, 6vw, 80px); }
.tab-panel[hidden] { display: none; }
.panel-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.panel-copy .h-lg { margin-bottom: 22px; }
.panel-copy p { color: var(--muted); font-size: 1.08rem; }
.panel-copy p.intro { color: var(--text); }
.metrics { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 26px; padding: 0; list-style: none; }
.metrics li {
  padding: 8px 14px; border-radius: 999px; font-size: 0.86rem; font-weight: 600;
  background: rgba(159, 230, 245, .1); color: var(--accent); border: 1px solid rgba(159, 230, 245, .3);
}
.metrics-label { display: block; font-size: 0.75rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.panel-copy .btn { margin-top: 14px; }

.tab-panel.is-entering .panel-copy > *, .tab-panel.is-entering .phones { animation: panel-in .7s var(--ease) both; }
.tab-panel.is-entering .panel-copy > :nth-child(2) { animation-delay: .06s; }
.tab-panel.is-entering .panel-copy > :nth-child(3) { animation-delay: .12s; }
.tab-panel.is-entering .panel-copy > :nth-child(n+4) { animation-delay: .18s; }
@keyframes panel-in { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* Phones */
.phones { position: relative; height: 600px; }
.phone {
  position: absolute; left: 50%; top: 50%;
  width: 270px; height: 560px;
  padding: 10px;
  border-radius: 46px;
  background: linear-gradient(145deg, #2a3956, #0c1528 40%, #1d2a45);
  box-shadow: 0 0 0 1px rgba(255,255,255,.12) inset, 0 50px 90px -30px rgba(0,0,0,.9);
  transform: translate(-50%, -50%);
}
.phone::after {
  content: ""; position: absolute; top: 20px; left: 50%; transform: translateX(-50%);
  width: 84px; height: 24px; border-radius: 20px; background: #000; z-index: 2;
}
.phone .screen { position: relative; width: 100%; height: 100%; border-radius: 37px; overflow: hidden; background: #fff; }
.phone .screen img { width: 100%; height: auto; }
.phone--main { z-index: 3; }
.phone--main .screen img { animation: phone-scroll 26s ease-in-out infinite alternate; }
.phone--left, .phone--right { width: 230px; height: 480px; border-radius: 40px; opacity: .9; }
.phone--left .screen, .phone--right .screen { border-radius: 31px; }
.phone--left::after, .phone--right::after { width: 70px; height: 20px; top: 18px; }
.phone--left { transform: translate(-112%, -46%) rotate(-8deg); z-index: 1; }
.phone--right { transform: translate(12%, -54%) rotate(7deg); z-index: 2; }
@keyframes phone-scroll {
  0%, 8% { transform: translateY(0); }
  92%, 100% { transform: translateY(calc(-100% + 540px)); }
}

@media (max-width: 960px) {
  .system-head, .panel-grid { grid-template-columns: 1fr; }
  .phones { height: 540px; order: 2; }
  .phone { width: 240px; height: 500px; }
  @keyframes phone-scroll {
    0%, 8% { transform: translateY(0); }
    92%, 100% { transform: translateY(calc(-100% + 480px)); }
  }
  .phone--left, .phone--right { width: 200px; height: 420px; }
  .phone--left { transform: translate(-100%, -46%) rotate(-8deg); }
  .phone--right { transform: translate(0%, -54%) rotate(7deg); }
}
@media (max-width: 560px) {
  .tablist { display: grid; width: 100%; }
  .tab { padding: 12px 8px; font-size: 0.92rem; flex-direction: column; gap: 0; }
  .timeline { font-size: 0.66rem; }
}

/* ---------- Beyond the inbox ---------- */

.beyond { background: var(--bg-2); overflow: hidden; }
.beyond-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.beyond-copy .h-lg { margin-bottom: 32px; }
.beyond-copy p { color: var(--muted); font-size: 1.1rem; }
.beyond-copy p.intro { color: var(--text); }

.leaks { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.leak {
  display: grid; grid-template-columns: 52px 1fr; gap: 18px; align-items: center;
  padding: 20px 22px; border-radius: var(--radius); border: 1px solid var(--line);
  background: rgba(5, 13, 31, .5);
  transition: border-color .4s var(--ease), transform .4s var(--ease);
}
.leak:hover { border-color: rgba(159, 230, 245, .45); transform: translateX(-6px); }
.leak .icon { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: rgba(255, 143, 125, .1); color: var(--danger); }
.leak .icon svg { width: 24px; height: 24px; }
.leak strong { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; letter-spacing: -0.01em; }
.leak span { font-size: 0.9rem; color: var(--muted); }

.partners { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; padding: 0; list-style: none; }
.partners li { padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line-strong); font-size: 0.88rem; font-weight: 500; }
.partners li.is-hl { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

/* ---------- Work gallery ---------- */

.work-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; }
.carousel-controls { display: flex; gap: 10px; }
.icon-btn {
  width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--line-strong); background: transparent; color: var(--text); cursor: pointer;
  transition: background .3s var(--ease), color .3s var(--ease), opacity .3s;
}
.icon-btn:hover { background: #fff; color: var(--accent-ink); }
.icon-btn:disabled { opacity: .3; pointer-events: none; }
.icon-btn svg { width: 20px; height: 20px; }

.carousel {
  display: grid; grid-auto-flow: column; grid-auto-columns: clamp(220px, 22vw, 300px); gap: 20px;
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter);
  padding: clamp(40px, 5vw, 64px) var(--gutter) 24px;
  margin-top: 8px;
  scrollbar-width: none;
}
.carousel::-webkit-scrollbar { display: none; }
@media (min-width: 1320px) {
  .carousel { padding-inline: calc((100vw - var(--max)) / 2 + var(--gutter)); scroll-padding-inline: calc((100vw - var(--max)) / 2 + var(--gutter)); }
}
.work-card {
  scroll-snap-align: start;
  appearance: none; border: 0; padding: 0; background: none; color: inherit; text-align: left; cursor: zoom-in;
  font: inherit;
}
.work-card .frame {
  border-radius: 18px; overflow: hidden; background: var(--bg-2);
  aspect-ratio: 440 / 638;
  box-shadow: 0 30px 60px -30px rgba(0,0,0,.9);
  transition: transform .5s var(--ease), box-shadow .5s var(--ease);
}
.work-card img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .8s var(--ease); }
.work-card:hover .frame { transform: translateY(-8px); box-shadow: 0 40px 70px -30px rgba(33,153,191,.5); }
.work-card:hover img { transform: scale(1.03); }
.work-card .meta { display: block; margin-top: 14px; }
.work-card .client { display: block; font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--brand); font-weight: 600; }
.work-card .title { display: block; font-family: var(--font-display); font-weight: 500; font-size: 1rem; line-height: 1.3; margin-top: 4px; }

/* Lightbox */
.lightbox {
  width: min(760px, 100vw); max-width: 100vw; height: 100dvh; max-height: 100dvh;
  margin: 0 auto; padding: 0; border: 0; background: transparent; color: var(--text);
}
.lightbox::backdrop { background: rgba(2, 7, 18, .88); backdrop-filter: blur(6px); }
.lightbox[open] { display: flex; flex-direction: column; }
.lightbox-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px; flex: none;
}
.lightbox-bar .client { font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--brand); font-weight: 600; display: block; }
.lightbox-bar .title { font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; display: block; }
.lightbox-actions { display: flex; gap: 8px; flex: none; }
.lightbox-actions .icon-btn { width: 46px; height: 46px; background: rgba(5,13,31,.6); }
.lightbox-scroll { flex: 1; overflow-y: auto; padding: 0 16px 24px; overscroll-behavior: contain; }
.lightbox-scroll img { width: 100%; max-width: 640px; margin: 0 auto; border-radius: 14px; background: #fff; min-height: 60vh; }

/* ---------- Testimonials ---------- */

.quotes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: clamp(48px, 6vw, 80px); }
.quote {
  display: flex; flex-direction: column; gap: 28px;
  padding: clamp(24px, 3vw, 36px);
  border-radius: var(--radius-lg);
  background: var(--bg-2); border: 1px solid var(--line);
  margin: 0;
}
.quote:first-child { background: linear-gradient(160deg, #0d2d58, var(--bg-2) 70%); border-color: rgba(127,176,204,.3); }
.quote .mark { font-family: Georgia, serif; font-size: 4.5rem; line-height: .6; height: 28px; color: var(--accent); }
.quote blockquote { margin: 0; flex: 1; font-size: 1.04rem; line-height: 1.6; }
.quote figcaption { display: grid; grid-template-columns: 56px 1fr; gap: 14px; align-items: center; padding-top: 24px; border-top: 1px solid var(--line); }
.quote figcaption img.avatar { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; }
.quote .who strong { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.02rem; }
.quote .who span { font-size: 0.86rem; color: var(--muted); }
.quote .client-logo { grid-column: 1 / -1; height: 26px; width: auto; max-width: 150px; object-fit: contain; object-position: left; opacity: .7; margin-top: 6px; }

@media (max-width: 760px) { .quotes { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */

.faq-grid { display: grid; grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.faq-aside { position: sticky; top: 120px; }
.faq-aside p { color: var(--muted); margin-top: 24px; max-width: 32ch; }
.faq-list { display: grid; gap: 12px; }
.faq-item {
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  transition: background .4s var(--ease), border-color .4s var(--ease);
}
.faq-item[open] { background: var(--bg-2); border-color: rgba(159, 230, 245, .4); }
.faq-item summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: 22px 26px;
  font-family: var(--font-display); font-weight: 600; font-size: clamp(1.05rem, 1.6vw, 1.3rem); letter-spacing: -0.015em; line-height: 1.25;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item .plus {
  flex: none; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line-strong); position: relative;
  transition: transform .4s var(--ease), background .4s, border-color .4s;
}
.faq-item .plus::before, .faq-item .plus::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; background: currentColor; transform: translate(-50%, -50%); }
.faq-item .plus::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq-item[open] .plus { transform: rotate(45deg); background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.faq-answer { padding: 0 26px 24px; color: var(--muted); max-width: 70ch; }

@media (max-width: 860px) {
  .faq-grid { grid-template-columns: 1fr; }
  .faq-aside { position: static; }
  .faq-item summary { padding: 18px 20px; }
  .faq-answer { padding: 0 20px 20px; }
}

/* ---------- CTA ---------- */

.cta {
  position: relative; overflow: hidden; isolation: isolate;
  padding: clamp(96px, 14vw, 190px) 0;
}
.cta::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 80% at 80% 20%, rgba(33,153,191,.45), transparent 70%),
    linear-gradient(180deg, var(--bg) 0%, #061a3d 100%);
}
.cta-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.6fr); gap: 48px; align-items: end; }
.cta p { color: rgba(243, 246, 251, .78); font-size: 1.1rem; margin-bottom: 30px; }

@media (max-width: 860px) { .cta-grid { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--line); padding: 64px 0 40px; background: var(--bg); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer-grid img { height: 22px; width: auto; margin-bottom: 18px; }
.footer-grid p { color: var(--muted); max-width: 34ch; font-size: 0.95rem; }
.footer-grid .footer-h { margin: 0 0 14px; font-size: 0.75rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-grid a { text-decoration: none; font-family: var(--font-display); font-weight: 600; text-transform: uppercase; letter-spacing: 0.02em; }
.footer-grid a:hover { color: var(--accent); }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.85rem; }

@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > :first-child { grid-column: 1 / -1; } }

/* ---------- About page ---------- */

.page-hero { padding: clamp(150px, 18vw, 230px) 0 clamp(64px, 8vw, 110px); position: relative; overflow: hidden; isolation: isolate; }
.page-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(55% 70% at 85% 0%, rgba(33,153,191,.35), transparent 70%);
}
.page-hero .lead { max-width: 40ch; margin-top: 36px; color: var(--muted); }

.story { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(40px, 6vw, 96px); }
.story-aside { position: sticky; top: 120px; align-self: start; }
.steps { list-style: none; margin: 0; padding: 0; position: relative; }
.steps::before { content: ""; position: absolute; left: 7px; top: 10px; bottom: 10px; width: 1px; background: linear-gradient(var(--line-strong), var(--accent), var(--line-strong)); }
.step { position: relative; padding: 0 0 clamp(36px, 5vw, 56px) 48px; }
.step:last-child { padding-bottom: 0; }
.step::before {
  content: ""; position: absolute; left: 0; top: 8px; width: 15px; height: 15px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--brand);
}
.step.is-key::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 6px rgba(159,230,245,.15); }
.step .kicker { font-size: 0.75rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--brand); font-weight: 600; display: block; margin-bottom: 8px; }
.step p { font-size: 1.1rem; color: var(--muted); }
.step p.big { font-family: var(--font-display); font-weight: 500; font-size: clamp(1.3rem, 2.2vw, 1.75rem); line-height: 1.25; letter-spacing: -0.02em; color: var(--text); }
.step .chart-card { margin-top: 24px; }

.values { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: clamp(48px, 6vw, 80px); }
.value {
  padding: clamp(26px, 3.5vw, 44px); border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: var(--bg-2);
  transition: border-color .4s var(--ease), transform .4s var(--ease);
}
.value:hover { border-color: rgba(159,230,245,.4); transform: translateY(-4px); }
.value .n { font-family: var(--font-display); font-size: 0.9rem; color: var(--brand); letter-spacing: 0.08em; }
.value h3 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.03em; font-size: clamp(1.5rem, 2.6vw, 2.2rem); line-height: 1.05; margin: 40px 0 14px; }
.value p { color: var(--muted); margin: 0; }

@media (max-width: 860px) {
  .story { grid-template-columns: 1fr; }
  .story-aside { position: static; }
  .values { grid-template-columns: 1fr; }
}

/* ---------- Shared responsive ---------- */

@media (max-width: 960px) {
  .problem-grid, .team-grid, .beyond-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .signal-row { grid-template-columns: 1fr; }
  .btn { --bh: 54px; padding: 0 24px; font-size: 0.86rem; }
  .hero-actions .btn { width: 100%; }
}

/* ---------- Reveal on scroll ---------- */

.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }
.js .reveal[data-delay="1"] { transition-delay: .08s; }
.js .reveal[data-delay="2"] { transition-delay: .16s; }
.js .reveal[data-delay="3"] { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .js .reveal { opacity: 1; transform: none; }
  .fan-card, .metric-chip, .marquee, .phone--main .screen img { animation: none !important; }
}

/* ---------- Fixes ---------- */
.carousel { align-items: start; }
.work-card { display: flex; flex-direction: column; }
.cta-grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); }
.cta .btn { white-space: normal; text-align: center; max-width: 100%; }
.section, .hero { overflow-x: clip; }
.quote .client-logo--tall { height: 40px; }
.footer-legal {
  font-style: normal; display: flex; flex-wrap: wrap; gap: 6px 28px;
  margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line);
  color: var(--muted); font-size: 0.85rem;
}
.footer-legal strong { color: var(--text); font-weight: 600; }
.footer-legal + .footer-bottom { margin-top: 16px; padding-top: 0; border-top: 0; }

/* ---------- Cookie consent ---------- */
.cc-banner {
  position: fixed; z-index: 150; left: 24px; bottom: 24px;
  width: min(440px, calc(100vw - 32px));
  padding: 22px 22px 18px;
  border-radius: var(--radius);
  background: rgba(10, 22, 48, .96);
  border: 1px solid var(--line-strong);
  box-shadow: 0 30px 80px -20px rgba(0,0,0,.8);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  font-size: 0.9rem; line-height: 1.55; color: var(--muted);
  opacity: 0; transform: translateY(16px);
  transition: opacity .5s var(--ease), transform .5s var(--ease);
}
.cc-banner.is-in { opacity: 1; transform: none; }
.cc-title { margin: 0 0 8px; font-family: var(--font-display); font-size: 1.1rem; font-weight: 600; letter-spacing: -0.01em; color: var(--text); }
.cc-banner p { margin: 0 0 16px; }
.cc-banner a, .cc-modal a { color: var(--accent); }
.cc-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cc-btn {
  appearance: none; cursor: pointer; min-height: 44px; padding: 0 16px; border-radius: 999px;
  font-family: var(--font-display); font-weight: 600; font-size: 0.88rem;
  background: #fff; color: var(--accent-ink); border: 1px solid #fff;
  transition: background .25s var(--ease), border-color .25s var(--ease);
}
.cc-btn:hover { background: var(--accent); border-color: var(--accent); }
.cc-link {
  grid-column: 1 / -1; justify-self: center; appearance: none; background: none; border: 0; cursor: pointer;
  color: var(--text); font: inherit; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; padding: 6px;
}
.cc-link:hover { color: var(--accent); }

.cc-modal {
  width: min(560px, calc(100vw - 24px)); max-height: calc(100dvh - 24px);
  padding: 0; border-radius: var(--radius-lg); border: 1px solid var(--line-strong);
  background: var(--bg-2); color: var(--text); overflow: auto;
}
.cc-modal::backdrop { background: rgba(2, 7, 18, .75); backdrop-filter: blur(4px); }
.cc-form { padding: 26px; }
.cc-modal-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 10px; }
.cc-modal-head h2 { margin: 0; font-family: var(--font-display); font-size: 1.4rem; font-weight: 600; letter-spacing: -0.02em; }
.cc-close { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line-strong); background: transparent; color: var(--text); cursor: pointer; display: grid; place-items: center; }
.cc-close svg { width: 18px; height: 18px; }
.cc-intro { color: var(--muted); font-size: 0.92rem; margin-bottom: 18px; }
.cc-cat { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 10px; }
.cc-cat-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; cursor: pointer; }
.cc-cat h3 { margin: 0; font-family: var(--font-display); font-size: 1rem; font-weight: 600; }
.cc-cat p { margin: 6px 0 0; color: var(--muted); font-size: 0.88rem; }
.cc-always { font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); font-weight: 600; }
.cc-switch { position: relative; flex: none; width: 46px; height: 26px; }
.cc-switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.cc-switch span { position: absolute; inset: 0; border-radius: 999px; background: rgba(255,255,255,.18); transition: background .25s; pointer-events: none; }
.cc-switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .25s var(--ease); }
.cc-switch input:checked + span { background: var(--teal); }
.cc-switch input:checked + span::after { transform: translateX(20px); }
.cc-switch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.cc-actions--modal { grid-template-columns: repeat(3, 1fr); margin-top: 18px; }

@media (max-width: 560px) {
  .cc-banner { left: 12px; right: 12px; bottom: 12px; width: auto; }
  .cc-actions--modal { grid-template-columns: 1fr; }
  .cc-form { padding: 20px; }
}

/* ---------- Footer: legal links ---------- */
.footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
.footer-grid .footer-small a, .footer-grid .footer-small button { font-family: var(--font-body); text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 0.95rem; }
.footer-grid button { appearance: none; background: none; border: 0; padding: 0; color: inherit; cursor: pointer; }
.footer-grid button:hover { color: var(--accent); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- Legal pages ---------- */
.legal { padding: clamp(140px, 16vw, 200px) 0 clamp(80px, 10vw, 140px); }
.legal .container { max-width: 860px; }
.legal h1 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.04em; line-height: 1; font-size: clamp(2.4rem, 6vw, 4.2rem); margin: 0 0 16px; }
.legal .updated { color: var(--muted); font-size: 0.9rem; margin-bottom: 48px; }
.legal h2 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.02em; font-size: 1.45rem; margin: 48px 0 14px; padding-top: 24px; border-top: 1px solid var(--line); }
.legal h3 { font-family: var(--font-display); font-weight: 600; font-size: 1.08rem; margin: 26px 0 8px; }
.legal p, .legal li { color: #c9d4e3; font-size: 1rem; }
.legal ul { padding-left: 20px; margin: 0 0 1em; }
.legal li { margin-bottom: 6px; }
.legal a { color: var(--accent); }
.legal .table-wrap { overflow-x: auto; margin: 16px 0 24px; border: 1px solid var(--line); border-radius: 14px; }
.legal table { width: 100%; border-collapse: collapse; font-size: 0.9rem; min-width: 620px; }
.legal th, .legal td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.legal th { background: rgba(255,255,255,.04); font-weight: 600; color: var(--text); font-size: 0.8rem; letter-spacing: 0.04em; text-transform: uppercase; }
.legal td { color: #c9d4e3; }
.legal tr:last-child td { border-bottom: 0; }
.legal code { font-size: 0.86em; background: rgba(255,255,255,.07); padding: 2px 6px; border-radius: 6px; }
.legal dl { display: grid; grid-template-columns: minmax(160px, 240px) 1fr; gap: 0; margin: 0; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.legal dt, .legal dd { margin: 0; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.legal dt { color: var(--muted); font-size: 0.9rem; background: rgba(255,255,255,.03); }
.legal dd { color: var(--text); }
.legal dl > :nth-last-child(-n+2) { border-bottom: 0; }
@media (max-width: 560px) { .legal dl { grid-template-columns: 1fr; } .legal dt { border-bottom: 0; padding-bottom: 2px; } }
.todo { background: rgba(255, 214, 102, .18); color: #ffd666; padding: 1px 6px; border-radius: 6px; font-weight: 600; }

/* ---------- Blog: listing ---------- */
.blog-hero { text-align: center; padding-bottom: clamp(24px, 4vw, 48px); }
.blog-hero .container { display: flex; flex-direction: column; align-items: center; }
.blog-hero .lead { margin-top: 0; color: var(--muted); }
.blog-list { padding-top: clamp(24px, 4vw, 48px); }

.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.post-card {
  display: flex; flex-direction: column; text-decoration: none; color: inherit;
  border-radius: var(--radius-lg); border: 1px solid var(--line); background: var(--bg-2);
  overflow: hidden;
  transition: border-color .4s var(--ease), transform .4s var(--ease), box-shadow .4s var(--ease);
}
.post-card:hover { border-color: rgba(159,230,245,.4); transform: translateY(-6px); box-shadow: 0 30px 60px -30px rgba(33,153,191,.45); }
.post-card-cover { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-3); }
.post-card-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.post-card:hover .post-card-cover img { transform: scale(1.04); }
.post-card-body { display: flex; flex-direction: column; gap: 10px; padding: 22px 24px 26px; flex: 1; }
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 0.82rem; color: var(--muted); margin: 0; }
.post-card-title { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; line-height: 1.2; letter-spacing: -0.02em; }
.post-card-excerpt { color: var(--muted); font-size: 0.95rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.post-card-more { margin-top: auto; padding-top: 8px; display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 600; font-size: 0.85rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.post-card-more svg { width: 16px; height: 16px; transition: transform .35s var(--ease); }
.post-card:hover .post-card-more svg { transform: translateX(4px); }

.post-card--featured { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
.post-card--featured .post-card-cover { aspect-ratio: auto; min-height: 340px; }
.post-card--featured .post-card-body { padding: clamp(28px, 4vw, 48px); justify-content: center; }
.post-card--featured .post-card-title { font-size: clamp(1.7rem, 3vw, 2.5rem); }
.post-card--featured .post-card-excerpt { -webkit-line-clamp: 5; font-size: 1.05rem; }
.post-card--featured .post-card-more { margin-top: 12px; }

/* Cover used when a post has no image */
.cover-fallback {
  position: relative; display: flex; align-items: flex-end; width: 100%; height: 100%; min-height: 100%;
  padding: 24px; overflow: hidden;
}
.cover-fallback span {
  position: relative; font-family: "Instrument Serif", Georgia, serif; font-style: italic;
  font-size: clamp(1.5rem, 2.4vw, 2.2rem); line-height: 1.05; color: rgba(255,255,255,.92);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.cover-fallback::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,.07) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.07) 1px, transparent 1px);
  background-size: 32px 32px;
  -webkit-mask-image: linear-gradient(to top, transparent, #000); mask-image: linear-gradient(to top, transparent, #000);
}
.cover-fallback--0 { background: linear-gradient(135deg, #2199bf, #0b3c74 60%, #071a3d); }
.cover-fallback--1 { background: linear-gradient(135deg, #0f6e8c, #0a2a55 55%, #050d1f); }
.cover-fallback--2 { background: linear-gradient(135deg, #3d7ea6, #12305c 60%, #06122b); }
.cover-fallback--3 { background: linear-gradient(135deg, #1c8fa8, #173a6b 55%, #0a1630); }
.post-card--featured .cover-fallback span { font-size: clamp(2rem, 4vw, 3.4rem); }

.empty-state { text-align: center; padding: 64px 24px; border: 1px dashed var(--line-strong); border-radius: var(--radius-lg); color: var(--muted); font-size: 1.1rem; }

@media (max-width: 1024px) { .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .post-grid { grid-template-columns: 1fr; }
  .post-card--featured { grid-template-columns: 1fr; }
  .post-card--featured .post-card-cover { min-height: 0; aspect-ratio: 16 / 10; }
}

/* ---------- Blog: article ---------- */
.post-narrow { max-width: 780px; }
.post-hero { padding: clamp(130px, 15vw, 180px) 0 clamp(32px, 5vw, 56px); position: relative; isolation: isolate; }
.post-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(50% 70% at 50% 0%, rgba(33,153,191,.28), transparent 70%); }
.post-back { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--muted); font-size: 0.9rem; font-weight: 500; margin-bottom: 28px; }
.post-back:hover { color: var(--accent); }
.post-back svg { width: 16px; height: 16px; }
.post-title { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.04em; line-height: 1.02; font-size: clamp(2.3rem, 5.4vw, 4.2rem); margin: 18px 0 22px; text-wrap: balance; }
.post-hero .lead { color: var(--muted); }
.post-cover { margin: 0 auto clamp(40px, 6vw, 72px); max-width: 1100px; }
.post-cover img { width: 100%; height: auto; border-radius: var(--radius-lg); }

.prose { font-size: 1.12rem; line-height: 1.75; color: #d3dceb; padding-bottom: clamp(64px, 9vw, 120px); }
.prose > * + * { margin-top: 1.1em; }
.prose p { margin-bottom: 0; }
.prose h2 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.025em; line-height: 1.15; font-size: clamp(1.6rem, 2.8vw, 2.1rem); color: var(--text); margin-top: 2em; }
.prose h3 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.015em; font-size: 1.35rem; color: var(--text); margin-top: 1.6em; }
.prose a { color: var(--accent); }
.prose strong { color: var(--text); }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .4em; }
.prose li::marker { color: var(--brand); }
.prose blockquote {
  margin: 1.6em 0; padding: 4px 0 4px 24px; border-left: 3px solid var(--accent);
  font-family: "Instrument Serif", Georgia, serif; font-style: italic; font-size: 1.55rem; line-height: 1.35; color: var(--text);
}
.prose blockquote p { margin: 0; }
.prose img { width: 100%; height: auto; border-radius: var(--radius); margin: 1.6em 0; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
.prose code { font-size: .9em; background: rgba(255,255,255,.07); padding: 2px 6px; border-radius: 6px; }
.prose table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.prose th { color: var(--text); }

.related { padding-top: clamp(64px, 8vw, 110px); }
.related .h-lg { margin-bottom: 40px; }
.post-grid--related .post-card--featured { grid-column: auto; display: flex; }
.post-cover img { max-height: 640px; object-fit: cover; }

/* ---------- Touch targets ---------- */
.footer-grid li a, .footer-grid li button { display: inline-block; padding: 6px 0; }
.footer-grid ul { gap: 2px; }
.brand { padding: 12px 0; }
.post-back { padding: 6px 0; }

/* ---------- Above-the-fold content animates with CSS, without waiting for JS ---------- */
.js .hero .reveal, .js .page-hero .reveal, .js .post-hero .reveal {
  opacity: 1; transform: none; transition: none;
  animation: rise .9s var(--ease) both;
}
.js .hero .reveal[data-delay="1"], .js .page-hero .reveal[data-delay="1"], .js .post-hero .reveal[data-delay="1"] { animation-delay: .08s; }
.js .hero .reveal[data-delay="2"], .js .page-hero .reveal[data-delay="2"], .js .post-hero .reveal[data-delay="2"] { animation-delay: .16s; }
.js .hero .reveal[data-delay="3"], .js .page-hero .reveal[data-delay="3"], .js .post-hero .reveal[data-delay="3"] { animation-delay: .24s; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }

/* Lightbox header on small screens */
.lightbox-bar > div:first-child { min-width: 0; flex: 1; }
.lightbox-bar .title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 560px) {
  .lightbox-bar { padding: 12px; gap: 8px; }
  .lightbox-actions { gap: 6px; }
  .lightbox-actions .icon-btn { width: 40px; height: 40px; }
  .lightbox-actions .icon-btn svg { width: 18px; height: 18px; }
}
.serif .amp { font-style: normal; }

/* ---------- Subscribe stage: animated plan picker ---------- */
.picker-demo { position: relative; display: flex; justify-content: center; padding: 24px 0; }
.picker-demo::before {
  content: ""; position: absolute; inset: 10% 5%; z-index: 0; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(33,153,191,.35), transparent);
  filter: blur(20px);
}
.pd-card {
  position: relative; z-index: 1; width: min(430px, 100%);
  padding: 22px; border-radius: 24px;
  background: #fff; color: #0b1a33;
  font-family: var(--font-body); font-size: 14px; line-height: 1.35;
  box-shadow: 0 50px 90px -30px rgba(0,0,0,.85), 0 0 0 1px rgba(255,255,255,.1);
}
.pd-product { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.pd-thumb { width: 54px; height: 54px; flex: none; border-radius: 14px; display: grid; place-items: center; color: #fff; background: linear-gradient(140deg, #2199bf, #0b3c74); }
.pd-thumb svg { width: 30px; height: 30px; }
.pd-name { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.15rem; letter-spacing: -0.01em; }
.pd-rating { display: block; font-size: 12px; color: #5b6b82; margin-top: 2px; }
.pd-stars { color: #f5a623; letter-spacing: 1px; }

.pd-toggle { display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 999px; background: #eef2f7; margin-bottom: 14px; font-weight: 600; font-size: 13px; text-align: center; }
.pd-toggle span { padding: 8px 0; border-radius: 999px; color: #5b6b82; }
.pd-toggle .is-on { background: #fff; color: #0b1a33; box-shadow: 0 2px 8px rgba(4,18,42,.12); }

.pd-plans { display: grid; gap: 10px; }
.pd-plan {
  position: relative; display: grid; grid-template-columns: 20px 1fr auto; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 14px; border: 1.5px solid #dfe5ee; background: #fff;
  transition: border-color .35s var(--ease), background .35s var(--ease), transform .35s var(--ease);
}
.pd-plan strong { font-weight: 600; }
.pd-plan small { display: block; font-size: 12px; color: #6a7a90; margin-top: 2px; }
.pd-plan-price { text-align: right; }
.pd-plan-price strong { display: block; font-family: var(--font-display); font-size: 1.05rem; }
.pd-save { display: inline-block; margin-top: 3px; padding: 2px 8px; border-radius: 999px; background: #e3f6e9; color: #1d7a3d; font-size: 11px; font-weight: 600; white-space: nowrap; }
.pd-radio { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid #b9c4d3; position: relative; transition: border-color .3s, background .3s; }
.pd-radio::after { content: ""; position: absolute; inset: 4px; border-radius: 50%; background: #fff; transform: scale(0); transition: transform .3s var(--ease); }
.pd-plan.is-selected { border-color: #2199bf; background: #eef8fc; }
.pd-plan.is-selected .pd-radio { border-color: #2199bf; background: #2199bf; }
.pd-plan.is-selected .pd-radio::after { transform: scale(1); }
.pd-plan.is-pressed { transform: scale(.98); }
.pd-tag { position: absolute; top: -9px; right: 14px; padding: 2px 9px; border-radius: 999px; background: #04122a; color: #fff; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

.pd-perks { list-style: none; margin: 14px 0 16px; padding: 0; display: grid; gap: 4px; font-size: 12.5px; color: #3f4f66; }
.pd-perks li::before { content: "✓"; color: #1d7a3d; font-weight: 700; margin-right: 8px; }

.pd-cta {
  position: relative; display: grid; place-items: center; height: 50px; border-radius: 999px; overflow: hidden;
  background: #04122a; color: #fff;
  font-family: var(--font-display); font-weight: 600; font-size: 14px; letter-spacing: .06em; text-transform: uppercase;
  transition: background .35s var(--ease), transform .2s var(--ease);
}
.pd-cta > span { grid-area: 1 / 1; display: inline-flex; align-items: center; gap: 8px; transition: opacity .3s, transform .4s var(--ease); }
.pd-cta-done { opacity: 0; transform: translateY(14px); text-transform: none; letter-spacing: 0; font-size: 14.5px; }
.pd-cta-done svg { width: 18px; height: 18px; }
.pd-cta.is-pressed { transform: scale(.97); }
.pd-cta.is-done { background: #1d8a4a; }
.pd-cta.is-done .pd-cta-label { opacity: 0; transform: translateY(-14px); }
.pd-cta.is-done .pd-cta-done { opacity: 1; transform: none; }

.pd-cursor {
  position: absolute; z-index: 5; left: 0; top: 0; width: 28px; height: 28px;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,.35));
  transition: transform .65s cubic-bezier(.45,.05,.25,1), opacity .3s;
  pointer-events: none; opacity: 0;
}
.pd-cursor.is-click { animation: pd-click .35s ease; }
@keyframes pd-click { 50% { scale: .82; } }

@media (max-width: 960px) { .picker-demo { order: 2; } }
@media (max-width: 420px) { .pd-card { padding: 16px; } .pd-plan { padding: 10px 12px; gap: 10px; } }
@media (prefers-reduced-motion: reduce) { .pd-cursor { display: none; } }
.pd-card strong { color: #0b1a33; }

/* ---------- Blog: author ---------- */
.post-byline {
  display: inline-flex; align-items: center; gap: 14px; margin-top: 28px;
  text-decoration: none; color: inherit;
}
.post-byline img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px rgba(159,230,245,.45); }
.post-byline-text strong { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.02rem; }
.post-byline-text span { display: block; font-size: 0.88rem; color: var(--muted); }
a.post-byline:hover strong { color: var(--accent); }
.post-avatar-sm { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }
.post-author-sm { color: var(--text); font-weight: 500; }
.footer-grid a.footer-email { font-family: var(--font-body); text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 0.95rem; }
@media (max-width: 760px) { .footer-grid > :nth-child(3) { grid-column: 1 / -1; } }

/* ---------- About: team ---------- */
.team-grid-people { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: clamp(48px, 6vw, 80px); }
.member { margin: 0; }
.member-photo {
  position: relative; aspect-ratio: 4 / 5; border-radius: var(--radius-lg); overflow: hidden;
  border: 1px solid var(--line);
  background: linear-gradient(150deg, #2199bf, #0b3c74 55%, #071a3d);
}
.member-photo img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.05);
  transition: filter .6s var(--ease), transform .8s var(--ease);
}
.member:hover .member-photo img { filter: grayscale(0); transform: scale(1.03); }
.member-initial {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-family: "Instrument Serif", Georgia, serif; font-style: italic; font-size: clamp(5rem, 10vw, 8rem); color: rgba(255,255,255,.85);
}
.member-name { margin: 20px 0 4px; font-family: var(--font-display); font-weight: 600; font-size: 1.35rem; letter-spacing: -0.02em; }
.member-role { margin: 0; color: var(--muted); font-size: 0.95rem; }
@media (max-width: 860px) { .team-grid-people { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .team-grid-people { grid-template-columns: 1fr; } }
.faq-answer a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.faq-answer a:hover { color: #fff; }
