/* NosHost shared components. Depends on tokens.css. */

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--font-sans); font-size: var(--fs-md); line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  min-height: 100vh; display: flex; flex-direction: column;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4 { line-height: var(--lh-tight); margin: 0 0 var(--s-3); letter-spacing: -0.015em; font-weight: 640; }
h1 { font-size: var(--fs-3xl); letter-spacing: -0.025em; }
h2 { font-size: var(--fs-xl); }
h3 { font-size: var(--fs-lg); }
h4 { font-size: var(--fs-md); }
p { margin: 0 0 var(--s-3); }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
code, kbd, pre, samp, .mono { font-family: var(--font-mono); font-size: 0.92em; }
:not(pre) > code { background: var(--surface-2); border: 1px solid var(--border); padding: 0.05em 0.35em; border-radius: 5px; }
hr { border: 0; border-top: 1px solid var(--border); margin: var(--s-6) 0; }
ul, ol { padding-left: 1.3em; margin: 0 0 var(--s-3); }
[hidden] { display: none !important; }
::selection { background: var(--accent-soft); color: var(--text); }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline-offset: 0; }

.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--accent); color: var(--accent-text); padding: 10px 14px; border-radius: var(--r-sm); font-weight: 600; text-decoration: none; }
.skip-link:focus { top: 10px; color: var(--accent-text); }

.icon { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 15px; height: 15px; }
.icon-lg { width: 22px; height: 22px; }

