/* WARP Generator — guide site stylesheet
   Dark theme to match the generator's own branding (#ff7a18 → #ff3d57). */

:root {
  --bg: #0b0b0e;
  --bg-soft: #101014;
  --card: #16161b;
  --card-2: #1b1b21;
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(255, 255, 255, 0.16);
  --fg: #ececf1;
  --fg-dim: #c3c3cd;
  --muted: #9a9aa8;
  --accent: #ff7a18;
  --accent-2: #ff3d57;
  --accent-soft: rgba(255, 122, 24, 0.12);
  --ok: #4ade80;
  --radius: 16px;
  --max: 1080px;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial,
    "Helvetica Neue", sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* Subtle top glow */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto 0;
  height: 420px;
  background: radial-gradient(
    60% 100% at 50% 0%,
    rgba(255, 122, 24, 0.14),
    rgba(255, 61, 87, 0.05) 45%,
    transparent 70%
  );
  pointer-events: none;
  z-index: 0;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

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

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 1;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(11, 11, 14, 0.82);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 18px;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--fg);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand:hover { text-decoration: none; }
.brand svg { flex: none; }

.nav {
  display: flex;
  gap: 22px;
  margin-left: 12px;
  font-size: 15px;
}
.nav a { color: var(--fg-dim); }
.nav a:hover { color: var(--fg); text-decoration: none; }

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

.lang-switch {
  display: inline-flex;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  overflow: hidden;
  font-size: 13px;
  font-weight: 600;
}
.lang-switch a,
.lang-switch span {
  padding: 5px 11px;
  color: var(--muted);
}
.lang-switch a:hover { background: var(--card-2); color: var(--fg); text-decoration: none; }
.lang-switch .is-active { background: var(--card-2); color: var(--fg); cursor: default; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 10px;
  font-weight: 650;
  font-size: 15px;
  line-height: 1.2;
  border: 1px solid transparent;
  transition: transform 0.12s ease, filter 0.12s ease, background 0.12s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: linear-gradient(105deg, #ff7a18 0%, #ff3d57 100%);
  color: #fff;
  box-shadow: 0 6px 22px rgba(255, 90, 40, 0.28);
}
.btn-primary:hover { filter: brightness(1.07); }

.btn-ghost {
  background: transparent;
  color: var(--fg);
  border-color: var(--line-strong);
}
.btn-ghost:hover { background: var(--card-2); }

.btn-sm { padding: 8px 15px; font-size: 14px; }

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

.hero {
  padding: 68px 0 44px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

h1 {
  font-size: clamp(30px, 4.6vw, 50px);
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin: 20px 0 16px;
  font-weight: 800;
}

.lead {
  font-size: clamp(17px, 2vw, 19px);
  color: var(--fg-dim);
  max-width: 720px;
  margin: 0 0 26px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 30px;
}

.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.facts li {
  padding: 8px 14px;
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 10px;
  font-size: 14px;
  color: var(--fg-dim);
}
.facts b { color: var(--fg); }

/* ---------- Sections ---------- */

.section {
  padding: 46px 0;
  border-top: 1px solid var(--line);
}

h2 {
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  font-weight: 750;
}

h3 {
  font-size: 18px;
  margin: 30px 0 10px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.section-intro {
  color: var(--muted);
  max-width: 760px;
  margin: 0 0 26px;
}

p { margin: 0 0 14px; }
ul, ol { margin: 0 0 16px; padding-left: 22px; }
li { margin-bottom: 7px; }
li:last-child { margin-bottom: 0; }

strong { color: #fff; font-weight: 650; }

code {
  font-family: var(--mono);
  font-size: 0.9em;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1px 6px;
  color: #ffd8b8;
}

/* ---------- Steps ---------- */

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 14px;
}

.steps > li {
  counter-increment: step;
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px 22px 76px;
  margin: 0;
}

.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 22px;
  top: 20px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 16px;
  color: #fff;
  background: linear-gradient(135deg, #ff7a18, #ff3d57);
}

.steps h3 { margin: 0 0 6px; font-size: 17px; }
.steps p { margin: 0; color: var(--fg-dim); font-size: 15.5px; }
.steps p + p { margin-top: 8px; }

/* ---------- Tables ---------- */

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  min-width: 560px;
}

thead th {
  text-align: left;
  font-size: 12.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
  white-space: nowrap;
}

tbody td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  color: var(--fg-dim);
  vertical-align: top;
}
tbody tr:last-child td { border-bottom: 0; }
tbody td:first-child { color: var(--fg); font-weight: 600; white-space: nowrap; }

.table-note {
  margin: 10px 2px 0;
}

.tag {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 650;
  border: 1px solid var(--line-strong);
  color: var(--fg-dim);
  background: rgba(255, 255, 255, 0.04);
  white-space: nowrap;
}
.tag-hot {
  border-color: rgba(255, 122, 24, 0.45);
  color: var(--accent);
  background: var(--accent-soft);
}

/* ---------- Cards / callouts ---------- */

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px;
}

