/* site.css: TheAdminStack page layer on Frosted Aura (redesign Phase 1).
   Load order: fa-tokens.css → [legacy style.css / theme-v2.css on unmigrated pages] →
   fa-components.css → site.css.
   Phase 1 scope: the shared chrome only (header, nav, mobile menu, footer, skip link).
   Every rule is scoped to .tas-* and uses px, because legacy stylesheets set different
   root font sizes (15px in GRC, 16px elsewhere) and global element resets. */

/* ---------- Skip link ---------- */
.tas-skip {
  position: absolute; left: 12px; top: -100px; z-index: 1000;
  background: var(--surface-raised); color: var(--brand-strong);
  font: 600 14px/20px var(--font-text); padding: 10px 14px;
  border: 1px solid var(--line); border-radius: var(--radius-md); text-decoration: none;
}
.tas-skip:focus { top: calc(12px + env(safe-area-inset-top, 0px)); outline: 2px solid var(--focus); outline-offset: 2px; }
#tas-content { position: relative; top: -64px; height: 0; outline: none; }

/* ---------- Header ---------- */
.tas-hdr {
  position: fixed; top: 0; left: 0; right: 0; z-index: 900;
  padding-top: env(safe-area-inset-top, 0px);
  background: var(--frost);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
  font-family: var(--font-text); font-size: 14px; line-height: 20px; color: var(--ink);
  transition: box-shadow var(--dur-fast) var(--ease-standard);
}
.tas-hdr.is-scrolled { box-shadow: var(--shadow-sm); }
.tas-hdr__in {
  box-sizing: border-box; max-width: 1200px; height: 64px; margin: 0 auto;
  display: flex; align-items: center; gap: 24px;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}
/* theme-v2.css styles "header nav" as a second frosted bar; cancel it inside our header. */
.tas-hdr .tas-nav { background: none; -webkit-backdrop-filter: none; backdrop-filter: none; border: 0; box-shadow: none; }

.tas-ic { display: inline-block; width: 20px; height: 20px; flex: none; vertical-align: middle; }
.tas-ic--sm { width: 16px; height: 16px; }

/* Brand */
.tas-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); flex: none; }
.tas-brand:hover { color: var(--ink); text-decoration: none; }
.tas-brand__mark { display: block; width: 28px; height: 28px; color: var(--brand); flex: none; }
.tas-brand__txt { display: flex; flex-direction: column; }
.tas-brand__name { font: 600 18px/20px var(--font-display); letter-spacing: -0.01em; color: var(--ink); }
.tas-brand__tag { font: 500 10.5px/14px var(--font-mono); letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-muted); margin-top: 2px; }

/* Main nav */
.tas-nav { flex: 1; min-width: 0; }
.tas-nav ul { display: flex; gap: 20px; list-style: none; margin: 0; padding: 0; }
.tas-nav a {
  display: block; padding: 6px 0; border-bottom: 2px solid transparent;
  font: 600 14px/20px var(--font-text); color: var(--ink-secondary); text-decoration: none;
}
.tas-nav a:hover { color: var(--ink); text-decoration: none; }
.tas-nav a[aria-current="page"] { color: var(--brand-strong); border-bottom-color: var(--brand); }

/* Actions */
.tas-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; flex: none; }
.tas-find {
  display: inline-flex; align-items: center; gap: 8px; height: 36px; box-sizing: border-box;
  padding: 0 12px 0 10px; border: 1px solid var(--control-border); border-radius: var(--radius-pill);
  font: 600 14px/20px var(--font-text); color: var(--ink-secondary); text-decoration: none; background: transparent;
}
.tas-find:hover { color: var(--ink); background: var(--surface-sunken); text-decoration: none; }
.tas-find kbd {
  font: 500 11px/16px var(--font-mono); color: var(--ink-secondary);
  border: 1px solid var(--line-strong); border-radius: 4px; padding: 0 5px; background: none;
}
.tas-iconbtn {
  display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px;
  padding: 0; margin: 0; border: 1px solid transparent; border-radius: var(--radius-pill);
  background: transparent; color: var(--ink-secondary); cursor: pointer;
}
.tas-iconbtn:hover { color: var(--ink); background: var(--surface-sunken); }
.tas-ic--sun { display: none; }
:root[data-theme="dark"] .tas-ic--sun { display: inline-block; }
:root[data-theme="dark"] .tas-ic--moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .tas-ic--sun { display: inline-block; }
  :root:not([data-theme="light"]) .tas-ic--moon { display: none; }
}
.tas-cta { flex: none; }
a.fa-btn { text-decoration: none; }
/* Without JS: no dead buttons; on small screens the menu panel is simply shown. */
html:not(.tas-js) [data-tas-theme], html:not(.tas-js) .tas-menubtn { display: none; }
.tas-menubtn { display: none; }

