/* ============================================================
   FITZ WEB DEV — fitzwebdev.com
   Black + red. Clash Display / Switzer / Fragment Mono.
   Signature: "The Cutout" — headline letters are windows onto a
   live cinematic image; cursor moves the image INSIDE the type.
   Nothing is ever hidden by hovering.
   ============================================================ */

@font-face {
  font-family: 'Clash Display';
  src: url('/fonts/ClashDisplay-Variable.woff2') format('woff2');
  font-weight: 200 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Switzer';
  src: url('/fonts/Switzer-Variable.woff2') format('woff2');
  font-weight: 100 900; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Fragment Mono';
  src: url('/fonts/FragmentMono-Regular.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}

:root {
  --black: #000000;
  --near: #070707;
  --panel: #0D0D0E;
  --line: rgba(255, 255, 255, 0.10);
  --line-2: rgba(255, 255, 255, 0.055);
  --white: #F4F3F2;
  --grey: rgba(244, 243, 242, 0.58);
  --grey-2: rgba(244, 243, 242, 0.38);
  --red: #E11D2A;
  --red-hot: #FF2E3A;
  /* green is reserved for money the client MAKES — never for UI chrome */
  --green: #25E07F;
  --green-hot: #4BFF9E;
  --green-dim: rgba(37, 224, 127, 0.18);
  --disp: 'Clash Display', Georgia, serif;
  --text: 'Switzer', 'Helvetica Neue', Arial, sans-serif;
  --mono: 'Fragment Mono', 'Courier New', monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--text);
  background: var(--black);
  color: var(--white);
  font-size: 17px; line-height: 1.62; font-weight: 400;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
::selection { background: var(--red); color: #fff; }
img { max-width: 100%; display: block; }

.wrap { max-width: 1240px; margin: 0 auto; padding: 0 32px; }
.mono { font-family: var(--mono); letter-spacing: 0.08em; }

.h2 {
  font-family: var(--disp); font-weight: 600;
  font-size: clamp(2.5rem, 6.2vw, 5.1rem); line-height: 0.98;
  letter-spacing: -0.022em;
}
.lede { margin-top: 24px; max-width: 54ch; color: var(--grey); font-size: 1.13rem; }

/* green = money the client makes; usable inline in display type */
.money { color: var(--green); text-shadow: 0 0 38px rgba(37, 224, 127, 0.32); }

.kicker {
  display: flex; align-items: center; gap: 14px;
  font-size: 0.7rem; color: var(--red); margin-bottom: 26px;
}
.kicker-bar { display: block; width: 34px; height: 2px; background: var(--red); }

/* ---------------- buttons ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--text); font-weight: 600; font-size: 0.95rem;
  text-decoration: none; padding: 15px 28px; border-radius: 2px;
  border: 1px solid transparent; letter-spacing: -0.005em;
  transition: background .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease;
}
.btn-red { background: var(--red); color: #fff; box-shadow: 0 0 0 rgba(225,29,42,0); }
.btn-red:hover { background: var(--red-hot); box-shadow: 0 0 34px rgba(225,29,42,0.45); }
.btn-ghost { color: var(--white); border-color: var(--line); background: transparent; }
.btn-ghost:hover { border-color: var(--white); }
.btn-slim { padding: 10px 18px; font-size: 0.85rem; background: var(--red); color: #fff; }
.btn-slim:hover { background: var(--red-hot); box-shadow: 0 0 26px rgba(225,29,42,0.42); }
.btn-block { display: flex; width: 100%; margin-top: 30px; }
.btn-big { font-family: var(--mono); font-size: clamp(0.95rem, 2.3vw, 1.35rem); padding: 20px 38px; }
.btn-short { display: none; }

/* ---------------- topbar ---------------- */
.topbar {
  position: fixed; inset: 0 0 auto 0; z-index: 60;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 32px; transition: background .3s ease, border-color .3s ease;
  border-bottom: 1px solid transparent;
}
.topbar.stuck {
  background: rgba(0,0,0,0.82); backdrop-filter: blur(10px);
  border-bottom-color: var(--line-2);
}
.wordmark {
  font-family: var(--disp); font-weight: 600; font-size: 1.15rem;
  letter-spacing: 0.02em; color: var(--white); text-decoration: none;
}
.wm-red { color: var(--red); }

/* ============================================================
   HERO — "The Cutout"
   ============================================================ */
.hero {
  position: relative; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  overflow: hidden; padding: 130px 0 96px;
}
.hero-bg {
  position: absolute; inset: -4%;
  background: url('/assets/gen/hero-trails.jpg') center/cover no-repeat;
  opacity: 0.09; filter: saturate(1.1) blur(1px);
}
.hero-vignette {
  position: absolute; inset: 0;
  background:
    radial-gradient(120% 90% at 50% 44%, rgba(0,0,0,0.25) 0%, rgba(0,0,0,0.82) 58%, #000 100%),
    linear-gradient(to bottom, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.45) 24%, rgba(0,0,0,0.55) 62%, #000 100%);
}
.hero-inner { position: relative; z-index: 3; }

.eyebrow { font-size: 0.72rem; color: var(--grey-2); margin-bottom: 30px; }

/* the signature: image-filled headline */
.cutout {
  font-family: var(--disp); font-weight: 600;
  font-size: clamp(2.9rem, 9.4vw, 8.2rem); line-height: 0.9;
  letter-spacing: -0.035em; margin-bottom: 30px;
  color: var(--white); text-wrap: balance;
}
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .cutout {
    background-image:
      linear-gradient(rgba(255, 60, 70, 0.30), rgba(255, 60, 70, 0.30)),
      url('/assets/gen/hero-trails.jpg');
    background-size: 190% auto, 190% auto;
    background-position: var(--bgx, 50%) var(--bgy, 62%);
    -webkit-background-clip: text; background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    /* the fill must out-punch the near-black page or letterforms dissolve */
    filter: brightness(2.5) contrast(1.3) saturate(1.45);
    /* guarantees an edge even where the photo goes black */
    -webkit-text-stroke: 1.1px rgba(255, 255, 255, 0.30);
  }
}
/* soft red bloom so the type reads as lit, not pasted */
.cutout::after {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(58% 62% at 42% 52%, rgba(225, 29, 42, 0.20), transparent 70%);
  filter: blur(38px); pointer-events: none;
}
.cutout { position: relative; }
html.anim .cutout { transition: background-position .45s cubic-bezier(.2,.7,.3,1); }
html.anim .cutout.tracking { transition: none; }

.hero-sub {
  max-width: 56ch; color: var(--grey); font-size: 1.14rem; margin-bottom: 40px;
}
.hero-sub strong { color: var(--white); font-weight: 600; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* the differentiator, demoted to a badge — it de-risks, it doesn't sell */
.hero-badge {
  display: inline-flex; align-items: center; gap: 10px;
  margin-top: 34px; font-size: 0.66rem; color: var(--grey-2);
}
.hb-dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--red);
  box-shadow: 0 0 10px 1px rgba(225,29,42,0.9); flex: 0 0 auto;
}
html.anim .hb-dot { animation: pulse 2.6s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.hero-foot {
  position: absolute; left: 0; right: 0; bottom: 30px; z-index: 3;
  display: flex; justify-content: center; gap: 16px;
  font-size: 0.66rem; color: var(--grey-2);
}
.hero-foot .dot { color: var(--red); }

/* one-time red sweep on load */
.scanline {
  position: absolute; top: 0; bottom: 0; width: 2px; left: -3px; z-index: 4;
  background: linear-gradient(to bottom, transparent, var(--red-hot) 22%, var(--red-hot) 78%, transparent);
  box-shadow: 0 0 30px 5px rgba(225,29,42,0.6);
  opacity: 0; pointer-events: none;
}
html.anim .scanline.run { animation: sweep 1.45s cubic-bezier(.65,0,.25,1) forwards; }
@keyframes sweep {
  0%   { opacity: 0;   left: -3px; }
  12%  { opacity: 1; }
  88%  { opacity: 1; }
  100% { opacity: 0;   left: 100%; }
}

/* ============================================================
   SECTIONS
   ============================================================ */
.sect { padding: clamp(92px, 13vw, 168px) 0; position: relative; }
.sect + .sect { border-top: 1px solid var(--line-2); }

.steps {
  margin-top: clamp(52px, 7vw, 88px);
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px; background: var(--line-2); border: 1px solid var(--line-2);
}
.step { background: var(--black); padding: clamp(28px, 3.6vw, 46px); position: relative; }
.step-n { font-size: 0.72rem; color: var(--red); display: block; margin-bottom: 20px; }
.step h3 {
  font-family: var(--disp); font-weight: 600; font-size: 1.55rem;
  letter-spacing: -0.015em; margin-bottom: 12px;
}
.step p { color: var(--grey); font-size: 0.98rem; max-width: 40ch; }

/* ---------------- bands ---------------- */
.band {
  position: relative; padding: clamp(96px, 15vw, 190px) 0;
  background-color: var(--black); background-size: cover;
  background-position: center; background-repeat: no-repeat;
}
.band::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to right, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.62) 55%, rgba(0,0,0,0.3) 100%);
}
.band-edge { background-image: url('/assets/gen/red-edge.jpg'); }
.band-room { background-image: url('/assets/gen/red-room.jpg'); }
.band-inner { position: relative; z-index: 2; }
.band-quote {
  font-family: var(--disp); font-weight: 500;
  font-size: clamp(2rem, 5.2vw, 4.1rem); line-height: 1.02;
  letter-spacing: -0.022em; max-width: 20ch;
}
.band-quote em { font-style: normal; color: var(--red); }
.band-sub { margin-top: 26px; font-size: 0.68rem; color: var(--grey-2); }

