/* ==========================================================================
   IC7 Game — Global styles & shared components
   Mobile-first. BEM-lite. No frameworks.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Sora:wght@400;600;700;800&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@600;700&display=swap');

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--color-bg);
  color: var(--color-text-primary);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea, select { font: inherit; color: inherit; }

:focus-visible {
  outline: 2px solid var(--color-accent-bright);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

::selection { background: var(--color-accent); color: #fff; }

/* ---------- Typography ---------- */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: var(--lh-tight);
  color: var(--color-text-primary);
}

h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); font-weight: 700; }
h4 { font-size: var(--fs-h4); font-weight: 700; letter-spacing: -0.01em; }

p { color: var(--color-text-secondary); }

strong, b { color: var(--color-text-primary); font-weight: 600; }

.text-accent { color: var(--color-accent-bright); }
.text-gold   { color: var(--color-gold); }
.text-muted  { color: var(--color-text-muted); }

/* Numerals get emphasis — the one sanctioned color deviation */
.num {
  font-family: var(--font-mono);
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* ---------- Layout primitives ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.container--narrow { max-width: var(--container-narrow); }

.section {
  position: relative;
  padding-block: var(--space-16);
}

.section--alt { background: var(--color-bg-alt); }

/* Diagonal-cut divider — 2.5deg, subtle rhythm */
.section--cut {
  clip-path: polygon(0 2.2vw, 100% 0, 100% 100%, 0 100%);
  margin-top: -2vw;
  padding-top: calc(var(--space-16) + 2vw);
}

.section--cut-bottom {
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 2.2vw), 0 100%);
  padding-bottom: calc(var(--space-16) + 2vw);
}

.section__head {
  max-width: 720px;
  margin-bottom: var(--space-12);
}

.section__head--center {
  margin-inline: auto;
  text-align: center;
}

/* Long paragraphs stay left-aligned even in centered sections */
.section__head--center p { text-align: left; }
@media (min-width: 768px) {
  .section__head--center p { text-align: center; }
}

.section__lead {
  margin-top: var(--space-4);
  font-size: 1.05rem;
  color: var(--color-text-secondary);
}

/* ---------- Eyebrow + chip motif ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent-bright);
  margin-bottom: var(--space-4);
}

/* Casino chip: flat ring, no photorealism */
.chip {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  border-radius: 50%;
  border: 2px solid currentColor;
  position: relative;
}

.chip::after {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  border: 1px dashed currentColor;
  opacity: 0.55;
}

.chip--lg { width: 20px; height: 20px; flex-basis: 20px; }

/* ---------- Vault-line card ---------- */
.vault {
  position: relative;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: background var(--dur-med) var(--ease-out),
              border-color var(--dur-med) var(--ease-out),
              transform var(--dur-med) var(--ease-out),
              box-shadow var(--dur-med) var(--ease-out);
}

/* Scanner line sweeps the top edge on hover */
.vault::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  height: 1px;
  width: 100%;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--color-accent) 45%,
    var(--color-accent-bright) 50%,
    var(--color-accent) 55%,
    transparent 100%);
  transform: translateX(-100%);
  opacity: 0;
  transition: opacity var(--dur-fast) linear;
}

.vault:hover,
.vault:focus-within {
  background: var(--color-surface-raised);
  border-color: var(--color-border-glow);
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
}

.vault:hover::before,
.vault:focus-within::before {
  opacity: 1;
  animation: vault-sweep 1.1s var(--ease-out) forwards;
}

@keyframes vault-sweep {
  from { transform: translateX(-100%); }
  to   { transform: translateX(100%); }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 14px var(--space-6);
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  text-align: center;
  transition: background var(--dur-med) var(--ease-out),
              box-shadow var(--dur-med) var(--ease-out),
              transform var(--dur-med) var(--ease-out),
              border-color var(--dur-med) var(--ease-out);
}

