/* Red September — styles */
:root {
  --bg: #0b0d10;
  --bg-alt: #111418;
  --surface: #161a20;
  --line: #262c35;
  --text: #e8eaed;
  --muted: #9aa3ae;
  --red: #e03131;
  --red-hover: #f03e3e;
  --radius: 12px;
  --wrap: 1120px;
  --font-head: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1.0625rem/1.65 var(--font-body);
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-head); line-height: 1.12; letter-spacing: -0.02em; margin: 0 0 0.6em; }
h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 700; max-width: 16ch; }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.75rem); font-weight: 700; }
h3 { font-size: 1.25rem; font-weight: 600; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.accent { color: var(--red); }
.eyebrow {
  font: 500 0.8rem/1 var(--font-mono);
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--red); margin-bottom: 1.25rem;
}
.lede { font-size: 1.2rem; color: var(--muted); max-width: 60ch; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--red); color: #fff; padding: 8px 12px; border-radius: 6px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; border-radius: 4px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.85rem 1.4rem; border-radius: 8px;
  background: var(--red); color: #fff; text-decoration: none;
  font: 600 0.98rem/1 var(--font-body);
  border: 1px solid var(--red);
  transition: background .15s, border-color .15s, transform .15s;
}
.btn:hover { background: var(--red-hover); border-color: var(--red-hover); transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn--ghost:hover { background: var(--surface); border-color: var(--muted); }
.btn--small { padding: 0.55rem 1rem; font-size: 0.9rem; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 13, 16, 0.82);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 700 1.1rem var(--font-head); letter-spacing: -0.01em; }
.brand__logo { display: block; height: 26px; width: auto; }
.nav__links { display: flex; align-items: center; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav__links a:not(.btn) { text-decoration: none; color: var(--muted); font-size: 0.95rem; }
.nav__links a:not(.btn):hover { color: var(--text); }

/* Hero */
.hero { position: relative; overflow: hidden; padding: clamp(80px, 14vw, 160px) 0 clamp(64px, 10vw, 120px); }
.hero .wrap { position: relative; z-index: 1; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 2rem; }
.hero__grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 70% 60% at 80% 30%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 80% 30%, #000 20%, transparent 75%);
  opacity: 0.55;
}
.hero::after {
  content: ""; position: absolute; width: 520px; height: 520px; right: -120px; top: -80px;
  background: radial-gradient(circle, rgba(224, 49, 49, 0.22), transparent 65%);
  pointer-events: none;
}

/* Strip */
.strip { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--bg-alt); }
.strip__inner { display: grid; grid-template-columns: repeat(4, 1fr); }
.strip__inner > div { padding: 28px 20px; display: flex; flex-direction: column; gap: 4px; border-left: 1px solid var(--line); }
.strip__inner > div:first-child { border-left: 0; padding-left: 0; }
.strip__k { font: 700 1.6rem var(--font-head); }
.strip__v { color: var(--muted); font-size: 0.95rem; }

/* Sections */
.section { padding: clamp(72px, 10vw, 120px) 0; }
.section--alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 2.5rem; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 32px 28px; transition: border-color .2s, transform .2s;
}
.card:hover { border-color: rgba(224, 49, 49, 0.55); transform: translateY(-3px); }
.card__num { display: block; font: 500 0.85rem var(--font-mono); color: var(--red); margin-bottom: 1.25rem; }
.card p { color: var(--muted); }
.card ul { list-style: none; padding: 0; margin: 1.25rem 0 0; border-top: 1px solid var(--line); }
.card li { padding: 10px 0 10px 20px; border-bottom: 1px solid var(--line); font-size: 0.95rem; position: relative; }
.card li:last-child { border-bottom: 0; }
.card li::before { content: ""; position: absolute; left: 0; top: 19px; width: 8px; height: 2px; background: var(--red); }

/* Point of view + diagram */
.pov { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
.pov__text p:not(.eyebrow) { color: var(--muted); }
.diagram { margin: 0; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.diagram svg { width: 100%; height: auto; color: var(--muted); }
.diagram figcaption { margin-top: 12px; font: 400 0.85rem var(--font-mono); color: var(--muted); text-align: center; }
.d-src rect { fill: var(--surface); stroke: var(--line); stroke-width: 1.5; }
.d-src text { fill: var(--text); }
.d-core rect { fill: rgba(224, 49, 49, 0.12); stroke: var(--red); stroke-width: 2; }
.d-core text { fill: var(--text); }
.d-core .d-muted { fill: var(--muted); }

/* Steps */
.steps { list-style: none; padding: 0; margin: 72px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: s; }
.steps li { border-top: 2px solid var(--line); padding-top: 20px; position: relative; }
.steps li::before { content: ""; position: absolute; top: -2px; left: 0; width: 40px; height: 2px; background: var(--red); }
.steps__n { font: 500 0.85rem var(--font-mono); color: var(--red); }
.steps h3 { margin-top: 8px; }
.steps p { color: var(--muted); font-size: 0.97rem; }

/* Benefits */
.benefits { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 2.5rem; }
.benefit {
  background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--red);
  border-radius: var(--radius); padding: 28px 28px 24px;
}
.benefit__tag { display: block; font: 500 0.8rem var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--red); margin-bottom: 0.9rem; }
.benefit p { color: var(--muted); margin: 0; }

/* About */
.about { display: grid; grid-template-columns: 1fr 1.6fr; gap: 56px; }
.about__body p { color: var(--muted); }
.about__body strong { color: var(--text); font-weight: 600; }
.tags { list-style: none; padding: 0; margin: 1.75rem 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { font: 400 0.82rem var(--font-mono); padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--text); background: var(--surface); }

/* Contact */
.contact { background: linear-gradient(180deg, var(--bg) 0%, #1a0d0e 100%); border-top: 1px solid var(--line); }
.contact__inner { display: grid; grid-template-columns: 1.4fr 1fr; gap: 48px; align-items: end; }
.contact__links { display: flex; flex-direction: column; gap: 12px; }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 28px 0; font-size: 0.85rem; color: var(--muted); }
.footer__inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px 24px; }
.footer__brand { display: flex; align-items: center; gap: 12px; }
.footer__mark { height: 14px; width: auto; display: block; }
.footer p { margin: 0; }

/* Responsive */
@media (max-width: 900px) {
  .cards, .steps { grid-template-columns: 1fr 1fr; }
  .strip__inner { grid-template-columns: 1fr 1fr; }
  .strip__inner > div:nth-child(odd) { border-left: 0; padding-left: 0; }
  .strip__inner > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .pov, .about, .contact__inner { grid-template-columns: 1fr; gap: 36px; }
}
@media (max-width: 640px) {
  .benefits { grid-template-columns: 1fr; }
  .wrap { padding: 0 16px; }
  .nav__links li:not(:last-child) { display: none; }
  .brand__logo { height: 22px; }
  .cards, .steps { grid-template-columns: 1fr; }
  .strip__inner { grid-template-columns: 1fr; }
  .strip__inner > div { padding: 18px 0; border-left: 0; }
  .strip__inner > div + div { border-top: 1px solid var(--line); }
  .diagram { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
