/* ==========================================================================
   Mr Jeffman — one-page site
   Styles follow the Mr. Jeff Man Design System ("sticker-book cinema"):
   ink outlines, hard offset shadows, flat color, red as a highlighter.
   ========================================================================== */

@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,600;0,700;0,800;1,800&family=Nunito:wght@400;600;700&family=JetBrains+Mono:wght@400;700&display=swap");

/* ---- Design tokens (from the brand kit) ---- */
:root {
  --ink-900: #171717;
  --ink-800: #2B2B2B;
  --ink-600: #6B6B6B;
  --ink-500: #909090;
  --ink-200: #E8E8E8;
  --ink-100: #F3F3F3;
  --ink-050: #FAFAFA;
  --cut-red-700: #B5121B;
  --cut-red-600: #D81A24;
  --cut-red-500: #F4222D;
  --cut-red-100: #FEE8E9;
  --paper-000: #FFFFFF;

  --font-display: "Poppins", "Trebuchet MS", sans-serif;
  --font-body: "Nunito", "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", "Courier New", monospace;

  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-pill: 999px;

  --shadow-sticker: 4px 4px 0 var(--ink-900);
  --shadow-sticker-lg: 6px 6px 0 var(--ink-900);
  --shadow-sticker-press: 2px 2px 0 var(--ink-900);
  /* White gap then ink, so the outer ring clears 3:1 on white, on red,
     and on the ink sections alike. A red outer ring failed on the red button. */
  --ring-focus: 0 0 0 3px var(--paper-000), 0 0 0 6px var(--ink-900);

  --border-w: 2px;
  --border-w-thick: 3px;
  --page-max: 1160px;
  --page-gutter: 24px;

  --dur-base: 180ms;
  --ease-out: cubic-bezier(.2, .8, .3, 1);

  --pattern-perf: repeating-linear-gradient(90deg, var(--ink-900) 0 10px, transparent 10px 18px);
}

/* ---- Reset & base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font: 400 16px/1.6 var(--font-body);
  color: var(--ink-800);
  background: var(--paper-000);
}

img { max-width: 100%; display: block; }

a:focus-visible,
button:focus-visible {
  outline: none;
  box-shadow: var(--ring-focus);
}

section { scroll-margin-top: 88px; }

.wrap {
  max-width: var(--page-max);
  margin: 0 auto;
  padding-left: var(--page-gutter);
  padding-right: var(--page-gutter);
}

/* ---- Type helpers ---- */
h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--ink-900);
  letter-spacing: -0.02em;
}

.eyebrow {
  font: 700 14px/1.2 var(--font-display);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--cut-red-600);
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 20px;
  font: 800 16px/1 var(--font-display);
  text-decoration: none;
  color: var(--paper-000);
  background: var(--cut-red-500);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sticker);
  transition: all var(--dur-base) var(--ease-out);
}

.btn:hover { background: var(--cut-red-600); }

.btn:active {
  transform: translate(2px, 2px);
  box-shadow: var(--shadow-sticker-press);
}

.btn--pill { border-radius: var(--radius-pill); }

.btn--lg { padding: 16px 28px; font-size: 18px; }

/* ---- Sticky top bar ---- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--paper-000);
  border-bottom: var(--border-w) solid var(--ink-900);
}

.topbar .wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 64px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  margin-right: auto;
}

.brand img { width: 40px; height: auto; }

.brand span {
  font: 800 18px/1 var(--font-display);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-900);
  white-space: nowrap;
}

.topbar nav {
  display: flex;
  align-items: center;
  gap: 20px;
}

.topbar nav a:not(.btn) {
  font: 700 15px/1 var(--font-display);
  text-decoration: none;
  color: var(--ink-900);
  padding: 6px 2px;
  border-radius: 6px;
}

.topbar nav a:not(.btn):hover { color: var(--cut-red-600); }

@media (max-width: 480px) {
  .brand span { display: none; }
  .topbar nav { gap: 12px; }
}

/* ---- Hero: full-bleed cinema ---- */
.hero-cinema {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: min(92svh, 980px);
  padding: 96px 0 72px;
  background: image-set(
      url("assets/hero-bg.avif") type("image/avif"),
      url("assets/hero-bg.webp") type("image/webp"),
      url("assets/hero-bg.jpg") type("image/jpeg")
    ) center 35% / cover no-repeat var(--ink-900);
  overflow: hidden;
}

