/* ============================================================
   DeDupe Photos v2 — "midnight photo lab" design system.
   Animated, responsive, and fully disabled under
   prefers-reduced-motion.
   ============================================================ */

:root {
  --bg: #0a0d15;
  --bg-soft: #0e1320;
  --panel: rgba(255, 255, 255, 0.045);
  --panel-strong: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #f2f4f8;
  --muted: #9aa3b5;
  --muted-dim: #6b7488;
  --amber: #fbbf24;
  --amber-deep: #f59e0b;
  --violet: #a78bfa;
  --green: #34d399;
  --red: #f87171;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 0.6em; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); }
p { margin: 0 0 1em; }
a { color: var(--amber); }
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.wrap.narrow { max-width: 760px; }
.section { padding: 96px 0; position: relative; }
.eyebrow {
  text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.78rem;
  color: var(--amber); font-weight: 700; margin-bottom: 0.8em;
}
.section-lede { color: var(--muted); max-width: 640px; font-size: 1.08rem; }

.skip-link {
  position: absolute; left: -9999px; top: 0; background: var(--amber);
  color: #111; padding: 10px 16px; border-radius: 0 0 10px 0; z-index: 200;
}
.skip-link:focus { left: 0; }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(10, 13, 21, 0.78); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav-inner { max-width: 1120px; margin: 0 auto; padding: 14px 24px; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-weight: 800; font-size: 1.1rem; }
.brand em { font-style: normal; color: var(--amber); }
.brand-mark { position: relative; width: 30px; height: 30px; display: inline-block; }
.brand-mark .ring { position: absolute; border-radius: 50%; border: 3.5px solid; }
.brand-mark .r1 { width: 20px; height: 20px; left: 0; top: 4px; border-color: var(--amber); }
.brand-mark .r2 { width: 20px; height: 20px; left: 10px; top: 8px; border-color: var(--violet); opacity: 0.85; }
.nav-links { display: flex; gap: 22px; margin-left: auto; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 0.95rem; transition: color 0.2s; }
.nav-links a:hover { color: var(--text); }

/* ---------- buttons ---------- */
.btn {
  font: inherit; font-weight: 650; border: 1px solid transparent; cursor: pointer;
  border-radius: 999px; padding: 12px 24px; display: inline-flex; align-items: center; gap: 8px;
  transition: transform 0.18s var(--ease-out), box-shadow 0.18s, background 0.18s, border-color 0.18s;
  text-decoration: none; position: relative; overflow: hidden;
}
.btn:active { transform: scale(0.97); }
.btn .ic { width: 18px; height: 18px; }
.btn-primary {
  background: linear-gradient(135deg, var(--amber), var(--amber-deep)); color: #1a1206;
  box-shadow: 0 8px 24px rgba(251, 191, 36, 0.28);
}
.btn-primary:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(251, 191, 36, 0.38); }
.btn-secondary { background: var(--panel-strong); color: var(--text); border-color: var(--border-strong); }
.btn-secondary:hover:not(:disabled) { background: rgba(255,255,255,0.13); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--muted); border-color: var(--border); }
.btn-ghost:hover:not(:disabled) { color: var(--text); border-color: var(--border-strong); }
.btn-danger { background: linear-gradient(135deg, #ef4444, #dc2626); color: #fff; box-shadow: 0 8px 24px rgba(239, 68, 68, 0.3); }
.btn-danger:hover:not(:disabled) { transform: translateY(-2px); }
.btn-lg { padding: 15px 32px; font-size: 1.05rem; }
.btn-sm { padding: 8px 16px; font-size: 0.88rem; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
[data-premium] { border-style: dashed; }

/* ---------- hero ---------- */
.hero { position: relative; padding: 130px 0 70px; overflow: hidden; text-align: center; }
.hero-inner { position: relative; z-index: 2; max-width: 820px; margin: 0 auto; padding: 0 24px; }
.hero h1 { font-size: clamp(2.4rem, 6vw, 4.2rem); font-weight: 850; margin-bottom: 0.5em; }
.grad {
  background: linear-gradient(100deg, var(--amber) 10%, #fde68a 40%, var(--violet) 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lede { color: var(--muted); font-size: 1.18rem; max-width: 640px; margin: 0 auto 2em; }
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 2.2em; }
.hero-chips { list-style: none; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; padding: 0; margin: 0; }
.hero-chips li {
  display: flex; align-items: center; gap: 8px; font-size: 0.9rem; color: var(--muted);
  background: var(--panel); border: 1px solid var(--border); padding: 8px 16px; border-radius: 999px;
}
.chip-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); }

.orb { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.5; z-index: 0; animation: drift 16s ease-in-out infinite alternate; }
.orb-a { width: 480px; height: 480px; background: radial-gradient(circle, rgba(251,191,36,0.5), transparent 70%); top: -160px; left: -120px; }
.orb-b { width: 560px; height: 560px; background: radial-gradient(circle, rgba(167,139,250,0.42), transparent 70%); top: -80px; right: -160px; animation-delay: -6s; }
.orb-c { width: 420px; height: 420px; background: radial-gradient(circle, rgba(52,211,153,0.22), transparent 70%); bottom: -220px; left: 40%; animation-delay: -11s; }
@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(60px, 40px) scale(1.12); }
}

