/* ═══════════════════════════════════════════════════════════════════
   Ardena Design System — shared across all pages
   Light + dark mode · Inter Tight · Instrument Serif · JetBrains Mono
   ═══════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Inter+Tight:ital,wght@0,200;0,300;0,400;0,500;1,200;1,300&family=Instrument+Serif:ital@1&family=JetBrains+Mono:wght@400&display=swap');

/* ── Tokens ──────────────────────────────────────────────────────── */
:root {
  --font-sans: "Inter Tight", -apple-system, system-ui, sans-serif;
  --font-serif: "Instrument Serif", "Times New Roman", serif;
  --font-mono: "JetBrains Mono", monospace;

  /* Light (default) */
  --bg:        #F7F4EE;
  --bg-soft:   #EFEAE0;
  --bg-card:   #FBF8F2;
  --fg:        #141210;
  --fg-soft:   rgba(20,18,16,0.62);
  --fg-faint:  rgba(20,18,16,0.38);
  --line:      rgba(20,18,16,0.14);
  --line-str:  rgba(20,18,16,0.28);
  --accent:    #B66A2C;
  --accent-gl: rgba(182,106,44,0.18);
  --inv-bg:    #141210;
  --inv-fg:    #F5E9D2;
}
[data-theme="dark"] {
  --bg:        #0F0E0C;
  --bg-soft:   #161412;
  --bg-card:   #1A1816;
  --fg:        #F5E9D2;
  --fg-soft:   rgba(245,233,210,0.7);
  --fg-faint:  rgba(245,233,210,0.42);
  --line:      rgba(245,233,210,0.12);
  --line-str:  rgba(245,233,210,0.26);
  --accent:    #D69458;
  --accent-gl: rgba(214,148,88,0.22);
  --inv-bg:    #F7F4EE;
  --inv-fg:    #141210;
}

/* ── Reset ───────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
html, body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background 0.6s ease, color 0.6s ease;
}
a { color: inherit; text-decoration: none; cursor: pointer; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
img { display: block; max-width: 100%; }

/* ── Type scale ──────────────────────────────────────────────────── */
.h-display {
  font-family: var(--font-sans);
  font-weight: 200;
  letter-spacing: -0.04em;
  line-height: 0.92;
}
.h-section {
  font-family: var(--font-sans);
  font-weight: 200;
  letter-spacing: -0.035em;
  line-height: 0.96;
}
.h-card {
  font-family: var(--font-sans);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.serif-italic {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  color: var(--accent);
}
.mono-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

/* ── Logo ────────────────────────────────────────────────────────── */
.brand-word {
  font-family: var(--font-sans);
  font-weight: 500;
  font-style: normal;
  letter-spacing: -0.02em;
  font-size: 24px;
}
.brand-word .dot { color: var(--accent); }
.nav-drawer-brand .brand-word { font-size: 28px; }

/* ── Buttons ─────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 26px;
  border-radius: 100px;
  font-size: 14px; letter-spacing: 0.01em;
  border: 1px solid transparent;
  font-family: inherit; font-weight: 400;
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.btn-primary:hover { background: var(--accent); border-color: var(--accent); color: #141210; }
.btn-ghost { background: transparent; color: var(--fg); border-color: var(--line-str); }
.btn-ghost:hover { border-color: var(--fg); }
.btn-accent { background: var(--accent); color: #141210; border-color: var(--accent); }
.btn-accent:hover { filter: brightness(1.08); }
.btn-sm { padding: 10px 18px; font-size: 13px; }

/* ── Layout ──────────────────────────────────────────────────────── */
.shell { padding: 0 56px; max-width: 1640px; margin: 0 auto; }
.rule { height: 1px; background: var(--line); }

/* ── Header ──────────────────────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 80;
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 18px 56px;
  backdrop-filter: blur(14px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  border-bottom: 1px solid var(--line);
  transition: background 0.4s ease;
}
.nav-l { display: flex; align-items: center; }
.nav-c { display: flex; gap: 28px; font-size: 13px; }
.nav-c a {
  padding: 8px 0; position: relative;
  transition: color 0.3s ease;
}
.nav-c a::after {
  content: ''; position: absolute; left: 0; bottom: 4px;
  height: 1px; width: 0; background: var(--accent);
  transition: width 0.3s ease;
}
.nav-c a:hover { color: var(--accent); }
.nav-c a:hover::after, .nav-c a.is-active::after { width: 100%; }
.nav-r { display: flex; justify-content: flex-end; gap: 12px; align-items: center; }

/* ── Theme toggle ────────────────────────────────────────────────── */
.theme-toggle {
  width: 44px; height: 26px; border-radius: 100px;
  background: var(--bg-soft); border: 1px solid var(--line-str);
  position: relative; cursor: pointer;
  transition: background 0.3s ease, border-color 0.3s ease;
}
.theme-toggle .knob {
  position: absolute; top: 2px; left: 2px;
  width: 20px; height: 20px; border-radius: 100px;
  background: var(--fg);
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), background 0.4s ease;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; color: var(--bg);
}
[data-theme="dark"] .theme-toggle .knob { transform: translateX(18px); }

