/* Hearth — home & travel planner workspace. Scoped under .hh-app; the only root rule targets the mount
   (.uwapp-root + app class), never the body, which carries the app class too. Warm stone neutrals with a terracotta accent; light + dark themes. */
.uwapp-root.uwapp-hearth { min-height: 0; }

.hh-app {
  --hh-accent: #b3401b;
  --hh-accent-ink: #9a3412;
  --hh-accent-hover: #93330f;
  --hh-on-accent: #ffffff;
  --hh-accent-soft: #ffedd5;
  --hh-bg: #f5f3f0;
  --hh-panel: #ffffff;
  --hh-panel-2: #faf8f6;
  --hh-ink: #1c1917;
  --hh-ink-2: #44403c;
  --hh-muted: #57534e;
  --hh-line: #e7e5e4;
  --hh-line-2: #a8a29e;
  --hh-control: #78716c;
  --hh-focus: #1d4ed8;
  --hh-good-bg: #dcfce7; --hh-good-ink: #14532d;
  --hh-warn-bg: #fef3c7; --hh-warn-ink: #78350f; --hh-warn-text: #92400e;
  --hh-info-bg: #e0f2fe; --hh-info-ink: #0c4a6e;
  --hh-bad: #b91c1c;
  --hh-ok: #15803d;
  --hh-shadow: 0 10px 30px rgba(28, 25, 23, .14);
  --hh-nav-w: 214px;
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: var(--hh-bg);
  color: var(--hh-ink);
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.45;
  overflow: hidden;
}
.hh-app[data-theme='dark'] {
  --hh-accent: #fb923c;
  --hh-accent-ink: #fdba74;
  --hh-accent-hover: #fdba74;
  --hh-on-accent: #1c1917;
  --hh-accent-soft: #431407;
  --hh-bg: #0c0a09;
  --hh-panel: #1c1917;
  --hh-panel-2: #171412;
  --hh-ink: #f5f5f4;
  --hh-ink-2: #e7e5e4;
  --hh-muted: #c4bfbb;
  --hh-line: #353130;
  --hh-line-2: #78716c;
  --hh-control: #a8a29e;
  --hh-focus: #93c5fd;
  --hh-good-bg: #052e16; --hh-good-ink: #bbf7d0;
  --hh-warn-bg: #422006; --hh-warn-ink: #fde68a; --hh-warn-text: #fcd34d;
  --hh-info-bg: #082f49; --hh-info-ink: #bae6fd;
  --hh-bad: #fca5a5;
  --hh-ok: #86efac;
  --hh-shadow: 0 10px 30px rgba(0, 0, 0, .55);
  color-scheme: dark;
}

/* Platform element defaults (buttons, tables, links) leak into the workspace: reset them inside the app. */
.hh-app button { font: inherit; font-size: 14px; font-weight: 600; padding: 0; border: 0; border-radius: 8px; background: none; color: inherit; cursor: pointer; width: auto; min-height: 0; }
.hh-app button:hover { background: none; }
.hh-app button:disabled { cursor: not-allowed; opacity: .55; }
.hh-app a { color: var(--hh-accent-ink); }
.hh-app :is(input, select, textarea) { font: inherit; color: inherit; }
.hh-app h1, .hh-app h2, .hh-app h3, .hh-app h4 { margin: 0; line-height: 1.25; color: var(--hh-ink); }
.hh-app p { margin: 0; }
.hh-app table { border-collapse: collapse; width: 100%; margin: 0; font-size: 13.5px; }
.hh-app :is(th, td) { text-align: start; vertical-align: top; padding: 7px 10px; border-bottom: 1px solid var(--hh-line); }
.hh-app thead th { background: var(--hh-panel-2); color: var(--hh-ink-2); font-weight: 650; white-space: nowrap; }
.hh-app kbd { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; padding: 1px 6px; border: 1px solid var(--hh-line-2); border-bottom-width: 2px; border-radius: 5px; background: var(--hh-panel-2); color: var(--hh-ink); }
.hh-app code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; background: var(--hh-panel-2); color: var(--hh-ink); padding: 0 4px; border-radius: 4px; }
.hh-app :focus-visible { outline: 3px solid var(--hh-focus); outline-offset: 2px; }
.hh-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
.hh-app [hidden] { display: none !important; }
.hh-ico { flex: none; }