.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  background: var(--color-accent);
  color: var(--color-text-on-accent);
  box-shadow: 0 0 0 rgba(230, 30, 45, 0);
}

.btn--primary:hover {
  background: var(--color-accent-bright);
  box-shadow: var(--shadow-glow-accent);
}

.btn--primary:active { background: var(--color-accent-dim); }

.btn--ghost {
  background: transparent;
  border-color: var(--color-border);
  color: var(--color-text-primary);
}

.btn--ghost:hover {
  border-color: var(--color-accent);
  box-shadow: 0 0 18px rgba(230, 30, 45, 0.18);
}

.btn--gold {
  background: var(--color-gold);
  color: #17140A;
}

.btn--gold:hover { box-shadow: var(--shadow-glow-gold); }

/* Telegram — brand blue lives only here */
.btn--telegram {
  background: rgba(38, 165, 228, 0.1);
  border-color: rgba(38, 165, 228, 0.45);
  color: var(--color-text-primary);
}

.btn--telegram svg { width: 18px; height: 18px; fill: var(--color-telegram); }

.btn--telegram:hover {
  background: rgba(38, 165, 228, 0.18);
  border-color: var(--color-telegram);
  box-shadow: 0 0 20px rgba(38, 165, 228, 0.28);
}

.btn--telegram-solid {
  background: var(--color-telegram);
  border-color: var(--color-telegram);
  color: #fff;
}

.btn--telegram-solid svg { fill: #fff; }

.btn--telegram-solid:hover {
  background: #1c93cf;
  box-shadow: 0 0 24px rgba(38, 165, 228, 0.4);
}

.btn--lg { padding: 17px var(--space-8); font-size: 1.02rem; }
.btn--sm { padding: 10px var(--space-4); font-size: var(--fs-small); }
.btn--block { display: flex; width: 100%; }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

/* ---------- Badges / pills ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 6px var(--space-3);
  font-size: var(--fs-xs);
  font-weight: 600;
  border-radius: var(--radius-pill);
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text-secondary);
  white-space: nowrap;
}

.badge--age {
  border-color: rgba(230, 30, 45, 0.4);
  color: var(--color-accent-bright);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.badge--gold {
  border-color: rgba(232, 184, 75, 0.4);
  color: var(--color-gold);
}

/* ---------- Navigation ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background var(--dur-med) var(--ease-out),
              border-color var(--dur-med) var(--ease-out);
}

.nav.is-stuck {
  background: rgba(10, 10, 12, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--color-border);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  height: 72px;
}

/* Brand wordmark. logo.png is 1254x406 (~3.09:1) — never constrain both
   axes or it distorts. Set height only and let width follow. */
.nav__logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  line-height: 0;
}

.nav__logo img {
  height: 34px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}

@media (min-width: 992px) {
  .nav__logo img { height: 38px; }
}

/* Footer wordmark sits a touch larger — it anchors the brand block */
.footer__logo img { height: 44px; }

.nav__links { display: none; }

.nav__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.nav__cta { display: none; }

.nav__burger {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
}

.nav__burger span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--color-text-primary);
  box-shadow: 0 -6px 0 var(--color-text-primary), 0 6px 0 var(--color-text-primary);
}

/* Mobile drawer */
.drawer {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  visibility: hidden;
  pointer-events: none;
}

.drawer.is-open { visibility: visible; pointer-events: auto; }

.drawer__scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  opacity: 0;
  transition: opacity var(--dur-med) var(--ease-out);
}

.drawer.is-open .drawer__scrim { opacity: 1; }

.drawer__panel {
  position: absolute;
  top: 0; right: 0;
  height: 100%;
  width: min(320px, 86vw);
  padding: var(--space-6);
  background: var(--color-bg-alt);
  border-left: 1px solid var(--color-border);
  transform: translateX(100%);
  transition: transform var(--dur-slow) var(--ease-out);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  overflow-y: auto;
}

