:root {
  --bg: #0A0A0F;
  --bg-elev: #121218;
  --bg-elev-2: #1A1A24;
  --bg-elev-3: #22222E;
  --fg: #F5F5F7;
  --fg-dim: #9A9AA6;
  --fg-mute: #686875;
  --accent: #22C55E;                           /* rickylaserart.com primary green (green-500) */
  --accent-hover: #4ADE80;                     /* lighter hover (green-400) */
  --accent-dim: #16A34A;                       /* shadow / pressed (green-600) */
  --accent-ink: #052E16;                       /* dark forest text on accent bg - WCAG AA */
  --accent-glow: rgba(34, 197, 94, 0.35);
  --accent-glow-soft: rgba(34, 197, 94, 0.14);
  --border: #22222E;
  --border-strong: #2E2E3C;
  --error: #FF4A4A;
  --warning: #FFB800;
  --success: #4ADE80;
  --radius: 14px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --font-display: 'Instrument Sans', ui-sans-serif, system-ui, sans-serif;
  --font-body: 'Inter', ui-sans-serif, system-ui, sans-serif;
  --max-w: 1180px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; }
html { background: var(--bg); color-scheme: dark; }
body {
  background:
    radial-gradient(ellipse 85% 55% at 50% -8%, rgba(34, 197, 94, 0.18), transparent 62%),
    radial-gradient(ellipse 60% 45% at 92% 108%, rgba(13, 77, 63, 0.28), transparent 72%),
    linear-gradient(180deg, #06100A 0%, #0A0F0C 60%, #080B09 100%);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  position: relative;
}

/* mouse-following radial glow, lerp-smoothed via JS writing --mx/--my on <body> */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(
    circle 720px at var(--mx, 50%) var(--my, 50%),
    rgba(34, 197, 94, 0.22) 0%,
    rgba(13, 77, 63, 0.14) 35%,
    transparent 70%
  );
  mix-blend-mode: screen;
  will-change: background;
}

/* content stays above the mouse glow */
.site-header, .site-main, .site-footer { position: relative; z-index: 1; }

@media (hover: none), (prefers-reduced-motion: reduce) {
  body::before { display: none; }
}

a { color: var(--fg); text-decoration: none; transition: color 180ms var(--ease); }
a:hover { color: var(--accent); }
button { font-family: inherit; }

::selection { background: var(--accent); color: #fff; }

/* ---------- header ---------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 40px;
  min-height: 100px;
  max-width: var(--max-w);
  width: 100%;
  margin: 0 auto;
  gap: 24px;
}
/* visually hidden text for screen readers and crawlers */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* header brand (inline SVG wordmark with animated dot) */
/* header brand: "polyline." wordmark + "DXF Doctor by RickyLaserArt" positioning subtitle */
.brand-logo {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  text-decoration: none;
  transition: opacity 180ms var(--ease);
}
.brand-logo:hover { opacity: 0.9; }
.brand-wordmark {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 36px;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--fg);
  display: inline-flex;
  align-items: baseline;
}
.brand-text { color: var(--fg); }
.brand-dot {
  display: inline-block;
  color: var(--accent);
  transform-origin: center;
  --hb-glow: 6px;
  animation: heartbeat 1.4s ease-in-out infinite;
}
.brand-subtitle {
  font-family: var(--font-body);
  font-size: 11px;
  color: #9CA3AF;
  letter-spacing: 0.1em;
  line-height: 1.2;
  margin-top: 3px;
  text-transform: uppercase;
  font-weight: 500;
}
.brand-byline { color: #6B7280; }
.site-nav {
  display: flex;
  gap: 30px;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--fg-dim);
}
.site-nav a {
  color: var(--fg-dim);
  transition: color 200ms var(--ease);
}
.site-nav a:hover { color: var(--accent); }
.site-nav a.current {
  color: var(--accent);
}

/* ---------- main ---------- */
.site-main {
  flex: 1;
  max-width: var(--max-w);
  width: 100%;
  margin: 0 auto;
  padding: 48px 32px 96px;
}

/* ---------- hero ---------- */
.hero { text-align: center; animation: fadeUp 700ms var(--ease) both; }
.hero-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(64px, 11vw, 148px);
  letter-spacing: -0.045em;
  margin: 24px 0 20px;
  line-height: 0.95;
  background: linear-gradient(180deg, var(--fg) 0%, #8E8E99 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-title .hero-dot {
  display: inline-block;
  width: 0.14em;
  height: 0.14em;
  background: var(--accent);
  border-radius: 50%;
  margin-left: 0.05em;
  vertical-align: 0.06em;
  transform-origin: center;
  --hb-glow: 14px;
  animation: heartbeat 1.4s ease-in-out infinite;
}

/* lub-dub ECG rhythm: strong beat at 15%, echo at 45%, long rest to 100%.
   drop-shadow works on both HTML and SVG elements so one keyframe serves both. */
