/* MoxuTools: site styles, built to the UI redesign spec. Colours, type and radii come from tokens.css. */

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--text); font-family: var(--font-body); font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
main { flex: 1; }
h1, h2, h3 { font-family: var(--font-display); margin: 0; color: var(--text); font-optical-sizing: auto; }
p { margin: 0; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: var(--r-sm); }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); color: var(--text); padding: 8px 12px; border-radius: var(--r-sm); z-index: 50; }
.skip:focus { left: 8px; }
.mono { font-family: var(--font-mono); }
svg { flex: none; }

.wrap { width: 100%; max-width: var(--content-width); margin: 0 auto; padding: 0 32px; }

/* ---------- header ---------- */
.site { position: sticky; top: 0; z-index: 30; background: var(--bg); border-bottom: 1px solid var(--border-subtle); }
.site__inner { max-width: var(--content-width); margin: 0 auto; height: 64px; padding: 0 32px; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand__mark { width: 28px; height: 28px; border-radius: var(--r-sm); background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; }
.brand__mark svg { width: 16px; height: 16px; }
.brand__name { font-family: var(--font-display); font-size: 18px; font-weight: 700; color: var(--text); letter-spacing: -0.02em; }
.brand__name em { font-style: normal; color: var(--accent); }
.nav { display: flex; gap: 22px; margin-left: auto; font-size: 14px; }
.nav a { color: var(--text-muted); text-decoration: none; padding: 6px 0; }
.nav a:hover { color: var(--text); }
.nav a[aria-current] { color: var(--text); font-weight: 500; }
.pill { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 12px; border: 1px solid var(--border); border-radius: var(--r-pill); font-size: 12px; color: var(--text-muted); white-space: nowrap; }
.pill svg { width: 13px; height: 13px; }
.menu-btn { display: none; margin-left: auto; width: 44px; height: 44px; border: 1px solid var(--border-strong); border-radius: var(--r-md); background: transparent; color: var(--text); cursor: pointer; place-items: center; }
.menu-btn svg { width: 20px; height: 20px; }

/* ---------- footer ---------- */
.foot { margin-top: 96px; border-top: 1px solid var(--border-subtle); }
.foot__inner { max-width: var(--content-width); margin: 0 auto; padding: 28px 32px 36px; display: flex; align-items: center; justify-content: space-between; gap: 16px 32px; flex-wrap: wrap; font-size: 13px; color: var(--text-faint); }
.foot__inner p { display: flex; align-items: center; gap: 8px; }
.foot__inner svg { width: 14px; height: 14px; }
.foot nav { display: flex; gap: 22px; }
.foot nav a { color: var(--text-muted); text-decoration: none; }
.foot nav a:hover { color: var(--text); }

/* ---------- tiles (icons) ---------- */
.tile { display: grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-md); background: var(--c-bg); color: var(--c); flex: none; }
.tile svg { width: 20px; height: 20px; }
.tile--sm { width: 36px; height: 36px; }
.tile--lg { width: 56px; height: 56px; border-radius: var(--r-lg); }
.tile--lg svg { width: 28px; height: 28px; }

/* ---------- hero (directory) ---------- */
.hero { padding: 88px 0 0; }
.eyebrow { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 20px; }
.hero h1, .page-head h1 { font-size: clamp(38px, 6vw, 64px); font-weight: 700; letter-spacing: -0.02em; line-height: 1.04; max-width: 15ch; }
.hero__lede { margin-top: 20px; max-width: 52ch; font-size: 17px; color: var(--text-muted); line-height: 1.55; }
.page-head { padding: 64px 0 0; }
.page-head h1 { font-size: clamp(34px, 5vw, 48px); max-width: none; }

/* ---------- search + pills ---------- */
.search { position: relative; max-width: 640px; margin-top: 32px; }
.search__icon { position: absolute; left: 18px; top: 50%; width: 20px; height: 20px; margin-top: -10px; color: var(--text-muted); pointer-events: none; }
.search input { width: 100%; height: 56px; padding: 0 60px 0 50px; border-radius: var(--r-lg); border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: inherit; font-size: 16px; }
.search input::placeholder { color: var(--text-faint); }
.search kbd { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); min-width: 24px; height: 24px; padding: 0 7px; display: grid; place-items: center; border: 1px solid var(--border-strong); border-radius: 6px; font-family: var(--font-mono); font-size: 12px; color: var(--text-faint); }
.pills { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }
.pill-btn { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 16px; border-radius: var(--r-pill); border: 1px solid var(--border-strong); background: transparent; color: var(--text-2); font: inherit; font-size: 14px; cursor: pointer; transition: background .15s, border-color .15s; }
.pill-btn:hover { border-color: var(--text-faint); }
.pill-btn .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); }
.pill-btn[aria-pressed="true"] { background: var(--text); border-color: var(--text); color: var(--bg); font-weight: 500; }
.pill-btn[aria-pressed="true"] .dot { display: none; }