/* ── Currency toggle ─────────────────────────────────────────────── */
.currency-toggle {
  height: 26px; padding: 0 10px; border-radius: 100px;
  background: var(--bg-soft); border: 1px solid var(--line-str);
  color: var(--fg); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}
.currency-toggle .cur-code {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em;
  line-height: 1;
}
.currency-toggle:hover { color: var(--accent); border-color: var(--accent); }

/* ── Marquee ─────────────────────────────────────────────────────── */
.marquee {
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 22px 0;
  /* Mark visible immediately — no .rv fade dependency, so the animation
     is always running by the time the user sees it on mobile. */
  opacity: 1; transform: none;
}
.marquee-track {
  display: flex; gap: 56px; white-space: nowrap;
  animation: ardena-marquee 18s linear infinite;
  font-family: var(--font-serif); font-size: 32px; font-style: italic;
  will-change: transform;
}
.marquee-track .star { color: var(--accent); }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes ardena-marquee {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}
@media (max-width: 720px) {
  .marquee { padding: 14px 0; }
  .marquee-track { animation-duration: 9s !important; gap: 24px !important; font-size: 22px; }
}

/* ── Scroll-reveal ───────────────────────────────────────────────── */
.rv {
  opacity: 0; transform: translateY(28px);
  transition:
    opacity 0.9s cubic-bezier(0.2, 0.8, 0.1, 1),
    transform 0.9s cubic-bezier(0.2, 0.8, 0.1, 1);
}
.rv.is-in { opacity: 1; transform: translateY(0); }
.rv-line { display: inline-block; overflow: hidden; padding-bottom: 0.08em; }
.rv-line span {
  display: inline-block; transform: translateY(110%);
  transition: transform 0.9s cubic-bezier(0.2, 0.8, 0.1, 1);
}
.rv-line.is-in span { transform: translateY(0); }

/* ── Stat counter gradient ───────────────────────────────────────── */
.stat-num {
  display: inline-block;
  background-image: linear-gradient(180deg, var(--fg) 50%, var(--accent) 50%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  background-size: 100% 200%; background-position: 0 0;
  transition: background-position 0.7s cubic-bezier(0.2, 0.8, 0.1, 1);
}
.rv.is-in .stat-num { background-position: 0 100%; }

/* ── Row hover (services / journal / industries) ─────────────────── */
.hover-row {
  position: relative;
  transition: padding-left 0.4s ease;
}
.hover-row::before {
  content: ''; position: absolute; inset: 0;
  background: var(--bg-soft);
  transform: scaleY(0); transform-origin: bottom;
  transition: transform 0.55s cubic-bezier(0.65, 0, 0.35, 1);
  z-index: 0;
}
.hover-row > * { position: relative; z-index: 1; }
.hover-row:hover::before { transform: scaleY(1); transform-origin: top; }
.hover-row:hover { padding-left: 16px; }
.hover-row .arrow { transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1); }
.hover-row:hover .arrow { transform: translate(6px, -6px); }