/* ---------------- pricing ---------------- */
.price-grid {
  margin-top: clamp(52px, 7vw, 84px);
  display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1fr);
  gap: clamp(28px, 4vw, 56px); align-items: start;
}
.price-card {
  background: var(--panel); border: 1px solid var(--line);
  padding: clamp(30px, 3.4vw, 44px); border-radius: 3px; position: relative;
}
.price-card::before {
  content: ''; position: absolute; top: -1px; left: -1px; right: -1px; height: 2px;
  background: var(--red); box-shadow: 0 0 24px rgba(225,29,42,0.65);
}
.pc-label { font-size: 0.66rem; color: var(--grey-2); }
.pc-price {
  font-family: var(--disp); font-weight: 600; font-size: clamp(3.6rem, 8vw, 5.6rem);
  line-height: 1; letter-spacing: -0.04em; margin: 12px 0 28px;
}
.pc-cur { color: var(--red); font-size: 0.5em; vertical-align: super; margin-right: 2px; }
.pc-per { font-family: var(--text); font-size: 0.2em; font-weight: 500; color: var(--grey); letter-spacing: 0; }
.pc-tax {
  font-size: 0.6rem; color: var(--grey-2);
  margin: -18px 0 26px; letter-spacing: 0.1em;
}
.pc-list { list-style: none; }
.pc-list li {
  padding: 12px 0 12px 26px; border-bottom: 1px solid var(--line-2);
  color: var(--grey); font-size: 0.95rem; position: relative;
}
.pc-list li:last-child { border-bottom: none; }
.pc-list li::before {
  content: ''; position: absolute; left: 0; top: 20px;
  width: 9px; height: 2px; background: var(--green);
}
.price-notes { display: grid; gap: 1px; background: var(--line-2); border: 1px solid var(--line-2); }
.price-notes .note { background: var(--black); padding: clamp(24px, 2.8vw, 34px); }
.note h3 {
  font-family: var(--disp); font-weight: 600; font-size: 1.24rem;
  margin-bottom: 8px; letter-spacing: -0.012em;
}
.note p { color: var(--grey); font-size: 0.95rem; max-width: 46ch; }