.tas-hdr a:focus-visible, .tas-hdr button:focus-visible,
.tas-ftr a:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

/* Mobile menu */
.tas-mnav {
  border-top: 1px solid var(--line); background: var(--surface-raised);
  padding: 4px max(20px, env(safe-area-inset-right, 0px)) 12px max(20px, env(safe-area-inset-left, 0px));
  box-shadow: var(--shadow-card);
}
.tas-mnav[hidden] { display: none; }
.tas-mnav a {
  display: block; padding: 12px 0; border-bottom: 1px solid var(--line);
  font: 600 16px/24px var(--font-text); color: var(--ink); text-decoration: none;
}
.tas-mnav a:last-child { border-bottom: 0; color: var(--brand-strong); }
.tas-mnav a[aria-current="page"] { color: var(--brand-strong); }

@media (max-width: 860px) {
  .tas-nav, .tas-cta, .tas-find__lbl, .tas-find kbd { display: none; }
  .tas-find { width: 36px; padding: 0; justify-content: center; }
  .tas-menubtn { display: inline-flex; }
  html:not(.tas-js) .tas-mnav[hidden] { display: block; }
  .tas-hdr__in { gap: 12px; }
}
@media (max-width: 420px) { .tas-brand__tag { display: none; } }

/* ---------- Footer ---------- */
.tas-ftr {
  background: var(--surface-raised); border-top: 1px solid var(--line);
  font-family: var(--font-text); font-size: 14px; line-height: 20px; color: var(--ink-secondary);
  padding: 48px 0 calc(32px + env(safe-area-inset-bottom, 0px));
}
.tas-ftr__in {
  box-sizing: border-box; max-width: 1200px; margin: 0 auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}
