/* ============================================================================
   md5decrypt.io — app.css
   One stylesheet, light theme. No inline styles anywhere (CSP: style-src 'self').
   Sections:  tokens · base · layout · buttons · header/drawer · hero · tool ·
              results · trust · sections · algos · steps · api · faq · footer
   ========================================================================== */

/* ── Tokens ───────────────────────────────────────────────────────────── */
:root {
  --ink:        #0f172a;   /* headings            */
  --ink-2:      #334155;   /* body                */
  --muted:      #64748b;   /* secondary           */
  --muted-2:    #94a3b8;   /* faint               */
  --line:       #e5e8ef;   /* borders             */
  --line-2:     #eef1f7;   /* hairlines           */
  --surface:    #ffffff;
  --bg:         #ffffff;
  --bg-soft:    #f6f8fc;   /* alt sections        */
  --bg-tint:    #f9fafe;

  --primary:      #4f46e5; /* indigo-600          */
  --primary-600:  #4338ca;
  --primary-700:  #3730a3;
  --primary-050:  #eef2ff;
  --primary-100:  #e0e7ff;
  --accent:       #06b6d4; /* cyan, gradient pair */

  --ok:      #059669;  --ok-bg: #ecfdf5;  --ok-line: #a7f3d0;
  --miss:    #b45309;  --miss-bg: #fff7ed; --miss-line: #fed7aa;
  --danger:  #dc2626;  --danger-bg: #fef2f2; --danger-line: #fecaca;

  --r-xs: 7px; --r-sm: 10px; --r: 14px; --r-lg: 18px; --r-xl: 24px; --pill: 999px;

  --sh-1: 0 1px 2px rgba(15,23,42,.05);
  --sh-2: 0 1px 3px rgba(15,23,42,.06), 0 10px 26px -14px rgba(15,23,42,.18);
  --sh-card: 0 1px 2px rgba(15,23,42,.05), 0 18px 44px -22px rgba(30,27,75,.30);
  --sh-pop: 0 12px 30px -10px rgba(15,23,42,.22);

  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, "Cascadia Code", "JetBrains Mono", Menlo, Consolas, "Liberation Mono", monospace;

  --wrap: 1280px;
  --wrap-narrow: 760px;
  --pad: clamp(16px, 4vw, 28px);
  --hd-h: 64px;
}

/* ── Base ─────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;               /* last-line guard against a stray horizontal scroll */
}

h1, h2, h3 { color: var(--ink); line-height: 1.15; letter-spacing: -0.02em; font-weight: 700; }
p { text-wrap: pretty; }

a { color: var(--primary-600); text-decoration: none; }
a:hover { color: var(--primary-700); }

svg { display: block; }
.ic { width: 1.15em; height: 1.15em; flex: none; }

img, svg, pre { max-width: 100%; }

::selection { background: var(--primary-100); color: var(--primary-700); }

/* One visible, consistent focus ring for every interactive element. */
:where(a, button, summary, textarea, input, [tabindex]):focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: var(--r-xs);
}

.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 {
  position: fixed; top: 10px; left: 50%; transform: translateX(-50%) translateY(-160%);
  z-index: 100; background: var(--ink); color: #fff; padding: 10px 18px;
  border-radius: var(--pill); font-weight: 600; font-size: .9rem; box-shadow: var(--sh-pop);
  transition: transform .18s ease;
}
.skip:focus { transform: translateX(-50%) translateY(0); color: #fff; }

/* ── Layout ───────────────────────────────────────────────────────────── */
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--pad); }
.wrap-narrow { max-width: var(--wrap-narrow); }

/* Anchored sections clear the sticky header when jumped to. */
section[id] { scroll-margin-top: calc(var(--hd-h) + 14px); }

.section { padding-block: clamp(52px, 8vw, 92px); }
.section-alt { background: var(--bg-soft); border-block: 1px solid var(--line-2); }