.hero-strip { margin-top: 70px; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.strip-track { display: flex; gap: 14px; width: max-content; animation: marquee 40s linear infinite; }
.strip-track img {
  width: 150px; height: 100px; object-fit: cover; border-radius: 12px;
  border: 1px solid var(--border); opacity: 0.85;
}
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- cards ---------- */
.card {
  background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow); position: relative;
}

/* ---------- demo ---------- */
.demo-stage { margin-top: 34px; overflow: hidden; }
.demo-controls { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.demo-hint { color: var(--muted-dim); font-size: 0.9rem; }

.scan-theater { margin-top: 26px; }
.theater-top { display: flex; align-items: center; gap: 26px; margin-bottom: 18px; flex-wrap: wrap; }
.pulse-ring { width: 74px; height: 74px; position: relative; flex: none; }
.pulse-ring span, .pulse-ring::before, .pulse-ring::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 3px solid var(--amber); animation: pulse 1.8s var(--ease-out) infinite;
}
.pulse-ring::before { animation-delay: 0.6s; }
.pulse-ring::after { animation-delay: 1.2s; }
.pulse-ring span { animation: none; inset: 22px; background: var(--amber); border: none; box-shadow: 0 0 24px var(--amber); }
@keyframes pulse {
  0% { transform: scale(0.35); opacity: 1; }
  100% { transform: scale(1.15); opacity: 0; }
}
.theater-stats { display: flex; gap: 34px; flex-wrap: wrap; }
.tstat { display: flex; flex-direction: column; }
.tstat-num { font-size: 2rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--text); }
.tstat-label { color: var(--muted); font-size: 0.85rem; }

.progress-track {
  height: 14px; border-radius: 999px; background: rgba(255,255,255,0.07);
  border: 1px solid var(--border); position: relative; overflow: hidden;
}
.progress-fill {
  height: 100%; width: 0%; border-radius: 999px;
  background: linear-gradient(90deg, var(--amber-deep), var(--amber), #fde68a);
  transition: width 0.25s var(--ease-out);
  box-shadow: 0 0 18px rgba(251, 191, 36, 0.55);
}
.progress-shimmer {
  position: absolute; inset: 0; border-radius: 999px;
  background: linear-gradient(100deg, transparent 30%, rgba(255,255,255,0.35) 50%, transparent 70%);
  background-size: 200% 100%; animation: shimmer 1.6s linear infinite; pointer-events: none;
}
@keyframes shimmer { from { background-position: 180% 0; } to { background-position: -80% 0; } }

.demo-result { margin-top: 8px; }

/* ---------- groups & thumbnails ---------- */
.groups-summary {
  display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap;
  margin: 18px 0 6px; padding: 14px 18px;
  background: rgba(52, 211, 153, 0.08); border: 1px solid rgba(52, 211, 153, 0.3);
  border-radius: var(--radius-sm);
  animation: slideDown 0.5s var(--ease-out);
}
@keyframes slideDown { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: none; } }
.groups-summary strong { font-size: 1.15rem; }