@keyframes heartbeat {
  0%, 30%, 60%, 100% {
    transform: scale(1);
    filter: drop-shadow(0 0 0 rgba(34, 197, 94, 0));
  }
  15% {
    transform: scale(1.15);
    filter: drop-shadow(0 0 var(--hb-glow, 12px) rgba(34, 197, 94, 0.65));
  }
  45% {
    transform: scale(1.1);
    filter: drop-shadow(0 0 calc(var(--hb-glow, 12px) * 0.67) rgba(34, 197, 94, 0.5));
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-title .hero-dot,
  #header-logo-dot { animation: none; }
}
.hero-sub {
  font-size: 18px;
  color: var(--fg-dim);
  max-width: 580px;
  margin: 0 auto 56px;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- drop zone ---------- */
.tool-shell {
  max-width: 920px;
  margin: 0 auto;
}
.drop-zone {
  position: relative;
  border: 2px dashed var(--border-strong);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--bg-elev) 0%, var(--bg-elev-2) 100%);
  padding: 72px 24px;
  cursor: pointer;
  transition:
    border-color 220ms var(--ease),
    background 220ms var(--ease),
    transform 220ms var(--ease),
    box-shadow 220ms var(--ease);
  outline: none;
}
.drop-zone:hover,
.drop-zone:focus-visible {
  border-color: var(--accent);
  box-shadow: 0 0 0 6px var(--accent-glow-soft);
}
.drop-zone.drag-over {
  border-color: var(--accent);
  background: linear-gradient(180deg, var(--bg-elev-2) 0%, var(--bg-elev-3) 100%);
  box-shadow: 0 0 0 10px var(--accent-glow);
  transform: scale(1.015);
}
.drop-zone.busy {
  pointer-events: none;
  opacity: 0.6;
}
.drop-inner {
  text-align: center;
  color: var(--fg-dim);
}
.drop-icon-svg {
  width: 48px;
  height: 48px;
  color: var(--accent);
  margin: 0 auto 16px;
  display: block;
  filter: drop-shadow(0 6px 18px var(--accent-glow));
  transition: transform 220ms var(--ease);
}
.drop-zone:hover .drop-icon-svg,
.drop-zone.drag-over .drop-icon-svg {
  transform: translateY(-4px);
}
.drop-label {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--fg);
  margin: 0 0 6px;
}
.drop-hint {
  font-size: 13px;
  color: var(--fg-mute);
  margin: 0;
}
.drop-accepted-types {
  margin-top: 14px;
  font-size: 11px;
  color: var(--fg-mute);
  letter-spacing: 0.02em;
}
.type-tag {
  display: inline-block;
  padding: 2px 10px;
  background: rgba(34, 197, 94, 0.1);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  margin: 0 2px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ---------- progress steps ---------- */
.progress {
  max-width: 720px;
  margin: 32px auto 0;
}
.progress-steps {
  display: flex;
  justify-content: center;
  gap: 32px;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 14px;
  color: var(--fg-mute);
  flex-wrap: wrap;
}
.progress-steps li {
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0.4;
  transition: opacity 280ms var(--ease), color 280ms var(--ease);
}
.progress-steps li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border-strong);
  transition: background 280ms var(--ease), box-shadow 280ms var(--ease);
}
.progress-steps li.active {
  opacity: 1;
  color: var(--fg);
}
.progress-steps li.active::before {
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow-soft);
  animation: pulseDot 1.2s var(--ease) infinite;
}
.progress-steps li.done {
  opacity: 0.85;
  color: var(--fg-dim);
}
.progress-steps li.done::before {
  background: var(--success);
  box-shadow: none;
  animation: none;
}
@keyframes pulseDot {
  0%, 100% { box-shadow: 0 0 0 4px var(--accent-glow-soft); }
  50%      { box-shadow: 0 0 0 10px rgba(34, 197, 94, 0.08); }
}

/* ---------- error panel ---------- */
.error-panel {
  max-width: 720px;
  margin: 32px auto 0;
  padding: 16px 20px;
  background: rgba(255, 74, 74, 0.08);
  border: 1px solid rgba(255, 74, 74, 0.3);
  border-radius: var(--radius-sm);
  color: #FFB4B4;
  font-size: 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.error-panel strong { color: var(--error); }

/* ---------- report card ---------- */
.result {
  margin-top: 40px;
  animation: fadeUp 500ms var(--ease) both;
}
.report-card {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}
.report-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
}
.report-eyebrow {
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-weight: 500;
  margin: 0 0 6px;
}
.report-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 0 0 4px;
  word-break: break-all;
}
.report-sub {
  font-size: 13px;
  color: var(--fg-mute);
  margin: 0;
  font-variant-numeric: tabular-nums;
}

/* success check */
.success-check {
  width: 44px;
  height: 44px;
  color: var(--success);
  flex-shrink: 0;
}
.success-check svg { width: 100%; height: 100%; }
.success-ring {
  stroke-dasharray: 126;
  stroke-dashoffset: 126;
  animation: ringDraw 500ms var(--ease) 50ms forwards;
}
.success-tick {
  stroke-dasharray: 36;
  stroke-dashoffset: 36;
  animation: tickDraw 350ms var(--ease) 400ms forwards;
}
@keyframes ringDraw { to { stroke-dashoffset: 0; } }
@keyframes tickDraw { to { stroke-dashoffset: 0; } }