.section-head { max-width: 640px; margin-bottom: clamp(28px, 4vw, 44px); }
.section-title { font-size: clamp(1.5rem, 3.4vw, 2.05rem); }
.section-sub { margin-top: 10px; color: var(--muted); font-size: 1.05rem; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 7px;
  color: var(--primary-600); font-weight: 650; font-size: .82rem;
  letter-spacing: .04em; text-transform: uppercase;
}
.eyebrow .ic { width: 1.05em; height: 1.05em; }

.grad {
  background: linear-gradient(100deg, var(--primary) 10%, var(--accent) 95%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ── Buttons ──────────────────────────────────────────────────────────── */
.btn {
  --bh: 44px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--bh); padding-inline: 18px;
  font: inherit; font-weight: 600; line-height: 1; color: var(--ink);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm);
  cursor: pointer; white-space: nowrap; user-select: none;
  transition: background .15s ease, border-color .15s ease, transform .12s ease, box-shadow .15s ease, color .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn .ic { width: 1.15em; height: 1.15em; }

.btn-primary {
  color: #fff; border-color: transparent;
  background: linear-gradient(180deg, #5a52ea, #4940df);
  box-shadow: 0 1px 2px rgba(23,20,58,.22), inset 0 1px 0 rgba(255,255,255,.16);
}
.btn-primary:hover { color: #fff; background: linear-gradient(180deg, #514ae7, #3f37d2); }
.btn-primary:active { background: #3830bd; }
.btn-primary:disabled { background: #c7c9e8; box-shadow: none; cursor: not-allowed; }

.btn-ghost { color: var(--ink-2); }
.btn-ghost:hover { background: var(--bg-soft); border-color: var(--line); color: var(--ink); }

.btn-sm  { --bh: 38px; padding-inline: 14px; font-size: .9rem; }
.btn-lg  { --bh: 52px; padding-inline: 26px; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn-grow { flex: 1 1 auto; }
.btn-icon { padding-inline: 0; width: var(--bh); flex: none; }
.btn-icon .ic { width: 1.2em; height: 1.2em; }

.link-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: none; border: 0; padding: 6px 4px; cursor: pointer;
  color: var(--primary-600); font: inherit; font-weight: 600; font-size: .9rem;
}
.link-btn:hover { color: var(--primary-700); text-decoration: underline; text-underline-offset: 3px; }
.link-btn .ic { width: 1em; height: 1em; }

/* ── Header ───────────────────────────────────────────────────────────── */
.hd { position: sticky; top: 0; z-index: 50; background: var(--surface); border-bottom: 1px solid var(--line-2); transition: box-shadow .2s ease, border-color .2s ease; }
.hd.is-scrolled { box-shadow: var(--sh-2); border-color: var(--line); }
.hd-wide { width: 100%; max-width: 1280px; margin-inline: auto; padding-inline: var(--pad); }
html.drawer-open { overflow: hidden; }

/* Utility strip */
.hd-top { background: var(--primary-050); border-bottom: 1px solid var(--primary-100); overflow: hidden; max-height: 46px; transition: max-height .25s ease, opacity .2s ease, border-color .2s ease; }
.hd.is-scrolled .hd-top { max-height: 0; opacity: 0; border-color: transparent; }
.hd-top-in { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 40px; }
.hd-tagline { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: .84rem; margin: 0; min-width: 0; }
.hd-tagline .ic { width: 1.05em; height: 1.05em; color: var(--primary); flex: none; }
.hd-tagline b { color: var(--primary-700); font-weight: 700; }
.hd-facts { display: flex; align-items: center; gap: 6px 18px; list-style: none; padding: 0; margin: 0; flex-wrap: wrap; }
.hd-facts li { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: .8rem; font-weight: 550; white-space: nowrap; }
.hd-facts .ic { width: 1em; height: 1em; color: var(--ok); flex: none; }

/* Main bar */
.hd-main { position: relative; }
.hd-in { display: flex; align-items: center; gap: 6px; min-height: var(--hd-h); }
.hd-brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; margin-inline-end: 8px; color: var(--ink); flex: none; }
.hd-mark { width: 30px; height: 30px; color: var(--primary); flex: none; }
.hd-name { font-weight: 750; font-size: 1.22rem; letter-spacing: -0.03em; color: var(--ink); }
.hd-name b { font-weight: 750; color: var(--primary-600); }

.hd-nav { display: flex; }
.hd-list { display: flex; align-items: center; gap: 2px; list-style: none; padding: 0; margin: 0; }
.hd-item { display: flex; }
.hd-item.has-dropdown { position: relative; }
.hd-link {
  display: inline-flex; align-items: center; gap: 5px; min-height: 44px; padding: 0 13px;
  color: var(--ink-2); font-weight: 600; font-size: .95rem; line-height: 1; white-space: nowrap;
  background: none; border: 0; border-radius: var(--r-sm); cursor: pointer; font-family: inherit;
  transition: color .15s ease, background .15s ease;
}
.hd-link:hover { color: var(--ink); background: var(--bg-soft); }
.hd-link.is-active { color: var(--primary-700); }
.hd-caret { width: 15px; height: 15px; color: var(--muted-2); transition: transform .2s ease, color .15s ease; }
.hd-trigger[aria-expanded="true"] { color: var(--primary-700); background: var(--primary-050); }
.hd-trigger[aria-expanded="true"] .hd-caret { transform: rotate(180deg); color: var(--primary); }

.hd-act { margin-inline-start: auto; display: flex; align-items: center; gap: 10px; }
.hd-act .ic { width: 1em; height: 1em; }

/* Shared panel chrome (mega + dropdown): JS toggles .is-open; a .no-js
   fallback opens on hover/focus so the links are reachable without scripting. */
.mega, .dd {
  position: absolute; top: 100%; z-index: 40; background: var(--surface); box-shadow: var(--sh-pop);
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s;
}
.hd-item.is-open > .mega, .hd-item.is-open > .dd { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.no-js .hd-item.has-mega:hover > .mega, .no-js .hd-item.has-mega:focus-within > .mega,
.no-js .hd-item.has-dropdown:hover > .dd, .no-js .hd-item.has-dropdown:focus-within > .dd {
  opacity: 1; visibility: visible; transform: none; transition-delay: 0s;
}

/* Mega — full width */
.mega { left: 0; right: 0; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line); }
.mega-in { display: grid; grid-template-columns: 1fr 300px; gap: 34px; padding-block: 26px 30px; }
.mega-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px 24px; align-content: start; }
.mega-h { font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted-2); font-weight: 700; margin: 0 0 6px; padding-inline: 11px; }
.mega-group ul { list-style: none; padding: 0; margin: 0 0 8px; display: grid; gap: 1px; }
.mega-link { display: grid; gap: 1px; padding: 9px 11px; border-radius: var(--r-sm); transition: background .12s ease; }
.mega-link:hover { background: var(--bg-soft); }
.mega-name { font-family: var(--mono); font-weight: 700; color: var(--ink); font-size: .96rem; }
.mega-desc { color: var(--muted); font-size: .8rem; }
.mega-feature { background: linear-gradient(160deg, var(--primary-050), var(--surface) 72%); border: 1px solid var(--primary-100); border-radius: var(--r-lg); padding: 20px; align-self: start; }
.mega-eyebrow { display: inline-flex; align-items: center; gap: 6px; color: var(--primary-600); font-weight: 700; font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; margin: 0 0 8px; }
.mega-eyebrow .ic { width: 1.1em; height: 1.1em; }
.mega-ft-title { font-weight: 700; color: var(--ink); font-size: 1.02rem; letter-spacing: -0.01em; margin: 0; }
.mega-ft-text { color: var(--muted); font-size: .88rem; margin: 6px 0 14px; }
.mega-feature .btn { width: 100%; }
.mega-stats { list-style: none; padding: 14px 0 0; margin: 16px 0 0; display: flex; gap: 6px 14px; flex-wrap: wrap; border-top: 1px dashed var(--primary-100); }
.mega-stats li { color: var(--muted); font-size: .78rem; }
.mega-stats b { color: var(--ink); font-weight: 750; }

/* Dropdown — compact */
.dd { left: 0; min-width: 268px; border: 1px solid var(--line); border-radius: var(--r); margin-top: 6px; padding: 8px; }
.dd-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.dd-link { display: grid; gap: 1px; padding: 9px 11px; border-radius: var(--r-sm); transition: background .12s ease; }
.dd-link:hover { background: var(--bg-soft); }
.dd-name { color: var(--ink); font-weight: 650; font-size: .92rem; }
.dd-desc { color: var(--muted); font-size: .8rem; }

/* Burger */
.hd-burger { display: none; margin-inline-start: auto; width: 44px; height: 44px; align-items: center; justify-content: center; background: none; border: 1px solid var(--line); border-radius: var(--r-sm); cursor: pointer; }
.hd-burger-box { position: relative; width: 20px; height: 14px; }
.hd-burger-box span { position: absolute; left: 0; width: 100%; height: 2px; border-radius: 2px; background: var(--ink); transition: transform .2s ease, opacity .2s ease, top .2s ease; }
.hd-burger-box span:nth-child(1) { top: 0; }
.hd-burger-box span:nth-child(2) { top: 6px; }
.hd-burger-box span:nth-child(3) { top: 12px; }
.hd-burger[aria-expanded="true"] .hd-burger-box span:nth-child(1) { top: 6px; transform: rotate(45deg); }
.hd-burger[aria-expanded="true"] .hd-burger-box span:nth-child(2) { opacity: 0; }
.hd-burger[aria-expanded="true"] .hd-burger-box span:nth-child(3) { top: 6px; transform: rotate(-45deg); }

/* Mobile drawer */
.drawer { position: fixed; inset: var(--hd-h) 0 0 0; z-index: 45; background: var(--surface); box-shadow: var(--sh-pop); padding: 8px var(--pad) 24px; overflow-y: auto; overscroll-behavior: contain; }
.drawer[hidden] { display: none; }
.drawer-in { display: grid; gap: 0; }
.drawer-sec { border-bottom: 1px solid var(--line-2); }
.drawer-sec-h { display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0 8px; cursor: pointer; list-style: none; font-weight: 650; color: var(--ink); font-size: 1.02rem; }
.drawer-sec-h::-webkit-details-marker { display: none; }
.drawer-caret { width: 18px; height: 18px; color: var(--muted-2); transition: transform .2s ease, color .15s ease; }
.drawer-sec[open] .drawer-caret { transform: rotate(180deg); color: var(--primary); }
.drawer-sublist { list-style: none; padding: 0 0 10px; margin: 0; display: grid; gap: 1px; }
.drawer-sublink { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; padding: 0 14px; color: var(--ink-2); font-weight: 550; border-radius: var(--r-sm); }
.drawer-sublink:hover { background: var(--bg-soft); color: var(--ink); }
.drawer-sub-d { font-family: var(--mono); font-size: .78rem; color: var(--muted-2); }
.drawer-link { display: flex; align-items: center; min-height: 52px; padding: 0 8px; color: var(--ink); font-weight: 650; font-size: 1.02rem; border-bottom: 1px solid var(--line-2); }
.drawer-link:hover { color: var(--primary-700); }
.drawer-cta { margin-top: 16px; }
.drawer-facts { list-style: none; padding: 0; margin: 14px 2px 0; display: flex; flex-wrap: wrap; gap: 8px 16px; }
.drawer-facts li { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: .82rem; }
.drawer-facts .ic { width: 1em; height: 1em; color: var(--ok); flex: none; }

/* ── Hero ─────────────────────────────────────────────────────────────── */
.hero { position: relative; overflow: hidden; padding-block: clamp(34px, 5.5vw, 70px) clamp(40px, 6vw, 78px); }
.hero::before {
  content: ""; position: absolute; inset: -22% -12% auto -12%; height: 660px; z-index: -1; pointer-events: none;
  background:
    radial-gradient(44% 58% at 80% 16%, rgba(79,70,229,.13), transparent 62%),
    radial-gradient(38% 48% at 10% 6%, rgba(124,58,237,.08), transparent 60%),
    linear-gradient(180deg, var(--bg-tint), var(--bg) 74%);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.02fr); gap: clamp(30px, 4.5vw, 72px); align-items: start; }

.hero-copy { max-width: 560px; padding-top: clamp(0px, 1vw, 6px); }
.eyebrow-pill {
  display: inline-flex; align-items: center; gap: 9px; padding: 6px 14px 6px 12px;
  border: 1px solid var(--line); border-radius: var(--pill); background: var(--surface);
  color: var(--ink-2); font-size: .8rem; font-weight: 600; box-shadow: var(--sh-1);
}
.eyebrow-pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgba(5,150,105,.16); flex: none; }
.hero-title { margin-top: 0; font-size: clamp(2.2rem, 4.6vw, 3.45rem); letter-spacing: -0.035em; line-height: 1.06; }
.hero-title .accent { background: linear-gradient(92deg, #4f46e5, #7c3aed 72%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-sub { margin-top: 18px; font-size: clamp(1.02rem, 1.5vw, 1.16rem); color: var(--muted); max-width: 32em; }

.hero-stats { display: flex; flex-wrap: wrap; gap: 20px 0; list-style: none; padding: 0; margin: 30px 0 0; }
.hero-stats li { padding-inline: 24px; border-left: 1px solid var(--line); }
.hero-stats li:first-child { padding-inline-start: 0; border-left: 0; }
.hero-stats b { display: block; font-size: 1.55rem; font-weight: 800; color: var(--ink); letter-spacing: -0.02em; line-height: 1.1; }
.hero-stats span { color: var(--muted); font-size: .84rem; }

.hero-trust { display: inline-flex; align-items: center; gap: 8px; margin-top: 26px; color: var(--muted); font-size: .88rem; }
.hero-trust .ic { width: 1.05em; height: 1.05em; color: var(--ok); flex: none; }

/* ── Tool ─────────────────────────────────────────────────────────────── */
.tool { width: 100%; min-width: 0; }
.tool-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-xl);
  box-shadow: 0 1px 2px rgba(15,23,42,.04), 0 26px 50px -30px rgba(30,27,75,.36);
  padding: clamp(16px, 2.2vw, 22px);
}
.tool-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.tool-head-l { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 650; font-size: .98rem; }
.tool-head-l .ic { width: 1.1em; height: 1.1em; color: var(--primary); flex: none; }