/* ── Service card (grid) ─────────────────────────────────────────── */
.svc-card {
  padding: 40px 40px 60px;
  border-bottom: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 14px;
  position: relative;
  transition: background 0.4s ease;
}
.svc-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--bg-soft);
  transform: scaleY(0); transform-origin: bottom;
  transition: transform 0.55s cubic-bezier(0.65, 0, 0.35, 1);
  z-index: 0;
}
.svc-card > * { position: relative; z-index: 1; }
.svc-card:hover::before { transform: scaleY(1); transform-origin: top; }
.svc-card .arrow { transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1); }
.svc-card:hover .arrow { transform: translate(6px, -6px); }

/* ── Placeholder images ──────────────────────────────────────────── */
.placeholder {
  position: relative; overflow: hidden;
  background:
    repeating-linear-gradient(135deg,
      color-mix(in srgb, var(--fg) 8%, transparent) 0 1px,
      transparent 1px 14px),
    var(--bg-soft);
  border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.1, 1);
}
.placeholder:hover { transform: scale(1.012); }
.placeholder .label {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em;
  color: var(--fg-faint); text-transform: lowercase;
  padding: 4px 10px; background: var(--bg); border: 1px solid var(--line);
}

/* ── Page head ───────────────────────────────────────────────────── */
.page-head { padding-block: 100px 80px; }
.page-head h1 {
  font-size: clamp(48px, 8vw, 140px);
  font-weight: 200; letter-spacing: -0.04em; line-height: 0.94;
  margin: 24px 0 0;
}
.page-head .crumb {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--fg-faint);
  display: flex; gap: 10px;
}
.page-head .lede {
  font-size: 22px; line-height: 1.45; max-width: 720px;
  color: var(--fg-soft); margin: 40px 0 0; font-weight: 300;
}

/* ── Progress bar (blog posts) ───────────────────────────────────── */
#read-progress {
  position: fixed; top: 0; left: 0; z-index: 200;
  height: 3px; width: 0; background: var(--accent);
  transition: width 0.1s linear;
}

/* ── Footer ──────────────────────────────────────────────────────── */
.site-footer {
  background: var(--inv-bg); color: var(--inv-fg);
  padding: 80px 56px 0;
}
.ft-mark {
  font-family: var(--font-sans); font-weight: 200;
  letter-spacing: -0.06em;
  font-size: clamp(140px, 22vw, 360px); line-height: 0.85;
  padding: 40px 0 20px;
  border-bottom: 1px solid color-mix(in srgb, var(--inv-fg) 16%, transparent);
  /* Continuous color travel: beige -> orange -> beige, looping */
  background: linear-gradient(
    90deg,
    var(--inv-fg) 0%,
    var(--inv-fg) 30%,
    var(--accent) 50%,
    var(--inv-fg) 70%,
    var(--inv-fg) 100%
  );
  background-size: 220% 100%;
  background-position: 100% 0%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: ft-mark-flow 7s linear infinite;
}
@keyframes ft-mark-flow {
  from { background-position: 100% 0%; }
  to   { background-position: -100% 0%; }
}
@media (prefers-reduced-motion: reduce) {
  .ft-mark { animation: none; background-position: 0% 0%; }
}
.ft-cta {
  font-family: var(--font-serif); font-style: italic;
  font-size: 48px; line-height: 1; letter-spacing: -0.02em;
  color: var(--inv-fg); margin: 0 0 20px;
}
.ft-cols {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 64px; padding: 60px 0;
}
.ft-line { font-size: 15px; line-height: 1.6; color: color-mix(in srgb, var(--inv-fg) 80%, transparent); }
.ft-bottom {
  display: flex; justify-content: space-between;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.18em;
  text-transform: uppercase; color: color-mix(in srgb, var(--inv-fg) 50%, transparent);
  padding: 24px 0;
  border-top: 1px solid color-mix(in srgb, var(--inv-fg) 12%, transparent);
}

