/* ==========================================================================
   GrimToaster Interactive — grimtoaster.com
   ========================================================================== */

/* Fonts (self-hosted, SIL Open Font License) ------------------------------- */

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("../fonts/archivo-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("../fonts/archivo-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("../fonts/archivo-symbols.woff2") format("woff2");
  unicode-range: U+2192, U+221E;
}
@font-face {
  font-family: "Space Mono";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/space-mono-700-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Space Mono";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/space-mono-700-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Tokens -------------------------------------------------------------------- */

:root {
  --bg: #0c0a09;
  --bg-raised: #110e0c;
  --surface: #161210;
  --surface-hi: #1e1815;
  --line: rgba(244, 237, 228, 0.08);
  --line-strong: rgba(244, 237, 228, 0.16);
  --text: #f4ede4;
  --text-muted: #a69c91;
  --orange: #fb5e18;
  --orange-hot: #ff7a3d;
  --orange-glow: rgba(251, 94, 24, 0.55);

  --font-sans: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Space Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --container: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 72px;
  --radius: 20px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);

  --noise: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
  --tv-noise: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='s'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' seed='7' stitchTiles='stitch'/%3E%3CfeColorMatrix values='2.2 0 0 0 -.6 2.2 0 0 0 -.6 2.2 0 0 0 -.6 0 0 0 0 1'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23s)'/%3E%3C/svg%3E");
  --coil: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='30' viewBox='0 0 24 30'%3E%3Cdefs%3E%3Cpath id='c' d='M-24.00 5.00 -24.49 5.03 -24.98 5.13 -25.46 5.29 -25.92 5.51 -26.37 5.79 -26.78 6.13 -27.17 6.53 -27.53 6.98 -27.84 7.48 -28.12 8.03 -28.35 8.63 -28.52 9.26 -28.65 9.94 -28.72 10.64 -28.74 11.38 -28.69 12.13 -28.58 12.91 -28.41 13.70 -28.18 14.49 -27.88 15.29 -27.52 16.09 -27.10 16.88 -26.61 17.66 -26.06 18.42 -25.45 19.16 -24.79 19.87 -24.06 20.56 -23.29 21.20 -22.46 21.81 -21.59 22.37 -20.67 22.89 -19.72 23.36 -18.72 23.77 -17.70 24.12 -16.65 24.42 -15.59 24.66 -14.50 24.84 -13.40 24.95 -12.30 25.00 -11.19 24.98 -10.09 24.90 -9.00 24.76 -7.92 24.56 -6.86 24.29 -5.82 23.97 -4.82 23.59 -3.84 23.15 -2.90 22.66 -2.01 22.12 -1.15 21.54 -0.35 20.91 0.40 20.25 1.10 19.55 1.74 18.82 2.32 18.07 2.84 17.30 3.30 16.52 3.70 15.72 4.03 14.92 4.30 14.13 4.50 13.33 4.64 12.55 4.72 11.78 4.74 11.04 4.70 10.31 4.60 9.62 4.45 8.97 4.25 8.35 4.00 7.77 3.70 7.24 3.37 6.76 3.00 6.34 2.60 5.97 2.17 5.65 1.71 5.40 1.24 5.21 0.76 5.08 0.27 5.01 -0.23 5.01 -0.72 5.07 -1.20 5.19 -1.68 5.38 -2.13 5.63 -2.56 5.94 -2.97 6.31 -3.34 6.73 -3.68 7.20 -3.98 7.73 -4.23 8.30 -4.43 8.92 -4.59 9.57 -4.69 10.26 -4.74 10.98 -4.72 11.72 -4.65 12.49 -4.51 13.27 -4.31 14.06 -4.05 14.86 -3.73 15.66 -3.34 16.46 -2.88 17.24 -2.37 18.01 -1.79 18.77 -1.15 19.49 -0.46 20.19 0.29 20.86 1.09 21.49 1.94 22.08 2.83 22.62 3.76 23.11 4.74 23.55 5.74 23.94 6.78 24.27 7.84 24.54 8.91 24.75 10.00 24.90 11.11 24.98 12.21 25.00 13.31 24.95 14.41 24.85 15.50 24.68 16.57 24.44 17.62 24.15 18.64 23.80 19.64 23.39 20.60 22.93 21.52 22.42 22.39 21.86 23.22 21.25 24.00 20.61 24.73 19.93 25.40 19.22 26.02 18.48 26.57 17.72 27.06 16.94 27.49 16.15 27.86 15.36 28.16 14.56 28.40 13.76 28.57 12.97 28.68 12.19 28.74 11.44 28.73 10.70 28.66 9.99 28.54 9.32 28.36 8.68 28.14 8.08 27.87 7.52 27.55 7.02 27.20 6.56 26.82 6.16 26.40 5.81 25.96 5.53 25.50 5.30 25.02 5.14 24.53 5.04 24.04 5.00 23.55 5.03 23.06 5.12 22.58 5.27 22.11 5.49 21.67 5.76 21.25 6.10 20.86 6.49 20.50 6.94 20.18 7.44 19.90 7.99 19.67 8.58 19.49 9.21 19.36 9.88 19.28 10.59 19.26 11.32 19.30 12.07 19.41 12.85 19.57 13.63 19.80 14.43 20.09 15.23 20.45 16.03 20.87 16.82 21.35 17.60 21.89 18.36 22.50 19.10 23.16 19.82 23.88 20.50 24.65 21.15 25.47 21.76 26.34 22.33 27.25 22.85 28.21 23.32 29.20 23.74 30.22 24.10 31.26 24.40 32.33 24.64 33.41 24.82 34.51 24.94 35.61 25.00 36.72 24.99 37.82 24.91 38.91 24.78 39.99 24.58 41.06 24.32 42.09 24.00 43.11 23.62 44.08 23.18 45.02 22.70 45.92 22.16 46.78 21.58 47.59 20.96 48.34 20.30 49.05 19.61 49.69 18.88 50.28 18.13 50.80 17.36 51.27 16.58 51.67 15.79 52.00 14.99 52.28 14.19 52.49 13.39 52.63 12.61 52.72 11.84 52.74 11.09 52.70 10.37 52.61 9.68 52.46 9.02 52.26 8.40 52.02 7.82 51.73 7.28 51.40 6.80 51.03 6.37 50.63 5.99 50.20 5.68 49.75 5.42 49.28 5.22 48.80 5.08 48.31 5.01' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/defs%3E%3Cuse href='%23c' stroke='%23ff5a1f' stroke-opacity='.5' stroke-width='3.6'/%3E%3Cuse href='%23c' stroke='%23ffc08a' stroke-width='1.3'/%3E%3C/svg%3E");
  --ink-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='m'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' numOctaves='3' seed='3'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -5 3.4'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23m)'/%3E%3C/svg%3E");
}