/* stat grid */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}
.stat {
  background: var(--bg-elev-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-label {
  font-size: 12px;
  color: var(--fg-mute);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.stat-value {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.stat-open { color: var(--warning); }
.stat-error { color: var(--error); }
.stat-warn { color: var(--warning); }

/* chips */
.chips-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.16) 0%, rgba(34, 197, 94, 0.06) 100%);
  border: 1px solid rgba(74, 222, 128, 0.28);
  border-radius: 999px;
  font-size: 12px;
  color: #CDEBD6;
  font-variant-numeric: tabular-nums;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.chip strong { color: #ECFBF1; font-weight: 500; }

/* entity-type glow (keeps inset highlight; outer halo pulses by type) */
@keyframes chipGlow {
  0%, 100% { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 0 0 0 rgba(0, 0, 0, 0); }
  50%      { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 0 12px 2px var(--chip-glow, transparent); }
}
.chip--polyline,
.chip--spline,
.chip--hatch,
.chip--line,
.chip--other {
  animation: chipGlow 2.5s ease-in-out infinite;
}
.chip--polyline { --chip-glow: rgba(34, 197, 94, 0.5); }
.chip--spline   { --chip-glow: rgba(234, 179, 8, 0.5); }
.chip--hatch    { --chip-glow: rgba(249, 115, 22, 0.5); }
.chip--line     { --chip-glow: rgba(59, 130, 246, 0.5); }
.chip--other    { --chip-glow: rgba(154, 154, 166, 0.4); }

@media (prefers-reduced-motion: reduce) {
  .chip--polyline,
  .chip--spline,
  .chip--hatch,
  .chip--line,
  .chip--other { animation: none; }
}

.bbox-row {
  font-size: 12px;
  color: var(--fg-mute);
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
  font-variant-numeric: tabular-nums;
}

/* CTA row */
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 10px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: 15px;
  border: none;
  cursor: pointer;
  transition:
    transform 200ms var(--ease),
    box-shadow 200ms var(--ease),
    background 200ms var(--ease);
}
.btn-primary:hover {
  background: var(--accent-hover);
  color: var(--accent-ink);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px var(--accent-glow);
}
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled { opacity: 0.5; cursor: default; transform: none; box-shadow: none; }
.btn-icon { width: 16px; height: 16px; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 11px 18px;
  border-radius: 10px;
  background: transparent;
  color: var(--fg-dim);
  border: 1px solid var(--border-strong);
  font-size: 14px;
  cursor: pointer;
  transition:
    color 180ms var(--ease),
    border-color 180ms var(--ease),
    background 180ms var(--ease);
}
.btn-ghost:hover {
  color: var(--fg);
  border-color: var(--fg-mute);
  background: var(--bg-elev-2);
}

/* format picker */
.format-select {
  display: flex;
  gap: 6px;
  background: var(--bg-elev-2);
  padding: 4px;
  border-radius: 10px;
  border: 1px solid var(--border);
}
.format-select label {
  display: inline-flex;
  flex-direction: column;
  padding: 6px 12px;
  border-radius: 7px;
  cursor: pointer;
  font-size: 12px;
  color: var(--fg-dim);
  transition: background 180ms var(--ease), color 180ms var(--ease);
}
.format-select label small {
  font-size: 10px;
  color: var(--fg-mute);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.format-select input { display: none; }
.format-select label:has(input:checked) {
  background: var(--bg-elev-3);
  color: var(--fg);
}
.format-select label:has(input:checked) small { color: var(--accent); }

/* ---------- preview canvases ---------- */
.preview-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 28px;
}
@media (min-width: 980px) {
  .preview-grid.two-up {
    grid-template-columns: 1fr 1fr;
  }
}
.preview-pane {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  animation: fadeUp 400ms var(--ease) both;
}
.preview-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}
.preview-tag {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--bg-elev-2);
  color: var(--fg-dim);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
}
.preview-tag-ok {
  background: rgba(74, 222, 128, 0.12);
  color: var(--success);
}
.preview-hint {
  font-size: 12px;
  color: var(--fg-mute);
}
.canvas-wrap {
  position: relative;
  background:
    linear-gradient(var(--border) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, var(--border) 1px, transparent 1px) 0 0 / 24px 24px,
    #0d0d14;
}
canvas {
  display: block;
  width: 100%;
  height: 460px;
  touch-action: none;
}

/* download button in After head */
.btn-download {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 13px;
  font-weight: 600;
  transition: background 180ms var(--ease), transform 180ms var(--ease), box-shadow 180ms var(--ease);
}
.btn-download:hover {
  background: var(--accent-hover);
  color: var(--accent-ink);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px var(--accent-glow);
}

/* marker tooltip */
.marker-tooltip {
  position: absolute;
  background: var(--bg-elev-3);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-xs);
  padding: 8px 12px;
  font-size: 12px;
  color: var(--fg);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  transform: translate(-50%, -110%);
  z-index: 10;
  white-space: nowrap;
}
.marker-tooltip strong { color: var(--accent); font-weight: 500; }
.marker-tooltip .mt-handle {
  color: var(--fg-mute);
  margin-left: 8px;
  font-variant-numeric: tabular-nums;
}