/* ── Featured post (journal) — desktop 2-col, mobile stacked ─────── */
.featured-post {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
  text-decoration: none;
  color: inherit;
}
@media (max-width: 720px) {
  .featured-post {
    grid-template-columns: 1fr;
    gap: clamp(20px, 4vw, 32px);
    align-items: stretch;
  }
}

/* ── Stats grid — 2 cols × 3 rows at every viewport ───────────────── */
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; }
.stat-cell {
  padding: clamp(28px, 4vw, 48px) clamp(20px, 3vw, 32px);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
/* Clean edges: every 2nd cell drops its right border (right edge),
   last two cells (bottom row) drop their bottom border. */
.stats-grid > *:nth-child(2n) { border-right: none; }
.stats-grid > *:nth-last-child(-n+2) { border-bottom: none; }
.stat-cell--last { border-right: none; }
.stat-num {
  font-family: var(--font-sans);
  font-size: clamp(44px, 5vw, 72px);
  font-weight: 200; letter-spacing: -0.04em; line-height: 1;
  margin-bottom: 12px;
  color: var(--accent);
}
.stat-cell .mono-label {
  font-size: 12px; letter-spacing: 0.22em;
}
@media (max-width: 520px) {
  .stat-cell { padding: clamp(18px, 4vw, 24px) clamp(14px, 3vw, 20px); }
  .stat-num { font-size: clamp(32px, 8vw, 44px); margin-bottom: 8px; }
}

/* ── Dodecahedron ────────────────────────────────────────────────── */
.hero-stage { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; position: relative; }
.dodeca-col { position: relative; min-height: 520px; }

/* Mobile: dodecahedron is hidden completely. The 3D + perspective
   animation was causing scroll stutter on phones; backdrop variant
   was also performance-heavy. Hero collapses to single-column copy. */
@media (max-width: 900px) {
  .hero-stage { grid-template-columns: 1fr; }
  .dodeca-col { display: none; }
  /* Stop the spin animation on the actual element so it doesn't burn
     CPU even when display:none is computed (some browsers still tick). */
  .dodecahedron { animation: none; }
}
.dodeca-wrap {
  position: relative; width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  perspective: 1200px; perspective-origin: 50% 50%;
}
.dodecahedron {
  width: 260px; height: 260px;
  transform-style: preserve-3d;
  animation: dodeca-spin 80s linear infinite, dodeca-jump 6s ease-in-out infinite;
}
.pentagon {
  position: absolute; width: 100%; height: 100%;
  transform-style: preserve-3d;
}
.pentagon::before {
  content: '';
  position: absolute; inset: 0;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  transform: rotateX(26.57deg) translateZ(69px);
  clip-path: polygon(50% 0%, 100% 38%, 82% 100%, 18% 100%, 0% 38%);
}
.pentagon:nth-child(1)  { transform: rotateY(0turn); }
.pentagon:nth-child(2)  { transform: rotateY(0.2turn); }
.pentagon:nth-child(3)  { transform: rotateY(0.4turn); }
.pentagon:nth-child(4)  { transform: rotateY(0.6turn); }
.pentagon:nth-child(5)  { transform: rotateY(0.8turn); }
.pentagon:nth-child(6)  { transform: rotateY(0turn)   rotateX(180deg); }
.pentagon:nth-child(7)  { transform: rotateY(0.2turn) rotateX(180deg); }
.pentagon:nth-child(8)  { transform: rotateY(0.4turn) rotateX(180deg); }
.pentagon:nth-child(9)  { transform: rotateY(0.6turn) rotateX(180deg); }
.pentagon:nth-child(10) { transform: rotateY(0.8turn) rotateX(180deg); }
.pentagon:nth-child(11) { transform: rotateY(0turn)   rotateX(90deg); }
.pentagon:nth-child(12) { transform: rotateY(0turn)   rotateX(270deg); }
@keyframes dodeca-spin {
  from { transform: rotateX(0deg) rotateY(360deg) rotateZ(360deg); }
  to   { transform: rotateX(360deg) rotateY(0deg) rotateZ(-360deg); }
}
@keyframes dodeca-jump {
  0%, 100% { margin-top: 0; }
  50%       { margin-top: -20px; }
}

/* ── Float ───────────────────────────────────────────────────────── */
.float-slow { animation: ardena-float 9s ease-in-out infinite; }
@keyframes ardena-float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-10px); }
}