.muted { color: var(--muted); }
.small { font-size: var(--fs-sm); }
.xs { font-size: var(--fs-xs); }
.nowrap { white-space: nowrap; }
.stack > * + * { margin-top: var(--gap); }
.row { display: flex; align-items: center; gap: var(--s-2); flex-wrap: wrap; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; }
.grow { flex: 1 1 auto; min-width: 0; }
.dotgrid { background-image: radial-gradient(var(--dot) 1px, transparent 1px); background-size: 18px 18px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(140%) blur(10px); -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner { height: 100%; display: flex; align-items: center; gap: var(--s-3); padding: 0 var(--s-4); max-width: 1600px; margin: 0 auto; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 1.05rem; letter-spacing: -0.02em; flex: none; }
.brand:hover { color: var(--text); }
.brand-mark { width: 28px; height: 28px; border-radius: 6px; background: #14171b; color: #f5f7f8; display: grid; place-items: center; }
.brand-mark svg { width: 28px; height: 28px; }
.brand b { color: var(--accent); font-weight: 700; }
.main-nav { display: flex; gap: 2px; margin-left: var(--s-2); }
.main-nav a { color: var(--text-2); text-decoration: none; padding: 7px 11px; border-radius: var(--r-sm); font-size: var(--fs-sm); font-weight: 520; }
.main-nav a:hover { background: var(--surface-2); color: var(--text); }
.main-nav a[aria-current="page"] { color: var(--text); background: var(--surface-2); }
.search-trigger {
  margin-left: auto; display: flex; align-items: center; gap: 10px; width: min(380px, 40vw);
  height: 38px; padding: 0 8px 0 12px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--border); color: var(--muted);
  font: inherit; font-size: var(--fs-sm); cursor: pointer; text-align: left;
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.search-trigger:hover { border-color: var(--border-strong); box-shadow: var(--shadow-sm); }
.search-trigger span.grow { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
kbd, .kbd {
  font-family: var(--font-mono); font-size: 11px; line-height: 1; padding: 4px 6px; border-radius: 5px;
  border: 1px solid var(--border); border-bottom-width: 2px; background: var(--surface-2); color: var(--muted); white-space: nowrap;
}
.header-actions { display: flex; align-items: center; gap: 4px; }
.btn.nav-toggle { display: none; }

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: var(--surface); --btn-fg: var(--text); --btn-bd: var(--border);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: var(--control-h); padding: 0 14px; border-radius: var(--r-sm);
  background: var(--btn-bg); color: var(--btn-fg); border: 1px solid var(--btn-bd);
  font: inherit; font-size: var(--fs-sm); font-weight: 560; cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: background var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.btn:hover { --btn-bg: var(--surface-2); --btn-bd: var(--border-strong); color: var(--btn-fg); }
.btn:active { transform: translateY(1px); }
.btn-primary { --btn-bg: var(--accent); --btn-fg: var(--accent-text); --btn-bd: var(--accent); }
.btn-primary:hover { --btn-bg: var(--accent-hover); --btn-bd: var(--accent-hover); }
.btn-ghost { --btn-bg: transparent; --btn-bd: transparent; color: var(--text-2); }
.btn-ghost:hover { --btn-bg: var(--surface-2); --btn-bd: transparent; }
.btn-danger { --btn-fg: var(--fail); }
.btn-sm { height: var(--control-h-sm); padding: 0 10px; font-size: var(--fs-xs); }
.btn-lg { height: 46px; padding: 0 20px; font-size: var(--fs-md); }
.btn-icon { width: var(--control-h); padding: 0; }
.btn-icon.btn-sm { width: var(--control-h-sm); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; transform: none; }
.btn.is-copied { --btn-fg: var(--pass); }
.btn.is-failed { --btn-fg: var(--fail); }
.fav-btn[aria-pressed="true"] { color: var(--warn); }
.fav-btn[aria-pressed="true"] .icon { fill: currentColor; }

/* ---------- App layout ---------- */
.app { flex: 1; display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); max-width: 1600px; width: 100%; margin: 0 auto; }
.app.no-sidebar { grid-template-columns: minmax(0, 1fr); }
html[data-sidebar="collapsed"] .app:not(.no-sidebar) { grid-template-columns: var(--sidebar-w-collapsed) minmax(0, 1fr); }
.main { min-width: 0; overflow-x: clip; padding: var(--s-6) var(--s-6) var(--s-16); }
.main-narrow { max-width: var(--content-max); margin: 0 auto; width: 100%; }

.sidebar {
  position: sticky; top: var(--header-h); height: calc(100vh - var(--header-h)); overflow-y: auto; overscroll-behavior: contain;
  border-right: 1px solid var(--border); padding: var(--s-4) var(--s-3) var(--s-6); scrollbar-width: thin;
}
.sidebar-section + .sidebar-section { margin-top: var(--s-5); }
.sidebar-title { display: flex; align-items: center; justify-content: space-between; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 0 10px; margin-bottom: 6px; }
.side-link {
  display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: var(--r-sm);
  color: var(--text-2); text-decoration: none; font-size: var(--fs-sm); line-height: 1.3;
}
.side-link:hover { background: var(--surface-2); color: var(--text); }
.side-link[aria-current="page"] { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.side-link .count { margin-left: auto; font-family: var(--font-mono); font-size: 11px; color: var(--muted); }
.side-link .label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-empty { font-size: var(--fs-xs); color: var(--muted); padding: 4px 10px; margin: 0; }
.sidebar-collapse { width: 100%; justify-content: flex-start; margin-bottom: var(--s-3); }
html[data-sidebar="collapsed"] .sidebar { padding-left: 8px; padding-right: 8px; }
html[data-sidebar="collapsed"] .sidebar .label,
html[data-sidebar="collapsed"] .sidebar .count,
html[data-sidebar="collapsed"] .sidebar .sidebar-title,
html[data-sidebar="collapsed"] .sidebar .side-empty,
html[data-sidebar="collapsed"] .sidebar [data-collapsible-hide] { display: none; }
html[data-sidebar="collapsed"] .side-link, html[data-sidebar="collapsed"] .sidebar-collapse { justify-content: center; padding: 9px 0; }
html[data-sidebar="collapsed"] .sidebar-collapse .icon { transform: rotate(180deg); }

/* ---------- Recent bar ---------- */
.recent-bar { border-bottom: 1px solid var(--border); background: var(--bg-elev); }
.recent-inner { max-width: 1600px; margin: 0 auto; display: flex; align-items: center; gap: var(--s-2); padding: 6px var(--s-4); min-height: 42px; }
.recent-list { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; flex: 1; min-width: 0; padding: 2px; }
.recent-list::-webkit-scrollbar { display: none; }
.recent-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: var(--r-pill); border: 1px solid var(--border); background: var(--surface); font-size: var(--fs-xs); color: var(--text-2); text-decoration: none; white-space: nowrap; }
.recent-chip:hover { border-color: var(--border-strong); color: var(--text); }

/* ---------- Breadcrumbs / page head ---------- */
.breadcrumbs ol { list-style: none; padding: 0; margin: 0 0 var(--s-4); display: flex; flex-wrap: wrap; gap: 4px; font-size: var(--fs-sm); color: var(--muted); }
.breadcrumbs li { display: inline-flex; align-items: center; gap: 4px; }
.breadcrumbs li + li::before { content: "/"; color: var(--border-strong); margin-right: 2px; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--text); text-decoration: underline; }
.page-head { margin-bottom: var(--s-6); }
.page-head h1 { margin-bottom: var(--s-2); }
.page-head .lede { color: var(--text-2); font-size: var(--fs-lg); max-width: 68ch; margin: 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin-bottom: var(--s-2); }

/* ---------- Surfaces ---------- */
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: var(--card-pad); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); margin-bottom: var(--s-3); flex-wrap: wrap; }
.panel-head h2, .panel-head h3 { margin: 0; }
.panel-flush { padding: 0; overflow: hidden; }
.section { margin-top: var(--s-12); }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: var(--s-4); margin-bottom: var(--s-4); flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.section-head p { margin: 4px 0 0; color: var(--muted); }