/* Base ---------------------------------------------------------------------- */

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

html {
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
  overflow-x: clip;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

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

img {
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

h1,
h2,
h3,
p,
ul {
  margin: 0;
}

ul {
  padding: 0;
  list-style: none;
}

strong {
  font-weight: 650;
  color: var(--text);
}

::selection {
  background: var(--orange);
  color: var(--bg);
}

:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 1.15em;
  height: 1.15em;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 200;
  padding: 10px 18px;
  border-radius: 10px;
  background: var(--orange);
  color: var(--bg);
  font-weight: 700;
  transition: top 0.2s;
}

.skip-link:focus {
  top: 12px;
}

.container {
  width: min(100% - 2 * var(--gutter), var(--container));
  margin-inline: auto;
}

/* Film grain over everything — static, so it costs nothing while scrolling. */
.grain {
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  opacity: 0.05;
  background-image: var(--noise);
}

/* Shared bits --------------------------------------------------------------- */

/* Small labels are punched out on a label maker and stuck on slightly crooked. */
.tape {
  --tape-color: #a8380b;
  --tilt: -2deg;
  display: inline-block;
  padding: 0.52em 0.9em 0.46em;
  border-radius: 3px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0) 45%, rgba(0, 0, 0, 0.18)),
    var(--tape-color);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    inset 0 -1px 0 rgba(0, 0, 0, 0.35),
    0 10px 18px -10px rgba(0, 0, 0, 0.9);
  color: #fdeee2;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 800;
  font-stretch: 78%;
  letter-spacing: 0.1em;
  line-height: 1;
  text-shadow: 0 -1px 0 rgba(255, 255, 255, 0.2), 0 1px 1px rgba(0, 0, 0, 0.55);
  text-transform: uppercase;
  white-space: nowrap;
  transform: rotate(var(--tilt));
}