/* ---------------- the calculator ---------------- */
.calc {
  margin-top: clamp(52px, 7vw, 84px);
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 1px; background: var(--line-2); border: 1px solid var(--line-2);
}
.calc-controls {
  background: var(--black); padding: clamp(30px, 3.6vw, 48px);
  display: flex; flex-direction: column; gap: clamp(34px, 4vw, 48px);
  justify-content: center;
}
.cf-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 16px; margin-bottom: 20px;
}
.cf-label { font-size: 0.64rem; color: var(--grey-2); }
.cf-val {
  font-family: var(--disp); font-weight: 600; font-size: 1.65rem;
  letter-spacing: -0.02em; color: var(--white); font-variant-numeric: tabular-nums;
}

/* range input — styled for both engines */
.cfield input[type="range"] {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 4px; border-radius: 3px; outline: none;
  background: rgba(255, 255, 255, 0.13);
  cursor: pointer; display: block;
}
.cfield input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 24px; height: 24px; border-radius: 50%; border: 0;
  background: var(--green); cursor: grab;
  box-shadow: 0 0 0 5px var(--green-dim), 0 0 20px rgba(37, 224, 127, 0.55);
}
.cfield input[type="range"]::-webkit-slider-thumb:active { cursor: grabbing; }
.cfield input[type="range"]::-moz-range-thumb {
  width: 24px; height: 24px; border-radius: 50%; border: 0;
  background: var(--green); cursor: grab;
  box-shadow: 0 0 0 5px var(--green-dim), 0 0 20px rgba(37, 224, 127, 0.55);
}
.cfield input[type="range"]:focus-visible {
  outline: 2px solid var(--green); outline-offset: 8px;
}
.cf-scale {
  display: flex; justify-content: space-between;
  margin-top: 14px; font-size: 0.62rem; color: rgba(244, 243, 242, 0.26);
}