.group {
  border: 1px solid var(--border); border-radius: var(--radius); padding: 20px;
  margin-top: 18px; background: rgba(255,255,255,0.025);
  opacity: 0; transform: translateY(24px) scale(0.99);
  animation: groupIn 0.55s var(--ease-out) forwards;
  animation-delay: calc(var(--i, 0) * 90ms);
  transition: border-color 0.25s;
}
.group:hover { border-color: var(--border-strong); }
@keyframes groupIn { to { opacity: 1; transform: none; } }
.group.regrouping-out { animation: groupOut 0.18s ease-in forwards; }
@keyframes groupOut { to { opacity: 0; transform: translateY(10px) scale(0.99); } }

.group-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.group-title { font-weight: 750; font-size: 1.05rem; }
.badge {
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px; border: 1px solid;
}
.badge.exact { color: var(--green); border-color: rgba(52,211,153,0.5); background: rgba(52,211,153,0.1); }
.badge.near { color: var(--amber); border-color: rgba(251,191,36,0.5); background: rgba(251,191,36,0.1); }
.group-head .spacer { flex: 1; }
.group-size-note { color: var(--muted-dim); font-size: 0.85rem; }

.thumb-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); gap: 12px;
}
.thumb-card {
  position: relative; border-radius: var(--radius-sm); overflow: hidden;
  border: 2px solid transparent; background: #11151f; cursor: pointer;
  opacity: 0; transform: translateY(18px) scale(0.94);
  animation: thumbIn 0.5s var(--ease-out) forwards;
  animation-delay: calc(var(--i, 0) * 70ms + 120ms);
  transition: border-color 0.2s, transform 0.2s var(--ease-out), box-shadow 0.2s;
  padding: 0;
}
.thumb-card:nth-child(1) { --i: 0; } .thumb-card:nth-child(2) { --i: 1; }
.thumb-card:nth-child(3) { --i: 2; } .thumb-card:nth-child(4) { --i: 3; }
.thumb-card:nth-child(5) { --i: 4; } .thumb-card:nth-child(n+6) { --i: 5; }
@keyframes thumbIn { to { opacity: 1; transform: none; } }
.thumb-card:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(0,0,0,0.5); }
.thumb-card:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; }
.thumb-card img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; }
.thumb-card .thumb-meta {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 8px 6px;
  background: linear-gradient(transparent, rgba(0,0,0,0.82));
  font-size: 0.72rem; color: #d7dce6; text-align: left;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  pointer-events: none;
}
.expand-btn {
  position: absolute; bottom: 8px; right: 8px; z-index: 3;
  width: 30px; height: 30px; border-radius: 9px; border: 1px solid var(--border-strong);
  background: rgba(0,0,0,0.6); color: #fff; font-size: 15px; cursor: pointer;
  display: grid; place-items: center; opacity: 0; transform: translateY(4px);
  transition: opacity 0.2s, transform 0.2s var(--ease-out), background 0.2s;
}
.thumb-card:hover .expand-btn, .thumb-card:focus-within .expand-btn { opacity: 1; transform: none; }
.expand-btn:hover { background: rgba(0,0,0,0.85); }
.thumb-card.selected { border-color: var(--red); }
.thumb-card.selected::after {
  content: ""; position: absolute; inset: 0; background: rgba(248, 113, 113, 0.16); pointer-events: none;
}
.keep-badge {
  position: absolute; top: 8px; left: 8px; z-index: 2;
  background: linear-gradient(135deg, var(--green), #10b981); color: #04120c;
  font-size: 0.7rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase;
  padding: 4px 9px; border-radius: 999px; box-shadow: 0 4px 12px rgba(0,0,0,0.4);
  animation: badgePop 0.45s var(--ease-out) 0.35s backwards;
}
@keyframes badgePop { from { transform: scale(0.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.select-box {
  position: absolute; top: 8px; right: 8px; z-index: 2; width: 26px; height: 26px;
  border-radius: 8px; border: 2px solid rgba(255,255,255,0.65); background: rgba(0,0,0,0.45);
  display: grid; place-items: center; color: #fff; font-size: 15px; font-weight: 800;
  transition: background 0.18s, border-color 0.18s, transform 0.18s var(--ease-out);
}
.thumb-card.selected .select-box { background: var(--red); border-color: var(--red); transform: scale(1.12); }
.select-box::before { content: "✓"; opacity: 0; transform: scale(0.4); transition: opacity 0.15s, transform 0.2s var(--ease-out); }
.thumb-card.selected .select-box::before { opacity: 1; transform: scale(1); }

/* ---------- intake ---------- */
.intake-card { margin-top: 26px; padding: 0; overflow: hidden; }
.dropzone {
  padding: 54px 30px; text-align: center; cursor: pointer;
  border: 2px dashed transparent; border-radius: var(--radius);
  transition: background 0.25s, border-color 0.25s, transform 0.25s var(--ease-out);
}
.dropzone:hover { background: rgba(255,255,255,0.03); }
.dropzone:focus-visible { outline: 2px solid var(--amber); outline-offset: -2px; }
.dropzone.drag-over {
  background: rgba(251, 191, 36, 0.07); border-color: var(--amber);
  transform: scale(1.01);
}
.dropzone.drag-over .dz-icon { transform: translateY(-6px) scale(1.08); color: var(--amber); }
.dz-icon { width: 64px; height: 64px; margin: 0 auto 14px; color: var(--muted); transition: transform 0.25s var(--ease-out), color 0.25s; }
.dz-icon svg { width: 100%; height: 100%; }
.dz-title { font-size: 1.35rem; font-weight: 750; margin-bottom: 0.2em; }
.dz-sub { color: var(--muted-dim); margin-bottom: 1em; }
.dz-buttons { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 1.2em; }
.dz-note { color: var(--muted-dim); font-size: 0.88rem; margin: 0; }
.browser-note {
  margin: 0; padding: 14px 28px; font-size: 0.9rem; color: var(--muted);
  background: rgba(167, 139, 250, 0.08); border-top: 1px solid var(--border);
}

.resume-banner {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  background: rgba(251, 191, 36, 0.08); border: 1px solid rgba(251, 191, 36, 0.35);
  border-radius: var(--radius-sm); padding: 16px 20px; margin-top: 26px;
  animation: slideDown 0.5s var(--ease-out);
}
.resume-icon { font-size: 1.8rem; color: var(--amber); animation: spin 2.4s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.resume-text { flex: 1; min-width: 200px; }
.resume-text span { display: block; color: var(--muted); font-size: 0.9rem; }
.resume-actions { display: flex; gap: 10px; }

/* ---------- scanning ---------- */
.scan-card { margin-top: 26px; }
.scan-grid { display: flex; gap: 34px; align-items: center; flex-wrap: wrap; }
.ring-wrap { position: relative; width: 160px; height: 160px; flex: none; }
.ring { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 12; stroke-linecap: round; }
.ring-bg { stroke: rgba(255,255,255,0.08); }
.ring-fg {
  stroke: url(#ringGrad); stroke: var(--amber);
  stroke-dasharray: 427.3; stroke-dashoffset: 427.3;
  transition: stroke-dashoffset 0.3s var(--ease-out);
  filter: drop-shadow(0 0 8px rgba(251,191,36,0.6));
}
.ring-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ring-pct { font-size: 1.9rem; font-weight: 850; font-variant-numeric: tabular-nums; }
.ring-sub { color: var(--muted-dim); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em; }
.scan-info { flex: 1; min-width: 240px; }
.scan-info h3 { margin-bottom: 0.3em; }
.scan-current { color: var(--muted); font-size: 0.92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 420px; }
.scan-current::after { content: "…"; animation: dots 1.2s steps(4) infinite; }
@keyframes dots { 0% { content: ""; } 33% { content: "."; } 66% { content: ".."; } 100% { content: "..."; } }
.scan-stats { display: flex; gap: 30px; flex-wrap: wrap; margin: 18px 0; }
.sstat { display: flex; flex-direction: column; }
.sstat-num { font-size: 1.7rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--amber); transition: transform 0.2s; }
.sstat-num.tick { animation: tickPop 0.3s var(--ease-out); }
@keyframes tickPop { 40% { transform: scale(1.18); } }
.sstat-label { color: var(--muted); font-size: 0.82rem; }
.scan-actions { display: flex; gap: 10px; }

.skipped-details { margin-top: 22px; border-top: 1px solid var(--border); padding-top: 16px; }
.skipped-details summary { cursor: pointer; color: var(--muted); font-weight: 600; }
.skipped-list { list-style: none; padding: 0; margin: 12px 0 0; max-height: 220px; overflow: auto; display: flex; flex-direction: column; gap: 8px; }
.skipped-list li {
  font-size: 0.88rem; color: var(--muted); background: rgba(255,255,255,0.03);
  border: 1px solid var(--border); border-radius: 10px; padding: 8px 12px;
  animation: slideDown 0.3s var(--ease-out);
}
.skipped-list li strong { color: var(--text); font-weight: 600; }

/* ---------- results ---------- */
.recovery-banner {
  margin-top: 26px; display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
  background: linear-gradient(120deg, rgba(251,191,36,0.12), rgba(167,139,250,0.08));
  border-color: rgba(251, 191, 36, 0.35); overflow: hidden; position: relative;
}
.recovery-banner::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 40%, rgba(255,255,255,0.06) 50%, transparent 60%);
  background-size: 220% 100%; animation: shimmer 3.2s linear infinite; pointer-events: none;
}
.recovery-icon { width: 54px; height: 54px; color: var(--amber); flex: none; }
.recovery-icon svg { width: 100%; height: 100%; }
.recovery-text { flex: 1; min-width: 220px; }
.recovery-label { color: var(--muted); font-size: 0.9rem; margin: 0; }
.recovery-amount {
  font-size: clamp(2rem, 5vw, 3rem); font-weight: 850; margin: 0;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(100deg, var(--amber), #fde68a);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.recovery-sub { color: var(--muted-dim); font-size: 0.88rem; margin: 0.2em 0 0; }
.recovery-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.toolbar { margin-top: 18px; display: flex; gap: 26px; align-items: center; flex-wrap: wrap; padding: 20px 28px; }
.slider-block { flex: 1; min-width: 260px; }
.slider-title { font-weight: 700; display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.sim-badge {
  background: var(--amber); color: #1a1206; font-size: 0.8rem; font-weight: 800;
  min-width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center;
  transition: transform 0.2s var(--ease-out);
}
.sim-badge.bump { animation: tickPop 0.3s var(--ease-out); }
input[type="range"]#similarity {
  width: 100%; appearance: none; -webkit-appearance: none; height: 10px; border-radius: 999px;
  background: linear-gradient(90deg, var(--green), var(--amber) 50%, var(--red));
  outline-offset: 4px; cursor: pointer;
}
input[type="range"]#similarity::-webkit-slider-thumb {
  -webkit-appearance: none; width: 26px; height: 26px; border-radius: 50%;
  background: #fff; border: 3px solid var(--amber); box-shadow: 0 4px 14px rgba(0,0,0,0.5);
  transition: transform 0.15s var(--ease-out);
}
input[type="range"]#similarity::-webkit-slider-thumb:hover { transform: scale(1.15); }
input[type="range"]#similarity::-moz-range-thumb {
  width: 22px; height: 22px; border-radius: 50%;
  background: #fff; border: 3px solid var(--amber); box-shadow: 0 4px 14px rgba(0,0,0,0.5);
}
.slider-desc { color: var(--muted); font-size: 0.88rem; margin: 6px 0 0; min-height: 1.4em; }
.toolbar-meta { display: flex; align-items: center; gap: 14px; color: var(--muted); font-size: 0.9rem; }

/* ---------- staged ---------- */
#staged-view { margin-top: 26px; }
.staged-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.staged-head h3 { margin-bottom: 0.2em; }
.staged-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; max-height: 420px; overflow: auto; }
.staged-list li {
  display: flex; align-items: center; gap: 14px; padding: 10px 14px;
  background: rgba(255,255,255,0.03); border: 1px solid var(--border); border-radius: var(--radius-sm);
  animation: slideDown 0.35s var(--ease-out);
}
.staged-list img { width: 52px; height: 52px; object-fit: cover; border-radius: 8px; flex: none; }
.staged-list .sname { font-weight: 600; font-size: 0.92rem; word-break: break-all; }
.staged-list .spath { color: var(--muted-dim); font-size: 0.8rem; word-break: break-all; }
.staged-list .ssize { margin-left: auto; color: var(--muted); font-size: 0.88rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.staged-list .unstage {
  flex: none; background: transparent; border: 1px solid var(--border); color: var(--muted);
  border-radius: 8px; padding: 6px 10px; cursor: pointer; font: inherit; font-size: 0.82rem;
  transition: color 0.2s, border-color 0.2s;
}
.staged-list .unstage:hover { color: var(--text); border-color: var(--border-strong); }
.staged-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--border); }
.staged-total { font-size: 1.05rem; }
.staged-total strong { color: var(--amber); font-variant-numeric: tabular-nums; }

/* ---------- modal ---------- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 150; display: grid; place-items: center; padding: 20px;
  background: rgba(4, 6, 10, 0.72); backdrop-filter: blur(6px);
  animation: fadeIn 0.25s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } }
.modal {
  width: min(560px, 100%); max-height: 86vh; overflow: auto;
  background: #121724; border: 1px solid var(--border-strong); border-radius: var(--radius);
  padding: 30px; box-shadow: var(--shadow);
  animation: modalIn 0.35s var(--ease-out);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(26px) scale(0.97); } }
.modal h3 { font-size: 1.4rem; }
.modal-list { list-style: none; padding: 0; margin: 0 0 18px; max-height: 240px; overflow: auto; display: flex; flex-direction: column; gap: 8px; }
.modal-list li { display: flex; gap: 10px; align-items: center; font-size: 0.88rem; color: var(--muted); background: rgba(255,255,255,0.03); border: 1px solid var(--border); padding: 8px 12px; border-radius: 10px; }
.modal-list img { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; flex: none; }
.confirm-check {
  display: flex; gap: 12px; align-items: flex-start; cursor: pointer;
  background: rgba(248, 113, 113, 0.07); border: 1px solid rgba(248, 113, 113, 0.3);
  border-radius: var(--radius-sm); padding: 14px 16px; margin-bottom: 20px; font-size: 0.94rem;
}
.confirm-check input { width: 22px; height: 22px; margin-top: 2px; accent-color: var(--red); flex: none; cursor: pointer; }
.modal-actions { display: flex; gap: 12px; justify-content: flex-end; flex-wrap: wrap; }

/* ---------- log / done ---------- */
#log-view { margin-top: 26px; }
.log-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }
.log-head h3 { margin: 0; }
.log-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.done-celebration { text-align: center; padding: 26px 10px 10px; }
.check-burst { width: 84px; height: 84px; margin: 0 auto 12px; color: var(--green); animation: badgePop 0.6s var(--ease-out); }
.check-burst svg { width: 100%; height: 100%; filter: drop-shadow(0 0 18px rgba(52,211,153,0.5)); }
.done-celebration h4 { font-size: 1.5rem; margin-bottom: 0.2em; }
.recovered-line { color: var(--muted); font-size: 1.1rem; }
.recovered-line strong { color: var(--green); font-variant-numeric: tabular-nums; }
.manual-notice {
  background: rgba(167, 139, 250, 0.09); border: 1px solid rgba(167, 139, 250, 0.35);
  border-radius: var(--radius-sm); padding: 14px 18px; margin-bottom: 16px; font-size: 0.94rem;
  animation: slideDown 0.4s var(--ease-out);
}
.deletion-log { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; max-height: 440px; overflow: auto; }
.deletion-log li {
  display: flex; gap: 12px; align-items: center; font-size: 0.9rem;
  background: rgba(255,255,255,0.03); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 14px;
  animation: slideDown 0.3s var(--ease-out);
}
.deletion-log img { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; flex: none; }
.outcome { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 4px 10px; border-radius: 999px; flex: none; }
.outcome.deleted { color: var(--green); background: rgba(52,211,153,0.12); border: 1px solid rgba(52,211,153,0.4); }
.outcome.failed { color: var(--red); background: rgba(248,113,113,0.12); border: 1px solid rgba(248,113,113,0.4); }
.outcome.not-deleted { color: var(--violet); background: rgba(167,139,250,0.12); border: 1px solid rgba(167,139,250,0.4); }
.deletion-log .lname { font-weight: 600; word-break: break-all; }
.deletion-log .lnote { color: var(--muted-dim); font-size: 0.82rem; }