.tape--dark {
  --tape-color: #2b2420;
  color: var(--text);
}

.section-label {
  line-height: 1;
}

.section {
  position: relative;
  padding-block: clamp(88px, 11vw, 150px);
}

.section-head {
  max-width: 760px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

.section-title {
  margin-top: 20px;
  font-size: clamp(2.1rem, 1.3rem + 3.6vw, 3.9rem);
  font-weight: 850;
  font-stretch: 112%;
  line-height: 0.98;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  text-wrap: balance;
}

.section-lead {
  margin-top: 20px;
  max-width: 40em;
  color: var(--text-muted);
  font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  transition: transform 0.25s var(--ease-out), background-color 0.2s, color 0.2s, border-color 0.2s, box-shadow 0.25s;
}

.btn-primary {
  background: var(--orange);
  color: #140e0b;
  box-shadow: 0 10px 30px -10px var(--orange-glow);
}

.btn-ghost {
  border: 1px solid var(--line-strong);
  background: rgba(244, 237, 228, 0.03);
  color: var(--text);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 4px;
  transition: color 0.2s, border-color 0.2s;
}

@media (hover: hover) {
  .btn-primary:hover {
    background: var(--orange-hot);
    transform: translateY(-2px);
    box-shadow: 0 16px 36px -12px var(--orange-glow);
  }

  .btn-ghost:hover {
    border-color: var(--text);
    transform: translateY(-2px);
  }

  .text-link:hover {
    color: var(--orange);
    border-color: var(--orange);
  }
}

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

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 60;
  border-bottom: 1px solid transparent;
  transition: background-color 0.35s, border-color 0.35s;
}

.site-header.is-scrolled {
  background: rgba(12, 10, 9, 0.82);
  border-bottom-color: var(--line);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
}

/* Solid while the mobile menu is open: the page must not bleed through the panel. */
.nav-open .site-header {
  background: var(--bg);
  border-bottom-color: var(--line);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

.header-inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.brand-icon {
  width: auto;
  height: 40px;
  transition: transform 0.4s var(--ease-out);
}

.brand-word {
  width: auto;
  height: 19px;
}

@media (hover: hover) {
  .brand:hover .brand-icon {
    transform: rotate(-8deg) scale(1.06);
  }
}

.nav-panel {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
}

.nav-menu {
  display: flex;
  gap: 4px;
}

.nav-menu a {
  display: block;
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 600;
  transition: color 0.2s, background-color 0.2s;
}

.nav-menu a:hover {
  color: var(--text);
  background: rgba(244, 237, 228, 0.06);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  transition: color 0.2s, border-color 0.2s;
}

.icon-btn .icon {
  width: 16px;
  height: 16px;
}

.icon-btn:hover {
  color: var(--orange);
  border-color: var(--orange);
}

.lang-switch {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
}

.lang-switch button {
  min-width: 38px;
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  transition: color 0.2s, background-color 0.2s;
}

.lang-switch button:hover {
  color: var(--text);
}

.lang-switch button[aria-pressed="true"] {
  background: var(--orange);
  color: #140e0b;
}

.nav-toggle {
  display: none;
  position: relative;
  width: 44px;
  height: 44px;
  margin-left: auto;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
}

.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  position: absolute;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.3s var(--ease-out), background-color 0.2s;
}