.drawer.is-open .drawer__panel { transform: translateX(0); }

.drawer__close {
  align-self: flex-end;
  width: 40px;
  height: 40px;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--color-text-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

.drawer__link {
  padding: var(--space-4) var(--space-2);
  font-family: var(--font-display);
  font-weight: 600;
  border-bottom: 1px solid var(--color-border);
  transition: color var(--dur-fast) var(--ease-out), padding-left var(--dur-fast) var(--ease-out);
}

.drawer__link:hover,
.drawer__link[aria-current='page'] {
  color: var(--color-accent-bright);
  padding-left: var(--space-4);
}

.drawer .btn { margin-top: var(--space-4); }

@media (min-width: 992px) {
  .nav__links {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    margin-left: auto;
  }

  .nav__link {
    position: relative;
    padding: var(--space-2) var(--space-4);
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    transition: color var(--dur-fast) var(--ease-out);
  }

  .nav__link::after {
    content: '';
    position: absolute;
    left: var(--space-4);
    right: var(--space-4);
    bottom: 2px;
    height: 1px;
    background: var(--color-accent);
    transform: scaleX(0);
    transition: transform var(--dur-med) var(--ease-out);
  }

  .nav__link:hover,
  .nav__link[aria-current='page'] { color: var(--color-text-primary); }
  .nav__link:hover::after,
  .nav__link[aria-current='page']::after { transform: scaleX(1); }

  .nav__cta { display: inline-flex; }
  .nav__burger { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding-block: var(--space-12) var(--space-16);
  overflow: hidden;
}

/* Ambient red glow — the ONLY big glow on the page, behind the mockup */
.hero__glow {
  position: absolute;
  top: 8%;
  right: -10%;
  width: 620px;
  height: 620px;
  border-radius: 50%;
  background: radial-gradient(circle,
    rgba(230, 30, 45, 0.28) 0%,
    rgba(230, 30, 45, 0.10) 35%,
    transparent 68%);
  pointer-events: none;
  filter: blur(20px);
}

.hero__grid {
  position: relative;
  display: grid;
  gap: var(--space-12);
  align-items: center;
}

.hero__title { margin-bottom: var(--space-5); }

.hero__sub {
  font-size: 1.06rem;
  max-width: 56ch;
  margin-bottom: var(--space-6);
}

.hero__ctas { margin-bottom: var(--space-6); }

.hero__trust {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-5);
  padding-top: var(--space-6);
  border-top: 1px solid var(--color-border);
  font-size: var(--fs-small);
  color: var(--color-text-muted);
}

.hero__trust li {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.hero__trust .chip { color: var(--color-accent); }

/* Phone mockup — CSS shell, real screenshot inside */
.mockup {
  position: relative;
  justify-self: center;
  width: min(300px, 82vw);
  padding: 10px;
  background: linear-gradient(160deg, #26262C, #121215);
  border: 1px solid var(--color-border);
  border-radius: 38px;
  box-shadow: var(--shadow-card-hover), 0 0 60px rgba(230, 30, 45, 0.15);
  animation: float 4s ease-in-out infinite;
}

.mockup::before {
  content: '';
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: 90px;
  height: 5px;
  border-radius: var(--radius-pill);
  background: #0A0A0C;
  z-index: 2;
}

/* hero_image.png is 839x1874 — match it so the screen isn't cropped */
.mockup img {
  width: 100%;
  border-radius: 30px;
  aspect-ratio: 839 / 1874;
  object-fit: contain;
  background: var(--color-bg);
}

.mockup--sm { width: min(240px, 70vw); }

@keyframes float {
  0%, 100% { transform: translateY(-6px); }
  50%      { transform: translateY(6px); }
}

@media (min-width: 992px) {
  .hero { padding-block: var(--space-16) var(--space-24); }
  .hero__grid { grid-template-columns: 1.1fr 0.9fr; gap: var(--space-16); }
}

/* ---------- OG / promo banner strip ---------- */
.promo {
  position: relative;
  min-height: 320px;
  display: grid;
  align-items: center;
  overflow: hidden;
  border-block: 1px solid var(--color-border);
}

.promo__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.34;
}

.promo::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    var(--color-bg) 8%,
    rgba(10, 10, 12, 0.86) 45%,
    rgba(10, 10, 12, 0.55) 100%);
}