/* Flat scrim so white type reads on the sky — no blur, per the brand. */
.hero-cinema::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 55% at 50% 42%, rgba(23, 23, 23, 0.42), transparent 70%),
    linear-gradient(180deg, rgba(23, 23, 23, 0.30), rgba(23, 23, 23, 0.08) 45%, rgba(23, 23, 23, 0.38));
}

.hero-cinema-inner {
  position: relative;
}

.hero-mark {
  display: block;
  width: clamp(96px, 14vw, 140px);
  height: auto;
  margin: 0 auto 18px;
  filter: drop-shadow(0 3px 0 rgba(23, 23, 23, 0.35));
}

.hero-chip {
  display: inline-block;
  padding: 6px 14px;
  font: 700 13px/1.2 var(--font-display);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-900);
  background: var(--paper-000);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sticker-press);
}

.hero-cinema h1 {
  font-weight: 800;
  font-size: clamp(40px, 8vw, 76px);
  line-height: 1.08;
  margin: 20px 0 22px;
  color: var(--paper-000);
  text-shadow: 0 2px 0 rgba(23, 23, 23, 0.35);
}

.hero-cinema h1 span { display: block; }

/* The highlighter word: white italic on a tilted red sticker. */
.hero-cinema h1 em {
  display: inline-block;
  font-style: italic;
  color: var(--paper-000);
  text-shadow: none;
  background: var(--cut-red-500);
  border: var(--border-w-thick) solid var(--ink-900);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sticker);
  padding: 0.02em 0.28em 0.10em;
  transform: rotate(-2deg);
}

.hero-cinema .sub {
  font-size: 20px;
  line-height: 1.5;
  color: var(--ink-100);
  max-width: 34ch;
  margin: 0 auto 32px;
}

/* Staggered entrance, springy per the kit's motion tokens.
   Scoped to no-preference so the RESTING state is the visible one: if the
   animation never runs (reduced motion, no CSS animation support, a crawler
   snapshotting instantly) the hero is fully visible rather than at opacity 0. */
@media (prefers-reduced-motion: no-preference) {
  @keyframes hero-rise {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  .hero-cinema .hero-mark,
  .hero-cinema .hero-chip,
  .hero-cinema h1,
  .hero-cinema .sub,
  .hero-cinema .btn,
  .hero-cinema .hero-arrow {
    animation: hero-rise 320ms cubic-bezier(.34, 1.56, .64, 1) both;
  }

  .hero-cinema .hero-chip { animation-delay: 60ms; }
  .hero-cinema h1 { animation-delay: 120ms; }
  .hero-cinema .sub { animation-delay: 180ms; }
  .hero-cinema .btn { animation-delay: 240ms; }
  .hero-cinema .hero-arrow { animation-delay: 300ms; }
}

.hero-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-top: 40px;
  font: 700 20px/1 var(--font-mono);
  text-decoration: none;
  color: var(--ink-900);
  background: var(--paper-000);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sticker);
  transition: all var(--dur-base) var(--ease-out);
}

.hero-arrow:hover { background: var(--cut-red-100); }

.hero-arrow:active {
  transform: translate(2px, 2px);
  box-shadow: var(--shadow-sticker-press);
}

/* ---- Filmstrip perforation divider ---- */
.perf {
  height: 10px;
  background: var(--pattern-perf);
  border: 0;
  margin: 0;
}

/* ---- Sections ---- */
.section { padding: 72px 0; }

.section-head {
  text-align: center;
  margin-bottom: 40px;
}

.section-head h2 {
  font-weight: 800;
  font-size: clamp(28px, 5vw, 40px);
  line-height: 1.15;
  margin-top: 8px;
}

/* ---- Live stat cards (numbers come from the channel feed) ---- */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 720px;
  margin: 0 auto 40px;
}

@media (min-width: 600px) { .stats { gap: 20px; } }

/* Small screens get the 900px hero rather than the 1800px one. */
@media (max-width: 700px) {
  .hero-cinema {
    background-image: image-set(
      url("assets/hero-bg-sm.webp") type("image/webp"),
      url("assets/hero-bg.jpg") type("image/jpeg")
    );
  }
}

.stat {
  text-align: center;
  padding: 18px 10px;
  background: var(--paper-000);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sticker);
}

.stat-num {
  display: block;
  font: 800 clamp(26px, 6vw, 40px)/1 var(--font-display);
  letter-spacing: -0.02em;
  color: var(--cut-red-500);
}