.nav-toggle-bars {
  top: calc(50% - 1px);
  left: calc(50% - 9px);
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  left: 0;
}

.nav-toggle-bars::before {
  transform: translateY(-6px);
}

.nav-toggle-bars::after {
  transform: translateY(6px);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars {
  background: transparent;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before {
  transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after {
  transform: rotate(-45deg);
}

@media (max-width: 860px) {
  .nav-toggle {
    display: block;
  }

  .nav-panel {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 24px;
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
    margin: 0;
    padding: 4px var(--gutter) 28px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.9);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.25s, transform 0.35s var(--ease-out), visibility 0s 0.35s;
  }

  .nav-panel.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition: opacity 0.25s, transform 0.35s var(--ease-out), visibility 0s;
  }

  .nav-menu {
    flex-direction: column;
    gap: 0;
  }

  .nav-menu a {
    padding: 16px 2px;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
    color: var(--text);
    font-size: 1.35rem;
    font-weight: 800;
    font-stretch: 110%;
    text-transform: uppercase;
  }

  .nav-menu a:hover {
    background: none;
    color: var(--orange);
  }

  .header-actions {
    justify-content: space-between;
  }
}

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

.hero {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: calc(var(--header-h) + 24px) 0 88px;
  overflow: hidden;
  text-align: center;
}

.hero-embers {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

/* Heat behind the toaster: dithered pixel art, shown at 5x with crisp pixels.
   The canvas is bigger than any hero and fades out before its edges, so tall screens get no hard band. */
.hero-heat {
  position: absolute;
  inset: 0;
  background: url("../img/hero/pixel-glow.png?v=2") 50% 44% / 2560px 1600px no-repeat;
  image-rendering: pixelated;
  animation: pixel-heat 2.4s steps(3) infinite alternate;
}

/* Heating element along the bottom, with its warm haze — the embers rise off it. */
.hero-element {
  position: absolute;
  inset: 0;
  animation: coil-heat 3.4s ease-in-out infinite alternate;
}

.hero-element::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(110% 48% at 50% 100%, rgba(251, 94, 24, 0.3), transparent 72%);
}

/* The wrapper is much taller than the wire so its edge fade never clips the glow into a band. */
.coil-wrap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -10px;
  height: 110px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.coil {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 38px;
  margin-top: -19px;
  background: var(--coil) 0 50% / 30px 37.5px repeat-x;
  filter: drop-shadow(0 0 3px rgba(255, 90, 31, 0.9)) drop-shadow(0 0 16px rgba(255, 70, 20, 0.6));
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-logo {
  width: min(500px, 84vw);
  width: min(500px, 84vw, max(240px, (100svh - 460px) * 1.226));
  margin: 0 0 30px;
}

.hero-logo img {
  width: 100%;
}

.hero-icon {
  transform-origin: 51% 93%;
  animation: rumble 6s 2s infinite;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hero-icon.is-popping {
  animation: toaster-pop 0.7s var(--ease-out);
}

.hero-tagline {
  font-size: clamp(1.45rem, 1rem + 1.9vw, 2.3rem);
  font-weight: 850;
  font-stretch: 115%;
  line-height: 1.05;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  text-wrap: balance;
}

.accent {
  color: var(--orange);
}

.hero-sub {
  max-width: 32em;
  margin-top: 16px;
  color: var(--text-muted);
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.15rem);
  text-wrap: balance;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

/* Ticker -------------------------------------------------------------------- */

.marquee {
  overflow: hidden;
  padding: 22px 0;
  border-block: 1px solid var(--line);
  background: var(--bg-raised);
}

.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee 46s linear infinite;
}

.marquee-group {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.marquee span {
  padding-inline: 30px;
  color: transparent;
  -webkit-text-stroke: 1px rgba(244, 237, 228, 0.5);
  font-size: clamp(1.4rem, 1rem + 1.8vw, 2.3rem);
  font-weight: 850;
  font-stretch: 115%;
  line-height: 1.1;
  text-transform: uppercase;
  white-space: nowrap;
}

.marquee .marquee-label {
  color: var(--orange);
  -webkit-text-stroke: 0;
}

.marquee i {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
  background: var(--orange);
  transform: rotate(45deg);
}

/* Games --------------------------------------------------------------------- */

.game-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(16px, 2.4vw, 28px);
}

.game-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color 0.3s, transform 0.45s var(--ease-out), box-shadow 0.45s var(--ease-out);
}

@media (hover: hover) {
  .game-card:hover {
    border-color: rgba(251, 94, 24, 0.45);
    transform: translateY(-4px);
    box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.85);
  }
}

