/* ACCURE (design system inherited from MXO): neutral canvas, hairline borders, compact type, line icons (light + dark). */

:root {
  --font: "Inter Variable", Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  --canvas: oklch(98.75% 0 0);
  --base: #fff;
  --elevated: oklch(98% 0 0);
  --recessed: oklch(96% 0 0);
  --tint: oklch(97% 0 0);
  --fill: oklch(92.2% 0 0);
  --line: oklch(14.5% 0 0 / .1);
  --hairline: oklch(93.5% 0 0);
  --text: oklch(21% .006 285.885);
  --strong: oklch(14.5% 0 0);
  --subtle: oklch(55.6% 0 0);
  --placeholder: oklch(70.8% 0 0);
  --brand: #1100ff;
  --brand-hover: #0d00cc;
  --accent: #1100ff;
  --accent-2: #0d00cc;
  --link: oklch(42.4% .199 265.638);
  --success: oklch(43.2% .095 166.913);
  --success-tint: oklch(96.2% .043 156.7 / .57);
  --danger: oklch(50.5% .213 27.518);
  --danger-tint: oklch(93.6% .032 17.7 / .42);
  --warning: oklch(59.7% .144 57.5);
  --warning-tint: oklch(93.1% .107 94.6 / .25);
  --info-tint: oklch(93.2% .032 255.6 / .45);
  --focus: oklch(15% 0 0);
  --shadow: 0 0 1px .5px oklch(0% 0 0 / .12), 0 1px 2px oklch(0% 0 0 / .08);
  --radius: 9px;
  --radius-lg: 14px;
  --sidebar: 248px;
  --header: 56px;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --canvas: oklch(8% 0 0);
  --base: oklch(14.5% 0 0);
  --elevated: oklch(12% 0 0);
  --recessed: oklch(15% 0 0);
  --tint: oklch(26.9% 0 0);
  --fill: oklch(26.9% 0 0);
  --line: oklch(32% 0 0);
  --hairline: oklch(26.9% 0 0);
  --text: oklch(97% 0 0);
  --strong: oklch(98.5% 0 0);
  --subtle: oklch(70.8% 0 0);
  --placeholder: oklch(55.6% 0 0);
  --brand: #1100ff;
  --link: oklch(70.7% .165 254.624);
  --success: oklch(90.5% .093 164.15);
  --success-tint: oklch(39.3% .096 152.3 / .2);
  --danger: oklch(70.4% .191 22.216);
  --danger-tint: oklch(42.9% .176 28.7 / .17);
  --warning: oklch(75% .183 55.934);
  --warning-tint: oklch(35.3% .079 65 / .37);
  --info-tint: oklch(38% .145 265.5 / .22);
  --focus: oklch(93.5% 0 0);
  --shadow: 0 0 1px .5px oklch(100% 0 0 / .1), 0 1px 2px oklch(0% 0 0 / .3);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --canvas: oklch(8% 0 0);
    --base: oklch(14.5% 0 0);
    --elevated: oklch(12% 0 0);
    --recessed: oklch(15% 0 0);
    --tint: oklch(26.9% 0 0);
    --fill: oklch(26.9% 0 0);
    --line: oklch(32% 0 0);
    --hairline: oklch(26.9% 0 0);
    --text: oklch(97% 0 0);
    --strong: oklch(98.5% 0 0);
    --subtle: oklch(70.8% 0 0);
    --placeholder: oklch(55.6% 0 0);
    --brand: #1100ff;
    --link: oklch(70.7% .165 254.624);
    --success: oklch(90.5% .093 164.15);
    --success-tint: oklch(39.3% .096 152.3 / .2);
    --danger: oklch(70.4% .191 22.216);
    --danger-tint: oklch(42.9% .176 28.7 / .17);
    --warning: oklch(75% .183 55.934);
    --warning-tint: oklch(35.3% .079 65 / .37);
    --info-tint: oklch(38% .145 265.5 / .22);
    --focus: oklch(93.5% 0 0);
    --shadow: 0 0 1px .5px oklch(100% 0 0 / .1), 0 1px 2px oklch(0% 0 0 / .3);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body {
  margin: 0; background: var(--canvas); color: var(--text);
  font-family: var(--font); font-size: 14px; line-height: 1.5; letter-spacing: -.01em;
  font-feature-settings: "cv02", "cv03", "cv04", "calt";
}
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
code, pre, .secret { font-family: var(--mono); letter-spacing: 0; }
code { font-size: 12.5px; background: var(--tint); border: 1px solid var(--hairline); border-radius: 4px; padding: 1px 5px; }
h1 { font-size: 22px; font-weight: 500; letter-spacing: -.02em; color: var(--strong); margin: 0 0 6px; }
h2 { font-size: 15px; font-weight: 500; color: var(--strong); margin: 36px 0 12px; }
.card > h2:first-child { margin-top: 0; }
p { margin: 8px 0; }

/* Icons */
.ic { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }

/* Top bar */
header.top {
  position: sticky; top: 0; z-index: 20; height: var(--header);
  display: flex; align-items: center; gap: 12px; padding: 0 16px;
  background: var(--canvas); border-bottom: 1px solid var(--line);
}
header.top .spacer { flex: 1; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--strong); font-weight: 600; font-size: 15px; letter-spacing: -.01em; }
.brand:hover { text-decoration: none; }
.brand .mark { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; background: var(--accent); color: #fff; }
.brand .mark .ic { width: 18px; height: 18px; stroke-width: 2.25; vertical-align: 0; }
.brand .tag, .tag { font-size: 11px; font-weight: 500; color: var(--subtle); border: 1px solid var(--line); border-radius: 99px; padding: 1px 8px; }
.brand.big { font-size: 20px; justify-content: center; margin-bottom: 20px; }
.brand.big .mark { width: 36px; height: 36px; border-radius: 9px; }
.divider { width: 1px; height: 24px; background: var(--line); }
.org { display: inline-flex; align-items: center; gap: 6px; color: var(--subtle); }
.org select { border: 0; background: transparent; padding: 6px 4px; font-weight: 500; color: var(--text); max-width: 260px; box-shadow: none; }
.org select:focus-visible { box-shadow: 0 0 0 2px var(--brand); }
.toplink { display: inline-flex; align-items: center; gap: 6px; color: var(--text); padding: 6px 10px; border-radius: var(--radius); }
.toplink:hover { background: var(--tint); text-decoration: none; }
.who { color: var(--subtle); font-size: 13px; padding: 0 4px; }

/* Layout */
.layout { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: calc(100vh - var(--header)); }
nav.side {
  position: sticky; top: var(--header); align-self: start; height: calc(100vh - var(--header)); overflow-y: auto;
  padding: 12px; border-right: 1px solid var(--line); background: var(--canvas);
  display: flex; flex-direction: column; gap: 2px;
}
nav.side button, nav.side .navlink, nav.side a.navitem {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  background: none; border: 0; padding: 7px 10px; border-radius: var(--radius);
  color: var(--text); font: inherit; cursor: pointer;
}
nav.side button .ic, nav.side .navlink .ic, nav.side a.navitem .ic { color: var(--subtle); }
nav.side button:hover, nav.side .navlink:hover, nav.side a.navitem:hover { background: var(--tint); text-decoration: none; }
nav.side .navitem.active { background: var(--recessed); color: var(--strong); font-weight: 500; box-shadow: inset 0 0 0 1px var(--hairline); }
nav.side .navitem.active .ic { color: var(--strong); }
nav.side .navlink { margin-top: auto; color: var(--subtle); }
nav.side .navlink .ic:last-child { width: 12px; height: 12px; margin-left: auto; }

main { padding: 40px 48px 96px; max-width: 1160px; width: 100%; }
main.docs { margin: 0 auto; max-width: 860px; }
.eyebrow { display: inline-flex; align-items: center; gap: 6px; color: var(--subtle); font-size: 12px; margin-bottom: 4px; }
.eyebrow .ic { width: 14px; height: 14px; vertical-align: 0; }
#view > h1 + p, #view > h1 + .muted { margin-top: 0; }
#view > h1 { margin-bottom: 4px; }

/* Surfaces */
.card {
  background: var(--base); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 24px; margin: 20px 0; box-shadow: 0 1px 1px oklch(0% 0 0 / .02);
}
/* Tiles wrap and grow to fill each row, so a row never ends in an empty cell. */
.tiles { display: flex; flex-wrap: wrap; gap: 16px; margin: 22px 0; }
.tiles > * { flex: 1 1 200px; min-width: 0; }
.tile { background: var(--base); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px 22px; }
.tile .label { color: var(--subtle); font-size: 13px; }
.tile .value { font-size: 22px; font-weight: 500; letter-spacing: -.02em; color: var(--strong); font-variant-numeric: tabular-nums; margin-top: 2px; }
.tile .sub { color: var(--subtle); font-size: 12px; margin-top: 2px; }

/* Tables */
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--hairline); vertical-align: top; }
thead th { color: var(--subtle); font-weight: 500; font-size: 12px; background: var(--elevated); border-bottom: 1px solid var(--line); }
thead tr th:first-child { border-top-left-radius: var(--radius); }
thead tr th:last-child { border-top-right-radius: var(--radius); }
tbody tr:hover td { background: var(--elevated); }
tbody tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
thead th { white-space: nowrap; }
/* Wide tables scroll sideways inside their card when the page is narrow (phone, Ask AI open). */
.table-wrap { overflow-x: auto; max-width: 100%; overscroll-behavior-x: contain; }
.card > .table-wrap, .card > div > .table-wrap { margin: -4px 0; }

/* Controls */
input, select, textarea, button { font: inherit; letter-spacing: inherit; color: var(--text); }
input, select, textarea {
  background: var(--base); border: 0; border-radius: var(--radius); padding: 6px 10px; min-height: 34px;
  box-shadow: 0 0 0 1px var(--line); transition: box-shadow .1s;
}
input::placeholder, textarea::placeholder { color: var(--placeholder); }
input:focus, select:focus, textarea:focus { outline: none; box-shadow: 0 0 0 1.5px var(--brand); }
input[type="checkbox"] { min-height: 0; width: 16px; height: 16px; accent-color: var(--brand); box-shadow: none; }
input[type="file"] { padding: 4px; }
input[type="file"]::file-selector-button { border: 0; border-radius: 6px; background: var(--fill); padding: 6px 10px; margin-right: 10px; font: inherit; color: var(--text); cursor: pointer; }
textarea { width: 100%; min-height: 160px; resize: vertical; line-height: 1.5; }
select { padding-right: 28px; }

button.primary, button.secondary, button.danger, button.ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 34px; padding: 0 13px; border-radius: var(--radius); border: 0; cursor: pointer;
  font-weight: 500; white-space: nowrap; transition: background-color .1s, box-shadow .1s, transform .1s;
}
button.primary { background: var(--brand); color: #fff; box-shadow: inset 0 1px 0 oklch(100% 0 0 / .2), var(--shadow); }
button.primary:hover { background: var(--brand-hover); }
button.secondary { background: var(--base); box-shadow: 0 0 0 1px var(--line), var(--shadow); }
button.secondary:hover { background: var(--tint); }
button.danger { background: var(--base); color: var(--danger); box-shadow: 0 0 0 1px var(--line); }
button.danger:hover { background: var(--danger-tint); }
button.ghost { background: none; color: var(--subtle); padding: 0 10px; }
button.ghost:hover { background: var(--tint); color: var(--text); }
button:focus-visible, a:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
button:disabled { opacity: .55; cursor: default; }

.row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; margin: 12px 0; }
.row > label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 500; color: var(--subtle); }
.row > label:has(input[type="checkbox"]) { flex-direction: row; align-items: center; min-height: 36px; }
.grow { flex: 1; min-width: 200px; }

/* Feedback */
.muted { color: var(--subtle); }
.small { font-size: 13px; }
.badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 1px 8px; border-radius: 99px;
  font-size: 12px; font-weight: 500; background: var(--tint); color: var(--text); vertical-align: 2px;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .8; }
.badge.good { background: var(--success-tint); color: var(--success); }
.badge.bad { background: var(--danger-tint); color: var(--danger); }
.badge.warn { background: var(--warning-tint); color: var(--warning); }
.notice { padding: 10px 14px; border-radius: var(--radius); margin: 10px 0; background: var(--info-tint); border: 1px solid var(--line); font-size: 13px; }
.notice.bad { background: var(--danger-tint); color: var(--danger); border-color: transparent; }
.notice.good { background: var(--success-tint); color: var(--success); border-color: transparent; }
.secret { display: block; background: var(--recessed); border: 1px solid var(--hairline); padding: 8px 10px; border-radius: var(--radius); word-break: break-all; font-size: 12.5px; margin-top: 6px; }
code.secret { display: inline-block; margin: 0; }
pre { background: var(--recessed); border: 1px solid var(--hairline); padding: 12px 14px; border-radius: var(--radius); overflow: auto; font-size: 12.5px; line-height: 1.6; }
.output { white-space: pre-wrap; background: var(--recessed); border: 1px solid var(--hairline); padding: 12px 14px; border-radius: var(--radius); min-height: 140px; }
details > summary { cursor: pointer; color: var(--subtle); padding: 6px 0; }
details > summary:hover { color: var(--text); }

/* Sign in */
.center { max-width: 400px; margin: 12vh auto; padding: 0 16px; }
.center .card { padding: 28px; }
.center h1 { font-size: 20px; }

.hidden { display: none !important; }

main { container: content / inline-size; min-width: 0; }
@container app (max-width: 820px) {
  .layout { grid-template-columns: 1fr; }
  nav.side { position: static; height: auto; flex-direction: row; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  nav.side button, nav.side .navlink, nav.side a.navitem { width: auto; white-space: nowrap; }
  nav.side .navlink { margin-top: 0; }
  main { padding: 20px 16px 48px; }
}

/* Native selects styled like inputs, with a small chevron glyph */
select:not(.org select) {
  -webkit-appearance: none; appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 15 5 5 5-5M7 9l5-5 5 5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 9px center;
}
.row > label { min-width: 160px; }
.row > label > input:not([type="checkbox"]), .row > label > select { width: 100%; }

/* Brand: the Marcus Aurelius mark on its own near-black shape: one file for light and dark. */
.logo { display: block; height: 32px; width: auto; }
.brand.big .logo { height: 56px; margin: 0 auto; }
.head-left { display: flex; align-items: center; gap: 10px; width: calc(var(--sidebar) - 16px); padding-right: 12px; margin-right: 4px; border-right: 1px solid var(--line); height: 100%; }
.org { flex: 1; min-width: 0; gap: 4px; }
.org select { flex: 1; min-width: 0; -webkit-appearance: none; appearance: none; cursor: pointer; text-overflow: ellipsis; }
.org > .ic:last-child { width: 14px; height: 14px; }
button.toplink { background: none; border: 0; font: inherit; cursor: pointer; }

/* Page header: title + subtitle left, actions right */
.pagehead { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 8px; }
.pagehead > div:first-child { flex: 1; min-width: 0; }
.pagehead h1 { font-size: 24px; margin-bottom: 4px; }
.pagehead p { margin: 0; color: var(--subtle); }
.pagehead .actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
a.button { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 13px; border-radius: var(--radius); color: var(--text); background: var(--base); box-shadow: 0 0 0 1px var(--line), var(--shadow); font-weight: 500; white-space: nowrap; }
a.button:hover { background: var(--tint); text-decoration: none; }
.pill { display: inline-flex; align-items: center; font-size: 12px; padding: 2px 9px; border-radius: 99px; background: var(--fill); color: var(--text); white-space: nowrap; }

/* Recommendations */
.recs { padding: 0; overflow: hidden; }
.recs > summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 16px 22px; color: var(--text); font-weight: 500; }
.recs > summary::-webkit-details-marker { display: none; }
.recs > summary .count { display: inline-grid; place-items: center; min-width: 18px; height: 18px; border-radius: 9px; background: var(--brand); color: #fff; font-size: 11px; padding: 0 5px; }
.recs > summary .ic:last-child { margin-left: auto; transition: transform .15s; }
.recs:not([open]) > summary .ic:last-child { transform: rotate(180deg); }
.recs ul { list-style: none; margin: 0; padding: 4px 22px 12px; border-top: 1px solid var(--hairline); background: var(--elevated); }
.recs li { position: relative; padding: 10px 0 10px 18px; }
.recs li + li { border-top: 1px solid var(--hairline); }
.recs li::before { content: ""; position: absolute; left: 2px; top: 17px; width: 7px; height: 7px; border-radius: 50%; background: var(--brand); }
.recs li b { display: block; color: var(--strong); font-weight: 500; }
.recs li span { color: var(--subtle); font-size: 13px; }
.recs li a, .recs li button.link { font-size: 13px; }
button.link { background: none; border: 0; padding: 0; color: var(--link); cursor: pointer; font: inherit; text-decoration: underline; text-underline-offset: 2px; }

/* Dialog */
dialog.dialog { border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 0; width: min(560px, calc(100vw - 32px)); background: var(--base); color: var(--text); box-shadow: 0 20px 50px oklch(0% 0 0 / .35); }
dialog.dialog::backdrop { background: oklch(0% 0 0 / .45); }
dialog.dialog .dhead { display: flex; align-items: center; gap: 8px; padding: 16px 20px; border-bottom: 1px solid var(--hairline); font-weight: 500; color: var(--strong); }
dialog.dialog .dhead button { margin-left: auto; }
dialog.dialog .dbody { padding: 16px 20px 20px; }
dialog.dialog label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 500; color: var(--subtle); margin: 10px 0; }
dialog.dialog label > * { width: 100%; }
dialog.dialog textarea { min-height: 140px; }

/* Estimator */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin: 12px 0; }
.suggest { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); }
.suggest .big { font-size: 22px; font-weight: 500; color: var(--strong); }
.bars { display: flex; align-items: flex-end; gap: 6px; height: 120px; padding: 8px 0 0; }
.bars .bar { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; height: 100%; font-size: 11px; color: var(--subtle); min-width: 0; }
.bars .bar i { display: block; width: 100%; max-width: 44px; background: var(--brand); border-radius: 4px 4px 0 0; min-height: 2px; opacity: .85; }
.segmented { display: inline-flex; background: var(--fill); border-radius: var(--radius); padding: 2px; gap: 2px; }
.segmented button { border: 0; background: none; padding: 5px 12px; border-radius: 6px; font: inherit; font-size: 13px; cursor: pointer; color: var(--subtle); }
.segmented button.on { background: var(--base); color: var(--strong); box-shadow: var(--shadow); }

@container app (max-width: 820px) {
  .head-left { width: auto; border-right: 0; }
  nav.side .navhead { display: none; }
}
@container app (max-width: 640px) { .toplink span { display: none; } }
@container content (max-width: 640px) { .pagehead { flex-direction: column; } }