.tool-input {
  width: 100%; min-height: 134px; resize: vertical; display: block;
  font-family: var(--mono); font-size: 1rem; line-height: 1.7; color: var(--ink);
  background: var(--bg-tint); border: 1px solid var(--line); border-radius: var(--r);
  padding: 15px 16px; transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.tool-input::placeholder { color: var(--muted-2); }
.tool-input:hover { border-color: #d3d9e6; }
.tool-input:focus { outline: none; border-color: var(--primary); background: var(--surface); box-shadow: 0 0 0 3px rgba(79,70,229,.13); }
.tool-input.is-invalid { border-color: var(--danger); box-shadow: 0 0 0 3px rgba(220,38,38,.12); }

.tool-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 24px; margin-top: 12px; flex-wrap: wrap; }
.tool-hint { color: var(--muted); font-size: .84rem; margin: 0; }
.tool-hint.is-error { color: var(--danger); font-weight: 550; }
.tool-count { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.type-tag { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: var(--pill); font-size: .75rem; font-weight: 650; background: var(--primary-050); color: var(--primary-700); border: 1px solid var(--primary-100); }
.type-tag.is-unknown { background: var(--miss-bg); color: var(--miss); border-color: var(--miss-line); }

.tool-actions { display: flex; align-items: center; gap: 10px; margin-top: 16px; }
.btn.is-busy { pointer-events: none; }
.btn.is-busy .ic { animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .btn.is-busy .ic { animation: none; } }

.tool-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 7px 16px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line-2); color: var(--muted); font-size: .82rem; }
.tool-foot span { display: inline-flex; align-items: center; gap: 6px; }
.tool-foot .ic { width: 1em; height: 1em; color: var(--ok); flex: none; }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: clamp(26px, 6vw, 40px); }
  .hero-copy { max-width: 640px; padding-top: 0; }
}
@media (max-width: 560px) {
  .hero-stats { gap: 16px 24px; }
  .hero-stats li { padding-inline: 0; border-left: 0; }
  .hero-stats b { font-size: 1.35rem; }
}