/* ---------- empty state ---------- */
.empty-state { margin-top: 26px; text-align: center; padding: 60px 30px; }
.empty-art { width: 110px; height: 110px; margin: 0 auto 18px; color: var(--muted-dim); animation: floaty 4s ease-in-out infinite; }
.empty-art svg { width: 100%; height: 100%; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ---------- privacy / faq / footer ---------- */
.privacy-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; margin-top: 30px; }
.privacy-card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; transition: transform 0.25s var(--ease-out), border-color 0.25s; }
.privacy-card:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.privacy-card h3 { color: var(--amber); font-size: 1.05rem; }
.privacy-card p { color: var(--muted); margin: 0; font-size: 0.95rem; }

.faq-item { background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 12px; overflow: hidden; }
.faq-item summary { cursor: pointer; padding: 18px 22px; font-weight: 650; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.faq-item summary::after { content: "+"; font-size: 1.4rem; color: var(--amber); transition: transform 0.25s var(--ease-out); flex: none; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { padding: 0 22px 20px; margin: 0; color: var(--muted); }

.footer { border-top: 1px solid var(--border); padding: 34px 0; margin-top: 40px; }
.footer-inner { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.footer-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.footer-inner .small { margin: 0; flex: 1; min-width: 200px; }

/* ---------- lightbox ---------- */
.lightbox-backdrop {
  position: fixed; inset: 0; z-index: 160; display: grid; place-items: center; padding: 24px;
  background: rgba(4, 6, 10, 0.88); backdrop-filter: blur(8px); animation: fadeIn 0.25s ease-out;
}
.lightbox { position: relative; max-width: min(860px, 94vw); animation: modalIn 0.35s var(--ease-out); }
.lightbox img { max-width: 100%; max-height: 76vh; border-radius: var(--radius-sm); border: 1px solid var(--border-strong); display: block; box-shadow: var(--shadow); }
.lightbox-close {
  position: absolute; top: -14px; right: -14px; width: 40px; height: 40px; border-radius: 50%;
  background: var(--panel-strong); border: 1px solid var(--border-strong); color: var(--text);
  font-size: 1rem; cursor: pointer; transition: transform 0.2s var(--ease-out);
}
.lightbox-close:hover { transform: scale(1.1); }
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%); width: 46px; height: 46px; border-radius: 50%;
  background: rgba(0,0,0,0.55); border: 1px solid var(--border-strong); color: #fff;
  font-size: 1.5rem; cursor: pointer; transition: background 0.2s;
}
.lightbox-nav:hover { background: rgba(0,0,0,0.8); }
.lightbox-nav.prev { left: -58px; } .lightbox-nav.next { right: -58px; }
.lightbox-meta { text-align: center; color: var(--muted); font-size: 0.9rem; margin-top: 12px; }

/* ---------- toasts ---------- */
.toast-region { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 10px; align-items: center; pointer-events: none; width: min(480px, 92vw); }
.toast {
  background: #161c2b; border: 1px solid var(--border-strong); color: var(--text);
  padding: 13px 20px; border-radius: 999px; font-size: 0.92rem; box-shadow: var(--shadow);
  animation: toastIn 0.35s var(--ease-out); max-width: 100%;
}
.toast.success { border-color: rgba(52,211,153,0.5); }
.toast.error { border-color: rgba(248,113,113,0.5); }
@keyframes toastIn { from { opacity: 0; transform: translateY(16px) scale(0.96); } }
.toast.leaving { animation: fadeOut 0.3s ease-in forwards; }
@keyframes fadeOut { to { opacity: 0; transform: translateY(10px); } }

/* ---------- responsive ---------- */
@media (max-width: 760px) {
  .section { padding: 64px 0; }
  .nav-links { display: none; }
  .scan-grid { gap: 22px; }
  .toolbar { padding: 18px; }
  .recovery-banner { padding: 22px; }
  .lightbox-nav.prev { left: 6px; } .lightbox-nav.next { right: 6px; }
  .theater-stats { gap: 20px; }
  .tstat-num { font-size: 1.5rem; }
}

/* ---------- reduced motion: everything still ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .group, .thumb-card { opacity: 1; transform: none; }
  .orb, .strip-track, .progress-shimmer, .pulse-ring span, .pulse-ring::before, .pulse-ring::after,
  .recovery-banner::before, .resume-icon, .empty-art, .scan-current::after { display: none; }
  .scan-current::after { content: ""; }
}