.calc-out {
  background: var(--panel); padding: clamp(30px, 3.6vw, 48px);
  display: flex; flex-direction: column; justify-content: center;
  position: relative; overflow: hidden;
}
.calc-out::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(85% 70% at 20% 30%, rgba(37, 224, 127, 0.10), transparent 70%);
  pointer-events: none;
}
.calc-out > * { position: relative; }
.co-label { font-size: 0.64rem; color: var(--green); margin-bottom: 12px; }
.co-big {
  font-family: var(--disp); font-weight: 600;
  font-size: clamp(3.2rem, 7.4vw, 5.4rem); line-height: 0.94;
  letter-spacing: -0.04em; color: var(--green);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 46px rgba(37, 224, 127, 0.35);
}
.co-sub { margin-top: 16px; color: var(--grey); font-size: 1.02rem; }
.co-year { color: var(--green-hot); font-weight: 600; font-variant-numeric: tabular-nums; }
.co-foot {
  margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line-2);
  font-size: 0.64rem; color: var(--grey-2); font-variant-numeric: tabular-nums;
}

.math-note {
  margin-top: clamp(38px, 5vw, 58px); max-width: 64ch;
  color: var(--grey); font-size: 1.06rem;
  padding-left: 22px; border-left: 2px solid var(--green);
}
.math-note strong { color: var(--white); font-weight: 600; }

/* ---------------- features ---------------- */
.feat {
  margin-top: clamp(52px, 7vw, 84px);
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(30px, 3.6vw, 52px);
}
.f { padding-top: 22px; border-top: 1px solid var(--line); }
.f-n { font-size: 0.68rem; color: var(--red); display: block; margin-bottom: 16px; }
.f h3 {
  font-family: var(--disp); font-weight: 600; font-size: 1.3rem;
  margin-bottom: 8px; letter-spacing: -0.012em;
}
.f p { color: var(--grey); font-size: 0.95rem; }