/* Website list + detail */
tr.clickable { cursor: pointer; }
tr.clickable td:last-child .ic { color: var(--subtle); }
.progress { position: relative; height: 8px; border-radius: 99px; background: var(--fill); overflow: visible; margin-top: 6px; }
.progress > span { display: block; height: 100%; border-radius: 99px; background: var(--brand); width: 100%;
  clip-path: inset(0 calc(100% - var(--p, 0%)) 0 0 round 99px); transition: clip-path .2s ease-out; }
@starting-style { .progress > span { clip-path: inset(0 100% 0 0 round 99px); } }
.progress > small { position: absolute; right: 0; top: -18px; font-size: 11px; color: var(--subtle); }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin: 16px 0 4px; overflow-x: auto; }
.tabs button { background: none; border: 0; font: inherit; color: var(--subtle); padding: 9px 12px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs button:hover { color: var(--text); }
.tabs button.on { color: var(--strong); border-bottom-color: var(--brand); font-weight: 500; }
.back { display: inline-block; margin-bottom: 8px; text-decoration: none; }
.sitemeta { margin-top: -2px; }
.legend { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.legend .dot { width: 8px; height: 8px; border-radius: 2px; background: var(--brand); display: inline-block; }
.legend .dot.alt { background: var(--success); margin-left: 10px; }
.bars .bar .pair { display: flex; align-items: flex-end; gap: 1px; width: 100%; height: 100%; justify-content: center; }
.bars .bar .pair i { width: 45%; max-width: 12px; }
.bars .bar .pair i.alt { background: var(--success); }
.pagerow { border: 1px solid var(--line); border-radius: var(--radius); background: var(--base); margin: 6px 0; }
.pagerow > summary { display: flex; align-items: center; gap: 12px; padding: 9px 12px; flex-wrap: wrap; color: var(--text); }
.pagerow > summary .path { font-family: var(--mono); font-size: 12.5px; flex: 1; min-width: 200px; word-break: break-all; }
.pagerow[open] > summary { border-bottom: 1px solid var(--hairline); }
.pagerow > .table-wrap > table { margin: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 3px; }
.chip { font-size: 10.5px; padding: 0 5px; border-radius: 4px; background: var(--fill); color: var(--subtle); font-family: var(--mono); }
.chip.published { background: var(--success-tint); color: var(--success); }
.chip.failed { background: var(--danger-tint); color: var(--danger); }
.chip.queued, .chip.translating { background: var(--warning-tint); color: var(--warning); }
ol.timeline { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--line); }
ol.timeline li { position: relative; padding: 4px 0 10px 16px; font-size: 13px; }
ol.timeline li::before { content: ""; position: absolute; left: -6px; top: 9px; width: 10px; height: 10px; border-radius: 50%; background: var(--base); border: 2px solid var(--brand); }
ol.steps { padding-left: 20px; } ol.steps li { margin: 6px 0; }
ul.checks { list-style: none; padding: 0; margin: 0; } ul.checks li { display: flex; gap: 8px; align-items: flex-start; padding: 5px 0; font-size: 13px; }
ul.checks .ic { color: var(--success); margin-top: 2px; }
.card.danger-zone { border-color: color-mix(in srgb, var(--danger) 40%, var(--line)); }
details.card > summary { list-style: none; display: flex; align-items: center; gap: 6px; font-weight: 500; color: var(--strong); }
details.card > summary::-webkit-details-marker { display: none; }
details.card[open] > summary { margin-bottom: 8px; }

/* ---- Shell: user menu, quick search, recents ---- */
.iconbtn { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 99px; border: 0; background: none; color: var(--text); cursor: pointer; }
.iconbtn:hover { background: var(--tint); }
.iconbtn .ic { width: 18px; height: 18px; }
.usermenu { position: relative; }
.popover { position: absolute; right: 0; top: calc(100% + 8px); min-width: 240px; background: var(--base); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: 0 12px 32px oklch(0% 0 0 / .25); padding: 6px; z-index: 40; display: flex; flex-direction: column; }
.popover .pop-head { padding: 8px 10px 10px; border-bottom: 1px solid var(--hairline); margin-bottom: 4px; }
.popover button, .popover a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--radius); border: 0; background: none; color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.popover button:hover, .popover a:hover { background: var(--tint); text-decoration: none; }
.popover hr { border: 0; border-top: 1px solid var(--hairline); margin: 4px 0; width: 100%; }
.quicksearch { display: flex !important; align-items: center; gap: 10px; width: 100%; margin: 0 0 8px; padding: 7px 10px !important; border-radius: var(--radius) !important;
  background: var(--base) !important; box-shadow: 0 0 0 1px var(--line); color: var(--subtle) !important; }
.quicksearch span { flex: 1; }
kbd { font-family: var(--font); font-size: 11px; color: var(--subtle); border: 1px solid var(--line); border-radius: 5px; padding: 0 5px; background: var(--base); }
.recents .navhead { display: flex; align-items: center; gap: 6px; padding-top: 6px; }
.recents .navhead .ic { width: 13px; height: 13px; }


/* ---- Quick search palette ---- */
dialog.palette { width: min(680px, calc(100vw - 32px)); max-height: 70vh; margin-top: 12vh; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--base); color: var(--text); box-shadow: 0 24px 60px oklch(0% 0 0 / .45); display: none; flex-direction: column; }
dialog.palette[open] { display: flex; }
dialog.palette::backdrop { background: oklch(0% 0 0 / .5); }
.pal-search { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--hairline); }
.pal-search input { flex: 1; border: 0; box-shadow: none; background: none; font-size: 15px; padding: 4px 0; }
.pal-search input:focus { box-shadow: none; }
.pal-list { overflow-y: auto; padding: 6px; flex: 1; }
.pal-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 12px; border: 0; background: none; border-radius: var(--radius); color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.pal-item small { margin-left: auto; color: var(--subtle); font-size: 12px; }
.pal-item.on { background: var(--tint); }
.pal-foot { display: flex; align-items: center; gap: 6px; padding: 9px 16px; border-top: 1px solid var(--hairline); }

/* ---- Ask AI panel ---- */
.assistant { position: fixed; top: var(--header); right: 0; bottom: 0; width: min(420px, 100vw); background: var(--canvas); border-left: 1px solid var(--line);
  transform: translateX(100%); transition: transform .18s ease; z-index: 30; display: flex; flex-direction: column; }
.assistant.open { transform: none; box-shadow: -12px 0 32px oklch(0% 0 0 / .2); }
.as-top { display: flex; align-items: center; gap: 2px; flex: none; height: var(--header); padding: 0 10px 0 18px; border-bottom: 1px solid var(--line); background: var(--canvas); }
.as-top b { flex: 1; font-weight: 500; }
.as-help { display: flex; align-items: center; justify-content: space-between; margin: 12px; padding: 8px 8px 8px 14px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--base); }
.as-body { flex: 1; overflow-y: auto; padding: 4px 16px 16px; }
.as-hello { text-align: center; padding: 8px 0 8px; }
.as-hello h3 { margin: 10px 0 2px; font-weight: 500; font-size: 18px; color: var(--strong); }
.as-logo { height: 56px; width: auto; }
.as-sugg { display: flex; flex-direction: column; gap: 8px; margin: 20px auto 0; max-width: 300px; text-align: left; }
.as-sugg button { display: flex; gap: 12px; align-items: center; padding: 9px 12px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--base); color: var(--text); font: inherit; font-size: 13.5px; cursor: pointer; text-align: left; transition: background-color .12s, border-color .12s, transform .12s; }
.as-sugg button:hover { background: var(--tint); }
.as-sugg b { display: block; font-weight: 500; }
.as-sugg small { display: block; color: var(--subtle); font-size: 12px; }
.as-ic { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line); flex: none; }
.as-msg { margin: 12px 0; line-height: 1.55; font-size: 14px; }
.as-msg.me { margin-left: 15%; background: var(--fill); padding: 8px 12px; border-radius: 12px 12px 4px 12px; white-space: pre-wrap; }
.as-msg.ai { background: var(--base); border: 1px solid var(--line); padding: 10px 14px; border-radius: 12px 12px 12px 4px; }
.md p { margin: 6px 0; } .md ul, .md ol { margin: 6px 0; padding-left: 20px; } .md h4 { margin: 10px 0 4px; font-size: 14px; }
.as-input { margin: 12px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--base); padding: 8px 10px; }
.as-input:focus-within { box-shadow: 0 0 0 1.5px var(--brand); }
.as-input textarea { min-height: 44px; border: 0; box-shadow: none; padding: 4px 2px; background: none; resize: none; }
.as-row { display: flex; align-items: center; justify-content: space-between; }
.chip-ro { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--subtle); border: 1px solid var(--line); border-radius: 99px; padding: 2px 9px; }
.chip-ro .ic { width: 12px; height: 12px; }
.as-send { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 99px; border: 0; background: var(--brand); color: #fff; cursor: pointer; }
.as-send:disabled { opacity: .5; }

/* ---- Analytics ---- */
.sectionhead { display: flex; align-items: center; gap: 8px; margin: 28px 0 10px; }
.sectionhead h2 { margin: 0; flex: 1; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stat { background: var(--base); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 14px 16px 10px; min-width: 0; }
.stat.wide { grid-column: span 2; }
.stat-head { display: flex; justify-content: space-between; color: var(--subtle); font-size: 13px; }
.stat-value { display: flex; align-items: baseline; gap: 8px; font-size: 24px; font-weight: 500; letter-spacing: -.02em; color: var(--strong); margin: 2px 0 6px; font-variant-numeric: tabular-nums; }
.delta { font-size: 12px; font-weight: 500; color: var(--subtle); }
.delta.up { color: var(--success); } .delta.down { color: var(--danger); }
svg.chart { width: 100%; height: auto; display: block; overflow: visible; }
svg.chart .grid { stroke: var(--hairline); stroke-width: 1; vector-effect: non-scaling-stroke; }
svg.chart .axis { fill: var(--subtle); font-size: 11px; font-family: var(--font); }
svg.chart .area { opacity: .14; }
svg.chart .line { fill: none; stroke-width: 1.6; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
svg.chart .empty { fill: var(--subtle); font-size: 13px; font-family: var(--font); }
.barlist { display: flex; flex-direction: column; gap: 6px; }
.barrow { display: grid; grid-template-columns: minmax(80px, 30%) 1fr auto; gap: 10px; align-items: center; font-size: 13px; }
.barrow .bt { height: 8px; background: var(--fill); border-radius: 99px; overflow: hidden; }
.barrow .bt i { display: block; height: 100%; background: var(--brand); border-radius: 99px; }
.barrow .bv { color: var(--subtle); font-variant-numeric: tabular-nums; }
@container content (max-width: 860px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container content (max-width: 480px) { .stats { grid-template-columns: 1fr; } .stat.wide { grid-column: auto; } }

/* ---- Promo banner (Cloudflare style) ---- */
.banner { display: flex; align-items: center; gap: 18px; padding: 6px 18px 6px 6px; margin: 16px 0; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--base); }
.banner .banner-art { width: 132px; align-self: stretch; min-height: 84px; flex: none; padding: 4px; border-radius: 12px; }
.banner .banner-art .globe-card { border-radius: 9px; display: flex; flex-direction: column; justify-content: flex-start; padding: 10px 12px; }
.banner .banner-art b { font-size: 24px; line-height: 1; font-weight: 650; letter-spacing: -.03em; }
.banner .banner-art small { font-size: 11px; line-height: 1.25; opacity: .9; margin-top: 3px; }
@container content (max-width: 560px) { .banner { flex-wrap: wrap; padding: 6px; } .banner .txt { flex-basis: calc(100% - 160px); } }
.banner .txt { flex: 1; min-width: 0; padding: 8px 0; }
.banner .txt b { display: block; color: var(--strong); font-weight: 500; font-size: 15px; }
.banner .txt span { color: var(--subtle); font-size: 13px; }
button.accent { background: var(--brand); color: #fff; box-shadow: inset 0 1px 0 oklch(100% 0 0 / .2), var(--shadow); }
button.accent:hover { background: var(--brand-hover); }
.nudge { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: var(--radius-lg); border: 1px solid color-mix(in srgb, var(--brand) 40%, var(--line)); background: var(--info-tint); margin: 12px 0; }
.nudge .txt { flex: 1; }

/* ---- Forms: switches, glossary, compare ---- */
.switch { display: flex; align-items: flex-start; gap: 12px; padding: 12px 0; border-top: 1px solid var(--hairline); }
.switch:first-of-type { border-top: 0; }
.switch .txt { flex: 1; } .switch .txt b { display: block; font-weight: 500; color: var(--strong); } .switch .txt span { color: var(--subtle); font-size: 13px; }
.switch input[type="checkbox"] { width: 34px; height: 20px; appearance: none; -webkit-appearance: none; border-radius: 99px; background: var(--fill); position: relative; cursor: pointer; flex: none; margin-top: 2px; box-shadow: none; transition: background .15s; }
.switch input[type="checkbox"]::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: left .15s; box-shadow: 0 1px 2px oklch(0% 0 0 / .3); }
.switch input[type="checkbox"]:checked { background: var(--brand); }
.switch input[type="checkbox"]:checked::after { left: 16px; }
.gloss-row { display: grid; grid-template-columns: 1fr 120px 1fr auto; gap: 8px; margin: 6px 0; }
.cmp { width: 100%; border-collapse: separate; border-spacing: 0; }
.cmp td { vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--hairline); font-size: 13.5px; }
.cmp td.src { width: 45%; color: var(--subtle); }
.cmp td.tr textarea { min-height: 60px; font-size: 13.5px; }
.cmp tr.manual td.tr { box-shadow: inset 3px 0 0 var(--success); }
.models3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.models3 .card { margin: 0; }
.models3 .out { white-space: pre-wrap; min-height: 80px; }
@container content (max-width: 760px) { .models3 { grid-template-columns: 1fr; } .gloss-row { grid-template-columns: 1fr 1fr; } }
.codeblock { position: relative; }
.codeblock button { position: absolute; top: 8px; right: 8px; }
.dnsbox { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; margin: 10px 0; }
.dnsbox > div { background: var(--recessed); border: 1px solid var(--hairline); border-radius: var(--radius); padding: 10px 12px; }
.dnsbox small { display: block; color: var(--subtle); font-size: 11.5px; }
@container app (max-width: 820px) { .quicksearch kbd { display: none; } }

/* ---- Public tools page ---- */
body.public header.top { justify-content: space-between; }
.tools-main { max-width: 1100px; margin: 0 auto; padding: 32px 20px 80px; }
.hero h1 { font-size: 34px; letter-spacing: -.03em; margin: 12px 0 6px; }
.hero p { font-size: 16px; margin: 0 0 8px; }
.tabs button .ic { vertical-align: -3px; }
.preview-frame { border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: #fff; margin: 12px 0; }
.preview-frame iframe { width: 100%; height: 640px; border: 0; display: block; }
.cta { display: flex; align-items: center; gap: 16px; justify-content: space-between; padding: 16px 20px; margin: 16px 0; border-radius: var(--radius-lg);
  border: 1px solid color-mix(in srgb, var(--accent) 40%, var(--line)); background: color-mix(in srgb, var(--accent) 8%, var(--base)); flex-wrap: wrap; }
a.primary-link { background: var(--brand); color: #fff; box-shadow: none; }
a.primary-link:hover { background: var(--brand-hover); }
.card.score { display: flex; align-items: center; gap: 20px; }
.ring { width: 92px; height: 92px; border-radius: 50%; display: grid; place-items: center; align-content: center; border: 6px solid; flex: none; }
.ring b { font-size: 28px; line-height: 1; } .ring small { color: var(--subtle); font-size: 11px; }
.ring.good { border-color: var(--success); } .ring.warn { border-color: var(--warning); } .ring.bad { border-color: var(--danger); }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-top: 5px; }
.dot.pass { background: var(--success); } .dot.warn { background: var(--warning); } .dot.fail { background: var(--danger); }
.fix { display: inline-flex; gap: 6px; color: var(--success); } .fix .ic { flex: none; margin-top: 2px; }
.card.reach { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card.reach > div { display: flex; flex-direction: column; gap: 4px; }
.card.reach b { font-size: 28px; font-weight: 500; letter-spacing: -.02em; } .card.reach b.plus { color: var(--success); }
.reach-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 6px; }
.market { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--base); cursor: pointer; font-size: 13px; }
.market small { margin-left: auto; color: var(--subtle); } .market.on { border-color: var(--brand); background: var(--info-tint); }
@container content (max-width: 760px) { .card.reach { grid-template-columns: 1fr; } .hero h1 { font-size: 26px; } .preview-frame iframe { height: 480px; } }
.codeblock pre { padding-right: 84px; white-space: pre-wrap; word-break: break-all; }
.newtag { margin-left: auto; font-size: 10.5px; font-weight: 600; line-height: 1; letter-spacing: .02em; padding: 3px 7px; border-radius: 99px; background: var(--success-tint); color: var(--success); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--success) 35%, transparent); }
.mdflow { list-style: none; padding: 0; margin: 12px 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.mdflow li { display: flex; gap: 10px; padding: 12px; border: 1px solid var(--hairline); border-radius: var(--radius); background: var(--recessed); }
.mdflow .step { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 600; background: var(--brand); color: #fff; }
.mdpreview { margin-top: 10px; }
.mdmeta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 8px; }
.mdmeta .spacer { flex: 1; }
.mdraw { max-height: 420px; overflow: auto; white-space: pre-wrap; word-break: break-word; font-size: 12.5px; line-height: 1.55; padding: 12px; border-radius: var(--radius); background: var(--recessed); border: 1px solid var(--hairline); margin: 0; }
.mdrendered { max-height: 420px; overflow: auto; padding: 12px 16px; border-radius: var(--radius); border: 1px solid var(--hairline); }
.card > .sectionhead:first-child { margin-top: 0; }
.card .stats { margin: 8px 0 12px; }
.md h1, .md h2, .md h3, .md h4, .md h5, .md h6 { margin: 1em 0 .4em; color: var(--strong); line-height: 1.3; }
.md h1 { font-size: 22px; } .md h2 { font-size: 18px; } .md h3 { font-size: 16px; } .md h4, .md h5, .md h6 { font-size: 14px; }
.md > :first-child { margin-top: 0; }
.md blockquote { margin: .8em 0; padding: 2px 12px; border-left: 3px solid var(--line); color: var(--subtle); }
.md hr { border: 0; border-top: 1px solid var(--hairline); margin: 1em 0; }
.md .mdcode { padding: 10px 12px; border-radius: var(--radius); background: var(--recessed); overflow: auto; font-size: 12.5px; }
.md .mdtable { overflow-x: auto; margin: .8em 0; }
.md .mdtable table { border-collapse: collapse; font-size: 13px; }
.md .mdtable th, .md .mdtable td { border: 1px solid var(--hairline); padding: 5px 9px; text-align: left; }
.md .mdimg { display: inline-block; font-size: 12px; padding: 1px 8px; border-radius: 99px; background: var(--fill); color: var(--subtle); }

/* ---- Scrollbars: thin everywhere ---- */
* { scrollbar-width: thin; scrollbar-color: color-mix(in srgb, var(--subtle) 45%, transparent) transparent; }
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: color-mix(in srgb, var(--subtle) 45%, transparent); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: color-mix(in srgb, var(--subtle) 70%, transparent); }
::-webkit-scrollbar-corner { background: transparent; }

