/* Bothy landing page. Tokens and layout follow the Fury Goods family stylesheet.
   The UI previews (.ui) use the extension's own tokens, appended at build time
   by scripts/lib/demo.mjs. */
:root {
  color-scheme: light;
  --ink: #182628;
  --dark-green: #244542;
  --cream: #f6f0e1;
  --paper: #fbf8ef;
  --card: #fffdf8;
  --band: #eeede2;
  --honey: #e3b763;
  --muted: #4b5e5a;
  --line: #d8d9cd;
  --focus: #b56d15;
  --hero-text: #eee7d5;
  --hero-note: #d9d1bd;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.62 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; overflow-wrap: break-word; }
a { color: inherit; text-underline-offset: .2em; }
a:hover { text-decoration-thickness: .13em; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.site-header :focus-visible, .site-footer :focus-visible, .hero :focus-visible { outline-color: var(--honey); }
img, svg { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { margin: 0; font-weight: 700; line-height: 1.1; letter-spacing: -.03em; }
h1, h2 { font-family: Georgia, 'Times New Roman', serif; }
h1 { font-size: clamp(2.4rem, 1.6rem + 4vw, 5rem); }
h2 { font-size: clamp(1.9rem, 1.4rem + 2.4vw, 3.1rem); }
h3 { font-size: clamp(1.15rem, 1.05rem + .5vw, 1.35rem); letter-spacing: -.02em; }
p { margin: 0; }
p + p { margin-top: .8rem; }
code { font: .9em ui-monospace, Consolas, monospace; background: var(--band); padding: .05rem .3rem; border-radius: .25rem; overflow-wrap: anywhere; }
kbd { font: .85rem ui-monospace, Consolas, monospace; padding: .05rem .35rem; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: .3rem; background: var(--card); white-space: nowrap; }
.wrap { width: min(100% - 2rem, 74rem); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; top: 0; left: .75rem; transform: translateY(-125%); padding: .65rem 1rem; background: var(--honey); color: var(--ink); z-index: 2; }
.skip:focus { transform: translateY(0); }

/* header and footer */
.site-header, .site-footer { background: var(--ink); color: var(--cream); }
.header-inner, .footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .25rem 1.5rem; }
.header-inner { min-height: 4.5rem; padding-block: .35rem; }
.brand { display: inline-flex; align-items: center; gap: .5rem; min-height: 44px; text-decoration: none; font-weight: 760; font-size: 1.1rem; letter-spacing: -.025em; white-space: nowrap; }
.brand img { border-radius: .4rem; }
.site-header nav, .site-footer nav { display: flex; flex-wrap: wrap; column-gap: 1.25rem; font-size: .95rem; }
.site-header nav a, .site-footer nav a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.site-header nav a:hover, .site-header nav a[aria-current="page"], .site-footer nav a:hover { text-decoration: underline; }
.footer-inner { padding-block: 1rem; }
.footer-inner p a { display: inline-block; padding-block: .6rem; }

/* hero */
.hero { background: var(--ink); color: var(--cream); border-bottom: .3rem solid var(--honey); }
.hero-inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(1.5rem, 4vw, 4rem); align-items: center; padding-block: clamp(1.75rem, 5vw, 4.5rem) clamp(2.5rem, 6vw, 5.5rem); }
.hero-copy > p:first-of-type { max-width: 36rem; margin-top: 1.25rem; font-size: clamp(1rem, .95rem + .3vw, 1.15rem); color: var(--hero-text); }
.cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.6rem; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .55rem 1.2rem; border-radius: .45rem; font-weight: 700; text-decoration: none; border: 2px solid var(--honey); text-align: center; }
.button.primary { background: var(--honey); color: var(--ink); }
.button.secondary { color: var(--honey); }
.button:hover { text-decoration: underline; }
.status-note { max-width: 36rem; margin-top: 1rem; font-size: .95rem; color: var(--hero-note); }
.hero .preview figcaption { color: var(--hero-note); }

/* sections */
.section { padding-block: clamp(2.5rem, 6vw, 5.5rem); }
.section + .section { border-top: 1px solid var(--line); }
.section h2 { margin-bottom: .9rem; }
.lede { max-width: 46rem; font-size: clamp(1.02rem, .98rem + .25vw, 1.12rem); color: var(--muted); margin-bottom: 2rem; }
.more { margin-top: 1.5rem; }
.sub-h, .facts-h { margin: 2.5rem 0 1rem; }