/* ---------- directory sections and cards ---------- */
.topics { margin-top: 72px; }
.topic + .topic { margin-top: 72px; }
.topic__head { display: flex; align-items: center; gap: 14px; padding-bottom: 20px; margin-bottom: 24px; border-bottom: 1px solid var(--border-subtle); }
.topic__head > div { flex: 1; min-width: 0; }
.topic__head h2 { font-size: 24px; font-weight: 600; letter-spacing: -0.015em; }
.topic__head p { font-size: 14px; color: var(--text-muted); margin-top: 2px; }
.topic__count { font-family: var(--font-mono); font-size: 13px; color: var(--text-faint); white-space: nowrap; }
.cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.cards > li { display: flex; margin: 0; }
.card { display: flex; flex-direction: column; width: 100%; min-height: 180px; padding: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); text-decoration: none; color: var(--text); transition: background .15s, border-color .15s, transform .15s; }
.card:hover { background: var(--surface-hover); border-color: var(--c); transform: translateY(-2px); color: var(--text); }
.card__top { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 16px; }
.card__arrow { width: 18px; height: 18px; color: var(--icon-idle); transition: color .15s; }
.card:hover .card__arrow { color: var(--c); }
.card__title { font-family: var(--font-display); font-size: 18px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.25; }
.card__desc { margin-top: 6px; font-size: 14px; line-height: 1.5; color: var(--text-muted); }
.no-results { margin-top: 48px; color: var(--text-muted); }

/* ---------- compact rows (mobile lists, related tools) ---------- */
.rowlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rowlink { display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 12px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); text-decoration: none; color: var(--text); transition: background .15s, border-color .15s; }
.rowlink:hover { background: var(--surface-hover); border-color: var(--c); color: var(--text); }
.rowlink__text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.rowlink__title { font-family: var(--font-display); font-size: 16px; font-weight: 600; }
.rowlink__desc { font-size: 13px; color: var(--text-muted); }
.rowlink__arrow { width: 18px; height: 18px; color: var(--icon-idle); }
.rowlink:hover .rowlink__arrow { color: var(--c); }

/* ---------- tool page ---------- */
.crumbs { padding-top: 32px; font-size: 13px; color: var(--text-faint); }
.crumbs a { color: var(--text-muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); text-decoration: underline; }
.title-row { display: flex; align-items: center; gap: 20px; margin-top: 20px; }
.title-row h1 { font-size: clamp(30px, 4.5vw, 40px); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; }
.title-row p { margin-top: 6px; color: var(--text-muted); font-size: 16px; }
.workbench { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 32px; align-items: start; }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl); padding: 28px; min-width: 0; }
.panel__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.panel__label { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-faint); font-weight: 500; }
.currency { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-muted); }
.privacy-line { display: flex; align-items: center; gap: 8px; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--border-subtle); font-size: 13px; color: var(--text-faint); }
.privacy-line svg { width: 14px; height: 14px; color: var(--cat-money); }

/* inputs */
form { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 20px 16px; }
.field[data-field="mode"], .field:has(textarea), .field:has(.chips) { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field > label, .field__label { font-size: 13px; font-weight: 500; color: var(--text-2); }
.hint { font-size: 12.5px; color: var(--text-faint); line-height: 1.4; }
input, select, textarea { width: 100%; height: 56px; padding: 0 16px; border-radius: calc(var(--r-lg) - 2px); border: 1px solid var(--border-strong); background-color: var(--input-bg); color: var(--text); font-family: var(--font-mono); font-size: 20px; transition: border-color .15s, box-shadow .15s; }
select { appearance: none; padding-right: 44px; font-family: var(--font-body); font-size: 16px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239BA3AB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; background-size: 18px; }
textarea { height: auto; min-height: 112px; padding: 14px 16px; font-size: 15px; line-height: 1.5; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--text-faint); }
input:hover, select:hover, textarea:hover { border-color: var(--text-faint); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--focus-ring); }
.affix-wrap { position: relative; }
.affix { position: absolute; top: 0; bottom: 0; display: flex; align-items: center; color: var(--text-muted); font-family: var(--font-mono); font-size: 20px; pointer-events: none; }
.affix--pre { left: 16px; } .affix--post { right: 16px; }
.affix-wrap:has(.affix--pre) input { padding-left: 34px; }
.affix-wrap:has(.affix--post) input { padding-right: 36px; }
.affix-wrap:has([data-currency].is-empty) input { padding-left: 16px; }

