:root {
  --ink: #172033;
  --muted: #667085;
  --line: #d8dee8;
  --paper: #f6f8fb;
  --surface: #ffffff;
  --teal: #0f766e;
  --gold: #f59e0b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select {
  font: inherit;
}

.shell {
  display: grid;
  gap: 18px;
  margin: 0 auto;
  max-width: 1280px;
  min-height: 100vh;
  padding: clamp(16px, 3vw, 28px);
}

.topbar,
.output-head,
.fineprint {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar {
  border-bottom: 1px solid var(--line);
  padding-bottom: 18px;
}

.purchase-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, #fdf7ee 100%);
  padding: 16px 18px;
}

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

h1,
h2,
h3 {
  margin: 0;
}

h1 {
  max-width: 850px;
  font-size: clamp(2.15rem, 6vw, 4.9rem);
  line-height: 0.98;
}

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

.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 20px 60px rgba(23, 32, 51, 0.1);
  padding: 18px;
}

.controls {
  display: grid;
  gap: 13px;
  align-content: start;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 850;
}

input,
select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  padding: 0 11px;
}

.primary,
button {
  display: inline-grid;
  min-height: 42px;
  place-items: center;
  border: 1px solid var(--ink);
  border-radius: 7px;
  background: var(--ink);
  color: #fff;
  cursor: pointer;
  font-weight: 900;
  padding: 0 14px;
  text-decoration: none;
}

.secondary {
  display: inline-grid;
  min-height: 42px;
  place-items: center;
  border: 1px solid var(--teal);
  border-radius: 7px;
  background: #e6fffb;
  color: #115e59;
  cursor: pointer;
  font-weight: 900;
  padding: 0 14px;
  text-decoration: none;
}

.output {
  display: grid;
  gap: 14px;
}

.output article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
  padding: 14px;
}

pre {
  margin: 10px 0 0;
  white-space: pre-wrap;
  color: #344054;
  line-height: 1.6;
  font-family: inherit;
}

.fineprint {
  color: var(--muted);
  font-size: 0.86rem;
}

.fineprint a,
.legal a {
  color: var(--teal);
  font-weight: 900;
  text-decoration: none;
}

.legal {
  display: grid;
  gap: 14px;
  margin: 0 auto;
  max-width: 760px;
  min-height: 100vh;
  padding: clamp(28px, 6vw, 72px) 20px;
}

.legal h1 {
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
}

.legal p {
  color: var(--muted);
  line-height: 1.7;
}

@media (max-width: 850px) {
  .grid {
    grid-template-columns: 1fr;
  }

  .topbar,
  .purchase-strip,
  .fineprint {
    align-items: flex-start;
    flex-direction: column;
  }
}
