:root {
  color-scheme: light;
  --bg: #f7f8fb;
  --surface: #ffffff;
  --text: #17202a;
  --muted: #617080;
  --line: #dbe2ea;
  --accent: #0f766e;
  --accent-strong: #115e59;
  --accent-soft: #d9f4ef;
  --warn: #8a4b0f;
  --warn-soft: #fff4df;
  --shadow: 0 18px 55px rgba(32, 43, 54, 0.09);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.12), rgba(255, 255, 255, 0) 34%),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select {
  font: inherit;
}

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

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: stretch;
  margin-bottom: 22px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

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

h1 {
  max-width: 760px;
  margin-bottom: 12px;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 0.96;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 8px;
  font-size: 18px;
  line-height: 1.2;
}

.lead {
  max-width: 780px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.6;
}

.wallet-panel,
.panel,
.step {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.wallet-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  padding: 22px;
}

.wallet-meta {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  word-break: break-all;
}

.flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.step {
  min-height: 150px;
  padding: 18px;
}

.step.active {
  border-color: rgba(15, 118, 110, 0.38);
  background: linear-gradient(180deg, #ffffff, #eefaf7);
}

.step-index {
  display: inline-grid;
  width: 30px;
  height: 30px;
  place-items: center;
  margin-bottom: 14px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 14px;
  font-weight: 800;
}

.step p,
.notes p {
  color: var(--muted);
  line-height: 1.55;
}

.workbench,
.output-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(330px, 0.65fr);
  gap: 18px;
  margin-bottom: 18px;
}

.panel {
  padding: 20px;
}

.panel-head {
  display: flex;
  min-height: 34px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.panel-head h2 {
  margin: 0;
}

.pill {
  display: inline-flex;
  max-width: 100%;
  min-height: 28px;
  align-items: center;
  border-radius: 999px;
  background: #eef2f7;
  color: var(--muted);
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 700;
  word-break: break-all;
}

form {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 7px;
  color: #314052;
  font-size: 13px;
  font-weight: 750;
}

input,
select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  padding: 10px 12px;
  outline: none;
}

input:focus,
select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.14);
}

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

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

button {
  min-height: 42px;
  border: 0;
  border-radius: 6px;
  padding: 9px 12px;
  cursor: pointer;
  font-weight: 800;
  transition: transform 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

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

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
}

.primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 10px 24px rgba(15, 118, 110, 0.22);
}

.primary:hover {
  background: var(--accent-strong);
}

.secondary {
  background: #1f2937;
  color: #fff;
}

.ghost {
  min-height: 34px;
  background: #eef2f7;
  color: #344054;
  font-size: 13px;
}

.stats {
  display: grid;
  gap: 12px;
  margin: 0;
}

.stats div {
  display: grid;
  gap: 4px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}

.stats dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.stats dd {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  word-break: break-all;
}

.notice {
  margin-top: 16px;
  border: 1px solid #f1d7a8;
  border-radius: 8px;
  background: var(--warn-soft);
  color: var(--warn);
  padding: 12px;
  font-size: 14px;
  line-height: 1.45;
}

pre {
  min-height: 240px;
  max-height: 380px;
  overflow: auto;
  margin: 0;
  border: 1px solid #e4e9ef;
  border-radius: 8px;
  background: #101820;
  color: #d6fff7;
  padding: 14px;
  font-size: 12px;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}

.notes {
  padding: 0 2px;
}

@media (max-width: 920px) {
  .hero,
  .workbench,
  .output-grid,
  .flow {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 560px) {
  .shell {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  h1 {
    font-size: 36px;
  }

  .grid.two,
  .actions {
    grid-template-columns: 1fr;
  }

  .panel,
  .step,
  .wallet-panel {
    padding: 16px;
  }
}
