/* SplatStudio storefront. One page, no framework — `/j/<id>` is the same
   document as `/`, with panels swapped by app.js. */

:root {
  color-scheme: dark;
  --bg: #08080a;
  --panel: #121216;
  --line: #26262e;
  --ink: #eaeaf0;
  --dim: #8c8c98;
  --accent: #7c9cff;
  --accent-ink: #0a0a0c;
  --ok: #4ec9a0;
  --warn: #e8b04b;
  --bad: #f0736a;
  --radius: 14px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100dvh;
  padding: 28px 18px calc(40px + env(safe-area-inset-bottom));
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.55 system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

.wrap { width: 100%; max-width: 560px; margin-inline: auto; }

/* -- masthead ------------------------------------------------------------- */
.masthead { text-align: center; margin-bottom: 22px; }
.brand {
  font-size: 14px; font-weight: 600; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--dim); margin: 0 0 14px;
}
.brand a { color: inherit; text-decoration: none; }
h1 { margin: 0; font-size: clamp(24px, 6vw, 32px); font-weight: 650; letter-spacing: -0.02em; }
.tagline { margin: 8px 0 0; color: var(--dim); font-size: 15px; }

/* -- generic panel -------------------------------------------------------- */
.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}
.panel + .panel { margin-top: 14px; }
[hidden] { display: none !important; }

/* -- drop zone ------------------------------------------------------------ */
.drop {
  display: grid; place-items: center; gap: 10px;
  padding: 34px 20px;
  border: 1.5px dashed #33333d;
  border-radius: var(--radius);
  background: var(--panel);
  text-align: center;
  cursor: pointer;
  transition: border-color 140ms ease, background 140ms ease;
}
.drop:hover, .drop:focus-visible { border-color: var(--accent); outline: none; }
.drop.is-over { border-color: var(--accent); background: #171722; }
.drop-title { font-weight: 600; }
.drop-sub { color: var(--dim); font-size: 13.5px; }
.drop input[type=file] { display: none; }

/* -- how to shoot it ------------------------------------------------------ */
.howto { margin-top: 14px; }
.howto h3 {
  margin: 0 0 10px; font-size: 12px; font-weight: 600; letter-spacing: 0.07em;
  text-transform: uppercase; color: var(--dim);
}
.howto ol { margin: 0; padding-left: 20px; display: grid; gap: 7px; }
.howto li { font-size: 14px; color: var(--dim); }
.howto li b { color: var(--ink); font-weight: 600; }
.howto-fit {
  margin: 13px 0 0; padding-top: 12px; border-top: 1px solid var(--line);
  font-size: 13px; color: var(--dim); line-height: 1.65;
}
.howto-fit .yes { color: var(--ok); font-weight: 600; }
.howto-fit .no { color: var(--warn); font-weight: 600; }

/* -- progress ------------------------------------------------------------- */
.bar {
  height: 6px; border-radius: 999px; background: #23232b; overflow: hidden;
  margin-top: 14px;
}
.bar > i {
  display: block; height: 100%; width: 0%; border-radius: 999px;
  background: var(--accent);
  transition: width 200ms ease;
}
.bar.is-indeterminate > i {
  width: 40%;
  animation: slide 1.4s ease-in-out infinite;
}
@keyframes slide {
  0% { transform: translateX(-110%); }
  100% { transform: translateX(260%); }
}

.steps { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 9px; }
.steps li {
  display: flex; align-items: center; gap: 10px;
  color: var(--dim); font-size: 14.5px;
}
.steps li::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: #33333d; flex: none;
}
.steps li.is-done { color: var(--ink); }
.steps li.is-done::before { background: var(--ok); }
.steps li.is-active { color: var(--ink); font-weight: 550; }
.steps .est {
  margin-left: 8px; padding: 2px 8px; border-radius: 999px;
  background: #23232c; color: var(--dim);
  font-size: 12px; font-weight: 400; white-space: nowrap;
}

.eta {
  margin: 16px 0 0; padding-top: 14px; border-top: 1px solid var(--line);
  color: var(--dim); font-size: 13.5px;
}
.eta b { color: var(--ink); }
.steps li.is-active::before { background: var(--accent); animation: pulse 1.3s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.3; } }

@media (prefers-reduced-motion: reduce) {
  .bar.is-indeterminate > i, .steps li.is-active::before { animation: none; }
}