/* segmented control + choice chips (progressive enhancement of a select, see tool.js) */
.is-enhanced select { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.seg { display: flex; padding: 4px; gap: 4px; background: var(--input-bg); border: 1px solid var(--border); border-radius: calc(var(--r-md) + 2px); }
.seg button { flex: 1; height: 44px; padding: 0 12px; border: 0; border-radius: var(--r-md); background: transparent; color: var(--text-muted); font: inherit; font-size: 14px; cursor: pointer; transition: background .15s, color .15s; }
.seg button:hover { color: var(--text); }
.seg button[aria-checked="true"] { background: var(--border); color: var(--text); font-weight: 500; }
.chips { display: grid; grid-template-columns: repeat(auto-fit, minmax(74px, 1fr)); gap: 8px; }
.chips button { min-height: 48px; padding: 8px 10px; border-radius: var(--r-md); border: 1px solid var(--border-strong); background: transparent; color: var(--text-2); font-family: var(--font-body); font-size: 14px; line-height: 1.3; cursor: pointer; transition: border-color .15s, background .15s; }
.chips button:hover { border-color: var(--text-faint); }
.chips button[aria-checked="true"] { border-color: var(--c, var(--accent)); background: var(--c-bg, var(--focus-ring)); color: var(--text); }

/* result panel */
.results { min-height: 120px; }
.results__hint { color: var(--text-muted); font-size: 15px; }
.results__error { color: var(--danger); font-weight: 500; }
.result__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.rows { margin: 0; }
.rows dt { font-size: 13px; color: var(--text-2); }
.rows dd { margin: 0; font-family: var(--font-mono); overflow-wrap: anywhere; }
.result__main .rows__item--primary dd { font-size: clamp(36px, 5vw, 56px); line-height: 1.1; letter-spacing: -0.03em; color: var(--c, var(--accent)); margin-top: 6px; font-weight: 500; }
.copy { display: inline-flex; align-items: center; gap: 8px; height: 44px; min-width: 44px; padding: 0 12px; justify-content: center; border: 1px solid var(--border-strong); border-radius: var(--r-md); background: transparent; color: var(--text-muted); font: inherit; font-size: 13px; cursor: pointer; }
.copy:hover { color: var(--text); border-color: var(--text-faint); }
.copy svg { width: 18px; height: 18px; }
.breakdown { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); margin-top: 20px; border: 1px solid var(--border); border-radius: var(--r-md); overflow: hidden; }
.breakdown .rows__item { padding: 14px 16px; min-width: 0; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); margin: 0 -1px -1px 0; }
.breakdown dd { font-size: 17px; margin-top: 4px; color: var(--text); }
.results__explain { margin-top: 18px; color: var(--text-muted); font-size: 15px; }
.working { margin-top: 24px; }
.working__title { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 12px; }
.working ol { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: 12px; }
.working li { counter-increment: step; position: relative; padding-left: 34px; font-size: 14.5px; line-height: 1.55; color: var(--text-2); }
.working li::before { content: counter(step); position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: 50%; background: var(--surface-raised); color: var(--text-muted); font-family: var(--font-mono); font-size: 12px; display: grid; place-items: center; }
.working .num { font-family: var(--font-mono); font-size: 0.95em; color: var(--text); white-space: nowrap; }
.working--single { margin-top: 20px; }
.working--single p { font-size: 14.5px; color: var(--text-2); }