/* ---- Dashboard shell: header and sidebar never move; only the content scrolls.
   The Ask AI panel is a full-height column next to the app, so opening it narrows the header too. ---- */
html:has(body.app) { height: 100%; overflow: hidden; overscroll-behavior: none; }
body.app { height: 100%; height: 100dvh; overflow: hidden; overscroll-behavior: none; display: flex; }
body.app .app-col { flex: 1; min-width: 0; display: flex; flex-direction: column; height: 100%; container: app / inline-size; }
body.app header.top { position: relative; flex: none; }
body.app .layout { flex: 1; min-height: 0; }
body.app nav.side { position: static; height: 100%; overscroll-behavior: contain; }
body.app .scroller { min-width: 0; height: 100%; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
body.app .assistant { position: relative; top: auto; right: auto; bottom: auto; flex: none; height: 100%; width: 0; transform: none;
  border-left: 0; overflow: hidden; box-shadow: none; z-index: 30; visibility: hidden; }
body.app .assistant.open { width: 400px; border-left: 1px solid var(--line); box-shadow: none; visibility: visible; }
@container app (max-width: 820px) {
  .layout { grid-template-rows: auto minmax(0, 1fr); }
  nav.side { height: auto; }
}
/* Below 1024px the panel doesn't squeeze the page: it slides over it. */
@media (max-width: 1023px) {
  body.app .assistant { position: fixed; inset: 0 0 0 auto; z-index: 50; }
  body.app .assistant.open { width: min(420px, 100vw); box-shadow: -16px 0 40px oklch(0% 0 0 / .22); }
}

/* ---- Tips / notifications ---- */
.iconbtn { position: relative; }
.dot-badge { position: absolute; top: 6px; right: 7px; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 2px var(--canvas); }
.tips-pop { width: min(380px, calc(100vw - 24px)); max-height: 70vh; overflow-y: auto; padding: 0; }
.tips-pop .pop-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px; margin: 0; }
.tips-pop .pop-head b { flex: 1; }
.tip { display: flex !important; gap: 10px; align-items: flex-start !important; padding: 12px 14px !important; border-radius: 0 !important; border-bottom: 1px solid var(--hairline) !important; width: 100%; }
.tip:last-child { border-bottom: 0 !important; }
.tip .tip-ic { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: var(--info-tint); color: var(--brand); flex: none; }
.tip b { display: block; font-weight: 500; color: var(--strong); font-size: 13.5px; }
.tip span { display: block; color: var(--subtle); font-size: 12.5px; line-height: 1.45; }
.tip.unseen b::after { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); margin-left: 6px; vertical-align: 2px; }
.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 60; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.toast { pointer-events: auto; width: min(400px, calc(100vw - 32px)); background: var(--base); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: 0 18px 44px oklch(0% 0 0 / .28); padding: 14px 14px 12px; display: grid; grid-template-columns: auto 1fr auto; gap: 4px 12px; }
.toast .tip-ic { grid-row: span 2; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: var(--brand); color: #fff; box-shadow: inset 0 1px 0 oklch(100% 0 0 / .2); }
.toast .tip-ic .ic { width: 18px; height: 18px; }
.toast b { color: var(--strong); font-weight: 500; }
.toast p { margin: 0; grid-column: 2 / 4; color: var(--subtle); font-size: 13px; }
.toast .toast-actions { grid-column: 2 / 4; display: flex; gap: 8px; margin-top: 8px; }
.toast .toast-actions button { min-height: 30px; padding: 0 12px; font-size: 13px; }
@keyframes toast-in { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---- Cookie consent ---- */
.consent { position: fixed; left: 16px; bottom: 16px; z-index: 70; width: min(440px, calc(100vw - 32px)); background: var(--base); color: var(--text);
  border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: 0 18px 44px oklch(0% 0 0 / .3); padding: 16px 18px; font-size: 13px; }
.consent-head { display: flex; align-items: center; gap: 8px; color: var(--strong); font-size: 14px; }
.consent p { color: var(--subtle); margin: 6px 0 10px; }
.consent-actions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
.consent-settings { margin-bottom: 8px; }

/* ---- Plans & pricing ---- */
.billing-toggle { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 18px 0 6px; }
.save-tag { font-size: 11.5px; font-weight: 600; color: var(--success); background: var(--success-tint); padding: 2px 8px; border-radius: 99px; }
.plan-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin: 16px 0; }
.plan { position: relative; display: flex; flex-direction: column; gap: 12px; background: var(--base); border: 1px solid var(--line); border-radius: 14px; padding: 20px 20px 18px; }
.plan.featured { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand), 0 14px 36px color-mix(in srgb, var(--brand) 18%, transparent); }
.plan.current { background: var(--elevated); }
.plan .ribbon { position: absolute; top: -11px; left: 18px; font-size: 11px; font-weight: 600; letter-spacing: .02em; padding: 3px 10px; border-radius: 99px; background: var(--brand); color: #fff; }
.plan .ribbon.alt { background: var(--success); }
.plan h3 { margin: 0; font-size: 15px; font-weight: 600; color: var(--strong); }
.plan .for { color: var(--subtle); font-size: 12.5px; margin-top: -8px; }
.plan .price { display: flex; align-items: baseline; gap: 4px; color: var(--strong); }
.plan .price b { font-size: 30px; font-weight: 600; letter-spacing: -.03em; }
.plan .price small { color: var(--subtle); font-size: 13px; }
.plan .billed { color: var(--subtle); font-size: 12px; margin-top: -8px; min-height: 1.5em; }
.plan ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 7px; font-size: 13px; }
.plan li { display: flex; gap: 8px; align-items: flex-start; }
.plan li .ic { color: var(--success); width: 15px; height: 15px; margin-top: 2px; }
.plan .cta-row { margin-top: auto; padding-top: 6px; display: flex; flex-direction: column; gap: 6px; }
.plan .cta-row button { width: 100%; }
.trust { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; color: var(--subtle); font-size: 12.5px; margin: 6px 0 18px; }
.trust span { display: inline-flex; align-items: center; gap: 6px; } .trust .ic { color: var(--success); width: 14px; height: 14px; }