.demo-note {
  display: flex; gap: 10px; align-items: flex-start; padding: 10px 14px; border-radius: var(--r-md);
  background: var(--info-soft); color: var(--text); border: 1px dashed color-mix(in srgb, var(--info) 45%, transparent); font-size: var(--fs-sm);
}
.demo-note .icon { color: var(--info); margin-top: 2px; }
.demo-note p { margin: 0; }
.tag { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: var(--r-pill); font-size: 11.5px; font-weight: 560; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border); white-space: nowrap; }
.tag-mono { font-family: var(--font-mono); font-weight: 450; }
.tag-accent { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.tag-demo { background: transparent; border-style: dashed; color: var(--muted); }

/* ---------- Tool cards ---------- */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: var(--gap); }
.tool-card {
  position: relative; display: flex; flex-direction: column; gap: 8px; padding: var(--card-pad);
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg);
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.tool-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-md); }
.tool-card:focus-within { border-color: var(--accent); }
.tool-card .tc-top { display: flex; align-items: center; gap: 10px; }
.tool-ico { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; background: var(--surface-2); color: var(--text-2); flex: none; border: 1px solid var(--border); }
.tool-card h3 { font-size: var(--fs-md); margin: 0; font-weight: 600; line-height: 1.3; }
.tool-card .tc-link { color: var(--text); text-decoration: none; }
.tool-card .tc-link::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.tool-card .tc-link:focus-visible { outline: none; }
.tool-card .tc-link:focus-visible::after { outline: 2px solid var(--accent); outline-offset: 2px; }
.tool-card p { margin: 0; color: var(--muted); font-size: var(--fs-sm); line-height: 1.5; }
.tool-card .tc-meta { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; padding-top: 4px; }
.tool-card .fav-btn { position: relative; z-index: 2; margin-left: auto; }
.tool-list { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--surface); overflow: hidden; }
.tool-list .tool-card { flex-direction: row; align-items: center; border: 0; border-radius: 0; gap: var(--s-3); padding: var(--row-pad) var(--card-pad); }
.tool-list .tool-card + .tool-card { border-top: 1px solid var(--border); }
.tool-list .tool-card:hover { box-shadow: none; background: var(--surface-2); }
.tool-list .tool-card .tc-top { flex: 0 0 300px; min-width: 0; }
.tool-list .tool-card p { flex: 1; min-width: 0; }
.tool-list .tool-card .tc-meta { margin: 0; padding: 0; flex: none; }
.tool-list .tool-card .tc-cat { display: none; }
.tool-list .tool-card .fav-btn { margin-left: 0; order: 9; }

/* ---------- Chips / segmented / filters ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 12px; border-radius: var(--r-pill);
  border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font: inherit; font-size: var(--fs-sm); cursor: pointer; text-decoration: none;
}
.chip:hover { border-color: var(--border-strong); color: var(--text); }
.chip[aria-pressed="true"], .chip[aria-current="page"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.chip .count { font-family: var(--font-mono); font-size: 11px; opacity: .7; }
.seg { display: inline-flex; padding: 3px; gap: 2px; border-radius: var(--r-md); background: var(--surface-2); border: 1px solid var(--border); }
.seg button { display: inline-flex; align-items: center; gap: 6px; height: calc(var(--control-h-sm) - 2px); padding: 0 10px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); font: inherit; font-size: var(--fs-xs); font-weight: 560; cursor: pointer; }
.seg button[aria-pressed="true"], .seg button[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2); margin-bottom: var(--s-4); }

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field + .field { margin-top: var(--s-4); }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: var(--s-4); }
.field-row > .field + .field { margin-top: 0; }
label, .label { font-size: var(--fs-sm); font-weight: 580; color: var(--text); }
.hint { font-size: var(--fs-xs); color: var(--muted); margin: 0; }
.input, .select, .textarea {
  width: 100%; min-height: var(--control-h); padding: 0 12px; border-radius: var(--r-sm);
  border: 1px solid var(--input-border); background: var(--bg-elev); color: var(--text);
  font: inherit; font-size: var(--fs-md);
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.textarea { padding: 10px 12px; min-height: 120px; resize: vertical; line-height: 1.5; }
.input.mono, .textarea.mono { font-family: var(--font-mono); font-size: var(--fs-sm); }
.select { appearance: none; padding-right: 34px; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 17px) 50%, calc(100% - 12px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
.input:hover, .select:hover, .textarea:hover { border-color: var(--muted); }
.input:focus, .select:focus, .textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); outline: none; }
.input[aria-invalid="true"], .textarea[aria-invalid="true"] { border-color: var(--fail); }
.input[aria-invalid="true"]:focus { box-shadow: 0 0 0 3px color-mix(in srgb, var(--fail) 35%, transparent); }
.error-text { display: flex; gap: 6px; align-items: flex-start; color: var(--fail); font-size: var(--fs-sm); margin: 0; }
.input-group { display: flex; gap: var(--s-2); }
.input-group .input { flex: 1; }
.input-affix { position: relative; }
.input-affix .icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.input-affix .input { padding-left: 38px; }
.check { display: flex; align-items: flex-start; gap: 10px; font-size: var(--fs-sm); cursor: pointer; font-weight: 450; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); margin: 1px 0 0; flex: none; }
.radio-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 8px; }
.radio-card { position: relative; }
.radio-card input { position: absolute; opacity: 0; inset: 0; }
.radio-card span { display: block; padding: 10px 12px; border: 1px solid var(--input-border); border-radius: var(--r-md); background: var(--surface); font-size: var(--fs-sm); cursor: pointer; }
.radio-card input:checked + span { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); background: var(--accent-soft); }
.radio-card input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.radio-card small { display: block; color: var(--muted); font-size: var(--fs-xs); }
.examples { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: var(--fs-sm); }
.examples > span { color: var(--muted); }
.link-btn { text-align: left; background: none; border: 0; padding: 0; color: var(--accent); font: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

/* ---------- Disclosure: Advanced / Accordion ---------- */
details.disclosure { border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface); }
details.disclosure > summary { list-style: none; cursor: pointer; padding: 10px 14px; display: flex; align-items: center; gap: 8px; font-size: var(--fs-sm); font-weight: 580; border-radius: inherit; }
details.disclosure > summary::-webkit-details-marker { display: none; }
details.disclosure > summary .chev { margin-left: auto; transition: transform var(--t-med) var(--ease); color: var(--muted); }
details.disclosure[open] > summary .chev { transform: rotate(180deg); }
details.disclosure > .disclosure-body { padding: 4px 14px 14px; }
.accordion { border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--surface); overflow: hidden; }
.accordion details + details { border-top: 1px solid var(--border); }
.accordion summary { list-style: none; cursor: pointer; padding: 14px 16px; display: flex; gap: 10px; align-items: center; font-weight: 580; }
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary .chev { margin-left: auto; color: var(--muted); transition: transform var(--t-med) var(--ease); }
.accordion details[open] summary .chev { transform: rotate(180deg); }
.accordion .acc-body { padding: 0 16px 16px; color: var(--text-2); }
.accordion .acc-body p:last-child { margin: 0; }

