/* =============================================================
   1. Tokens (from the Stitch "Universal Converter" design system)
   ============================================================= */
:root {
  --bg: #0C0F14;
  --surface: #161B22;
  --surface-2: #1F242D;
  --surface-3: #232936;
  --input: #12151C;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --ink: #F8FAFC;
  --ink-2: #C7C4D8;
  --muted: #94A3B8;

  --primary: #4F46E5;
  --primary-hover: #4338CA;
  --primary-light: #C3C0FF;
  --primary-glow: rgba(79, 70, 229, 0.18);
  --emerald: #4EDEA3;
  --emerald-solid: #10B981;
  --amber: #FFB95F;
  --error: #FFB4AB;
  --error-bg: rgba(239, 68, 68, 0.12);

  --display: "Syne", "Inter", system-ui, sans-serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 24px;
  --gutter: 16px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: dark;
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  letter-spacing: -0.005em;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; }
p { text-wrap: pretty; }
h1, h2, h3 { text-wrap: balance; }
ul, ol { padding: 0; list-style: none; }
::selection { background: var(--primary); color: #fff; }
:focus-visible { outline: 1px solid var(--primary); box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.35); outline-offset: 2px; border-radius: 6px; }

/* =============================================================
   3. Utilities
   ============================================================= */
.container { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: var(--gutter); }
.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;
}
.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 999;
  padding: .6rem 1rem; background: var(--primary); color: #fff; border-radius: 8px;
}
.skip-link:focus { top: 1rem; }
html:not(.js) [data-js-only] { display: none !important; }
[hidden] { display: none !important; }
kbd {
  font: 500 .72rem/1 var(--mono); padding: .2em .45em; border-radius: 5px;
  border: 1px solid var(--line-2); background: var(--surface-2); color: var(--ink-2);
}
.label-caps { font: 600 11px/16px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.c-primary { color: var(--primary-light); }
.c-emerald { color: var(--emerald); }
.c-amber { color: var(--amber); }
.c-light { color: #E2DFFF; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--emerald-solid); box-shadow: 0 0 0 3px rgba(16, 185, 129, .18); }

/* =============================================================
   4. Components
   ============================================================= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 44px; padding: .6rem 1.15rem; border-radius: var(--r-md);
  font: 500 15px/1.2 var(--sans); text-decoration: none; white-space: nowrap;
  transition: background-color .2s var(--ease-out), box-shadow .2s var(--ease-out), transform .15s var(--ease-out), border-color .2s;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 8px 24px -8px rgba(79, 70, 229, .55); }
.btn-primary:hover { background: var(--primary-hover); box-shadow: 0 12px 32px -6px rgba(79, 70, 229, .6); }
.btn-secondary { color: var(--ink); border: 1px solid var(--line-2); background: transparent; }
.btn-secondary:hover { background: rgba(255, 255, 255, .05); border-color: rgba(255, 255, 255, .22); }
.btn-big { min-height: 52px; padding-inline: 1.5rem; font-size: 16px; font-weight: 600; border-radius: var(--r-lg); }
.btn-small { min-height: 34px; padding: .35rem .8rem; font-size: 13px; border-radius: var(--r-sm); }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* =============================================================
   5. Header / footer
   ============================================================= */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(12, 15, 20, .78);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; height: 64px; }
.logo { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--ink); }
.logo-mark { width: 34px; height: 34px; color: var(--primary); filter: drop-shadow(0 6px 14px rgba(79, 70, 229, .35)); }
.logo-word { font: 700 1.3rem/1 var(--display); letter-spacing: -0.02em; }
.header-nav { display: none; gap: 28px; margin-left: auto; }
.header-nav a { font-size: 15px; color: var(--ink-2); text-decoration: none; transition: color .2s; }
.header-nav a:hover { color: var(--primary-light); }
.btn-header { margin-left: auto; min-height: 38px; padding: .45rem .9rem; font-size: 14px; }

