:root {
  --bg: #121212;
  --surface: #191919;
  --surface-2: #252525;
  --surface-3: #2c2c2c;
  --text: #f0f0f0;
  --muted: #b0b0b0;
  --subtle: #787878;
  --stroke: #2f2f2f;
  --stroke-strong: #5a5a5a;
  --primary: #ff7c2a;
  --primary-dark: #ce6533;
  --bitcoin: #f7931a;
  --cyan: #34c7cf;
  --success: #4caf50;
  --warning: #ff9800;
  --danger: #ef5350;
  --radius: 16px;
  --radius-sm: 8px;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
  color-scheme: dark;
}

[data-theme="light"] {
  --bg: #f5f7f2;
  --surface: #ffffff;
  --surface-2: #f9f9f9;
  --surface-3: #f2f2f2;
  --text: #191919;
  --muted: #5f6467;
  --subtle: #8b9092;
  --stroke: #dedede;
  --stroke-strong: #b8b8b8;
  --shadow: 0 24px 70px rgba(25, 25, 25, 0.1);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(180deg, rgba(255, 124, 42, 0.08), transparent 24rem),
    var(--bg);
  color: var(--text);
  font-family:
    "Px Grotesk",
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  font-size: 14px;
  line-height: 1.45;
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

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

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  z-index: 100;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: var(--primary);
  color: #191919;
}

.skip-link:focus {
  left: 8px;
}

.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  width: min(1180px, calc(100vw - 48px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--stroke);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(18px);
}

.header-grid {
  min-height: 72px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: center;
}

.brand {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  min-width: 226px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--stroke);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--primary);
}

.brand-mark svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.brand-copy {
  display: grid;
  gap: 1px;
}

.brand-name {
  font-weight: 500;
  letter-spacing: 0;
}

.brand-domain,
.eyebrow,
.muted {
  color: var(--muted);
}

.brand-domain,
.eyebrow {
  font-size: 12px;
}

.eyebrow {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.site-nav {
  justify-self: center;
  display: flex;
  gap: 26px;
  color: var(--muted);
}

.site-nav a {
  transition: color 160ms ease;
}

.site-nav a:hover {
  color: var(--primary);
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.button,
.icon-button {
  min-height: 40px;
  border: 1px solid var(--stroke-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.button {
  padding: 0 16px;
  text-align: center;
}

.button:hover,
.icon-button:hover,
.button:focus-visible,
.icon-button:focus-visible {
  border-color: var(--primary);
}

.button:active,
.icon-button:active {
  transform: translateY(1px);
}

.button.primary {
  border-color: var(--primary);
  background: var(--primary);
  color: #191919;
  font-weight: 500;
}

.button.secondary {
  background: var(--surface-2);
}

.button.ghost {
  color: var(--muted);
}

.icon-button {
  width: 40px;
  padding: 0;
}

.main {
  flex: 1;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: 20px;
  padding: 42px 0 18px;
}

.hero-content,
.hero-panel,
.panel,
.surface-card,
.flow-card,
.artifact-card {
  min-width: 0;
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  box-shadow: var(--shadow);
}

.hero-content {
  min-height: 378px;
  padding: 34px;
  position: relative;
  overflow: hidden;
}

.hero-content::after {
  content: "";
  position: absolute;
  right: 34px;
  bottom: 34px;
  width: 120px;
  height: 2px;
  background: var(--primary);
  opacity: 0.75;
  pointer-events: none;
}

.status-pill {
  width: fit-content;
}

.brand-motto {
  margin: 22px 0 0;
  color: var(--primary);
  font-size: 14px;
  font-weight: 500;
}

h1,
h2,
h3,
h4,
p {
  margin-top: 0;
}

h1 {
  max-width: 840px;
  margin: 12px 0 18px;
  font-size: clamp(42px, 6vw, 76px);
  font-weight: 400;
  line-height: 0.96;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 400;
  line-height: 1.08;
}

h3 {
  margin-bottom: 0;
  font-size: 21px;
  font-weight: 400;
}

h4 {
  margin-bottom: 4px;
  font-size: 15px;
  font-weight: 500;
}

.hero-lede {
  max-width: 760px;
  margin-bottom: 20px;
  color: var(--muted);
  font-size: 17px;
}

.truth-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 30px;
}

.truth-row span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 4px 10px;
  background: var(--surface-2);
  color: var(--text);
  font-size: 12px;
}

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

.hero-panel,
.panel {
  padding: 24px;
}

.panel-header,
.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.panel-header {
  align-items: flex-start;
  margin-bottom: 20px;
}

.section-heading {
  align-items: flex-end;
  margin-bottom: 18px;
}

.section-heading.compact {
  display: block;
  margin-bottom: 18px;
}

.section-heading > p {
  max-width: 520px;
  margin-bottom: 0;
  color: var(--muted);
}

.section {
  padding-top: 34px;
}

.metric-list {
  margin: 0;
}

.metric-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 13px 0;
  border-bottom: 1px solid var(--stroke);
}

.metric-row:last-child {
  border-bottom: 0;
}

.metric-row dt {
  color: var(--muted);
}

.metric-row dd {
  margin: 0;
  text-align: right;
  overflow-wrap: anywhere;
}

.badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 24px;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 3px 9px;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
}