/* -- reveal + checkout ---------------------------------------------------- */
.price-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; flex-wrap: wrap; margin-top: 18px;
}
.price { font-size: 15px; color: var(--dim); }
.price b { color: var(--ink); font-size: 19px; font-weight: 650; }

.btn {
  appearance: none; border: 0; cursor: pointer;
  padding: 12px 22px; border-radius: 10px;
  background: var(--accent); color: var(--accent-ink);
  font: 600 15.5px/1 system-ui, -apple-system, sans-serif;
  transition: filter 140ms ease;
}
.btn:hover { filter: brightness(1.08); }
.btn:disabled { opacity: 0.5; cursor: default; }
.btn.secondary { background: #23232c; color: var(--ink); }

/* Optional "email me when it's ready" row on the working panel. Wraps to two
   lines on a phone rather than shrinking the input — this is the one field in
   the product and it is most often filled in on a phone. */
.notify-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; font-size: 14.5px;
}
.notify-input { display: flex; gap: 8px; flex: 1 1 260px; }
.notify-input input {
  flex: 1 1 auto; min-width: 0;
  appearance: none; border: 1px solid var(--line); border-radius: 10px;
  background: #0d0d11; color: var(--ink);
  padding: 11px 13px; font: 400 15px/1.2 system-ui, -apple-system, sans-serif;
}
/* 16px on small screens: anything smaller makes iOS Safari zoom the viewport on
   focus, and it does not zoom back out. */
@media (max-width: 520px) { .notify-input input { font-size: 16px; } }
.notify-input input:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent;
}
.notify-input .btn { padding: 11px 16px; font-size: 14.5px; white-space: nowrap; }
.notify-note { margin: 10px 0 0; font-size: 13px; }
.notify-note.bad { color: var(--bad); }
.dim { color: var(--dim); }

.chips { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 12px; }
.chip {
  font-size: 12.5px; color: var(--dim);
  border: 1px solid var(--line); border-radius: 999px; padding: 4px 10px;
}

.dl { display: grid; gap: 9px; margin-top: 14px; }
.dl a {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 13px 15px; border: 1px solid var(--line); border-radius: 10px;
  color: var(--ink); text-decoration: none; font-size: 14.5px;
  transition: border-color 140ms ease;
}
.dl a:hover { border-color: var(--accent); }
.dl .size { color: var(--dim); font-size: 12.5px; font-variant-numeric: tabular-nums; }

/* -- verdicts ------------------------------------------------------------- */
.verdict { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; }
.verdict .mark { flex: none; font-weight: 700; }
.verdict.ok .mark { color: var(--ok); }
.verdict.warn .mark { color: var(--warn); }
.verdict.bad .mark { color: var(--bad); }

/* Sits below the step list on the working panel, separated so it reads as an
   answer to "did my shoot work?" rather than as another progress line. */
.triage-early { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }

.reasons { margin: 12px 0 0; padding-left: 18px; color: var(--dim); font-size: 14px; }
.reasons li + li { margin-top: 5px; }
.reasons .span { font-variant-numeric: tabular-nums; color: #6f6f7a; }

.tips { margin: 14px 0 0; padding-left: 18px; font-size: 14px; color: var(--dim); }
.tips li + li { margin-top: 4px; }

/* -- banners -------------------------------------------------------------- */
.banner {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 15px; border-radius: 10px; font-size: 14px;
  border: 1px solid var(--line); background: #17171d; color: var(--dim);
  margin-bottom: 14px;
}
.banner.warn { border-color: #4a3c1c; background: #1d1810; color: #e5cf9d; }

/* -- recents -------------------------------------------------------------- */
.recents { margin-top: 26px; }
.recents h3 {
  margin: 0 0 9px; font-size: 12px; font-weight: 600; letter-spacing: 0.07em;
  text-transform: uppercase; color: var(--dim);
}
.recents ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.recents a {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 10px 13px; border: 1px solid var(--line); border-radius: 9px;
  color: var(--ink); text-decoration: none; font-size: 14px;
}
.recents a:hover { border-color: var(--accent); }
.recents .when { color: var(--dim); font-size: 12.5px; }

/* -- footer --------------------------------------------------------------- */
.foot {
  margin-top: 30px; text-align: center; color: #5f5f6a; font-size: 12.5px;
}
.foot a { color: #7a7a88; }