.contact-card { display: flex; align-items: center; gap: 12px 18px; flex-wrap: wrap; padding: 20px 22px; border-radius: 14px; margin: 16px 0;
  background: var(--brand); color: #fff; box-shadow: inset 0 1px 0 oklch(100% 0 0 / .18), inset 0 0 0 1px oklch(0% 0 0 / .08); }
.contact-card .txt { flex: 1; min-width: 240px; } .contact-card b { font-size: 17px; font-weight: 600; display: block; } .contact-card span { opacity: .92; font-size: 13.5px; }
.contact-card .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.contact-card button { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 14px; border: 0; border-radius: var(--radius); font-weight: 500; cursor: pointer;
  background: #fff; color: oklch(30% .12 262); box-shadow: 0 1px 2px oklch(0% 0 0 / .15); transition: background-color .1s, transform .1s; }
.contact-card button:hover { background: oklch(96% .02 255); }
.contact-card button.ghostw { background: transparent; color: #fff; box-shadow: inset 0 0 0 1px oklch(100% 0 0 / .55); }
.contact-card button.ghostw:hover { background: oklch(100% 0 0 / .1); }
.contact-card button:focus-visible { outline-color: #fff; }
.notice.warn { background: var(--warning-tint); color: var(--warning); border-color: transparent; }
@container app (max-width: 820px) {
  header.top { gap: 4px; padding: 0 10px; }
  header.top .spacer { display: none; }
  .head-left { flex: 1 1 auto; min-width: 0; }
}

/* ---- Sidebar groups: collapsible headings (remembered for 30 days) ---- */
/* Groups read like pages: icon, name and a chevron; their pages hang off a guide line. */
nav.side .navgroup { display: flex; flex-direction: column; }
nav.side button.navhead { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: var(--radius); font-size: inherit; font-weight: 400;
  text-transform: none; letter-spacing: inherit; color: var(--text); background: none; }
nav.side button.navhead:hover { background: var(--tint); }
nav.side button.navhead .chev { width: 14px; height: 14px; margin-left: auto; transform: rotate(180deg); transition: transform .18s ease; opacity: .6; }
nav.side .navgroup.collapsed button.navhead .chev { transform: rotate(90deg); }
nav.side .navgroup.has-active:not(.collapsed) > button.navhead { color: var(--strong); }
nav.side .navitems { display: grid; grid-template-rows: 1fr; transition: grid-template-rows .18s ease; }
nav.side .navitems > .sub { min-height: 0; overflow: hidden; display: flex; flex-direction: column; gap: 1px; margin-left: 17px; padding: 2px 0 6px 8px; border-left: 1px solid var(--line); }
nav.side .navgroup.collapsed .navitems { grid-template-rows: 0fr; }
nav.side .navgroup.collapsed .navitems > .sub { visibility: hidden; transition: visibility 0s .18s; }
nav.side .sub a.navitem { padding: 6px 10px; }
nav.side .sub a.navitem > .ic { display: none; }
nav.side .sub a.navitem.active { box-shadow: none; background: var(--recessed); }
nav.side a.navitem:focus-visible, nav.side a.recent:focus-visible { outline-offset: -2px; }
nav.side .recent { display: flex; flex-direction: column; align-items: flex-start; gap: 0; padding: 5px 10px; }
nav.side .recent span { font-size: 13.5px; line-height: 1.35; }
nav.side .recent small { font-size: 11.5px; color: var(--subtle); line-height: 1.3; }
.newtag.soon { background: var(--info-tint); color: var(--brand); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 35%, transparent); }
@container app (max-width: 820px) {
  nav.side .navgroup, nav.side .navitems, nav.side .navitems > .sub { display: contents; }
  nav.side .sub a.navitem > .ic { display: inline; }
  nav.side button.navhead, nav.side .recents { display: none !important; }
}

/* ---- Settings ---- */
.setlayout { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 24px; align-items: start; margin-top: 8px; }
.settoc { position: sticky; top: 0; display: flex; flex-direction: column; gap: 2px; padding-top: 16px; }
.settoc a { color: var(--subtle); padding: 6px 10px; border-radius: var(--radius); font-size: 13.5px; }
.settoc a:hover { background: var(--tint); color: var(--text); text-decoration: none; }
.setsec { scroll-margin-top: 16px; }
.sethead { margin-bottom: 6px; } .sethead h2 { margin: 0 0 2px; } .sethead p { margin: 0; }
.setrow { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; border-top: 1px solid var(--hairline); flex-wrap: wrap; }
.setrow b { font-weight: 500; color: var(--strong); }
.setrow .segmented button { display: inline-flex; align-items: center; gap: 6px; }
.setrow .segmented .ic { width: 14px; height: 14px; }
h3.subhead { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; letter-spacing: .04em; color: var(--subtle); margin: 18px 0 2px; }
h3.subhead .ic { width: 14px; height: 14px; }
.subcard { border-top: 1px solid var(--hairline); padding: 4px 0 8px; }
.swmsg { font-weight: 400; }
@container content (max-width: 760px) { .setlayout { grid-template-columns: 1fr; } .settoc { position: static; flex-direction: row; flex-wrap: wrap; padding-top: 0; } }

/* ---- Hosted preview ---- */
.pv { margin: 12px 0; }
.pv-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.pv-bar .spacer { flex: 1; }
.pv-timer { font-variant-numeric: tabular-nums; }
.pv .preview-frame { position: relative; min-height: 200px; }
.pv-ended { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 260px; padding: 32px; text-align: center; color: var(--text); background: var(--base); }
.pv-ended .ic { width: 28px; height: 28px; color: var(--subtle); }
.pv-ended-page { min-height: 60vh; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.pv-src { word-break: break-all; }
.pv-live { display: inline-flex; align-items: center; gap: 7px; color: var(--subtle); transition: opacity .3s; }
.pv-live .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: pv-pulse 1.1s ease-in-out infinite; }
.pv-live.idle .dot { background: var(--success); animation: none; }
.pv-live.limit .dot { background: var(--warning); animation: none; }
@keyframes pv-pulse { 50% { opacity: .25; transform: scale(.8); } }
.pv-loading { display: flex; align-items: center; gap: 10px; }
.pv-spinner { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--fill); border-top-color: var(--accent); animation: pv-spin .7s linear infinite; flex: none; }
@keyframes pv-spin { to { transform: rotate(360deg); } }
.pv-limit { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (prefers-reduced-motion: reduce) { .pv-live .dot, .pv-spinner { animation: none; } }
body.hosted header.top { position: sticky; }
.pv-meta { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding-left: 12px; }
.pv-main { padding: 12px 16px 24px; max-width: none; }
.pv-main .preview-frame iframe { height: calc(100dvh - 120px); }
@media (max-width: 760px) { .pv-meta { display: none; } }

/* ---- Models: one row per model ---- */
.model-rows { padding: 0; overflow: hidden; }
.model-rows table { min-width: 960px; }
.model-rows td.small:nth-child(2), .model-rows .price, .model-rows td:nth-child(4), .model-rows td:nth-child(6) { white-space: nowrap; }
.model-rows td:nth-child(6) .muted { font-size: 12px; }
.model-rows td { vertical-align: middle; padding-top: 12px; padding-bottom: 12px; }
.model-rows td:first-child { padding-left: 18px; } .model-rows td:last-child { padding-right: 18px; }
.model-rows .tier { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.model-rows .tier b { color: var(--strong); font-weight: 500; }
.model-ic { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; background: var(--info-tint); color: var(--brand); flex: none; }
.model-ic .ic { width: 15px; height: 15px; }
.model-rows .price b { font-weight: 600; color: var(--strong); font-variant-numeric: tabular-nums; }
.model-rows .use { min-width: 200px; max-width: 280px; color: var(--subtle); }
.model-rows .id { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.model-rows .id button { min-height: 26px; padding: 0 8px; font-size: 12px; }
.model-rows tr.planned td { color: var(--subtle); }
.q-up { color: var(--success); } .q-down { color: var(--subtle); }
nav.side a.recent { color: var(--text); text-decoration: none; border-radius: var(--radius); }
nav.side a.recent:hover { background: var(--tint); text-decoration: none; }

/* Website → Switcher & notices: sketch of a page with the visitor UI */
.uiprev { margin: 14px 0 18px; border: 1px solid var(--hairline); border-radius: 12px; overflow: hidden; background: var(--base); max-width: 560px; }
.uiprev-page { position: relative; height: 170px; padding: 14px 16px; }
.uiprev-nav { height: 10px; width: 40%; border-radius: 99px; background: var(--fill); margin-bottom: 18px; }
.uiprev-lines span { display: block; height: 8px; border-radius: 99px; background: var(--fill); margin: 9px 0; }
.uiprev-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-top: 1px solid var(--hairline); font-size: 11px; color: var(--subtle); min-height: 46px; }
.uiprev-credit u { text-underline-offset: 2px; }
.uiprev em { font-style: normal; opacity: .6; }
.uiprev-pill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 99px; border: 1px solid var(--hairline); background: var(--base); color: var(--strong); font-size: 11px; font-weight: 500; white-space: nowrap; }
.uiprev-pill.dark { background: #262628; color: #f4f4f5; border-color: #3a3a3c; }
.uiprev-pill i { font-style: normal; opacity: .6; }
.uiprev-pill .ic { width: 12px; height: 12px; }
.uiprev-page { height: 200px; }
.uiprev-dock { position: absolute; left: 12px; right: 12px; bottom: 10px; display: flex; flex-direction: column; gap: 6px; }
.uiprev-pill.corner { align-self: flex-start; order: 3; box-shadow: var(--shadow); }
.uiprev-card { display: inline-flex; align-items: center; gap: 8px; padding: 6px 8px 6px 11px; border-radius: 10px; font-size: 10.5px; background: var(--base); border: 1px solid var(--hairline); box-shadow: var(--shadow); color: var(--strong); white-space: nowrap; }
.uiprev-card b { padding: 3px 8px; border-radius: 99px; background: var(--strong); color: var(--base); font-weight: 600; }
.uiprev-card.prompt { align-self: center; order: 2; }
.uiprev-card.bottom-right { align-self: flex-end; order: 1; }
.uiprev-card.bottom-left { align-self: flex-start; order: 1; }
.uiprev-card.top { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); }
.uiform { display: grid; gap: 16px; }
.uiform > div > b { display: block; font-weight: 500; color: var(--strong); margin-bottom: 6px; }
.uiform .segmented { flex-wrap: wrap; }
@media (prefers-reduced-motion: no-preference) { .uiprev-pill, .uiprev-card { transition: all .2s ease; } }

/* ---- Globe cards: solid blue card in a darker frame, hatched globe behind the content ---- */
:root { --globe-fill: #1100ff; --globe-frame: oklch(89% .035 258); --globe-ink: .5; }
:root[data-theme="dark"] { --globe-fill: #1100ff; --globe-frame: oklch(18% 0 0); --globe-ink: .42; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --globe-fill: #1100ff; --globe-frame: oklch(18% 0 0); --globe-ink: .42; } }
.globe-frame { padding: 5px; border-radius: 21px; background: var(--globe-frame); box-shadow: inset 0 0 0 1px oklch(100% 0 0 / .07); }
.globe-card { position: relative; isolation: isolate; overflow: hidden; height: 100%; border-radius: 15px; background: var(--globe-fill); color: #fff;
  box-shadow: inset 0 0 0 1px oklch(100% 0 0 / .16), inset 0 0 26px oklch(100% 0 0 / .16), 0 10px 28px -14px var(--globe-fill); }
.globe-card.lined::before { content: ""; position: absolute; left: 0; right: 0; top: 18%; height: 1px; z-index: 1; pointer-events: none;
  background: oklch(0% 0 0 / .16); box-shadow: 0 1px 0 oklch(100% 0 0 / .12); }
.globe-card > canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; opacity: 0; transition: opacity .4s ease; pointer-events: none; }
.globe-card > canvas.on { opacity: var(--globe-ink); }
.globe-card > :not(canvas) { position: relative; z-index: 2; }

/* Empty states with a small globe */
.empty { display: flex; align-items: center; gap: 18px; padding: 14px; }
.empty .globe-frame { width: 132px; height: 104px; flex: none; }
.empty .txt { flex: 1; min-width: 200px; }
.empty .txt b { display: block; color: var(--strong); font-weight: 500; font-size: 15px; }
.empty .txt p { margin: 2px 0 10px; color: var(--subtle); font-size: 13px; }
@container content (max-width: 480px) { .empty { flex-wrap: wrap; } }

/* Website preview while translating */
.pv-busy { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 16px; align-items: center; margin: 12px 0; }
.pv-busy .globe-frame { height: 132px; }
.pv-busy b { display: block; color: var(--strong); font-weight: 500; }
@container content (max-width: 480px) { .pv-busy { grid-template-columns: 1fr; } }

/* Sign in: form first, the globe beside it on wide screens and below it on phones */
.auth { max-width: none; min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: minmax(0, 400px) minmax(0, 480px); gap: 56px; align-items: center; justify-content: center; padding: 40px 24px; }
.auth .center { margin: 0; max-width: none; padding: 0; }
.auth-hero { height: min(560px, calc(100dvh - 80px)); }
.auth-hero .globe-frame, .empty .globe-frame > .globe-card { height: 100%; }
.auth-hero .globe-card { padding: 28px 30px; }
.auth-hero h2 { margin: 0 0 6px; font-size: 26px; line-height: 1.15; font-weight: 600; letter-spacing: -.025em; color: #fff; max-width: 15ch; }
.auth-hero p { margin: 0; max-width: 34ch; font-size: 14px; opacity: .9; }
@media (max-width: 899px) {
  .auth { grid-template-columns: minmax(0, 420px); gap: 24px; align-content: start; padding: 10vh 16px 32px; }
  .auth-hero { height: 220px; }
  .auth-hero .globe-card { padding: 20px 22px; }
  .auth-hero h2 { font-size: 20px; }
}

/* Loading skeletons (shown only when a page takes longer than a moment) */
.skel { display: block; border-radius: 6px; background: var(--fill); }
.skel-title { width: 220px; height: 26px; margin: 22px 0 10px; }
.skel-line { width: 420px; max-width: 80%; height: 12px; margin: 0 0 22px; }
.skel-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin: 16px 0; }
.skel-tile { height: 92px; border-radius: var(--radius-lg); }
.skel-card { height: 220px; border-radius: var(--radius-lg); }

/* ---- Motion: short, transform/opacity only, off for reduced motion ---- */
@media (prefers-reduced-motion: no-preference) {
  button.primary:active, button.secondary:active, button.danger:active, button.ghost:active, button.accent:active,
  a.button:active, .iconbtn:active, .toplink:active, .as-send:active, .contact-card button:active, .segmented button:active { transform: scale(.97); }
  .skel { animation: skel-pulse 1.1s ease-in-out infinite alternate; }
  dialog.dialog[open], dialog.palette[open] { animation: dlg-in .16s cubic-bezier(.2, .8, .2, 1); }
  dialog.dialog[open]::backdrop, dialog.palette[open]::backdrop { animation: fade-in .16s ease-out; }
  .popover:not(.hidden) { animation: pop-in .12s ease-out; transform-origin: top right; }
  body.app .assistant.open > * { animation: as-in .18s cubic-bezier(.2, .8, .2, 1); }
  .toast { animation: toast-in .18s cubic-bezier(.2, .8, .2, 1); }
  .toast.out { animation: toast-out .14s ease-in forwards; }
  #view.enter { animation: view-in .16s ease-out; }
  .scroller { view-transition-name: content; }
  ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
  ::view-transition-old(content) { animation: fade-out .1s ease-in both; }
  ::view-transition-new(content) { animation: view-in .16s ease-out both; }
}
@media (prefers-reduced-motion: no-preference) and (max-width: 1023px) {
  body.app .assistant.open { animation: sheet-in .2s cubic-bezier(.2, .8, .2, 1); }
  body.app .assistant.open > * { animation: none; }
}
@media (prefers-reduced-motion: reduce) {
  nav.side .navitems, .progress > span, .globe-card > canvas { transition: none; }
}
@keyframes skel-pulse { from { opacity: .55; } to { opacity: 1; } }
@keyframes dlg-in { from { opacity: 0; transform: translateY(6px) scale(.98); } }
@keyframes pop-in { from { opacity: 0; transform: scale(.97); } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes fade-out { to { opacity: 0; } }
@keyframes as-in { from { opacity: 0; transform: translateX(14px); } }
@keyframes sheet-in { from { transform: translateX(100%); } }
@keyframes view-in { from { opacity: 0; transform: translateY(4px); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(8px); } }

/* ---- Header balance (left, beside the organization) ---- */
.headbal { display: inline-flex; align-items: center; gap: 8px; margin-left: 6px; padding: 5px 10px; border-radius: var(--radius); color: var(--subtle); font-size: 13px; white-space: nowrap; }
.headbal:hover { background: var(--tint); text-decoration: none; color: var(--text); }
.headbal b { color: var(--strong); font-weight: 500; font-variant-numeric: tabular-nums; }
.headbal .pill { font-size: 11px; padding: 1px 8px; }
.headbal.low b { color: var(--warning); }
@container app (max-width: 980px) { .headbal .pill, .headbal-label { display: none; } }
@container app (max-width: 560px) { .headbal { display: none; } }

/* ---- Recommendations: one in full, the next fading out, "Show all" ---- */
.recs ul { background: none; border-top: 1px solid var(--hairline); padding: 6px 18px 4px; }
.recs li { padding: 9px 0 9px 20px; }
.recs li + li { border-top: 0; }
.recs li::before { top: 16px; }
.recs li span a, .recs li span button.link { color: var(--text); text-decoration-color: color-mix(in srgb, var(--text) 45%, transparent); }
.recs.folded li:nth-child(n+3) { display: none; }
.recs.folded li:nth-child(2) { max-height: 30px; overflow: hidden; -webkit-mask-image: linear-gradient(#000, transparent); mask-image: linear-gradient(#000, transparent); pointer-events: none; }
.recs.folded li:nth-child(2) * { visibility: visible; }
.recs-more { display: block; width: 100%; padding: 8px 0 12px; border: 0; background: none; color: var(--text); font: inherit; font-size: 13.5px; font-weight: 500; cursor: pointer; }
.recs-more:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---- Accessibility ---- */
.skiplink { position: fixed; left: 12px; top: -60px; z-index: 100; padding: 8px 14px; border-radius: var(--radius); background: var(--strong); color: var(--base); font-weight: 500; }
.skiplink:focus { top: 10px; text-decoration: none; }
#view:focus { outline: none; }
html[data-text="large"] :is(main, nav.side, header.top, .assistant > *, dialog) { zoom: 1.08; }
html[data-text="larger"] :is(main, nav.side, header.top, .assistant > *, dialog) { zoom: 1.18; }
html[data-contrast="more"] { --subtle: oklch(40% 0 0); --placeholder: oklch(52% 0 0); --line: oklch(14.5% 0 0 / .28); --hairline: oklch(82% 0 0); }
html[data-contrast="more"][data-theme="dark"] { --subtle: oklch(84% 0 0); --placeholder: oklch(70% 0 0); --line: oklch(52% 0 0); --hairline: oklch(40% 0 0); }
@media (prefers-color-scheme: dark) { html[data-contrast="more"]:not([data-theme="light"]) { --subtle: oklch(84% 0 0); --placeholder: oklch(70% 0 0); --line: oklch(52% 0 0); --hairline: oklch(40% 0 0); } }
html[data-underline] a:not(.button):not(.navitem):not(.navlink):not(.recent):not(.brand):not(.headbal) { text-decoration: underline; text-underline-offset: 2px; }
html[data-motion="reduce"] *, html[data-motion="reduce"] *::before, html[data-motion="reduce"] *::after { animation-duration: 0s !important; animation-iteration-count: 1 !important; transition-duration: 0s !important; scroll-behavior: auto !important; }
html[data-motion="reduce"] .scroller { view-transition-name: none; }

/* Info tooltips */
.infotip-wrap { display: inline-flex; vertical-align: middle; margin-left: 4px; }
.infotip { display: inline-grid; place-items: center; width: 18px; height: 18px; padding: 0; border: 0; border-radius: 99px; background: none; color: var(--subtle); cursor: help; }
.infotip:hover, .infotip:focus-visible { color: var(--text); background: var(--tint); }
.infotip .ic { width: 14px; height: 14px; vertical-align: 0; }
.tip-bubble { position: fixed; z-index: 90; display: none; padding: 8px 11px; border-radius: var(--radius); background: var(--strong); color: var(--base); font-size: 12.5px; font-weight: 400; line-height: 1.45;
  letter-spacing: 0; text-transform: none; box-shadow: 0 8px 24px oklch(0% 0 0 / .25); pointer-events: none; text-align: left; white-space: normal; }
.tip-bubble.on { display: block; }
@media (prefers-reduced-motion: no-preference) { .tip-bubble.on { animation: fade-in .12s ease-out; } }

/* ---- Banner: a fixed-size card that never stretches ---- */
.banner { padding: 10px 14px 10px 10px; gap: 16px; }
.banner .banner-art { width: 96px; height: 68px; min-height: 0; align-self: center; padding: 3px; border-radius: 12px; }
.banner .banner-art .globe-card { border-radius: 9px; padding: 8px 10px; }
.banner .banner-art b { font-size: 19px; }
.banner .banner-art small { font-size: 10.5px; }
.banner .txt b { font-size: 14.5px; }
@container content (max-width: 560px) { .banner { flex-wrap: wrap; } .banner .txt { flex: 1 1 calc(100% - 140px); } }

/* ---- Ask AI: dots behind everything below the header, glyph with a moving blue dot field ---- */
body.app .assistant { background-color: var(--canvas); background-image: radial-gradient(var(--hairline) 1px, transparent 1px); background-size: 14px 14px; background-position: 0 var(--header); }
.as-hero { position: relative; height: 170px; display: grid; place-items: center; margin: 0 -16px; }
.as-halo { position: absolute; inset: 0; width: 100%; height: 100%; }
.as-hero .as-logo { position: relative; height: 64px; filter: drop-shadow(0 6px 14px oklch(0% 0 0 / .25)); }
@media (prefers-reduced-motion: no-preference) {
  .as-hero .as-logo { animation: glyph-float 5s ease-in-out infinite; }
  .as-sugg button:hover { transform: translateY(-1px); }
}
@keyframes glyph-float { 50% { transform: translateY(-4px); } }
.as-sugg button:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); background: var(--base); }
.as-sugg small { font-size: 12px; }
.as-ic { background: var(--tint); border-color: var(--hairline); }

/* ---- Websites ---- */
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 18px 0 12px; }
.searchbox { display: flex; align-items: center; gap: 8px; min-width: 220px; padding: 0 10px; border-radius: var(--radius); background: var(--base); box-shadow: 0 0 0 1px var(--line); color: var(--subtle); }
.searchbox:focus-within { box-shadow: 0 0 0 1.5px var(--brand); }
.searchbox input { flex: 1; min-width: 0; box-shadow: none; padding-left: 0; background: none; }
.searchbox input:focus { box-shadow: none; }
.listcard { padding: 0; overflow: hidden; }
.listcard-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 18px; border-bottom: 1px solid var(--line); color: var(--subtle); }
.listcard-head b { color: var(--strong); font-weight: 500; }
.listcard > .table-wrap { margin: 0; }
.listcard td:first-child, .listcard th:first-child { padding-left: 18px; }
.meter { width: 140px; height: 6px; border-radius: 99px; background: var(--fill); overflow: hidden; flex: none; }
.meter i { display: block; height: 100%; width: 100%; background: var(--brand); clip-path: inset(0 calc(100% - var(--p, 0%)) 0 0 round 99px); }
a.rowlink { color: var(--strong); font-weight: 500; }
@container content (max-width: 560px) { .meter { display: none; } }

/* Add-website dialog */
dialog.dialog.wide { width: min(720px, calc(100vw - 32px)); max-height: calc(100dvh - 48px); }
dialog.dialog .dhead { font-size: 18px; padding: 18px 22px; }
dialog.dialog.wide .dbody { padding: 18px 22px 22px; }
.readback { margin: 0 0 18px; font-size: 15px; line-height: 1.6; color: var(--text); }
.readback span { color: var(--strong); font-weight: 500; }
.readback .ph { color: var(--subtle); font-weight: 400; }
.choices { border: 0; padding: 0; margin: 0 0 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.choices legend { padding: 0; margin-bottom: 8px; font-size: 12px; font-weight: 500; color: var(--subtle); }
dialog.dialog .choice, .choice { display: flex; flex-direction: row; gap: 10px; align-items: flex-start; margin: 0; padding: 12px 14px; border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: var(--base); cursor: pointer; color: var(--text); font-size: 14px; font-weight: 400; }
dialog.dialog .choice > *, .choice > * { width: auto; }
.choice:has(input:checked) { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); background: var(--info-tint); }
.choice:has(input:focus-visible) { outline: 2px solid var(--focus); outline-offset: 2px; }
.choice input { margin-top: 3px; accent-color: var(--brand); min-height: 0; box-shadow: none; }
.choice b { display: block; font-weight: 500; color: var(--strong); }
.choice small { display: block; color: var(--subtle); font-size: 12.5px; margin-top: 2px; }
.fgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 12px; }
dialog.dialog .fgrid label small { font-weight: 400; color: var(--subtle); font-size: 12px; }
.langchips { margin: 2px 0 6px; }
.langchips .chip { font-size: 11px; padding: 1px 6px; }
details.advanced { margin: 14px 0 4px; border-top: 1px solid var(--hairline); padding-top: 6px; }
details.advanced > summary { font-weight: 500; color: var(--text); }
.dfoot { display: flex; gap: 8px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--hairline); }
@container content (max-width: 560px) { .choices { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .choices { grid-template-columns: 1fr; } }

/* ---- Plans: key facts only, the rest in "Compare all plans" ---- */
.plan-balance { font-size: 13.5px; padding: 10px 12px; border-radius: var(--radius); background: var(--elevated); border: 1px solid var(--hairline); }
.plan-balance b { color: var(--strong); font-weight: 600; }
.plan ul.facts { gap: 9px; }
.plan ul.facts li { align-items: center; color: var(--text); }
.plan ul.facts li .ic { color: var(--subtle); margin-top: 0; }
.plan ul.facts b { font-weight: 600; color: var(--strong); }
.plan ul.facts small { display: block; color: var(--subtle); font-size: 11.5px; }
.plan ul.facts li > span { flex: 1; }
.plan li.fresh > span { display: flex; flex-wrap: wrap; align-items: center; gap: 0 4px; }
.plan li.fresh b { margin: 0 2px; }
.freshbar { display: inline-flex; gap: 2px; margin-left: auto; padding-left: 6px; align-self: center; }
.freshbar i { width: 4px; height: 10px; border-radius: 2px; background: var(--fill); }
.freshbar i.on { background: var(--success); }

/* ---- Questions: a quiet list with chevrons ---- */
.card.faq { padding: 0; overflow: hidden; }
.faq-head { padding: 18px 22px 14px; border-bottom: 1px dashed var(--line); }
.faq-head h2 { margin: 0 0 2px; font-size: 17px; }
.faq-head p { margin: 0; }
.faq-item { border-bottom: 1px solid var(--hairline); }
.faq-item:last-child { border-bottom: 0; }
.faq-item > summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 14px 22px; color: var(--text); font-weight: 500; font-size: 14px; cursor: pointer; }
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary:hover { background: var(--elevated); color: var(--strong); }
.faq-item > summary > span { flex: 1; }
.faq-item > summary .ic { color: var(--subtle); transform: rotate(180deg); transition: transform .18s ease; }
.faq-item[open] > summary .ic { transform: none; }
.faq-item > p { margin: 0; padding: 0 22px 16px; max-width: 72ch; color: var(--subtle); font-size: 13.5px; line-height: 1.6; }
@media (prefers-reduced-motion: no-preference) { .faq-item[open] > p { animation: view-in .16s ease-out; } }
/* Plan cards: 4, 2 or 1 per row, so the four main plans never leave a gap. */
.plan-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@container content (max-width: 1040px) { .plan-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container content (max-width: 540px) { .plan-grid { grid-template-columns: 1fr; } }

/* ---- Ask AI: structure, history, full screen ---- */
.assistant .as-frame { flex: 1; min-height: 0; display: flex; }
.assistant .as-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.assistant .as-side, .assistant .as-chips { display: none; }
.as-top .spacer { flex: 1; }
.as-title-wrap { position: relative; min-width: 0; }
.as-title { display: inline-flex; align-items: center; gap: 6px; max-width: 220px; padding: 5px 8px; margin-left: -8px; border: 0; border-radius: var(--radius); background: none;
  color: var(--strong); font: inherit; font-weight: 500; cursor: pointer; }
.as-title span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.as-title:hover { background: var(--tint); }
.as-title .ic { width: 14px; height: 14px; color: var(--subtle); flex: none; }
.as-history { left: 0; right: auto; width: 290px; max-height: 60vh; overflow-y: auto; }
.as-chat { display: flex; align-items: center; border-radius: var(--radius); }
.as-chat:hover, .as-chat.on { background: var(--tint); }
.as-chat .as-chat-open { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block !important; padding: 7px 10px !important; background: none !important; }
.as-chat .as-chat-del { opacity: 0; padding: 6px !important; color: var(--subtle) !important; }
.as-chat:hover .as-chat-del, .as-chat .as-chat-del:focus-visible { opacity: 1; }
.as-chat-del .ic { width: 13px; height: 13px; }
.as-chatgroup { padding: 12px 10px 4px; font-size: 12px; font-weight: 500; color: var(--subtle); }
.as-history .as-chat button { border: 0; font: inherit; color: var(--text); cursor: pointer; text-align: left; }
.assistant .as-msg.me { white-space: pre-wrap; }
/* The access chip is a toggle */
button.chip-ro { background: var(--base); cursor: pointer; font: inherit; font-size: 12px; }
button.chip-ro:hover { color: var(--text); border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); }
button.chip-ro[aria-pressed="true"] .ic { color: var(--success); }

/* Full screen (like a chat app): chats on the left, the conversation centred */
body.app .assistant.full { position: fixed; inset: 10px; z-index: 80; width: auto !important; height: auto; border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 30px 80px oklch(0% 0 0 / .45); visibility: visible; }
body.ai-full::after { content: ""; position: fixed; inset: 0; z-index: 79; background: oklch(0% 0 0 / .45); }
@media (prefers-reduced-motion: no-preference) { body.app .assistant.full { animation: dlg-in .18s cubic-bezier(.2, .8, .2, 1); } body.app .assistant.full > * { animation: none; } }
.assistant.full .as-top { border-radius: 14px 14px 0 0; }
.assistant.full .as-title { cursor: default; }
.assistant.full .as-title:hover { background: none; }
.assistant.full .as-side { display: flex; flex-direction: column; gap: 2px; width: 260px; flex: none; padding: 10px; border-right: 1px solid var(--line); background: var(--canvas); overflow-y: auto; }
.as-side-head { display: none; }
.as-side-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 0; border-radius: var(--radius); background: none; color: var(--text); font: inherit; cursor: pointer; text-align: left; }
.as-side-item:hover { background: var(--tint); }
.as-side-search { display: flex; align-items: center; gap: 10px; padding: 0 10px; margin: 2px 0 6px; border-radius: var(--radius); color: var(--subtle); }
.as-side-search:focus-within { box-shadow: 0 0 0 1.5px var(--brand); }
.as-side-search input { flex: 1; min-width: 0; padding-left: 0; box-shadow: none; background: none; }
.as-side-search input:focus { box-shadow: none; }
.as-chatlist .as-chat button { border: 0; font: inherit; color: var(--text); cursor: pointer; text-align: left; background: none; border-radius: var(--radius); }
.assistant.full .as-help { display: none; }
.assistant.full .as-body, .assistant.full .as-input, .assistant.full .as-chips { width: min(780px, calc(100% - 48px)); margin-left: auto; margin-right: auto; }
.assistant.full .as-body { padding: 16px 0; }
.assistant.full .as-input { margin-bottom: 20px; }
.assistant.full .as-input textarea { min-height: 64px; font-size: 15px; }
/* Empty full screen: glyph, question and the input in the middle, three suggestions under it */
.assistant.full.is-empty .as-main { justify-content: center; }
.assistant.full.is-empty .as-body { flex: none; overflow: visible; }
.assistant.full.is-empty .as-sugg { display: none; }
.assistant.full.is-empty .as-hello h3 { font-size: 30px; font-weight: 600; letter-spacing: -.02em; margin: 6px 0 4px; }
.assistant.full.is-empty .as-hero { height: 190px; }
.assistant.full.is-empty .as-hero .as-logo { height: 84px; }
.assistant.full.is-empty .as-chips { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-bottom: 32px; }
.as-chips button { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--base); color: var(--text); font: inherit; font-size: 13px; cursor: pointer; text-align: left; }
.as-chips button:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
.as-chips b { display: block; font-weight: 500; } .as-chips small { display: block; color: var(--subtle); font-size: 12px; }
@media (max-width: 760px) {
  body.app .assistant.full { inset: 0; border-radius: 0; }
  .assistant.full .as-side { display: none; }
}

