:root {
  color-scheme: dark;
  --ink: #f4f1ea;
  --muted: #999b96;
  --line: #292c2a;
  --panel: #151816;
  --panel-2: #1b1f1c;
  --accent: #b7f34a;
  --accent-ink: #12170b;
  --danger: #ff816d;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 77% 8%, rgba(183, 243, 74, 0.08), transparent 28rem),
    #0c0e0d;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button, input { font: inherit; }

.shell { width: min(1080px, calc(100% - 40px)); margin: 0 auto; padding-bottom: 64px; }
.masthead { display: flex; align-items: center; justify-content: space-between; height: 88px; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; font-weight: 720; letter-spacing: -0.02em; }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid #555d55; color: var(--accent); font-family: ui-monospace, monospace; transform: rotate(-7deg); }
.local-badge { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: 0.13em; }
.local-badge i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 14px var(--accent); }

.hero { padding: 72px 0 50px; }
.eyebrow { margin: 0 0 18px; color: var(--accent); font: 700 11px/1 ui-monospace, SFMono-Regular, Consolas, monospace; letter-spacing: 0.15em; text-transform: uppercase; }
h1 { max-width: 800px; margin: 0; font-size: clamp(52px, 9vw, 104px); line-height: 0.88; letter-spacing: -0.07em; font-weight: 760; }
h1 span { color: #70756f; }
.lede { max-width: 570px; margin: 32px 0 0 auto; color: var(--muted); font-size: 16px; line-height: 1.7; }

.workspace { padding: 30px; border: 1px solid var(--line); background: linear-gradient(145deg, rgba(27,31,28,.94), rgba(18,21,19,.96)); box-shadow: 0 26px 80px rgba(0,0,0,.28); }
.step-rail { display: flex; align-items: center; margin-bottom: 28px; color: #676b66; font: 650 11px/1 ui-monospace, monospace; letter-spacing: .12em; text-transform: uppercase; }
.step { white-space: nowrap; }
.step b { margin-right: 7px; color: #565b55; }
.step.active { color: var(--ink); }
.step.active b { color: var(--accent); }
.rule { width: 56px; height: 1px; margin: 0 14px; background: var(--line); }

.drop-zone { display: grid; min-height: 320px; place-items: center; align-content: center; border: 1px dashed #444a44; background: rgba(8,10,9,.38); text-align: center; transition: border-color .2s, background .2s, transform .2s; }
.drop-zone:hover, .drop-zone.dragging { border-color: var(--accent); background: rgba(183,243,74,.035); }
.drop-zone.dragging { transform: scale(.994); }
.drop-icon { display: grid; place-items: center; width: 54px; height: 54px; margin-bottom: 22px; border: 1px solid #4a504a; border-radius: 50%; color: var(--accent); font-size: 25px; }
.drop-zone h2 { margin: 0; font-size: clamp(22px, 4vw, 34px); letter-spacing: -.035em; }
.drop-zone p { margin: 12px 0 24px; color: var(--muted); }
.picker-actions { display:flex; justify-content:center; gap:10px; margin:4px 0 24px; }
.picker-button { display:inline-flex; align-items:center; gap:9px; padding:12px 15px; border:1px solid #4a504a; background:#141714; color:var(--ink); cursor:pointer; font-size:12px; font-weight:750; }
.picker-button:hover { border-color:var(--accent); }
.primary-picker { border-color:var(--accent); background:var(--accent); color:var(--accent-ink); }
.primary-picker:hover { background:#c6ff5d; }
.drop-zone small { color: #696d69; font: 11px/1.4 ui-monospace, monospace; text-transform: uppercase; letter-spacing: .1em; }

.selection, .progress-panel, .result { margin-top: 16px; border: 1px solid var(--line); background: rgba(8,10,9,.42); }
.selection { display: flex; align-items: center; padding: 15px; }
.file-glyph { display: grid; place-items: center; width: 45px; height: 45px; background: var(--accent); color: var(--accent-ink); font: 800 11px ui-monospace, monospace; }
.file-copy { display: grid; gap: 4px; min-width: 0; margin-left: 14px; }
.file-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.file-copy span { color: var(--muted); font-size: 12px; }
.icon-button { margin-left: auto; border: 0; background: transparent; color: var(--muted); font-size: 24px; cursor: pointer; }
.icon-button:hover { color: var(--ink); }

.progress-panel { padding: 18px; }
.progress-copy { display: grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap: 20px; font-size: 12px; }
.progress-copy span { overflow:hidden; color: var(--muted); text-align: right; text-overflow:ellipsis; white-space:nowrap; }
.progress-copy b { min-width:42px; color:var(--accent); text-align:right; font:700 12px ui-monospace,monospace; }
.progress-track { height: 3px; margin-top: 14px; overflow: hidden; background: #292d29; }
.progress-track i { display:block; width:100%; height:100%; background:var(--accent); transform:scaleX(0); transform-origin:left center; transition:transform .16s linear; will-change:transform; }
.progress-track i.resetting { transition:none; }
.transfer-stats { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); margin-top:16px; border:1px solid var(--line); background:#0e110f; }
.transfer-stats div { display:grid; gap:5px; padding:11px 13px; border-right:1px solid var(--line); }
.transfer-stats div:last-child { border-right:0; }
.transfer-stats small { color:#686d68; font:700 9px ui-monospace,monospace; letter-spacing:.08em; text-transform:uppercase; }
.transfer-stats strong { color:var(--ink); font:750 12px ui-monospace,monospace; }
.transfer-stats div:first-child strong { color:var(--accent); }

.primary-button { display: flex; width: 100%; align-items: center; justify-content: space-between; margin-top: 16px; padding: 18px 20px; border: 0; background: var(--accent); color: var(--accent-ink); font-weight: 800; cursor: pointer; text-transform: uppercase; letter-spacing: .08em; }
.primary-button:hover:not(:disabled) { background: #c6ff5d; }
.primary-button:disabled { cursor: not-allowed; opacity: .35; }
.primary-button span { font-size: 20px; }

.result { padding: 22px; }
.link-row { display: flex; gap: 8px; }
.link-row input { min-width: 0; flex: 1; padding: 13px; border: 1px solid #383d38; background: #0c0e0d; color: var(--ink); font: 12px ui-monospace, monospace; outline: none; }
.link-row button { padding: 0 18px; border: 1px solid var(--accent); background: transparent; color: var(--accent); cursor: pointer; font-weight: 700; }
.warning, .privacy-note { color: var(--muted); font-size: 12px; line-height: 1.55; }
.warning { margin: 14px 0 0; }
.warning code { color: var(--ink); }
.privacy-note { margin: 18px 0 0; text-align: center; }
.privacy-note span { margin-right: 8px; color: var(--accent); }
.error { margin: 16px 0 0; padding: 14px; border-left: 2px solid var(--danger); background: rgba(255,129,109,.08); color: var(--danger); font-size: 13px; }
.hidden { display: none !important; }

@media (max-width: 640px) {
  .shell { width: min(100% - 24px, 1080px); }
  .masthead { height: 70px; }
  .hero { padding: 48px 0 36px; }
  .lede { margin-left: 0; }
  .workspace { padding: 16px; }
  .rule { width: 18px; margin: 0 7px; }
  .step b { display: none; }
  .drop-zone { min-height: 245px; padding: 24px 12px; }
  .picker-actions { width:100%; flex-direction:column; }
  .picker-button { justify-content:center; }
  .progress-copy { grid-template-columns:1fr auto; }
  .progress-copy span { grid-column:1 / -1; grid-row:2; text-align:left; }
  .transfer-stats { grid-template-columns:1fr 1fr; }
  .transfer-stats div:nth-child(2) { border-right:0; }
  .transfer-stats div:last-child { grid-column:1 / -1; border-top:1px solid var(--line); }
  .link-row { display: grid; }
  .link-row button { padding: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  .progress-track i { transition: none; }
}