/* ---------- Workspace ---------- */
.tool-head { display: flex; align-items: flex-start; gap: var(--s-4); margin-bottom: var(--s-5); }
.tool-head .tool-ico { width: 46px; height: 46px; border-radius: 12px; }
.tool-head .tool-ico .icon { width: 22px; height: 22px; }
.tool-head h1 { font-size: var(--fs-2xl); margin-bottom: 4px; }
.tool-head p { color: var(--text-2); margin: 0; max-width: 70ch; }
.tool-head .tool-actions { margin-left: auto; display: flex; gap: 6px; flex: none; }
.workspace { display: grid; gap: var(--gap); grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 1100px) {
  .workspace.split { grid-template-columns: minmax(340px, 5fr) minmax(0, 7fr); }
}
.ws-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; margin-top: var(--s-4); }

/* ---------- Status + result cards ---------- */
.status { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px 0 7px; border-radius: var(--r-pill); font-size: 12px; font-weight: 620; white-space: nowrap; }
.status .icon { width: 14px; height: 14px; stroke-width: 2.2; }
.st-pass { color: var(--pass); background: var(--pass-soft); }
.st-warn { color: var(--warn); background: var(--warn-soft); }
.st-fail { color: var(--fail); background: var(--fail-soft); }
.st-na { color: var(--na); background: var(--na-soft); }
.st-info { color: var(--info); background: var(--info-soft); }
.result-list { display: flex; flex-direction: column; gap: 10px; }
.result-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 12px; padding: 14px var(--card-pad); border: 1px solid var(--border); border-left-width: 4px; border-radius: var(--r-md); background: var(--surface); }
.result-card.rc-pass { border-left-color: var(--pass); }
.result-card.rc-warn { border-left-color: var(--warn); }
.result-card.rc-fail { border-left-color: var(--fail); }
.result-card.rc-na { border-left-color: var(--na); border-left-style: dashed; }
.result-card .rc-icon { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; grid-row: span 2; }
.rc-pass .rc-icon { background: var(--pass-soft); color: var(--pass); }
.rc-warn .rc-icon { background: var(--warn-soft); color: var(--warn); }
.rc-fail .rc-icon { background: var(--fail-soft); color: var(--fail); }
.rc-na .rc-icon { background: var(--na-soft); color: var(--na); }
.result-card h3 { font-size: var(--fs-md); margin: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.result-card p { margin: 0; color: var(--text-2); font-size: var(--fs-sm); }
.result-card .rc-fix { grid-column: 2; margin-top: 8px; padding: 10px 12px; border-radius: var(--r-sm); background: var(--surface-2); font-size: var(--fs-sm); }
.result-card .rc-fix strong { display: block; font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 2px; }
.summary-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; }
.summary-strip > div { background: var(--surface); padding: 14px 16px; }
.summary-strip .k { font-size: var(--fs-xs); color: var(--muted); display: flex; align-items: center; gap: 6px; }
.summary-strip .v { font-size: var(--fs-xl); font-weight: 650; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; margin-top: 2px; }
.summary-strip .v small { font-size: var(--fs-sm); color: var(--muted); font-weight: 500; }