/* ── Form inputs ─────────────────────────────────────────────────── */
.field {
  width: 100%; padding: 16px 20px;
  background: var(--bg-card); border: 1px solid var(--line);
  color: var(--fg); font-family: var(--font-sans); font-size: 15px; font-weight: 300;
  border-radius: 4px; outline: none;
  transition: border-color 0.3s ease;
}
.field:focus { border-color: var(--accent); }
.field::placeholder { color: var(--fg-faint); }
textarea.field { resize: vertical; min-height: 140px; }

/* ── Card border ─────────────────────────────────────────────────── */
.card-line { border-top: 1px solid var(--line); }

/* ── Tag pills ───────────────────────────────────────────────────── */
.tag {
  display: inline-flex; align-items: center;
  padding: 6px 14px; border-radius: 100px;
  border: 1px solid var(--line); font-size: 12px;
  color: var(--fg-soft); cursor: pointer;
  transition: all 0.25s ease;
}
.tag:hover, .tag.active {
  border-color: var(--accent); color: var(--accent);
}

/* ── Hamburger button (mobile only) ──────────────────────────────── */
.hamburger {
  display: none;
  width: 36px; height: 36px;
  position: relative;
  background: transparent; border: none;
  padding: 0; cursor: pointer;
  align-items: center; justify-content: center;
}
.hamburger .bar {
  position: absolute; left: 8px; right: 8px;
  height: 1px; background: var(--fg);
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.1, 1),
              opacity 0.25s ease, top 0.35s cubic-bezier(0.2, 0.8, 0.1, 1);
}
.hamburger .bar:nth-child(1) { top: 11px; }
.hamburger .bar:nth-child(2) { top: 17px; }
.hamburger .bar:nth-child(3) { top: 23px; }
.hamburger.is-open .bar:nth-child(1) { top: 17px; transform: rotate(45deg); }
.hamburger.is-open .bar:nth-child(2) { opacity: 0; }
.hamburger.is-open .bar:nth-child(3) { top: 17px; transform: rotate(-45deg); }