/* Confirmation cards */
.as-action { margin: 10px 0 4px; padding: 12px 14px; border: 1px solid color-mix(in srgb, var(--brand) 45%, var(--line)); border-radius: var(--radius-lg); background: var(--base); }
.as-action.danger { border-color: color-mix(in srgb, var(--danger) 45%, var(--line)); }
.as-action.done, .as-action.cancelled { border-color: var(--line); }
.as-action-head { display: flex; align-items: center; gap: 8px; }
.as-action-head b { flex: 1; color: var(--strong); font-weight: 500; }
.as-action-head .ic { color: var(--brand); }
.as-action.danger .as-action-head .ic { color: var(--danger); }
.as-action-sum { margin: 6px 0 0; }
.as-action-params { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 3px 12px; margin: 10px 0 0; padding: 8px 10px; border-radius: var(--radius); background: var(--elevated); font-size: 12.5px; }
.as-action-params dt { color: var(--subtle); }
.as-action-params dd { margin: 0; color: var(--text); overflow-wrap: anywhere; }
.as-action-btns { display: flex; gap: 8px; margin-top: 12px; }
.as-action-out { margin: 8px 0 4px; white-space: pre-wrap; font-size: 13px; }
.secretrow { display: flex; gap: 8px; align-items: center; }
.secretrow .secret { flex: 1; margin: 0; }

/* ---- Banner art: as before on desktop; on phones a card: art the full width, text, button bottom-left ---- */
.banner .banner-art { width: 132px; height: 88px; }
.banner .banner-art b { font-size: 23px; }
.banner .banner-art small { font-size: 11px; }
@container content (max-width: 560px) {
  .banner { position: relative; flex-direction: column; align-items: stretch; padding: 8px 8px 16px; gap: 14px; }
  .banner .banner-art { width: auto; height: 148px; align-self: stretch; }
  .banner .banner-art .globe-card { padding: 16px 18px; }
  .banner .banner-art b { font-size: 28px; }
  .banner .txt { padding: 0 8px; flex: none; }
  .banner > button.primary { align-self: flex-start; margin-left: 8px; }
  .banner > button.ghost { position: absolute; top: 14px; right: 14px; z-index: 3; color: #fff; }
  .banner > button.ghost:hover { background: oklch(100% 0 0 / .15); }
}

/* ---- Round 7 ---- */
.recs > summary { padding: 10px 18px; }
.recs > summary .count { min-width: 17px; height: 17px; font-size: 10.5px; }
.plans-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 18px 0 2px; }
.plans-bar .spacer { flex: 1; }
.plans-bar .segmented button { padding: 4px 10px; }
.testmode { display: flex; align-items: center; gap: 6px; margin: 10px 0 0; }
.testmode .ic { width: 14px; height: 14px; }
details.helper > summary { gap: 10px; }
details.helper > summary .small { font-weight: 400; }
details.helper[open] > summary { margin-bottom: 12px; }
/* Plan facts: icon | text | tip | meter, all on one centred line */
.plan ul.facts li { display: grid; grid-template-columns: 16px minmax(0, 1fr) auto auto; align-items: center; column-gap: 8px; }
.plan ul.facts li > .infotip-wrap { margin: 0; }
.plan ul.facts li .freshbar { margin: 0; padding: 0; }
.plan li.fresh > span { display: block; }
.plan li.fresh b { margin: 0; }