/* ---------- Code blocks ---------- */
.code-block { border: 1px solid var(--border); border-radius: var(--r-md); background: var(--code-bg); overflow: hidden; }
.code-head { display: flex; align-items: center; gap: 6px; padding: 6px 6px 6px 12px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.code-head .lang { font-family: var(--font-mono); font-size: 11.5px; color: var(--muted); margin-right: auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.code-block pre { margin: 0; padding: 14px 16px; overflow: auto; font-size: 13px; line-height: 1.65; color: var(--code-text); tab-size: 2; max-height: 460px; }
.code-block pre code { font-size: inherit; }
.code-block.wrap pre { white-space: pre-wrap; word-break: break-word; }
.tok-k { color: var(--tok-key); } .tok-s { color: var(--tok-str); } .tok-n { color: var(--tok-num); } .tok-c { color: var(--tok-com); font-style: italic; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface); -webkit-overflow-scrolling: touch; }
.table-wrap:focus-visible { outline-offset: 2px; }
table.data { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
table.data th, table.data td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
table.data th { font-size: var(--fs-xs); font-weight: 600; color: var(--muted); background: var(--surface-2); white-space: nowrap; position: sticky; top: 0; }
table.data tr:last-child td { border-bottom: 0; }
table.data td.num, table.data th.num { text-align: right; }
table.data .url { font-family: var(--font-mono); font-size: 12.5px; word-break: break-all; min-width: 220px; }
table.data tbody tr:hover td { background: color-mix(in srgb, var(--surface-2) 60%, transparent); }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); overflow-x: auto; scrollbar-width: none; margin-bottom: var(--s-4); }
.tabs::-webkit-scrollbar { display: none; }
.tabs [role="tab"] { position: relative; border: 0; background: none; padding: 10px 12px; font: inherit; font-size: var(--fs-sm); font-weight: 560; color: var(--muted); cursor: pointer; white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; }
.tabs [role="tab"]:hover { color: var(--text); }
.tabs [role="tab"][aria-selected="true"] { color: var(--text); }
.tabs [role="tab"][aria-selected="true"]::after { content: ""; position: absolute; left: 8px; right: 8px; bottom: -1px; height: 2px; background: var(--accent); border-radius: 2px; }
.tabs [role="tab"] .count { font-family: var(--font-mono); font-size: 11px; background: var(--surface-2); padding: 1px 6px; border-radius: 99px; }

/* ---------- Tooltip (works with hover, focus and tap) ---------- */
.tip { position: relative; display: inline-flex; }
.tip-btn { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); cursor: help; padding: 0; }
.tip-btn:hover { color: var(--text); background: var(--surface-2); }
.tip-bubble {
  position: absolute; z-index: 60; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%);
  width: max-content; max-width: min(280px, 80vw); padding: 8px 10px; border-radius: var(--r-sm);
  background: var(--text); color: var(--bg); font-size: var(--fs-xs); font-weight: 450; line-height: 1.45; text-align: left;
  box-shadow: var(--shadow-md); pointer-events: none; opacity: 0; visibility: hidden; transition: opacity var(--t-fast) var(--ease);
}
.tip.is-open .tip-bubble, .tip:hover .tip-bubble, .tip:focus-within .tip-bubble { opacity: 1; visibility: visible; }
.tip.align-start .tip-bubble { left: 0; transform: none; }
.tip.align-end .tip-bubble { left: auto; right: 0; transform: none; }

/* ---------- Dialogs ---------- */
dialog { border: 0; padding: 0; background: transparent; color: var(--text); max-width: none; max-height: none; }
dialog::backdrop { background: var(--overlay); backdrop-filter: blur(2px); }
.modal { width: min(560px, calc(100vw - 24px)); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); margin: 10vh auto auto; }
.modal-head { display: flex; align-items: center; gap: var(--s-3); padding: 16px 18px; border-bottom: 1px solid var(--border); }
.modal-head h2 { margin: 0; font-size: var(--fs-lg); }
.modal-head .btn-icon { margin-left: auto; }
.modal-body { padding: 18px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 18px; border-top: 1px solid var(--border); flex-wrap: wrap; }