/* ── Mobile nav drawer ───────────────────────────────────────────── */
.nav-drawer {
  position: fixed; top: 0; left: 0; right: 0;
  height: 100vh; height: 100dvh;
  z-index: 90;
  opacity: 0; visibility: hidden;
  transform: translateY(-12px);
  transition:
    opacity 0.4s cubic-bezier(0.2, 0.8, 0.1, 1),
    transform 0.4s cubic-bezier(0.2, 0.8, 0.1, 1),
    visibility 0s linear 0.4s;
}
.nav-drawer.is-open {
  opacity: 1; visibility: visible;
  transform: translateY(0);
  transition:
    opacity 0.4s cubic-bezier(0.2, 0.8, 0.1, 1),
    transform 0.4s cubic-bezier(0.2, 0.8, 0.1, 1),
    visibility 0s linear 0s;
}
.nav-drawer-panel {
  position: relative;
  width: 100%; height: 100%;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  padding: 80px 24px 40px;
  display: flex; flex-direction: column; gap: 8px;
  overflow-y: auto;
}
.nav-drawer-brand {
  position: absolute; top: 18px; left: 24px;
}
.nav-drawer-close {
  position: absolute; top: 14px; right: 16px;
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  background: transparent; border: 1px solid var(--line);
  border-radius: 100px;
  cursor: pointer; color: var(--fg);
  font-family: var(--font-sans); font-size: 22px; font-weight: 200; line-height: 1;
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.nav-drawer-close:hover { border-color: var(--accent); color: var(--accent); transform: rotate(90deg); }
.nav-drawer-link {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  align-items: baseline;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-sans);
  font-weight: 300;
  letter-spacing: -0.02em;
  font-size: clamp(28px, 7vw, 40px);
  line-height: 1.1;
  color: var(--fg);
  position: relative;
  transition: color 0.3s ease, padding-left 0.35s cubic-bezier(0.2, 0.8, 0.1, 1);
}
.nav-drawer-link .nav-drawer-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-faint);
}
.nav-drawer-link .nav-drawer-arrow {
  font-size: 22px;
  color: var(--accent);
  opacity: 0;
  transform: translate(-6px, 0);
  transition: opacity 0.3s ease, transform 0.35s cubic-bezier(0.2, 0.8, 0.1, 1);
}
.nav-drawer-link:hover { color: var(--accent); padding-left: 8px; }
.nav-drawer-link:hover .nav-drawer-num { color: var(--accent); }
.nav-drawer-link:hover .nav-drawer-arrow { opacity: 1; transform: translate(0, 0); }
.nav-drawer-link.is-active { color: var(--accent); }
.nav-drawer-link.is-active .nav-drawer-num { color: var(--accent); }
.nav-drawer-link.is-active .nav-drawer-arrow { opacity: 1; transform: translate(0, 0); }
.nav-drawer-controls {
  display: flex; flex-wrap: wrap;
  align-items: center; gap: 12px;
  margin-top: 24px;
}
.nav-drawer-cta {
  margin-top: 16px;
  align-self: flex-start;
}
.no-scroll { overflow: hidden; height: 100vh; }