/* ── Results ──────────────────────────────────────────────────────────── */
.results { margin-top: 18px; }
.results[hidden] { display: none; }

.res-summary {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 0 4px 12px; color: var(--muted); font-size: .9rem;
}
.res-summary b { color: var(--ink); font-weight: 700; }
.res-summary .pill-ok { color: var(--ok); }

.res-list { display: grid; gap: 10px; list-style: none; padding: 0; }
.res-row {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px 14px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 12px 14px; box-shadow: var(--sh-1); min-width: 0;
}
.res-row.is-found { border-color: var(--ok-line); background: linear-gradient(0deg, var(--ok-bg), #fff 60%); }
.res-badge {
  display: inline-flex; align-items: center; justify-content: center; min-width: 74px;
  padding: 5px 10px; border-radius: var(--pill); font-size: .75rem; font-weight: 700;
  letter-spacing: .02em; text-transform: uppercase; background: var(--primary-050);
  color: var(--primary-700); border: 1px solid var(--primary-100); white-space: nowrap;
}
.res-main { min-width: 0; }
.res-hash {
  font-family: var(--mono); font-size: .82rem; color: var(--muted);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.res-plain {
  display: flex; align-items: center; gap: 8px; margin-top: 3px; min-width: 0;
  font-family: var(--mono); font-size: 1.02rem; font-weight: 600; color: var(--ink);
}
.res-plain .val { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.res-plain .ic { width: 1em; height: 1em; color: var(--ok); flex: none; }
.res-miss { margin-top: 3px; color: var(--miss); font-size: .92rem; font-weight: 600; }
.res-miss .sub { color: var(--muted); font-weight: 400; }
.res-note { margin-top: 3px; color: var(--danger); font-size: .9rem; font-weight: 550; }

.res-copy {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 38px; padding: 0 12px; border-radius: var(--r-sm);
  background: var(--surface); border: 1px solid var(--line); color: var(--ink-2);
  font-size: .82rem; font-weight: 600; cursor: pointer; white-space: nowrap;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.res-copy:hover { background: var(--bg-soft); color: var(--ink); }
.res-copy.is-done { color: var(--ok); border-color: var(--ok-line); background: var(--ok-bg); }
.res-copy .ic { width: 1.05em; height: 1.05em; }

.res-note-box {
  display: flex; gap: 10px; align-items: flex-start; margin-top: 12px;
  background: var(--danger-bg); border: 1px solid var(--danger-line); color: #991b1b;
  border-radius: var(--r); padding: 12px 14px; font-size: .92rem;
}
.res-note-box .ic { color: var(--danger); margin-top: 2px; }

/* ── Trust strip removed — the stats now live in the hero. ────────────── */

/* ── Algorithms ───────────────────────────────────────────────────────── */
.algos { list-style: none; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(4, 1fr); }
.algo {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 18px; box-shadow: var(--sh-1); transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.algo:hover { transform: translateY(-3px); box-shadow: var(--sh-2); border-color: var(--primary-100); }
.algo-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.algo-name { font-family: var(--mono); font-weight: 700; color: var(--ink); font-size: 1.06rem; }
.algo-badge {
  font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em;
  color: var(--primary-700); background: var(--primary-050); border: 1px solid var(--primary-100);
  padding: 3px 8px; border-radius: var(--pill); font-size: .75rem;
}
.algo-note { color: var(--muted); font-size: .9rem; min-height: 2.6em; }
.algo-len { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); color: var(--muted-2); font-size: .8rem; font-family: var(--mono); }

/* ── Steps ────────────────────────────────────────────────────────────── */
.steps { list-style: none; padding: 0; display: grid; gap: 18px; grid-template-columns: repeat(3, 1fr); counter-reset: s; }
.step {
  position: relative; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 24px 22px; box-shadow: var(--sh-1);
}
.step-n {
  display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px;
  border-radius: 12px; font-weight: 750; font-size: 1.1rem; color: #fff; margin-bottom: 14px;
  background: linear-gradient(140deg, var(--primary), var(--primary-600));
  box-shadow: 0 6px 14px -6px rgba(79,70,229,.6);
}
.step-t { font-size: 1.1rem; margin-bottom: 6px; }
.step-d { color: var(--muted); font-size: .96rem; }

.how-note {
  display: flex; align-items: flex-start; gap: 10px; margin-top: 22px;
  color: var(--ink-2); font-size: .96rem; background: var(--surface);
  border: 1px solid var(--line); border-left: 3px solid var(--primary); border-radius: var(--r);
  padding: 14px 16px;
}
.how-note .ic { color: var(--primary); margin-top: 2px; flex: none; }
.how-note a { font-weight: 600; white-space: nowrap; }

/* ── API teaser ───────────────────────────────────────────────────────── */
.api-in { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(24px, 4vw, 52px); align-items: center; }
.api-copy { min-width: 0; }
.api-copy .eyebrow { margin-bottom: 12px; }
.api-copy .section-title { margin-bottom: 0; }
.api-points { list-style: none; padding: 0; margin-top: 18px; display: grid; gap: 10px; }
.api-points li { display: flex; align-items: center; gap: 10px; color: var(--ink-2); font-weight: 500; }
.api-points .ic { width: 1.1em; height: 1.1em; color: var(--ok); flex: none; }

.api-code {
  min-width: 0;                        /* lets the code scroll instead of the page */
  background: #0e1424; border: 1px solid #1e293b; border-radius: var(--r-lg);
  box-shadow: var(--sh-pop); overflow: hidden;
}
.code-head { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid #1e293b; }
.code-dots { display: inline-flex; gap: 6px; }
.dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.dot-r { background: #ff5f56; } .dot-y { background: #ffbd2e; } .dot-g { background: #27c93f; }
.code-file { color: #64748b; font-family: var(--mono); font-size: .78rem; margin-inline-start: 4px; }
.code {
  margin: 0; padding: 18px 20px; overflow-x: auto; color: #cbd5e1;
  font-family: var(--mono); font-size: .86rem; line-height: 1.7; tab-size: 2;
}
.code code { font: inherit; }
.c-cmd { color: #7dd3fc; font-weight: 700; }
.c-str { color: #86efac; }
.c-key { color: #c4b5fd; }
.c-bool{ color: #fca5a5; }
.c-out { color: #94a3b8; }

/* ── FAQ ──────────────────────────────────────────────────────────────── */
.faq { display: grid; gap: 10px; }
.faq-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--sh-1); overflow: hidden; }
.faq-q {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 16px 18px; min-height: 44px; cursor: pointer; list-style: none;
  font-weight: 650; color: var(--ink); font-size: 1.02rem;
}
.faq-q::-webkit-details-marker { display: none; }
.faq-q:hover { color: var(--primary-700); }
.faq-caret { width: 18px; height: 18px; color: var(--muted-2); transition: transform .2s ease; flex: none; }
.faq-item[open] .faq-caret { transform: rotate(90deg); color: var(--primary); }
.faq-a { padding: 0 18px 18px; color: var(--ink-2); }
.faq-a p { max-width: 62ch; }

/* ── Footer ───────────────────────────────────────────────────────────── */
.ft { background: #0e1220; color: #cbd5e1; padding-top: clamp(40px, 6vw, 60px); }
.ft a { color: #cbd5e1; }
.ft a:hover { color: #fff; }
.ft-in { display: grid; grid-template-columns: 1.8fr 1fr 1fr; gap: 32px; padding-bottom: 36px; }
.ft-brand { max-width: 360px; }
.ft-logo { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: #fff; }
.ft-mark { width: 28px; height: 28px; color: #a5b4fc; }
.ft-logo .hd-name { color: #fff; }
.ft-logo .hd-name b { color: #a5b4fc; }
.ft-blurb { margin-top: 14px; color: #94a3b8; font-size: .92rem; }
.ft-privacy { display: flex; align-items: center; gap: 8px; margin-top: 14px; color: #cbd5e1; font-size: .88rem; }
.ft-privacy .ic { color: #34d399; width: 1.1em; height: 1.1em; flex: none; }

.ft-nav { min-width: 0; }
.ft-col { border: 0; }
.ft-col-h {
  display: flex; align-items: center; justify-content: space-between;
  color: #fff; font-weight: 650; font-size: .82rem; letter-spacing: .05em; text-transform: uppercase;
  list-style: none; cursor: default; padding-bottom: 4px; min-height: 32px;
}
.ft-col-h::-webkit-details-marker { display: none; }
.ft-caret { display: none; width: 18px; height: 18px; color: #64748b; }
.ft-col ul { list-style: none; padding: 0; margin-top: 10px; display: grid; gap: 10px; }
.ft-col a { color: #94a3b8; font-size: .95rem; }
.ft-col a:hover { color: #fff; }

.ft-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  border-top: 1px solid #1e2536; padding-block: 20px 26px; margin-top: 4px;
}
.ft-copy { color: #64748b; font-size: .88rem; }
.ft-facts { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 18px; }
.ft-facts li { display: inline-flex; align-items: center; gap: 7px; color: #94a3b8; font-size: .85rem; }
.ft-facts .ic { width: 1.05em; height: 1.05em; color: #64748b; }

/* ── Responsive ───────────────────────────────────────────────────────── */
@media (max-width: 980px) {
  .hd-top { display: none; }
  .hd-nav { display: none; }
  .hd-act { display: none; }
  .hd-burger { display: inline-flex; }
  .api-in { grid-template-columns: 1fr; }
  .algos { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; gap: 14px; }
  .ft-in { grid-template-columns: 1fr 1fr; }
  .ft-brand { grid-column: 1 / -1; max-width: none; }
}

@media (max-width: 640px) {
  .algos { grid-template-columns: 1fr; }
  .algo-note { min-height: 0; }
  .tool-actions .btn-lg { flex: 1 1 auto; }
  .tool-privacy { margin-inline-start: 0; width: 100%; justify-content: center; order: 3; margin-top: 4px; }

  /* Footer columns fold on a phone; app.js closes them and reveals the caret. */
  .ft-in { grid-template-columns: 1fr; gap: 0; }
  .ft-brand { margin-bottom: 26px; }
  .ft-nav { border-top: 1px solid #1e2536; }
  .ft-col-h { cursor: pointer; padding-block: 14px; min-height: 48px; }
  .ft-col[data-folded] .ft-caret { display: block; transition: transform .2s ease; }
  .ft-col[data-folded][open] .ft-caret { transform: rotate(90deg); }
  .ft-col[data-folded] ul { margin-top: 0; padding-bottom: 14px; }
  .ft-bar { justify-content: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