.palette { width: min(640px, calc(100vw - 24px)); margin: 9vh auto auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); overflow: hidden; }
.palette-input { display: flex; align-items: center; gap: 10px; padding: 0 14px; border-bottom: 1px solid var(--border); }
.palette-input .icon { color: var(--muted); }
.palette-input input { flex: 1; height: 54px; border: 0; background: transparent; color: var(--text); font: inherit; font-size: var(--fs-lg); min-width: 0; }
.palette-input input:focus { outline: none; }
.palette-results { max-height: min(56vh, 460px); overflow-y: auto; padding: 6px; overscroll-behavior: contain; }
.palette-group { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 10px 10px 4px; font-weight: 600; }
.palette-item { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: var(--r-sm); cursor: pointer; color: var(--text); text-decoration: none; }
.palette-item[aria-selected="true"] { background: var(--accent-soft); }
.palette-item .pi-text { min-width: 0; flex: 1; }
.palette-item .pi-title { display: block; font-weight: 560; font-size: var(--fs-sm); }
.palette-item .pi-desc { display: block; font-size: var(--fs-xs); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.palette-item mark { background: transparent; color: var(--accent); font-weight: 700; }
.palette-foot { display: flex; gap: 14px; align-items: center; padding: 8px 14px; border-top: 1px solid var(--border); font-size: var(--fs-xs); color: var(--muted); background: var(--surface-2); flex-wrap: wrap; }
.palette-empty { padding: 28px 16px; text-align: center; color: var(--muted); font-size: var(--fs-sm); }

.fullview { width: 100vw; height: 100vh; height: 100dvh; margin: 0; background: var(--bg); display: flex; flex-direction: column; }
dialog.fullview-dialog { width: 100vw; height: 100vh; max-width: 100vw; max-height: 100vh; margin: 0; inset: 0; }
.fullview-head { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--border); background: var(--surface); }
.fullview-head h2 { margin: 0; font-size: var(--fs-md); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fullview-body { flex: 1; overflow: auto; padding: 20px; }
.fullview-body .code-block pre { max-height: none; }

/* ---------- Toasts ---------- */
.toasts { position: fixed; z-index: 300; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: max-content; max-width: calc(100vw - 24px); }
.toast { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: var(--r-md); background: var(--text); color: var(--bg); font-size: var(--fs-sm); box-shadow: var(--shadow-lg); animation: toast-in var(--t-med) var(--ease); pointer-events: auto; }
.toast.t-fail .icon { color: #ff9a8f; }
.toast.t-pass .icon { color: #7be3a1; }
[data-theme="dark"] .toast.t-fail .icon { color: var(--fail-soft); }
[data-theme="dark"] .toast.t-pass .icon { color: #157239; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- Dropzone ---------- */
.dropzone { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 8px; padding: 32px 20px; border: 2px dashed var(--border-strong); border-radius: var(--r-lg); background: var(--surface); transition: border-color var(--t-fast) var(--ease), background var(--t-fast) var(--ease); }
.dropzone.is-over { border-color: var(--accent); background: var(--accent-soft); }
.dropzone .dz-icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--text-2); }
.dropzone h3 { margin: 4px 0 0; font-size: var(--fs-md); }
.dropzone p { margin: 0; color: var(--muted); font-size: var(--fs-sm); }
.file-pill { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface); }
.file-pill .grow { min-width: 0; }
.file-pill strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--fs-sm); }

/* ---------- States ---------- */
.empty-state { text-align: center; padding: 40px 20px; border: 1px dashed var(--border-strong); border-radius: var(--r-lg); color: var(--muted); }
.empty-state .es-icon { width: 48px; height: 48px; margin: 0 auto 12px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--text-2); }
.empty-state h3 { color: var(--text); margin-bottom: 6px; }
.empty-state p { max-width: 46ch; margin: 0 auto 14px; font-size: var(--fs-sm); }
.state-box { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: var(--r-md); border: 1px solid; font-size: var(--fs-sm); }
.state-box p { margin: 0; }
.state-box strong { display: block; margin-bottom: 2px; font-size: var(--fs-md); }
.state-error { background: var(--fail-soft); border-color: color-mix(in srgb, var(--fail) 35%, transparent); }
.state-error > .icon { color: var(--fail); }
.state-partial { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 35%, transparent); }
.state-partial > .icon { color: var(--warn); }
.state-success { background: var(--pass-soft); border-color: color-mix(in srgb, var(--pass) 35%, transparent); }
.state-success > .icon { color: var(--pass); }
.skeleton { background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-3) 37%, var(--surface-2) 63%); background-size: 400% 100%; animation: shimmer 1.3s ease infinite; border-radius: var(--r-sm); }
@keyframes shimmer { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
.progress-steps { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; font-size: var(--fs-sm); }
.progress-steps li { display: flex; align-items: center; gap: 10px; color: var(--muted); }
.progress-steps li[data-state="done"] { color: var(--text); }
.progress-steps li[data-state="done"] .ps-dot { background: var(--pass); border-color: var(--pass); }
.progress-steps li[data-state="active"] { color: var(--text); font-weight: 560; }
.progress-steps li[data-state="active"] .ps-dot { border-color: var(--accent); border-top-color: transparent; animation: spin .8s linear infinite; }
.ps-dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--border-strong); flex: none; }
.spinner { width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-top-color: transparent; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Bars / meters ---------- */
.bar-list { display: flex; flex-direction: column; gap: 8px; }
.bar-item { display: grid; grid-template-columns: minmax(70px, 170px) minmax(0, 1fr) 64px; gap: 10px; align-items: center; font-size: var(--fs-sm); }
.bar-item .bar-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-track { height: 10px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.bar-fill { height: 100%; border-radius: 99px; background: var(--accent); }
.bar-item .bar-val { text-align: right; font-family: var(--font-mono); font-size: 12px; color: var(--text-2); }
.history { display: flex; gap: 2px; align-items: stretch; height: 28px; }
.history i { flex: 1; min-width: 2px; border-radius: 2px; background: var(--pass); opacity: .85; }
.history i.h-warn { background: var(--warn); }
.history i.h-fail { background: var(--fail); }
.history i.h-none { background: var(--surface-3); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--bg-elev); margin-top: auto; }
.footer-inner { max-width: 1600px; margin: 0 auto; padding: var(--s-10) var(--s-6) var(--s-6); display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: var(--s-8); }
.footer-inner h2 { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: var(--s-3); }
.footer-inner ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; font-size: var(--fs-sm); }
.footer-inner a { color: var(--text-2); text-decoration: none; }
.footer-inner a:hover { color: var(--text); text-decoration: underline; }
.footer-base { max-width: 1600px; margin: 0 auto; padding: var(--s-4) var(--s-6) var(--s-6); display: flex; justify-content: space-between; gap: var(--s-4); flex-wrap: wrap; color: var(--muted); font-size: var(--fs-xs); border-top: 1px solid var(--border); }