/* ---------- SEO pages ---------- */
.seo-hero {
  text-align: center;
  padding: 64px 0 32px;
  animation: fadeUp 600ms var(--ease) both;
}
.seo-hero h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(42px, 7vw, 76px);
  letter-spacing: -0.035em;
  margin: 0 0 20px;
  line-height: 1;
}
.lede {
  font-size: 18px;
  color: var(--fg-dim);
  max-width: 640px;
  margin: 0 auto 36px;
}
.seo-body {
  max-width: 760px;
  margin: 56px auto 0;
  color: var(--fg-dim);
  font-size: 16px;
}
.seo-body h2 {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--fg);
  margin: 48px 0 12px;
}
.seo-body h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 500;
  color: var(--fg);
  margin: 28px 0 8px;
}
.seo-body p { margin: 0 0 14px; }
.seo-body ul, .seo-body ol { padding-left: 20px; margin: 0 0 14px; }
.seo-body a { color: var(--accent); border-bottom: 1px solid rgba(34, 197, 94, 0.3); }
.seo-body a:hover { border-bottom-color: var(--accent); }

.faq {
  margin-top: 36px;
  border-top: 1px solid var(--border);
  padding-top: 32px;
}
.faq details {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  margin-bottom: 10px;
}
.faq summary {
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--fg);
  font-size: 16px;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq details[open] summary { color: var(--accent); }
.faq details p {
  margin: 10px 0 0;
  color: var(--fg-dim);
}