/* ---------- content below the tool ---------- */
.content { margin-top: 64px; max-width: 760px; }
.content section + section { margin-top: 48px; }
.content h2, .wrap > section > h2, .related h2 { font-size: 24px; font-weight: 600; letter-spacing: -0.02em; margin-bottom: 14px; }
.content p, .content li { color: var(--text-2); line-height: 1.65; max-width: 68ch; }
.content p + p { margin-top: 12px; }
.content ul { padding-left: 20px; } .content li { margin-bottom: 6px; }
.content strong { color: var(--text); }
.content code, code { font-family: var(--font-mono); font-size: .92em; background: var(--surface-raised); padding: 1px 6px; border-radius: 5px; }
.content table { border-collapse: collapse; margin: 14px 0; font-size: 15px; display: block; max-width: 100%; overflow-x: auto; }
.content th, .content td { text-align: left; padding: 8px 18px 8px 0; border-bottom: 1px solid var(--border); }
.content th { color: var(--text-muted); font-weight: 500; font-size: 13px; }
.examples { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 16px; }
.example { display: flex; flex-direction: column; gap: 12px; padding: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); }
.example h3 { font-family: var(--font-display); font-size: 16px; font-weight: 600; }
.example .rows { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; }
.example .rows dd { font-size: 16px; margin-top: 2px; }
.example .rows__item--primary { grid-column: 1 / -1; }
.example .rows__item--primary dd { font-size: 26px; color: var(--c, var(--accent)); }
.example__explain { color: var(--text-muted); font-size: 14px; flex: 1; }
details.working-ex { font-size: 14px; }
details.working-ex summary { cursor: pointer; color: var(--text-muted); }
details.working-ex ol { margin: 8px 0 0; padding-left: 20px; color: var(--text-2); }
.faq details { border-bottom: 1px solid var(--border); max-width: 68ch; }
.faq summary { cursor: pointer; padding: 16px 0; font-weight: 500; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--font-mono); color: var(--text-faint); font-size: 20px; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq summary:hover { color: var(--accent); }
.faq p { padding-bottom: 16px; color: var(--text-muted); }
.related { margin-top: 64px; }
.related .rowlist { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.reviewed { margin-top: 48px; color: var(--text-faint); font-size: 13px; max-width: 68ch; }
.prose { padding-top: 24px; max-width: 760px; }
.prose h1 { font-size: 40px; font-weight: 700; letter-spacing: -0.03em; margin: 12px 0 16px; }
.prose h2 { font-size: 22px; margin: 36px 0 10px; }
.prose p, .prose li { color: var(--text-2); line-height: 1.65; }
.prose ul { padding-left: 20px; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 20px; border-radius: var(--r-md); border: 1px solid var(--border-strong); background: transparent; color: var(--text-2); font: inherit; font-size: 15px; font-weight: 500; cursor: pointer; text-decoration: none; transition: background .15s, border-color .15s, color .15s; }
.btn:hover { border-color: var(--text-faint); color: var(--text); }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn--primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn--primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-ink); }
.btn--small { height: 36px; padding: 0 14px; font-size: 13.5px; }
.btn--ghost { color: var(--text-muted); }

