:root {
  --paper: #ffffff;
  --paper-2: #ffe4e4;
  --raised: #ffffff;
  --ink: #191a1d;
  --ink-2: #42454b;
  --muted: #62666f;
  --line: #e8e8eb;
  --line-strong: #d9dade;
  --pine: #ac0203;
  --pine-deep: #850102;
  --moss: #ac0203;
  --stamp: #ac0203;
  --copper: #ac0203;
  --good: #16834c;
  --good-bg: #e8f7ee;
  --mid: #8a5a10;
  --mid-bg: #f8efd6;
  --low: #ac0203;
  --low-bg: #fff0f0;
  --shadow: 0 20px 60px rgba(23, 23, 26, 0.08);
  --serif: "Manrope", "Segoe UI", sans-serif;
  --sans: "DM Sans", "Segoe UI", sans-serif;
  --max: 1160px;
  --header: 78px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 82% 8%, rgba(172, 2, 3, 0.08), transparent 28%),
    linear-gradient(180deg, #fff 0%, #fbfbfc 100%);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.55;
}
img, svg { max-width: 100%; }
a { color: var(--pine); }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 800; letter-spacing: -0.04em; line-height: 1.12; margin: 0; }
p { margin: 0; }
.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: var(--ink);
  color: white;
  padding: 8px 12px;
  z-index: 80;
}
.skip:focus { top: 12px; }