.site-footer { margin-top: 40px; border-top: 1px solid var(--line); background: #0B0E13; }
.footer-inner { display: grid; gap: 20px; padding-block: 40px 24px; }
.footer-brand p { margin-top: 10px; font-size: 13px; color: var(--muted); }
.logo--small .logo-mark { width: 26px; height: 26px; }
.logo--small .logo-word { font-size: 1.1rem; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 10px 24px; }
.footer-nav a { font-size: 13px; color: var(--muted); text-decoration: none; }
.footer-nav a:hover { color: var(--primary-light); }
.footer-sub {
  display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: space-between; align-items: center;
  padding-block: 16px 28px; border-top: 1px solid rgba(255, 255, 255, .05);
  font-size: 12px; color: var(--muted);
}
.footer-status { display: inline-flex; align-items: center; gap: 8px; }
.credits { font-family: var(--mono); font-size: 11px; }
.credits a { color: var(--muted); }
.credits a:hover { color: var(--ink); }

/* =============================================================
   6. Hero + tool card
   ============================================================= */
.glow { background: radial-gradient(ellipse 80% 520px at 50% -120px, rgba(79, 70, 229, .22), rgba(12, 15, 20, 0) 70%) no-repeat; }
.hero { padding-top: 20px; text-align: center; }
.hero-pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 5px 14px; border-radius: 999px;
  background: #191C21; border: 1px solid var(--line-2);
  font: 600 10.5px/16px var(--mono); letter-spacing: .07em; text-transform: uppercase; color: var(--ink-2);
}
.hero-pill .dot { width: 7px; height: 7px; }
.hero h1 {
  margin: 14px auto 0; max-width: 16em;
  font: 700 29px/35px var(--display); letter-spacing: -0.02em;
}
.grad {
  display: block;
  background: linear-gradient(90deg, var(--primary-light), #E2DFFF 45%, var(--emerald));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub { margin: 10px auto 0; max-width: 40em; color: var(--muted); font-size: 14.5px; line-height: 22px; }

.tool-card {
  margin: 18px auto 0; max-width: 880px; text-align: left;
  padding: 12px;
  background: var(--surface);
  border-radius: var(--r-xl);
  box-shadow: 0 0 0 1px var(--line), 0 24px 48px -12px rgba(0, 0, 0, .45);
  display: grid; gap: 12px;
}
.noscript { padding: 1.4rem; text-align: center; font-weight: 600; }

.dropzone {
  position: relative;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 20px 14px;
  border: 1.5px dashed rgba(255, 255, 255, .18);
  border-radius: calc(var(--r-xl) - 6px);
  background-color: #191C21;
  background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
  background-size: 24px 24px;
  cursor: pointer;
  transition: border-color .25s var(--ease-out), box-shadow .25s var(--ease-out), background-color .25s;
}
.dropzone:hover, .dropzone.is-over {
  border-color: var(--primary); border-style: solid;
  background-color: #1B1F2A;
  box-shadow: inset 0 0 0 1px var(--primary), inset 0 0 80px rgba(79, 70, 229, .15);
}
.dropzone:focus-within { border-color: var(--primary); }
.dz-badges { display: flex; align-items: center; margin-bottom: 12px; }
.fmt {
  display: grid; place-items: center; width: 44px; height: 38px; margin-inline: -3px;
  border-radius: var(--r-sm); background: #272A30; border: 1px solid rgba(255, 255, 255, .09);
  font: 600 10.5px/1 var(--mono); letter-spacing: .03em;
}
.fmt--a { color: var(--primary-light); }
.fmt--b { color: #E2DFFF; }
.fmt--hero { position: relative; z-index: 1; width: 50px; height: 44px; background: #32353B; color: var(--emerald); transform: translateY(-2px); box-shadow: 0 8px 20px -6px rgba(0, 0, 0, .6); }
.fmt--c { color: var(--amber); }
.fmt--d { color: var(--muted); }
.dz-icon {
  display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 10px;
  border-radius: 50%; background: rgba(79, 70, 229, .15); border: 1px solid rgba(195, 192, 255, .2);
  color: var(--primary-light); transition: transform .3s var(--ease-out);
}
.dz-icon svg { width: 26px; height: 26px; }
.dropzone:hover .dz-icon { transform: scale(1.08); }
.dz-title { font: 600 20px/28px var(--display); letter-spacing: -0.01em; }
.dz-hint { margin-top: 6px; font-size: 13px; color: var(--muted); }
.dz-btn { margin-top: 14px; pointer-events: none; }

.tool-card[data-state="done"] .dropzone,
.tool-card[data-state="working"] .dropzone,
.tool-card[data-state="error"] .dropzone { flex-direction: row; justify-content: center; gap: 12px; padding: 14px 16px; }
.tool-card[data-state="done"] :is(.dz-badges, .dz-hint, .dz-btn),
.tool-card[data-state="working"] :is(.dz-badges, .dz-hint, .dz-btn),
.tool-card[data-state="error"] :is(.dz-badges, .dz-hint, .dz-btn) { display: none; }
.tool-card[data-state="done"] .dz-icon,
.tool-card[data-state="working"] .dz-icon,
.tool-card[data-state="error"] .dz-icon { width: 36px; height: 36px; margin: 0; }
.tool-card[data-state="done"] .dz-title,
.tool-card[data-state="working"] .dz-title,
.tool-card[data-state="error"] .dz-title { font-size: 16px; }

.tool-options {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px;
  padding: 4px 6px;
}
.format-picker { border: 0; padding: 0; min-width: 0; display: flex; align-items: center; gap: 12px; }
.format-picker legend { float: left; margin-right: 12px; font: 600 11px/16px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.chips { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.chips label { position: relative; }
.chips input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.chips span {
  display: block; padding: 7px 12px; border-radius: var(--r-sm);
  background: var(--surface-2); border: 1px solid transparent;
  font: 600 12px/16px var(--mono); letter-spacing: .06em; color: var(--muted);
  transition: background-color .2s var(--ease-out), color .2s, border-color .2s;
}
.chips input:checked + span { color: #fff; background: rgba(79, 70, 229, .18); border-color: var(--primary); box-shadow: 0 0 16px -4px rgba(79, 70, 229, .6); }
.chips input:not(:checked):hover + span { color: var(--ink); }
.chips input:focus-visible + span { outline: 1px solid var(--primary-light); outline-offset: 2px; }

.quality { display: flex; align-items: center; gap: 10px; }
.quality label { font: 600 11px/16px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.quality output {
  min-width: 3.2em; padding: 5px 8px; border-radius: var(--r-sm); text-align: center;
  background: var(--input); border: 1px solid var(--line);
  font: 500 13px/1 var(--mono); font-variant-numeric: tabular-nums;
}
.quality input { width: 140px; accent-color: var(--primary); }
.quality.is-off { opacity: .4; }
.format-note { padding: 0 6px; font-size: 13px; color: var(--amber); }

.progress { display: grid; gap: 8px; padding: 0 6px; }
.progress-text { font: 500 13px/1.4 var(--mono); color: var(--muted); }
.progress-bar { height: 3px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.progress-bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--primary), var(--emerald-solid)); transition: width .25s var(--ease-out); }

.file-list { display: grid; gap: 8px; }
.file-list:empty { display: none; }
.file-row {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: var(--r-lg);
  background: rgba(11, 14, 19, .8); border: 1px solid var(--line);
  transition: border-color .2s;
}
.file-row:hover { border-color: rgba(255, 255, 255, .16); }
.file-conv { display: inline-flex; align-items: center; gap: 6px; }
.badge {
  padding: 3px 7px; border-radius: 6px;
  font: 600 11px/16px var(--mono); letter-spacing: .05em;
  background: var(--surface-2); color: var(--ink-2);
}
.badge--out { background: rgba(79, 70, 229, .2); color: var(--primary-light); }
.file-conv svg { width: 14px; height: 14px; color: var(--muted); }
.file-meta { min-width: 0; }
.file-name { font-size: 13.5px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-info { font: 400 12px/1.5 var(--mono); color: var(--muted); }
.file-info b { font-weight: 500; color: var(--emerald); }
.file-row.is-error .file-info { font-family: var(--sans); color: var(--error); }
.row-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: transparent; }
.row-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--primary), var(--emerald-solid)); transition: width .4s var(--ease-out); }
.file-row.is-working .row-bar i { width: 60%; animation: rowpulse 1.1s ease-in-out infinite alternate; }
.file-row.is-done .row-bar i { width: 100%; opacity: .7; }
.file-row.is-error .row-bar i { width: 100%; background: #EF4444; opacity: .6; }
@keyframes rowpulse { from { width: 25%; } to { width: 85%; } }

.result {
  display: grid; gap: 12px; padding: 16px;
  border-radius: var(--r-lg);
  background: linear-gradient(90deg, rgba(79, 70, 229, .14), rgba(16, 185, 129, .08));
  border: 1px solid rgba(195, 192, 255, .18);
}
.result-summary { font-weight: 500; }
.result-summary .saving { color: var(--emerald); font-family: var(--mono); }
.result-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.result-actions .btn-big { flex: 1 1 260px; }

.tool-error { padding: 12px 14px; border-radius: var(--r-md); background: var(--error-bg); color: var(--error); font-size: 14px; }

.privacy-badge {
  display: flex; gap: 10px; justify-content: center; align-items: flex-start;
  margin: 14px auto 0; max-width: 880px; font-size: 13px; color: var(--muted); text-align: left;
}
.privacy-badge svg { flex: none; width: 16px; height: 16px; margin-top: 2px; color: var(--emerald); }
.privacy-badge strong { color: var(--ink); font-weight: 600; }

/* =============================================================
   7. Ad slots (placeholders)
   ============================================================= */
.ad-slot {
  display: grid; place-items: center;
  max-width: 880px; margin: 36px auto;
  border: 1px dashed var(--line-2); border-radius: var(--r-md);
}
.ad-slot--leaderboard { min-height: 100px; }
.ad-slot--incontent { min-height: 250px; margin-block: 32px; }
.ad-label { font: 600 10px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); opacity: .6; }

/* =============================================================
   8. Content sections
   ============================================================= */
.metrics { margin-top: 24px; padding-block: 40px; border-block: 1px solid var(--line); background: rgba(11, 14, 19, .4); }
.metric-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 20px; padding-bottom: 28px; border-bottom: 1px solid rgba(255, 255, 255, .06); }
.metric-grid li { display: grid; gap: 2px; }
.metric-num { font: 600 30px/38px var(--display); letter-spacing: -0.02em; }
.metric-name { font-weight: 500; font-size: 14px; }
.metric-desc { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.standards { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; padding-top: 24px; }
.standards-list { display: flex; flex-wrap: wrap; gap: 10px 26px; }
.standards-list span { font: 600 14px/20px var(--mono); color: var(--ink-2); letter-spacing: .04em; }

.section { margin-top: 72px; }
.section h2 { font: 600 28px/36px var(--display); letter-spacing: -0.015em; }
.section-head { margin-bottom: 28px; }
.section-head .label-caps { display: block; margin-bottom: 8px; }
.section-head--split { display: grid; gap: 10px; }
.section-head--center { text-align: center; max-width: 640px; margin-inline: auto; }
.section-sub { color: var(--muted); max-width: 30em; }
.section-head--center .section-sub { margin: 8px auto 0; }

.cat-grid { display: grid; gap: 14px; }
.cat-card {
  display: flex; flex-direction: column; gap: 8px;
  padding: 22px; border-radius: var(--r-xl);
  background: #191C21; box-shadow: 0 0 0 1px rgba(255, 255, 255, .07);
  transition: box-shadow .25s var(--ease-out), transform .25s var(--ease-out);
}
.cat-card:hover { box-shadow: 0 0 0 1px rgba(195, 192, 255, .35); }
.cat-card.is-live { box-shadow: 0 0 0 1px var(--primary), 0 12px 32px -8px rgba(79, 70, 229, .3); }
.cat-icon {
  display: grid; place-items: center; width: 42px; height: 42px; margin-bottom: 8px;
  border-radius: var(--r-md); background: #272A30; border: 1px solid rgba(255, 255, 255, .07);
}
.cat-icon svg { width: 22px; height: 22px; }
.cat-card h3 { font: 500 19px/26px var(--display); letter-spacing: -0.005em; }
.cat-card p { font-size: 13px; line-height: 20px; color: var(--muted); }
.cat-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 12px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags span { padding: 2px 7px; border-radius: 6px; background: #272A30; font: 500 11px/16px var(--mono); color: var(--ink-2); }
.status { font: 600 10.5px/16px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.status--live { display: inline-flex; align-items: center; gap: 6px; color: var(--emerald); }
.status--live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--emerald-solid); }

.steps { display: grid; gap: 14px; }
.steps li { padding: 26px; border-radius: var(--r-xl); background: #191C21; box-shadow: 0 0 0 1px rgba(255, 255, 255, .07); }
.step-num {
  display: grid; place-items: center; width: 46px; height: 46px; margin-bottom: 20px;
  border-radius: var(--r-md); background: #32353B; border: 1px solid rgba(255, 255, 255, .1);
  font: 700 19px/1 var(--display);
}
.steps h3 { font: 500 19px/26px var(--display); }
.steps p { margin-top: 8px; color: var(--muted); }

.prose { max-width: 760px; }
.prose h3 { margin-top: 30px; font: 600 19px/26px var(--display); }
.prose p { margin-top: 10px; color: var(--ink-2); }
.prose .lead { font-size: 17px; line-height: 28px; color: var(--muted); }

.faq { max-width: 760px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-of-type { margin-top: 20px; border-top: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; position: relative;
  padding: 18px 36px 18px 0; font-weight: 500; font-size: 15.5px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  font: 400 22px/1 var(--mono); color: var(--primary-light); transition: transform .25s var(--ease-out);
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { padding-bottom: 18px; color: var(--muted); }

.pro-banner {
  position: relative; overflow: hidden;
  display: grid; gap: 24px; align-items: center;
  padding: 30px 22px; border-radius: 28px;
  background: linear-gradient(90deg, #191C21, #1D2025, #191C21);
  border: 1px solid rgba(70, 69, 85, .6);
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, .45);
}
.pro-banner::before {
  content: ""; position: absolute; right: -80px; top: -80px; width: 320px; height: 320px;
  border-radius: 50%; background: rgba(79, 70, 229, .22); filter: blur(60px); pointer-events: none;
}
.pro-copy, .pro-actions { position: relative; }
.pro-copy h2 { margin-top: 8px; }
.pro-copy p { margin-top: 12px; color: var(--ink-2); max-width: 36em; }
.pro-actions .btn { width: 100%; }

/* Legal pages */
.legal { padding-top: 48px; }
.legal h1 { font: 700 36px/44px var(--display); letter-spacing: -0.02em; }
.legal h2 { margin-top: 2rem; font: 600 20px/28px var(--display); }
.legal p, .legal li { margin-top: .6rem; color: var(--ink-2); }
.legal ul { list-style: disc; padding-left: 1.2rem; }
.legal a { color: var(--primary-light); }
.todo { background: rgba(255, 185, 95, .18); color: var(--amber); padding: 0 .3em; border-radius: 4px; }

/* =============================================================
   9. Responsive
   ============================================================= */
@media (min-width: 540px) {
  .tool-card { padding: 16px; }
  .dropzone { padding: 40px 24px; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .pro-actions .btn { width: auto; }
}
@media (min-width: 720px) {
  :root { --gutter: 24px; }
  .hero { padding-top: 56px; }
  .hero h1 { margin-top: 20px; max-width: 20em; font-size: 52px; line-height: 60px; letter-spacing: -0.03em; }
  .hero-sub { margin-top: 14px; font-size: 18px; line-height: 28px; }
  .dz-badges { margin-bottom: 18px; }
  .dz-icon { width: 52px; height: 52px; margin-bottom: 14px; }
  .dz-btn { margin-top: 18px; }
  .header-nav { display: flex; }
  .btn-header { margin-left: 8px; }
  .tool-card { padding: 20px; gap: 16px; margin-top: 36px; }
  .dropzone { padding: 48px 32px; }
  .metric-grid { grid-template-columns: repeat(4, 1fr); }
  .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .section h2 { font-size: 36px; line-height: 44px; letter-spacing: -0.02em; }
  .section-head--split { grid-template-columns: 1fr auto; align-items: end; gap: 24px; }
  .section-head--split .section-sub { text-align: right; }
  .pro-banner { grid-template-columns: 1fr auto; padding: 48px; }
  .footer-inner { grid-template-columns: 1fr auto; align-items: center; }
}
@media (min-width: 960px) {
  .cat-grid { grid-template-columns: repeat(4, 1fr); gap: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .file-row.is-working .row-bar i { animation: none; }
}

/* =============================================================
   10. Shared tool controls (all tool pages)
   ============================================================= */
.panel { display: grid; gap: 14px; padding: 4px 6px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field > label, .field > .field-label, .opt-label {
  font: 600 11px/16px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
}
.field-row { display: grid; gap: 12px; }
.input, .textarea, .select {
  width: 100%; min-height: 44px; padding: 10px 12px;
  border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--input);
  color: var(--ink); font: 400 14px/1.5 var(--sans);
  transition: border-color .2s, box-shadow .2s;
}
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(79, 70, 229, .2); }
.input.mono, .textarea { font-family: var(--mono); font-size: 13px; }
.textarea { min-height: 220px; resize: vertical; line-height: 1.55; tab-size: 2; }
.select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px; }
.input[type="color"] { padding: 4px; width: 56px; min-height: 44px; cursor: pointer; }
.hint { font-size: 12.5px; color: var(--muted); }
.warn { padding: 10px 12px; border-radius: var(--r-sm); background: rgba(255, 185, 95, .1); border: 1px solid rgba(255, 185, 95, .25); color: var(--amber); font-size: 13.5px; }
.ok-note { padding: 10px 12px; border-radius: var(--r-sm); background: rgba(16, 185, 129, .1); border: 1px solid rgba(16, 185, 129, .25); color: var(--emerald); font-size: 13.5px; }
.check { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--primary); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; }
.actions .btn-big { flex: 1 1 240px; }
.icon-btn { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: var(--r-sm); border: 1px solid var(--line-2); color: var(--ink-2); }
.icon-btn:hover { color: var(--ink); background: rgba(255, 255, 255, .05); }
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn[disabled] { opacity: .3; cursor: default; }
.row-actions { display: inline-flex; gap: 6px; align-items: center; }
.split-2 { display: grid; gap: 14px; }
.media-preview { width: 100%; max-height: 320px; border-radius: var(--r-md); background: #000; }
audio.media-preview { background: transparent; max-height: none; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; font-size: 13.5px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-family: var(--mono); font-size: 12.5px; overflow-wrap: anywhere; }
.reveal-card { padding: 14px; border-radius: var(--r-lg); background: rgba(11, 14, 19, .8); border: 1px solid var(--line); display: grid; gap: 10px; }
.reveal-card h3 { font: 600 15px/1.3 var(--sans); overflow-wrap: anywhere; }
.pill-danger { display: inline-block; padding: 2px 8px; border-radius: 99px; background: var(--error-bg); color: var(--error); font: 600 11px/16px var(--mono); }
.pill-ok { display: inline-block; padding: 2px 8px; border-radius: 99px; background: rgba(16, 185, 129, .12); color: var(--emerald); font: 600 11px/16px var(--mono); }

/* QR generator */
.qr-layout { display: grid; gap: 16px; }
.qr-preview-box { display: grid; place-items: center; padding: 18px; border-radius: var(--r-lg); background: #191C21; border: 1px solid var(--line); }
.qr-preview-box canvas, .qr-preview-box svg, .qr-preview-box img { width: min(100%, 300px) !important; height: auto !important; border-radius: 10px; }
.swatches { display: flex; gap: 12px; flex-wrap: wrap; align-items: end; }

/* 3D viewer */
.viewer3d { position: relative; aspect-ratio: 4 / 3; width: 100%; border-radius: var(--r-lg); overflow: hidden; background: radial-gradient(circle at 50% 30%, #1F2430, #0E1117); border: 1px solid var(--line); }
.viewer3d canvas { display: block; width: 100% !important; height: 100% !important; }
.viewer-msg { position: absolute; inset: 0; display: grid; place-items: center; padding: 20px; text-align: center; color: var(--muted); font-size: 13.5px; }

/* Tool links inside category cards */
.cat-links { display: grid; gap: 4px; margin-top: 4px; }
.cat-links a { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 10px; border-radius: var(--r-sm); background: #20242B; color: var(--ink); text-decoration: none; font-size: 13.5px; font-weight: 500; transition: background-color .2s, color .2s; }
.cat-links a:hover { background: rgba(79, 70, 229, .22); color: #fff; }
.cat-links a::after { content: "→"; color: var(--primary-light); font-family: var(--mono); }
.cat-links a[aria-current="page"] { background: rgba(79, 70, 229, .28); box-shadow: inset 0 0 0 1px var(--primary); }
.cat-card.is-here { box-shadow: 0 0 0 1px var(--primary), 0 12px 32px -8px rgba(79, 70, 229, .3); }
.footer-tools { display: flex; flex-wrap: wrap; gap: 8px 20px; padding-block: 0 20px; }
.footer-tools a { font-size: 13px; color: var(--muted); text-decoration: none; }
.footer-tools a:hover { color: var(--primary-light); }

@media (min-width: 720px) {
  .field-row { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
  .split-2 { grid-template-columns: 1fr 1fr; }
  .qr-layout { grid-template-columns: 1.2fr 1fr; align-items: start; }
}
.progress-bar span.is-indet { width: 35%; animation: indet 1.3s ease-in-out infinite; }
@keyframes indet { 0% { transform: translateX(-100%); } 100% { transform: translateX(300%); } }
.file-row .row-actions:empty { display: none; }
@media (prefers-reduced-motion: reduce) { .progress-bar span.is-indet { animation-duration: 2.6s; } }