.tas-ftr__grid { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 32px; }
.tas-ftr h2 {
  margin: 0 0 12px; font: 500 12px/16px var(--font-mono); letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--ink-muted);
}
.tas-ftr ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.tas-ftr a { color: var(--ink-secondary); text-decoration: none; font-size: 14px; }
.tas-ftr a:hover { color: var(--brand-strong); text-decoration: underline; text-underline-offset: 3px; }
.tas-ftr__brand p { margin: 12px 0 0; max-width: 34ch; font-size: 14px; line-height: 21px; color: var(--ink-muted); }
.tas-ftr__brand .tas-brand__name { font-size: 17px; }
.tas-ftr .tas-ftr__social { display: flex; gap: 8px; margin-top: 16px; }
.tas-ftr__social a {
  display: inline-block; padding: 4px 12px; border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill); font-size: 13px; color: var(--ink-secondary);
}
.tas-ftr__social a:hover { text-decoration: none; border-color: var(--brand); color: var(--brand-strong); }
.tas-ftr__base {
  margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--line);
  font: 400 12px/16px var(--font-text); color: var(--ink-muted);
}
@media (max-width: 760px) {
  .tas-ftr__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .tas-ftr__brand { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  .tas-hdr { transition: none; }
}

/* =====================================================================
   Phase 2: migrated-page base (body.tas-page) + homepage.
   Migrated pages load no legacy CSS, so everything they need is here.
   ===================================================================== */
body.tas-page {
  margin: 0; background: var(--surface-canvas); color: var(--ink);
  font: 400 17px/26px var(--font-text); letter-spacing: -0.006em;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
:where(.tas-page) *, :where(.tas-page) *::before, :where(.tas-page) *::after { box-sizing: border-box; }
.tas-page main { display: block; padding-top: calc(64px + env(safe-area-inset-top, 0px)); }
:where(.tas-page) :where(h1, h2, h3) { margin: 0; font-family: var(--font-display); font-weight: 600; color: var(--ink); text-wrap: balance; }
:where(.tas-page) p { margin: 0; }
/* Base element rules use :where() (zero specificity) so any component class wins. */
:where(.tas-page) a { color: var(--brand-strong); }
.tas-page [hidden]:not(.tas-mnav) { display: none !important; }
:where(.tas-page) :where(img, svg) { max-width: 100%; }
.tas-page :focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
:where(.tas-page) ::selection { background: var(--brand-soft); color: var(--ink); }
.vh { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Layout + type utilities */
.tas-wrap { max-width: 1200px; margin: 0 auto; padding-left: max(20px, env(safe-area-inset-left, 0px)); padding-right: max(20px, env(safe-area-inset-right, 0px)); }
@media (min-width: 720px) { .tas-wrap { padding-left: max(32px, env(safe-area-inset-left, 0px)); padding-right: max(32px, env(safe-area-inset-right, 0px)); } }
.tas-section { padding-block: 64px; }
.tas-section + .tas-section { border-top: 1px solid var(--line); }
.tas-band { background: var(--surface-wash); border-block: 1px solid var(--line); }
.tas-overline { font: 500 12px/16px var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-muted); }
.tas-display { font-size: clamp(36px, 5.2vw, 56px); line-height: 1.07; letter-spacing: -0.02em; margin-top: 16px; }
.tas-quiet { color: var(--ink-muted); }
.tas-h2 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.1; letter-spacing: -0.018em; margin-top: 12px; }
.tas-lede { font-size: 19px; line-height: 28px; color: var(--ink-secondary); max-width: 58ch; margin-top: 20px; }
.tas-body { color: var(--ink-secondary); }
.tas-small { font-size: 14px; line-height: 21px; color: var(--ink-muted); }
.tas-cap { font-size: 12px; line-height: 16px; color: var(--ink-muted); }
.tas-mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.tas-sechead { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }
.tas-sechead__note { max-width: 42ch; }
.tas-tile { width: 40px; height: 40px; flex: none; border-radius: var(--radius-md); background: var(--surface-wash); border: 1px solid var(--line); color: var(--brand-strong); display: grid; place-items: center; }
.tas-tile .tas-ic { width: 22px; height: 22px; }
.tas-linkbtn { font: inherit; color: var(--brand-strong); background: none; border: 0; padding: 0; text-decoration: underline; cursor: pointer; }
.tas-enter { animation: tas-rise var(--dur-base) var(--ease-enter) both; }
@keyframes tas-rise { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ---------- Hero ---------- */
.tas-hero { padding-block: 56px 64px; }
.tas-hero__grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 48px; align-items: start; }
@media (max-width: 960px) { .tas-hero__grid { grid-template-columns: minmax(0, 1fr); gap: 40px; } }

/* ---------- Finder ---------- */
.tas-finder { margin-top: 32px; background: var(--surface-raised); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; }
.tas-finder__label { display: block; font-weight: 600; font-size: 15px; line-height: 20px; margin-bottom: 8px; }
.tas-finder .fa-input-wrap .fa-input-icon { left: 14px; color: var(--ink-muted); }
.tas-finder__input { font-size: 16px; padding: 12px 14px 12px 40px; }
.tas-finder__help { font-size: 13px; line-height: 18px; color: var(--ink-muted); margin-top: 8px; }
.tas-goals { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.tas-goal { font: 500 13px/18px var(--font-text); border: 1px solid var(--line-strong); background: var(--surface-canvas); color: var(--ink-secondary); border-radius: var(--radius-pill); padding: 5px 12px; cursor: pointer; transition: background-color var(--dur-fast) var(--ease-standard), border-color var(--dur-fast) var(--ease-standard); }
.tas-goal:hover { border-color: var(--control-border); color: var(--ink); }
.tas-goal[aria-pressed="true"] { background: var(--brand-soft); color: var(--brand-onsoft); border-color: var(--brand); }
.tas-finder__ask:not([hidden]) + .tas-finder__results { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 12px; }
.tas-finder__head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 12px; line-height: 16px; color: var(--ink-muted); }
.tas-finder__all { color: var(--brand-strong); }
.tas-res-list { list-style: none; margin: 4px 0 0; padding: 0; }
.tas-res { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px; margin-inline: -10px; border-radius: var(--radius-md); text-decoration: none; color: inherit; transition: background-color var(--dur-fast) var(--ease-standard); }
.tas-res:hover { background: var(--surface-sunken); }
.tas-res__body { display: flex; flex-direction: column; min-width: 0; }
.tas-res__name { font-weight: 600; font-size: 15px; line-height: 20px; color: var(--ink); }
.tas-res__why { font-size: 14px; line-height: 20px; color: var(--ink-secondary); }
.tas-res__go { display: inline-flex; gap: 4px; align-items: center; font-size: 14px; font-weight: 600; color: var(--brand-strong); white-space: nowrap; }
.tas-res-none { padding: 10px 0; font-size: 14px; line-height: 21px; color: var(--ink-secondary); }

/* ---------- Blueprint diagrams ---------- */
.tas-bp {
  position: relative; margin: 0; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden;
  background-color: var(--surface-raised);
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 24px 24px; background-position: -1px -1px;
}
.tas-bp__label { position: relative; padding: 16px 20px 0; font: 500 12px/16px var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-muted); }
.tas-bp__cap { position: relative; padding: 0 20px 20px; font-size: 14px; line-height: 20px; color: var(--ink-secondary); }
.tas-bp__cap::before { content: ""; position: absolute; inset: -24px 0 0; background: linear-gradient(transparent, var(--surface-raised) 24px); z-index: -1; }
.tas-dg { display: block; width: 100%; height: auto; }
.tas-dg--tall { display: none; }
@media (max-width: 560px) { .tas-dg--wide { display: none; } .tas-dg--tall { display: block; } }
.tas-dg__node { fill: var(--surface-raised); stroke: var(--line-strong); stroke-width: 1.25; }
.tas-dg__node--brand { fill: var(--brand-soft); stroke: var(--brand); }
.tas-dg__bound { fill: var(--frost); stroke: var(--brand); stroke-width: 1.25; stroke-dasharray: 6 5; }
.tas-dg__t { fill: var(--ink); font: 600 13px var(--font-text); }
.tas-dg__s { fill: var(--ink-secondary); font: 400 11.5px var(--font-text); }
.tas-dg__mono { fill: var(--brand-strong); font: 500 10.5px var(--font-mono); letter-spacing: 0.06em; }
.tas-dg__mono--muted { fill: var(--ink-secondary); letter-spacing: 0; }
.tas-dg__logo { color: var(--brand); }
.tas-dg__link { fill: none; stroke: var(--ink-muted); stroke-width: 1.5; }
.tas-dg__arrow { fill: var(--ink-muted); }
.tas-dg__out { fill: none; stroke: var(--accent); stroke-width: 1.5; stroke-dasharray: 3 4; }
.tas-dg__arrow--out { fill: var(--accent); }
.tas-dg__dot { fill: var(--accent); }
.tas-dg--draw .tas-dg__stroke { stroke-dasharray: var(--len); animation: tas-draw var(--dur-draw) var(--ease-enter) both; animation-delay: var(--d, 0s); }
.tas-dg--draw .tas-dg__bound.tas-dg__stroke { stroke-dasharray: 6 5; animation: tas-fade var(--dur-draw) var(--ease-enter) both; }
.tas-dg--draw .tas-dg__in { animation: tas-fade var(--dur-base) var(--ease-enter) both; animation-delay: var(--d, 0s); }
@keyframes tas-draw { from { stroke-dashoffset: var(--len); } to { stroke-dashoffset: 0; } }
@keyframes tas-fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Try-it band + demo ---------- */
.tas-tryit { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 48px; align-items: start; }
@media (max-width: 900px) { .tas-tryit { grid-template-columns: minmax(0, 1fr); gap: 32px; } }
.tas-tryit__copy > * + * { margin-top: 16px; }
.tas-demo { background: var(--surface-raised); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.tas-demo__top { padding: 20px; border-bottom: 1px solid var(--line); display: grid; gap: 10px; }
.tas-seg { display: flex; flex-wrap: wrap; gap: 6px; }
.tas-seg button { font: 400 13px/18px var(--font-mono); padding: 6px 12px; border-radius: var(--radius-pill); border: 1px solid var(--control-border); background: var(--surface-canvas); color: var(--ink-secondary); cursor: pointer; }
.tas-seg button:hover { color: var(--ink); }
.tas-seg button[aria-pressed="true"] { background: var(--brand); color: var(--on-brand); border-color: var(--brand); }
.tas-demo__body { padding: 20px; display: grid; gap: 16px; }
.tas-demo__domain { font-size: 13px; color: var(--ink-muted); }
.tas-demo__foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 16px 20px; border-top: 1px solid var(--line); background: var(--surface-canvas); }
.tas-demo__foot .fa-btn { text-decoration: none; }
.tas-verdict { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 16px; align-items: start; }
.tas-verdict__mark { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; }
.tas-verdict__mark .tas-ic { width: 22px; height: 22px; }
.tas-verdict--secure .tas-verdict__mark { background: var(--status-secure-soft); color: var(--status-secure-text); }
.tas-verdict--medium .tas-verdict__mark { background: var(--sev-medium-soft); color: var(--sev-medium-text); }
.tas-verdict--high .tas-verdict__mark { background: var(--sev-high-soft); color: var(--sev-high-text); }
.tas-verdict--critical .tas-verdict__mark { background: var(--sev-critical-soft); color: var(--sev-critical-text); }
.tas-verdict__title { font: 600 22px/28px var(--font-display); letter-spacing: -0.01em; color: var(--ink); }
.tas-verdict__text { font-size: 15px; line-height: 22px; color: var(--ink-secondary); margin-top: 2px; }
.tas-checks { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 520px) { .tas-checks { grid-template-columns: minmax(0, 1fr); } }
.tas-check { border: 1px solid var(--line); border-radius: var(--radius-md); padding: 12px 16px; display: grid; gap: 6px; justify-items: start; background: var(--surface-canvas); }
.tas-check__name { font-weight: 600; font-size: 14px; line-height: 20px; }