.promo__inner {
  position: relative;
  z-index: 1;
  max-width: 640px;
  padding-block: var(--space-12);
}

.promo__title { margin-bottom: var(--space-4); }
.promo__text { margin-bottom: var(--space-6); }

/* ---------- Stats strip ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--color-border);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.stat {
  padding: var(--space-8) var(--space-5);
  background: var(--color-surface);
  text-align: center;
}

.stat__num {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(1.6rem, 4vw, 2.3rem);
  font-weight: 700;
  color: var(--color-gold);
  letter-spacing: -0.02em;
}

.stat__label {
  display: block;
  margin-top: var(--space-2);
  font-size: var(--fs-small);
  color: var(--color-text-secondary);
}

.stat__note {
  display: block;
  margin-top: var(--space-1);
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

@media (min-width: 768px) {
  .stats { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Generic card grids ---------- */
.grid {
  display: grid;
  gap: var(--space-5);
}

.grid--2 { grid-template-columns: 1fr; }
.grid--3 { grid-template-columns: 1fr; }
.grid--4 { grid-template-columns: repeat(2, 1fr); }

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

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

/* ---------- Feature card ---------- */
.feature { padding: var(--space-8) var(--space-6); }

.feature__icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin-bottom: var(--space-5);
  border-radius: var(--radius-md);
  border: 1px solid rgba(230, 30, 45, 0.3);
  background: rgba(230, 30, 45, 0.08);
  color: var(--color-accent-bright);
}

.feature__icon svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.7; }

.feature__title { margin-bottom: var(--space-3); }

.feature__text { font-size: 0.95rem; }

/* ---------- Game card ---------- */
.game-card {
  display: block;
  position: relative;
}

.game-card__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: var(--color-bg-alt);
}

.game-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--dur-slow) var(--ease-out);
}

.game-card:hover .game-card__media img { transform: scale(1.04); }