/* ── Cookie banner ───────────────────────────────────────────────── */
.cookie-banner {
  position: fixed;
  left: clamp(16px, 2vw, 28px);
  right: clamp(16px, 2vw, 28px);
  bottom: clamp(16px, 2vw, 28px);
  z-index: 95;
  max-width: 720px;
  margin-left: auto; margin-right: auto;
  padding: clamp(20px, 2.4vw, 28px) clamp(20px, 2.4vw, 28px);
  background: var(--bg-card);
  color: var(--fg);
  border: 1px solid var(--line-str);
  border-radius: 8px;
  box-shadow: 0 12px 40px rgba(20, 18, 16, 0.18);
  display: none;
  flex-direction: column;
  gap: clamp(14px, 1.6vw, 18px);
  font-size: 14px; line-height: 1.55; font-weight: 300;
}
.cookie-banner.is-visible { display: flex; }
.cookie-banner__title {
  font-family: var(--font-mono); font-size: 11px;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--accent);
}
.cookie-banner__body { color: var(--fg-soft); margin: 0; }
.cookie-banner__body a { color: var(--accent); border-bottom: 1px solid var(--accent); }
.cookie-banner__actions {
  display: flex; gap: 10px; flex-wrap: wrap; align-items: center;
}
.cookie-banner__btn {
  padding: 12px 20px;
  border-radius: 100px;
  font-family: inherit; font-size: 13px; font-weight: 400;
  cursor: pointer;
  border: 1px solid var(--line-str);
  background: transparent; color: var(--fg);
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}
.cookie-banner__btn--primary {
  background: var(--fg); color: var(--bg); border-color: var(--fg);
}
.cookie-banner__btn--primary:hover { background: var(--accent); border-color: var(--accent); color: #141210; }
.cookie-banner__btn:hover { border-color: var(--fg); }
@media (max-width: 520px) {
  .cookie-banner { font-size: 13px; }
  .cookie-banner__actions { gap: 8px; }
  .cookie-banner__btn { padding: 10px 16px; font-size: 12px; }
}

/* ── Floating action buttons (FAB) — Contact + Back to top ───────── */
.fab-stack {
  position: fixed;
  right: clamp(16px, 2vw, 28px);
  bottom: clamp(16px, 2vw, 28px);
  z-index: 75;
  display: flex; flex-direction: column; gap: 12px;
  pointer-events: none; /* children re-enable */
}
.fab {
  pointer-events: auto;
  width: 52px; height: 52px;
  border-radius: 100px;
  background: var(--fg);
  color: var(--bg);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-sans); font-size: 22px; font-weight: 300;
  text-decoration: none;
  box-shadow: 0 6px 24px rgba(20, 18, 16, 0.18);
  border: 1px solid var(--fg);
  cursor: pointer;
  opacity: 0; transform: translateY(8px) scale(0.96);
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), background 0.3s ease, color 0.3s ease;
}
.fab.is-visible { opacity: 1; transform: translateY(0) scale(1); }
.fab:hover { background: var(--accent); color: #141210; border-color: var(--accent); }
.fab:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.fab svg { width: 20px; height: 20px; }
.fab-contact { transition-delay: 0.04s; }
@media (max-width: 520px) {
  .fab-stack { right: 14px; bottom: 14px; gap: 10px; }
  .fab { width: 48px; height: 48px; font-size: 20px; }
}

/* ── Accent stripe — small visual cue under section markers ──────── */
.mono-label[data-accent-stripe]::before,
.mono-label.has-stripe::before {
  content: '';
  display: inline-block;
  width: 28px; height: 1px;
  background: var(--accent);
  vertical-align: middle;
  margin-right: 12px;
  transform: translateY(-2px);
}

/* ── Hero glow — subtle radial behind hero / page-head ──────────── */
.hero-glow {
  position: absolute; inset: 0;
  background: radial-gradient(60% 80% at 70% 35%, color-mix(in srgb, var(--accent) 14%, transparent) 0%, transparent 70%);
  pointer-events: none; z-index: 0;
}

/* ── Service hover-row (used on services.html listing) ─────────────── */
.svc-row {
  display: grid;
  grid-template-columns: 64px 1fr 1fr auto;
  gap: clamp(20px, 3.5vw, 40px);
  align-items: start;
  padding-block: clamp(28px, 5vw, 48px);
  border-bottom: 1px solid var(--line);
}
@media (max-width: 900px) {
  .svc-row { grid-template-columns: 48px 1fr auto; }
  .svc-row .svc-tags { grid-column: 2 / -1; padding-top: 0; }
}
@media (max-width: 520px) {
  .svc-row { grid-template-columns: 1fr auto; gap: 16px 14px; }
  .svc-row .svc-num { grid-column: 1; padding-top: 0; font-size: 11px; }
  .svc-row .svc-body { grid-column: 1 / -1; }
  .svc-row .svc-tags { grid-column: 1 / -1; }
  .svc-row .svc-arrow { grid-column: 2; grid-row: 1; }
}

/* ── Work showcase cards (used on home, portfolios, package pages) ── */
.work-cards-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2vw, 24px); }
.work-card {
  display: flex; flex-direction: column; gap: 0;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--bg-card);
  text-decoration: none; color: inherit;
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.1, 1), border-color 0.3s;
}
.work-card:hover { transform: translateY(-4px); border-color: var(--line-str); }
.work-card .work-img {
  aspect-ratio: 16 / 10;
  background: var(--bg-soft);
  overflow: hidden;
  position: relative;
}
.work-card .work-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.work-card .play-badge {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 56px; height: 56px;
  border-radius: 100px;
  background: rgba(20, 18, 16, 0.66);
  color: var(--inv-fg);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  backdrop-filter: blur(8px);
}
.work-card .work-body {
  padding: clamp(16px, 2vw, 22px) clamp(18px, 2.2vw, 22px) clamp(20px, 2.4vw, 24px);
  display: flex; flex-direction: column; gap: 8px;
}


/* ── Trust strip — clean borders at every breakpoint ─────────────── */
.trust-strip > * { box-sizing: border-box; }
/* Default 3-col: remove right-border on every 3rd cell (last in row),
   bottom-border on the last row */
@media (min-width: 901px) {
  .trust-strip > *:nth-child(3n) { border-right: none !important; }
  .trust-strip > *:nth-last-child(-n+3) { border-bottom: none !important; }
}
/* 2-col (mobile + tablet ≤900): remove right-border on every 2nd cell,
   bottom-border on the last row */
