:root {
  --bg: #09090B;
  --surface: #121217;
  --surface-2: #18181F;
  --surface-3: #202029;
  --text: #F4F4F5;
  --muted: #A1A1AA;
  --line: rgba(244, 244, 245, 0.12);
  --blue: #4F8CFF;
  --green: #23D18B;
  --orange: #FFB86B;
  --pink: #F8A5B8;
  --radius: 8px;
  --shadow: 0 22px 80px rgba(0, 0, 0, 0.32);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Quicksand", system-ui, sans-serif;
  line-height: 1.65;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(180deg, #09090B 0%, #101016 52%, #09090B 100%);
  background-size: 44px 44px, 44px 44px, auto;
}

a {
  color: inherit;
  text-decoration: none;
}

code,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

pre {
  overflow: auto;
  margin: 0;
  white-space: pre-wrap;
}

iframe {
  display: block;
  max-width: 100%;
  border: 0;
}

.shell {
  width: min(calc(100% - 32px), 1180px);
  margin: 0 auto;
}

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

.header-shell {
  width: min(calc(100% - 32px), 1440px);
  min-height: 70px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.nav-links {
  display: flex;
  align-items: center;
}

.brand {
  gap: 12px;
  font-family: "Fredoka", system-ui, sans-serif;
  font-weight: 700;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  color: #06110D;
  background: linear-gradient(135deg, var(--green), var(--blue));
}

.nav-links {
  gap: 8px;
}

.nav-links a {
  padding: 9px 13px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
}

.nav-links a[aria-current="page"],
.nav-links a:hover {
  color: var(--text);
  border-color: rgba(79, 140, 255, 0.45);
  background: rgba(79, 140, 255, 0.12);
}

.hero {
  padding: 56px 0 36px;
}

.hero-grid,
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 0.86fr);
  gap: 28px;
  align-items: center;
}

.hero-stack {
  display: grid;
  gap: 30px;
}

.hero-copy-below {
  max-width: 1040px;
}

.hero-copy h1 {
  max-width: 820px;
  margin: 16px 0 18px;
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: clamp(2.4rem, 7vw, 5.35rem);
  line-height: 0.98;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--green);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.82rem;
}

.lead,
.section-lead {
  max-width: 780px;
  color: #D4D4D8;
  font-size: 1.12rem;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(244, 244, 245, 0.05);
  color: var(--text);
  font-weight: 700;
  cursor: pointer;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  border-color: transparent;
  color: #06110D;
  background: linear-gradient(135deg, var(--green), var(--blue));
}

.fact-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 22px;
}

.fact-card,
.card,
.control-card,
.code-card,
.hero-panel,
.hero-demo,
.map-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(244, 244, 245, 0.055);
  box-shadow: var(--shadow);
}

.fact-card {
  padding: 14px;
}

.fact-card strong {
  display: block;
  color: var(--orange);
  font-size: 1.45rem;
  line-height: 1.1;
}

.fact-card span {
  color: var(--muted);
  font-size: 0.86rem;
}

.hero-demo {
  overflow: hidden;
  background: var(--surface);
}

.browser-bar {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.browser-bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--pink);
}

.browser-bar span:nth-child(2) {
  background: var(--orange);
}

.browser-bar span:nth-child(3) {
  background: var(--green);
}

.hero-demo iframe,
.wide-frame iframe {
  width: 100%;
  min-height: 450px;
  background: #0B0B0F;
}

.hero-demo-wide iframe {
  height: min(74vh, 720px);
  min-height: 640px;
}

.demo-frame-large iframe {
  height: 760px;
  min-height: 760px;
}

.hero-panel,
.control-card {
  padding: 22px;
}

.hero-panel h2 {
  margin-top: 0;
}

.section {
  padding: 54px 0;
}

.compact-section .shell {
  max-width: 900px;
}

.section h2 {
  margin: 0 0 14px;
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: clamp(1.8rem, 4vw, 3.25rem);
  line-height: 1.05;
}

.card-grid,
.code-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 22px;
  min-width: 0;
}

.code-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.code-card {
  padding: 20px;
  min-width: 0;
}

.card h3,
.code-card h3 {
  margin: 0 0 8px;
  font-size: 1.18rem;
}

.card p {
  margin: 0;
  color: var(--muted);
}

.control-card {
  display: grid;
  gap: 11px;
}

.control-card label {
  color: #D4D4D8;
  font-weight: 700;
}

.control-card textarea,
.control-card select,
.control-card input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  color: var(--text);
  background: var(--surface-2);
  font: inherit;
}

.control-card textarea {
  min-height: 120px;
  resize: vertical;
}

.inline-result {
  margin: 0;
  color: var(--orange);
  font-weight: 700;
}

.code-card {
  background: #050507;
}

.code-card pre,
.control-card pre {
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: #050507;
  color: #D7FFE7;
}

.table-wrap {
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

th,
td {
  padding: 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

thead th {
  color: #06110D;
  background: linear-gradient(135deg, var(--green), var(--blue));
}

tbody th {
  color: var(--text);
  width: 20%;
}

td {
  color: #D4D4D8;
}

.section-map {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 22px;
}

.map-item {
  padding: 16px;
  box-shadow: none;
  min-width: 0;
}

.map-item span {
  color: var(--green);
  font-weight: 700;
}

.map-item h2 {
  margin: 8px 0;
  font-size: 1.1rem;
  line-height: 1.2;
}

.map-item p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.faq-section details {
  margin: 10px 0;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(244, 244, 245, 0.05);
}

.faq-section summary {
  cursor: pointer;
  font-weight: 700;
}

.wide-frame {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.language-section {
  border-block: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(35, 209, 139, 0.08), rgba(79, 140, 255, 0.09)),
    rgba(244, 244, 245, 0.025);
}

.language-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 22px;
}

.language-card {
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(9, 9, 11, 0.62);
}

.language-card span {
  display: inline-grid;
  width: 42px;
  height: 42px;
  margin-bottom: 14px;
  place-items: center;
  border-radius: var(--radius);
  color: #06110D;
  background: linear-gradient(135deg, var(--orange), var(--green));
  font-weight: 800;
}

.language-card h3 {
  margin: 0 0 8px;
}

.language-card p {
  margin: 0;
  color: var(--muted);
}

.trust-copy {
  display: grid;
  gap: 10px;
  color: #D4D4D8;
}

.site-footer {
  padding: 38px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.footer-grid {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.footer-grid nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 980px) {
  .hero-grid,
  .split,
  .card-grid,
  .code-grid,
  .section-map,
  .language-grid {
    grid-template-columns: 1fr;
  }

  .fact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nav-links {
    display: none;
  }

  .hero-demo {
    order: -1;
  }
}

@media (max-width: 640px) {
  .shell,
  .header-shell {
    width: min(calc(100% - 22px), 1180px);
  }

  .hero {
    padding-top: 34px;
  }

  .hero-demo iframe,
  .wide-frame iframe {
    height: 460px;
    min-height: 460px;
  }

  .hero-copy h1 {
    font-size: 2.35rem;
  }

  .fact-grid {
    grid-template-columns: 1fr;
  }

  .button-row,
  .footer-grid {
    flex-direction: column;
  }
}
