:root {
  --ink: #060607;
  --ink-soft: #0d0d0f;
  --line: #1b1b1f;
  --text: #f4f4f5;
  --muted: #9a9a9f;
  --accent: #ff4d1c;
  --accent-dim: #7a2a08;
  --green: #2ebd7c;
  --danger: #e8453c;
  --stage-h: 560px;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font: 400 16px/1.55 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 24px 64px;
  isolation: isolate;
}

#streams,
.glow,
.circuit {
  position: absolute;
  pointer-events: none;
}

/* The glow must sit under the streams, otherwise its blur washes them out. */
.glow { z-index: -3; }
.circuit { z-index: -3; }
#streams { inset: 0; width: 100%; height: 100%; z-index: -2; }
.stage { z-index: 1; }

.glow {
  left: 52%;
  top: 52%;
  width: min(1000px, 82vw);
  aspect-ratio: 1.5;
  transform: translate(-52%, -50%);
  background:
    radial-gradient(closest-side, rgba(255, 104, 36, .62), rgba(255, 74, 20, .22) 40%, transparent 68%);
  filter: blur(12px);
}

.circuit {
  width: 300px;
  height: 260px;
  stroke: #23232a;
  stroke-width: 1.2;
  fill: none;
}
.circuit circle { fill: #23232a; stroke: none; }
.circuit--left { left: 0; bottom: 110px; opacity: .8; }
.circuit--right { right: 0; bottom: 110px; opacity: .8; }

.intro { max-width: 1120px; margin: 0 auto; text-align: center; }

.eyebrow {
  margin: 0 0 18px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.intro h1 {
  margin: 0 0 22px;
  font-size: clamp(27px, 3.9vw, 52px);
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.08;
}

.lede {
  margin: 0 auto;
  max-width: 620px;
  color: var(--muted);
  font-size: 15px;
}

/* ---------- illustration ---------- */

.stage {
  position: relative;
  height: var(--stage-h);
  max-width: 1420px;
  margin: -12px auto 0;
}

.chip,
.ghost,
.core {
  position: absolute;
  left: var(--x);
  top: var(--y);
  transform: translate(-50%, -50%);
}

.chip {
  display: grid;
  place-items: center;
  width: 76px;
  height: 88px;
  border-radius: 14px;
  background: #0e0e11;
  border: 1px solid #212127;
  box-shadow: 0 20px 40px rgba(0, 0, 0, .65);
}

.chip img { width: 46px; height: 46px; display: block; }

.chip--out { width: 96px; height: 108px; }
.chip--out img { width: 58px; height: 58px; }

.ghost {
  width: 34px;
  height: 42px;
  border-radius: 5px;
  border: 1px solid #1c1c21;
  background: #0b0b0d;
}
.ghost::after {
  content: "";
  display: block;
  margin: 10px auto;
  width: 16px;
  height: 2px;
  border-top: 2px solid #26262c;
  border-bottom: 2px solid #26262c;
  height: 8px;
}

.core { left: 52%; top: 52%; width: min(310px, 28vw); }
.mark { width: 100%; height: auto; filter: drop-shadow(0 26px 60px rgba(0, 0, 0, .7)); }

/* ---------- pillars ---------- */

.pillars {
  display: flex;
  justify-content: center;
  gap: clamp(32px, 8vw, 120px);
  margin: 4px auto 0;
  padding: 0;
  list-style: none;
  text-align: center;
}

.pillars li { max-width: 220px; }

/* Line icons ship black; the filter recolours them to the accent. */
.pillar-icon,
.drop-icon {
  filter: brightness(0) saturate(100%) invert(46%) sepia(72%) saturate(4200%)
          hue-rotate(348deg) brightness(101%) contrast(101%);
}

.pillar-icon { width: 28px; height: 28px; margin-bottom: 14px; }

.pillars p { margin: 0; font-size: 15px; color: #d6d6da; }

/* ---------- panel ---------- */

.panel {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 24px 96px;
}

.panel-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 14px;
  color: var(--muted);
}

.panel-head select {
  padding: 8px 12px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--ink-soft);
  color: var(--text);
  font: inherit;
}

.panel-meta { margin-left: auto; font-size: 13px; }

.drop {
  display: grid;
  place-items: center;
  padding: 54px 24px;
  border: 1.5px dashed #2a2a31;
  border-radius: 18px;
  background: linear-gradient(180deg, #0b0b0d, #08080a);
  cursor: pointer;
  transition: border-color .18s, background .18s, transform .18s;
}

.drop:hover,
.drop:focus-visible { border-color: #3a3a44; outline: none; }

.drop.is-hot {
  border-color: var(--accent);
  background: linear-gradient(180deg, rgba(255, 77, 28, .10), #08080a);
  transform: scale(1.01);
}

.drop-icon { width: 34px; height: 34px; margin-bottom: 14px; }

.drop-title { margin: 0 0 6px; font-size: 17px; font-weight: 600; }
.drop-hint { margin: 0; font-size: 13.5px; color: var(--muted); }

/* ---------- progress ---------- */

.run {
  margin-top: 22px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--ink-soft);
}

.run-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.run-name { font-weight: 600; font-size: 15px; }
.run-clock { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.run-stage {
  margin-left: auto;
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
}

/* A steady pulse and a moving sweep say "still working" even when the stage label sits still. */
.run-stage::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 1.1s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: .2; transform: scale(.75); }
  50% { opacity: 1; transform: scale(1.2); }
}

.bar { height: 5px; border-radius: 99px; background: #17171b; overflow: hidden; }
.bar span {
  position: relative;
  display: block;
  height: 100%;
  width: 0;
  border-radius: 99px;
  overflow: hidden;
  background: linear-gradient(90deg, var(--accent-dim), var(--accent));
}
.bar span::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .5), transparent);
  transform: translateX(-100%);
  animation: sweep 1.5s linear infinite;
}
.bar.is-done span::after { animation: none; }

@keyframes sweep { to { transform: translateX(100%); } }

@media (prefers-reduced-motion: reduce) {
  .run-stage::before, .bar span::after { animation: none; }
}

.run-detail { margin: 10px 0 0; font-size: 13.5px; color: var(--muted); }

/* ---------- result ---------- */

.result {
  margin-top: 22px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--ink-soft);
}

.result h2 { margin: 0 0 4px; font-size: 19px; }
.result .sub { margin: 0 0 22px; font-size: 13.5px; color: var(--muted); }


.download {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 11px;
  background: var(--green);
  color: #04150d;
  font-weight: 650;
  font-size: 15px;
  text-decoration: none;
}
.download:hover { filter: brightness(1.08); }



.alert {
  margin-top: 18px;
  padding: 14px 18px;
  border: 1px solid #40201d;
  border-radius: 12px;
  background: #170d0c;
  color: #ffb3a7;
  font-size: 14px;
}

@media (max-width: 900px) {
  :root { --stage-h: 420px; }
  .chip { width: 52px; height: 62px; }
  .chip::before { width: 22px; height: 28px; }
  .pillars { flex-direction: column; align-items: center; gap: 26px; }
  .circuit { display: none; }
}

/* ---------- language ---------- */

.lang {
  position: absolute;
  top: 22px;
  right: 26px;
  z-index: 4;
  display: flex;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
}

.lang a {
  padding: 5px 9px;
  border-radius: 7px;
  color: #6d6d75;
  text-decoration: none;
}
.lang a:hover { color: var(--text); }
.lang a.is-on { background: #17171b; color: var(--text); }