/* ---- Translate & Documents: one card, languages on top, two panes ---- */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.tx.card { padding: 0; overflow: hidden; }
.tx-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--elevated); }
.tx-bar .spacer, .tx-opts .spacer, .tx-foot .spacer { flex: 1; }
.tx-langs { display: flex; align-items: center; gap: 6px; flex: 1 1 360px; min-width: 0; }
.tx-langs select { flex: 1; min-width: 0; font-weight: 500; box-shadow: none; background-color: transparent; }
.tx-langs select:hover { background-color: var(--tint); }
.tx-langs select:focus-visible { box-shadow: 0 0 0 1.5px var(--brand); }
.tx-swap .ic { transform: rotate(90deg); }
.tx-bar .segmented button { padding: 4px 10px; }
.tx-panes { display: grid; grid-template-columns: 1fr 1fr; min-height: 320px; }
.tx-pane { display: flex; flex-direction: column; min-width: 0; }
.tx-pane + .tx-pane { border-left: 1px solid var(--line); }
.tx-pane.out { background: var(--elevated); }
.tx-text { flex: 1; min-height: 260px; border: 0; border-radius: 0; box-shadow: none; padding: 18px 20px; font-size: 16px; line-height: 1.6; resize: none; background: transparent; }
.tx-text:focus { box-shadow: none; }
.tx-out { flex: 1; padding: 18px 20px; font-size: 16px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; min-height: 260px; }
.tx-out.busy { opacity: .6; }
.tx-ph { color: var(--placeholder); }
.tx-foot { display: flex; align-items: center; gap: 12px; padding: 6px 10px 8px 20px; min-height: 42px; font-size: 12.5px; color: var(--subtle); }
.tx-quote { color: var(--text); font-variant-numeric: tabular-nums; }
.tx-foot .ghost { min-height: 28px; padding: 0 8px; font-size: 12.5px; }
.tx-opts { display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap; padding: 12px 14px; border-top: 1px solid var(--line); }
.tx-opts > .tx-more { flex: 1 1 420px; }
.tx-more > summary { font-weight: 500; color: var(--text); padding: 7px 0; }
.tx-more .fgrid { margin-top: 6px; }
.tx-opts label, .tx-more label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 500; color: var(--subtle); margin: 4px 0; }
.tx-opts label.inline { flex-direction: row; align-items: center; gap: 10px; margin: 0; }
.tx-opts label > span { display: inline-flex; align-items: center; gap: 4px; }
.tx-opts input[type="range"] { min-height: 0; box-shadow: none; padding: 0; accent-color: var(--brand); width: 100%; }
.tx-go { align-self: center; }
.tx-go kbd { background: oklch(100% 0 0 / .18); border-color: transparent; color: #fff; margin-left: 4px; }
.tx > .notice, .tx > div > .notice { margin: 0 14px 12px; }
@container content (max-width: 720px) {
  .tx-panes { grid-template-columns: 1fr; }
  .tx-pane + .tx-pane { border-left: 0; border-top: 1px solid var(--line); }
  .tx-text, .tx-out { min-height: 180px; }
  .tx-go kbd { display: none; }
}
/* Documents: a drop zone instead of a file field */
.tx-drop { padding: 16px; }
.drop { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 200px; padding: 24px; text-align: center;
  border: 1.5px dashed var(--line); border-radius: var(--radius-lg); background: var(--elevated); cursor: pointer; transition: border-color .12s, background-color .12s; }
.drop:hover, .drop.over { border-color: var(--brand); background: var(--info-tint); }
.drop:focus-within { outline: 2px solid var(--focus); outline-offset: 2px; }
.drop b { color: var(--strong); font-weight: 500; font-size: 15px; }
.drop-ic { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--base); border: 1px solid var(--line); color: var(--brand); margin-bottom: 4px; }
.drop-ic .ic { width: 20px; height: 20px; }
.drop.has-file > b, .drop.has-file > .small, .drop.has-file > .drop-ic { display: none; }
.drop-picked { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius); background: var(--base); border: 1px solid var(--line); }
.drop-picked span { font-weight: 500; color: var(--strong); }
.drop-picked small { color: var(--subtle); }
.docrow { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto auto 36px; align-items: center; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--hairline); }
.docrow:last-child { border-bottom: 0; }
.doc-ic { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--tint); color: var(--subtle); }
.doc-main { min-width: 0; }
.doc-main b { display: block; font-weight: 500; color: var(--strong); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@container content (max-width: 560px) { .docrow { grid-template-columns: 32px minmax(0, 1fr) 36px; } .docrow > .badge { display: none; } .docrow > a.button, .docrow > span:not(.doc-ic):not(.badge) { grid-column: 2; justify-self: start; } }
.plan ul.facts li > .freshbar { display: inline-flex; flex: none; }
@container content (min-width: 861px) { .plan-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@container content (max-width: 860px) { .plan-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container content (max-width: 540px) { .plan-grid { grid-template-columns: 1fr; } }
.tx-swap .ic { transform: none; }

/* ---- Round 8 ---- */
/* Settings contents: a pill that slides to the section in view */
.settoc a { position: relative; z-index: 1; transition: color .18s ease; }
.settoc a.on { color: var(--strong); font-weight: 500; }
.settoc a.on:hover { background: none; }
.settoc-ind { position: absolute; left: 0; top: 0; z-index: 0; border-radius: var(--radius); background: var(--recessed); box-shadow: inset 0 0 0 1px var(--hairline); opacity: 0; pointer-events: none;
  transition: transform .28s cubic-bezier(.2, .8, .2, 1), height .28s cubic-bezier(.2, .8, .2, 1), width .28s cubic-bezier(.2, .8, .2, 1), opacity .2s; }
.settoc-ind::before { content: ""; position: absolute; left: 0; top: 7px; bottom: 7px; width: 2px; border-radius: 2px; background: var(--brand); }
@media (prefers-reduced-motion: reduce) { .settoc-ind { transition: none; } }

/* Ask AI: one dot canvas behind the panel's content */
.assistant .as-frame { position: relative; }
.as-dots { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.assistant .as-side, .assistant .as-main { position: relative; z-index: 1; }
.as-hero .as-tilt { display: inline-block; transition: transform .2s ease-out; will-change: transform; }
.as-hero { height: 150px; }

/* ⓘ beside its label text, centred on the line */
.lbl { display: inline-flex; align-items: center; gap: 4px; }
.lbl .infotip-wrap { margin-left: 0; }
.infotip-wrap { vertical-align: -3px; }
.infotip { width: 16px; height: 16px; }

/* Disclosure triangles become the same line chevron as everywhere else */
details > summary { list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details:not(.recs):not(.faq-item):not(.pagerow) > summary::before {
  content: ""; display: inline-block; width: 14px; height: 14px; margin-right: 6px; vertical-align: -2px; flex: none; background: currentColor; opacity: .7;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 6 6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 6 6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform .18s ease;
}
details[open]:not(.recs):not(.faq-item):not(.pagerow) > summary::before { transform: rotate(90deg); }

/* Sidebar: the guide line starts below its row and ends above the next one */
nav.side .navitems > .sub { margin: 4px 0 6px 17px; padding: 0 0 0 8px; }
nav.side .navgroup.collapsed .navitems > .sub { margin-top: 0; margin-bottom: 0; }

/* Concentric corners: a container's radius is its child's radius plus the gap between them */
.banner { border-radius: 22px; }
.banner .banner-art { border-radius: 14px; padding: 3px; }
.banner .banner-art .globe-card { border-radius: 11px; }
@container content (max-width: 560px) { .banner { border-radius: 22px; } .banner .banner-art { border-radius: 14px; } }

/* Recommendations: tight header, list and footer at any length */
.recs > summary { padding: 12px 18px; }
.recs ul { padding: 2px 18px 2px; }
.recs li { padding: 8px 0 8px 20px; }
.recs li::before { top: 15px; }
.recs.folded li:nth-child(2) { max-height: 24px; }
.recs-more { padding: 4px 0 10px; }
.recs:not(.folded) .recs-more { padding-top: 6px; border-top: 1px solid var(--hairline); }

/* Rows of lists read on one centre line */
.listcard td, .model-rows td { vertical-align: middle; }
.listcard td .progress { margin-top: 14px; }

/* ---- Round 9 ---- */
/* Tips: a quiet note, not an alert */
.toast.tipnote { display: block; width: min(360px, calc(100vw - 32px)); padding: 12px 14px 10px; box-shadow: 0 12px 32px oklch(0% 0 0 / .18); }
.tipnote-head { display: flex; align-items: center; justify-content: space-between; margin: -2px -6px 2px 0; }
.tipnote-kicker { font-size: 11px; font-weight: 600; letter-spacing: .06em; color: var(--subtle); }
.tipnote-head .ghost { min-height: 26px; padding: 0 6px; }
.toast.tipnote b { display: block; font-size: 14px; color: var(--strong); font-weight: 500; }
.toast.tipnote p { margin: 4px 0 8px; font-size: 13px; line-height: 1.5; }
.toast.tipnote .toast-actions { display: flex; gap: 16px; margin: 0; }
.toast.tipnote button.link { font-size: 13px; font-weight: 500; text-decoration: none; }
.toast.tipnote button.link:hover { text-decoration: underline; }
button.link.quiet { color: var(--subtle); }
.tip { display: block !important; padding: 12px 16px !important; }
.tip .tip-cta { display: block; margin-top: 4px; color: var(--link); font-size: 12.5px; }
.tip.unseen { box-shadow: inset 2px 0 0 var(--brand); }

/* Settings contents: just the pill, no accent bar */
.settoc-ind::before { display: none; }

/* Tiles: a label, the number, one quiet line */
.tile { padding: 14px 16px; }
.tile .label { display: flex; align-items: center; gap: 4px; font-size: 12.5px; }
.tile .value { font-size: 22px; margin: 4px 0 2px; }
.tile .sub { font-size: 12.5px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tiles > .tile { flex-basis: 180px; }

/* Search-style first row (preview, estimator) */
.tx-bar.bigbar { gap: 8px; padding: 10px; }
.tx-bar.bigbar .searchbox { min-height: 40px; background: var(--base); }
.tx-bar.bigbar .searchbox input { font-size: 15px; }
.tx-bar.bigbar > select { width: auto; max-width: 240px; }
.tx-opts.optgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 0 12px; }
.tx-opts.optgrid label select { width: 100%; }
.tx-note { margin: 0; padding: 0 14px 14px; }
.tx-opts > .small.muted { flex: 1; min-width: 200px; align-self: center; }

/* Compare models */
.cmpgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 16px 0; }
.cmpcard { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--base); }
.cmpcard.busy { opacity: .6; }
.cmpcard-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid var(--hairline); }
.cmpcard-head b { color: var(--strong); font-weight: 500; }
.cmpcard-out { flex: 1; margin: 0; padding: 14px 16px; font-size: 15px; line-height: 1.6; white-space: pre-wrap; min-height: 110px; }
.cmpcard-foot { padding: 8px 16px 12px; }
@container content (max-width: 760px) { .cmpgrid { grid-template-columns: 1fr; } }

/* Models catalog */
.found { margin: 4px 0 12px; color: var(--subtle); font-size: 13px; }
.catalog { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin-bottom: 18px; }
.mcard { display: flex; flex-direction: column; gap: 10px; padding: 16px 16px 0; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--base); }
.mcard.planned { background: var(--elevated); }
.mcard-top { display: flex; align-items: center; gap: 10px; }
.mcard-top b { font-size: 16px; font-weight: 500; color: var(--strong); flex: 1; }
.mcard-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13px; color: var(--text); font-weight: 500; }
.mcard .chip { font-family: var(--font); font-size: 11.5px; padding: 2px 8px; border-radius: 99px; border: 1px solid var(--line); background: none; color: var(--text); }
.mcard-text { margin: 0; color: var(--subtle); font-size: 13.5px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mcard-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.mcard-tags .chip { background: var(--tint); border-color: transparent; color: var(--subtle); }
.mcard-foot { display: flex; align-items: center; justify-content: space-between; margin: 2px -16px 0; padding: 8px 10px 8px 16px; border-top: 1px solid var(--hairline); font-size: 13px; }
.mcard-foot a .ic { width: 12px; height: 12px; }
.mcard-foot .ghost { min-height: 28px; font-size: 13px; }
label.switch.card { margin: 0 0 16px; padding: 14px 16px; }

/* Footer */
.appfoot { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; max-width: 1160px; margin: 0; padding: 18px 36px 28px; border-top: 1px solid var(--line); color: var(--subtle); font-size: 13px; }
.appfoot nav { display: flex; flex-wrap: wrap; align-items: center; }
.appfoot nav > * { padding: 2px 12px; border: 0; border-left: 1px solid var(--line); background: none; color: var(--text); font: inherit; cursor: pointer; }
.appfoot nav > :first-child { padding-left: 0; border-left: 0; }
.appfoot nav > *:hover { color: var(--strong); text-decoration: underline; text-underline-offset: 3px; }
@container app (max-width: 820px) { .appfoot { padding: 16px 16px 24px; } }
.tx-short .tx-text { min-height: 130px; }

/* ---- Round 10 ---- */
/* Recommendations header: no extra gap under the summary (details.card adds one). */
.recs[open] > summary { margin-bottom: 0; }
/* Footer sits at the bottom of the content column and its line runs to the right edge. */
body.app .scroller { display: flex; flex-direction: column; }
body.app .scroller > main { flex: 1 0 auto; }
.appfoot { max-width: none; width: 100%; padding-right: max(36px, calc(100% - 1160px + 36px)); }
@container app (max-width: 820px) { .appfoot { padding: 16px 16px 24px; } }
/* Code blocks: even padding, Copy button centred on a one-line command. */
.codeblock pre { margin: 0; padding: 15px 84px 15px 14px; min-height: 52px; }
.codeblock button { top: 9px; right: 9px; }
/* Buttons: text centred and not selectable. */
button, a.button, .toplink, .navitem, .navlink, .navhead, .recs > summary, .segmented, .chip, .newtag, .ai-badge { -webkit-user-select: none; user-select: none; }
button.primary, button.secondary, button.danger, button.ghost, a.button { line-height: 1; }
/* "Set up with AI" badge beside Ask AI. */
.ai-badge { font-size: 10.5px; font-weight: 600; line-height: 1; letter-spacing: .02em; padding: 3px 7px; border-radius: 99px; color: var(--brand); background: color-mix(in srgb, var(--brand) 12%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 35%, transparent); white-space: nowrap; }
:root[data-theme="dark"] .ai-badge { color: oklch(78% .12 270); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ai-badge { color: oklch(78% .12 270); } }
@container app (max-width: 980px) { .ai-badge { display: none; } }
.mcp-pick { display: flex; flex-wrap: wrap; width: fit-content; max-width: 100%; margin: 2px 0 6px; }

/* ---- Round 11 ---- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
/* Recommendations: details.card[open] > summary adds 8px below; this rule outranks it. */
details.card.recs[open] > summary { margin-bottom: 0; }
/* Footer: same space below as above. */
.appfoot { padding-top: 18px; padding-bottom: 18px; }
@container app (max-width: 820px) { .appfoot { padding: 16px; } }
/* "Set up with AI": a little apart from the label, brighter. */
.ai-badge { margin-left: 4px; color: #fff; background: color-mix(in srgb, var(--brand) 85%, #fff); box-shadow: none; }
:root[data-theme="dark"] .ai-badge { color: #fff; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ai-badge { color: #fff; } }
/* Tip note: title + close on one row, real buttons on the right. */
.toast.tipnote { padding: 14px 16px; }
.tipnote-head { align-items: flex-start; gap: 10px; margin: 0; }
.tipnote-head b { flex: 1; padding-top: 2px; }
.tipnote-head .ghost { margin: -2px -8px 0 0; }
.toast.tipnote p { margin: 6px 0 12px; color: var(--subtle); }
.toast.tipnote .toast-actions { justify-content: flex-end; gap: 8px; }
.toast.tipnote .toast-actions button { min-height: 32px; }
/* Phone menu: one row, every item centred on the same line. */
@container app (max-width: 820px) {
  nav.side { align-items: center; gap: 4px; padding-top: 8px; padding-bottom: 8px; }
  nav.side .quicksearch { width: auto; margin: 0; flex: none; }
  nav.side > a.navitem, nav.side > .navlink, nav.side .quicksearch { min-height: 36px; }
}
/* Sign in: logo and wordmark. */
.lockup { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.lockup .logo { height: 64px; width: auto; }
.lockup b { display: block; font-size: 30px; font-weight: 700; letter-spacing: -.02em; line-height: 1; color: var(--strong); }
.lockup small { display: block; margin-top: 4px; font-size: 15px; color: var(--subtle); }
/* Sign-in code: six slots over one real input. */
.otp { position: relative; display: block; flex: 1; min-width: 0; }
.otp input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; font-size: 16px; letter-spacing: 0; cursor: text; z-index: 1; }
.otp-slots { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.otp-slots i { display: grid; place-items: center; height: 44px; border-radius: var(--radius); background: var(--base); box-shadow: 0 0 0 1px var(--line); font-style: normal; font-size: 20px; font-weight: 500; font-variant-numeric: tabular-nums; color: var(--strong); transition: box-shadow .1s; }
.otp-slots i.on { box-shadow: 0 0 0 2px var(--brand); }
#code-form { flex-wrap: nowrap; align-items: stretch; }
#code-form button { min-height: 44px; }
/* Websites: empty state with hero, steps and what's included. */
.site-empty { margin: 16px 0; }
.site-empty-hero { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: 28px; align-items: center; padding: 22px; border-radius: var(--radius-lg); background: var(--base); border: 1px solid var(--hairline); }
.site-empty-hero .globe-frame { height: 210px; }
.site-empty-hero .globe-card { height: 100%; padding: 16px 18px; }
.site-empty-kicker { position: relative; z-index: 1; font-size: 12px; font-weight: 600; letter-spacing: .04em; color: #fff; opacity: .9; }
.site-empty-hero h2 { margin: 0 0 6px; font-size: 22px; line-height: 1.25; letter-spacing: -.02em; }
.site-empty-hero p { margin: 0 0 16px; color: var(--subtle); max-width: 56ch; }
.site-steps { list-style: none; padding: 0; margin: 14px 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.site-steps li { padding: 16px; border-radius: var(--radius-lg); background: var(--base); border: 1px solid var(--hairline); }
.site-steps .n { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: color-mix(in srgb, var(--brand) 16%, transparent); color: var(--brand); font-size: 12px; font-weight: 600; margin-bottom: 10px; }
.site-steps b { display: block; color: var(--strong); font-weight: 500; }
.site-steps p { margin: 2px 0 0; color: var(--subtle); font-size: 13px; }
.site-parts { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
:root[data-theme="dark"] .site-steps .n { color: oklch(78% .12 270); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .site-steps .n { color: oklch(78% .12 270); } }
@container content (max-width: 720px) { .site-empty-hero, .site-steps { grid-template-columns: 1fr; } }
/* Fewer borders (less eye strain): surfaces separate by tone, hairlines stay faint. */
:root[data-theme="dark"] { --line: oklch(24% 0 0); --hairline: oklch(20% 0 0); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --line: oklch(24% 0 0); --hairline: oklch(20% 0 0); } }
.card, .tile { border-color: var(--hairline); box-shadow: none; }
.recs ul { border-top-color: transparent; }

/* ---- Round 12 ---- */
/* Charts: neutral blue-grey line, not the brand blue. */
:root { --chart: oklch(52% .03 260); }
:root[data-theme="dark"] { --chart: oklch(84% .035 260); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --chart: oklch(84% .035 260); } }
svg.chart .area { opacity: 1; }
svg.chart .line { stroke-width: 1.5; }
svg.chart .line.flat { opacity: .35; }
/* Websites list: 7-day page-view sparkline. */
.spark { display: inline-flex; align-items: center; gap: 10px; min-width: 150px; }
.spark svg.chart { width: 104px; height: 28px; flex: none; }
.spark b { font-weight: 500; font-variant-numeric: tabular-nums; color: var(--strong); }
/* "Set up with AI": a plain, quiet label (no glowing pill). */
.ai-badge, :root[data-theme="dark"] .ai-badge { margin-left: 6px; padding: 2px 7px; border-radius: 6px; font-size: 11px; font-weight: 500; letter-spacing: 0;
  color: var(--subtle); background: none; box-shadow: inset 0 0 0 1px var(--line); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ai-badge { color: var(--subtle); } }
.toplink:hover .ai-badge { color: var(--text); }
/* Plans: name, rule, price, plain list; one accent for the recommended plan. */
.plan { gap: 0; padding: 22px 22px 20px; border-color: var(--hairline); box-shadow: none; }
.plan.featured { border-color: var(--hairline); box-shadow: none; }
.plan.current { background: var(--base); }
.plan.fits { border-color: color-mix(in srgb, var(--brand) 55%, var(--hairline)); }
.plan-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.plan h3 { font-size: 22px; font-weight: 500; letter-spacing: -.02em; color: var(--text); }
.plan-tag { font-size: 11.5px; font-weight: 500; padding: 2px 9px; border-radius: 99px; background: var(--fill); color: var(--text); white-space: nowrap; }
.plan-tag.rec, .plan-tag.fit { background: color-mix(in srgb, var(--brand) 16%, transparent); color: var(--link); }
.plan-rule { height: 3px; border-radius: 2px; margin: 12px 0 14px; background: var(--fill); }
.plan.featured .plan-rule { background: var(--brand); }
.plan .price b { font-size: 28px; font-weight: 600; }
.plan .for { margin: 4px 0 16px; font-size: 13px; min-height: 2.6em; }
.plan ul.facts { gap: 10px; margin-bottom: 18px; }
.plan ul.facts li { display: flex; align-items: flex-start; gap: 8px; color: var(--text); font-size: 13.5px; line-height: 1.45; }
.plan ul.facts li > span:first-child { flex: 1; }
.plan ul.facts li .infotip-wrap, .plan ul.facts li .infotip { opacity: .55; }
.plan ul.facts li:hover .infotip-wrap, .plan ul.facts li:hover .infotip { opacity: 1; }
/* Locked feature: dimmed controls with the plan and an Upgrade button on top. */
.locked { position: relative; border-radius: var(--radius); margin: 6px 0; }
.locked-body { opacity: .35; filter: blur(.6px); pointer-events: none; }
.locked-over { position: absolute; inset: 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 10px; padding: 8px; text-align: center; }
.locked-plan { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 500; padding: 3px 9px; border-radius: 99px; background: var(--fill); color: var(--text); }
.locked-plan .ic { width: 13px; height: 13px; }
.locked-over button.primary { min-height: 30px; font-size: 13px; }
.locked-about { flex-basis: 100%; font-size: 12px; color: var(--subtle); }
.segmented button.is-locked { display: inline-flex; align-items: center; gap: 5px; opacity: .6; }
.segmented button.is-locked .ic { width: 12px; height: 12px; }
.segmented button.is-locked:hover { opacity: 1; }
.plan ul.facts li > span.infotip-wrap { flex: none; margin-top: 1px; }

/* ---- Round 13: sign-in options, setup guide, batch ---- */
.stack { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.auth-alt { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 14px 0 4px; }
.auth-alt .secondary { display: inline-flex; align-items: center; gap: 8px; }
.redo-setup { color: var(--subtle); font-size: 13px; border: 1px dashed var(--line); }
.redo-setup:hover { color: var(--text); }

.choices { display: grid; gap: 10px; }
.choices.two { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.choice { display: flex; align-items: flex-start; gap: 12px; text-align: left; padding: 14px 16px; border-radius: var(--radius); background: var(--base); border: 1px solid var(--line); color: var(--text); font: inherit; cursor: pointer; }
.choice:hover { border-color: color-mix(in srgb, var(--brand) 50%, var(--line)); }
.choice.on { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.choice.big { flex-direction: column; padding: 20px; }
.choice > span:last-child { display: flex; flex-direction: column; gap: 3px; }
.choice b { display: inline-flex; align-items: center; gap: 8px; color: var(--strong); font-weight: 600; }
.choice-ic { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 8px; background: color-mix(in srgb, var(--brand) 10%, transparent); color: var(--brand); }

.totp-box { display: grid; gap: 8px; }
.totp-steps { margin: 0; padding-left: 18px; display: grid; gap: 6px; }
.totp-key { font-family: var(--mono); letter-spacing: .06em; user-select: all; }
.pk-list { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 4px; }
.pk-list li { display: flex; align-items: center; gap: 8px; }
.row-inline { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }

.batch-langs { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 0; }
.batch-chips { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.langchip { display: inline-flex; align-items: center; gap: 2px; font-size: 13px; padding: 2px 4px 2px 10px; border-radius: 99px; background: var(--fill); color: var(--text); }
.langchip .ghost { padding: 2px; }
.batch-text { min-height: 220px; }
.totp-scan { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; }
.totp-qr { padding: 8px; background: #fff; border-radius: var(--radius); box-shadow: 0 0 0 1px var(--line); line-height: 0; }
.totp-steps details summary { cursor: pointer; }

/* Setup guide: full screen, one question at a time. */
body.setup-mode { overflow: hidden; }
.setup { position: fixed; inset: 0; z-index: 70; display: flex; flex-direction: column; background: var(--canvas); overflow-y: auto; }
.setup-bar { position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--fill); }
.setup-bar i { display: block; height: 100%; background: var(--brand); transition: width .4s cubic-bezier(.2, .8, .2, 1); }
.setup-head { display: flex; align-items: center; gap: 12px; padding: 20px 28px; flex: none; }
.setup-logo { width: 30px; height: auto; }
.setup-back { width: 34px; height: 34px; border-radius: 99px; border: 1px solid var(--line); background: none; color: var(--text); font-size: 16px; cursor: pointer; }
.setup-back:hover { background: var(--tint); }
.setup-back.invisible { visibility: hidden; }
.setup-skipall, .setup-skip { background: none; border: 0; color: var(--subtle); font: inherit; font-size: 14px; cursor: pointer; padding: 6px 8px; }
.setup-skipall:hover, .setup-skip:hover { color: var(--text); }
.setup-stage { flex: 1; display: grid; place-items: center; padding: 0 20px 10vh; }
.setup-step { width: 100%; max-width: 440px; }
.setup-step.wide { max-width: 760px; }
@media (prefers-reduced-motion: no-preference) { .setup-step { animation: setup-in .45s cubic-bezier(.2, .8, .2, 1); } }
@keyframes setup-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.setup-step h1 { font-size: clamp(28px, 4vw, 38px); line-height: 1.1; letter-spacing: -.02em; font-weight: 600; color: var(--strong); margin: 0 0 10px; }
.setup-line { color: var(--subtle); font-size: 16px; margin: 0 0 28px; }
.setup-step h1 + :not(.setup-line) { margin-top: 24px; }
.setup-fields { display: grid; gap: 10px; }
.setup-fields input { height: 46px; font-size: 16px; }
.setup-actions { display: flex; align-items: center; gap: 14px; margin-top: 28px; }
.setup-go { height: 46px; padding: 0 26px; font-size: 15px; border-radius: 99px; display: inline-flex; align-items: center; gap: 8px; }
.setup-msg:not(:empty) { margin-top: 14px; }
.setup-extra { display: grid; gap: 12px; margin-top: 12px; }
.setup-step .link { margin-top: 16px; display: inline-block; font-size: 14px; }
.setup-facts { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.setup-facts li { display: flex; align-items: center; gap: 12px; font-size: 16px; color: var(--strong); }
.setup-facts .ic { width: 20px; height: 20px; color: var(--brand); flex: none; }
.setup-key { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-radius: 12px; background: var(--recessed); border: 1px solid var(--hairline); }
.setup-key code { flex: 1; font-family: var(--mono); font-size: 13px; word-break: break-all; }
.setup-try { display: flex; gap: 8px; flex-wrap: wrap; }
.setup-try input { flex: 1; min-width: 200px; }
.setup-result { min-height: 26px; margin: 12px 0; font-size: 16px; }
.setup-result .bad { color: var(--danger); font-size: 14px; }
.setup-tabs { display: flex; gap: 4px; }
.setup-tabs button { background: none; border: 0; padding: 6px 10px; border-radius: 8px; color: var(--subtle); font: inherit; font-size: 13px; cursor: pointer; }
.setup-tabs button.on { background: var(--fill); color: var(--strong); }
.setup-code { background: var(--recessed); border: 1px solid var(--hairline); border-radius: 12px; padding: 14px 16px; font-family: var(--mono); font-size: 12.5px; overflow-x: auto; white-space: pre; margin: 8px 0 0; }
.setup-ai { height: min(560px, calc(100dvh - 330px)); min-height: 340px; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; }
/* The real Ask AI, embedded: no panel chrome. */
body.app .assistant.embedded { position: static; transform: none; width: 100% !important; height: 100%; border: 0; box-shadow: none; visibility: visible; animation: none; }
.assistant.embedded > * { animation: none !important; }
.assistant.embedded .as-top, .assistant.embedded .as-help { display: none; }
@media (max-width: 640px) { .setup-head { padding: 16px; } .setup-stage { place-items: start center; padding-top: 4vh; } }
.setup-skipall { margin-left: auto; }
body.setup-mode .app-col, body.setup-mode .skiplink { visibility: hidden; }

/* ---- Round 14: calmer setup, more room everywhere ---- */
/* Spacing: everything had too little air. */
@media (max-width: 640px) { main { padding: 24px 16px 72px; } }

/* Setup: one calm rhythm on every screen. */
.setup-stage { padding: 24px 24px 12vh; }
.setup-step { max-width: 480px; }
.setup-step.wide { max-width: 800px; }
.setup-step h1 { margin-bottom: 12px; }
.setup-line { margin-bottom: 36px; line-height: 1.5; }
.setup-step h1 + :not(.setup-line) { margin-top: 32px; }
.setup-fields { gap: 14px; }
.setup-fields input { height: 48px; padding: 0 16px; border-radius: 12px; }
.setup-reveal { margin-top: 18px; }
.setup-reveal.hidden { display: none; }
.setup-facts { gap: 18px; }
.choice { padding: 18px 20px; gap: 14px; border-radius: 14px; transition: border-color .15s, background-color .15s; }
.choice.big { padding: 22px 24px; gap: 14px; }
.choice.on { box-shadow: none; background: color-mix(in srgb, var(--brand) 6%, var(--base)); }
.choice > span:last-child { gap: 5px; }
.choices.stack-3 { grid-template-columns: 1fr; }
.choices.two { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
/* Buttons: quiet, not shouting. */
.setup-actions { gap: 12px; margin-top: 40px; }
button.primary.setup-go { height: 44px; padding: 0 22px; border-radius: 12px; font-size: 15px; font-weight: 500;
  background: color-mix(in srgb, var(--brand) 16%, var(--base)); color: var(--strong);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 45%, var(--line)); }
button.primary.setup-go:hover { background: color-mix(in srgb, var(--brand) 26%, var(--base)); }
.setup-backbtn { height: 44px; padding: 0 18px; border-radius: 12px; background: none; border: 1px solid var(--line); color: var(--text); font: inherit; font-size: 15px; cursor: pointer; }
.setup-backbtn:hover { background: var(--tint); }
.setup-skip { padding: 10px 12px; }
/* Two-step switch row. */
.setup-toggle { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; padding: 18px 20px; border-radius: 14px; border: 1px solid var(--line); background: var(--base); color: var(--text); font: inherit; cursor: pointer; }
.setup-toggle-text { flex: 1; display: flex; flex-direction: column; gap: 5px; }
.setup-toggle-text b { color: var(--strong); font-weight: 600; }
.switch-knob { flex: none; width: 40px; height: 24px; border-radius: 99px; background: var(--fill); position: relative; transition: background-color .2s; }
.switch-knob::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 2px oklch(0% 0 0 / .3); }
.setup-toggle.on .switch-knob { background: var(--brand); }
.setup-toggle.on .switch-knob::after { transform: translateX(16px); }
/* Setup page: the dot grid is the page itself; the embedded assistant sits on it, unframed. */
.setup { background-color: var(--canvas); background-image: radial-gradient(var(--hairline) 1px, transparent 1px); background-size: 16px 16px; background-attachment: local; }
.setup-ai { border: 0; border-radius: 0; overflow: visible; height: max(520px, calc(100dvh - 250px)); min-height: 520px; }
.setup-step.wide:has(.setup-ai) { max-width: 880px; }
body.app .assistant.embedded { background: none; overflow: visible; }
.assistant.embedded .as-dots { display: none; }
.assistant.embedded .as-frame, .assistant.embedded .as-main { overflow: visible; }
.assistant.embedded .as-body { padding: 4px 4px 12px; }
.assistant.embedded .as-input { margin: 8px 2px 2px; background: var(--base); }
/* Always solid and still: no fades, no slide-ins, nothing half-transparent. */
.setup-step.wide, .assistant.embedded, .assistant.embedded * { animation: none !important; }
.assistant.embedded .as-msg { opacity: 1; margin: 16px 0; }
.assistant.embedded .as-msg.ai { background: var(--base); border-color: var(--line); padding: 14px 18px; border-radius: 16px 16px 16px 6px; }
.assistant.embedded .as-msg.me { background: var(--fill); padding: 12px 16px; border-radius: 16px 16px 6px 16px; }
.as-quick { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 0 0; }
.as-quick button { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 99px; border: 1px solid var(--line); background: var(--base); color: var(--text); font: inherit; font-size: 13px; cursor: pointer; }
.as-quick button:hover { border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); }
.as-quick .ic { width: 15px; height: 15px; color: var(--brand); }

/* ---- Round 15: art cards, finished websites hero, friendlier setup ---- */
.globe-card[class*="art-"] > canvas.on { opacity: .92; }
.empty .globe-frame > .globe-card[class*="art-"] { height: 100%; }
/* Setup pitch art */
.setup-art { height: 180px; margin: 0 0 28px; }
.setup-art .globe-frame { height: 100%; }
.setup-art .globe-card { padding: 16px 18px; }
.setup-art-label { font-size: 12.5px; font-weight: 600; letter-spacing: .02em; color: #fff; opacity: .92; }
/* Websites hero: live language caption, stats and the proof line */
.site-empty-hero { padding: 28px; gap: 36px; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); }
.site-empty-hero .globe-frame { height: 236px; }
.site-empty-hero .globe-card { display: flex; flex-direction: column; justify-content: space-between; padding: 18px 20px; }
.site-empty-live { position: relative; z-index: 2; align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 10px; border-radius: 99px;
  background: oklch(0% 0 0 / .28); box-shadow: inset 0 0 0 1px oklch(100% 0 0 / .18); font-size: 13px; font-weight: 500; color: #fff; backdrop-filter: blur(6px); }
.site-empty-live i { width: 7px; height: 7px; border-radius: 50%; background: oklch(85% .17 150); box-shadow: 0 0 0 3px oklch(85% .17 150 / .25); }
.site-empty-hero h2 { font-size: 24px; margin-bottom: 10px; }
.site-empty-hero p { margin-bottom: 20px; line-height: 1.55; }
.site-empty-stats { display: flex; flex-wrap: wrap; gap: 10px 28px; margin: 0 0 24px; }
.site-empty-stats span { display: flex; align-items: baseline; gap: 7px; color: var(--subtle); font-size: 13.5px; }
.site-empty-stats b { color: var(--strong); font-size: 20px; font-weight: 600; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.site-empty-hero .site-empty-proof { margin: 20px 0 0; font-size: 13px; color: var(--subtle); display: flex; align-items: center; gap: 8px; }
.site-empty-proof::before { content: ""; width: 16px; height: 16px; flex: none; border-radius: 50%; background: var(--success-tint) center / 10px no-repeat;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--success) 40%, transparent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3 3 7-7' fill='none' stroke='%2322c55e' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
.site-steps { gap: 16px; margin: 20px 0; }
.site-steps li { padding: 20px 22px; }
.site-parts { gap: 8px; margin-top: 4px; }
@container content (max-width: 720px) { .site-empty-hero { grid-template-columns: 1fr; padding: 20px; gap: 24px; } }

/* Enterprise contact page */
.ent-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 32px; align-items: start; margin: 12px 0 24px; }
.ent-intro .eyebrow { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px; }
.ent-intro h1 { font-size: 34px; line-height: 1.1; letter-spacing: -.02em; margin: 0 0 12px; }
.ent-intro > p { font-size: 15.5px; line-height: 1.55; max-width: 44ch; }
.ent-points { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 16px; }
.ent-points li { display: flex; gap: 12px; align-items: flex-start; }
.ent-points li > svg { flex: none; width: 34px; height: 34px; padding: 8px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 10%, var(--base)); color: var(--accent); }
.ent-points b { display: block; font-weight: 600; margin-bottom: 2px; }
.ent-card { padding: 24px; border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.ent-card h2 { margin: 0 0 16px; font-size: 19px; }
.ent-form { display: grid; gap: 16px; }
.ent-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 14px; }
.ent-form label { display: grid; gap: 6px; font-size: 13px; font-weight: 500; }
.ent-form input:not([type=checkbox]), .ent-form select, .ent-form textarea { width: 100%; box-sizing: border-box; }
.ent-needs { border: 0; padding: 0; margin: 0; }
.ent-needs legend { font-size: 13px; font-weight: 500; margin-bottom: 8px; padding: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-check { display: inline-flex !important; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; font-weight: 400 !important; }
.chip-check:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--base)); }
.chip-check input { margin: 0; }
.ent-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.ent-done { text-align: center; padding: 28px 8px; display: grid; justify-items: center; gap: 8px; }
.ent-done > svg { width: 40px; height: 40px; padding: 9px; border-radius: 50%; background: var(--success-tint); color: var(--success); }
@media (max-width: 860px) { .ent-hero { grid-template-columns: 1fr; gap: 20px; } .ent-intro h1 { font-size: 28px; } }
@media (max-width: 520px) { .ent-grid { grid-template-columns: 1fr; } .ent-card { padding: 18px; } }

/* Assistant: plan change card */
.as-plan { margin: 10px 0 0; border-radius: var(--radius); background: var(--elevated); padding: 12px; display: grid; gap: 10px; }
.as-plan-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.as-plan-name { font-size: 18px; font-weight: 600; color: var(--strong); line-height: 1.2; }
.as-plan-price { font-size: 15px; font-weight: 600; color: var(--brand); white-space: nowrap; }
.as-plan-rows { display: grid; gap: 4px; font-size: 12.5px; border-top: 1px solid var(--hairline); padding-top: 8px; }
.as-plan-row { display: grid; grid-template-columns: 76px minmax(0, 1fr) 14px minmax(0, 1fr); align-items: center; gap: 6px; }
.as-plan-row .ic { width: 12px; height: 12px; color: var(--subtle); }
.as-plan-row b { color: var(--strong); font-weight: 600; }
.as-plan-note { margin: 0; }

/* Batch translation */
.batch-tabs button { display: inline-flex; align-items: center; gap: 6px; }
.batch-tabs .ic { width: 14px; height: 14px; }
.batch-langs { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.batch-label { font-size: 12px; font-weight: 500; color: var(--subtle); white-space: nowrap; }
.batch-chips { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; flex: 1; min-width: 0; }
.langchip { display: inline-flex; align-items: center; gap: 2px; height: 28px; padding: 0 4px 0 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--base); font-size: 13px; color: var(--strong); }
.langchip.main { padding-right: 10px; border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); background: color-mix(in srgb, var(--brand) 7%, var(--base)); }
.langchip .ghost { min-height: 22px; width: 22px; padding: 0; justify-content: center; border-radius: 50%; }
.langchip .ic { width: 12px; height: 12px; }
.batch-add { width: auto; min-height: 28px; height: 28px; padding: 0 28px 0 10px; border-radius: 999px; font-size: 13px; }
.batch .batch-text { min-height: 220px; }
.batch-actions { align-items: center; }
.batch-quote:empty { display: none; }
.batch-quote { margin-top: 14px; display: grid; gap: 8px; }
.batch-quote p { margin: 0; }
.batch-quote-wait { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--subtle); }
.batch-total { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--line); }
.batch-total > div { background: var(--base); padding: 10px 12px; display: grid; gap: 2px; }
.batch-total b { font-size: 17px; font-weight: 600; color: var(--strong); }
.batch-files summary { cursor: pointer; font-size: 13px; color: var(--subtle); }
.batch-progress { padding: 16px 18px; display: grid; gap: 12px; margin-top: 16px; }
.batch-progress-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.batch-progress-head .spacer { flex: 1; }
.batch-meter { width: 100%; }
.batch-rows { max-height: 420px; overflow: auto; margin: 0 -18px -16px; border-top: 1px solid var(--line); }
@media (max-width: 640px) { .batch-total { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Assistant answers as cards */
.as-msg.ai.as-card { padding: 0; overflow: hidden; }
.as-card-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px 10px 14px; border-bottom: 1px solid var(--hairline); }
.as-card-head b { font-size: 13.5px; font-weight: 600; color: var(--strong); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.as-card-head .spacer { flex: 1; }
.as-card-mark { display: grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 7px; background: color-mix(in srgb, var(--brand) 12%, var(--base)); color: var(--brand); }
.as-card-mark .ic { width: 14px; height: 14px; }
.as-card.err .as-card-mark { background: var(--danger-tint); color: var(--danger); }
.as-card-copy { min-height: 26px; width: 26px; padding: 0; justify-content: center; opacity: .7; }
.as-card-copy:hover, .as-card-copy.done { opacity: 1; color: var(--success); }
.as-card-body { padding: 12px 14px; }
.as-card-body > :first-child { margin-top: 0; }
.as-card-body > :last-child { margin-bottom: 0; }
.as-card-actions { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 14px 12px; border-top: 1px solid var(--hairline); background: var(--elevated); }
.as-card-actions button { min-height: 30px; font-size: 13px; display: inline-flex; align-items: center; gap: 4px; }
.as-card-actions .ic { width: 12px; height: 12px; }
.assistant.embedded .as-msg.ai.as-card { padding: 0; }
.assistant.embedded .as-card-body { padding: 14px 18px; }

/* Setup: the featured purpose (website translation) */
.choices .choice.featured { grid-column: 1 / -1; padding: 18px 18px; border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); background: color-mix(in srgb, var(--brand) 6%, var(--base)); }
.choice.featured b { font-size: 17px; font-weight: 600; }
.choice.featured .choice-ic { color: var(--brand); }
.choice-tag { display: inline-block; margin-bottom: 4px; padding: 2px 8px; border-radius: 999px; background: var(--brand); color: #fff; font-size: 11px; font-weight: 600; letter-spacing: .02em; }

/* Websites empty state: simple */
.site-empty.simple .site-empty-hero .txt h2 { font-size: 26px; letter-spacing: -.01em; margin: 0 0 8px; }
.site-empty.simple .site-empty-hero .txt > p:first-of-type { max-width: 46ch; margin: 0 0 18px; }
.site-empty-includes { margin: 16px 0 0; }

/* Settings on phones: a menu of sections; each opens on its own page */
.setmenu, .setback { display: none; }
@media (max-width: 760px) {
  .setlayout { display: block; }
  .setlayout .settoc { display: none; }
  .setlayout:not([data-open]) .setmenu { display: block; padding: 4px 0; overflow: hidden; }
  .setlayout:not([data-open]) .setmain { display: none; }
  .setlayout[data-open] .setsec:not(.open) { display: none; }
  .setlayout[data-open] .setback { display: inline-flex; }
  .setmenu-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 0 14px; border: 0; border-radius: 0; background: none; font: inherit; font-size: 15px; color: var(--strong); text-align: left; cursor: pointer; }
  .setmenu-row + .setmenu-row { border-top: 1px solid var(--hairline); }
  .setmenu-row > span:nth-child(2) { flex: 1; }
  .setmenu-row > .ic { width: 14px; height: 14px; color: var(--subtle); }
  .setmenu-row:active { background: var(--tint); }
  .setmenu-ic { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; background: color-mix(in srgb, var(--brand) 10%, var(--base)); color: var(--brand); }
  .setmenu-ic .ic { width: 16px; height: 16px; }
  .setback { align-items: center; gap: 2px; margin: 0 0 10px -6px; padding: 6px; border: 0; background: none; font: inherit; font-size: 15px; color: var(--link); cursor: pointer; }
  .setback-ic .ic { width: 16px; height: 16px; transform: rotate(180deg); }
}

/* Colour, round 17: #1100FF stays the light-theme brand (marks, accents). Primary buttons use a
   brighter, softer azure in the Cloudflare style: subtle top highlight, gently rounded, white text.
   Dark theme: lighter blues for buttons, links and accents, so they don't sit heavy on black. */
:root { --btn: #1a6dff; --btn-hover: #0d5ef0; --btn-edge: #0c57de; }
:root[data-theme="dark"] { --brand: #4a8dff; --brand-hover: #6aa1ff; --accent: #4a8dff; --accent-2: #6aa1ff; --link: #78acff;
  --btn: #3b82ff; --btn-hover: #5794ff; --btn-edge: #2f6fe0; --globe-fill: #3b7dff; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --brand: #4a8dff; --brand-hover: #6aa1ff; --accent: #4a8dff; --accent-2: #6aa1ff; --link: #78acff;
  --btn: #3b82ff; --btn-hover: #5794ff; --btn-edge: #2f6fe0; --globe-fill: #3b7dff; } }
button.primary, a.button.primary, button.primary.setup-go {
  background: linear-gradient(180deg, color-mix(in srgb, #fff 12%, var(--btn)), var(--btn)); color: #fff; border: 1px solid var(--btn-edge);
  border-radius: 8px; box-shadow: inset 0 1px 0 oklch(100% 0 0 / .28), 0 1px 2px oklch(0% 0 0 / .12); }
button.primary:hover, a.button.primary:hover, button.primary.setup-go:hover { background: linear-gradient(180deg, color-mix(in srgb, #fff 10%, var(--btn-hover)), var(--btn-hover)); }
button.primary:disabled { opacity: .55; }
button.primary.setup-go { border-radius: 10px; }

/* Setup fits one screen: no scrolling; tall steps are scaled down by onboarding.js. */
.setup { overflow: hidden; height: 100dvh; }
.setup-stage { min-height: 0; overflow: hidden; padding: 12px 24px 4vh; }
.setup-step { max-height: none; }
@media (max-height: 820px) {
  .setup-step h1 { font-size: clamp(24px, 3.4vw, 32px); }
  .setup-line { margin-bottom: 22px; }
  .setup-step h1 + :not(.setup-line) { margin-top: 20px; }
  .setup-actions { margin-top: 24px; }
  .setup-art { height: 140px; margin-bottom: 20px; }
  .setup-head { padding-top: 14px; padding-bottom: 14px; }
}
@media (max-height: 680px) {
  .setup-line { margin-bottom: 14px; font-size: 15px; }
  .setup-art { height: 110px; margin-bottom: 14px; }
  .setup-actions { margin-top: 16px; }
  .choice.big { padding: 14px 16px; }
}
.setup-ai { height: calc(100dvh - 260px); min-height: 0; }
@media (max-width: 640px) { .setup-ai { height: calc(100dvh - 220px); } .setup-stage { padding-top: 4px; } }

/* "What brings you here?": the website card featured on top, the other three evenly below. */
.choices.purpose { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.choices.purpose .choice.big { padding: 18px; gap: 12px; }
.choices.purpose .choice-ic { width: 40px; height: 40px; border-radius: 10px; background: color-mix(in srgb, var(--brand) 14%, var(--base)); color: var(--brand); }
.choices.purpose .choice-ic .ic { width: 20px; height: 20px; }
.choices.purpose .choice.featured { grid-column: 1 / -1; flex-direction: row; align-items: center; gap: 16px; padding: 20px 22px; }
.choices.purpose .choice.featured .choice-ic { width: 48px; height: 48px; border-radius: 12px; background: var(--brand); color: #fff; }
.choices.purpose .choice.featured .choice-ic .ic { width: 24px; height: 24px; }
.choices.purpose .choice.featured > .ic { margin-left: auto; width: 18px; height: 18px; color: var(--brand); flex: none; }
.choice-body { display: grid; gap: 4px; min-width: 0; flex: 1; }
.choice-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.choice-title b { font-size: 17px; }
.choices.purpose .choice-tag { width: fit-content; justify-self: start; margin: 0; padding: 2px 8px; font-size: 11px; line-height: 1.5; }
@media (max-width: 720px) { .choices.purpose { grid-template-columns: 1fr; } .choices.purpose .choice.big:not(.featured) { flex-direction: row; align-items: center; } }
.globe-card.art-nolabel > :not(canvas) { display: none; }

/* ======================================================================================
   ACCURE layer. Everything above is the MXO design system, unchanged. ACCURE keeps its tokens,
   type scale and components and adds: its own brand (the orange plus mark), document status
   pills, the AI home, the module kit (lists, forms, detail, boards), the inbox and confirm page.
   ====================================================================================== */

:root {
  --brand: #e2700a; --brand-hover: #c95f04; --accent: #e2700a; --accent-2: #c95f04;
  --brand-mark: #ffa239; --brand-ink: #1b1206;
  --btn: #ffa239; --btn-hover: #ff9a24; --btn-edge: #e98a1f; --btn-text: #1b1206;
  --link: oklch(48% .15 50);
  --debit: var(--text); --credit: var(--text); --negative: var(--danger);
  --brand-tint: color-mix(in srgb, #ffa239 16%, var(--base));
}
:root[data-theme="dark"] {
  --brand: #ffa239; --brand-hover: #ffb562; --accent: #ffa239; --accent-2: #ffb562; --link: #ffb870;
  --btn: #ffa239; --btn-hover: #ffb05a; --btn-edge: #e8891c; --btn-text: #1b1206;
  --brand-tint: color-mix(in srgb, #ffa239 14%, var(--base));
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --brand: #ffa239; --brand-hover: #ffb562; --accent: #ffa239; --accent-2: #ffb562; --link: #ffb870;
  --btn: #ffa239; --btn-hover: #ffb05a; --btn-edge: #e8891c; --btn-text: #1b1206;
  --brand-tint: color-mix(in srgb, #ffa239 14%, var(--base));
} }
button.primary, a.button.primary {
  background: linear-gradient(180deg, color-mix(in srgb, #fff 18%, var(--btn)), var(--btn)); color: var(--btn-text); border: 1px solid var(--btn-edge);
  box-shadow: inset 0 1px 0 oklch(100% 0 0 / .35), 0 1px 2px oklch(0% 0 0 / .12);
}
button.primary:hover, a.button.primary:hover { background: linear-gradient(180deg, color-mix(in srgb, #fff 14%, var(--btn-hover)), var(--btn-hover)); color: var(--btn-text); }
a.button.primary { justify-content: center; font-weight: 500; }
input:focus, select:focus, textarea:focus { box-shadow: 0 0 0 1.5px var(--brand); }
.num, td.num, .amount { font-variant-numeric: tabular-nums; }
main.wide { max-width: 1440px; }

/* Brand lockup: the orange square plus, wordmark beside it. */
.brandmark { display: inline-flex; align-items: center; gap: 9px; color: var(--strong); font-weight: 650; letter-spacing: .06em; font-size: 14px; }
.brandmark:hover { text-decoration: none; }
.brandmark img { width: 26px; height: 26px; border-radius: 6px; box-shadow: 0 1px 2px oklch(0% 0 0 / .15); }
.lockup .logo { width: 48px; height: 48px; border-radius: 11px; box-shadow: 0 6px 16px -6px #ffa23999, 0 1px 2px oklch(0% 0 0 / .15); }
.lockup b { letter-spacing: .08em; }

/* Org switcher (searchable popover) */
.orgswitch { position: relative; flex: 1; min-width: 0; }
.orgswitch > button { display: flex; align-items: center; gap: 8px; width: 100%; min-width: 0; padding: 6px 8px; border: 0; border-radius: var(--radius); background: none; font: inherit; color: var(--text); cursor: pointer; text-align: left; }
.orgswitch > button:hover { background: var(--tint); }
.orgswitch > button > span:not(.avatar) { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.orgswitch > button small { color: var(--subtle); font-weight: 400; }
.orgswitch .popover { left: 0; right: auto; width: 300px; max-height: 70vh; overflow-y: auto; }
.orgswitch .popover input { margin: 4px 4px 6px; width: calc(100% - 8px); }
.orgswitch .popover .org-item small { margin-left: auto; color: var(--subtle); font-size: 12px; }
.orgswitch .popover .org-item.on { background: var(--recessed); }
.orgswitch .grp { padding: 6px 10px 2px; font-size: 11px; font-weight: 600; color: var(--subtle); text-transform: uppercase; letter-spacing: .05em; }
.avatar { display: inline-grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 6px; background: var(--brand-tint); color: var(--brand); font-size: 11px; font-weight: 650; }

/* Count badges in the sidebar and on the bell */
.count { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; margin-left: auto; border-radius: 9px; background: var(--brand-mark); color: var(--brand-ink); font-size: 11px; font-weight: 600; }
.iconbtn { position: relative; }
.iconbtn .count { position: absolute; top: 2px; right: 0; margin: 0; min-width: 16px; height: 16px; font-size: 10px; }

/* Document status pills (planning/UI/design-system.md) */
.st { display: inline-flex; align-items: center; gap: 5px; padding: 1px 8px; border-radius: 99px; font-size: 12px; font-weight: 500; background: var(--fill); color: var(--text); white-space: nowrap; }
.st::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .75; }
.st.pending, .st.draft-pending, .st.T2 { background: var(--warning-tint); color: var(--warning); }
.st.approved, .st.posted, .st.executed, .st.paid, .st.done, .st.active { background: var(--success-tint); color: var(--success); }
.st.sent, .st.info, .st.T1 { background: var(--info-tint); color: var(--link); }
.st.overdue, .st.failed, .st.T3, .st.rejected { background: var(--danger-tint); color: var(--danger); }
.st.locked, .st.cancelled, .st.expired { background: var(--recessed); color: var(--subtle); }

/* Legal pack honesty banner */
.draftnote { display: flex; gap: 10px; align-items: flex-start; padding: 10px 14px; border-radius: var(--radius); background: var(--warning-tint); color: var(--text); font-size: 13px; margin: 12px 0; border: 1px solid color-mix(in srgb, var(--warning) 25%, transparent); }
.draftnote .ic { color: var(--warning); margin-top: 1px; }

/* AI home */
.aihome { max-width: 820px; margin: 0 auto; }
.aihome-hero { text-align: center; padding: 3vh 0 8px; }
.aihome-hero img { width: 56px; height: 56px; border-radius: 13px; box-shadow: 0 10px 28px -10px #ffa239aa; }
.aihome-hero h1 { font-size: 30px; font-weight: 600; letter-spacing: -.025em; margin: 14px 0 4px; }
.aihome-hero p { color: var(--subtle); margin: 0; }
.composer { position: relative; margin: 22px 0 10px; border: 1px solid var(--line); border-radius: 16px; background: var(--base); box-shadow: 0 1px 2px oklch(0% 0 0 / .04), 0 8px 24px -16px oklch(0% 0 0 / .25); }
.composer:focus-within { box-shadow: 0 0 0 1.5px var(--brand), 0 8px 24px -16px oklch(0% 0 0 / .25); }
.composer textarea { min-height: 72px; border: 0; box-shadow: none; background: none; resize: none; padding: 16px 18px 6px; font-size: 15px; }
.composer textarea:focus { box-shadow: none; }
.composer .bar { display: flex; align-items: center; gap: 8px; padding: 6px 8px 8px 16px; color: var(--subtle); font-size: 12px; }
.composer .bar .grow { min-width: 0; }
.composer .send { width: 34px; height: 34px; padding: 0; border-radius: 10px; }
.chipsrow { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 4px 0 24px; }
.chipsrow button { border: 1px solid var(--line); background: var(--base); border-radius: 99px; padding: 6px 12px; font: inherit; font-size: 13px; color: var(--text); cursor: pointer; }
.chipsrow button:hover { background: var(--tint); }
.brief { display: grid; gap: 8px; }
.brief-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--base); color: var(--text); }
a.brief-item:hover { background: var(--elevated); text-decoration: none; }
.brief-item .bi { display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 8px; background: var(--recessed); color: var(--subtle); }
.brief-item.due .bi { background: var(--warning-tint); color: var(--warning); }
.brief-item.todo .bi { background: var(--brand-tint); color: var(--brand); }
.brief-item.warn .bi { background: var(--danger-tint); color: var(--danger); }
.brief-item b { display: block; font-weight: 500; color: var(--strong); }
.brief-item span { color: var(--subtle); font-size: 13px; }
.brief-item .when { margin-left: auto; color: var(--subtle); font-size: 12px; white-space: nowrap; }
.sectionhead { display: flex; align-items: baseline; gap: 10px; margin: 28px 0 10px; }
.sectionhead h2 { margin: 0; }
.sectionhead a, .sectionhead button { margin-left: auto; font-size: 13px; }

/* Assistant panel (shares MXO's .assistant frame) */
.assistant .as-top .brandmark img { width: 22px; height: 22px; }
.assistant .as-top b { margin-left: 8px; }
.assistant .as-body { display: flex; flex-direction: column; }
.as-msg.ai .md > :first-child { margin-top: 0; } .as-msg.ai .md > :last-child { margin-bottom: 0; }
.as-msg.ai .md h4 { margin: 6px 0 4px; font-size: 14px; color: var(--strong); }
.as-msg.ai .md ul, .as-msg.ai .md ol { padding-left: 18px; margin: 6px 0; }
.as-tools { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.as-tool { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--subtle); background: var(--base); border: 1px solid var(--line); border-radius: 99px; padding: 2px 9px; }
.as-tool.running::after { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid var(--brand); border-right-color: transparent; animation: spin .7s linear infinite; }
.as-tool.failed { color: var(--danger); }
@keyframes spin { to { transform: rotate(360deg); } }
.as-input .row { margin: 0; align-items: center; }
.as-input .hint { color: var(--subtle); font-size: 12px; flex: 1; }
.as-history { padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; }
.as-history button { display: flex; align-items: center; gap: 8px; text-align: left; border: 0; background: none; padding: 7px 8px; border-radius: var(--radius); font: inherit; color: var(--text); cursor: pointer; }
.as-history button:hover { background: var(--tint); }
.as-history button span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.typing { display: inline-flex; gap: 3px; padding: 4px 0; }
.typing i { width: 5px; height: 5px; border-radius: 50%; background: var(--subtle); animation: blink 1.2s infinite; }
.typing i:nth-child(2) { animation-delay: .2s; } .typing i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }

/* Pending action card (assistant, inbox) */
.pcard { border: 1px solid color-mix(in srgb, var(--brand) 35%, var(--line)); background: var(--base); border-radius: 12px; padding: 12px 14px; margin: 8px 0; }
.pcard .ph { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--subtle); }
.pcard .ph .st { margin-left: auto; }
.pcard p { margin: 6px 0 10px; color: var(--strong); font-weight: 500; }
.pcard .row { margin: 0; gap: 8px; }
.pcard details { margin-top: 6px; font-size: 12px; }
.pcard pre { max-height: 220px; font-size: 12px; }

/* Module kit */
.kit-toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 16px 0 10px; }
.kit-toolbar input[type="search"] { min-width: 220px; flex: 1; max-width: 360px; }
.kit-list tbody tr { cursor: pointer; }
.kit-empty { text-align: center; padding: 40px 16px; color: var(--subtle); }
.kit-empty .ic { width: 28px; height: 28px; color: var(--brand); }
.kit-empty b { display: block; color: var(--strong); font-weight: 500; margin: 8px 0 2px; font-size: 15px; }
.kit-form { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px 16px; }
.kit-form .field.wide { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 500; color: var(--subtle); }
.field > input, .field > select, .field > textarea { width: 100%; font-size: 14px; font-weight: 400; color: var(--text); }
.field > textarea { min-height: 90px; }
.field small { font-weight: 400; }
.field .req { color: var(--brand); }
label.check { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; color: var(--text); font-weight: 400; }
label.check input { margin-top: 2px; }
.kit-detail { display: grid; grid-template-columns: minmax(140px, 220px) 1fr; gap: 0; margin: 0; }
.kit-detail dt, .kit-detail dd { padding: 9px 0; border-bottom: 1px solid var(--hairline); margin: 0; }
.kit-detail dt { color: var(--subtle); font-size: 13px; }
.kit-board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; align-items: start; }
.kit-col { background: var(--recessed); border-radius: 12px; padding: 8px; min-height: 120px; border: 1px solid var(--hairline); }
.kit-col.drop { box-shadow: inset 0 0 0 2px var(--brand); }
.kit-col h3 { display: flex; align-items: center; gap: 8px; margin: 4px 6px 8px; font-size: 13px; font-weight: 600; color: var(--strong); }
.kit-col h3 small { color: var(--subtle); font-weight: 500; }
.kit-card { background: var(--base); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; cursor: grab; box-shadow: 0 1px 1px oklch(0% 0 0 / .03); }
.kit-card:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
.kit-card b { display: block; font-weight: 500; color: var(--strong); }
.kit-card span { color: var(--subtle); font-size: 12px; }
.kit-card.dragging { opacity: .5; }

/* Inbox */
.inbox-item { display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--hairline); }
.inbox-item:last-child { border-bottom: 0; }
.inbox-item .meta { color: var(--subtle); font-size: 12px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.inbox-item b { color: var(--strong); font-weight: 500; }
.inbox-item .row { margin: 0; gap: 8px; }

/* Onboarding (create company) */
.onboard { max-width: 560px; margin: 4vh auto; }
.onboard .card { padding: 28px; }
.onboard h1 { font-size: 24px; }
.found { display: flex; gap: 14px; padding: 14px; border-radius: 12px; background: var(--brand-tint); border: 1px solid color-mix(in srgb, var(--brand) 25%, transparent); margin: 12px 0; }
.found b { display: block; color: var(--strong); font-size: 15px; }
.found span { color: var(--subtle); font-size: 13px; display: block; }

/* Confirm page */
.confirm { max-width: 520px; margin: 6vh auto; padding: 0 16px; }
.confirm .card { padding: 26px; }
.confirm h1 { font-size: 21px; line-height: 1.3; }
.confirm .what { font-size: 17px; font-weight: 500; color: var(--strong); margin: 10px 0 16px; line-height: 1.4; }
.confirm .actions { display: flex; flex-direction: column; gap: 8px; margin-top: 18px; }
.confirm .actions button { min-height: 44px; font-size: 15px; }
.confirm .done { text-align: center; padding: 10px 0; }
.confirm .done .ic { width: 40px; height: 40px; color: var(--success); }

/* Sign-in page: single column variant */
.auth.single { grid-template-columns: minmax(0, 420px); }
.auth-hero.accure { border-radius: 21px; padding: 5px; background: color-mix(in srgb, #ffa239 30%, var(--line)); }
.auth-hero.accure .inner { height: 100%; border-radius: 16px; padding: 30px; color: var(--brand-ink); background:
  radial-gradient(120% 80% at 100% 0%, #ffd29c 0%, transparent 60%), linear-gradient(160deg, #ffb35c, #ff9424); display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.auth-hero.accure .inner::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 280px; height: 280px; opacity: .09; transform: rotate(-8deg);
  background: linear-gradient(var(--brand-ink), var(--brand-ink)) center / 18% 100% no-repeat, linear-gradient(var(--brand-ink), var(--brand-ink)) center / 100% 18% no-repeat; border-radius: 40px; }
.auth-hero.accure h2 { color: var(--brand-ink); font-size: 28px; max-width: 16ch; }
.auth-hero.accure ul { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 8px; font-size: 14px; position: relative; z-index: 1; }
.auth-hero.accure li { display: flex; gap: 8px; align-items: center; }
.auth-hero.accure li .ic { color: var(--brand-ink); }
.langswitch { display: inline-flex; gap: 2px; margin-left: auto; }
.langswitch button { border: 0; background: none; font: inherit; font-size: 12px; color: var(--subtle); padding: 3px 7px; border-radius: 6px; cursor: pointer; }
.langswitch button.on { background: var(--fill); color: var(--strong); }
.consent-list { margin: 4px 0; padding-left: 18px; color: var(--subtle); }
.consent-list li { margin: 3px 0; }

/* Settings */
.kv { display: grid; grid-template-columns: 160px 1fr; gap: 8px 16px; font-size: 14px; }
.kv dt { color: var(--subtle); }
.kv dd { margin: 0; }
.copyrow { display: flex; gap: 8px; align-items: center; }
.copyrow code { flex: 1; padding: 8px 10px; overflow-x: auto; white-space: nowrap; }
.rules-path { font-family: var(--mono); font-size: 12.5px; }
.rules-crumbs { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; font-family: var(--mono); font-size: 12.5px; margin: 10px 0; }
.rules-crumbs button { border: 0; background: none; color: var(--link); cursor: pointer; font: inherit; padding: 0; }

/* Fixes after visual review */
nav.side .recents a.navitem.recent { display: block; width: 100%; text-align: left; padding: 6px 10px; color: var(--subtle); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
nav.side .recents a.navitem.recent span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.as-input { align-self: stretch; }
.as-input textarea { width: 100%; }
.as-input textarea:focus, .composer textarea:focus { box-shadow: none; }
.aipage .as-body { flex: 1; overflow: auto; padding: 16px 0; }
.aipage .as-body > *, .aipage .as-input { width: min(780px, calc(100% - 48px)); margin-left: auto; margin-right: auto; }
.aipage .as-body > .as-msg.me { margin-left: auto; margin-right: max(24px, calc((100% - 780px) / 2)); width: auto; max-width: min(640px, 80%); }
.aipage .as-input { margin-bottom: 20px; }
.aipage .as-input textarea { min-height: 56px; font-size: 15px; }
.aipage-side { width: 250px; flex: none; border-right: 1px solid var(--line); overflow: auto; background: var(--elevated); }
.aipage-side button.on { background: var(--recessed); font-weight: 500; }
.aipage-side small { margin-left: auto; white-space: nowrap; }
@container app (max-width: 820px) { .aipage-side { display: none; } }
@container app (max-width: 640px) { #ask-ai kbd { display: none; } }
.confirm form.card { display: flex; flex-direction: column; gap: 12px; }
.confirm form.card h1 { margin: 0; }
.confirm form.card .field select { width: 100%; }

/* Phone: summary tiles two per row everywhere (integrator polish) */
@media (max-width: 640px) {
  .tiles { gap: 10px; margin: 16px 0; }
  .tiles > *, .tiles > .tile { flex: 1 1 calc(50% - 10px); min-width: 0; }
  .tile { padding: 12px 14px; }
  .tile .value { font-size: 18px; }
}

/* ---- WP5: notifications bell, support banner, palette records -------------------------------- */
.notifpop { width: min(380px, calc(100vw - 24px)); max-height: min(70vh, 560px); overflow-y: auto; padding: 6px; }
.notifpop .notif-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.notifpop .notif-item { display: flex; align-items: flex-start; gap: 10px; padding: 9px 10px; border-radius: var(--radius); color: var(--text); text-decoration: none; }
.notifpop .notif-item:hover { background: var(--tint); text-decoration: none; }
.notifpop .notif-item > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.notifpop .notif-item b { font-weight: 450; color: var(--text); overflow-wrap: anywhere; }
.notifpop .notif-item.unread b { font-weight: 600; color: var(--strong); }
.notifpop .notif-item.unread::after { content: ""; flex: none; width: 7px; height: 7px; margin: 6px 0 0 auto; border-radius: 50%; background: var(--brand); }
.notifpop .notif-item.todo { background: var(--warning-tint); color: var(--warning); }
.notifpop .notif-item .ic { flex: none; margin-top: 2px; color: var(--subtle); }
.notifpop a:not(.notif-item) { display: inline-flex; padding: 6px; font-size: 13px; }
.linkbtn { background: none; border: 0; padding: 2px 4px; color: var(--brand); font: inherit; font-size: 13px; cursor: pointer; }
.linkbtn:hover { text-decoration: underline; }
.notif-row.unread b { color: var(--strong); }
.notif-row.unread { box-shadow: inset 3px 0 0 var(--brand); }
.notif-row .bi .ic { color: var(--subtle); margin-top: 3px; }
.impbar { display: flex; align-items: center; gap: 10px; padding: 7px 16px; background: var(--warning-tint); color: var(--warning); font-size: 13px; border-bottom: 1px solid var(--line); flex: none; }
.impbar span { flex: 1; min-width: 0; }
.impbar button { padding: 3px 10px; font-size: 12px; }
@media (max-width: 640px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .impbar { flex-wrap: wrap; } }