/* ---------- file tools (same components) ---------- */
.tool-card { margin-top: 32px; padding: 28px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl); }
.tool-card__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.util-badge { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; border: 1px solid var(--border); border-radius: var(--r-pill); font-size: 12px; color: var(--text-muted); }
.util-badge svg { width: 13px; height: 13px; color: var(--cat-money); }
#util-root { display: grid; gap: 14px; }
.util-drop { padding: 44px 20px; text-align: center; border: 1.5px dashed var(--border-strong); border-radius: var(--r-xl); background: var(--input-bg); cursor: pointer; transition: border-color .15s, background .15s; }
.util-drop::before { content: ""; display: block; width: 44px; height: 44px; margin: 0 auto 14px; border-radius: var(--r-md); background: var(--c-bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237AA7FF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 16V5'/%3E%3Cpath d='m7 9 5-5 5 5'/%3E%3Cpath d='M4 16v3a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-3'/%3E%3C/svg%3E") center / 22px no-repeat; }
.util-drop:hover, .util-drop:focus-visible, .util-drop.is-over { border-color: var(--accent); background: var(--surface-hover); outline: none; }
.util-drop__title { font-family: var(--font-display); font-weight: 600; font-size: 18px; }
.util-drop__sub { color: var(--text-muted); font-size: 14px; margin-top: 4px; }
.util-panel { display: grid; gap: 14px; }
.util-file { font-family: var(--font-mono); font-size: 14px; color: var(--text-2); overflow-wrap: anywhere; }
.util-fieldset { border: 1px solid var(--border); border-radius: var(--r-md); padding: 12px 16px; margin: 0; display: grid; gap: 8px; max-height: 240px; overflow: auto; justify-items: start; }
.util-fieldset legend { padding: 0 6px; font-size: 13px; color: var(--text-muted); }
.util-check { display: flex; gap: 10px; align-items: center; font-size: 15px; color: var(--text-2); text-align: left; }
.util-check input[type="checkbox"] { width: 18px; height: 18px; min-height: 0; padding: 0; margin: 0; flex: none; accent-color: var(--accent); }
.util-summary { font-weight: 500; }
.util-note { color: var(--text-muted); font-size: 14px; }
.util-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 16px; }
.util-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.util-status { min-height: 1.4em; color: var(--text-muted); font-size: 14px; }
.util-status.is-ok { color: var(--cat-money); } .util-status.is-error { color: var(--danger); }
.util-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.util-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--input-bg); }
.util-item__n { width: 24px; height: 24px; border-radius: 50%; background: var(--surface-raised); display: grid; place-items: center; font-family: var(--font-mono); font-size: 12px; flex: none; }
.util-item__text { flex: 1; min-width: 0; }
.util-item__name { font-weight: 500; overflow-wrap: anywhere; }
.util-item__meta { font-family: var(--font-mono); font-size: 12.5px; color: var(--text-muted); }
.util-item__meta.is-error { color: var(--danger); }
.util-x { width: 36px; height: 36px; border: 0; border-radius: var(--r-sm); background: none; color: var(--text-muted); font-size: 18px; cursor: pointer; flex: none; }
.util-x:hover:not(:disabled) { color: var(--text); background: var(--surface-raised); } .util-x:disabled { opacity: .3; cursor: default; }
.util-tablewrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--r-md); }
.util-table { border-collapse: collapse; width: 100%; font-family: var(--font-mono); font-size: 12.5px; }
.util-table th, .util-table td { padding: 6px 10px; border-bottom: 1px solid var(--border-subtle); text-align: left; white-space: nowrap; }
.rp-warn { margin: 0; padding-left: 18px; color: var(--text-muted); font-size: 14px; display: grid; gap: 4px; } .rp-warn:empty { display: none; }
.rp-door { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 12px 14px; border: 1px dashed var(--border-strong); border-radius: var(--r-md); font-size: 14px; color: var(--text-muted); }
.rp-preview { display: grid; gap: 14px; justify-items: center; }
.rp-page { width: 100%; max-width: 720px; border-radius: var(--r-sm); background: #fff; }
.howto { padding-left: 22px; display: grid; gap: 6px; color: var(--text-2); }
.nudge { margin-top: 48px; padding: 24px; border: 1px solid var(--border); border-radius: var(--r-xl); background: var(--surface); max-width: 760px; }
.nudge h2 { font-size: 20px; margin: 0 0 8px; } .nudge p { color: var(--text-muted); margin-bottom: 14px; }

/* ---------- responsive ---------- */
@media (max-width: 1023px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .workbench { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
  .site__inner { gap: 12px; }
  .pill { display: none; }
  .menu-btn { display: grid; }
  .nav { display: none; position: absolute; top: 56px; left: 0; right: 0; flex-direction: column; gap: 0; margin: 0; padding: 8px var(--gutter-mobile) 16px; background: var(--bg); border-bottom: 1px solid var(--border-subtle); }
  .nav.is-open { display: flex; }
  .nav a { padding: 14px 0; font-size: 16px; min-height: 44px; border-bottom: 1px solid var(--border-subtle); }
}
@media (max-width: 640px) {
  .wrap, .site__inner, .foot__inner { padding-left: var(--gutter-mobile); padding-right: var(--gutter-mobile); }
  .site__inner { height: 56px; }
  .nav { top: 56px; }
  .hero { padding-top: 44px; } .page-head { padding-top: 36px; }
  .hero h1 { font-size: 38px; }
  .search input { height: 52px; } .search kbd { display: none; }
  .pills { flex-wrap: nowrap; overflow-x: auto; margin-right: calc(var(--gutter-mobile) * -1); padding-right: var(--gutter-mobile); scrollbar-width: none; }
  .pills::-webkit-scrollbar { display: none; }
  .pill-btn { height: 40px; flex: none; }
  .topics { margin-top: 44px; } .topic + .topic { margin-top: 44px; }
  .cards { grid-template-columns: 1fr; gap: 10px; }
  .card { min-height: 0; flex-direction: row; align-items: center; gap: 14px; padding: 14px; }
  .card__top { margin: 0; } .card__arrow { display: none; }
  .card__body { flex: 1; min-width: 0; }
  .card__desc { font-size: 13px; margin-top: 2px; }
  .title-row { align-items: flex-start; gap: 14px; } .tile--lg { width: 44px; height: 44px; } .tile--lg svg { width: 22px; height: 22px; }
  .panel, .tool-card { padding: 20px; border-radius: var(--r-lg); }
  .workbench { gap: 16px; }
  .foot { margin-top: 64px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; } .card:hover { transform: none; } }
@media print { .site, .foot, form, .pills, .search { display: none; } body { background: #fff; color: #000; } }

/* small additions */
.card__title, .card__desc, .card__body { display: block; }
details.working { margin: 0; }
details.working summary { cursor: pointer; font-size: 14px; color: var(--text-muted); }
details.working ol { margin-top: 10px; }
.hero + .search, .hero .search { margin-top: 32px; }
.page-head .hero__lede { margin-top: 16px; }
.hero { padding-bottom: 0; }
.tool-card__head h2 { margin: 0; }

.chips--num button { font-family: var(--font-mono); font-size: 15px; }