.game-card--featured {
  grid-column: 1 / -1;
}

.game-media {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: #050404;
}

.game-media > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.9s var(--ease-out);
}

@media (hover: hover) {
  .game-card:hover .game-media > img {
    transform: scale(1.035);
  }
}

.game-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  padding: clamp(22px, 3vw, 36px);
}

.game-title {
  font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.1rem);
  font-weight: 850;
  font-stretch: 110%;
  line-height: 1.02;
  text-transform: uppercase;
  text-wrap: balance;
}

.game-teaser {
  color: var(--text-muted);
}

/* Hand-applied labels never sit at the same angle twice. */
.game-card:nth-child(2) .tape { --tilt: 1.5deg; }
.game-card:nth-child(3) .tape { --tilt: -1deg; }

.game-card--featured .game-title {
  font-size: clamp(1.75rem, 1rem + 1.6vw, 2.6rem);
}

.game-card--featured .game-teaser {
  font-size: 1.15rem;
}

.game-card--featured .text-link {
  margin-top: 8px;
}

/* Anything To Declare? — real key art (2x pixel art, keep it crisp). */
.game-media--atd {
  aspect-ratio: 920 / 430;
}

.game-media--atd img {
  object-position: 50% 30%;
  image-rendering: pixelated;
}

@media (min-width: 961px) {
  .game-card--featured {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  }

  .game-card--featured .game-media {
    aspect-ratio: auto;
  }

  .game-card--featured .game-body {
    justify-content: center;
    padding: clamp(28px, 3.4vw, 48px);
  }
}

/* Customs stamp on the ATD art. */
.stamp {
  position: absolute;
  right: 5%;
  bottom: 9%;
  z-index: 2;
  padding: 0.5em 0.85em 0.45em;
  border: 3px solid currentColor;
  border-radius: 6px;
  color: #ff5233;
  font-family: var(--font-mono);
  font-size: clamp(0.66rem, 0.5rem + 0.55vw, 1rem);
  font-weight: 700;
  letter-spacing: 0.16em;
  line-height: 1.2;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: inset 0 0 0 2px rgba(0, 0, 0, 0.35);
  text-shadow: 0 0 14px rgba(255, 82, 51, 0.55);
  transform: rotate(-9deg);
  opacity: 0.92;
  mix-blend-mode: screen;
  -webkit-mask-image: var(--ink-mask);
  mask-image: var(--ink-mask);
  pointer-events: none;
}

/* Channel 404 — placeholder screen (static + OSD). */
.game-media--c404 {
  background: #0b0b0b;
}

.game-media--c404::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  background: radial-gradient(ellipse at center, transparent 45%, rgba(0, 0, 0, 0.8) 100%);
  pointer-events: none;
}

.tv-static {
  position: absolute;
  inset: -100px;
  background-image: var(--tv-noise);
  background-size: 200px 200px;
  opacity: 0.5;
  animation: tv-static 0.42s steps(1) infinite;
}

.tv-roll {
  position: absolute;
  left: 0;
  right: 0;
  top: -30%;
  height: 30%;
  background: linear-gradient(transparent, rgba(255, 255, 255, 0.09), transparent);
  animation: tv-roll 5s linear infinite;
}

.tv-scan {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: repeating-linear-gradient(to bottom, rgba(0, 0, 0, 0.38) 0 1px, transparent 1px 3px);
}