.internal-links {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.internal-links a {
  display: inline-flex;
  padding: 6px 14px;
  background: var(--bg-elev-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 13px;
  color: var(--fg-dim);
  border-bottom: none;
}
.internal-links a:hover { color: var(--fg); border-color: var(--accent); background: var(--bg-elev-3); }

/* ---------- celebration overlay ("DXF Healed") ---------- */
.celebration-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
  animation: celebFade 2.8s ease forwards;
}
@keyframes celebFade {
  0%   { opacity: 0; }
  15%  { opacity: 1; }
  80%  { opacity: 1; }
  100% { opacity: 0; }
}
.celebration-content {
  text-align: center;
  transform: scale(0.3);
  opacity: 0;
  animation: celebPop 2.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  padding: 0 24px;
}
@keyframes celebPop {
  0%   { transform: scale(0.3); opacity: 0; }
  15%  { transform: scale(1.1); opacity: 1; }
  25%  { transform: scale(1); }
  85%  { transform: scale(1); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0; }
}
.celebration-title {
  font-family: var(--font-display);
  font-size: 64px;
  font-weight: 800;
  color: #FFFFFF;
  margin: 0 0 12px;
  letter-spacing: -0.03em;
  line-height: 1;
  text-shadow:
    0 2px 20px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(34, 197, 94, 0.3);
}
.check-emoji {
  color: var(--accent);
  display: inline-block;
  margin-left: 8px;
  transform-origin: center;
  transform: scale(0) rotate(-45deg);
  opacity: 0;
  text-shadow: 0 0 20px rgba(34, 197, 94, 0.6);
  animation: checkEmojiPop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.3s forwards;
}
@keyframes checkEmojiPop {
  0%   { transform: scale(0) rotate(-45deg); opacity: 0; }
  60%  { transform: scale(1.3) rotate(10deg); opacity: 1; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}
.celebration-subtitle {
  font-family: var(--font-body);
  font-size: 22px;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
  font-weight: 400;
  letter-spacing: 0.01em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

@media (max-width: 720px) {
  .celebration-title { font-size: 42px; }
  .celebration-subtitle { font-size: 16px; padding: 0 24px; }
}

@media (prefers-reduced-motion: reduce) {
  .celebration-overlay,
  .celebration-content,
  .check-emoji {
    animation: none !important;
    opacity: 1;
    transform: none;
  }
}

/* ---------- file detail inspector modal ---------- */
.fd-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity 220ms ease;
}
.fd-overlay.is-open { opacity: 1; }

.fd-card {
  position: relative;
  width: 100%;
  max-width: 1100px;
  max-height: calc(100vh - 40px);
  background: linear-gradient(135deg, rgba(20, 20, 25, 0.95), rgba(10, 15, 10, 0.98));
  border: 1px solid rgba(34, 197, 94, 0.22);
  border-radius: 22px;
  box-shadow:
    0 24px 72px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.95) translateY(16px);
  opacity: 0;
  transition:
    transform 320ms cubic-bezier(0.34, 1.56, 0.64, 1),
    opacity 240ms ease;
}
.fd-overlay.is-open .fd-card { transform: scale(1) translateY(0); opacity: 1; }

.fd-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.2);
}
.fd-head-text { min-width: 0; }
.fd-filename {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 2px;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.fd-folder {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  margin: 0;
}

.fd-body {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 0;
  min-height: 0;
  flex: 1;
}

.fd-preview {
  position: relative;
  padding: 20px;
  background: #0A0F0C;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  flex-direction: column;
}
.fd-preview .canvas-wrap {
  flex: 1;
  min-height: 300px;
  border-radius: 14px;
  overflow: hidden;
}
.fd-preview canvas { height: 100%; min-height: 300px; }
.fd-extents {
  padding-top: 10px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.fd-info {
  padding: 20px 24px;
  overflow-y: auto;
}

.fd-status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 18px;
}
.fd-status[data-status="healthy"]       { color: #22c55e; border-color: rgba(34, 197, 94, 0.35); }
.fd-status[data-status="healthy"]       .chip-dot { background: #22c55e; box-shadow: 0 0 8px #22c55e; }
.fd-status[data-status="needs_healing"] { color: #fbbf24; border-color: rgba(251, 191, 36, 0.35); }
.fd-status[data-status="needs_healing"] .chip-dot { background: #fbbf24; box-shadow: 0 0 8px #fbbf24; }
.fd-status[data-status="critical"]      { color: #ef4444; border-color: rgba(239, 68, 68, 0.35); }
.fd-status[data-status="critical"]      .chip-dot { background: #ef4444; box-shadow: 0 0 8px #ef4444; }

.fd-section { margin-bottom: 20px; }
.fd-section-title {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.fd-badge {
  display: inline-flex;
  min-width: 20px;
  height: 18px;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
}

.fd-meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.fd-meta-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 2px;
}
.fd-meta-value {
  font-size: 15px;
  color: #fff;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.fd-entity-list, .fd-issue-list, .fd-rx-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.fd-entity-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  font-size: 13px;
}
.fd-entity-icon {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}
.fd-entity-row.action-kept       .fd-entity-icon { background: #22c55e; }
.fd-entity-row.action-converting .fd-entity-icon { background: #fbbf24; }
.fd-entity-row.action-dropping   .fd-entity-icon { background: #ef4444; }

.fd-entity-name  { color: #fff; font-weight: 600; min-width: 90px; font-variant-numeric: tabular-nums; }
.fd-entity-count { color: rgba(255, 255, 255, 0.55); font-variant-numeric: tabular-nums; margin-right: auto; }
.fd-entity-action { font-size: 11px; color: rgba(255, 255, 255, 0.5); }
.fd-entity-row.action-kept       .fd-entity-action { color: #22c55e; }
.fd-entity-row.action-converting .fd-entity-action { color: #fbbf24; }
.fd-entity-row.action-dropping   .fd-entity-action { color: #ef4444; }

.fd-issue-row {
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  border-left: 2px solid transparent;
}
.fd-issue-row[data-sev="error"]   { border-left-color: #ef4444; }
.fd-issue-row[data-sev="warning"] { border-left-color: #fbbf24; }
.fd-issue-head {
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}
.fd-issue-dot {
  width: 6px; height: 6px; border-radius: 50%;
}
.fd-issue-row[data-sev="error"]   .fd-issue-dot { background: #ef4444; box-shadow: 0 0 6px #ef4444; }
.fd-issue-row[data-sev="warning"] .fd-issue-dot { background: #fbbf24; box-shadow: 0 0 6px #fbbf24; }
.fd-issue-msg {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  margin-top: 3px;
  padding-left: 14px;
}

.fd-rx {
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.18);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 0;
}
.fd-rx-icon { color: var(--accent); font-size: 14px; }
.fd-rx-list { gap: 4px; }
.fd-rx-list li {
  position: relative;
  padding: 2px 0 2px 18px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 13px;
  line-height: 1.5;
}
.fd-rx-list li::before {
  content: "\2022";
  position: absolute;
  left: 4px;
  color: var(--accent);
  font-weight: 700;
}

.fd-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.2);
}
.fd-include {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.85);
}
.fd-include input { position: absolute; opacity: 0; pointer-events: none; }

@media (max-width: 820px) {
  .fd-body { grid-template-columns: 1fr; }
  .fd-preview { border-right: none; border-bottom: 1px solid rgba(255, 255, 255, 0.06); min-height: 260px; }
  .fd-preview canvas, .fd-preview .canvas-wrap { min-height: 240px; }
  .fd-info { padding: 16px 18px; }
  .fd-filename { font-size: 17px; }
  .fd-foot { padding: 12px 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .fd-overlay, .fd-card { transition: none !important; }
}

/* ---------- bulk results grid ---------- */
.bulk-results {
  max-width: 960px;
  margin: 32px auto 0;
  padding: 0 4px;
  animation: fadeUp 500ms var(--ease) both;
}
.bulk-header {
  text-align: center;
  margin-bottom: 24px;
}
.bulk-title {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  color: #fff;
  margin: 2px 0 8px;
  letter-spacing: -0.02em;
}
.bulk-filename {
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
  margin: 0 0 18px;
  font-variant-numeric: tabular-nums;
}
.bulk-dot-sep { margin: 0 10px; color: rgba(255, 255, 255, 0.3); }
.stat-chips {
  display: inline-flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}
.stat-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
}
.chip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  box-shadow: 0 0 8px currentColor;
}
.stat-chip.chip-healthy  { color: #22c55e; border-color: rgba(34, 197, 94, 0.3); }
.stat-chip.chip-healthy  .chip-dot { background: #22c55e; }
.stat-chip.chip-warning  { color: #fbbf24; border-color: rgba(251, 191, 36, 0.3); }
.stat-chip.chip-warning  .chip-dot { background: #fbbf24; }
.stat-chip.chip-critical { color: #ef4444; border-color: rgba(239, 68, 68, 0.3); }
.stat-chip.chip-critical .chip-dot { background: #ef4444; }

.file-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
  margin: 24px 0 28px;
}
.file-card {
  position: relative;
  padding: 14px;
  background: linear-gradient(135deg, rgba(20, 20, 25, 0.9), rgba(10, 15, 10, 0.95));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  transition: transform 180ms var(--ease), border-color 180ms var(--ease), box-shadow 180ms var(--ease);
  cursor: pointer;
}
.file-card:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 197, 94, 0.35);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(34, 197, 94, 0.1);
}
.file-card.is-selected {
  border-color: rgba(34, 197, 94, 0.6);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.3), 0 10px 24px rgba(0, 0, 0, 0.35);
}
.file-card.is-healed {
  border-color: rgba(34, 197, 94, 0.6);
  background: linear-gradient(135deg, rgba(10, 25, 15, 0.95), rgba(5, 15, 8, 0.98));
}
.file-card.is-healed::after {
  content: "\2713";
  position: absolute;
  top: 10px;
  right: 10px;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: #052e16;
  font-weight: 700;
  font-size: 13px;
  border-radius: 50%;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.5);
  z-index: 2;
}
.file-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.file-select {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}
.file-select input { position: absolute; opacity: 0; pointer-events: none; }
.checkbox-visual {
  width: 18px;
  height: 18px;
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.03);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 150ms ease;
}
.file-select input:checked + .checkbox-visual,
.fd-include input:checked + .checkbox-visual {
  background: var(--accent);
  border-color: var(--accent);
}
.file-select input:checked + .checkbox-visual::after,
.fd-include input:checked + .checkbox-visual::after {
  content: "\2713";
  color: #052e16;
  font-weight: 700;
  font-size: 12px;
  line-height: 1;
}
.status-dot-sm {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.file-card[data-status="healthy"]       .status-dot-sm { background: #22c55e; box-shadow: 0 0 8px #22c55e; }
.file-card[data-status="needs_healing"] .status-dot-sm { background: #fbbf24; box-shadow: 0 0 8px #fbbf24; }
.file-card[data-status="critical"]      .status-dot-sm { background: #ef4444; box-shadow: 0 0 8px #ef4444; }

.file-thumb {
  display: flex;
  justify-content: center;
  margin: 8px 0 10px;
}
.file-icon-svg {
  width: 44px;
  height: 44px;
  color: var(--accent);
}
.file-info { text-align: center; }
.file-name {
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-folder {
  color: rgba(255, 255, 255, 0.4);
  font-size: 11px;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-meta {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 8px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  font-variant-numeric: tabular-nums;
}
.meta-sep { color: rgba(255, 255, 255, 0.2); }
.file-card[data-status="healthy"]       .meta-issue { color: #22c55e; }
.file-card[data-status="needs_healing"] .meta-issue { color: #fbbf24; }
.file-card[data-status="critical"]      .meta-issue { color: #ef4444; }

.bulk-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}
.btn-large { padding: 14px 28px; font-size: 15px; }
.heal-icon { font-size: 18px; line-height: 1; }
.btn-primary.is-done {
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent);
  box-shadow: inset 0 0 0 1px rgba(34, 197, 94, 0.4);
}
.btn-primary.is-done:disabled { opacity: 1; }
.heal-check { margin-left: 4px; }

/* progress overlay (bulk heal in flight) */
.progress-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 220ms ease;
}
.progress-overlay.is-open { opacity: 1; }
.progress-card {
  width: 100%;
  max-width: 400px;
  padding: 32px;
  text-align: center;
  background: linear-gradient(135deg, rgba(20, 20, 25, 0.92), rgba(10, 15, 10, 0.96));
  border: 1px solid rgba(34, 197, 94, 0.22);
  border-radius: 20px;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.progress-icon {
  font-size: 44px;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 12px;
  animation: progressPulse 1.6s ease-in-out infinite;
  filter: drop-shadow(0 0 16px rgba(34, 197, 94, 0.5));
}
@keyframes progressPulse {
  0%, 100% { transform: scale(1); opacity: 0.85; }
  50%      { transform: scale(1.08); opacity: 1; }
}
.progress-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 18px;
  letter-spacing: -0.01em;
}
.progress-bar {
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 12px;
}
.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #22c55e, #10b981);
  border-radius: 999px;
  transition: width 300ms ease;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.5);
}
.progress-text {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.75);
  font-variant-numeric: tabular-nums;
  margin-bottom: 4px;
}
.progress-filename {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 720px) {
  .file-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
  .bulk-title { font-size: 24px; }
  .bulk-actions { flex-direction: column; align-items: stretch; }
  .bulk-actions > * { width: 100%; justify-content: center; }
}

/* ---------- usage indicator ---------- */
.usage-indicator {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 12px;
  padding: 12px 16px;
  margin: 20px auto 0;
  max-width: 520px;
  font-size: 13px;
  font-family: var(--font-body);
}
.usage-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.65);
}
.usage-count {
  margin-left: auto;
  color: #fff;
  font-variant-numeric: tabular-nums;
}
.usage-count strong { color: #fff; font-weight: 600; }
.usage-bar {
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
}
.usage-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #22c55e, #10b981);
  border-radius: 999px;
  transition: width 500ms var(--ease), background 300ms ease;
}
.usage-indicator[data-usage="medium"] .usage-bar-fill {
  background: linear-gradient(90deg, #fbbf24, #f59e0b);
}
.usage-indicator[data-usage="high"] .usage-bar-fill {
  background: linear-gradient(90deg, #ef4444, #dc2626);
}
.usage-reset {
  color: rgba(255, 255, 255, 0.4);
  font-size: 11px;
  margin-top: 6px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ---------- limit-exceeded modal (shares feedback glossy liquid base) ---------- */
.limit-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  padding: 20px;
  transition: opacity 300ms ease;
}
.limit-overlay.is-open { opacity: 1; }
.limit-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  padding: 32px;
  background: linear-gradient(135deg, rgba(20, 20, 25, 0.92), rgba(10, 15, 10, 0.96));
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(34, 197, 94, 0.22);
  border-radius: 24px;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 0 1px rgba(34, 197, 94, 0.05);
  overflow: hidden;
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  transition:
    transform 400ms cubic-bezier(0.34, 1.56, 0.64, 1),
    opacity 300ms ease;
  text-align: center;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
}
.limit-overlay.is-open .limit-card {
  transform: scale(1) translateY(0);
  opacity: 1;
}
.limit-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(34, 197, 94, 0.4), transparent);
}

.limit-head { margin-bottom: 20px; }
.limit-head h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 10px;
  letter-spacing: -0.02em;
}
.limit-stat {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.75);
  margin: 0 0 6px;
}
.limit-stat strong { color: var(--accent); font-weight: 600; }
.limit-reset {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
  margin: 0;
}
.limit-reset strong { color: #fff; font-variant-numeric: tabular-nums; }

.limit-divider {
  position: relative;
  text-align: center;
  margin: 20px 0 20px;
  color: rgba(255, 255, 255, 0.3);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
}
.limit-divider::before,
.limit-divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 40%;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
}
.limit-divider::before { left: 0; }
.limit-divider::after { right: 0; }
.limit-divider span { background: transparent; padding: 0 10px; }

.pro-card {
  background: rgba(34, 197, 94, 0.04);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 16px;
  padding: 20px;
  text-align: left;
  margin-bottom: 18px;
}
.pro-badge {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.pro-title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 12px;
  letter-spacing: -0.01em;
  line-height: 1.3;
}
.pro-features {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.75);
}
.pro-features li {
  position: relative;
  padding: 3px 0 3px 20px;
}
.pro-features li::before {
  content: "\2713";
  position: absolute;
  left: 2px;
  color: var(--accent);
  font-weight: 700;
}
.pro-waitlist {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}
.pro-waitlist .fb-input { padding: 10px 14px; font-size: 13px; }
.pro-waitlist .fb-submit {
  width: auto;
  flex-shrink: 0;
  padding: 10px 18px;
  font-size: 13px;
  margin-top: 0;
}
.pro-social {
  text-align: center;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  margin: 0;
}
.pro-social span { color: var(--accent); font-weight: 600; font-variant-numeric: tabular-nums; }
.pro-success {
  text-align: center;
  font-size: 14px;
  color: var(--accent);
  padding: 10px;
  background: rgba(34, 197, 94, 0.08);
  border-radius: 10px;
  margin-top: 6px;
}

.limit-dismiss {
  width: 100%;
  justify-content: center;
}

@media (max-width: 720px) {
  .limit-card { padding: 24px; border-radius: 20px; }
  .limit-head h2 { font-size: 20px; }
  .pro-waitlist { flex-direction: column; }
  .pro-waitlist .fb-submit { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .limit-overlay, .limit-card { transition: none !important; }
}

/* ---------- feedback modal (glossy liquid) ---------- */
.fb-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  padding: 20px;
  transition: opacity 300ms ease;
}
.fb-overlay.is-open { opacity: 1; }

.fb-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  padding: 32px;
  background:
    linear-gradient(135deg, rgba(20, 20, 25, 0.9), rgba(10, 15, 10, 0.95));
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 24px;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 0 1px rgba(34, 197, 94, 0.05);
  overflow: hidden;
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  transition:
    transform 400ms cubic-bezier(0.34, 1.56, 0.64, 1),
    opacity 300ms ease;
}
.fb-overlay.is-open .fb-card {
  transform: scale(1) translateY(0);
  opacity: 1;
}
.fb-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(34, 197, 94, 0.4), transparent);
}
.fb-card::after {
  content: "";
  position: absolute;
  inset: -50%;
  background: radial-gradient(circle at 30% 20%, rgba(34, 197, 94, 0.08), transparent 50%);
  pointer-events: none;
  animation: fbLiquid 8s ease-in-out infinite;
}
@keyframes fbLiquid {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(10%, 10%); }
}
.fb-card.is-shaking { animation: fbShake 400ms ease; }
@keyframes fbShake {
  0%, 100% { transform: translateX(0); }
  20%      { transform: translateX(-8px); }
  40%      { transform: translateX(8px); }
  60%      { transform: translateX(-4px); }
  80%      { transform: translateX(4px); }
}

.fb-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  padding: 0;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease;
  z-index: 1;
}
.fb-close:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.fb-card-inner { position: relative; z-index: 1; }

.fb-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 6px;
  letter-spacing: -0.01em;
}
.fb-subtitle {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0 0 20px;
}

.fb-rating {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  justify-content: center;
}
.fb-star {
  width: 36px;
  height: 36px;
  padding: 2px;
  background: transparent;
  border: none;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.2);
  transition: transform 180ms ease, color 180ms ease, filter 180ms ease;
}
.fb-star svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
  stroke: currentColor;
  stroke-width: 1.4;
}
.fb-star:hover {
  color: #fbbf24;
  transform: scale(1.15);
  filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.6));
}
.fb-star.is-active {
  color: #fbbf24;
  filter: drop-shadow(0 0 6px rgba(251, 191, 36, 0.4));
  animation: fbStarPop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes fbStarPop {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.25); }
  100% { transform: scale(1); }
}

