/* =====================================================================
   VAULTNET — neobrutalist component layer (loaded AFTER Tailwind CDN)
   Tokens: paper #f5f2e9 · ink #111111 · accent #2b2bff
   Rules: radius 0 everywhere, hard offset shadows, 2–4px ink borders.
   ===================================================================== */

:root {
  --paper: #f5f2e9;
  --ink: #111111;
  --accent: #2b2bff;
  --accent-fg: #ffffff;
  --shadow: 6px 6px 0 var(--ink);
  --shadow-sm: 3px 3px 0 var(--ink);
  --shadow-lg: 10px 10px 0 var(--ink);
  --font-display: "Archivo Black", Archivo, "Space Grotesk", Impact, sans-serif;
  --font-sans: "Space Grotesk", system-ui, -apple-system, sans-serif;
  --font-mono: "Space Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --header-h: 5rem;
}

/* Light accents get ink text; dark accents get white text */
[data-cat="email"], [data-cat="anonymity"] { --accent-fg: #111111; }
[data-cat="vpn"], [data-cat="messengers"], [data-cat="tools"] { --accent-fg: #ffffff; }

* { border-radius: 0 !important; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  position: relative;
}
/* Paper grain */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: 1000; pointer-events: none;
  opacity: .045; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.container-x { width: 100%; max-width: 1400px; margin: 0 auto; padding-left: 1rem; padding-right: 1rem; }
@media (min-width: 640px) { .container-x { padding-left: 1.5rem; padding-right: 1.5rem; } }
@media (min-width: 1024px) { .container-x { padding-left: 2.5rem; padding-right: 2.5rem; } }

/* Exposed grid background */
.bg-grid {
  background-color: var(--paper);
  background-image:
    linear-gradient(to right, rgba(17,17,17,.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(17,17,17,.07) 1px, transparent 1px);
  background-size: 48px 48px;
}

/* ---------- Typography ---------- */
.display {
  font-family: var(--font-display);
  font-weight: 400;
  text-transform: uppercase;
  line-height: .95;
  letter-spacing: -.03em;
  overflow-wrap: anywhere;
}
.kicker {
  font-family: var(--font-mono);
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .22em;
  font-weight: 700;
}
.kicker--inverse { color: var(--paper); }
.kicker--on-accent { color: var(--accent-fg); }

.hero__title { font-size: clamp(2.25rem, 10.5vw, 10.5rem); max-width: 14ch; }
.page-title { font-size: clamp(2.6rem, 9vw, 7.5rem); }
.article-title { font-size: clamp(2rem, 6vw, 4.75rem); max-width: 22ch; line-height: 1; }
.section-title { font-size: clamp(2rem, 5vw, 4rem); margin-top: .5rem; }

.section-head--row {
  display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.5rem;
}

/* Text split (hero headline): words are atomic — line breaks only at the real spaces BETWEEN .word spans. */
.word {
  display: inline-block; white-space: nowrap; overflow-wrap: normal; word-break: keep-all;
  overflow: hidden; vertical-align: top; padding-bottom: .12em; margin-bottom: -.12em;
}
.char { display: inline-block; white-space: nowrap; will-change: transform; }

/* ---------- Icons (single SVG set, see templates/_icons.html) ---------- */
/* Size comes from the SVG width/height attributes (icon(name, size)); the helpers below override when needed. */
.icon { display: inline-block; vertical-align: middle; flex-shrink: 0; }
.icon--sm { width: 1rem; height: 1rem; }
.icon--md { width: 1.5rem; height: 1.5rem; }
.icon--lg { width: 2.5rem; height: 2.5rem; }
.btn-brutal .icon, .chip .icon, .tab .icon, .copy-link .icon, .result-card__more .icon, .result-card__link .icon, .cat-block__cta .icon, .top-list__views .icon, .related-list__meta .icon { margin-left: .1em; }
.btn-brutal:hover .icon--arrow-right { translate: 3px 0; }
.btn-brutal .icon { transition: translate .15s; }

/* ---------- Initial hidden states — ONLY when JS + GSAP are confirmed ---------- */
html.js [data-reveal],
html.js [data-intro],
html.js [data-split],
html.js [data-result] { opacity: 0; }
html.anim-fallback [data-reveal],
html.anim-fallback [data-intro],
html.anim-fallback [data-split],
html.anim-fallback [data-result] { opacity: 1 !important; transform: none !important; }

/* ---------- Header ---------- */
.site-header { transition: box-shadow .2s; }
.site-header.is-scrolled { box-shadow: 0 6px 0 var(--ink); }
.logo-mark {
  display: inline-block; width: 1.5rem; height: 1.5rem; flex: none;
  background: var(--accent); border: 3px solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
  transition: transform .2s, box-shadow .2s;
}
.wordmark:hover .logo-mark { transform: rotate(90deg) translate(-1px,-1px); }
.logo-mark--inverse { border-color: var(--paper); box-shadow: 3px 3px 0 var(--paper); }

.nav-link {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: 0 1.25rem; font-weight: 700; text-transform: uppercase; font-size: .9rem; letter-spacing: .04em;
  border-left: 4px solid var(--ink); position: relative;
  transition: background .15s, color .15s;
}
.nav-link:first-child { border-left: 0; }
.nav-link__idx { font-family: var(--font-mono); font-size: .65rem; font-weight: 400; opacity: .6; }
.nav-link:hover { background: var(--ink); color: var(--paper); }
.nav-link:hover .nav-link__idx { opacity: 1; color: var(--accent); }

.lang-switch { display: inline-flex; border: 3px solid var(--ink); box-shadow: var(--shadow-sm); background: #fff; }
.lang-switch a {
  font-family: var(--font-mono); font-weight: 700; font-size: .75rem; letter-spacing: .1em;
  padding: .45rem .8rem; border-right: 3px solid var(--ink); transition: background .15s, color .15s;
}
.lang-switch a:last-child { border-right: 0; }
.lang-switch a.is-active { background: var(--accent); color: #fff; }
.lang-switch a:not(.is-active):hover { background: var(--ink); color: var(--paper); }
.lang-switch--lg a { font-size: 1rem; padding: .8rem 1.4rem; }
.lang-switch--inverse { border-color: var(--paper); box-shadow: 3px 3px 0 var(--paper); background: var(--ink); }
.lang-switch--inverse a { color: var(--paper); border-color: var(--paper); }
.lang-switch--inverse a:not(.is-active):hover { background: var(--paper); color: var(--ink); }

.menu-btn {
  width: 3rem; height: 3rem; align-self: center; display: inline-grid; place-items: center;
  padding: 0; border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow-sm); color: var(--ink); cursor: pointer;
  transition: translate .12s, box-shadow .12s;
}
.menu-btn:hover { translate: -2px -2px; box-shadow: 5px 5px 0 var(--ink); }
.menu-btn .icon { grid-area: 1 / 1; transition: transform .2s, opacity .2s; }
.menu-btn .menu-btn__close { opacity: 0; transform: rotate(-90deg) scale(.6); }
.menu-btn[aria-expanded="true"] .menu-btn__open { opacity: 0; transform: rotate(90deg) scale(.6); }
.menu-btn[aria-expanded="true"] .menu-btn__close { opacity: 1; transform: none; }
.menu-close {
  display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; color: var(--ink);
  border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow-sm); cursor: pointer; transition: background .15s, color .15s;
}
.menu-close:hover { background: var(--ink); color: var(--paper); }

/* ---------- Mobile menu ---------- */
.mobile-menu {
  position: fixed; inset: 0; z-index: 50; background: var(--paper);
  background-image:
    linear-gradient(to right, rgba(17,17,17,.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(17,17,17,.07) 1px, transparent 1px);
  background-size: 48px 48px;
  overflow-y: auto;
}
.mobile-menu__inner { min-height: 100%; display: flex; flex-direction: column; }
.mobile-nav { display: flex; flex-direction: column; margin-top: 1rem; }
.mobile-nav a {
  display: flex; align-items: baseline; gap: 1rem;
  font-family: var(--font-display); text-transform: uppercase; font-size: clamp(2.2rem, 10vw, 4rem); line-height: 1;
  padding: 1rem 0; border-bottom: 3px solid var(--ink);
}
.mobile-nav a span { font-family: var(--font-mono); font-size: .8rem; letter-spacing: .1em; opacity: .6; }
.mobile-nav a:hover { color: var(--accent); }
body.menu-open { overflow: hidden; }

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; border-bottom: 4px solid var(--ink); position: relative; }
.marquee--ink { background: var(--ink); color: var(--paper); }
.marquee--accent { background: var(--accent); color: #fff; border-top: 4px solid var(--ink); }
.marquee__track { display: flex; width: max-content; animation: marquee 32s linear infinite; }
.marquee__track--reverse { animation-direction: reverse; animation-duration: 40s; }
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__group {
  display: flex; align-items: center; gap: 1.25rem; flex: none; padding: .5rem 1.25rem .5rem 0;
  font-family: var(--font-mono); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; white-space: nowrap;
}
.marquee--accent .marquee__group { font-size: .9rem; padding-top: .75rem; padding-bottom: .75rem; font-weight: 700; }
.marquee__sep, .marquee__dot { opacity: .55; }
.marquee__item { display: inline-flex; align-items: center; gap: .5rem; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Buttons ---------- */
.btn-brutal {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .85rem 1.4rem; background: #fff; color: var(--ink);
  border: 3px solid var(--ink); box-shadow: var(--shadow);
  font-family: var(--font-sans); font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: .9rem; line-height: 1;
  cursor: pointer; white-space: nowrap; text-decoration: none;
  transition: translate .15s ease, box-shadow .15s ease, background .15s, color .15s;
}
.btn-brutal:hover { translate: -3px -3px; box-shadow: 9px 9px 0 var(--ink); }
.btn-brutal:active { translate: 3px 3px; box-shadow: 1px 1px 0 var(--ink); }
.btn-brutal--accent { background: var(--accent); color: #fff; }
.btn-brutal--accent:hover { background: var(--ink); }
.btn-brutal--ink { background: var(--ink); color: var(--paper); }
.btn-brutal--paper { background: var(--paper); box-shadow: var(--shadow); }
.btn-brutal--lg { padding: 1.1rem 1.8rem; font-size: 1.05rem; }
.btn-brutal--xl { padding: 1.3rem 2.2rem; font-size: 1.2rem; box-shadow: var(--shadow-lg); }
.btn-brutal--xl:hover { box-shadow: 14px 14px 0 var(--ink); }

/* ---------- Tags & chips ---------- */
.tag {
  display: inline-flex; align-items: center; gap: .35rem;
  font-family: var(--font-mono); font-size: .68rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  padding: .3rem .55rem; border: 2px solid var(--ink);
  background: var(--accent); color: var(--accent-fg);
  box-shadow: 2px 2px 0 var(--ink);
}
.tag--outline { background: #fff; color: var(--ink); }
.tag__icon { stroke-width: 2.75; }
.chip {
  display: inline-flex; align-items: center; gap: .4rem;
  font-family: var(--font-mono); font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: .55rem .9rem; border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow-sm);
  transition: translate .12s, box-shadow .12s, background .12s, color .12s;
}
.chip:hover { translate: -2px -2px; box-shadow: 5px 5px 0 var(--ink); }
.chip.is-active { background: var(--accent); color: var(--accent-fg); }
.chip[data-cat].is-active { background: var(--accent); color: var(--accent-fg); }
.chip:not([data-cat]).is-active { background: var(--ink); color: var(--paper); }
.sticky-filters { position: sticky; top: var(--header-h); z-index: 30; }
@media (max-width: 767px) { .sticky-filters { top: 4rem; position: static; } }

/* ---------- Cards ---------- */
.cards-grid { display: grid; gap: 1.75rem; }
@media (min-width: 640px) { .cards-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .cards-grid { grid-template-columns: repeat(3, 1fr); gap: 2rem; } }

.card-brutal {
  display: flex; flex-direction: column; gap: 1rem; height: 100%;
  background: #fff; border: 3px solid var(--ink); box-shadow: var(--shadow); padding: 1.5rem;
  transition: translate .18s ease, box-shadow .18s ease;
}
.card-brutal:hover { translate: -5px -5px; box-shadow: 12px 12px 0 var(--ink); }
.card-brutal__top { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.card-brutal__title {
  font-family: var(--font-sans); font-weight: 700; font-size: 1.35rem; line-height: 1.15; letter-spacing: -.01em;
  text-decoration: underline transparent; text-decoration-thickness: 3px; text-underline-offset: 4px; transition: text-decoration-color .15s;
}
.card-brutal:hover .card-brutal__title { text-decoration-color: var(--accent); }
.card-brutal__desc { font-size: .95rem; line-height: 1.55; color: rgba(17,17,17,.8); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card-brutal__meta { margin-top: auto; display: flex; justify-content: space-between; align-items: center; padding-top: 1rem; border-top: 2px solid var(--ink); }
.card-brutal__arrow { display: inline-flex; line-height: 1; transition: translate .18s; }
.card-brutal:hover .card-brutal__arrow { translate: 6px 0; }

/* ---------- Hero ---------- */
.hero { --accent: #2b2bff; }
.hero__bignum {
  position: absolute; right: -.05em; top: -.15em; z-index: 0; pointer-events: none;
  font-family: var(--font-display); font-size: clamp(14rem, 40vw, 34rem); line-height: 1; color: transparent;
  -webkit-text-stroke: 2px rgba(17,17,17,.12);
}
.hero .container-x { position: relative; z-index: 1; }
.sticker { position: relative; width: 190px; height: 190px; }
.sticker__ring { width: 100%; height: 100%; animation: spin 18s linear infinite; font-family: var(--font-mono); font-weight: 700; fill: var(--ink); }
.sticker__core {
  position: absolute; inset: 0; margin: auto; width: 84px; height: 84px; display: grid; place-items: center;
  background: var(--accent); color: #fff; border: 3px solid var(--ink); box-shadow: var(--shadow); font-size: 1.6rem; transform: rotate(-8deg);
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Stats ---------- */
.stats-grid { display: grid; gap: 0; border: 4px solid var(--ink); box-shadow: var(--shadow-lg); background: #fff; }
@media (min-width: 768px) { .stats-grid { grid-template-columns: 1.3fr 1fr 1.3fr; } }
.stat { padding: 2rem 1.75rem 1.75rem; display: flex; flex-direction: column; gap: .5rem; border-bottom: 4px solid var(--ink); }
.stat:last-child { border-bottom: 0; }
@media (min-width: 768px) { .stat { border-bottom: 0; border-right: 4px solid var(--ink); } .stat:last-child { border-right: 0; } }
.stat__num { font-family: var(--font-display); font-size: clamp(3.5rem, 8vw, 7rem); line-height: .9; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.stat__label { font-family: var(--font-mono); font-size: .75rem; text-transform: uppercase; letter-spacing: .2em; font-weight: 700; }
.stat--accent { background: var(--accent); color: #fff; }
.stat--ink { background: var(--ink); color: var(--paper); }

.top-list { border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow); }
.top-list li + li { border-top: 2px solid var(--ink); }
.top-list a { display: grid; grid-template-columns: auto 1fr auto; gap: 1rem; align-items: center; padding: .85rem 1rem; font-weight: 700; transition: background .15s, color .15s; }
.top-list a:hover { background: var(--ink); color: var(--paper); }
.top-list__idx, .top-list__views { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .1em; font-weight: 400; }
.top-list__views { display: inline-flex; align-items: center; gap: .35rem; }
.top-list__title { font-size: .95rem; line-height: 1.3; }

/* ---------- Category blocks (asymmetric grid) ---------- */
.cat-grid { display: grid; gap: 1.5rem; }
@media (min-width: 768px) { .cat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) {
  .cat-grid { grid-template-columns: repeat(3, 1fr); grid-auto-rows: minmax(240px, auto); gap: 1.75rem; }
  .cat-grid .cat-block:nth-child(1) { grid-column: span 2; }
  .cat-grid .cat-block:nth-child(2) { grid-row: span 2; }
  .cat-grid .cat-block:nth-child(3) { grid-row: span 1; }
  .cat-grid .cat-block:nth-child(5) { grid-column: span 2; }
}
.cat-block {
  position: relative; display: flex; flex-direction: column; gap: .75rem; padding: 1.75rem; min-height: 240px;
  background: var(--accent); color: var(--accent-fg); border: 4px solid var(--ink); box-shadow: var(--shadow);
  transition: translate .2s ease, box-shadow .2s ease; overflow: hidden;
}
.cat-block:hover { translate: -6px -6px; box-shadow: 14px 14px 0 var(--ink); }
.cat-block__idx { font-family: var(--font-mono); font-size: .75rem; letter-spacing: .2em; font-weight: 700; }
/* Icon sits on a white plate so it reads in the category's accent colour on the accent background */
.cat-block__icon {
  position: absolute; right: 1.25rem; top: 1.25rem; display: grid; place-items: center; width: 3.75rem; height: 3.75rem;
  background: #fff; color: var(--accent); border: 3px solid var(--ink); box-shadow: 3px 3px 0 var(--ink); line-height: 1; transition: transform .25s;
}
.cat-block:hover .cat-block__icon { transform: rotate(-12deg) scale(1.1); }
.cat-block__name { font-size: clamp(2rem, 4vw, 3.25rem); margin-top: auto; }
.cat-block__desc { font-size: .95rem; line-height: 1.5; max-width: 46ch; opacity: .95; }
.cat-block__cta { font-family: var(--font-mono); font-size: .75rem; text-transform: uppercase; letter-spacing: .15em; font-weight: 700; margin-top: .5rem; }
.cat-grid .cat-block:nth-child(2) .cat-block__name { font-size: clamp(2.4rem, 5vw, 4rem); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 4px solid var(--ink); background: #fff; box-shadow: var(--shadow-lg); -webkit-overflow-scrolling: touch; }
.table-brutal { width: 100%; border-collapse: collapse; min-width: 640px; }
.table-brutal thead th {
  background: var(--ink); color: var(--paper); text-align: left; padding: .85rem 1rem;
  font-family: var(--font-mono); font-size: .68rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700;
  border-right: 2px solid rgba(245,242,233,.25); white-space: nowrap; user-select: none;
}
.table-brutal thead th:last-child { border-right: 0; }
.table-brutal tbody td { padding: .9rem 1rem; border-top: 2px solid var(--ink); border-right: 2px solid var(--ink); vertical-align: middle; font-size: .95rem; }
.table-brutal tbody td:last-child { border-right: 0; }
.table-brutal tbody tr:nth-child(even) { background: var(--paper); }
.table-brutal tbody tr:hover { background: #fffbe6; }
.table-brutal .th-idx, .table-brutal .td-idx { width: 3.5rem; text-align: center; }
.table-brutal .cell-name { font-weight: 700; font-size: 1.05rem; }
.table-brutal .cell-bool, .table-brutal .cell-price { text-align: center; }
.th-btn { all: unset; cursor: pointer; display: inline-flex; align-items: center; gap: .4rem; font: inherit; color: inherit; letter-spacing: inherit; text-transform: inherit; }
.th-sort { opacity: .5; display: inline-grid; place-items: center; }
.th-sort .icon { grid-area: 1 / 1; }
.th-sort .th-sort__asc, .th-sort .th-sort__desc { display: none; }
th[aria-sort="ascending"] .th-sort, th[aria-sort="descending"] .th-sort { opacity: 1; color: #ffd23f; }
th[aria-sort="ascending"] .th-sort .th-sort__none, th[aria-sort="descending"] .th-sort .th-sort__none { display: none; }
th[aria-sort="ascending"] .th-sort .th-sort__asc { display: inline-block; }
th[aria-sort="descending"] .th-sort .th-sort__desc { display: inline-block; }
th[aria-sort="ascending"] { box-shadow: inset 0 -4px 0 var(--accent); }
th[aria-sort="descending"] { box-shadow: inset 0 4px 0 var(--accent); }
.bool { display: inline-grid; place-items: center; width: 1.75rem; height: 1.75rem; border: 2px solid var(--ink); line-height: 1; }
.bool .icon { stroke-width: 3; }
.bool--yes { background: #00c26e; color: var(--ink); }
.bool--no { background: #ff3b30; color: #fff; }
.price-free { background: var(--ink); color: var(--paper); padding: .15rem .45rem; font-family: var(--font-mono); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; }
.stars { display: inline-flex; align-items: center; gap: .1rem; line-height: 1; white-space: nowrap; }
.star { display: inline-flex; color: var(--ink); }
.star--full { color: var(--ink); }
.star--empty { color: var(--ink); opacity: .35; }
.stars__num { font-family: var(--font-mono); font-size: .7rem; margin-left: .4rem; font-weight: 700; }
.ranking-panel[hidden] { display: none; }

/* Tabs */
.tabs { display: flex; flex-wrap: wrap; align-items: stretch; }
.tab {
  display: inline-flex; align-items: center; gap: .6rem; padding: 1rem 1.5rem;
  font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: .95rem;
  border-right: 4px solid var(--ink); transition: background .15s, color .15s; position: relative;
}
.tab__idx { font-family: var(--font-mono); font-size: .65rem; opacity: .6; }
.tab__count { font-family: var(--font-mono); font-size: .65rem; border: 2px solid currentColor; padding: .1rem .4rem; }
.tab:hover { background: var(--paper); }
.tab.is-active { background: var(--accent); color: var(--accent-fg); }
.tab.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 4px; background: var(--accent); }
.tabs__hint { align-self: center; padding-right: .5rem; }

/* Note block */
.note-block { display: grid; grid-template-columns: auto 1fr; border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow); }
.note-block__label { background: var(--ink); color: var(--paper); font-family: var(--font-mono); font-size: .7rem; letter-spacing: .2em; font-weight: 700; padding: 1rem .75rem; writing-mode: vertical-rl; transform: rotate(180deg); text-align: center; }
.note-block p, .note-block ol { padding: 1.25rem 1.5rem; font-size: .95rem; line-height: 1.6; }
.notes-list li { display: grid; grid-template-columns: auto 1fr; gap: 1rem; padding: .6rem 0; border-top: 2px dashed rgba(17,17,17,.3); }
.notes-list li:first-child { border-top: 0; padding-top: 0; }
.notes-list__idx { font-family: var(--font-mono); font-weight: 700; font-size: .75rem; letter-spacing: .1em; padding-top: .2rem; }

/* ---------- Finder ---------- */
.finder-progress { border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow); padding: 1rem 1.25rem; display: grid; gap: .75rem; }
.finder-progress__text { display: flex; justify-content: space-between; align-items: center; }
.finder-progress__track { height: 14px; border: 2px solid var(--ink); background: var(--paper); }
.finder-progress__bar { height: 100%; background: var(--accent); transition: width .35s cubic-bezier(.2,.8,.2,1); }
.finder-steps { display: grid; gap: 2rem; }
.q-block { border: 4px solid var(--ink); background: #fff; box-shadow: var(--shadow); padding: 0 1.5rem 1.5rem; margin: 0; min-width: 0; transition: box-shadow .2s; }
.q-block.is-answered { box-shadow: 8px 8px 0 var(--accent); }
.q-block__legend { display: flex; align-items: center; gap: 1rem; padding: 0 .5rem; margin-left: -.5rem; font-weight: 700; font-size: clamp(1.15rem, 2.2vw, 1.5rem); line-height: 1.2; background: #fff; }
.q-block__idx { font-family: var(--font-mono); font-size: .8rem; background: var(--ink); color: var(--paper); padding: .35rem .5rem; letter-spacing: .1em; flex: none; }
.q-block__check { display: none; background: var(--accent); color: #fff; width: 1.6rem; height: 1.6rem; place-items: center; border: 2px solid var(--ink); }
.q-block__check .icon { stroke-width: 3; }
.q-block.is-answered .q-block__check { display: grid; }
.q-options { display: grid; gap: .9rem; margin-top: 1.25rem; }
@media (min-width: 640px) { .q-options { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .q-options { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); } }
.pill-option {
  position: relative; display: flex; align-items: flex-start; gap: .85rem; padding: 1rem 1.1rem; cursor: pointer;
  border: 3px solid var(--ink); background: var(--paper); box-shadow: var(--shadow-sm); font-weight: 500; line-height: 1.35;
  transition: translate .12s, box-shadow .12s, background .12s, color .12s;
  --accent: #2b2bff; --accent-fg: #fff;
}
.pill-option:hover { translate: -2px -2px; box-shadow: 5px 5px 0 var(--ink); }
.pill-option input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.pill-option__idx { font-family: var(--font-mono); font-weight: 700; font-size: .75rem; border: 2px solid var(--ink); width: 1.6rem; height: 1.6rem; display: grid; place-items: center; flex: none; background: #fff; color: var(--ink); }
.pill-option:has(input:checked), .pill-option.is-checked { background: var(--accent); color: var(--accent-fg); translate: -3px -3px; box-shadow: 7px 7px 0 var(--ink); }
.pill-option:has(input:checked) .pill-option__idx, .pill-option.is-checked .pill-option__idx { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.pill-option:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 3px; }

/* Result */
.result-hero { background: var(--ink); color: var(--paper); border: 4px solid var(--ink); box-shadow: 10px 10px 0 var(--accent); padding: 2rem 1.75rem; }
.result-hero__title { font-size: clamp(2.2rem, 7vw, 5.5rem); }
.result-grid { display: grid; gap: 1.75rem; }
@media (min-width: 640px) { .result-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1200px) { .result-grid { grid-template-columns: repeat(4, 1fr); } }
.result-card { display: flex; flex-direction: column; gap: .9rem; background: #fff; border: 4px solid var(--ink); box-shadow: var(--shadow); padding: 1.5rem; border-top: 14px solid var(--accent); transition: translate .2s, box-shadow .2s; }
.result-card:hover { translate: -4px -4px; box-shadow: 12px 12px 0 var(--ink); }
.result-card__head { display: flex; justify-content: space-between; align-items: center; font-family: var(--font-mono); font-size: .7rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700; }
.result-card__idx { opacity: .5; }
.result-card__type { display: inline-flex; align-items: center; gap: .4rem; }
.result-card__icon { display: inline-flex; }
.result-card__name { font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1; }
.result-card__why { font-size: .95rem; line-height: 1.55; }
.result-card__why .kicker { display: block; margin-bottom: .25rem; }
.result-card__link { font-family: var(--font-mono); font-size: .75rem; text-decoration: underline; text-decoration-thickness: 2px; }
.result-card__more { margin-top: auto; padding-top: .9rem; border-top: 2px solid var(--ink); font-family: var(--font-mono); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 700; }
.result-card__more:hover { color: var(--accent); }

/* ---------- Article ---------- */
.progress-bar { position: fixed; top: 0; left: 0; height: 8px; width: 0; background: var(--accent); z-index: 60; border-right: 3px solid var(--ink); pointer-events: none; }
.breadcrumb { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.breadcrumb a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb__sep { opacity: .5; }
.breadcrumb--on-accent { color: var(--accent-fg); }
.breadcrumb--on-accent a:hover { color: inherit; opacity: .7; }
.meta-row { display: flex; flex-wrap: wrap; gap: .75rem 1.25rem; align-items: center; padding: 1rem 0; border-top: 3px solid var(--ink); border-bottom: 3px solid var(--ink); }
.meta-item { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 700; }
.meta-item--badge { border: 2px solid var(--ink); padding: .2rem .5rem; background: #fff; }
.copy-link { display: inline-flex; align-items: center; gap: .4rem; font-family: var(--font-mono); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 700; padding: .45rem .8rem; border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow-sm); cursor: pointer; transition: translate .12s, box-shadow .12s, background .12s, color .12s; }
.copy-link:hover { translate: -2px -2px; box-shadow: 5px 5px 0 var(--ink); }
.copy-link.is-copied { background: var(--accent); color: #fff; }
.article-lede { font-size: 1.25rem; line-height: 1.55; font-weight: 500; padding-left: 1.25rem; border-left: 8px solid var(--accent); margin-bottom: 2.5rem; max-width: 70ch; }
.article-layout { display: grid; gap: 3rem; }
@media (min-width: 1024px) { .article-layout { grid-template-columns: minmax(0, 1fr) 320px; gap: 4rem; align-items: start; } }
.article-main { min-width: 0; }
.side-sticky { position: sticky; top: calc(var(--header-h) + 1.5rem); }
.toc-wrap { border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow); padding: 1.25rem; }
.toc ul { display: flex; flex-direction: column; }
.toc li a { display: block; padding: .5rem .75rem; font-size: .9rem; font-weight: 500; line-height: 1.3; border-left: 4px solid transparent; transition: border-color .15s, background .15s; }
.toc li.toc-h3 a { padding-left: 1.5rem; font-size: .82rem; opacity: .85; }
.toc li a:hover { background: var(--paper); border-left-color: var(--ink); }
.toc li a.is-active { border-left-color: var(--accent); background: var(--paper); font-weight: 700; }
.related-list { border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow); }
.related-list li + li { border-top: 2px solid var(--ink); }
.related-list a { display: grid; grid-template-columns: auto 1fr; gap: .25rem .75rem; padding: .85rem 1rem; transition: background .15s, color .15s; }
.related-list a:hover { background: var(--ink); color: var(--paper); }
.related-list__idx { font-family: var(--font-mono); font-size: .7rem; grid-row: span 2; padding-top: .15rem; }
.related-list__title { font-weight: 700; font-size: .92rem; line-height: 1.3; }
.related-list__meta { font-family: var(--font-mono); font-size: .65rem; letter-spacing: .1em; text-transform: uppercase; opacity: .7; }
.table-scroll { overflow-x: auto; margin-bottom: 1.5rem; }

/* ---------- Prose (article body from DB) ---------- */
.prose { font-size: 1.125rem; line-height: 1.75; max-width: 72ch; counter-reset: h2; }
.prose > * { margin-top: 0; margin-bottom: 1.35em; }
.prose > *:last-child { margin-bottom: 0; }
.prose h1 { font-family: var(--font-display); text-transform: uppercase; line-height: 1; font-size: 2.25rem; margin: 2.5rem 0 1rem; }
.prose h2 {
  counter-increment: h2;
  font-family: var(--font-display); font-size: clamp(1.6rem, 3.2vw, 2.4rem); line-height: 1; text-transform: uppercase; letter-spacing: -.02em;
  margin: 3rem 0 1.25rem; padding-top: 1rem; border-top: 4px solid var(--ink);
  display: grid; grid-template-columns: auto 1fr; gap: .9rem; align-items: start;
}
.prose h2::before {
  content: counter(h2, decimal-leading-zero);
  font-family: var(--font-mono); font-size: .85rem; letter-spacing: .1em; line-height: 1;
  background: var(--accent); color: var(--accent-fg); padding: .45rem .5rem; border: 2px solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
  transform: translateY(.1em);
}
.prose h3 { font-weight: 700; font-size: 1.35rem; line-height: 1.2; margin: 2rem 0 .9rem; padding-left: .9rem; border-left: 6px solid var(--accent); }
.prose h4 { font-family: var(--font-mono); font-size: .85rem; text-transform: uppercase; letter-spacing: .15em; font-weight: 700; margin: 1.75rem 0 .75rem; }
.prose p { overflow-wrap: anywhere; }
.prose a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; font-weight: 500; transition: background .12s, color .12s; }
.prose a:hover { background: var(--accent); color: var(--accent-fg); text-decoration-color: var(--ink); }
.prose strong { font-weight: 700; }
.prose ul, .prose ol { padding-left: 1.75rem; }
.prose ul li, .prose ol li { position: relative; margin-bottom: .55em; }
.prose ul { list-style: none; }
.prose ul > li::before { content: ""; position: absolute; left: -1.75rem; top: .62em; width: .7rem; height: .7rem; background: var(--ink); }
.prose ul ul > li::before { background: transparent; border: 2px solid var(--ink); width: .55rem; height: .55rem; }
.prose ol { list-style: none; counter-reset: ol; padding-left: 2.6rem; }
.prose ol > li { counter-increment: ol; }
.prose ol > li::before { content: counter(ol, decimal-leading-zero); position: absolute; left: -2.6rem; top: .2em; font-family: var(--font-mono); font-weight: 700; font-size: .8em; letter-spacing: .05em; color: var(--accent); }
.prose code { font-family: var(--font-mono); font-size: .86em; background: #fff; border: 2px solid var(--ink); padding: .05em .35em; overflow-wrap: anywhere; }
.prose pre { background: #fff; border: 3px solid var(--ink); box-shadow: var(--shadow); padding: 1.25rem 1.5rem; overflow-x: auto; font-size: .9rem; line-height: 1.6; font-family: var(--font-mono); }
.prose pre code { border: 0; padding: 0; background: none; font-size: inherit; }
.prose blockquote { border: 3px solid var(--ink); border-left: 12px solid var(--accent); background: #fff; padding: 1.25rem 1.5rem; font-weight: 500; font-size: 1.1em; box-shadow: var(--shadow-sm); }
.prose blockquote p:last-child { margin-bottom: 0; }
.prose table { width: 100%; border-collapse: collapse; border: 3px solid var(--ink); background: #fff; font-size: .95rem; line-height: 1.4; }
.prose thead th { background: var(--ink); color: var(--paper); font-family: var(--font-mono); text-transform: uppercase; font-size: .7rem; letter-spacing: .12em; text-align: left; padding: .75rem .9rem; border: 2px solid var(--ink); }
.prose td { padding: .7rem .9rem; border: 2px solid var(--ink); vertical-align: top; }
.prose tbody tr:nth-child(even) { background: var(--paper); }
.prose img { display: block; border: 3px solid var(--ink); box-shadow: var(--shadow); }
.prose figure figcaption { font-family: var(--font-mono); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; margin-top: .75rem; }
.prose hr { border: 0; border-top: 4px solid var(--ink); margin: 3rem 0; }
.prose kbd { font-family: var(--font-mono); font-size: .85em; border: 2px solid var(--ink); border-bottom-width: 4px; padding: .05em .4em; background: #fff; }
.prose mark { background: #ffd23f; color: var(--ink); padding: 0 .2em; }

/* ---------- Category hero ---------- */
.cat-hero { background: var(--accent); color: var(--accent-fg); position: relative; overflow: hidden; }
.cat-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .18;
  background-image:
    linear-gradient(to right, var(--ink) 1px, transparent 1px),
    linear-gradient(to bottom, var(--ink) 1px, transparent 1px);
  background-size: 48px 48px;
}
.cat-hero .container-x { position: relative; z-index: 1; }
.cat-hero__icon { display: inline-grid; place-items: center; color: var(--accent); background: #fff; border: 4px solid var(--ink); box-shadow: var(--shadow-lg); padding: 1.25rem; transform: rotate(-6deg); }
.cat-hero__icon .icon { width: clamp(5rem, 12vw, 9rem); height: clamp(5rem, 12vw, 9rem); stroke-width: 2; }
.other-cats { display: grid; gap: 1rem; }
@media (min-width: 640px) { .other-cats { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .other-cats { grid-template-columns: repeat(4, 1fr); } }
.other-cat { display: grid; grid-template-columns: auto 1fr auto; gap: .75rem; align-items: center; padding: 1rem 1.1rem; border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow-sm); font-weight: 700; border-left: 12px solid var(--accent); transition: translate .15s, box-shadow .15s, background .15s, color .15s; }
.other-cat:hover { translate: -3px -3px; box-shadow: 6px 6px 0 var(--ink); background: var(--accent); color: var(--accent-fg); }
.other-cat__icon { display: inline-flex; color: var(--accent); }
.other-cat:hover .other-cat__icon { color: inherit; }
.other-cat__arrow { display: inline-flex; transition: translate .15s; }
.other-cat:hover .other-cat__arrow { translate: 4px 0; }

/* ---------- Finder band / count badge / empty / footer / 404 ---------- */
.finder-band { background: var(--accent); color: #fff; border-bottom: 4px solid var(--ink); position: relative; overflow: hidden; }
.finder-band::before { content: "?"; position: absolute; right: -2vw; bottom: -20%; font-family: var(--font-display); font-size: 40vw; line-height: 1; color: transparent; -webkit-text-stroke: 2px rgba(255,255,255,.2); pointer-events: none; }
.finder-band .container-x { position: relative; z-index: 1; }
.count-badge { display: inline-flex; align-items: baseline; gap: .5rem; font-family: var(--font-display); font-size: 2.5rem; line-height: 1; background: var(--ink); color: var(--paper); padding: .5rem .9rem; border: 3px solid var(--ink); box-shadow: 6px 6px 0 var(--accent); margin-bottom: .35rem; }
.count-badge__label { font-family: var(--font-mono); font-size: .75rem; letter-spacing: .2em; text-transform: uppercase; }
.empty-state { border: 4px dashed var(--ink); padding: 3rem 2rem; text-align: center; display: flex; flex-direction: column; align-items: center; gap: .75rem; font-weight: 500; font-size: 1.1rem; background: #fff; }
.empty-state__glyph { font-size: 3rem; line-height: 1; }
.footer-links li + li { margin-top: .35rem; }
.footer-links a { display: inline-flex; align-items: center; gap: .6rem; font-weight: 700; text-transform: uppercase; font-size: .9rem; letter-spacing: .03em; color: var(--paper); padding: .25rem 0; border-bottom: 2px solid transparent; transition: border-color .15s, color .15s; }
.footer-links a:hover { border-bottom-color: var(--paper); color: #fff; }
.footer-links__swatch { display: inline-block; width: .8rem; height: .8rem; border: 2px solid var(--paper); flex: none; }
.footer-links .icon { opacity: .8; }
.disclaimer { display: grid; grid-template-columns: auto 1fr; border: 3px solid var(--paper); }
.disclaimer__label { display: grid; place-items: center; width: 3rem; background: var(--paper); color: var(--ink); font-family: var(--font-display); font-size: 1.5rem; }
.disclaimer p { padding: 1rem 1.25rem; font-family: var(--font-mono); font-size: .75rem; line-height: 1.6; letter-spacing: .02em; color: rgba(245,242,233,.85); }
.glitch-block { position: relative; background: var(--accent); color: #fff; border: 4px solid var(--ink); box-shadow: var(--shadow-lg); padding: 1.5rem 2.5rem; transform: rotate(-4deg); }
.glitch-block__num { font-size: clamp(6rem, 18vw, 12rem); line-height: .9; display: block; }
.glitch-block__tag { position: absolute; right: -1.5rem; top: -1.5rem; background: var(--ink); color: var(--paper); font-family: var(--font-mono); font-size: .7rem; letter-spacing: .2em; padding: .5rem .7rem; transform: rotate(8deg); border: 3px solid var(--paper); line-height: 1.3; }

/* ---------- Tools (client-side utilities) ---------- */
.tool-grid { display: grid; gap: 1.75rem; }
@media (min-width: 640px) { .tool-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .tool-grid { grid-template-columns: repeat(3, 1fr); gap: 2rem; } }
.tool-card { position: relative; display: flex; flex-direction: column; gap: 1rem; height: 100%; background: #fff; border: 4px solid var(--ink); box-shadow: var(--shadow); padding: 1.5rem; transition: translate .18s ease, box-shadow .18s ease; }
.tool-card:hover { translate: -5px -5px; box-shadow: 12px 12px 0 var(--ink); }
.tool-card__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.tool-card__icon { display: grid; place-items: center; width: 3.5rem; height: 3.5rem; background: var(--accent); color: #fff; border: 3px solid var(--ink); box-shadow: 3px 3px 0 var(--ink); transition: transform .25s; }
.tool-card:hover .tool-card__icon { transform: rotate(-10deg); }
.tool-card__idx { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .2em; font-weight: 700; opacity: .6; }
.tool-card__live { display: inline-flex; align-items: center; gap: .4rem; font-family: var(--font-mono); font-size: .65rem; letter-spacing: .15em; font-weight: 700; text-transform: uppercase; border: 2px solid var(--ink); padding: .2rem .5rem; background: #00c26e; color: var(--ink); }
.tool-card__live::before { content: ""; width: .5rem; height: .5rem; background: var(--ink); }
.tool-card__title { font-family: var(--font-sans); font-weight: 700; font-size: 1.35rem; line-height: 1.15; letter-spacing: -.01em; text-decoration: underline transparent; text-decoration-thickness: 3px; text-underline-offset: 4px; transition: text-decoration-color .15s; }
.tool-card:hover .tool-card__title { text-decoration-color: var(--accent); }
.tool-card__desc { font-size: .95rem; line-height: 1.55; color: rgba(17,17,17,.8); }
.tool-card__meta { margin-top: auto; display: flex; justify-content: space-between; align-items: center; padding-top: 1rem; border-top: 2px solid var(--ink); font-family: var(--font-mono); font-size: .72rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700; }
.tool-card__arrow { display: inline-flex; transition: translate .18s; }
.tool-card:hover .tool-card__arrow { translate: 6px 0; }

.tool-layout { display: grid; gap: 2.5rem; }
@media (min-width: 1024px) { .tool-layout { grid-template-columns: minmax(0, 1fr) 320px; gap: 3.5rem; align-items: start; } }
.tool-panel { background: #fff; border: 4px solid var(--ink); box-shadow: var(--shadow-lg); padding: 1.5rem; display: grid; gap: 1.5rem; min-width: 0; }
@media (min-width: 640px) { .tool-panel { padding: 2rem; } }
.tool-panel__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem; padding-bottom: 1rem; border-bottom: 3px solid var(--ink); }
.tool-note { display: grid; grid-template-columns: auto 1fr; border: 3px solid var(--ink); background: var(--paper); box-shadow: var(--shadow-sm); }
.tool-note__label { display: grid; place-items: center; width: 3rem; background: var(--accent); color: #fff; }
.tool-note__label .icon { stroke-width: 2.5; }
.tool-note p { padding: .9rem 1.1rem; font-family: var(--font-mono); font-size: .75rem; line-height: 1.6; letter-spacing: .02em; font-weight: 700; text-transform: uppercase; }
.tool-note--warn .tool-note__label { background: #ff3b30; }
.tool-side { display: grid; gap: 1.5rem; }
.tool-side__box { border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow); padding: 1.25rem; font-size: .95rem; line-height: 1.6; }
.tool-side__box .kicker { display: block; margin-bottom: .6rem; }
.tool-side__box ol { counter-reset: s; display: grid; gap: .45rem; }
.tool-side__box ol li { display: grid; grid-template-columns: auto 1fr; gap: .7rem; counter-increment: s; }
.tool-side__box ol li::before { content: counter(s, decimal-leading-zero); font-family: var(--font-mono); font-size: .75rem; font-weight: 700; padding-top: .2rem; color: var(--accent); }
.tool-list { border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow); }
.tool-list a { display: grid; grid-template-columns: auto auto 1fr auto; gap: .75rem; align-items: center; padding: .8rem 1rem; font-weight: 700; font-size: .9rem; transition: background .15s, color .15s; }
.tool-list li + li a { border-top: 2px solid var(--ink); }
.tool-list a:hover { background: var(--ink); color: var(--paper); }
.tool-list a.is-active { background: var(--accent); color: #fff; }
.tool-list__idx { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .1em; opacity: .7; }

.tool-fields { display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .tool-fields--2 { grid-template-columns: repeat(2, 1fr); } .tool-fields--3 { grid-template-columns: repeat(3, 1fr); } .tool-fields--4 { grid-template-columns: repeat(4, 1fr); } }
.tool-field { display: grid; gap: .5rem; min-width: 0; }
.tool-field > label, .tool-label { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 700; }
.tool-field__hint { font-family: var(--font-mono); font-size: .7rem; opacity: .7; }
.tool-input, .tool-select, .tool-textarea {
  width: 100%; min-width: 0; padding: .8rem 1rem; background: var(--paper); color: var(--ink);
  border: 3px solid var(--ink); box-shadow: inset 3px 3px 0 rgba(17,17,17,.12);
  font-family: var(--font-mono); font-size: .95rem; line-height: 1.4; appearance: none; -webkit-appearance: none;
}
.tool-input:focus, .tool-select:focus, .tool-textarea:focus { outline: 3px solid var(--accent); outline-offset: 2px; background: #fff; }
.tool-input[type="number"] { font-variant-numeric: tabular-nums; }
.tool-select { background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%); background-position: calc(100% - 1.3rem) 50%, calc(100% - .8rem) 50%; background-size: .5rem .5rem; background-repeat: no-repeat; padding-right: 2.6rem; cursor: pointer; }
.tool-textarea { min-height: 9rem; resize: vertical; }
.tool-textarea--out { background: #fff; }
.tool-input[type="file"] { padding: .6rem; cursor: pointer; }
.tool-input[type="file"]::file-selector-button { font: inherit; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: .5rem .9rem; margin-right: 1rem; background: var(--ink); color: var(--paper); border: 0; cursor: pointer; }
.tool-range { width: 100%; height: 14px; appearance: none; -webkit-appearance: none; background: var(--paper); border: 3px solid var(--ink); cursor: pointer; }
.tool-range::-webkit-slider-thumb { appearance: none; -webkit-appearance: none; width: 1.6rem; height: 1.6rem; background: var(--accent); border: 3px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); cursor: grab; }
.tool-range::-moz-range-thumb { width: 1.6rem; height: 1.6rem; background: var(--accent); border: 3px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); cursor: grab; }
.tool-range:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.tool-toggle { display: inline-flex; align-items: center; gap: .75rem; cursor: pointer; font-weight: 700; font-size: .9rem; user-select: none; padding: .5rem 0; }
.tool-toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.tool-toggle__box { display: grid; place-items: center; width: 1.75rem; height: 1.75rem; border: 3px solid var(--ink); background: #fff; box-shadow: 2px 2px 0 var(--ink); flex: none; transition: background .12s; }
.tool-toggle__box .icon { opacity: 0; stroke-width: 3; }
.tool-toggle input:checked + .tool-toggle__box { background: var(--accent); color: #fff; }
.tool-toggle input:checked + .tool-toggle__box .icon { opacity: 1; }
.tool-toggle input:focus-visible + .tool-toggle__box { outline: 3px solid var(--accent); outline-offset: 3px; }

.tool-seg { display: inline-flex; border: 3px solid var(--ink); box-shadow: var(--shadow-sm); background: #fff; }
.tool-seg label { position: relative; cursor: pointer; padding: .7rem 1.3rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: .85rem; border-right: 3px solid var(--ink); transition: background .12s, color .12s; }
.tool-seg label:last-child { border-right: 0; }
.tool-seg input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.tool-seg label:has(input:checked), .tool-seg label.is-checked { background: var(--accent); color: #fff; }
.tool-seg label:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 3px; }
.tool-seg label:hover:not(:has(input:checked)) { background: var(--paper); }

.tool-actions { display: flex; flex-wrap: wrap; gap: 1rem 1.25rem; align-items: center; }
.btn-brutal.is-copied { background: #00c26e; color: var(--ink); }
.btn-brutal[disabled] { opacity: .5; cursor: not-allowed; translate: none; box-shadow: var(--shadow); }

.tool-output { position: relative; min-height: 5.5rem; padding: 1.25rem 1.5rem; background: var(--ink); color: var(--paper); border: 4px solid var(--ink); box-shadow: 8px 8px 0 var(--accent); font-family: var(--font-mono); font-size: clamp(1.15rem, 2.6vw, 1.75rem); font-weight: 700; line-height: 1.35; overflow-wrap: anywhere; word-break: break-word; user-select: all; }
.tool-output--sm { font-size: .95rem; font-weight: 400; line-height: 1.6; user-select: text; max-height: 22rem; overflow: auto; white-space: pre-wrap; }
.tool-output:empty::before { content: attr(data-placeholder); opacity: .45; font-weight: 400; }
.tool-output__word { display: inline-block; }
.tool-output__sep { opacity: .45; }
.tool-output__num { color: #ffd23f; }

.tool-stat { display: inline-flex; align-items: baseline; gap: .6rem; border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow-sm); padding: .6rem .9rem; }
.tool-stat__num { font-family: var(--font-display); font-size: 1.6rem; line-height: 1; font-variant-numeric: tabular-nums; }
.tool-stat__label { font-family: var(--font-mono); font-size: .68rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700; }
.tool-stat--weak .tool-stat__num { color: #ff3b30; }
.tool-stat--ok .tool-stat__num { color: #ff9500; }
.tool-stat--strong .tool-stat__num { color: #00a35c; }

.tool-error { display: none; grid-template-columns: auto 1fr; align-items: center; border: 3px solid var(--ink); background: #ff3b30; color: #fff; box-shadow: var(--shadow-sm); font-weight: 700; font-size: .95rem; }
.tool-error.is-visible { display: grid; }
.tool-error__label { display: grid; place-items: center; width: 3rem; align-self: stretch; background: var(--ink); color: var(--paper); }
.tool-error p { padding: .85rem 1.1rem; }
.tool-success { border: 3px solid var(--ink); background: #00c26e; color: var(--ink); box-shadow: var(--shadow-sm); font-weight: 700; font-size: .9rem; padding: .7rem 1rem; font-family: var(--font-mono); letter-spacing: .05em; }

/* Definition table */
.tool-kv { width: 100%; border-collapse: collapse; }
.tool-kv th, .tool-kv td { text-align: left; vertical-align: top; padding: .8rem 1rem; border-top: 2px solid var(--ink); font-size: .92rem; line-height: 1.45; }
.tool-kv tr:first-child th, .tool-kv tr:first-child td { border-top: 0; }
.tool-kv th { width: 34%; font-family: var(--font-mono); font-size: .7rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700; background: var(--paper); border-right: 2px solid var(--ink); white-space: nowrap; }
.tool-kv td { font-family: var(--font-mono); overflow-wrap: anywhere; word-break: break-word; }
.tool-kv tr:nth-child(even) td { background: #fffbe6; }
.tool-kv td.is-muted { opacity: .55; }
.tool-kv td.is-hash { color: var(--accent); font-weight: 700; }
.tool-kv__wrap { border: 3px solid var(--ink); background: #fff; overflow-x: auto; }
@media (max-width: 639px) { .tool-kv th { width: 40%; white-space: normal; } }
.tool-kv__group td, .tool-kv__group th { background: var(--ink) !important; color: var(--paper); border-right: 0; font-family: var(--font-mono); font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; font-weight: 700; padding: .6rem 1rem; }

/* URL cleaner results */
.url-results { display: grid; gap: 1rem; }
.url-result { border: 3px solid var(--ink); background: #fff; box-shadow: var(--shadow-sm); display: grid; gap: .6rem; padding: 1rem 1.1rem; }
.url-result__head { display: flex; justify-content: space-between; align-items: center; gap: .75rem; flex-wrap: wrap; }
.url-result__badge { font-family: var(--font-mono); font-size: .68rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700; border: 2px solid var(--ink); padding: .2rem .5rem; background: var(--paper); }
.url-result__badge--removed { background: var(--accent); color: #fff; }
.url-result__badge--clean { background: #00c26e; }
.url-result__badge--bad { background: #ff3b30; color: #fff; }
.url-result__url { font-family: var(--font-mono); font-size: .9rem; line-height: 1.5; overflow-wrap: anywhere; word-break: break-all; }
.url-result__url a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.url-result__url a:hover { color: var(--accent); }
.url-result__removed { font-family: var(--font-mono); font-size: .72rem; opacity: .75; display: flex; flex-wrap: wrap; gap: .35rem; }
.url-result__removed span { border: 2px solid var(--ink); padding: .05rem .4rem; text-decoration: line-through; }
.url-result__original { font-family: var(--font-mono); font-size: .72rem; opacity: .55; overflow-wrap: anywhere; word-break: break-all; text-decoration: line-through; }
.url-result__actions { display: flex; gap: .75rem; flex-wrap: wrap; }
.btn-mini { display: inline-flex; align-items: center; gap: .4rem; padding: .45rem .8rem; background: #fff; color: var(--ink); border: 3px solid var(--ink); box-shadow: var(--shadow-sm); font-family: var(--font-mono); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 700; cursor: pointer; transition: translate .12s, box-shadow .12s, background .12s, color .12s; white-space: nowrap; }
.btn-mini:hover { translate: -2px -2px; box-shadow: 5px 5px 0 var(--ink); }
.btn-mini:active { translate: 1px 1px; box-shadow: 1px 1px 0 var(--ink); }
.btn-mini.is-copied { background: #00c26e; }

/* TOTP */
.totp-display { display: grid; gap: 1rem; padding: 1.5rem; background: var(--ink); color: var(--paper); border: 4px solid var(--ink); box-shadow: 8px 8px 0 var(--accent); }
.totp-code { font-family: var(--font-display); font-size: clamp(3rem, 12vw, 6.5rem); line-height: 1; letter-spacing: .08em; font-variant-numeric: tabular-nums; user-select: all; overflow-wrap: anywhere; }
.totp-code.is-idle { opacity: .35; }
.totp-code.is-expiring { color: #ff3b30; }
.totp-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; font-family: var(--font-mono); font-size: .75rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700; }
.totp-meta__secs { font-size: 1.4rem; font-variant-numeric: tabular-nums; }
.totp-bar { height: 16px; border: 3px solid var(--paper); background: transparent; }
.totp-bar__fill { height: 100%; background: var(--accent); transition: width .9s linear; }
.totp-bar__fill.is-expiring { background: #ff3b30; }

/* EXIF */
.exif-layout { display: grid; gap: 1.5rem; }
@media (min-width: 768px) { .exif-layout { grid-template-columns: 260px minmax(0, 1fr); align-items: start; } }
.exif-thumb { border: 4px solid var(--ink); background: var(--paper); box-shadow: var(--shadow); aspect-ratio: 1; display: grid; place-items: center; overflow: hidden; position: relative; }
.exif-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.exif-thumb__empty { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .15em; text-transform: uppercase; opacity: .5; text-align: center; padding: 1rem; }
.exif-gps { display: grid; gap: .9rem; border: 4px solid var(--ink); background: #ff3b30; color: #fff; box-shadow: var(--shadow); padding: 1.25rem 1.5rem; }
.exif-gps__title { display: flex; align-items: center; gap: .75rem; font-family: var(--font-display); text-transform: uppercase; font-size: clamp(1.3rem, 3vw, 1.9rem); line-height: 1; }
.exif-gps__coords { font-family: var(--font-mono); font-size: 1.05rem; font-weight: 700; overflow-wrap: anywhere; }
.exif-gps .btn-brutal { background: #fff; color: var(--ink); justify-self: start; }
.exif-drop { border: 4px dashed var(--ink); background: var(--paper); padding: 1.5rem; display: grid; gap: .75rem; }

/* Fingerprint verdict */
.fp-verdict { display: grid; grid-template-columns: auto 1fr; border: 4px solid var(--ink); background: var(--accent); color: #fff; box-shadow: var(--shadow); }
.fp-verdict__label { display: grid; place-items: center; width: 4rem; background: var(--ink); color: var(--paper); }
.fp-verdict__label .icon { stroke-width: 2.5; }
.fp-verdict p { padding: 1.1rem 1.25rem; font-weight: 500; line-height: 1.55; font-size: .98rem; }
.fp-verdict strong { font-family: var(--font-mono); font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; display: block; margin-bottom: .3rem; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .marquee__track { animation: none; }
  .sticker__ring { animation: none; }
  html.js [data-reveal], html.js [data-intro], html.js [data-split], html.js [data-result] { opacity: 1; }
}