/* ---------- Settings panel ---------- */
.settings-pop { position: absolute; right: 12px; top: calc(var(--header-h) - 4px); width: min(320px, calc(100vw - 24px)); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); padding: 14px; z-index: 70; }
.settings-pop h2 { font-size: var(--fs-sm); margin: 0 0 10px; }
.settings-pop .set-row { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.settings-pop .set-row .label { font-size: var(--fs-xs); color: var(--muted); font-weight: 560; }
.settings-pop .seg { display: flex; }
.settings-pop .seg button { flex: 1; justify-content: center; }

/* ---------- Mobile drawer ---------- */
.drawer { position: fixed; inset: 0; z-index: 90; display: none; }
.drawer.is-open { display: block; }
.drawer-scrim { position: absolute; inset: 0; background: var(--overlay); }
.drawer-panel { position: absolute; top: 0; bottom: 0; left: 0; width: min(320px, 86vw); background: var(--bg-elev); border-right: 1px solid var(--border); overflow-y: auto; padding: 14px; box-shadow: var(--shadow-lg); animation: drawer-in var(--t-med) var(--ease); }
@keyframes drawer-in { from { transform: translateX(-16px); opacity: 0; } to { transform: none; opacity: 1; } }
.drawer-panel .main-nav-m { display: flex; flex-direction: column; gap: 2px; margin: 12px 0 18px; }

/* ---------- Prose (guides) ---------- */
.prose { max-width: var(--prose-max); font-size: 1rem; line-height: 1.72; color: var(--text-2); }
.prose h2 { font-size: var(--fs-xl); color: var(--text); margin: var(--s-10) 0 var(--s-3); }
.prose h3 { font-size: var(--fs-lg); color: var(--text); margin: var(--s-6) 0 var(--s-2); }
.prose p, .prose ul, .prose ol { margin-bottom: var(--s-4); }
.prose li + li { margin-top: 6px; }
.prose strong { color: var(--text); }
.prose .code-block { margin: var(--s-4) 0 var(--s-5); }
.callout { display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--r-md); border: 1px solid var(--border); background: var(--surface); margin: var(--s-5) 0; font-size: var(--fs-md); }
.callout > .icon { margin-top: 3px; }
.callout p:last-child { margin: 0; }
.callout-warn { border-color: color-mix(in srgb, var(--warn) 35%, transparent); background: var(--warn-soft); }
.callout-warn > .icon { color: var(--warn); }
.callout-tip { border-color: color-mix(in srgb, var(--info) 35%, transparent); background: var(--info-soft); }
.callout-tip > .icon { color: var(--info); }
.toc { position: sticky; top: calc(var(--header-h) + 20px); font-size: var(--fs-sm); }
.toc h2 { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 8px; }
.toc ol { list-style: none; padding: 0; margin: 0; border-left: 1px solid var(--border); }
.toc a { display: block; padding: 5px 12px; margin-left: -1px; border-left: 2px solid transparent; color: var(--muted); text-decoration: none; line-height: 1.4; }
.toc a:hover { color: var(--text); }
.toc a[aria-current="true"] { color: var(--accent); border-left-color: var(--accent); font-weight: 560; }