.fb-row { margin-bottom: 12px; }
.fb-textarea-wrap { position: relative; }

.fb-input {
  width: 100%;
  padding: 14px 18px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  color: #fff;
  font-family: var(--font-body);
  font-size: 14px;
  transition:
    border-color 200ms ease,
    background 200ms ease,
    box-shadow 200ms ease;
}
.fb-input::placeholder { color: rgba(255, 255, 255, 0.3); }
.fb-input:focus {
  outline: none;
  border-color: rgba(34, 197, 94, 0.6);
  background: rgba(0, 0, 0, 0.5);
  box-shadow:
    0 0 0 4px rgba(34, 197, 94, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.fb-textarea {
  min-height: 100px;
  resize: vertical;
  padding-bottom: 28px;
}
.fb-counter {
  position: absolute;
  bottom: 10px;
  right: 14px;
  font-size: 11px;
  color: rgba(34, 197, 94, 0.7);
  pointer-events: none;
  font-variant-numeric: tabular-nums;
}
.fb-counter.is-near { color: rgba(251, 191, 36, 0.85); }
.fb-counter.is-over { color: rgba(255, 74, 74, 0.95); }

.fb-honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.fb-error {
  margin: 4px 0 12px;
  padding: 10px 14px;
  background: rgba(255, 74, 74, 0.08);
  border: 1px solid rgba(255, 74, 74, 0.3);
  border-radius: 10px;
  color: #ffb4b4;
  font-size: 13px;
}

.fb-submit {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 14px 32px;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #fff;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.01em;
  border: none;
  border-radius: 14px;
  box-shadow:
    0 8px 24px rgba(34, 197, 94, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 200ms ease, opacity 200ms ease;
}
.fb-submit:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow:
    0 12px 32px rgba(34, 197, 94, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}
.fb-submit:active:not(:disabled) { transform: translateY(0); }
.fb-submit:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  box-shadow: none;
}

/* thank-you + cross-sell */
.fb-thanks { text-align: center; }
.fb-thanks-check {
  font-size: 56px;
  line-height: 1;
  color: var(--accent);
  text-shadow: 0 0 24px rgba(34, 197, 94, 0.5);
  margin-bottom: 12px;
  animation: fbPulseCheck 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes fbPulseCheck {
  0%   { transform: scale(0); opacity: 0; }
  60%  { transform: scale(1.25); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}
.fb-thanks-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 32px;
  color: #fff;
  margin: 0 0 6px;
  letter-spacing: -0.02em;
}
.fb-thanks-sub {
  color: rgba(255, 255, 255, 0.75);
  font-size: 14px;
  margin: 0 0 20px;
}
.fb-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.12), transparent);
  margin: 4px 0 18px;
}
.fb-cross-head {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0 0 12px;
}
.fb-cross-row {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}
.fb-cross-chip {
  display: inline-flex;
  padding: 8px 16px;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 999px;
  color: #d1fae5;
  font-size: 13px;
  font-weight: 500;
  transition: background 180ms ease, border-color 180ms ease, transform 180ms ease;
}
.fb-cross-chip:hover {
  background: rgba(34, 197, 94, 0.18);
  border-color: rgba(34, 197, 94, 0.6);
  color: #fff;
  transform: translateY(-1px);
}