/* ---------- Directory ---------- */
.tas-dirbar { margin-top: 32px; display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.tas-filters { display: flex; flex-wrap: wrap; gap: 8px; }
.tas-filter { font: 600 14px/20px var(--font-text); display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--radius-pill); border: 1px solid var(--line-strong); background: var(--surface-raised); color: var(--ink-secondary); cursor: pointer; }
.tas-filter:hover { color: var(--ink); border-color: var(--control-border); }
.tas-filter[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.tas-filter__n { font: 500 11px/16px var(--font-mono); padding: 0 6px; border-radius: var(--radius-pill); background: var(--status-neutral-soft); color: var(--status-neutral-text); }
.tas-filter[aria-pressed="true"] .tas-filter__n { background: var(--surface-raised); color: var(--brand-strong); }
.tas-dirbar__search { width: 280px; max-width: 100%; }
.tas-dirbar__search .fa-input-icon { color: var(--ink-muted); }
.tas-count { margin-top: 16px; font: 400 12px/16px var(--font-mono); color: var(--ink-muted); }
.tas-dir { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
@media (max-width: 900px) { .tas-dir { grid-template-columns: minmax(0, 1fr); } }
.tas-tool { position: relative; display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 16px; padding: 20px 12px; margin-inline: -12px; border-bottom: 1px solid var(--line); border-radius: var(--radius-md); transition: background-color var(--dur-instant) var(--ease-standard), transform var(--dur-instant) var(--ease-standard), box-shadow var(--dur-instant) var(--ease-standard); }
.tas-tool[hidden] { display: none; }
.tas-tool:hover { background: var(--surface-raised); box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.tas-tool:focus-within { background: var(--surface-raised); }
.tas-tool__name { font: 600 18px/24px var(--font-display); letter-spacing: -0.01em; }
.tas-tool__name a { color: var(--ink); text-decoration: none; }
.tas-tool__name a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius-md); }
.tas-tool__name a:focus-visible { outline: none; }
.tas-tool__name a:focus-visible::after { outline: 2px solid var(--focus); outline-offset: -2px; }
.tas-tool__sub { font: 400 12px/16px var(--font-mono); color: var(--ink-muted); letter-spacing: 0; }
.tas-tool__plain { font-size: 15px; line-height: 22px; color: var(--ink); margin-top: 4px; }
.tas-tool__tech { font-size: 13px; line-height: 19px; color: var(--ink-muted); margin-top: 6px; }
.tas-tool__tech .term { position: relative; z-index: 1; }
.tas-tool__tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.tas-tag { font: 400 11px/16px var(--font-mono); padding: 1px 7px; border-radius: var(--radius-sm); background: var(--status-neutral-soft); color: var(--status-neutral-text); }
.tas-empty { padding: 40px 0; color: var(--ink-secondary); }

/* ---------- Latest guides ---------- */
.tas-guides { list-style: none; margin: 32px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
@media (max-width: 900px) { .tas-guides { grid-template-columns: minmax(0, 1fr); } }
.tas-guide { position: relative; display: grid; gap: 12px; align-content: start; }
.tas-cover {
  position: relative; display: block; aspect-ratio: 16 / 9; max-width: 100%; overflow: hidden;
  border-radius: var(--radius-md); border: 1px solid var(--line); background-color: var(--surface-wash);
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 20px 20px;
}
.tas-cover__ic { position: absolute; right: 8%; top: 50%; width: 32%; height: auto; aspect-ratio: 1; transform: translateY(-50%); color: var(--brand); }
.tas-cover__lbl { position: absolute; left: 14px; bottom: 12px; font: 500 11px/16px var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--brand-strong); background: var(--surface-raised); border: 1px solid var(--line); padding: 2px 8px; border-radius: var(--radius-sm); }
.tas-guide__meta { font-size: 12px; line-height: 16px; color: var(--ink-muted); }
.tas-guide__title { font: 600 19px/25px var(--font-display); letter-spacing: -0.01em; }
.tas-guide__title a { color: var(--ink); text-decoration: none; }
.tas-guide__title a::after { content: ""; position: absolute; inset: 0; }
.tas-guide:hover .tas-guide__title a { color: var(--brand-strong); text-decoration: underline; text-underline-offset: 3px; }
.tas-guide__title a:focus-visible { outline: none; }
.tas-guide__title a:focus-visible::after { outline: 2px solid var(--focus); outline-offset: 4px; border-radius: var(--radius-md); }
.tas-guide__ex { font-size: 14px; line-height: 21px; color: var(--ink-secondary); }

/* ---------- FAQ + author ---------- */
.tas-faqgrid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 48px; }
@media (max-width: 900px) { .tas-faqgrid { grid-template-columns: minmax(0, 1fr); gap: 32px; } }
.tas-author { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 16px; align-items: start; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface-raised); margin-top: 32px; }
.tas-avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--brand-soft); color: var(--brand-onsoft); display: grid; place-items: center; font: 600 20px/1 var(--font-display); }
.tas-author__name { font-weight: 600; }
.tas-author__bio { font-size: 14px; line-height: 21px; color: var(--ink-secondary); margin-top: 2px; }
.tas-author__links { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 12px; font-size: 14px; }
.tas-faq { border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface-raised); overflow: hidden; align-self: start; }
.tas-faq__item + .tas-faq__item { border-top: 1px solid var(--line); }
.tas-faq__item summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 16px; padding: 14px 20px; font-weight: 600; font-size: 15px; line-height: 22px; color: var(--ink); }
.tas-faq__item summary::-webkit-details-marker { display: none; }
.tas-faq__item summary::after { content: "+"; font: 400 20px/22px var(--font-text); color: var(--ink-muted); flex: none; }
.tas-faq__item[open] summary::after { content: "\2212"; color: var(--brand-strong); }
.tas-faq__item summary:hover { background: var(--surface-sunken); }
.tas-faq__item summary:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.tas-faq__a { padding: 0 20px 20px; font-size: 15px; line-height: 23px; color: var(--ink-secondary); }