.game-card__body {
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.game-card__title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.game-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.game-card__rtp { color: var(--color-gold); font-family: var(--font-mono); font-weight: 700; }

.game-card__tag {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  z-index: 1;
  padding: 4px 10px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: var(--radius-pill);
  background: rgba(10, 10, 12, 0.8);
  backdrop-filter: blur(6px);
  color: var(--color-text-secondary);
  border: 1px solid var(--color-border);
}

.game-card__tag--hot {
  color: var(--color-accent-bright);
  border-color: rgba(230, 30, 45, 0.5);
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
}

@media (min-width: 640px) { .games-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 992px) { .games-grid { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 1200px) { .games-grid { grid-template-columns: repeat(5, 1fr); } }

/* ---------- Screenshot gallery ---------- */
.shots {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(230px, 1fr);
  gap: var(--space-5);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: var(--space-4);
  scrollbar-width: thin;
  scrollbar-color: var(--color-border) transparent;
}

.shots::-webkit-scrollbar { height: 6px; }
.shots::-webkit-scrollbar-thumb { background: var(--color-border); border-radius: var(--radius-pill); }

.shot { scroll-snap-align: start; }

.shot__frame {
  padding: 8px;
  background: linear-gradient(160deg, #26262C, #121215);
  border: 1px solid var(--color-border);
  border-radius: 26px;
  box-shadow: var(--shadow-card);
  transition: border-color var(--dur-med) var(--ease-out), box-shadow var(--dur-med) var(--ease-out);
}

.shot:hover .shot__frame {
  border-color: var(--color-border-glow);
  box-shadow: var(--shadow-card-hover);
}

/* Source screenshots are 1080x2412 — match it exactly so nothing is cropped */
.shot__frame img {
  width: 100%;
  border-radius: 20px;
  aspect-ratio: 1080 / 2412;
  object-fit: contain;
  background: var(--color-bg);
}

.shot__cap {
  margin-top: var(--space-4);
  font-size: var(--fs-small);
  color: var(--color-text-secondary);
}

.shot__cap strong { display: block; color: var(--color-text-primary); margin-bottom: 2px; }

/* ---------- Bonus / inverted CTA panel ---------- */
.bonus {
  position: relative;
  padding: var(--space-12) var(--space-6);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(230, 30, 45, 0.35);
  background:
    radial-gradient(circle at 15% 0%, rgba(230, 30, 45, 0.22), transparent 55%),
    var(--color-accent-dim);
  text-align: center;
  overflow: hidden;
}

.bonus__amount {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(2.5rem, 7vw, 4.2rem);
  font-weight: 700;
  color: var(--color-gold);
  line-height: 1;
  margin-block: var(--space-4);
  text-shadow: var(--shadow-glow-gold);
}

.bonus p {
  max-width: 62ch;
  margin-inline: auto;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: var(--space-8);
}

.bonus .btn-row { justify-content: center; }

@media (min-width: 768px) {
  .bonus { padding: var(--space-16) var(--space-12); }
}

/* ---------- Steps (How it works) ---------- */
.steps {
  display: grid;
  gap: var(--space-6);
  counter-reset: step;
}

.step {
  position: relative;
  padding: var(--space-8) var(--space-6);
}

.step__num {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: var(--space-5);
  border-radius: 50%;
  border: 2px solid var(--color-accent);
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--color-accent-bright);
  background: rgba(230, 30, 45, 0.08);
}

.step__title { margin-bottom: var(--space-3); }
.step__text { font-size: 0.95rem; }

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

/* ---------- Prose (long-form content, legal pages, guides) ---------- */
.prose { max-width: 78ch; }

.prose > * + * { margin-top: var(--space-5); }

.prose h2 {
  margin-top: var(--space-12);
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-border);
  font-size: var(--fs-h3);
}

.prose h3 {
  margin-top: var(--space-8);
  font-size: var(--fs-h4);
  color: var(--color-text-primary);
}

.prose h4 { margin-top: var(--space-6); color: var(--color-accent-bright); font-size: 1rem; }

.prose p { line-height: var(--lh-body); }

.prose a {
  color: var(--color-accent-bright);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(255, 59, 74, 0.4);
  transition: text-decoration-color var(--dur-fast) var(--ease-out);
}

.prose a:hover { text-decoration-color: var(--color-accent-bright); }

.prose ul, .prose ol {
  display: grid;
  gap: var(--space-3);
  padding-left: 0;
}

.prose li {
  position: relative;
  padding-left: var(--space-8);
  color: var(--color-text-secondary);
}

.prose ul > li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid var(--color-accent);
}

.prose ol { counter-reset: li; }

.prose ol > li::before {
  counter-increment: li;
  content: counter(li);
  position: absolute;
  left: 0;
  top: 0.1em;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(230, 30, 45, 0.12);
  border: 1px solid rgba(230, 30, 45, 0.35);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--color-accent-bright);
}

.prose blockquote {
  padding: var(--space-5) var(--space-6);
  border-left: 3px solid var(--color-accent);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--color-surface);
  color: var(--color-text-secondary);
}

.prose code {
  padding: 2px 6px;
  font-family: var(--font-mono);
  font-size: 0.85em;
  border-radius: var(--radius-sm);
  background: var(--color-surface-raised);
  color: var(--color-gold);
}

/* Table of contents */
.toc {
  padding: var(--space-6);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
}