/* ---------------- cta ---------------- */
.sect-cta { text-align: center; padding-bottom: clamp(96px, 13vw, 160px); }
.sect-cta .h2-cta { margin: 0 auto; }
.lede-cta { margin: 24px auto 44px; text-align: center; }

/* ---------------- footer ---------------- */
.foot { border-top: 1px solid var(--line-2); padding: 44px 0; }
.foot-inner { display: flex; justify-content: space-between; align-items: flex-end; gap: 26px; flex-wrap: wrap; }
.wordmark-foot { font-size: 1rem; }
.foot-legal { font-size: 0.66rem; color: var(--grey-2); text-align: right; line-height: 2; }
.foot-dim { color: rgba(244,243,242,0.24); }

/* ============================================================
   REVEALS — opt-in (content visible without JS)
   ============================================================ */
html.js-reveal .step, html.js-reveal .f, html.js-reveal .note,
html.js-reveal .price-card, html.js-reveal .band-inner,
html.js-reveal .calc-controls, html.js-reveal .calc-out {
  opacity: 0; transform: translateY(16px);
  transition: opacity .6s ease, transform .6s ease;
}
html.js-reveal .in { opacity: 1 !important; transform: none !important; }

/* ============================================================
   REDUCED MOTION — states still apply, transitions strip
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.anim .scanline.run { animation: none; opacity: 0; }
  html.anim .cutout, html.anim .cutout.tracking { transition: none; }
  html.js-reveal .step, html.js-reveal .f, html.js-reveal .note,
  html.js-reveal .price-card, html.js-reveal .band-inner,
  html.js-reveal .calc-controls, html.js-reveal .calc-out { transition: none; }
  html.anim .hb-dot { animation: none; }
  .co-big { transition: none; }
  .btn { transition: none; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
  .price-grid { grid-template-columns: 1fr; }
  .feat { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calc { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .steps { grid-template-columns: 1fr; }
  .feat { grid-template-columns: 1fr; gap: 26px; }
  .hero { padding-top: 116px; }
  /* zoom the fill hard: at small type, fine trails read as noise */
  .cutout { background-size: 330% auto; background-position: 42% 58%; }
  .foot-inner { flex-direction: column; align-items: flex-start; }
  .foot-legal { text-align: left; }
  .band::after { background: linear-gradient(to bottom, rgba(0,0,0,0.72), rgba(0,0,0,0.88)); }
}
@media (max-width: 520px) {
  .wrap { padding: 0 20px; }
  .topbar { padding: 12px 20px; gap: 12px; }
  .wordmark { font-size: 0.94rem; white-space: nowrap; }
  .btn-long { display: none; }
  .btn-short { display: inline; }
  /* topbar button must not inherit the full-width hero-button rule */
  .topbar .btn-slim {
    width: auto; padding: 9px 14px; font-size: 0.78rem;
    white-space: nowrap; flex: 0 0 auto;
  }
  /* At phone sizes the photo fill reads as stripes across the letterforms.
     Heavy red flood + extreme zoom = solid red type with a hint of streak. */
  .cutout {
    background-image:
      linear-gradient(rgba(214, 24, 38, 0.80), rgba(214, 24, 38, 0.80)),
      url('/assets/gen/hero-trails.jpg');
    background-size: 100% 100%, 620% auto;
    background-position: 50% 50%, 40% 56%;
    filter: brightness(1.35) contrast(1.1) saturate(1.25);
    -webkit-text-stroke-width: 0;
  }
  .hero-sub { font-size: 1.03rem; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .btn { width: 100%; }
  .btn-big { width: 100%; }
  .hero-foot { font-size: 0.6rem; gap: 10px; }
}