/* mobile */
@media (max-width: 720px) {
  .fb-card { padding: 24px; max-width: 400px; border-radius: 20px; }
  .fb-title { font-size: 20px; }
  .fb-subtitle { font-size: 12px; }
  .fb-star { width: 32px; height: 32px; }
  .fb-input { padding: 12px 16px; font-size: 13px; }
  .fb-textarea { min-height: 80px; }
  .fb-submit { padding: 12px 24px; font-size: 14px; }
  .fb-thanks-title { font-size: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  .fb-overlay, .fb-card, .fb-star, .fb-thanks-check {
    transition: none !important;
    animation: none !important;
  }
  .fb-card::after { animation: none !important; }
}

/* ---------- footer ---------- */
.site-footer {
  padding: 40px 32px;
  text-align: center;
  color: var(--fg-mute);
  font-size: 13px;
  border-top: 1px solid var(--border);
  margin-top: 64px;
}
.site-footer p { margin: 0; }

/* ---------- responsive ---------- */
@media (max-width: 720px) {
  .site-header {
    flex-direction: column;
    gap: 14px;
    padding: 16px 20px;
    min-height: 0;
  }
  .brand-wordmark { font-size: 26px; }
  .brand-subtitle { font-size: 10px; margin-top: 2px; }
  .site-nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 20px;
    font-size: 15px;
  }
  .site-main { padding: 24px 16px 64px; }
  .drop-zone { padding: 52px 16px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-value { font-size: 24px; }
  .report-card { padding: 20px; }
  .cta-row { flex-direction: column; align-items: stretch; }
  .cta-row > * { width: 100%; justify-content: center; }
  .format-select { flex-direction: row; }
  canvas { height: 320px; }
}