/* ---------- Before/after ---------- */
.ba { border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--surface); overflow: hidden; }
.ba-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 12px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.ba-panes { display: grid; grid-template-columns: 1fr 1fr; }
.ba-pane { min-width: 0; }
.ba-pane + .ba-pane { border-left: 1px solid var(--border); }
.ba-pane-title { display: flex; justify-content: space-between; gap: 8px; padding: 8px 14px; font-size: var(--fs-xs); color: var(--muted); border-bottom: 1px solid var(--border); font-family: var(--font-mono); }
.ba-pane pre { margin: 0; padding: 12px 0; overflow: auto; font-size: 12.5px; line-height: 1.7; background: var(--code-bg); max-height: 360px; }
.ba-line { display: block; padding: 0 14px 0 0; white-space: pre; }
.ba-line .ln { display: inline-block; width: 36px; text-align: right; padding-right: 12px; color: var(--muted); user-select: none; }
.ba-line.del { background: var(--fail-soft); }
.ba-line.add { background: var(--pass-soft); }
.ba-line.del .mk::before { content: "-"; color: var(--fail); }
.ba-line.add .mk::before { content: "+"; color: var(--pass); }
.ba-line .mk { display: inline-block; width: 14px; font-weight: 700; }
.ba[data-view="unified"] .ba-panes { grid-template-columns: 1fr; }
.ba[data-view="unified"] .ba-pane + .ba-pane { border-left: 0; }

/* ---------- Unavailable demo link marker ---------- */
.is-demo-only { cursor: pointer; }
.demo-badge { font-size: 10.5px; font-family: var(--font-mono); color: var(--muted); border: 1px dashed var(--border-strong); border-radius: 99px; padding: 1px 7px; white-space: nowrap; }

/* ---------- Responsive ---------- */
@media (max-width: 1099px) {
  .main-nav { display: none; }
  .btn.nav-toggle { display: inline-flex; }
}
@media (max-width: 899px) {
  .app, html[data-sidebar="collapsed"] .app:not(.no-sidebar) { grid-template-columns: minmax(0, 1fr); }
  .sidebar { display: none; }
  .main { padding: var(--s-5) var(--s-4) var(--s-12); }
  .footer-inner { grid-template-columns: 1fr 1fr; padding: var(--s-8) var(--s-4) var(--s-4); }
  .footer-base { padding: var(--s-4); }
  .tool-list .tool-card { flex-wrap: wrap; }
  .tool-list .tool-card .tc-top { flex: 1 1 100%; }
  .tool-list .tool-card p { flex: 1 1 100%; order: 3; }
  .tool-list .tool-card .tc-meta { order: 4; }
  .ba-panes { grid-template-columns: 1fr; }
  .ba-pane + .ba-pane { border-left: 0; border-top: 1px solid var(--border); }
}
@media (max-width: 640px) {
  :root { --header-h: 56px; }
  html, html[data-density="compact"] { --control-h: 44px; --control-h-sm: 44px; }
  h1 { font-size: 1.75rem; }
  .search-trigger { width: auto; flex: 1; min-width: 0; }
  .search-trigger .kbd-hint { display: none; }
  .header-inner { gap: 6px; padding: 0 10px; }
  .brand-text { display: none; }
  .tool-head { flex-wrap: wrap; }
  .tool-head .tool-actions { margin-left: 0; width: 100%; }
  .footer-inner { grid-template-columns: 1fr; gap: var(--s-6); }
  .input-group { flex-direction: column; }
  .input-group .btn { width: 100%; }
  .bar-item { grid-template-columns: 90px minmax(0, 1fr) 54px; }
  .modal { margin-top: 6vh; }
  .palette { margin-top: 2vh; }
  .btn, .chip, .seg button, .link-btn, .drawer .side-link, .radio-card span, .check { min-height: 44px; }
  .btn-icon, .btn-icon.btn-sm, .fav-btn { min-width: 44px; }
  .search-trigger { min-height: 44px; }
  .btn.nav-toggle { width: auto; padding-inline: 8px; gap: 6px; }
  .nav-toggle-label { font-size: var(--fs-xs); }
  .tip-btn { width: 44px; height: 44px; }
}
@media (hover: none) { .tool-card:hover { box-shadow: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
@media print {
  .site-header, .sidebar, .recent-bar, .site-footer, .tool-actions, .ws-actions { display: none !important; }
  .app { display: block; }
}

/* ---------- Utilities added for shell ---------- */
ul.plain { list-style: none; padding: 0; margin: 0; }
:where(.link-reset) { background: none; border: 0; padding: 0; margin: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
button.side-link { width: 100%; }
button.recent-chip { font-size: var(--fs-xs); }
dialog.sheet-dialog { width: 100%; max-width: 100%; height: auto; max-height: 100vh; margin: 0; inset: 0 0 auto 0; overflow-y: auto; padding: 0 12px 24px; }
html[data-sidebar="collapsed"] .sidebar .label { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; display: inline; }
.drawer .side-link .label { position: static; width: auto; height: auto; clip: auto; }
h1, h2, h3 { overflow-wrap: break-word; }
@media (max-width: 640px) { .summary-strip > div:last-child:nth-child(odd) { grid-column: 1 / -1; } }
