:root {
  --bg: #ffffff;
  --panel: #f4f5f7;
  --ink: #111316;
  --muted: #5b616b;
  --line: #e2e5ea;
  --accent: #d7262e;
  --mat: #1f7a6e;
  --radius: 18px;
  --max: 1120px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d0f12;
    --panel: #171a1f;
    --ink: #f2f3f5;
    --muted: #a3a9b3;
    --line: #262a31;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

header.top {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
header.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { font-weight: 800; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; font-size: 15px; }
.brand span { color: var(--accent); }
nav a { text-decoration: none; color: var(--muted); font-size: 15px; margin-left: 20px; }
nav a:hover { color: var(--ink); }
@media (max-width: 640px) { nav a.opt { display: none; } nav a { margin-left: 14px; } }

.hero { position: relative; color: #fff; }
.hero img { width: 100%; height: min(78vh, 720px); object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.05) 30%, rgba(0,0,0,.72)); }
.hero .text { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding-bottom: 56px; }
.hero h1 { font-size: clamp(40px, 7vw, 84px); line-height: 1; margin: 0 0 14px; letter-spacing: -.02em; text-transform: uppercase; font-weight: 900; }
.hero p { font-size: clamp(18px, 2.2vw, 22px); max-width: 640px; margin: 0 0 26px; }

.btn { display: inline-block; background: var(--accent); color: #fff; text-decoration: none; font-weight: 700;
  padding: 14px 26px; border-radius: 999px; letter-spacing: .03em; }
.btn.ghost { background: transparent; border: 2px solid currentColor; margin-left: 10px; }
.btn:hover { filter: brightness(1.08); }

section { padding: 84px 0; }
section.alt { background: var(--panel); }
.kicker { color: var(--accent); font-weight: 800; letter-spacing: .14em; text-transform: uppercase; font-size: 13px; margin: 0 0 10px; }
h2 { font-size: clamp(30px, 4vw, 46px); line-height: 1.1; margin: 0 0 18px; letter-spacing: -.01em; }
.lead { font-size: 20px; color: var(--muted); max-width: 720px; margin: 0; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.split img { border-radius: var(--radius); box-shadow: 0 20px 50px rgba(0,0,0,.14); }
.split.flip > :first-child { order: 2; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; gap: 28px; } .split.flip > :first-child { order: 0; } }

.points { list-style: none; padding: 0; margin: 22px 0 0; }
.points li { padding: 10px 0 10px 30px; position: relative; border-top: 1px solid var(--line); }
.points li::before { content: ""; position: absolute; left: 4px; top: 19px; width: 10px; height: 10px; border-radius: 3px; background: var(--accent); }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 36px; }
@media (max-width: 860px) { .grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .grid { grid-template-columns: 1fr; } }
.card { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
section.alt .card { background: var(--bg); }
.card h3 { margin: 0 0 6px; font-size: 18px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }

.wide img { border-radius: var(--radius); margin-top: 36px; }

.cta { text-align: center; }
.cta .lead { margin: 0 auto 28px; }

footer { border-top: 1px solid var(--line); padding: 34px 0 48px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px; }
footer a { margin-right: 18px; text-decoration: none; }
footer a:hover { color: var(--ink); }

/* Text pages */
main.doc { max-width: 780px; margin: 0 auto; padding: 56px 20px 80px; }
main.doc h1 { font-size: clamp(32px, 5vw, 44px); line-height: 1.1; margin: 0 0 6px; }
main.doc .updated { color: var(--muted); margin: 0 0 32px; }
main.doc h2 { font-size: 24px; margin: 44px 0 10px; }
main.doc h3 { font-size: 18px; margin: 26px 0 6px; }
.box { background: var(--panel); border-radius: var(--radius); padding: 6px 24px; }
.table { width: 100%; overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
th { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }

form.stack { display: grid; gap: 16px; margin-top: 24px; }
form.stack label { display: grid; gap: 6px; font-weight: 600; font-size: 15px; }
form.stack input, form.stack textarea, form.stack select {
  font: inherit; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); color: var(--ink);
}
form.stack textarea { min-height: 140px; resize: vertical; }
form.stack button { justify-self: start; border: 0; cursor: pointer; font: inherit; }
.hidden { position: absolute; left: -9999px; }