.badge.success {
  color: #adf2b0;
  border-color: color-mix(in srgb, var(--success) 38%, transparent);
  background: color-mix(in srgb, var(--success) 14%, transparent);
}

.badge.warning {
  color: #ffd49c;
  border-color: color-mix(in srgb, var(--warning) 38%, transparent);
  background: color-mix(in srgb, var(--warning) 14%, transparent);
}

.badge.danger {
  color: #ffb0a9;
  border-color: color-mix(in srgb, var(--danger) 38%, transparent);
  background: color-mix(in srgb, var(--danger) 14%, transparent);
}

.badge.info {
  color: #a7f1f5;
  border-color: color-mix(in srgb, var(--cyan) 38%, transparent);
  background: color-mix(in srgb, var(--cyan) 14%, transparent);
}

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

.surface-card {
  padding: 22px;
  min-height: 230px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.surface-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: color-mix(in srgb, var(--primary) 14%, transparent);
  color: var(--primary);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.surface-card p,
.flow-card p,
.artifact-card p,
.readiness-item p,
.boundary-item p {
  color: var(--muted);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 20px;
}

.tool-tabs,
.roadmap-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.tab-button,
.filter-button {
  border: 1px solid var(--stroke);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  padding: 7px 12px;
  cursor: pointer;
}

.tab-button[aria-selected="true"],
.filter-button.active {
  border-color: var(--primary);
  color: var(--text);
}

.table-shell {
  overflow-x: auto;
  border: 1px solid var(--stroke);
  border-radius: 12px;
}

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

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

th {
  color: var(--muted);
  font-weight: 400;
  font-size: 12px;
}

tr:last-child td {
  border-bottom: 0;
}

.mono,
code {
  font-family: "Px Grotesk Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
}

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

.command-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--stroke);
  border-radius: 12px;
  background: var(--surface-2);
}

.command-row code {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.copy-small {
  border: 1px solid var(--stroke-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  padding: 6px 10px;
  cursor: pointer;
}

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

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

.readiness-list,
.roadmap-list,
.boundary-list {
  display: grid;
  gap: 12px;
}

.readiness-item,
.roadmap-item,
.boundary-item {
  padding: 14px;
  border: 1px solid var(--stroke);
  border-radius: 12px;
  background: var(--surface-2);
}

.readiness-item h4,
.roadmap-item h4,
.boundary-item h4 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.flow-card,
.artifact-card {
  padding: 20px;
}

.flow-steps {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  padding: 0;
  list-style: none;
}

.flow-step {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
}

.step-number {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--surface-3);
  color: var(--text);
  font-size: 12px;
}

.artifact-card {
  display: grid;
  gap: 12px;
}

.artifact-path {
  padding: 10px;
  border-radius: 10px;
  background: var(--surface-2);
  overflow-wrap: anywhere;
}

.site-footer {
  margin-top: 64px;
  border-top: 1px solid var(--stroke);
}

.footer-grid {
  min-height: 86px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  color: var(--muted);
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 80;
  max-width: min(360px, calc(100vw - 40px));
  padding: 12px 14px;
  border: 1px solid var(--stroke);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.toast.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1060px) {
  .site-nav {
    display: none;
  }

  .header-grid,
  .hero,
  .split {
    grid-template-columns: 1fr;
  }

  .header-actions {
    justify-content: flex-start;
  }

  .hero {
    padding-top: 28px;
  }

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

@media (max-width: 700px) {
  body {
    overflow-x: hidden;
  }

  .container {
    width: calc(100vw - 32px);
    max-width: calc(100vw - 32px);
  }

  .header-grid {
    gap: 14px;
    padding: 12px 0;
  }

  .header-actions .button {
    display: none;
  }

  .brand {
    min-width: 0;
  }

  .hero-content,
  .hero-panel,
  .panel {
    max-width: 100%;
    padding: 18px;
  }

  .hero-lede,
  .truth-row,
  .hero-actions {
    max-width: calc(100vw - 68px);
  }

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

  .hero-actions .button {
    width: 100%;
    white-space: normal;
  }

  .surface-grid,
  .testnet-grid,
  .flow-grid,
  .artifact-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    max-width: calc(100vw - 68px);
    font-size: 36px;
    line-height: 1;
  }

  .section-heading,
  .panel-header {
    display: grid;
    gap: 10px;
  }

  .footer-grid {
    align-items: flex-start;
    flex-direction: column;
  }
}