@media (max-width: 900px) {
  .trust-strip > *:nth-child(2n) { border-right: none !important; }
  .trust-strip > *:nth-last-child(-n+2) { border-bottom: none !important; }
}

/* ── Responsive ──────────────────────────────────────────────────── */
@media (max-width: 980px) {
  .work-cards-grid { grid-template-columns: repeat(2, 1fr); }
  .site-header { padding: 14px 24px; grid-template-columns: 1fr auto; }
  .nav-c { display: none; }
  .hamburger { display: inline-flex; min-width: 40px; min-height: 40px; width: 40px; height: 40px; }
  .theme-toggle { width: 52px; height: 36px; }
  .theme-toggle .knob { width: 28px; height: 28px; top: 3px; left: 4px; font-size: 14px; }
  .theme-toggle.is-dark .knob { left: calc(100% - 32px); }
  .currency-toggle { height: 36px; padding: 0 14px; }
  .site-footer { padding: 60px 24px 0; }
  .ft-cols { grid-template-columns: 1fr 1fr; gap: 32px; }
  .shell { padding: 0 24px; }
  .page-head { padding-block: 60px 40px; }
  /* Inline `<div class="rule" style="margin:0 56px">` overflow on narrow screens */
  .rule[style*="56px"] { margin-inline: clamp(16px, 4vw, 56px) !important; }
}
@media (max-width: 720px) {
  .work-cards-grid { grid-template-columns: 1fr; gap: 16px; }
  /* De-clutter the cramped mobile header — theme & currency toggles live in the drawer */
  .nav-r > #themeToggle,
  .nav-r > #currencyToggle { display: none; }
  /* Shrink the Free Assessment CTA so it fits on one line */
  .nav-r .btn-sm { padding: 8px 12px; font-size: 12px; white-space: nowrap; }
  .shell { padding: 0 20px; }
  .site-header { padding: 12px 20px; }
  .page-head { padding-block: 40px 32px; }
  .h-display, .page-head h1 { font-size: clamp(44px, 12vw, 72px) !important; }
  .h-section { font-size: clamp(36px, 9vw, 56px) !important; }
  .lede { font-size: 18px; line-height: 1.55; }
  .page-head .lede { font-size: 18px; line-height: 1.55; margin-top: 28px; }
  .btn-primary, .btn-ghost, .btn-accent { padding: 14px 22px; font-size: 14px; }
  .btn-sm { padding: 10px 16px; font-size: 12px; }
  .ft-cols { grid-template-columns: 1fr; gap: 24px; }
  .ft-mark { font-size: clamp(60px, 22vw, 120px); }
  .ft-cta { font-size: clamp(28px, 7vw, 40px); }
}
@media (max-width: 480px) {
  .shell { padding: 0 16px; }
  .site-header { padding: 10px 16px; }
  .nav-r .mono-label { display: none; }
  .page-head { padding-block: 28px 24px; }
  .page-head .crumb { font-size: 10px; }
  /* Tighter type ceiling on phones — don't let huge clamp(...) values
     wrap one-word-per-line on narrow screens. */
  .h-display, .page-head h1 { font-size: clamp(34px, 11vw, 48px) !important; line-height: 1.0 !important; letter-spacing: -0.03em !important; }
  .h-section { font-size: clamp(28px, 9vw, 40px) !important; line-height: 1.05 !important; letter-spacing: -0.025em !important; }
  .lede, .page-head .lede { font-size: 16px !important; line-height: 1.55 !important; }
  .nav-drawer-panel { padding: 72px 16px 32px; }
  .nav-drawer-brand { left: 16px; }
  /* Belt-and-braces: never let the body horizontally scroll due to a stray
     wide element. (Also helps if any 3rd-party iframe overflows.) */
  body { overflow-x: hidden; }
  /* Constrain inline images that don't carry width:100% */
  main img, main video, main iframe { max-width: 100%; height: auto; }
}