/* ---------------------------------------------------------------- top bar */
.hh-top { display: flex; align-items: center; gap: 6px; padding: 6px 10px; background: var(--hh-panel); border-bottom: 1px solid var(--hh-line); min-width: 0; flex: none; }
.hh-menubar { display: flex; gap: 2px; flex: none; }
.hh-menuwrap { position: relative; }
.hh-app .hh-menubtn { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 4px 10px; border-radius: 7px; font-weight: 600; color: var(--hh-ink); white-space: nowrap; }
.hh-app .hh-menubtn:hover, .hh-app .hh-menubtn[aria-expanded='true'] { background: var(--hh-panel-2); box-shadow: inset 0 0 0 1px var(--hh-line); }
.hh-compact-menu { display: none; }
.hh-top.hh-compact .hh-menubar { display: none; }
.hh-top.hh-compact .hh-compact-menu { display: block; }
.hh-name { flex: 0 1 260px; min-width: 70px; height: 34px; padding: 4px 10px; border: 1px solid transparent; border-radius: 7px; background: transparent; color: var(--hh-ink); font-weight: 700; font-size: 15px; text-overflow: ellipsis; }
.hh-name:hover { border-color: var(--hh-line); }
.hh-name:focus { border-color: var(--hh-control); background: var(--hh-panel); }
.hh-grow { flex: 1 1 0; min-width: 0; }
.hh-app .hh-ibtn { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; min-height: 34px; padding: 4px; border-radius: 7px; color: var(--hh-ink); flex: none; }
.hh-app .hh-ibtn:hover:not(:disabled) { background: var(--hh-panel-2); box-shadow: inset 0 0 0 1px var(--hh-line); }

.hh-menu { position: absolute; z-index: 60; inset-block-start: calc(100% + 4px); inset-inline-start: 0; min-width: 250px; max-height: min(70vh, 560px); overflow-y: auto; padding: 5px; background: var(--hh-panel); border: 1px solid var(--hh-line); border-radius: 10px; box-shadow: var(--hh-shadow); }
.hh-app .hh-menu-item { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 32px; padding: 5px 9px; border-radius: 6px; text-align: start; font-weight: 500; color: var(--hh-ink); }
.hh-app .hh-menu-item:hover:not(:disabled), .hh-app .hh-menu-item:focus { background: var(--hh-accent-soft); outline: none; }
.hh-app .hh-menu-item:focus-visible { outline: 2px solid var(--hh-focus); outline-offset: -2px; }
.hh-menu-ico { display: inline-flex; width: 16px; justify-content: center; color: var(--hh-muted); }
.hh-menu-label { flex: 1; }
.hh-menu-key { color: var(--hh-muted); font-size: 12px; white-space: nowrap; }
.hh-menu-sep { height: 1px; margin: 5px 4px; background: var(--hh-line); }
.hh-menu-heading { padding: 6px 9px 2px; font-size: 12px; font-weight: 700; color: var(--hh-muted); text-transform: uppercase; letter-spacing: .04em; }