.card h3 { margin-top: 0; }

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.callout {
  display: flex;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 14px;
  border: 1px solid rgba(255, 122, 24, 0.35);
  background: linear-gradient(
    180deg,
    rgba(255, 122, 24, 0.1),
    rgba(255, 61, 87, 0.04)
  );
  margin: 22px 0;
}
.callout-icon { flex: none; font-size: 20px; line-height: 1.4; }
.callout p { margin: 0; font-size: 15.5px; color: var(--fg-dim); }
.callout p + p { margin-top: 8px; }
.callout strong { color: #ffcda6; }

.callout.neutral {
  border-color: var(--line-strong);
  background: var(--card);
}

/* ---------- Accordion (details) ---------- */

.faq {
  display: grid;
  gap: 10px;
}

details {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 20px;
  transition: border-color 0.15s ease;
}
details[open] { border-color: var(--line-strong); }

summary {
  cursor: pointer;
  padding: 17px 34px 17px 0;
  font-weight: 650;
  font-size: 16.5px;
  list-style: none;
  position: relative;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: "+";
  position: absolute;
  right: 2px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 22px;
  font-weight: 400;
  color: var(--accent);
  line-height: 1;
}
details[open] summary::after { content: "–"; }

.details-body {
  padding: 0 0 18px;
  color: var(--fg-dim);
  font-size: 15.5px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}
.details-body p:last-child { margin-bottom: 0; }
.details-body ul { margin-bottom: 0; }

/* ---------- CTA block ---------- */

.cta {
  margin: 52px 0 8px;
  padding: 40px 32px;
  border-radius: 20px;
  border: 1px solid rgba(255, 122, 24, 0.35);
  background:
    radial-gradient(90% 130% at 12% 0%, rgba(255, 122, 24, 0.2), transparent 60%),
    radial-gradient(90% 130% at 92% 100%, rgba(255, 61, 87, 0.16), transparent 60%),
    var(--card);
  text-align: center;
}
.cta h2 { margin-bottom: 10px; }
.cta p { color: var(--fg-dim); max-width: 560px; margin: 0 auto 22px; }

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

.site-footer {
  border-top: 1px solid var(--line);
  padding: 34px 0 46px;
  color: var(--muted);
  font-size: 14px;
}
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 26px 44px;
  justify-content: space-between;
  margin-bottom: 24px;
}
.footer-col h4 {
  font-size: 12.5px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--fg-dim);
  margin: 0 0 10px;
  font-weight: 700;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 6px; }
.footer-col a { color: var(--muted); }
.footer-col a:hover { color: var(--fg); }

.footer-note {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  font-size: 13px;
  line-height: 1.6;
  max-width: 820px;
}

/* ---------- Utilities ---------- */

.muted { color: var(--muted); }
.small { font-size: 14px; }
.mt-0 { margin-top: 0; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; }
.mx-auto { margin-inline: auto; }
.center-actions { justify-content: center; }
.nowrap { white-space: nowrap; }

.error-shell {
  min-height: 78vh;
  display: grid;
  place-items: center;
  text-align: center;
}
.error-inner { max-width: 620px; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--card-2);
  color: var(--fg);
  padding: 10px 16px;
  border-radius: 0 0 8px 0;
  z-index: 100;
}
.skip-link:focus { left: 0; }

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

@media (max-width: 900px) {
  .nav { display: none; }
  .hero { padding: 48px 0 34px; }
  .grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .header-inner { height: 58px; gap: 10px; }
  .brand span { display: none; }

  /* Tables become stacked rows instead of a horizontal scroller */
  .table-scroll { overflow: visible; }
  table { min-width: 0; }
  table, tbody, tr, td { display: block; }
  thead { display: none; }
  tbody tr { padding: 4px 0 14px; border-bottom: 1px solid var(--line); }
  tbody tr:last-child { border-bottom: 0; }
  tbody td { border: 0; padding: 2px 18px; }
  tbody td:first-child {
    padding-top: 15px;
    padding-bottom: 4px;
    font-size: 16px;
    color: #fff;
    white-space: normal;
  }

  .steps > li { padding: 20px 18px 20px 18px; }
  .steps > li::before {
    position: static;
    display: inline-grid;
    margin-bottom: 10px;
    width: 30px;
    height: 30px;
    font-size: 14px;
  }
  .cta { padding: 30px 20px; }
  .btn { width: 100%; }
  .hero-actions { gap: 10px; }
  .header-actions .btn { width: auto; }
}

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