:root {
  color-scheme: dark;
  --bg: #0c1014;
  --panel: #141b22;
  --panel-strong: #1f2a33;
  --text: #f4f0e6;
  --muted: #abb6bd;
  --line: rgba(244, 240, 230, 0.13);
  --gold: #d9a441;
  --green: #69c08f;
  --red: #d86f5d;
  --blue: #6ea8d9;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
  min-height: 72px;
  padding: 12px clamp(18px, 5vw, 64px);
  border-bottom: 1px solid var(--line);
  background: rgba(12, 16, 20, 0.88);
  backdrop-filter: blur(14px);
}

.brand,
.top-nav,
.hero-actions,
.site-footer {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--gold);
  color: #17120b;
  font-weight: 900;
}

.top-nav {
  justify-content: center;
  gap: clamp(14px, 3vw, 34px);
  color: var(--muted);
  font-size: 0.95rem;
}

.top-nav a:hover,
.site-footer a:hover {
  color: var(--text);
}

.header-action,
.primary-action,
.secondary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 8px;
  font-weight: 800;
  white-space: nowrap;
}

.header-action,
.secondary-action {
  border: 1px solid var(--line);
  padding: 0 16px;
  color: var(--text);
}

.primary-action {
  padding: 0 20px;
  background: var(--gold);
  color: #17120b;
}

.hero-actions .primary-action {
  min-width: 240px;
}

.secondary-action.compact {
  min-height: 40px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(320px, 1.25fr) minmax(190px, 0.42fr);
  align-items: center;
  gap: clamp(22px, 4vw, 52px);
  min-height: calc(100svh - 72px);
  padding: clamp(34px, 6vw, 82px) clamp(18px, 5vw, 64px) 34px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: 9rem;
  line-height: 0.9;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  max-width: 820px;
  font-size: 4.6rem;
  line-height: 0.98;
  letter-spacing: 0;
}

h3 {
  margin: 0 0 10px;
  font-size: 1.18rem;
  letter-spacing: 0;
}

.hero-text {
  max-width: 560px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 1.22rem;
}

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

.hero-visual {
  overflow: hidden;
  min-height: 360px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.34);
}

.hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 360px;
  object-fit: cover;
  object-position: center;
}

.hero-status {
  display: grid;
  gap: 12px;
}

.hero-status div,
.system-grid article,
.command-panel,
.command-output,
.webhook-copy {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.hero-status div {
  min-height: 94px;
  padding: 18px;
}

.hero-status span {
  display: block;
  color: var(--muted);
  font-size: 0.86rem;
}

.hero-status strong {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 1.65rem;
}

.trust-strip {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #10171d;
}

.trust-strip span {
  display: grid;
  place-items: center;
  min-height: 72px;
  border-right: 1px solid var(--line);
  color: var(--muted);
  font-weight: 800;
}

.trust-strip span:last-child {
  border-right: 0;
}

.section {
  padding: clamp(56px, 8vw, 104px) clamp(18px, 5vw, 64px);
}

.section-heading {
  margin-bottom: 34px;
}

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

.system-grid article {
  min-height: 250px;
  padding: 22px;
}

.system-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  margin-bottom: 28px;
  border-radius: 8px;
  background: var(--panel-strong);
  color: var(--gold);
  font-weight: 900;
}

.system-grid p,
.webhook-copy p {
  margin: 0;
  color: var(--muted);
}

.command-section {
  display: grid;
  grid-template-columns: minmax(300px, 0.9fr) minmax(320px, 1.1fr);
  gap: 18px;
  background: #0f1419;
}

.command-panel,
.command-output {
  min-height: 460px;
  padding: 24px;
}

.command-list {
  display: grid;
  gap: 10px;
}