.stat-label {
  display: block;
  margin-top: 6px;
  font: 600 12px/1.3 var(--font-body);
  color: var(--ink-600);
}

/* ---- Video grid ---- */
.video-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 600px) { .video-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .video-grid { grid-template-columns: repeat(3, 1fr); } }

.video-card {
  display: block;
  text-decoration: none;
}

.video-card .thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--ink-100);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sticker);
  overflow: hidden;
  transition: all var(--dur-base) var(--ease-out);
}

/* A dropped-in thumbnail <img> or <iframe> fills the frame automatically. */
.video-card .thumb img,
.video-card .thumb iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
}

.video-card:hover .thumb {
  transform: translate(-2px, -2px);
  box-shadow: var(--shadow-sticker-lg);
}

.play-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--cut-red-500);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-md);
}

.play-badge::before {
  content: "";
  width: 0;
  height: 0;
  margin-left: 4px;
  border-style: solid;
  border-width: 11px 0 11px 18px;
  border-color: transparent transparent transparent var(--paper-000);
}

.video-card h3 {
  font-weight: 700;
  font-size: 18px;
  line-height: 1.3;
  margin-top: 14px;
}

.video-card:hover h3 { color: var(--cut-red-600); }

.video-views {
  margin-top: 4px;
  font: 400 13px/1.4 var(--font-mono);
  letter-spacing: 0.02em;
  color: var(--ink-600);
}

/* ---- Steps ---- */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  counter-reset: step;
}

@media (min-width: 720px) { .steps { grid-template-columns: repeat(3, 1fr); } }

.step {
  background: var(--paper-000);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sticker);
  padding: 24px;
}

.step .num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  font: 700 16px/1 var(--font-mono);
  letter-spacing: 0.02em;
  color: var(--paper-000);
  background: var(--cut-red-500);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sticker-press);
  margin-bottom: 16px;
}

.step h3 {
  font-weight: 700;
  font-size: 20px;
  margin-bottom: 8px;
}

.step p { color: var(--ink-600); }

/* ---- Merch (dark "cinema" section) ---- */
.merch {
  background: var(--ink-900);
  padding: 72px 0;
}

/* White, not red: red on ink measures 4.37:1 and the brand rule is
   "never red text on black". The red accent lives in the checklist and button. */
.merch .eyebrow { color: var(--paper-000); }

.merch .section-head h2 { color: var(--paper-000); }

.offer {
  background: var(--paper-000);
  border: var(--border-w-thick) solid var(--paper-000);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sticker-lg);
  padding: 32px 24px;
}

@media (min-width: 720px) { .offer { padding: 48px; } }

.merch-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 36px;
}

@media (min-width: 600px) {
  .merch-grid { grid-template-columns: repeat(3, 1fr); gap: 24px; }
}

.product {
  display: block;
  text-decoration: none;
}

.product .photo {
  aspect-ratio: 1 / 1;
  background: var(--paper-000);
  border: var(--border-w) solid var(--ink-900);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sticker);
  overflow: hidden;
  transition: all var(--dur-base) var(--ease-out);
}

.product .photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product:hover .photo {
  transform: translate(-2px, -2px);
  box-shadow: var(--shadow-sticker-lg);
}

.product h3 {
  font-weight: 700;
  font-size: 16px;
  line-height: 1.3;
  margin-top: 12px;
}

.product:hover h3 { color: var(--cut-red-600); }

.product .price {
  font: 700 14px/1.4 var(--font-mono);
  letter-spacing: 0.02em;
  color: var(--ink-600);
}

.offer-checklist {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  max-width: 480px;
  margin: 0 auto 32px;
}

@media (min-width: 600px) { .offer-checklist { grid-template-columns: repeat(2, 1fr); } }

.offer-checklist li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  color: var(--ink-800);
}

.offer-checklist li::before {
  content: "";
  flex: none;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 6px 0 6px 10px;
  border-color: transparent transparent transparent var(--cut-red-500);
}

.offer-cta { text-align: center; }

.offer-cta small {
  display: block;
  margin-top: 12px;
  color: var(--ink-600);
}

/* ---- Footer ---- */
footer {
  text-align: center;
  padding: 48px 24px 56px;
}

footer img {
  width: 72px;
  margin: 0 auto 16px;
}

footer a {
  font-weight: 700;
  color: var(--cut-red-600);
  text-decoration: none;
  border-radius: 6px;
}

footer a:hover { color: var(--cut-red-700); text-decoration: underline; }

/* ---- Reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
  }
}