.tv-osd {
  position: absolute;
  z-index: 2;
  color: #eef6ee;
  font-family: var(--font-mono);
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1;
  text-shadow: 0 0 8px rgba(210, 255, 220, 0.55), 2px 0 rgba(255, 0, 70, 0.35), -2px 0 rgba(0, 200, 255, 0.35);
}

.tv-osd--ch {
  top: 8%;
  left: 6%;
  font-size: clamp(1rem, 0.75rem + 1vw, 1.6rem);
}

.tv-osd--clock {
  right: 6%;
  bottom: 9%;
  font-size: clamp(0.7rem, 0.6rem + 0.4vw, 0.95rem);
  opacity: 0.85;
}

.tv-nosignal {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  padding: 0.6em 0.9em 0.6em 1.2em;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.7);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: clamp(0.8rem, 0.65rem + 0.6vw, 1.1rem);
  font-weight: 700;
  letter-spacing: 0.3em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
  transform: translate(-50%, -50%);
  animation: tv-glitch 3.4s infinite;
}

/* Studio -------------------------------------------------------------------- */

.studio {
  background:
    radial-gradient(60% 50% at 100% 0%, rgba(251, 94, 24, 0.07), transparent 70%),
    var(--bg-raised);
  border-block: 1px solid var(--line);
}

.studio-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(40px, 6vw, 96px);
}

.studio-copy .section-title {
  margin-bottom: 28px;
}

.studio-copy p:not(.section-label) {
  max-width: 34em;
  color: var(--text-muted);
  font-size: 1.12rem;
}

.studio-copy p + p {
  margin-top: 1em;
}

.studio-copy a {
  color: var(--text);
  border-bottom: 1px solid var(--orange);
  transition: color 0.2s;
}

.studio-copy a:hover {
  color: var(--orange);
}

.stats {
  display: grid;
  gap: 14px;
}

.stat {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 22px 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(244, 237, 228, 0.035), rgba(244, 237, 228, 0.01));
  transition: border-color 0.3s;
}

.stat:hover {
  border-color: rgba(251, 94, 24, 0.35);
}

.stat-num {
  min-width: 1.25em;
  color: var(--orange);
  font-size: clamp(2.6rem, 2rem + 2vw, 3.6rem);
  font-weight: 900;
  font-stretch: 115%;
  line-height: 1;
  text-align: center;
}

.stat-label {
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.35;
}

/* Contact ------------------------------------------------------------------- */

.contact-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(48px, 8vw, 104px) clamp(20px, 5vw, 64px);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) * 1.5);
  background:
    radial-gradient(80% 120% at 50% 0%, rgba(251, 94, 24, 0.16), transparent 60%),
    var(--surface);
  text-align: center;
}

.contact-card .section-title {
  max-width: 15ch;
  margin-inline: auto;
}

.contact-text {
  max-width: 34em;
  margin: 22px auto 0;
  color: var(--text-muted);
  font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem);
}

.contact-mail {
  display: inline-block;
  margin-top: 36px;
  padding-bottom: 6px;
  font-size: clamp(1rem, 5.2vw, 3rem);
  font-weight: 800;
  font-stretch: 105%;
  letter-spacing: -0.01em;
  line-height: 1.15;
  overflow-wrap: anywhere;
  background: linear-gradient(var(--orange), var(--orange)) 0 100% / 0 3px no-repeat;
  transition: background-size 0.45s var(--ease-out), color 0.2s;
}

.contact-mail:hover {
  color: var(--orange);
  background-size: 100% 3px;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 30px;
}

.copy-btn .icon-check,
.copy-btn .copy-done {
  display: none;
}

.copy-btn.is-copied {
  border-color: var(--orange);
  color: var(--orange);
}

.copy-btn.is-copied .icon-check,
.copy-btn.is-copied .copy-done {
  display: inline;
}

.copy-btn.is-copied .icon-copy,
.copy-btn.is-copied .copy-label {
  display: none;
}

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

.site-footer {
  padding: 56px 0 40px;
  border-top: 1px solid var(--line);
}

.footer-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
}