/* ---------------------------------------------------------------- buttons */
.hh-app .hh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 34px; padding: 6px 13px; border-radius: 8px; border: 1px solid var(--hh-line-2); background: var(--hh-panel); color: var(--hh-ink); font-weight: 600; white-space: nowrap; max-width: 100%; }
@media (max-width: 760px) { .hh-app .hh-btn { white-space: normal; text-align: start; } }
.hh-app .hh-btn:hover:not(:disabled) { border-color: var(--hh-accent); background: var(--hh-accent-soft); }
.hh-app .hh-btn-primary { background: var(--hh-accent); border-color: var(--hh-accent); color: var(--hh-on-accent); }
.hh-app .hh-btn-primary:hover:not(:disabled) { background: var(--hh-accent-hover); border-color: var(--hh-accent-hover); color: var(--hh-on-accent); }
.hh-app .hh-btn-ghost { border-color: var(--hh-line); background: transparent; }
.hh-app .hh-btn-danger { background: var(--hh-bad); border-color: var(--hh-bad); color: #fff; }
.hh-app[data-theme='dark'] .hh-btn-danger { color: #1c1917; }
.hh-app .hh-btn-link { border: 0; background: none; padding: 2px 0; min-height: 24px; color: var(--hh-accent-ink); text-decoration: underline; text-underline-offset: 2px; }
.hh-app .hh-btn-link:hover:not(:disabled) { background: none; color: var(--hh-ink); }

/* ---------------------------------------------------------------- hint, body, nav, main */
.hh-hint { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 14px; background: var(--hh-info-bg); color: var(--hh-info-ink); border-bottom: 1px solid var(--hh-line); flex: none; }
.hh-hint p { flex: 1 1 280px; }
.hh-body { flex: 1 1 auto; min-height: 0; display: grid; grid-template-columns: var(--hh-nav-w) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
.hh-nav { background: var(--hh-panel); border-inline-end: 1px solid var(--hh-line); overflow-y: auto; padding: 10px 8px; min-height: 0; }
.hh-nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.hh-app .hh-navbtn { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 38px; padding: 7px 10px; border-radius: 8px; color: var(--hh-ink-2); font-weight: 600; text-align: start; position: relative; }
.hh-app .hh-navbtn:hover { background: var(--hh-panel-2); color: var(--hh-ink); }
.hh-app .hh-navbtn[aria-current='page'] { background: var(--hh-accent-soft); color: var(--hh-accent-ink); box-shadow: inset 3px 0 0 var(--hh-accent); }
[dir='rtl'] .hh-app .hh-navbtn[aria-current='page'], .hh-app[dir='rtl'] .hh-navbtn[aria-current='page'] { box-shadow: inset -3px 0 0 var(--hh-accent); }
.hh-navlabel { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.hh-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--hh-accent); flex: none; }
.hh-app .hh-main:focus { outline: none; }
.hh-main { min-height: 0; overflow-y: auto; padding: 18px clamp(12px, 2.4vw, 30px) 40px; outline: none; scroll-padding-top: 12px; }
.hh-section { max-width: 1180px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.hh-sechead { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; }
.hh-sechead h2 { font-size: 22px; font-weight: 800; letter-spacing: -.01em; }
.hh-lede { margin-top: 4px; max-width: 78ch; color: var(--hh-muted); }
.hh-sechead-acts { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------------------------------------------------------------- cards, fields */
.hh-card { background: var(--hh-panel); border: 1px solid var(--hh-line); border-radius: 12px; padding: 14px 16px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; min-width: 0; align-content: start; }
.hh-card-run { border-inline-start: 4px solid var(--hh-accent); }
.hh-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; flex-wrap: wrap; }
.hh-card h3 { font-size: 16px; font-weight: 750; }
.hh-card h4 { font-size: 14px; font-weight: 700; color: var(--hh-ink-2); }
.hh-card-acts { display: flex; gap: 6px; flex-wrap: wrap; }
.hh-card-lede { color: var(--hh-muted); margin-top: -6px; }
.hh-results { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.hh-form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); gap: 10px 14px; align-items: start; }
.hh-two { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 12px 16px; }
.hh-field { display: grid; gap: 4px; min-width: 0; }
.hh-field > label, .hh-label { font-weight: 600; font-size: 13px; color: var(--hh-ink-2); }
.hh-field-check { align-self: center; }
.hh-help { font-size: 12.5px; color: var(--hh-muted); }
.hh-app .hh-input { width: 100%; min-height: 34px; padding: 5px 8px; border: 1px solid var(--hh-control); border-radius: 7px; background: var(--hh-panel); color: var(--hh-ink); min-width: 0; }
.hh-app select.hh-input { padding-inline-end: 4px; }
.hh-app .hh-input:focus { border-color: var(--hh-focus); }
.hh-sharebox { font-family: ui-monospace, monospace; font-size: 12px; word-break: break-all; }
.hh-checks { border: 1px solid var(--hh-line); border-radius: 10px; padding: 8px 12px 10px; margin: 0; display: flex; flex-wrap: wrap; gap: 4px 16px; min-width: 0; }
.hh-checks legend { padding: 0 4px; font-weight: 650; font-size: 13px; color: var(--hh-ink-2); }
.hh-check { display: inline-flex; align-items: center; gap: 7px; min-height: 28px; cursor: pointer; }
.hh-check input, .hh-td-check input { width: 18px; height: 18px; accent-color: var(--hh-accent); flex: none; margin: 0; }
.hh-scenario { border: 1px solid var(--hh-line); border-radius: 10px; padding: 8px 12px 12px; margin: 0; display: grid; gap: 8px; min-width: 0; }
.hh-scenario legend { font-weight: 750; padding: 0 4px; }
.hh-picker { display: flex; align-items: flex-end; gap: 8px; flex-wrap: wrap; }
.hh-picker .hh-field { min-width: 220px; }
.hh-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------------------------------------------------------------- editable grid + tables */
.hh-gridbox { display: grid; gap: 8px; min-width: 0; }
.hh-gridwrap, .hh-tablewrap { position: relative; overflow-x: auto; border: 1px solid var(--hh-line); border-radius: 10px; background: var(--hh-panel); max-width: 100%; }
.hh-grid td { padding: 4px 5px; vertical-align: middle; }
.hh-grid th { padding: 7px 6px; font-size: 12.5px; }
.hh-grid tr:last-child td { border-bottom: 0; }
.hh-grid .hh-input { min-height: 32px; }
.hh-grid .hh-num { width: 6.5em; }
.hh-w-s { min-width: 90px; } .hh-w-m { min-width: 150px; } .hh-w-l { min-width: 210px; } .hh-w-xl { min-width: 340px; } .hh-w-act, .hh-w-fit { width: 1%; }
.hh-grid .hh-w-fit { white-space: normal; min-width: 5.5em; }
.hh-td-check { text-align: center; }
.hh-row-acts { white-space: nowrap; width: 1%; }
.hh-app .hh-row-acts .hh-ibtn { min-width: 28px; min-height: 28px; color: var(--hh-muted); }
.hh-gridfoot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.hh-empty, .hh-muted { color: var(--hh-muted); }
.hh-table tbody tr:nth-child(even) { background: var(--hh-panel-2); }
.hh-table tbody tr:last-child > * { border-bottom: 0; }
.hh-table tbody th { font-weight: 650; }
.hh-caption { font-weight: 700; padding: 8px 10px 4px; text-align: start; caption-side: top; color: var(--hh-ink); }
.hh-numc { text-align: end !important; font-variant-numeric: tabular-nums; white-space: nowrap; }
.hh-matrix td { white-space: nowrap; }
.hh-ok { color: var(--hh-ok); font-weight: 650; }
.hh-bad { color: var(--hh-bad); font-weight: 650; }

/* ---------------------------------------------------------------- run blocks, notes, badges, metrics */
.hh-run { display: grid; gap: 8px; }
.hh-run-row { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; }
.hh-run-status { display: grid; gap: 1px; flex: 1 1 260px; }
.hh-run-status > span:first-child { font-weight: 600; }
.hh-run-tools { font-size: 12.5px; color: var(--hh-muted); }
.hh-tone-warn.hh-run-status > span:first-child { color: var(--hh-warn-ink); }
.hh-app[data-theme='light'] .hh-tone-warn.hh-run-status > span:first-child { color: #92400e; }
.hh-summary { padding: 8px 12px; border-radius: 8px; background: var(--hh-panel-2); border: 1px solid var(--hh-line); color: var(--hh-ink-2); }
.hh-note { display: flex; gap: 8px; align-items: flex-start; padding: 8px 12px; border-radius: 8px; }
.hh-note .hh-ico { margin-top: 2px; }
.hh-note.hh-tone-warn, .hh-badge.hh-tone-warn { background: var(--hh-warn-bg); color: var(--hh-warn-ink); }
.hh-note.hh-tone-good, .hh-badge.hh-tone-good { background: var(--hh-good-bg); color: var(--hh-good-ink); }
.hh-note.hh-tone-info, .hh-badge.hh-tone-info { background: var(--hh-info-bg); color: var(--hh-info-ink); }
.hh-badge { display: inline-block; padding: 1px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.hh-warnings { margin: 0; padding: 8px 12px 8px 30px; border-radius: 8px; background: var(--hh-warn-bg); color: var(--hh-warn-ink); font-size: 13px; }
[dir='rtl'] .hh-warnings { padding: 8px 30px 8px 12px; }
.hh-errlist { margin: 0; font-size: 13px; }
.hh-metrics { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 10px; margin: 0; }
.hh-metric { background: var(--hh-panel); border: 1px solid var(--hh-line); border-radius: 10px; padding: 10px 12px; min-width: 0; }
.hh-card .hh-metric { background: var(--hh-panel-2); }
.hh-metric dt { font-size: 12.5px; color: var(--hh-muted); font-weight: 600; }
.hh-metric dd { margin: 2px 0 0; font-size: 19px; font-weight: 800; overflow-wrap: anywhere; }
.hh-metric:has(.hh-metric-text) { grid-column: span 2; }
@media (max-width: 420px) { .hh-metric:has(.hh-metric-text) { grid-column: auto; } }
.hh-metric dd.hh-metric-text { font-size: 15px; font-weight: 750; }
.hh-metric.hh-tone-warn dd:first-of-type { color: var(--hh-warn-text); }
.hh-metric dd.hh-metric-sub { font-size: 12.5px; font-weight: 500; color: var(--hh-muted); }
.hh-metric.hh-tone-good { border-color: color-mix(in srgb, var(--hh-ok) 45%, var(--hh-line)); }
.hh-metric.hh-tone-warn { border-color: color-mix(in srgb, #d97706 55%, var(--hh-line)); }
.hh-details summary { cursor: pointer; font-weight: 600; color: var(--hh-accent-ink); padding: 4px 0; min-height: 24px; }
.hh-details[open] summary { margin-bottom: 8px; }
.hh-chartbox { position: relative; overflow-x: auto; }
.hh-chart, .hh-plan { display: block; max-width: 100%; height: auto; }
.hh-planbox { position: relative; overflow: auto; padding: 4px; background: var(--hh-panel-2); border: 1px solid var(--hh-line); border-radius: 10px; }
.hh-planbox .hh-plan { margin: 0 auto; }
.hh-plainlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.hh-plainlist li { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.hh-tips li { display: block; }

/* checklists (shopping, emergency kit) */
.hh-checklist { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 2px 16px; }
.hh-checklist li.hh-done .hh-check span { text-decoration: line-through; color: var(--hh-muted); }
.hh-checkgroups { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 12px 20px; }
.hh-checkgroups h4 { margin-bottom: 4px; }
.hh-checkgroups .hh-checklist { grid-template-columns: 1fr; }

/* findings, agenda, steps */
.hh-findings { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.hh-findings li { display: flex; gap: 8px; align-items: flex-start; padding: 7px 10px; border-radius: 8px; }
.hh-findings li .hh-ico { margin-top: 2px; }
.hh-findings li.hh-tone-warn { background: var(--hh-warn-bg); color: var(--hh-warn-ink); }
.hh-findings li.hh-tone-good { background: var(--hh-good-bg); color: var(--hh-good-ink); }
.hh-findings li.hh-tone-info { background: var(--hh-info-bg); color: var(--hh-info-ink); }
.hh-dash { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.hh-span2 { grid-column: 1 / -1; }
.hh-findgroups { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 12px 18px; }
.hh-findgroup { display: grid; gap: 6px; align-content: start; }
.hh-agenda { position: relative; max-height: 460px; overflow-y: auto; display: grid; gap: 4px; padding-inline-end: 4px; }
.hh-agenda-day { margin-top: 6px; font-size: 13px; color: var(--hh-accent-ink); position: sticky; top: 0; background: var(--hh-panel); padding: 3px 0; }
.hh-agenda ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
.hh-ev { display: flex; gap: 8px; align-items: baseline; padding: 3px 0 3px 2px; border-bottom: 1px dashed var(--hh-line); }
.hh-ev-kind { flex: none; min-width: 7.5em; font-size: 12px; font-weight: 700; color: var(--hh-muted); }
.hh-ev-time { flex: none; font-variant-numeric: tabular-nums; font-weight: 650; }
.hh-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.hh-steps li { display: flex; align-items: center; gap: 10px; padding: 4px 0; border-bottom: 1px solid var(--hh-line); }
.hh-steps li .hh-badge { min-width: 7.5em; text-align: center; }
.hh-step-name { flex: 1; min-width: 0; overflow-wrap: anywhere; }

/* ---------------------------------------------------------------- report */
.hh-report { background: var(--hh-panel); border: 1px solid var(--hh-line); border-radius: 12px; padding: 22px clamp(14px, 3vw, 34px); display: grid; gap: 16px; }
.hh-report-title { font-size: 21px; font-weight: 800; }
.hh-report-part { display: grid; gap: 10px; border-top: 1px solid var(--hh-line); padding-top: 14px; }
.hh-report-part > h4 { font-size: 17px; color: var(--hh-accent-ink); }
.hh-report-plan { margin: 0; display: grid; gap: 4px; justify-items: start; }
.hh-report-plan figcaption { font-weight: 600; }
.hh-report-foot { color: var(--hh-muted); font-size: 12.5px; }

/* ---------------------------------------------------------------- status bar, toasts */
.hh-status { display: flex; align-items: center; gap: 14px; padding: 4px 12px; min-height: 30px; background: var(--hh-panel); border-top: 1px solid var(--hh-line); color: var(--hh-muted); font-size: 12.5px; flex: none; flex-wrap: wrap; }
.hh-saveinfo, .hh-netinfo { display: inline-flex; align-items: center; gap: 6px; }
.hh-progress-wrap { flex: 1; display: inline-flex; align-items: center; gap: 10px; justify-content: center; min-width: 0; }
.hh-progress { color: var(--hh-ink-2); font-weight: 600; overflow-wrap: anywhere; }
.hh-app .hh-cancel { min-height: 24px; padding: 1px 10px; }
.hh-on, .hh-off { width: 8px; height: 8px; border-radius: 50%; background: #16a34a; display: inline-block; }
.hh-off { background: #d97706; }
.hh-toasts { position: fixed; z-index: 90; inset-block-end: 44px; inset-inline-end: 16px; display: grid; gap: 8px; max-width: min(440px, calc(100vw - 32px)); }
.hh-toast { display: flex; gap: 8px; align-items: flex-start; padding: 10px 14px; border-radius: 10px; background: var(--hh-panel); color: var(--hh-ink); border: 1px solid var(--hh-line); box-shadow: var(--hh-shadow); }
.hh-toast-good { border-inline-start: 4px solid var(--hh-ok); }
.hh-toast-error { border-inline-start: 4px solid var(--hh-bad); }
.hh-toast .hh-ico { margin-top: 2px; }

/* ---------------------------------------------------------------- dialogs */
.hh-dialog { width: min(560px, calc(100vw - 24px)); max-height: calc(100dvh - 32px); padding: 0; border: 1px solid var(--hh-line); border-radius: 14px; background: var(--hh-panel); color: var(--hh-ink); box-shadow: var(--hh-shadow); display: none; }
.hh-dialog[open] { display: grid; grid-template-rows: auto auto minmax(0, 1fr) auto; grid-template-columns: minmax(0, 1fr); }
.hh-dialog-wide { width: min(860px, calc(100vw - 24px)); }
.hh-dialog::backdrop { background: rgba(12, 10, 9, .5); }
.hh-dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px 8px 18px; }
.hh-dialog-head h2 { font-size: 18px; font-weight: 800; }
.hh-dialog-lede { padding: 0 18px; color: var(--hh-muted); }
.hh-dialog-body { padding: 6px 18px 12px; overflow-y: auto; display: grid; gap: 12px; align-content: start; }
.hh-dialog-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 10px 14px 14px; border-top: 1px solid var(--hh-line); flex-wrap: wrap; }
.hh-tpls { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: 10px; }
.hh-app .hh-tpl { display: grid; gap: 4px; width: 100%; height: 100%; text-align: start; padding: 12px 14px; border: 1px solid var(--hh-line); border-radius: 10px; background: var(--hh-panel-2); font-weight: 500; color: var(--hh-ink); align-content: start; }
.hh-app .hh-tpl:hover { border-color: var(--hh-accent); background: var(--hh-accent-soft); }
.hh-tpl strong { font-size: 15px; color: var(--hh-accent-ink); }
.hh-tpl span { color: var(--hh-ink-2); font-size: 13px; }
.hh-recent { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.hh-recent li { display: flex; align-items: center; gap: 6px; }
.hh-app .hh-recent-open { flex: 1; display: grid; text-align: start; padding: 8px 12px; border: 1px solid var(--hh-line); border-radius: 8px; font-weight: 500; }
.hh-app .hh-recent-open:hover { border-color: var(--hh-accent); background: var(--hh-accent-soft); }
.hh-shortcut-toggle { padding-top: 6px; }
.hh-print { display: none; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1100px) { .hh-app { --hh-nav-w: 64px; } .hh-navlabel { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; } .hh-app .hh-navbtn { justify-content: center; padding: 8px; } .hh-dash { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) {
  .hh-body { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .hh-nav { border-inline-end: 0; border-bottom: 1px solid var(--hh-line); padding: 4px 6px; overflow-x: auto; overflow-y: hidden; }
  .hh-nav ul { display: flex; gap: 2px; width: max-content; }
  .hh-app .hh-navbtn { min-height: 40px; padding: 6px 10px; }
  .hh-navlabel { position: static; width: auto; height: auto; overflow: visible; clip-path: none; }
  .hh-app .hh-navbtn[aria-current='page'] { box-shadow: inset 0 -3px 0 var(--hh-accent); }
  .hh-app[dir='rtl'] .hh-navbtn[aria-current='page'] { box-shadow: inset 0 -3px 0 var(--hh-accent); }
  .hh-main { padding: 12px 10px 30px; }
  .hh-sechead h2 { font-size: 19px; }
  .hh-runall span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .hh-status { gap: 6px 10px; }
  .hh-progress-wrap { order: -1; flex-basis: 100%; justify-content: flex-start; }
  .hh-card { padding: 12px; }
  .hh-ev-kind { min-width: 6em; }
}
@media (prefers-reduced-motion: reduce) { .hh-app * { transition: none !important; animation: none !important; scroll-behavior: auto !important; } }

/* ---------------------------------------------------------------- print: only the report */
@media print {
  .uwapp-body > *:not(.hh-print) { display: none !important; }
  .uwapp-body { display: block; background: #fff; }
  .hh-print { display: block !important; color: #000; font-family: system-ui, sans-serif; font-size: 11pt; }
  .hh-print .hh-report { border: 0; padding: 0; display: block; }
  .hh-print .hh-report-part { break-inside: auto; margin-top: 14pt; padding-top: 8pt; border-top: 1px solid #ccc; }
  .hh-print table { border-collapse: collapse; width: 100%; margin: 4pt 0 10pt; font-size: 9.5pt; }
  .hh-print :is(th, td) { border-bottom: 1px solid #ddd; padding: 3pt 5pt; text-align: start; vertical-align: top; }
  .hh-print thead th { background: #f3f3f3; }
  .hh-print .hh-findings { list-style: none; padding: 0; margin: 4pt 0; }
  .hh-print .hh-findings li { display: flex; gap: 6pt; padding: 2pt 0; }
  .hh-print .hh-sr { position: static !important; width: auto; height: auto; clip: auto; clip-path: none; margin: 0; overflow: visible; }
  .hh-print caption.hh-caption { text-align: start; font-weight: 700; padding: 4pt 0; }
  .hh-print .hh-report-plan { break-inside: avoid; }
  .hh-print .hh-tablewrap { overflow: visible; border: 0; }
}
.hh-nowrap { white-space: nowrap; }