.toc__title {
  font-family: var(--font-display);
  font-size: var(--fs-small);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.toc ol {
  display: grid;
  gap: var(--space-2);
  counter-reset: toc;
}

.toc li { padding-left: 0; }
.toc li::before { display: none; }

.toc a {
  display: block;
  padding: var(--space-1) 0;
  font-size: var(--fs-small);
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out), padding-left var(--dur-fast) var(--ease-out);
}

.toc a:hover { color: var(--color-accent-bright); padding-left: var(--space-2); }

/* ---------- Data table ---------- */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-small);
  min-width: 480px;
}

th, td {
  padding: var(--space-4) var(--space-5);
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

th {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--fs-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  background: var(--color-surface);
}

td { color: var(--color-text-secondary); }
td strong { color: var(--color-text-primary); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr { transition: background var(--dur-fast) var(--ease-out); }
tbody tr:hover { background: var(--color-surface); }

/* ---------- FAQ accordion ---------- */
.faq { display: grid; gap: var(--space-3); }

.faq__item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  overflow: hidden;
  transition: border-color var(--dur-med) var(--ease-out);
}

.faq__item:hover { border-color: var(--color-border-glow); }

.faq__q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  width: 100%;
  padding: var(--space-5) var(--space-6);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  text-align: left;
  color: var(--color-text-primary);
}

.faq__icon {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  position: relative;
  color: var(--color-accent-bright);
}

.faq__icon::before,
.faq__icon::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  background: currentColor;
  transform: translate(-50%, -50%);
  transition: transform var(--dur-med) var(--ease-out);
}

.faq__icon::before { width: 12px; height: 2px; }
.faq__icon::after  { width: 2px; height: 12px; }

.faq__q[aria-expanded='true'] .faq__icon::after { transform: translate(-50%, -50%) rotate(90deg); }

.faq__a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows var(--dur-slow) var(--ease-out);
}

.faq__item.is-open .faq__a { grid-template-rows: 1fr; }

.faq__a > div { overflow: hidden; }

.faq__a p {
  padding: 0 var(--space-6) var(--space-6);
  font-size: 0.95rem;
  color: var(--color-text-secondary);
}

.faq__a p + p { padding-top: 0; }

/* ---------- Forms (contact) ---------- */
.form { display: grid; gap: var(--space-5); }

.form__row { display: grid; gap: var(--space-5); }

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

.field { display: grid; gap: var(--space-2); }

.field__label {
  font-family: var(--font-display);
  font-size: var(--fs-small);
  font-weight: 600;
  color: var(--color-text-primary);
}

.field__label .req { color: var(--color-accent-bright); }

.field__hint {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.field__control {
  width: 100%;
  padding: 13px var(--space-4);
  font-size: 0.95rem;
  color: var(--color-text-primary);
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color var(--dur-fast) var(--ease-out),
              box-shadow var(--dur-fast) var(--ease-out);
}

.field__control::placeholder { color: var(--color-text-muted); }

.field__control:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(230, 30, 45, 0.15);
}

textarea.field__control { min-height: 160px; resize: vertical; line-height: 1.65; }

select.field__control {
  appearance: none;
  -webkit-appearance: none;
  padding-right: var(--space-10);
  background-image: linear-gradient(45deg, transparent 50%, var(--color-text-muted) 50%),
                    linear-gradient(135deg, var(--color-text-muted) 50%, transparent 50%);
  background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

select.field__control option { background: var(--color-bg-alt); color: var(--color-text-primary); }

.field__control[aria-invalid='true'] { border-color: var(--color-danger); }

.field__error {
  display: none;
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--color-accent-bright);
}

.field__error.is-shown { display: block; }

/* Inline result panel — never claims a message was delivered */
.form__result {
  display: none;
  padding: var(--space-5) var(--space-6);
  border: 1px solid rgba(38, 165, 228, 0.45);
  border-radius: var(--radius-md);
  background: rgba(38, 165, 228, 0.08);
  font-size: var(--fs-small);
  color: var(--color-text-secondary);
}