.wrap { width: min(var(--max), calc(100% - 40px)); margin-inline: auto; }
.wrap-wide { width: min(1200px, calc(100% - 40px)); margin-inline: auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: var(--header);
  padding: 10px 22px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
}
.site-header.is-stuck { border-bottom-color: var(--line); }
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  margin-right: auto;
}
.brand-mark {
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: 12px;
}
.brand strong, .brand em { font-family: var(--serif); font-size: 1.2rem; font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.brand strong { display: inline; }
.brand em { display: inline; margin-left: 0.28em; font-style: normal; color: var(--pine); text-transform: none; letter-spacing: -0.04em; }

.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav a {
  text-decoration: none;
  color: var(--ink-2);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 8px 10px;
  border-radius: 999px;
}
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--pine); background: #fff1f1; }
.nav-signin { display: none; }
.header-actions { display: flex; align-items: center; gap: 8px; }
.nav-toggle {
  display: none;
  border: 1px solid var(--line-strong);
  background: var(--raised);
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 700;
  cursor: pointer;
  background: transparent;
  border-radius: 10px;
}
.btn-primary { background: var(--pine); color: #f6f3ec; }
.btn-primary:hover { background: var(--pine-deep); }
.btn-ghost { border-color: var(--line-strong); color: var(--ink); background: transparent; }
.btn-ghost:hover { background: #f6f6f7; }
.btn-stamp { background: var(--stamp); color: #fffaf7; }
.btn-stamp:hover { background: #7e2e24; }
.btn-small { min-height: 38px; padding: 7px 12px; font-size: 0.95rem; }
.linkish { color: var(--pine); font-weight: 650; text-underline-offset: 3px; }

.kicker {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--copper);
  margin-bottom: 12px;
}
.lede { font-size: 1.18rem; color: var(--ink-2); max-width: 42rem; }
.muted { color: var(--muted); }
.fine { font-size: 0.92rem; color: var(--muted); }

.hero { padding: 54px 0 28px; }
.hero-grid, .split, .two, .three, .four, .plans, .deploy-grid {
  display: grid;
  gap: 22px;
}
.hero-grid { grid-template-columns: 1.05fr 0.95fr; align-items: center; gap: 42px; }
h1 { font-size: clamp(3rem, 6vw, 5.1rem); color: var(--pine-deep); }
h1 em { font-style: normal; font-weight: 800; color: var(--pine); }
h2 { font-size: clamp(2rem, 3.4vw, 2.8rem); color: var(--pine-deep); }
h3 { font-size: 1.45rem; }
.hero-actions, .cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.hero-note { margin-top: 18px; }

.metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 28px; }
.metric {
  padding: 14px 14px 12px;
  border-top: 2px solid var(--pine);
}
.metric b { display: block; font-family: var(--serif); font-size: 1.7rem; letter-spacing: -0.03em; color: var(--pine-deep); }
.metric span { color: var(--ink-2); font-size: 0.95rem; }

.sheet {
  background: var(--raised);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
  padding: 18px;
  position: relative;
}
.sheet::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  border-top: 28px solid var(--paper-2);
  border-left: 28px solid transparent;
  border-top-right-radius: 22px;
}
.sheet-top { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; margin-bottom: 12px; }
.sheet-top h3 { font-size: 1.55rem; }
.sheet-top p { color: var(--muted); margin-top: 4px; }
.stamp {
  flex: none;
  border: 2px solid var(--stamp);
  color: var(--stamp);
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.72rem;
  padding: 6px 8px;
  transform: rotate(8deg);
  border-radius: 4px;
}
.checkline { display: flex; gap: 8px; align-items: center; font-size: 0.95rem; margin: 8px 0 12px; color: var(--ink-2); }
.field-list { display: grid; gap: 8px; }
.field {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas: "name badge" "input badge";
  gap: 2px 10px;
  align-items: center;
  padding: 8px 10px;
  border-radius: 12px;
  background: #fafafa;
  border: 1px solid #ededf0;
}
.field[data-level="mid"] { background: var(--mid-bg); }
.field[data-level="low"] { background: var(--low-bg); }
.field.is-hidden { display: none; }
.field span { grid-area: name; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
.field input {
  grid-area: input;
  border: 0;
  background: transparent;
  padding: 0;
  font-weight: 650;
  width: 100%;
}
.field input:focus { outline: 2px solid var(--pine); border-radius: 4px; }
.badge {
  grid-area: badge;
  font-style: normal;
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 4px 8px;
}
.badge.good { background: var(--good-bg); color: var(--good); }
.badge.mid { background: #fff; color: var(--mid); }
.badge.low { background: #fff; color: var(--low); }
.sheet-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 14px; }
.sheet-actions p { flex-basis: 100%; }

.section { padding: 64px 0; }
.section-head { max-width: 40rem; margin-bottom: 26px; }
.section-head p { margin-top: 12px; color: var(--ink-2); }
.three { grid-template-columns: repeat(3, 1fr); }
.four { grid-template-columns: repeat(4, 1fr); }
.two { grid-template-columns: 1.1fr 0.9fr; align-items: start; }
.card, .plan, .model, .step, .deploy {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
}
.card:hover { border-color: #f1c4c4; box-shadow: var(--shadow); }
.card h3, .plan h3, .model h3, .step h3, .deploy h3 { margin-bottom: 8px; }
.card p, .model p, .step p, .deploy p, .plan p { color: var(--ink-2); }
.card .index, .step .index {
  font-family: var(--serif);
  color: var(--stamp);
  font-size: 1.3rem;
}
.product-card { min-height: 210px; display: flex; flex-direction: column; }
.product-card a { margin-top: auto; padding-top: 14px; font-weight: 700; }

.pipeline { display: flex; gap: 8px; list-style: none; padding: 0; margin: 18px 0 0; flex-wrap: wrap; }
.pipeline li {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--raised);
  color: var(--ink);
  font-weight: 700;
  font-size: 0.92rem;
}
.pipeline li.is-current { background: var(--pine); color: #fff; border-color: var(--pine); }
.login-side .pipeline li.is-current { background: #fff; color: var(--pine); border-color: #fff; }

.band {
  background: #171719;
  color: #fff;
  padding: 64px 0;
}
.band h2, .band h3 { color: #fff; }
.band p { color: #d5d6db; }
.band .card, .band .deploy { background: rgba(255, 255, 255, 0.05); border-color: rgba(255, 255, 255, 0.12); color: #fff; }
.band .card p, .band .deploy p { color: #d5d6db; }
.band .kicker { color: #ffb3b3; }
.checks { margin: 14px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.checks li { padding-left: 18px; position: relative; }
.checks li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #ffb4b4; position: absolute; left: 0; top: 0.55em; }

.plans { grid-template-columns: repeat(4, 1fr); align-items: stretch; }
.plan { display: flex; flex-direction: column; gap: 8px; position: relative; }
.plan.is-rec { border-color: var(--pine); box-shadow: var(--shadow); background: white; }
.plan .price { font-family: var(--serif); font-size: 2rem; color: var(--pine-deep); letter-spacing: -0.03em; }
.plan ul { margin: 8px 0 16px; padding-left: 18px; color: var(--ink-2); flex: 1; }
.plan li + li { margin-top: 6px; }
.ribbon {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--pine);
  color: #f6f3ec;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 4px 8px;
}
.plan.is-hot { outline: 2px solid var(--stamp); }

.calc {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 18px;
  align-items: end;
  margin: 8px 0 22px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--raised);
}
.calc label { font-weight: 700; display: grid; gap: 6px; }
.calc input[type="number"], .form input, .form select, .form textarea {
  width: 100%;
  border: 1px solid var(--line-strong);
  background: white;
  border-radius: 12px;
  padding: 10px 12px;
  min-height: 44px;
}
.form textarea { min-height: 120px; resize: vertical; }
.calc output { font-family: var(--serif); font-size: 1.4rem; }

.timeline { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; list-style: none; padding: 0; margin: 0; }
.timeline li { padding: 16px; border-left: 3px solid var(--pine); background: #fff; }
.timeline b { display: block; color: var(--stamp); font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; }

table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 16px; background: var(--raised); }

.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.filters button[aria-pressed="true"] { background: var(--pine); color: #f6f3ec; border-color: var(--pine); }
.model-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.model .tag {
  display: inline-block;
  margin-bottom: 8px;
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--copper);
}
.model code { font-size: 0.82rem; color: var(--muted); }
.model.is-hidden { display: none; }
.model .linkish { display: inline-block; margin-top: 12px; }

.arch { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; gap: 10px; align-items: center; }
.arch .arrow { color: var(--copper); font-size: 1.4rem; text-align: center; }
.login-grid { min-height: calc(100vh - 180px); display: grid; grid-template-columns: 0.9fr 1.1fr; }
.login-side {
  background: var(--pine);
  color: #fff;
  padding: 48px 36px;
}
.login-side h1 { color: #fff; font-size: clamp(2.4rem, 4vw, 3.6rem); }
.login-side p { color: rgba(255, 255, 255, 0.86); margin-top: 14px; }
.login-side .kicker { color: #ffd0d0; }
.login-main { padding: 36px 22px 64px; }
.form { display: grid; gap: 12px; max-width: 460px; }
.form label { display: grid; gap: 6px; font-weight: 700; }
.notice {
  border-radius: 14px;
  padding: 12px 14px;
  background: var(--good-bg);
  color: var(--pine-deep);
}
.cta-panel {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  padding: 28px;
  border-radius: 22px;
  background: var(--raised);
  border: 1px solid var(--line);
}

.site-footer { padding: 48px 0 25px; border-top: 0; margin-top: 20px; background: #171719; color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 22px; }
.site-footer .brand { color: #fff; }
.site-footer .brand em { color: #ffb3b3; }
.site-footer a { color: #b9bac0; text-decoration: none; }
.site-footer a:hover { color: #fff; }
.site-footer .fine, .site-footer p { color: #b9bac0; }
.site-footer h3 { font-family: var(--sans); font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase; margin-bottom: 10px; color: #fff; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.legal { margin-top: 26px; padding-top: 14px; border-top: 1px solid #343438; color: #9b9ca3; font-size: 0.92rem; }
.legal a { color: #d5d6db; }

.status {
  display: inline-flex;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 0.8rem;
  font-weight: 750;
  background: var(--mid-bg);
  color: var(--mid);
}
.status.ok { background: var(--good-bg); color: var(--good); }
.status.paid { background: #e7eef8; color: #234a78; }

.page-hero { padding: 42px 0 10px; }
.page-hero h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
.stack { display: grid; gap: 14px; }
.quote-list { margin: 0; padding-left: 18px; color: var(--ink-2); }
.quote-list li + li { margin-top: 6px; }

@media (max-width: 1180px) {
  .nav-toggle { display: inline-flex; }
  .site-nav { display: none; }
  body.nav-open .nav-signin { display: block; }
  .header-actions { margin-left: auto; }
  body.nav-open .site-nav {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: 10px;
  }
}
@media (max-width: 980px) {
  .hero-grid, .two, .login-grid, .calc, .arch, .footer-grid { grid-template-columns: 1fr; }
  .three, .plans, .timeline, .model-grid { grid-template-columns: 1fr 1fr; }
  .four { grid-template-columns: 1fr 1fr; }
  .arch .arrow { transform: rotate(90deg); }
  .login-side { padding: 32px 22px; }
  .cta-panel { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 760px) {
  .header-actions .btn-ghost { display: none; }
  .three, .four, .plans, .timeline, .model-grid, .metrics { grid-template-columns: 1fr; }
  .wrap, .wrap-wide { width: min(var(--max), calc(100% - 28px)); }
  h1 { font-size: 2.7rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