.command-row {
  display: grid;
  grid-template-columns: 120px 1fr;
  align-items: center;
  min-height: 64px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f151a;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.command-row span {
  padding-left: 16px;
  color: var(--gold);
  font-family: "SFMono-Regular", Consolas, monospace;
}

.command-row strong {
  padding: 0 16px;
}

.command-row.active {
  border-color: rgba(217, 164, 65, 0.75);
  background: #1b211e;
}

.terminal-label {
  margin: 0 0 12px;
  color: var(--blue);
  font-weight: 900;
}

pre {
  min-height: 320px;
  margin: 0;
  padding: 22px;
  border-radius: 8px;
  background: #080b0e;
  color: #d9f7e5;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.98rem;
  line-height: 1.7;
  white-space: pre-wrap;
}

.webhook-layout {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(280px, 0.72fr);
  gap: 18px;
}

.event-stream {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.event-stream span {
  display: grid;
  place-items: center;
  min-height: 92px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #10171d;
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, monospace;
}

.event-stream span:nth-child(2n) {
  color: var(--gold);
}

.event-stream span:nth-child(3n) {
  color: var(--red);
}

.webhook-copy {
  padding: 26px;
}

.webhook-copy .secondary-action {
  margin-top: 24px;
}

.site-footer {
  justify-content: space-between;
  min-height: 82px;
  padding: 0 clamp(18px, 5vw, 64px);
  border-top: 1px solid var(--line);
  color: var(--muted);
}

@media (max-width: 1080px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero-visual img,
  .hero-visual {
    min-height: 320px;
  }

  .hero-status {
    grid-template-columns: repeat(3, 1fr);
  }

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

  h1 {
    font-size: 6.5rem;
  }

  h2 {
    font-size: 3.4rem;
  }
}

@media (max-width: 760px) {
  .site-header {
    grid-template-columns: 1fr auto;
    gap: 10px;
    min-height: 64px;
    padding: 10px 14px;
  }

  .top-nav {
    display: none;
  }

  .header-action {
    min-height: 40px;
    padding: 0 12px;
    font-size: 0.9rem;
  }

  .hero {
    gap: 18px;
    padding: 28px 14px 22px;
  }

  h1 {
    font-size: 4.2rem;
    line-height: 0.95;
  }

  h2 {
    font-size: 2.15rem;
    line-height: 1.06;
  }

  .hero-text {
    margin-top: 16px;
    font-size: 1rem;
  }

  .hero-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 22px;
  }

  .primary-action,
  .secondary-action {
    min-width: 0;
    width: 100%;
    min-height: 46px;
  }

  .hero-visual,
  .hero-visual img {
    min-height: 210px;
  }

  .hero-visual {
    order: 3;
  }

  .hero-status {
    order: 2;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }

  .hero-status div {
    min-height: 78px;
    padding: 12px 10px;
  }

  .hero-status span {
    font-size: 0.74rem;
    line-height: 1.25;
  }

  .hero-status strong {
    font-size: 1.18rem;
  }

  .system-grid,
  .command-section,
  .webhook-layout {
    grid-template-columns: 1fr;
  }

  .trust-strip,
  .event-stream {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .trust-strip span {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    min-height: 54px;
    font-size: 0.92rem;
  }

  .trust-strip span:nth-child(odd) {
    border-right: 1px solid var(--line);
  }

  .trust-strip span:nth-last-child(-n + 2) {
    border-bottom: 0;
  }

  .section {
    padding: 46px 14px;
  }

  .section-heading {
    margin-bottom: 22px;
  }

  .system-grid {
    gap: 10px;
  }

  .system-grid article {
    min-height: 0;
    padding: 18px;
  }

  .system-icon {
    margin-bottom: 18px;
  }

  .command-panel,
  .command-output {
    min-height: 0;
    padding: 18px;
  }

  .command-row {
    grid-template-columns: 1fr;
    gap: 2px;
    padding: 12px 0;
  }

  .command-row span {
    padding: 0 14px;
  }

  .command-row strong {
    padding: 0 14px;
    font-size: 0.95rem;
  }

  pre {
    min-height: 210px;
    padding: 16px;
    font-size: 0.86rem;
    line-height: 1.55;
  }

  .event-stream {
    gap: 8px;
  }

  .event-stream span {
    min-height: 70px;
    padding: 0 8px;
    font-size: 0.8rem;
    text-align: center;
  }

  .webhook-copy {
    padding: 20px;
  }

  .site-footer {
    min-height: 68px;
    padding: 0 14px;
  }
}

@media (max-width: 380px) {
  .brand {
    gap: 8px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
  }

  .header-action {
    padding: 0 10px;
    font-size: 0.82rem;
  }

  h1 {
    font-size: 3.55rem;
  }

  h2 {
    font-size: 1.9rem;
  }

  .hero-status {
    grid-template-columns: 1fr;
  }

  .hero-status div {
    min-height: 62px;
  }
}
