/* =========================================================
   Better Foliage Mod — betterfoliagemod.com
   Theme: "Daybreak Meadow" — sky-washed light theme,
   forest ink, bark accents. Plain CSS, no build step.
   ========================================================= */

:root {
  --leaf: #667c44;
  --leaf-2: #7f9a55;
  --leaf-3: #b9d18a;
  --forest: #1f2e0c;
  --forest-2: #2c4014;
  --bark: #4a3821;
  --bark-2: #6b5333;
  --sky: #84abf7;
  --sky-2: #c9dafc;
  --sky-3: #eef3fe;

  --bg: #f5f8fe;
  --paper: #ffffff;
  --ink: #1f2e0c;
  --ink-2: #3c4a2c;
  --muted: #5b6750;
  --line: rgba(31, 46, 12, .12);
  --line-strong: rgba(31, 46, 12, .22);

  --f-head: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --f-body: "Figtree", "Segoe UI", system-ui, sans-serif;
  --f-pixel: "Silkscreen", "Courier New", monospace;

  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  --radius: 18px;
  --shadow: 0 1px 2px rgba(31,46,12,.06), 0 12px 32px -12px rgba(31,46,12,.22);
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { background: #141e07; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-2);
  background: var(--bg);
  overflow-x: hidden;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--leaf); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--forest); }
h1, h2, h3, h4 { font-family: var(--f-head); color: var(--ink); line-height: 1.08; letter-spacing: -.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.5rem, 7vw, 5.4rem); font-weight: 800; }
h2 { font-size: clamp(1.9rem, 4.2vw, 3rem); font-weight: 750; }
h3 { font-size: clamp(1.2rem, 2vw, 1.45rem); font-weight: 700; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.2em; }
code, kbd { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .9em; background: var(--sky-3); border: 1px solid var(--line); border-radius: 6px; padding: .05em .4em; color: var(--forest); word-break: break-word; }

.wrap { width: min(100% - var(--gutter) * 2, var(--wrap)); margin-inline: auto; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--forest); color: #fff; padding: 10px 16px; border-radius: 10px; z-index: 200; }
.skip:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 3px; border-radius: 6px; }

.pixel { font-family: var(--f-pixel); font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.eyebrow { display: inline-flex; align-items: center; gap: .6em; font-family: var(--f-pixel); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--leaf); margin-bottom: 1rem; }
.eyebrow::before { content: ""; width: 10px; height: 10px; background: var(--leaf); box-shadow: 10px 0 0 var(--sky), 0 10px 0 var(--bark); margin-right: 12px; }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--muted); max-width: 62ch; }

