:root {
  color-scheme: dark;
  --ink: #f5f2e9;
  --muted: #979b98;
  --line: rgba(255, 255, 255, 0.12);
  --panel: rgba(19, 22, 21, 0.9);
  --acid: #c9ff45;
  --acid-dark: #93bd27;
  --danger: #ff7b67;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 78% 10%, rgba(201, 255, 69, 0.09), transparent 25rem),
    linear-gradient(135deg, #090b0a 0%, #111513 55%, #090b0a 100%);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.2;
  background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 48px 48px;
}

.shell { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 30px 0 22px; }
.hero { padding: 12px 0 42px; }
.brand-row { display: flex; align-items: center; gap: 12px; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--acid); color: var(--acid); font: 800 12px/1 ui-monospace, monospace; transform: rotate(-4deg); }
.brand-name { font-weight: 760; letter-spacing: -.02em; }
.status-pill { margin-left: auto; border: 1px solid var(--line); border-radius: 999px; padding: 8px 12px; color: var(--muted); font-size: 12px; }
.status-pill i { display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: var(--acid); box-shadow: 0 0 12px var(--acid); }
.eyebrow, .step { color: var(--acid); font: 700 11px/1.2 ui-monospace, SFMono-Regular, Consolas, monospace; letter-spacing: .16em; }
.eyebrow { margin: 64px 0 18px; }
h1 { max-width: 850px; margin: 0; font-size: clamp(48px, 7vw, 86px); line-height: .94; letter-spacing: -.065em; font-weight: 760; }
h1 span { color: var(--acid); }
.intro { max-width: 650px; margin: 24px 0 0; color: var(--muted); font-size: 16px; line-height: 1.7; }

.workspace { display: grid; grid-template-columns: .82fr 1.18fr; min-height: 535px; overflow: hidden; border: 1px solid var(--line); background: rgba(4, 6, 5, .55); box-shadow: 0 30px 90px rgba(0,0,0,.35); }
.form-panel, .result-panel { padding: clamp(28px, 4vw, 48px); }
.form-panel { display: flex; flex-direction: column; border-right: 1px solid var(--line); background: var(--panel); }
.result-panel { position: relative; min-width: 0; }
.step { margin: 0 0 12px; }
h2 { margin: 0; font-size: 26px; letter-spacing: -.035em; }
.muted { margin: 14px 0 32px; color: var(--muted); font-size: 14px; line-height: 1.65; }
form { margin-bottom: 28px; }
label { display: block; margin-bottom: 9px; color: #d3d5d1; font-size: 13px; font-weight: 650; }
.input-wrap { display: flex; align-items: center; height: 54px; border: 1px solid var(--line); background: #0b0e0c; transition: .2s ease; }
.input-wrap:focus-within { border-color: var(--acid); box-shadow: 0 0 0 3px rgba(201,255,69,.1); }
.input-wrap span { padding-left: 17px; color: var(--acid); font: 700 15px ui-monospace, monospace; }
input { width: 100%; height: 100%; border: 0; outline: 0; padding: 0 15px 0 10px; background: transparent; color: var(--ink); font: inherit; }
input::placeholder { color: #535854; }
.field-error { min-height: 18px; margin: 7px 0 5px; color: var(--danger); font-size: 12px; }
button { font: inherit; }
#fetch-button { display: flex; align-items: center; justify-content: space-between; width: 100%; height: 54px; border: 0; padding: 0 18px; background: var(--acid); color: #10130b; font-weight: 800; cursor: pointer; transition: .2s ease; }
#fetch-button:hover { background: #d9ff78; transform: translateY(-1px); }
#fetch-button:disabled { cursor: wait; opacity: .7; transform: none; }
.button-arrow { font-size: 22px; }
.privacy-note { display: flex; gap: 12px; margin-top: auto; padding-top: 26px; border-top: 1px solid var(--line); }
.privacy-note > span { color: var(--acid); }
.privacy-note p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.privacy-note strong { color: var(--ink); }

.result-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.copy-button { border: 1px solid var(--line); padding: 9px 12px; background: transparent; color: var(--muted); font-size: 12px; cursor: pointer; }
.copy-button:not(:disabled):hover { border-color: var(--acid); color: var(--acid); }
.copy-button:disabled { opacity: .4; cursor: default; }
.summary { display: flex; gap: 12px; margin: 24px 0 14px; }
.summary div { min-width: 110px; padding: 12px 14px; border: 1px solid var(--line); background: rgba(255,255,255,.025); }
.summary span { display: block; color: var(--acid); font: 700 22px ui-monospace, monospace; }
.summary small { color: var(--muted); }
.empty-state, .loading-state { min-height: 350px; display: grid; place-content: center; justify-items: center; text-align: center; }
.empty-icon { margin-bottom: 18px; color: var(--acid); font: 600 35px ui-monospace, monospace; opacity: .8; }
.empty-state h3 { margin: 0 0 8px; font-size: 17px; }
.empty-state p, .loading-state p { max-width: 320px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.loader { width: 32px; height: 32px; margin-bottom: 16px; border: 2px solid var(--line); border-top-color: var(--acid); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.error-state { margin-top: 28px; border-left: 3px solid var(--danger); padding: 14px 16px; background: rgba(255,123,103,.08); color: #ffc2b9; font-size: 13px; line-height: 1.6; }
pre { max-height: 340px; margin: 14px 0 0; overflow: auto; border: 1px solid var(--line); padding: 20px; background: #080a09; color: #d7e5c0; font: 12px/1.65 ui-monospace, SFMono-Regular, Consolas, monospace; tab-size: 2; }
footer { display: flex; justify-content: space-between; padding: 18px 2px 0; color: #666d68; font: 10px ui-monospace, monospace; letter-spacing: .08em; text-transform: uppercase; }
[hidden] { display: none !important; }

@media (max-width: 820px) {
  .shell { width: min(100% - 24px, 680px); padding-top: 18px; }
  .hero { padding-bottom: 30px; }
  .eyebrow { margin-top: 48px; }
  .workspace { grid-template-columns: 1fr; }
  .form-panel { min-height: 470px; border-right: 0; border-bottom: 1px solid var(--line); }
  .result-panel { min-height: 500px; }
}

@media (max-width: 520px) {
  .status-pill { display: none; }
  h1 { font-size: 46px; }
  .form-panel, .result-panel { padding: 25px 20px; }
  .result-header { align-items: center; }
  footer { gap: 16px; flex-direction: column; }
}