/* ---------- Term hints ---------- */
.tas-page .term, .term {
  font: inherit; color: inherit; background: none; border: 0; padding: 0; margin: 0; cursor: help;
  text-decoration: underline dotted; text-decoration-color: var(--ink-muted); text-decoration-thickness: 1px; text-underline-offset: 3px;
}
.term:hover, .term:focus-visible { color: var(--ink); text-decoration-color: var(--brand); }
.tas-termpop {
  position: fixed; z-index: 950; max-width: 280px; padding: 10px 12px; pointer-events: none;
  background: var(--surface-inverse); color: var(--ink-inverse); border-radius: var(--radius-md); box-shadow: var(--shadow-card);
  font: 400 13px/19px var(--font-text);
}
.tas-termpop[hidden] { display: none; }
.tas-termpop b { display: block; margin-bottom: 2px; font: 600 11px/16px var(--font-mono); letter-spacing: 0.05em; text-transform: uppercase; }

/* ---------- Cookie notice on migrated pages ----------
   assets/js/cookie-consent.js styles itself with legacy variable names. Map them to
   Frosted Aura here so the notice follows the theme and its button stays AA. */
.tas-page .tas-consent-banner {
  --surface: var(--surface-raised); --bg-1: var(--surface-raised); --border: var(--line); --border-2: var(--line-strong);
  --text: var(--ink); --text-2: var(--ink-secondary); --accent: var(--brand); --accent-inv: var(--on-brand);
  --font-body: var(--font-text); --shadow-md: var(--shadow-card); --r-sm: var(--radius-sm);
}

@media (prefers-reduced-motion: reduce) {
  .tas-enter, .tas-dg--draw .tas-dg__stroke, .tas-dg--draw .tas-dg__in, .tas-dg--draw .tas-dg__bound { animation: none !important; }
  .tas-dg__dot { display: none; }
  .tas-tool, .tas-res, .tas-goal { transition: none; }
  .tas-tool:hover { transform: none; }
}