/* tour: copy beside a preview of the real UI */
.tour { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(2.5rem, 6vw, 4.5rem); }
.stop { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1fr); gap: clamp(1.25rem, 4vw, 3.5rem); align-items: center; }
.stop:nth-child(even) .stop-copy { order: 2; }
.stop-copy h3 { margin-bottom: .6rem; }
.stop-copy p { max-width: 34rem; }
.preview { margin: 0; min-width: 0; }
.preview figcaption { margin-top: .6rem; font-size: .9rem; color: var(--muted); }
.preview .ui-popup { margin-inline: auto; }

/* definition-style fact lists, not boxed cards */
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem 3rem; margin: 0; }
.facts div { border-top: 2px solid var(--ink); padding-top: .7rem; }
.facts dt { font-weight: 700; font-size: 1.08rem; }
.facts dd { margin: .3rem 0 0; }

/* comparison table */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: .5rem; background: var(--card); }
.table-wrap:focus-visible { outline-offset: 2px; }
table { border-collapse: collapse; width: 100%; }
.section table { min-width: 44rem; }
caption { text-align: left; padding: .8rem 1rem; font-weight: 700; }
th, td { text-align: left; padding: .7rem 1rem; border-top: 1px solid var(--line); vertical-align: top; }
thead th { background: var(--band); }
tbody th { font-weight: 650; }
tbody td:first-of-type { background: #f4f1e6; font-weight: 600; }
.table-note { margin-top: .7rem; font-size: .9rem; color: var(--muted); }
.downloads td a { display: inline-block; padding-block: .25rem; } /* at least 24px tall to tap */

/* data section */
.two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 3rem; }
.two-col h3 { margin-bottom: .6rem; }
.two-col ul { margin: 0; padding-left: 1.2rem; display: grid; gap: .35rem; }

/* import steps */
.steps { counter-reset: step; display: grid; gap: 1rem; padding: 0; margin: 0; list-style: none; max-width: 52rem; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 2.4rem minmax(0, 1fr); gap: .9rem; align-items: start; }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--dark-green); color: var(--cream); font-weight: 700; }
.steps strong { display: block; }

/* install band and FAQ */
.install-band { background: var(--band); }
.browser-list { margin: 0 0 1.5rem; padding-left: 1.2rem; display: grid; gap: .5rem; max-width: 52rem; }
.install-band .button.primary { background: var(--dark-green); border-color: var(--dark-green); color: var(--cream); }
.faq-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.6rem 3rem; }
.qa h3 { font-size: 1.1rem; margin-bottom: .4rem; }

/* inner pages */
.crumbs { padding-top: 1.2rem; font-size: .92rem; }
.crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin: 0; padding: 0; list-style: none; }
.crumbs li + li::before { content: "/"; margin-right: .4rem; color: var(--muted); }
.crumbs a { display: inline-block; padding-block: .6rem; }
.simple { min-height: 55vh; max-width: 48rem; padding-block: clamp(1.5rem, 6vw, 4.5rem); }
.simple h1 { font-size: clamp(2.3rem, 1.7rem + 3vw, 4rem); }
.simple h2 { font-size: clamp(1.45rem, 1.2rem + 1.2vw, 2rem); margin-top: 2.2rem; }
.simple p, .simple ul, .simple ol, .simple .table-wrap { margin-top: 1rem; }
.simple li + li { margin-top: .45rem; }
.status-box { border-left: 4px solid var(--focus); background: var(--card); padding: .9rem 1rem; }
.downloads code { font-size: .8rem; }
.howto { padding-left: 1.4rem; }