/* ---------- Buttons ---------- */
.btn {
  --b-bg: var(--forest); --b-fg: #fff;
  position: relative; display: inline-flex; align-items: center; gap: .6em;
  padding: .95em 1.4em; border: 0; border-radius: 12px;
  background: var(--b-bg); color: var(--b-fg);
  font: 700 1rem/1 var(--f-body); text-decoration: none; cursor: pointer;
  box-shadow: 0 5px 0 0 #0e1605, 0 12px 24px -10px rgba(31,46,12,.6);
  transform: translateY(0); transition: transform .18s var(--ease), box-shadow .18s var(--ease), background .2s;
}
.btn:hover { color: var(--b-fg); transform: translateY(-2px); box-shadow: 0 7px 0 0 #0e1605, 0 18px 30px -12px rgba(31,46,12,.6); }
.btn:active { transform: translateY(4px); box-shadow: 0 1px 0 0 #0e1605; }
.btn svg { width: 18px; height: 18px; }
.btn--leaf { --b-bg: var(--leaf); box-shadow: 0 5px 0 0 #3f4e28, 0 12px 24px -10px rgba(102,124,68,.7); }
.btn--leaf:hover { box-shadow: 0 7px 0 0 #3f4e28, 0 18px 30px -12px rgba(102,124,68,.7); }
.btn--ghost { --b-bg: transparent; --b-fg: var(--forest); box-shadow: inset 0 0 0 2px var(--forest); }
.btn--ghost:hover { box-shadow: inset 0 0 0 2px var(--forest), 0 10px 20px -12px rgba(31,46,12,.5); }
.btn--sky { --b-bg: var(--sky); --b-fg: var(--forest); box-shadow: 0 5px 0 0 #5a7fcc, 0 12px 24px -10px rgba(132,171,247,.8); }
.btn--sky:hover { box-shadow: 0 7px 0 0 #5a7fcc, 0 18px 30px -12px rgba(132,171,247,.8); }

/* =========================================================
   HEADER — two-tier: pixel status rail + main bar
   ========================================================= */
.site-header { position: sticky; top: 0; z-index: 100; }
.rail { background: var(--forest); color: var(--sky-2); font-family: var(--f-pixel); font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; }
.rail .wrap { display: flex; gap: 22px; align-items: center; justify-content: center; min-height: 30px; flex-wrap: wrap; }
.rail span { display: inline-flex; align-items: center; gap: 8px; }
.rail span::before { content: ""; width: 6px; height: 6px; background: var(--leaf-3); }
.rail span:nth-child(2)::before { background: var(--sky); }
.rail span:nth-child(3)::before { background: #c9a36b; }

.bar { background: rgba(245, 248, 254, .82); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--line); transition: box-shadow .3s; }
.site-header.scrolled .bar { box-shadow: 0 10px 30px -18px rgba(31,46,12,.45); }
.bar .wrap { display: flex; align-items: center; gap: 24px; min-height: 72px; }

.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); flex-shrink: 0; }
.brand-coin { position: relative; width: 46px; height: 46px; perspective: 400px; }
.brand-coin .coin { position: absolute; inset: 0; transform-style: preserve-3d; animation: coin 9s var(--ease) infinite; }
.brand-coin .face { position: absolute; inset: -.6px; border-radius: 50%; backface-visibility: hidden; overflow: hidden; box-shadow: inset 0 0 0 2px rgba(255,255,255,.7), 0 0 0 2px var(--leaf); }
.brand-coin .face img { width: 100%; height: 100%; object-fit: cover; }
.brand-coin .back { transform: rotateY(180deg); background: var(--forest); }
.brand-coin .back img { padding: 6px; object-fit: contain; }
@keyframes coin { 0%, 40% { transform: rotateY(0) } 50%, 90% { transform: rotateY(180deg) } 100% { transform: rotateY(360deg) } }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-text strong { font-family: var(--f-head); font-weight: 800; font-size: 1.12rem; letter-spacing: -.02em; }
.brand-text small { font-family: var(--f-pixel); font-size: .6rem; color: var(--leaf); letter-spacing: .1em; margin-top: 5px; text-transform: uppercase; }

.nav { margin-left: auto; }
.nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; position: relative; }
.nav a { position: relative; display: block; padding: 10px 12px; font-weight: 600; font-size: .95rem; color: var(--ink-2); text-decoration: none; }
.nav a::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 4px; height: 3px; background: linear-gradient(90deg, var(--leaf) 0 60%, var(--sky) 60% 100%); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.nav a:hover, .nav a[aria-current="page"] { color: var(--forest); }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a.guide-link { color: var(--bark); }
.nav a.guide-link::before { content: "✎"; margin-right: 5px; font-size: .9em; }
.bar-cta { padding: .75em 1.1em; font-size: .92rem; }
.nav .mobile-dl { display: none; }

.burger { display: none; margin-left: auto; width: 46px; height: 46px; border: 2px solid var(--forest); border-radius: 12px; background: transparent; cursor: pointer; position: relative; }
.burger span { position: absolute; left: 11px; right: 11px; height: 2.5px; background: var(--forest); transition: transform .3s var(--ease), opacity .2s; }
.burger span:nth-child(1) { top: 13px; } .burger span:nth-child(2) { top: 20px; } .burger span:nth-child(3) { top: 27px; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* =========================================================
   HERO — centred headline over a full-width 3D diorama
   ========================================================= */
.hero { position: relative; padding: clamp(48px, 7vw, 90px) 0 0; overflow: hidden; background: var(--sky-3); }
.hero::before { content: none; }
.hero-head { position: relative; text-align: center; max-width: 900px; margin-inline: auto; }
.hero-head h1 { margin: 0 auto .4em; max-width: 25ch; font-size: clamp(1.9rem, 4.5vw, 3.75rem); line-height: 1.15; }
.hero-head h1 .word { display: inline-block; }
.hero-head h1 em { font-style: normal; color: var(--leaf); position: relative; white-space: nowrap; }
.hero-head h1 em::after { content: ""; position: absolute; left: 0; right: 0; bottom: .06em; height: .14em; background: var(--sky); z-index: -1; border-radius: 3px; }
.hero-head .lede { margin-inline: auto; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin: 28px 0 12px; }
.hero-meta { display: flex; gap: 8px 18px; justify-content: center; flex-wrap: wrap; color: var(--muted); font-size: .9rem; }
.hero-meta b { color: var(--forest); }

.stage-wrap { position: relative; margin-top: 30px; padding-bottom: 66px; }
.stage {
  --b: 50px;
  position: relative; height: 620px; perspective: 1300px; perspective-origin: 50% 30%;
  cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none;
}
.stage:active { cursor: grabbing; }
.stage::after { content: ""; position: absolute; left: 50%; bottom: 96px; width: 420px; height: 70px; transform: translateX(-50%); background: radial-gradient(closest-side, rgba(31,46,12,.35), transparent); filter: blur(4px); pointer-events: none; }
.world { position: absolute; left: 50%; top: 60%; margin-top: -16px; width: 0; height: 0; transform-style: preserve-3d; transform: rotateX(-24deg) rotateY(-35deg); }
.world, .world * { transform-style: preserve-3d; }
.cube { position: absolute; width: var(--b); height: var(--b); left: calc(var(--b) / -2); top: calc(var(--b) / -2);
  transform: translate3d(calc(var(--x) * var(--b)), calc(var(--y) * var(--b) * -1), calc(var(--z) * var(--b))); }
.face { position: absolute; inset: -.6px; background-size: 100% 100%; image-rendering: pixelated; backface-visibility: hidden; }
.face.ft { transform: translateZ(calc(var(--b) / 2)); }
.face.bk { transform: rotateY(180deg) translateZ(calc(var(--b) / 2)); }
.face.rt { transform: rotateY(90deg) translateZ(calc(var(--b) / 2)); }
.face.lt { transform: rotateY(-90deg) translateZ(calc(var(--b) / 2)); }
.face.tp { transform: rotateX(90deg) translateZ(calc(var(--b) / 2)); }
.face.bt { transform: rotateX(-90deg) translateZ(calc(var(--b) / 2)); }
.face.ft, .face.bk { filter: brightness(.86); }
.face.rt, .face.lt { filter: brightness(.74); }
.face.bt { filter: brightness(.5); }

/* round log octagon (hidden in vanilla) */
.oct { position: absolute; inset: 0; opacity: 0; transition: opacity .5s; }
.oct i { position: absolute; top: 0; height: 100%; left: 50%; width: calc(var(--b) * .4142 + 1px); margin-left: calc(var(--b) * -.2071); background-size: 100% 100%; image-rendering: pixelated; transform: rotateY(calc(var(--i) * 45deg)) translateZ(calc(var(--b) * .5)); filter: brightness(calc(.68 + var(--l) * .32)); }
.log .face.ft, .log .face.bk, .log .face.lt, .log .face.rt { transition: opacity .5s; }
.world.f-logs .log .face.ft, .world.f-logs .log .face.bk, .world.f-logs .log .face.lt, .world.f-logs .log .face.rt { opacity: 0; }
.world.f-logs .log .oct { opacity: 1; }

/* leaf puffs */
.puff { position: absolute; inset: 0; pointer-events: none; }
.puff i { position: absolute; left: 50%; top: 50%; width: calc(var(--b) * 1.7); height: calc(var(--b) * 1.7); margin: calc(var(--b) * -.85) 0 0 calc(var(--b) * -.85); background-size: 100% 100%; image-rendering: pixelated; transform: rotateY(var(--r)) rotateX(var(--rx, 0deg)) scale(.2); opacity: 0; transition: transform .6s var(--ease), opacity .4s; transition-delay: var(--d); }
.world.f-leaves .puff i { transform: rotateY(var(--r)) rotateX(var(--rx, 0deg)) scale(1); opacity: 1; }

/* grass tufts */
.tuft { position: absolute; left: 50%; top: 50%; width: 0; height: 0; transform: translate3d(calc(var(--ox) * var(--b)), calc(var(--b) * -.5), calc(var(--oz) * var(--b))); }
.tuft i { position: absolute; width: calc(var(--b) * 1.05); height: calc(var(--b) * .95); left: calc(var(--b) * -.525); bottom: 0; background-size: 100% 100%; image-rendering: pixelated; transform-origin: 50% 100%; transform: rotateY(var(--r)) scaleY(0); transition: transform .5s var(--ease); transition-delay: var(--d); }
.world.f-grass .tuft i { transform: rotateY(var(--r)) scaleY(1); animation: sway 3.2s ease-in-out infinite alternate; animation-delay: calc(var(--d) * 4); }
@keyframes sway { from { transform: rotateY(var(--r)) scaleY(1) skewX(-6deg); } to { transform: rotateY(var(--r)) scaleY(.94) skewX(6deg); } }

/* falling leaves */
.fall { position: absolute; left: 0; top: 0; width: calc(var(--b) * .22); height: calc(var(--b) * .22); background: var(--leaf-2); box-shadow: inset -3px -3px 0 rgba(0,0,0,.18); opacity: 0; transform: translate3d(calc(var(--fx) * var(--b)), calc(var(--b) * -4), calc(var(--fz) * var(--b))); }
.world.f-fall .fall { animation: fall var(--t) linear infinite; animation-delay: var(--d); }
@keyframes fall {
  0% { opacity: 0; transform: translate3d(calc(var(--fx) * var(--b)), calc(var(--b) * -3.2), calc(var(--fz) * var(--b))) rotateZ(0) rotateY(0); }
  10% { opacity: 1; }
  50% { transform: translate3d(calc((var(--fx) + .6) * var(--b)), calc(var(--b) * -1.6), calc((var(--fz) - .3) * var(--b))) rotateZ(180deg) rotateY(160deg); }
  90% { opacity: 1; }
  100% { opacity: 0; transform: translate3d(calc((var(--fx) - .2) * var(--b)), calc(var(--b) * -.55), calc((var(--fz) + .4) * var(--b))) rotateZ(340deg) rotateY(320deg); }
}

/* lily pad + flower on water */
.water .face.tp { opacity: .85; }
.lily { position: absolute; left: 50%; top: 50%; width: calc(var(--b) * .8); height: calc(var(--b) * .8); margin: calc(var(--b) * -.4) 0 0 calc(var(--b) * -.4); background-size: 100% 100%; image-rendering: pixelated; transform: rotateX(90deg) translateZ(calc(var(--b) * .46)); }
.lily-flower { position: absolute; left: 50%; top: 50%; width: calc(var(--b) * .3); height: calc(var(--b) * .3); margin: calc(var(--b) * -.15) 0 0 calc(var(--b) * -.15); background: #f39bd0; box-shadow: inset -3px -3px 0 #d06aa8; transform: translate3d(calc(var(--b) * .1), calc(var(--b) * -.6), 0) rotateY(45deg) scale(0); transition: transform .5s var(--ease) .3s; }
.world.f-grass .lily-flower { transform: translate3d(calc(var(--b) * .1), calc(var(--b) * -.6), 0) rotateY(45deg) scale(1); }

/* stage UI */
.stage-ui { position: absolute; left: 50%; bottom: -48px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 12px; width: min(100% - 32px, 640px); z-index: 3; }
.switch { position: relative; display: grid; grid-template-columns: 1fr 1fr; background: var(--forest); border-radius: 14px; padding: 5px; width: min(100%, 380px); box-shadow: 0 16px 34px -14px rgba(31,46,12,.7); }
.switch button { position: relative; z-index: 1; border: 0; background: transparent; color: var(--sky-2); padding: 11px 10px; font: 700 .92rem var(--f-body); cursor: pointer; border-radius: 10px; transition: color .3s; }
.switch button[aria-pressed="true"] { color: var(--forest); }
.switch .knob { position: absolute; top: 5px; bottom: 5px; left: 5px; width: calc(50% - 5px); border-radius: 10px; background: var(--leaf-3); box-shadow: inset 0 -4px 0 rgba(0,0,0,.15); transition: transform .45s var(--ease), background .3s; }
.switch.on .knob { transform: translateX(100%); background: var(--sky); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.chip { display: inline-flex; align-items: center; gap: 7px; border: 1.5px solid var(--line-strong); background: rgba(255,255,255,.85); backdrop-filter: blur(6px); color: var(--ink); border-radius: 8px; padding: 6px 11px; font: 600 .82rem var(--f-body); cursor: pointer; transition: background .2s, border-color .2s, transform .2s; }
.chip::before { content: ""; width: 12px; height: 12px; border: 2px solid var(--leaf); border-radius: 3px; background: transparent; transition: background .2s; }
.chip[aria-pressed="true"] { border-color: var(--leaf); background: #fff; }
.chip[aria-pressed="true"]::before { background: var(--leaf); box-shadow: inset 0 0 0 2px #fff; }
.chip:hover { transform: translateY(-2px); }
.drag-hint { position: absolute; top: 12px; right: max(16px, calc(50% - 560px)); font-family: var(--f-pixel); font-size: .66rem; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; display: flex; align-items: center; gap: 8px; }
.drag-hint::before { content: "⟲"; font-size: 1.1rem; font-family: var(--f-body); }

.callout { position: absolute; z-index: 2; display: flex; align-items: center; gap: 10px; font-size: .86rem; font-weight: 600; color: var(--forest); background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; box-shadow: var(--shadow); opacity: 0; transform: translateY(8px); transition: opacity .5s, transform .5s var(--ease); pointer-events: none; }
.callout b { font-family: var(--f-pixel); font-size: .64rem; color: #fff; background: var(--leaf); border-radius: 5px; padding: 3px 6px; font-weight: 400; }
.stage.is-bf .callout { opacity: 1; transform: none; }
.callout.c1 { left: max(16px, calc(50% - 520px)); top: 110px; transition-delay: .2s; }
.callout.c2 { left: max(16px, calc(50% - 470px)); top: 300px; transition-delay: .35s; }
.callout.c3 { right: max(16px, calc(50% - 520px)); top: 160px; transition-delay: .5s; }
.callout.c4 { right: max(16px, calc(50% - 480px)); top: 330px; transition-delay: .65s; }

.hero-strip { position: relative; background: var(--forest); color: #e7eedb; margin-top: -1px; }
.hero-strip .wrap { display: grid; grid-template-columns: repeat(4, 1fr); }
.hero-strip div { padding: 22px 18px; border-left: 1px solid rgba(255,255,255,.1); }
.hero-strip div:first-child { border-left: 0; }
.hero-strip strong { display: block; font-family: var(--f-head); font-size: 1.7rem; color: #fff; line-height: 1.1; }
.hero-strip span { font-size: .85rem; color: var(--sky-2); }

/* =========================================================
   SECTIONS
   ========================================================= */
.section { padding: clamp(70px, 9vw, 120px) 0; position: relative; }
.section--paper { background: var(--paper); }
.section--sky { background: var(--sky-3); }
.section--forest { background: var(--forest); color: #d9e3c8; }
.section--forest h2, .section--forest h3 { color: #fff; }
.section--forest .eyebrow { color: var(--leaf-3); }
.section--forest .lede { color: #b8c6a3; }
.sec-head { max-width: 760px; margin-bottom: clamp(36px, 5vw, 60px); }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head.center .lede { margin-inline: auto; }
.sec-num { font-family: var(--f-pixel); color: var(--sky); font-size: .75rem; margin-right: 10px; }

/* ---- About: magazine columns ---- */
.mag { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(30px, 5vw, 70px); align-items: start; }
.mag-body { columns: 2 260px; column-gap: 34px; column-rule: 1px solid var(--line); }
.mag-body p:first-child::first-letter { float: left; font-family: var(--f-head); font-weight: 800; font-size: 4.4rem; line-height: .8; margin: .08em .12em 0 0; color: var(--leaf); }
.mag-body p { break-inside: avoid-column; }
.polaroid-wrap { perspective: 1200px; }
.polaroid { background: #fff; padding: 14px 14px 18px; border-radius: 6px; box-shadow: 0 30px 60px -25px rgba(31,46,12,.55), 0 0 0 1px var(--line); transform: rotateY(-14deg) rotateX(6deg) rotateZ(2deg); transition: transform .8s var(--ease); }
.polaroid:hover { transform: rotateY(0) rotateX(0) rotateZ(0) translateY(-6px); }
.polaroid img { border-radius: 3px; width: 100%; aspect-ratio: 551/362; object-fit: cover; }
.polaroid figcaption { font-family: var(--f-pixel); font-size: .7rem; color: var(--muted); margin-top: 12px; text-transform: uppercase; letter-spacing: .06em; }
.pull { margin: 34px 0 0; padding: 22px 0 0 26px; border-left: 6px solid var(--leaf); font-family: var(--f-head); font-size: clamp(1.3rem, 2.2vw, 1.7rem); line-height: 1.25; color: var(--forest); font-weight: 650; }
.pull cite { display: block; font-family: var(--f-pixel); font-size: .66rem; color: var(--muted); font-style: normal; margin-top: 12px; text-transform: uppercase; letter-spacing: .06em; }

/* ---- Features: THE ONLY CARD SECTION ---- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; perspective: 1400px; }
.card { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 24px 24px; box-shadow: var(--shadow); transform-style: preserve-3d; transition: transform .25s ease-out, box-shadow .3s; will-change: transform; overflow: hidden; }
.card::before { content: ""; position: absolute; inset: 0; background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 0%), rgba(132,171,247,.22), transparent 45%); opacity: 0; transition: opacity .3s; pointer-events: none; }
.card:hover::before { opacity: 1; }
.card:hover { box-shadow: 0 30px 50px -24px rgba(31,46,12,.45), 0 0 0 1px var(--line); }
.card .ico { width: 58px; height: 58px; margin-bottom: 18px; transform: translateZ(40px); }
.card h3 { transform: translateZ(28px); }
.card p { color: var(--muted); font-size: .97rem; margin: 0; transform: translateZ(14px); }
.card .tag { position: absolute; top: 18px; right: 18px; font-family: var(--f-pixel); font-size: .6rem; color: var(--leaf); background: var(--sky-3); border-radius: 5px; padding: 4px 7px; text-transform: uppercase; }

/* ---- How it works: exploded 3D layer stack ---- */
.how { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 5vw, 70px); align-items: center; }
.stack { position: relative; height: 460px; perspective: 1400px; }
.stack-inner { position: absolute; left: 50%; top: 50%; width: 0; height: 0; transform-style: preserve-3d; transform: rotateX(58deg) rotateZ(-38deg); }
.layer { position: absolute; width: 230px; height: 230px; left: -115px; top: -115px; border-radius: 18px; transform: translateZ(calc(var(--n) * 18px)); transition: transform .9s var(--ease), box-shadow .5s; display: grid; place-items: center; border: 2px solid rgba(255,255,255,.6); }
.stack.open .layer { transform: translateZ(calc(var(--n) * 78px - 90px)); box-shadow: -18px 18px 30px -10px rgba(31,46,12,.35); }
.layer span { font-family: var(--f-pixel); font-size: .75rem; color: #fff; transform: rotateZ(38deg); text-align: center; line-height: 1.5; padding: 0 10px; }
.layer.l1 { background: var(--bark); }
.layer.l2 { background: var(--leaf); }
.layer.l3 { background: #4f6233; }
.layer.l4 { background: var(--sky); }
.layer.l4 span { color: var(--forest); }
.steps-list { list-style: none; margin: 0; padding: 0; counter-reset: s; }
.steps-list li { counter-increment: s; position: relative; padding: 18px 0 18px 64px; border-bottom: 1px dashed var(--line-strong); cursor: default; transition: background .3s; }
.steps-list li::before { content: "0" counter(s); position: absolute; left: 0; top: 16px; font-family: var(--f-pixel); font-size: 1rem; color: #fff; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 10px; background: var(--c, var(--leaf)); }
.steps-list li:nth-child(1) { --c: var(--bark); } .steps-list li:nth-child(2) { --c: var(--leaf); } .steps-list li:nth-child(3) { --c: #4f6233; } .steps-list li:nth-child(4) { --c: #5d86d9; }
.steps-list h3 { margin-bottom: .25em; font-size: 1.15rem; }
.steps-list p { margin: 0; color: var(--muted); font-size: .96rem; }

/* ---- Versions: table ---- */
.tbl-wrap { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; box-shadow: var(--shadow); }
table.tbl { width: 100%; border-collapse: collapse; font-size: .95rem; }
.tbl caption { text-align: left; padding: 16px 20px; font-family: var(--f-pixel); font-size: .7rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; border-bottom: 1px solid var(--line); background: var(--sky-3); }
.tbl th, .tbl td { padding: 15px 20px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl thead th { font-family: var(--f-head); font-weight: 700; color: var(--forest); background: #fafcf6; font-size: .92rem; }
.tbl tbody tr { transition: background .2s; }
.tbl tbody tr:hover { background: #f7faf1; }
.tbl tbody tr:last-child td, .tbl tbody tr:last-child th { border-bottom: 0; }
.tbl th[scope="row"] { font-family: var(--f-head); color: var(--forest); font-weight: 700; }
.pill { display: inline-block; font-size: .76rem; font-weight: 700; padding: 3px 9px; border-radius: 6px; white-space: nowrap; }
.pill.yes { background: #e5eed6; color: #3f5225; }
.pill.no { background: #f6e6dc; color: #7a3d1c; }
.pill.alt { background: #e3ebfd; color: #2b4d93; }

/* ---- Download banner ---- */
.dl-banner { position: relative; display: grid; grid-template-columns: 1.4fr 1fr; gap: 30px; align-items: center; background: var(--forest); color: #dbe5ca; border-radius: 26px; padding: clamp(28px, 4vw, 54px); overflow: hidden; }
.dl-banner::before { content: none; }
.dl-banner h2, .dl-banner h3 { color: #fff; }
.dl-file { position: relative; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: 16px; padding: 20px; font-size: .9rem; }
.dl-file dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0 0 18px; }
.dl-file dt { color: var(--sky); font-family: var(--f-pixel); font-size: .66rem; text-transform: uppercase; padding-top: 3px; }
.dl-file dd { margin: 0; color: #fff; word-break: break-word; }
.dl-note { font-size: .85rem; color: #b8c6a3; margin-top: 14px; }

/* ---- Install: big numbered list ---- */
.install { list-style: none; padding: 0; margin: 0; counter-reset: i; display: grid; gap: 0; }
.install li { counter-increment: i; display: grid; grid-template-columns: 130px 1fr; gap: 24px; padding: 28px 0; border-top: 2px solid var(--forest); }
.install li:last-child { border-bottom: 2px solid var(--forest); }
.install li::before { content: counter(i, decimal-leading-zero); font-family: var(--f-head); font-weight: 800; font-size: clamp(3rem, 6vw, 4.6rem); line-height: .85; color: transparent; -webkit-text-stroke: 2px var(--leaf); transition: color .4s; }
.install li:hover::before { color: var(--leaf); }
.install h3 { margin-bottom: .3em; }
.install p { margin: 0; color: var(--muted); }

/* ---- Requirements: definition rows ---- */
.req { display: grid; gap: 0; border-top: 1px solid var(--line-strong); }
.req-row { display: grid; grid-template-columns: 240px 1fr; gap: 24px; padding: 18px 0; border-bottom: 1px solid var(--line-strong); align-items: baseline; }
.req-row dt { font-family: var(--f-head); font-weight: 700; color: var(--forest); }
.req-row dd { margin: 0; color: var(--muted); }
.req-row dd strong { color: var(--forest); }

/* ---- Use cases: editorial index list ---- */
.uses { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line-strong); }
.uses li { position: relative; display: grid; grid-template-columns: 70px 1.1fr 1.6fr 40px; gap: 24px; align-items: center; padding: 26px 8px; border-bottom: 1px solid var(--line-strong); transition: background .35s, padding .35s; overflow: hidden; }
.uses li::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--sky-3), transparent); transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); z-index: -1; }
.uses li:hover::before { transform: scaleX(1); }
.uses li:hover { padding-left: 18px; }
.uses .n { font-family: var(--f-pixel); color: var(--leaf); font-size: .85rem; }
.uses h3 { margin: 0; }
.uses p { margin: 0; color: var(--muted); font-size: .97rem; }
.uses .arr { width: 34px; height: 34px; border-radius: 50%; border: 1.5px solid var(--forest); display: grid; place-items: center; transition: transform .35s var(--ease), background .3s; }
.uses li:hover .arr { transform: rotate(-45deg); background: var(--forest); color: #fff; }

/* ---- Comparison (dark band) ---- */
.cmp { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .95rem; }
.cmp th, .cmp td { padding: 16px 18px; text-align: left; border-bottom: 1px solid rgba(255,255,255,.1); }
.cmp thead th { font-family: var(--f-head); color: #fff; font-size: 1rem; vertical-align: bottom; }
.cmp thead th.hl { background: var(--leaf); border-radius: 14px 14px 0 0; }
.cmp td.hl { background: rgba(102,124,68,.35); color: #fff; }
.cmp tbody tr:last-child td.hl { border-radius: 0 0 14px 14px; }
.cmp tbody th { color: #fff; font-weight: 600; }
.cmp .y { color: var(--leaf-3); font-weight: 700; } .cmp .n { color: #e3a98a; } .cmp .m { color: var(--sky); }
.cmp-wrap { background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.1); border-radius: 22px; padding: 10px; }

/* ---- Compatibility, support and balanced guidance ---- */
.support-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.support-card { padding: clamp(22px, 3vw, 34px); border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: 0 8px 24px -18px rgba(31,46,12,.25); }
.support-label { display: block; margin-bottom: 14px; color: var(--leaf); font: 700 .75rem/1.5 var(--f-body); letter-spacing: .08em; text-transform: uppercase; }
.support-card h3, .support-callout h3 { margin: 0 0 12px; font-size: clamp(1.15rem, 2vw, 1.4rem); line-height: 1.3; }
.support-card p, .support-callout p { margin: 0; color: var(--muted); }
.support-note { max-width: 900px; margin: 22px 0 0; color: var(--muted); font-size: .9rem; }
.support-callout { margin-top: 24px; padding: 24px 28px; border-left: 4px solid var(--leaf); border-radius: 0 14px 14px 0; background: var(--sky-3); }
.support-positive { border-top: 4px solid var(--leaf); }
.support-caution { border-top: 4px solid var(--bark-2); }
.support-caution .support-label { color: var(--bark-2); }
.support-points { margin: 0; padding-left: 20px; color: var(--muted); }
.support-points li + li { margin-top: 16px; }
.support-points strong { color: var(--forest); }
@media (max-width: 700px) {
  .support-grid { grid-template-columns: 1fr; gap: 16px; }
  .support-callout { padding: 22px; }
}

/* ---- Safety ---- */
.safety { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(30px, 5vw, 70px); align-items: center; }
.shield { position: relative; aspect-ratio: 1; max-width: 360px; margin-inline: auto; perspective: 900px; }
.shield svg { width: 100%; height: 100%; animation: float 6s ease-in-out infinite; filter: drop-shadow(0 30px 30px rgba(31,46,12,.3)); }
@keyframes float { 0%, 100% { transform: translateY(0) rotateY(-12deg); } 50% { transform: translateY(-14px) rotateY(12deg); } }
.checks { list-style: none; margin: 0; padding: 0; }
.checks li { display: grid; grid-template-columns: 34px 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.checks li::before { content: ""; width: 30px; height: 30px; border-radius: 8px; background: var(--leaf) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center/18px no-repeat; }
.checks li.warn::before { background-color: var(--bark); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M12 6v8M12 18v.5'/%3E%3C/svg%3E"); }
.checks strong { color: var(--forest); display: block; }
.checks span { color: var(--muted); font-size: .96rem; }

/* ---- Testimonials: community-theme marquee ---- */
.marquee { position: relative; overflow: hidden; padding: 6px 0; mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.marquee + .marquee { margin-top: 18px; }
.track { display: flex; gap: 18px; width: max-content; animation: marq 48s linear infinite; }
.marquee.rev .track { animation-direction: reverse; animation-duration: 56s; }
.marquee:hover .track { animation-play-state: paused; }
@keyframes marq { to { transform: translateX(-50%); } }
.quote { flex: 0 0 auto; width: 380px; max-width: 80vw; margin: 0; padding: 20px 24px; border-left: 5px solid var(--leaf); background: #fff; border-radius: 0 14px 14px 0; box-shadow: 0 1px 0 var(--line); }
.marquee.rev .quote { border-left-color: var(--sky); }
.quote p { margin: 0 0 10px; font-family: var(--f-head); font-weight: 600; font-size: 1.08rem; line-height: 1.35; color: var(--forest); white-space: normal; }
.quote footer { font-family: var(--f-pixel); font-size: .64rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.theme-note { text-align: center; color: var(--muted); font-size: .85rem; margin-top: 22px; }

/* ---- FAQ: single-column accordion ---- */
.faq { max-width: 860px; margin-inline: auto; }
.faq-tab-list { display: flex; gap: 8px; margin-bottom: 26px; padding: 6px; border: 1px solid var(--line); border-radius: 14px; background: var(--sky-3); }
.faq-tab-list[hidden], .faq-panel[hidden] { display: none; }
.faq-tab { flex: 1; min-width: 0; min-height: 48px; padding: 12px 14px; border: 0; border-radius: 10px; background: transparent; color: var(--forest); font: 600 15px/1.4 var(--f-body); cursor: pointer; }
.faq-tab:hover { background: var(--sky-2); }
.faq-tab[aria-selected="true"] { background: var(--forest); color: var(--paper); }
.faq-tab:focus-visible, .faq-panel:focus-visible, .faq-tabs summary:focus-visible { outline: 3px solid var(--leaf-2); outline-offset: 3px; }
.faq-tabs-ready .faq-category { display: none; }
.faq-tabs .faq-panel > details:first-of-type { border-top: 1px solid var(--line-strong); }
.faq-tabs summary { font-family: var(--f-body); font-size: clamp(1rem, 1.3vw, 1.125rem); font-weight: 600; line-height: 1.5; padding: 20px 4px; gap: 16px; }
@media (max-width: 600px) {
  .faq-tab-list { flex-direction: column; gap: 4px; margin-bottom: 20px; }
  .faq-tab { width: 100%; padding: 10px 12px; }
  .faq-tabs summary { padding: 17px 4px; gap: 12px; }
}
.faq details { border-bottom: 1px solid var(--line-strong); }
.faq details:first-child { border-top: 1px solid var(--line-strong); }
.faq summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: 1fr 36px; gap: 20px; align-items: center; padding: 22px 4px; font-family: var(--f-head); font-weight: 700; font-size: clamp(1.05rem, 1.7vw, 1.25rem); color: var(--forest); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; width: 34px; height: 34px; border-radius: 9px; background: var(--sky-3) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f2e0c' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E") center/16px no-repeat; transition: transform .35s var(--ease), background-color .3s; }
.faq details[open] summary::after { transform: rotate(135deg); background-color: var(--leaf-3); }
.faq .ans { padding: 0 60px 22px 4px; color: var(--muted); }
.faq details[open] .ans { animation: drop .4s var(--ease); }
@keyframes drop { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* ---- Final CTA ---- */
.cta { position: relative; overflow: hidden; text-align: center; padding: clamp(80px, 11vw, 140px) 0; background: var(--forest); color: #d6e0c4; }
.cta h2 { color: #fff; font-size: clamp(2.2rem, 5.5vw, 4rem); max-width: 16ch; margin-inline: auto; }
.cta p { max-width: 56ch; margin: 0 auto 30px; color: #b8c6a3; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.cta .btn--ghost { --b-fg: #fff; box-shadow: inset 0 0 0 2px rgba(255,255,255,.7); }
.floaters { position: absolute; inset: 0; pointer-events: none; perspective: 900px; }
.fb { position: absolute; width: var(--s); height: var(--s); transform-style: preserve-3d; animation: spin var(--t) linear infinite, bob 7s ease-in-out infinite; }
.fb i { position: absolute; inset: 0; background: var(--c); border: 1px solid rgba(0,0,0,.15); }
.fb i:nth-child(1) { transform: translateZ(calc(var(--s) / 2)); }
.fb i:nth-child(2) { transform: rotateY(90deg) translateZ(calc(var(--s) / 2)); filter: brightness(.8); }
.fb i:nth-child(3) { transform: rotateX(90deg) translateZ(calc(var(--s) / 2)); filter: brightness(1.15); }
.fb i:nth-child(4) { transform: rotateY(180deg) translateZ(calc(var(--s) / 2)); filter: brightness(.7); }
.fb i:nth-child(5) { transform: rotateY(-90deg) translateZ(calc(var(--s) / 2)); filter: brightness(.8); }
.fb i:nth-child(6) { transform: rotateX(-90deg) translateZ(calc(var(--s) / 2)); filter: brightness(.6); }
@keyframes spin { to { transform: rotateX(360deg) rotateY(720deg); } }
@keyframes bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -24px; } }

/* =========================================================
   FOOTER — giant outlined wordmark
   ========================================================= */
.footer { background: #141e07; color: #a9b794; padding-top: 70px; overflow: hidden; }
.footer a { color: #dfe8cf; text-decoration: none; }
.footer a:hover { color: var(--sky); }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 34px; padding-bottom: 46px; }
.foot-grid h4 { font-family: var(--f-pixel); font-size: .7rem; color: var(--leaf-3); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 16px; font-weight: 400; }
.foot-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; font-size: .95rem; }
.foot-brand { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.foot-brand img { width: 54px; height: 54px; border-radius: 12px; object-fit: cover; box-shadow: 0 0 0 2px var(--leaf); }
.foot-brand strong { font-family: var(--f-head); color: #fff; font-size: 1.2rem; }
.foot-brand + p { font-size: .93rem; }
.wordmark { font-family: var(--f-head); font-weight: 800; font-size: clamp(3rem, 13.5vw, 12rem); line-height: .8; letter-spacing: -.05em; color: transparent; -webkit-text-stroke: 1.5px rgba(185,209,138,.35); white-space: nowrap; text-align: center; user-select: none; margin: 0 0 -.12em; transition: -webkit-text-stroke-color .4s; }
.wordmark:hover { -webkit-text-stroke-color: var(--sky); }
.legal { border-top: 1px solid rgba(255,255,255,.08); padding: 22px 0 28px; font-size: .85rem; display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; position: relative; background: #141e07; }
.legal p { margin: 0; }
.legal .disc { color: #dfe8cf; }

/* back to top */
.to-top { position: fixed; right: 18px; bottom: 18px; z-index: 90; width: 50px; height: 50px; border: 0; border-radius: 14px; background: var(--leaf); color: #fff; cursor: pointer; box-shadow: 0 5px 0 #3f4e28, 0 14px 24px -10px rgba(31,46,12,.6); opacity: 0; transform: translateY(20px) scale(.8); pointer-events: none; transition: opacity .3s, transform .3s var(--ease); display: grid; place-items: center; }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--forest); }
.to-top svg { width: 22px; height: 22px; }

/* reveal */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--rd, 0s); }
.reveal.in { opacity: 1; transform: none; }

/* =========================================================
   INNER PAGES
   ========================================================= */
.page-hero { position: relative; padding: 46px 0 56px; background: var(--sky-3); border-bottom: 1px solid var(--line); overflow: hidden; }
.page-hero::after { content: none; }
.page-hero h1 { font-size: clamp(2.2rem, 5.5vw, 4rem); max-width: 18ch; }
.crumbs { margin-bottom: 26px; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; font-size: .88rem; }
.crumbs li { display: flex; align-items: center; gap: 6px; color: var(--muted); }
.crumbs li + li::before { content: "/"; color: var(--sky); font-weight: 700; }
.crumbs a { color: var(--leaf); text-decoration: none; font-weight: 600; }
.prose { max-width: 780px; }
.prose h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-top: 1.8em; }
.prose h3 { margin-top: 1.5em; }
.prose ul li, .prose ol li { margin-bottom: .45em; }
.layout-side { display: grid; grid-template-columns: 240px 1fr; gap: clamp(30px, 5vw, 64px); align-items: start; }
.toc { position: sticky; top: 130px; border-left: 3px solid var(--leaf); padding-left: 18px; }
.toc h2 { font-family: var(--f-pixel); font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 0 0 12px; font-weight: 400; }
.toc ol { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: .92rem; }
.toc a { text-decoration: none; color: var(--ink-2); }
.toc a:hover { color: var(--leaf); }
.kw-block { padding: 30px 0; border-top: 1px solid var(--line-strong); }
.kw-block:first-of-type { border-top: 0; padding-top: 0; }
.kw-block h2 { margin-top: 0; }
.status { display: inline-flex; gap: 8px; align-items: center; margin-bottom: 12px; }
.notice { border-left: 5px solid var(--sky); background: #fff; padding: 16px 20px; border-radius: 0 12px 12px 0; margin: 18px 0; box-shadow: 0 1px 0 var(--line); }
.notice.warn { border-left-color: var(--bark); }
.notice p:last-child { margin-bottom: 0; }
.logo-dl { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; margin: 18px 0; }
.logo-dl img { width: 120px; height: 120px; border-radius: 22px; object-fit: cover; box-shadow: var(--shadow); }
.logo-dl .btns { display: flex; flex-wrap: wrap; gap: 10px; }

/* contact */
.contact { display: grid; grid-template-columns: 1fr 1.3fr; gap: clamp(30px, 5vw, 64px); }
.form { display: grid; gap: 18px; }
.field label { display: block; font-weight: 700; color: var(--forest); margin-bottom: 6px; font-size: .95rem; }
.field input, .field select, .field textarea { width: 100%; font: inherit; color: var(--ink); padding: 13px 15px; border: 1.5px solid var(--line-strong); border-radius: 12px; background: #fff; transition: border-color .2s, box-shadow .2s; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--leaf); box-shadow: 0 0 0 4px rgba(102,124,68,.18); }
.field textarea { min-height: 150px; resize: vertical; }
.form-ok { display: none; border-left: 5px solid var(--leaf); background: #eef4e2; padding: 16px 20px; border-radius: 0 12px 12px 0; color: var(--forest); font-weight: 600; }
.form-ok.show { display: block; animation: drop .4s var(--ease); }
.err { color: #9a3b12; font-size: .85rem; margin-top: 4px; display: none; }
.field.invalid .err { display: block; }
.field.invalid input, .field.invalid textarea { border-color: #c4622f; }
.contact-side dl { margin: 0; }
.contact-side dt { font-family: var(--f-pixel); font-size: .68rem; color: var(--leaf); text-transform: uppercase; margin-top: 18px; }
.contact-side dd { margin: 4px 0 0; font-size: 1.05rem; color: var(--forest); font-weight: 600; }

/* 404 */
.nf { min-height: 70vh; display: grid; place-items: center; text-align: center; padding: 60px 0; background: var(--sky-3); }
.nf-num { font-family: var(--f-head); font-weight: 800; font-size: clamp(6rem, 22vw, 14rem); line-height: .85; color: transparent; -webkit-text-stroke: 3px var(--leaf); letter-spacing: -.05em; }
.nf-blocks { display: flex; gap: 10px; justify-content: center; margin: 20px 0; perspective: 600px; }
.nf-blocks span { width: 34px; height: 34px; background: var(--c); animation: hop 1.6s var(--ease) infinite; animation-delay: var(--d); box-shadow: inset -5px -5px 0 rgba(0,0,0,.18); }
@keyframes hop { 0%, 100% { transform: translateY(0) rotateX(0); } 40% { transform: translateY(-22px) rotateX(180deg); } }

/* blog */
.post-meta { display: flex; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: .9rem; }
.post-meta span { display: inline-flex; gap: 6px; align-items: center; }
.template-box { border: 2px dashed var(--line-strong); border-radius: 16px; padding: 22px; background: #fff; margin: 30px 0; }
.template-box h2 { margin-top: 0 !important; font-size: 1.3rem !important; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1080px) {
  .nav, .bar-cta { display: none; }
  .burger { display: block; }
  .nav.open { display: block; position: fixed; left: 0; right: 0; top: 100%; height: calc(100dvh - 102px); background: var(--bg); padding: 20px var(--gutter) 40px; overflow-y: auto; animation: drop .35s var(--ease); border-top: 1px solid var(--line); }
  .nav.open ul { flex-direction: column; gap: 0; }
  .nav.open a { font-family: var(--f-head); font-size: 1.6rem; font-weight: 750; padding: 16px 4px; border-bottom: 1px solid var(--line); }
  .nav.open a::after { display: none; }
  .nav .mobile-dl { display: block; margin-top: 24px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .callout { display: none; }
}
@media (max-width: 860px) {
  .mag, .how, .safety, .dl-banner, .contact, .layout-side { grid-template-columns: 1fr; }
  .toc { position: static; }
  .hero-strip .wrap { grid-template-columns: 1fr 1fr; }
  .hero-strip div:nth-child(3) { border-left: 0; }
  .hero-strip div:nth-child(n+3) { border-top: 1px solid rgba(255,255,255,.1); }
  .uses li { grid-template-columns: 44px 1fr 34px; }
  .uses li p { grid-column: 2 / 4; grid-row: 2; }
  .uses .arr { grid-column: 3; grid-row: 1; }
  .req-row { grid-template-columns: 1fr; gap: 4px; }
  .stack { height: 380px; }
  /* tables -> stacked rows */
  .tbl thead, .cmp thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .tbl tr, .cmp tr { display: block; border-bottom: 1px solid var(--line); padding: 10px 0; }
  .cmp tr { border-bottom-color: rgba(255,255,255,.12); }
  .tbl th, .tbl td, .cmp th, .cmp td { display: grid; grid-template-columns: 44% 1fr; gap: 10px; border: 0; padding: 7px 16px; }
  .tbl th[scope="row"], .cmp tbody th { display: block; font-size: 1.05rem; padding-top: 12px; }
  .tbl td::before, .cmp td::before { content: attr(data-label); font-weight: 700; color: var(--forest); font-size: .85rem; }
  .cmp td::before { color: var(--sky-2); }
  .cmp td.hl { background: rgba(102,124,68,.25); border-radius: 8px !important; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .rail span:nth-child(3) { display: none; }
  .brand-text small { display: none; }
  .stage { --b: 32px; height: 470px; }
  .stage .world { top: 53%; }
  .stage::after { bottom: 110px; }
  .stage::after { width: 260px; }
  .drag-hint { left: 16px; right: auto; }
  .cards { grid-template-columns: 1fr; }
  .install li { grid-template-columns: 1fr; gap: 6px; }
  .foot-grid { grid-template-columns: 1fr; }
  .faq .ans { padding-right: 4px; }
  .hero-strip strong { font-size: 1.35rem; }
  .chip { font-size: .76rem; padding: 6px 9px; }
  .layer { width: 170px; height: 170px; left: -85px; top: -85px; }
  .stack.open .layer { transform: translateZ(calc(var(--n) * 60px - 70px)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
  .track { animation: none !important; flex-wrap: wrap; width: auto; justify-content: center; }
  .marquee { mask-image: none; -webkit-mask-image: none; }
  .marquee .quote[aria-hidden="true"] { display: none; }
  .world.f-fall .fall { display: none; }
}
.nav.open .mobile-dl a.btn { display: inline-flex; width: 100%; justify-content: center; font: 700 1.05rem/1 var(--f-body); color: #fff; padding: 1.05em 1.4em; border-bottom: 0; }

/* Centered footer: existing forest palette, one menu row on desktop. */
.footer--centered { padding: 64px 0 30px; }
.footer-content { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 22px; }
.footer-logo { display: inline-flex; flex-direction: column; align-items: center; gap: 18px; }
.footer-logo .brand-coin { display: block; width: 72px; height: 72px; perspective: 600px; }
.footer-logo strong { font-family: var(--f-head); font-size: 1.35rem; color: #fff; }
.footer-description { max-width: 600px; margin: 0; font-size: .95rem; line-height: 1.7; }
.footer-menu { width: 100%; margin: 12px 0 8px; }
.footer-menu ul { display: flex; flex-wrap: nowrap; align-items: center; justify-content: center; gap: clamp(14px, 2.4vw, 36px); padding: 0; margin: 0; list-style: none; }
.footer-menu a { display: inline-block; padding: 8px 0; font-size: clamp(.78rem, 1.25vw, .98rem); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.footer-menu a[aria-current="page"] { color: var(--leaf-3); text-decoration: underline; text-underline-offset: 6px; }
.footer-copyright { margin: 0; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.08); width: 100%; font-size: .9rem; }
.footer-copyright > span[aria-hidden] { margin: 0 7px; }
.footer-copyright + .footer-copyright { border-top: 0; padding-top: 0; }
.info-page .page-hero { text-align: center; padding-bottom: 40px; }
.info-page .page-hero h1 { margin: 0; }
.info-content { padding-top: 40px; }
.info-page .prose { margin-inline: auto; }
.info-page .prose h4 { font-size: 1.05rem; margin-top: 1.5em; line-height: 1.35; }
.info-page .prose p { overflow-wrap: anywhere; }
@media (max-width: 767px) {
  .footer--centered { padding-top: 48px; }
  .footer-menu ul { flex-direction: column; gap: 8px; }
  .footer-menu a { font-size: .95rem; padding: 9px 8px; }
  .footer-copyright { max-width: 440px; line-height: 1.9; }
}
/* Guide directory and article pages. */
.guides-page .page-hero h1 { max-width: 28ch; }
.guide-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.guide-card { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; overflow: hidden; box-shadow: var(--shadow); }
.guide-card-link { display: block; height: 100%; color: inherit; text-decoration: none; transition: background-color .2s ease; }
.guide-card-link:hover { background: var(--sky-3); }
.guide-card-link:focus-visible { outline: 3px solid var(--leaf); outline-offset: -4px; }
.guide-card img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.guide-card-copy { padding: 24px; }
.guide-card h2 { font-family: var(--f-head); font-size: clamp(1.2rem, 2vw, 1.5rem); line-height: 1.3; margin: 0 0 14px; }
.guide-card p { color: var(--muted); line-height: 1.7; margin: 0; }
.guide-content { padding-top: 40px; padding-bottom: 72px; margin-inline: auto; overflow-wrap: anywhere; }
.guide-figure { margin: 0 0 32px; }
.guide-figure img { display: block; width: 100%; height: auto; border-radius: var(--radius); }
.guide-figure figcaption { font-size: .85rem; line-height: 1.6; color: var(--muted); margin-top: 12px; }
.guide-content p { line-height: 1.85; }
.guide-content h3 { font-size: 1.2rem; line-height: 1.4; }
@media (max-width: 1000px) { .guide-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .guide-grid { grid-template-columns: 1fr; } .guide-card-copy { padding: 20px; } .guide-content { padding-top: 28px; padding-bottom: 48px; } }
