:root {
  color-scheme: dark;
  --bg: #0d0d10;
  --panel: #17171c;
  --panel-2: #202027;
  --text: #f5f3f7;
  --muted: #b9b5bf;
  --line: #35343d;
  --accent: #ff4d79;
  --accent-dark: #d92e5c;
  --good: #5ed39b;
  --warn: #ffcc66;
  --radius: 14px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { min-width: 0; scroll-behavior: smooth; }
body { min-width: 0; margin: 0; overflow-x: hidden; background: var(--bg); color: var(--text); line-height: 1.55; }
a { color: inherit; }
img { display: block; max-width: 100%; }
button, input { font: inherit; }
.shell { width: min(100% - 32px, 1040px); margin-inline: auto; }
.analytics-consent { padding: 12px min(5vw, 20px); display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; border-bottom: 1px solid var(--line); background: var(--panel); font-size: .86rem; }
/* .analytics-consent's own `display: flex` has the same specificity as the
   UA stylesheet's `[hidden] { display: none }` default and, being an author
   rule, wins the cascade regardless -- so toggling the `hidden` attribute
   alone never hid the banner. This rule is more specific and restores the
   expected hidden behavior without an !important escape hatch. */
.analytics-consent[hidden] { display: none; }
.analytics-consent p { flex: 1 1 260px; min-width: 0; margin: 0; color: var(--muted); }
.analytics-consent .actions { display: flex; flex-wrap: wrap; gap: 8px; }
.analytics-consent .button { min-height: 40px; padding: 8px 14px; }
.footer-link-button { padding: 0; border: 0; background: transparent; color: var(--muted); font: inherit; font-weight: 650; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.footer-link-button:hover { color: var(--text); }
.site-header { border-bottom: 1px solid var(--line); background: rgba(13, 13, 16, .96); }
.header-row { min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { font-weight: 800; text-decoration: none; letter-spacing: -.02em; }
.site-navigation { display: flex; align-items: center; gap: 18px; }
.site-navigation a { color: var(--muted); text-decoration: none; font-weight: 650; }
.site-navigation a:hover { color: var(--text); }
.menu-toggle { display: none; min-height: 44px; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); color: var(--text); font-weight: 720; cursor: pointer; }
.menu-icon, .menu-icon::before, .menu-icon::after { width: 18px; height: 2px; display: block; border-radius: 2px; background: currentColor; }
.menu-icon { position: relative; }
.menu-icon::before, .menu-icon::after { position: absolute; left: 0; content: ""; }
.menu-icon::before { top: -6px; }
.menu-icon::after { top: 6px; }
main { min-height: 65vh; }
.tool, .supporter-page { padding-block: clamp(36px, 7vw, 72px); }
.intro { max-width: 760px; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 12px; font-size: clamp(2rem, 7vw, 3.5rem); line-height: 1.05; letter-spacing: -.045em; }
h2 { line-height: 1.15; letter-spacing: -.025em; }
.intro > p, .lede { color: var(--muted); font-size: clamp(1rem, 2.6vw, 1.18rem); }
.stage-badge { display: inline-flex; margin-bottom: 16px; padding: 5px 10px; border: 1px solid #694351; border-radius: 999px; color: #ffb1c5; font-size: .78rem; font-weight: 750; text-transform: uppercase; letter-spacing: .05em; }
.extract-form { margin-top: 30px; }
label { display: block; margin-bottom: 8px; font-weight: 720; }
.input-row { display: flex; gap: 10px; }
input { min-width: 0; min-height: 50px; flex: 1; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: #101014; color: var(--text); font-size: 16px; }
input::placeholder { color: #77737d; }
input:focus-visible, button:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid #ff94af; outline-offset: 3px; }
.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; padding: 11px 18px; border: 1px solid transparent; border-radius: 10px; font-weight: 760; text-decoration: none; cursor: pointer; }
.button:disabled { opacity: .58; cursor: wait; }
.primary { background: var(--accent); color: #16060a; }
.primary:hover { background: #ff6b8f; }
.secondary { border-color: var(--line); background: var(--panel-2); color: var(--text); }
.quiet { border-color: #754153; background: transparent; color: #ffb4c7; }
.clear-url { margin-top: 8px; padding: 4px 0; border: 0; background: transparent; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.limits { margin-block: 18px; display: flex; flex-wrap: wrap; gap: 9px 22px; color: var(--muted); font-size: .9rem; }
.limits strong { color: var(--text); }
.supported { margin-top: 22px; color: var(--muted); }
.supported h2 { margin-bottom: 10px; color: var(--text); font-size: .95rem; }
.supported ul { margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(105px, max-content)); gap: 8px; list-style: none; }
.supported li { min-width: 0; padding: 6px 9px; border: 1px solid var(--line); border-radius: 999px; font-size: .82rem; text-align: center; overflow-wrap: anywhere; }
.supported li a { text-decoration: none; }
.supported li:hover { border-color: #57545f; color: var(--text); }
.supported p { margin: 10px 0 0; font-size: .82rem; }
.supported.shell { margin-top: -34px; padding-bottom: 34px; }
.status { min-height: 28px; margin-top: 20px; color: var(--muted); }
.status.error { color: #ff9eb4; }
.results, .status, .notice, .activation { scroll-margin-top: 24px; }
.results { margin-top: 26px; }
.result-count { margin-bottom: 10px; color: var(--good); font-weight: 780; }
.media-summary { display: grid; grid-template-columns: minmax(0, 180px) 1fr; gap: 20px; align-items: center; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.media-summary img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 9px; background: var(--panel-2); }
.media-summary .result-preview { width: 100%; max-height: 60vh; border-radius: 9px; background: #000; }
.media-summary h2 { margin-bottom: 6px; overflow-wrap: anywhere; }
.media-summary.no-thumbnail { grid-template-columns: 1fr; }
.preview-notice { margin-top: 8px; font-size: .78rem; }
.media-summary h2 { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.eyebrow { margin-bottom: 6px; color: #ff91ad; font-size: .78rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.muted, .field-note { color: var(--muted); }
.format-list { margin-top: 14px; display: grid; gap: 10px; }
.format-group { min-width: 0; margin: 0; padding: 0; border: 0; display: grid; gap: 8px; }
.format-group + .format-group { margin-top: 10px; }
.format-group legend { width: 100%; margin-bottom: 7px; color: var(--muted); font-size: .86rem; font-weight: 760; }
.format-row { min-height: 64px; margin: 0; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 11px; background: var(--panel); cursor: pointer; }
.format-row:hover { border-color: #57545f; }
.format-row.selected { border-color: var(--accent); background: #22161b; box-shadow: inset 0 0 0 1px var(--accent); }
.format-row input { min-width: auto; min-height: auto; width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }
.format-copy { min-width: 0; display: grid; gap: 2px; }
.format-copy strong { overflow-wrap: anywhere; }
.format-copy > span { color: var(--muted); font-size: .84rem; }
.format-badge { color: var(--good); font-size: .78rem; font-weight: 760; text-align: right; }
.format-badge.supporter { color: var(--warn); }
.format-badge.unsupported { color: #ff9eb4; }
.primary-download { width: 100%; margin-top: 14px; }
.download-status:empty { margin-top: 0; min-height: 0; }
.download-target { position: fixed; width: 1px; height: 1px; inset: auto auto 0 0; border: 0; opacity: 0; pointer-events: none; }
.notice, .sponsored { margin-top: 16px; padding: 16px; border-radius: 12px; }
.notice { border: 1px solid #66502c; background: #211c13; }
.notice p { margin: 5px 0 14px; color: #ded0b6; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; }
.sponsored { border: 1px solid #49444e; background: #18171b; }
.sponsored span { display: block; color: var(--muted); font-size: .72rem; text-transform: uppercase; }
.sponsored strong { display: block; margin-block: 4px 8px; }
.sponsored a { color: #eeb1c1; }
.how { padding-block: 0 64px; }
.seo-content { max-width: 820px; padding-block: 12px 72px; }
.seo-content h2 { margin-top: 34px; }
.seo-content p, .seo-content li { color: var(--muted); }
.steps { padding-left: 22px; display: grid; gap: 10px; }
.steps strong { color: var(--text); }
.content-section ul, .related-tools ul { padding-left: 22px; display: grid; gap: 9px; color: var(--muted); }
.evidence-key, .resource-policy, .related-tools { margin-top: 34px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.evidence-key h2, .resource-policy h2, .related-tools h2 { margin-top: 0; }
.evidence-key dl { margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.evidence-key dl div { min-width: 0; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); }
.evidence-key dt { font-weight: 800; }
.evidence-key dd { margin: 4px 0 0; color: var(--muted); font-size: .88rem; }
.related-tools li::marker { color: var(--accent); }
.related-tools a { font-weight: 740; text-underline-offset: 3px; }
.faq { margin-top: 38px; }
.faq article { padding-block: 16px; border-top: 1px solid var(--line); }
.faq h3 { margin: 0 0 6px; font-size: 1rem; }
.faq p { margin-bottom: 0; }
.breadcrumbs { margin-bottom: 26px; display: flex; flex-wrap: wrap; gap: 8px; color: var(--muted); font-size: .85rem; }
.breadcrumbs a { color: var(--text); }
.simple-page, .error-page { padding-block: clamp(36px, 7vw, 72px); }
.simple-page > .lede { max-width: 760px; }
.supported-directory { margin-top: 28px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.supported-directory article, .universal-note { padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.supported-directory h2 { margin-bottom: 7px; font-size: 1rem; }
.supported-directory p, .universal-note p { margin-bottom: 0; color: var(--muted); }
.universal-note { margin-top: 14px; }
.comparison-wrap { max-width: 100%; margin-top: 28px; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.comparison-wrap:focus-visible { outline: 3px solid #ff94af; outline-offset: 3px; }
.source-comparison { width: 100%; min-width: 760px; border-collapse: collapse; text-align: left; }
.source-comparison caption { padding: 18px; color: var(--text); font-weight: 800; text-align: left; }
.source-comparison th, .source-comparison td { padding: 13px 15px; border-top: 1px solid var(--line); vertical-align: top; }
.source-comparison thead th { color: var(--text); font-size: .82rem; letter-spacing: .04em; text-transform: uppercase; }
.source-comparison tbody th { width: 18%; }
.source-comparison td { color: var(--muted); font-size: .9rem; }
.source-comparison a { text-underline-offset: 3px; }
.directory-section { max-width: 820px; margin-top: 34px; }
.directory-section p { color: var(--muted); }
.error-page { min-height: 58vh; }
.feature-grid, .tier-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.feature-grid article, .tier-grid article, .activation, .donate, .terms { padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.feature-grid p { margin: 7px 0 0; color: var(--muted); }
.supporter-page > h1 { max-width: 760px; }
.supporter-page .lede { max-width: 720px; }
.tier-grid { grid-template-columns: 1fr 1fr; margin-block: 30px 16px; }
.tier-grid article { padding: clamp(20px, 4vw, 30px); }
.tier-grid ul { padding-left: 20px; color: var(--muted); }
.supporter-tier { border-color: #774356 !important; }
.tier-size { display: block; margin-bottom: 14px; font-size: 2rem; }
.activation, .donate, .terms { margin-top: 16px; }
.activation form { margin-top: 18px; }
.field-note { margin-top: 7px; font-size: .82rem; }
.terms p:last-child, .site-footer p { margin-bottom: 0; }
.site-footer { padding-block: 30px; border-top: 1px solid var(--line); color: var(--muted); font-size: .85rem; }
.footer-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 28px; }
.site-footer strong { color: var(--text); }
.footer-links { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 7px 16px; }
.footer-links a { color: var(--muted); font-weight: 650; text-underline-offset: 3px; }

@media (max-width: 700px) {
  .shell { width: min(100% - 24px, 1040px); }
  .header-row { min-height: 58px; flex-wrap: wrap; gap: 0 12px; padding-block: 6px; }
  .menu-toggle { display: inline-flex; }
  .site-navigation { width: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 8px; padding: 8px 0 5px; border-top: 1px solid var(--line); }
  .site-navigation[data-mobile-collapsed="true"] { display: none; }
  .site-navigation a { min-height: 42px; display: flex; align-items: center; padding: 7px 8px; border-radius: 8px; font-size: .9rem; }
  .site-navigation a:hover { background: var(--panel); }
  .tool { padding-block: 24px 42px; }
  .intro h1 { font-size: clamp(1.85rem, 10vw, 2.65rem); }
  .intro > p { font-size: .98rem; }
  .stage-badge { margin-bottom: 11px; }
  .extract-form { margin-top: 22px; }
  .input-row { flex-direction: column; }
  .input-row .button { width: 100%; }
  .limits { margin-block: 14px; gap: 5px 14px; font-size: .82rem; }
  .media-summary { grid-template-columns: 1fr; }
  .media-summary img { width: min(100%, 360px); }
  .media-summary .result-preview { max-height: 46vh; }
  .feature-grid, .tier-grid, .footer-grid { grid-template-columns: 1fr; }
  .supported-directory { grid-template-columns: 1fr; }
  .evidence-key dl { grid-template-columns: 1fr; }
  .supported.shell { margin-top: 10px; padding-bottom: 32px; }
  .supported ul { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .site-footer { padding-block: 24px; }
  .footer-grid { gap: 20px; }
}

@media (max-width: 430px) {
  .shell { width: min(100% - 20px, 1040px); }
  .media-summary { padding: 13px; gap: 13px; }
  .media-summary h2 { font-size: 1.15rem; }
  .format-row { min-height: 68px; gap: 10px; padding: 11px 12px; }
  .format-copy strong { font-size: .94rem; }
  .format-copy > span { font-size: .79rem; }
  .supported ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 375px) {
  .format-row { grid-template-columns: auto minmax(0, 1fr); }
  .format-badge { grid-column: 2; text-align: left; }
  .actions { flex-direction: column; }
  .actions .button { width: 100%; }
  .site-navigation { grid-template-columns: 1fr; }
}

@media (max-width: 300px) {
  .shell { width: min(100% - 16px, 1040px); }
  .brand { font-size: .95rem; }
  .menu-toggle { padding-inline: 8px; }
  .format-row { padding-inline: 9px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