/* ---------- UI previews: markup from scripts/lib/demo.mjs ---------- */
.ui { container-type: inline-size; font: 14px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: .6rem; overflow: hidden; box-shadow: 0 1rem 2.4rem #111b1d40; letter-spacing: normal; }
.ui .btn { display: inline-flex; align-items: center; min-height: 28px; padding: .15rem .65rem; border: 1px solid var(--line); border-radius: .4rem; background: var(--surface); white-space: nowrap; font-size: .85rem; }
.ui .btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 650; }
.ui .btn.danger { color: var(--danger); }
.ui .brand { font-size: 1rem; min-height: 0; gap: .4rem; }
.ui .brand img { border-radius: .3rem; }
.ui-manager .bar { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem .7rem; padding: .55rem .75rem; background: #182628; color: #f6f0e1; border-bottom: 3px solid var(--honey); }
.ui-manager .search { flex: 1 1 9rem; min-width: 0; background: #fffdf8; color: #4b5e5a; border-radius: .4rem; padding: .25rem .6rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ui-manager .search.filled { color: #182628; }
.ui-manager .view { display: inline-flex; gap: .25rem; }
.ui-manager .bar .btn { background: transparent; color: inherit; border-color: #ffffff40; }
.ui-manager .bar .btn.pressed { background: var(--honey); color: #182628; border-color: var(--honey); font-weight: 650; }
.ui-manager .summary { margin: 0; padding: .45rem .75rem; color: var(--muted); }
.ui-manager .vlist { margin: 0 .75rem .75rem; border: 1px solid var(--line); border-radius: .5rem; background: var(--surface); overflow: hidden; }
.ui-manager .row { display: flex; align-items: center; gap: .5rem; height: 40px; padding: 0 .6rem; border-bottom: 1px solid var(--line); }
.ui-manager .row:last-child { border-bottom: 0; }
.ui-manager .row.lv-2 { padding-left: calc(.6rem + 22px); }
.ui-manager .row.lv-3 { padding-left: calc(.6rem + 44px); }
.ui-manager .row.lv-4 { padding-left: calc(.6rem + 66px); }
.ui-manager .row.session { background: var(--surface-2); font-weight: 650; }
.ui-manager .row.active { background: var(--row-active); box-shadow: inset 3px 0 0 var(--focus); }
.ui-manager .twisty { width: 1.2rem; text-align: center; flex: none; color: var(--muted); }
.ui-manager .label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ui-manager .sub { color: var(--muted); font-weight: 400; font-size: .85rem; margin-left: .5rem; }
.ui-manager .flags, .ui-manager .tools { flex: none; display: inline-flex; gap: .25rem; }
.ui-manager .tools .btn { min-height: 26px; padding: .05rem .45rem; font-size: .8rem; font-weight: 500; }
.ui .badge { display: inline-block; padding: 0 .4rem; border-radius: 1rem; font-size: .76rem; font-weight: 400; background: var(--surface); color: var(--muted); border: 1px solid var(--line); }
.ui .avatar { flex: none; width: 20px; height: 20px; border-radius: 4px; display: grid; place-items: center; color: #fff; font-size: .72rem; font-weight: 700; }
.ui .gdot { flex: none; width: .65rem; height: .65rem; border-radius: 50%; }
.ui-popup { max-width: 360px; }
.ui-popup .top { display: flex; justify-content: space-between; align-items: center; padding: .5rem .7rem; background: #182628; color: #f6f0e1; border-bottom: 3px solid var(--honey); }
.ui-popup .top .btn { background: transparent; color: inherit; border-color: #ffffff44; }
.ui-popup .body { padding: .7rem; display: grid; gap: .45rem; }
.ui-popup .btn.wide { display: flex; justify-content: space-between; min-height: 40px; font-size: inherit; white-space: normal; }
.ui-popup .count { font-variant-numeric: tabular-nums; }
.ui-popup .label { margin: .2rem 0 0; font-size: .85rem; color: var(--muted); }
.ui-popup .chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.ui-popup .chip { display: inline-flex; align-items: center; min-height: 28px; padding: .1rem .7rem; border: 1px solid var(--line); border-left-width: 6px; border-radius: 1rem; background: var(--surface); font-size: .85rem; }
.ui-popup .check { display: flex; gap: .45rem; align-items: center; font-size: .9rem; min-height: 28px; }
.ui-popup .box { width: 15px; height: 15px; flex: none; border: 1.5px solid var(--muted); border-radius: 3px; background: var(--surface); }
.ui-popup .recent-h { margin: .3rem 0 0; font-weight: 700; font-size: .95rem; }
.ui-popup .recent { list-style: none; margin: 0; padding: 0; display: grid; gap: .25rem; }
.ui-popup .recent li { display: flex; gap: .5rem; align-items: center; justify-content: space-between; padding: .35rem .5rem; border: 1px solid var(--line); border-radius: .4rem; background: var(--surface); }
.ui-popup .info { display: grid; min-width: 0; }
.ui-popup .name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.ui-popup .meta { font-size: .8rem; color: var(--muted); }
.ui-dialog { background: var(--surface); padding: 1rem 1.1rem 1.2rem; }
.ui-dialog .dlg-title { margin: 0 0 .6rem; font: 700 1.3rem/1.2 Georgia, 'Times New Roman', serif; letter-spacing: -.02em; }
.ui-dialog .row-buttons { display: flex; flex-wrap: wrap; gap: .4rem; }
.ui-dialog .dlg-h3 { margin: .9rem 0 .35rem; font-weight: 700; }
.ui-dialog table { min-width: 0; font-size: .85rem; border: 1px solid var(--line); }
.ui-dialog th, .ui-dialog td { padding: .3rem .5rem; border-top: 0; border-bottom: 1px solid var(--line); vertical-align: middle; }
.ui-dialog tbody td:first-of-type { background: none; font-weight: 400; }
.ui-dialog thead th { background: var(--surface-2); font-weight: 650; }
@container (max-width: 30rem) {
  .ui .wide-only, .ui-manager .sub { display: none; }
  .ui-manager .flags .badge + .badge { display: none; }
}

@media (max-width: 56rem) {
  .hero-inner, .stop { grid-template-columns: minmax(0, 1fr); }
  .stop:nth-child(even) .stop-copy { order: 0; }
}
@media (max-width: 44rem) {
  .facts, .two-col, .faq-list { grid-template-columns: minmax(0, 1fr); }
  /* The comparison table becomes one card per need, so nothing is cut off at the right edge. */
  #compare .table-wrap { overflow: visible; border: 0; background: none; }
  #compare table { min-width: 0; }
  #compare caption { display: block; padding: 0 0 .8rem; }
  #compare thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  #compare tbody, #compare tr, #compare th, #compare td { display: block; }
  #compare tbody { display: grid; gap: .9rem; }
  #compare tr { border: 1px solid var(--line); border-radius: .5rem; background: var(--card); overflow: hidden; }
  #compare tbody th { border-top: 0; background: var(--band); font-size: 1.02rem; }
  #compare td { padding-block: .55rem; }
  #compare td::before { content: attr(data-label); display: block; font-size: .85rem; font-weight: 700; color: var(--muted); }
  #compare tbody td:first-of-type::before { color: var(--dark-green); }
  .site-header nav { column-gap: .9rem; }
}
@media (min-width: 110rem) {
  html { font-size: 106.25%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* UI preview tokens, generated from src/ui/theme.css and src/manager/manager.css */
.ui { --bg: #fbf8ef; --surface: #fffdf8; --surface-2: #f2efe4; --ink: #182628; --muted: #4b5e5a; --line: #d8d9cd; --accent: #244542; --accent-ink: #fbf8ef; --honey: #e3b763; --danger: #9b2c1f; --focus: #b56d15; --row-hover: #f1ecdd; --row-active: #e9e2cc; --selected: #dfe9e3; }
.ui .c-grey { background: #8a8f8c; }
.ui .c-blue { background: #3b78d8; }
.ui .c-red { background: #d9473b; }
.ui .c-yellow { background: #e3b763; }
.ui .c-green { background: #3c9a5f; }
.ui .c-pink { background: #d6589b; }
.ui .c-purple { background: #8e5bd6; }
.ui .c-cyan { background: #2ea3b5; }
.ui .c-orange { background: #e07b2f; }
.ui .av-0 { background: #355c5a; }
.ui .av-1 { background: #244542; }
.ui .av-2 { background: #6b3e5e; }
.ui .av-3 { background: #5b4a8a; }
.ui .av-4 { background: #8a3b2e; }
.ui .av-5 { background: #4a6b2f; }
.ui .av-6 { background: #3d5a80; }
.ui .chip-grey { border-left-color: #8a8f8c; }
.ui .chip-blue { border-left-color: #3b78d8; }
.ui .chip-red { border-left-color: #d9473b; }
.ui .chip-yellow { border-left-color: #e3b763; }
.ui .chip-green { border-left-color: #3c9a5f; }
.ui .chip-pink { border-left-color: #d6589b; }
.ui .chip-purple { border-left-color: #8e5bd6; }
.ui .chip-cyan { border-left-color: #2ea3b5; }
.ui .chip-orange { border-left-color: #e07b2f; }