.footer-nav a {
  color: var(--text-muted);
  font-weight: 600;
  transition: color 0.2s;
}

.footer-nav a:hover {
  color: var(--orange);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--text-muted);
  font-size: 0.9rem;
}

.to-top {
  font-weight: 600;
  transition: color 0.2s;
}

.to-top:hover {
  color: var(--orange);
}

/* Responsive ---------------------------------------------------------------- */

@media (max-width: 900px) {
  .studio-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 720px) {
  .game-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 420px) {
  .brand-word {
    height: 16px;
  }

  .btn {
    padding: 0 22px;
  }

  .stat {
    padding: 18px 20px;
  }
}

/* Entrance + scroll reveal (only when JS is running) ------------------------ */

.js .site-header,
.js .hero-anim {
  opacity: 0;
}

.js.is-loaded .site-header {
  animation: fade-in 0.8s ease 0.1s both;
}

.js.is-loaded .hero-anim {
  animation: rise-in 1s var(--ease-out) calc(var(--i, 0) * 110ms + 120ms) both;
}

.js .reveal {
  opacity: 0;
}

.js .reveal.is-visible {
  animation: rise-in 0.9s var(--ease-out) calc(var(--d, 0) * 120ms) both;
}

.js .stamp {
  opacity: 0;
}

.js .is-visible .stamp {
  animation: stamp 0.55s cubic-bezier(0.5, 0, 0.75, 0) 0.7s both;
}

/* Keyframes ------------------------------------------------------------------ */

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes rise-in {
  from { opacity: 0; translate: 0 28px; }
  to { opacity: 1; translate: 0 0; }
}

@keyframes coil-heat {
  from { opacity: 0.72; }
  to { opacity: 1; }
}

@keyframes pixel-heat {
  from { opacity: 0.8; }
  to { opacity: 1; }
}

@keyframes rumble {
  0%, 84%, 100% { transform: none; }
  86% { transform: translate(-1px, 1px) rotate(-1.2deg); }
  88% { transform: translate(1px, -1px) rotate(1.2deg); }
  90% { transform: translate(-1px, 0) rotate(-0.8deg); }
  92% { transform: translate(1px, 1px) rotate(0.8deg); }
  94% { transform: translate(0, -1px) rotate(-0.4deg); }
  96% { transform: none; }
}

@keyframes toaster-pop {
  0% { transform: none; }
  18% { transform: translateY(5px) scale(1.03, 0.94); }
  45% { transform: translateY(-18px) scale(0.98, 1.04); }
  72% { transform: translateY(2px) scale(1.01, 0.98); }
  100% { transform: none; }
}

@keyframes marquee {
  to { transform: translateX(-50%); }
}

@keyframes stamp {
  0% { opacity: 0; transform: rotate(-16deg) scale(1.9); }
  70% { opacity: 0.95; transform: rotate(-8deg) scale(0.94); }
  100% { opacity: 0.92; transform: rotate(-9deg) scale(1); }
}

@keyframes tv-static {
  0% { background-position: 0 0; }
  20% { background-position: -47px 31px; }
  40% { background-position: 63px -82px; }
  60% { background-position: -91px -17px; }
  80% { background-position: 28px 74px; }
}

@keyframes tv-roll {
  to { transform: translateY(440%); }
}

@keyframes tv-glitch {
  0%, 86%, 100% { transform: translate(-50%, -50%); text-shadow: none; clip-path: none; }
  87% { transform: translate(calc(-50% + 4px), -50%); text-shadow: -3px 0 #ff2a55, 3px 0 #22d3ee; }
  89% { transform: translate(calc(-50% - 5px), calc(-50% + 1px)); clip-path: inset(28% 0 38% 0); }
  91% { transform: translate(calc(-50% + 2px), -50%); text-shadow: 2px 0 #ff2a55, -2px 0 #22d3ee; clip-path: none; }
  93% { transform: translate(-50%, -50%); text-shadow: none; }
}

/* Motion preferences ---------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    animation-delay: 0s !important;
    transition-duration: 0.001ms !important;
  }
}