.form__result.is-shown { display: grid; gap: var(--space-4); }

.form__result strong { display: block; color: var(--color-text-primary); }

/* ---------- Footer ---------- */
.footer {
  padding-top: var(--space-16);
  background: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
}

.footer__top {
  display: grid;
  gap: var(--space-10);
  padding-bottom: var(--space-12);
}

.footer__brand-text {
  margin-top: var(--space-4);
  font-size: var(--fs-small);
  max-width: 40ch;
}

.footer__cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-8);
}

.footer__title {
  font-family: var(--font-display);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}

.footer__list { display: grid; gap: var(--space-3); }

.footer__list a {
  font-size: var(--fs-small);
  color: var(--color-text-secondary);
  transition: color var(--dur-fast) var(--ease-out), padding-left var(--dur-fast) var(--ease-out);
}

.footer__list a:hover { color: var(--color-accent-bright); padding-left: var(--space-1); }

/* Compliance blocks — always visible, never collapsed */
.compliance {
  display: grid;
  gap: var(--space-4);
  padding: var(--space-6);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  margin-bottom: var(--space-8);
}

.compliance__block {
  display: flex;
  gap: var(--space-4);
  align-items: flex-start;
}

.compliance__mark {
  flex: 0 0 auto;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(230, 30, 45, 0.4);
  font-family: var(--font-display);
  font-size: var(--fs-xs);
  font-weight: 800;
  color: var(--color-accent-bright);
  white-space: nowrap;
}

.compliance__text {
  font-size: var(--fs-small);
  color: var(--color-text-secondary);
  line-height: 1.65;
}

.compliance__text a { color: var(--color-text-primary); text-decoration: underline; text-underline-offset: 2px; }
.compliance__text a:hover { color: var(--color-accent-bright); }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  align-items: center;
  justify-content: space-between;
  padding-block: var(--space-6);
  border-top: 1px solid var(--color-border);
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.footer__marks { display: flex; gap: var(--space-3); flex-wrap: wrap; }

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

@media (min-width: 992px) {
  .footer__top { grid-template-columns: 1fr 1.6fr; gap: var(--space-16); }
}

/* ---------- Page header (inner pages) ---------- */
.page-head {
  position: relative;
  padding-block: var(--space-16) var(--space-12);
  border-bottom: 1px solid var(--color-border);
  overflow: hidden;
}

.page-head::before {
  content: '';
  position: absolute;
  top: -140px;
  left: 50%;
  transform: translateX(-50%);
  width: 700px;
  height: 340px;
  background: radial-gradient(ellipse, rgba(230, 30, 45, 0.16), transparent 65%);
  pointer-events: none;
}

.page-head__inner { position: relative; }
.page-head__title { margin-bottom: var(--space-4); }
.page-head__text { max-width: 68ch; font-size: 1.04rem; }

/* Breadcrumbs */
.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

.crumbs a { color: var(--color-text-secondary); }
.crumbs a:hover { color: var(--color-accent-bright); }
.crumbs li { display: flex; align-items: center; gap: var(--space-2); }
.crumbs li + li::before { content: '/'; color: var(--color-text-muted); }

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out);
}

.reveal.is-visible { opacity: 1; transform: none; }

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

.skip-link {
  position: absolute;
  top: -100px;
  left: var(--space-4);
  z-index: var(--z-toast);
  padding: var(--space-3) var(--space-5);
  background: var(--color-accent);
  color: #fff;
  border-radius: var(--radius-sm);
  transition: top var(--dur-fast) var(--ease-out);
}

.skip-link:focus { top: var(--space-4); }

.mt-0 { margin-top: 0; }
.center { text-align: center; }
.stack-6 { display: grid; gap: var(--space-6); }
.stack-8 { display: grid; gap: var(--space-8); }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .reveal { opacity: 1; transform: none; }
  .mockup { animation: none; }
}
