/* AI Find Me design system (2026-11-22 refresh). Tokens first (colour, type, space, radius, shadow), light and dark
   through prefers-color-scheme (and the .theme-light / .theme-dark containers the style guide uses), then the
   components every page is built from. One accent (emerald) on a cool, quiet neutral; deep ink for the Human · AI
   switch and the AI-ready mark; the system sans for everything, set heavy and tight for headings, so the site looks the
   same on an iPhone, an Android phone and a desktop; mono only for code and the AI view's labels. Every text colour
   meets WCAG AA on the surfaces it is used on, in both themes. Motion only when the system allows it. No frameworks,
   no third-party assets, no inline styles (the Content-Security-Policy forbids them). Comfortable from 360px up. */

:root {
  /* Colour: quiet cool neutrals, emerald as the single accent, ink for the switch. */
  --bg: #f6f7f5;
  --bg-soft: #eef1ee;
  --surface: #ffffff;
  --surface-2: #f1f4f1;
  --text: #111a16;
  --text-soft: #37433d;
  --muted: #59665f;
  --line: #e1e6e2;
  --line-strong: #c9d1cb;
  --field-line: #85908a; /* form field borders: at least 3:1 against the page */
  --accent: #0b7449;
  --accent-hover: #075c39;
  --accent-soft: #e0f3e8;
  --accent-text: #ffffff;
  --ink: #0f1c16;
  --ink-text: #f6f7f5;
  --ok: #10703f;
  --ok-bg: #def2e6;
  --warn: #8a4709;
  --warn-bg: #fcebd8;
  --danger: #a12a2a;
  --danger-bg: #fbe4e4;
  --note-bg: #e6f2eb;
  --focus: #0b7449;
  --header-bg: rgba(246, 247, 245, 0.86);
  --hero-bg: radial-gradient(60% 90% at 0% 0%, #d9f0e3 0%, rgba(217, 240, 227, 0) 70%), radial-gradient(45% 70% at 100% 10%, #e3eee8 0%, rgba(227, 238, 232, 0) 70%), linear-gradient(180deg, #f0f5f2 0%, #f6f7f5 100%);
  --hero-dots: radial-gradient(rgba(17, 26, 22, 0.08) 1px, transparent 1.2px);
  --code-bg: #edf1ee;
  --band-bg: #0f1c16; /* the dark call-to-action band */
  --band-text: #f6f7f5;

  /* Type: one sans family. Headings heavy and tight; mono for code and the AI view's labels. */
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", Roboto, Inter, "Helvetica Neue", Arial, sans-serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", Roboto, Inter, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.3125rem;
  --text-2xl: 1.625rem;
  --text-3xl: clamp(1.75rem, 1.1rem + 2.2vw, 2.375rem);
  --text-4xl: clamp(2.125rem, 1.2rem + 3.6vw, 3.5rem);
  --leading: 1.6;
  --leading-tight: 1.15;

  /* Space, radius, shadow */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 2.5rem;
  --space-8: 3rem;
  --space-10: 4.5rem;
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-full: 999px;
  --shadow-sm: 0 1px 2px rgba(16, 28, 22, 0.05), 0 1px 1px rgba(16, 28, 22, 0.03);
  --shadow: 0 4px 16px rgba(16, 28, 22, 0.07), 0 1px 3px rgba(16, 28, 22, 0.05);
  --shadow-lg: 0 18px 44px rgba(16, 28, 22, 0.12);
  --content: 1140px;
  --narrow: 46rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b100e;
    --bg-soft: #0f1513;
    --surface: #141b18;
    --surface-2: #19221e;
    --text: #e8eeea;
    --text-soft: #c3ccc7;
    --muted: #97a39d;
    --line: #242e29;
    --line-strong: #37433d;
    --field-line: #7b8780;
    --accent: #5dd39a;
    --accent-hover: #86e1b5;
    --accent-soft: #15301f;
    --accent-text: #04160c;
    --ink: #dbe6e0;
    --ink-text: #0b100e;
    --ok: #7fd8a4;
    --ok-bg: #153020;
    --warn: #f2b378;
    --warn-bg: #3a2814;
    --danger: #f3a3a3;
    --danger-bg: #3b1d1d;
    --note-bg: #142a1e;
    --focus: #5dd39a;
    --header-bg: rgba(11, 16, 14, 0.86);
    --hero-bg: radial-gradient(60% 90% at 0% 0%, #133023 0%, rgba(19, 48, 35, 0) 70%), radial-gradient(45% 70% at 100% 10%, #121f1a 0%, rgba(18, 31, 26, 0) 70%), linear-gradient(180deg, #0f1714 0%, #0b100e 100%);
    --hero-dots: radial-gradient(rgba(232, 238, 234, 0.07) 1px, transparent 1.2px);
    --code-bg: #19221e;
    --band-bg: #19221e;
    --band-text: #e8eeea;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow: 0 4px 16px rgba(0, 0, 0, 0.4), 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 18px 44px rgba(0, 0, 0, 0.55);
    color-scheme: dark;
  }
}

/* The same two sets of tokens as classes, so the style guide can show both themes on one page. Keep them equal to
   the blocks above. */
.theme-light {
  --bg: #f6f7f5; --bg-soft: #eef1ee; --surface: #ffffff; --surface-2: #f1f4f1; --text: #111a16; --text-soft: #37433d; --muted: #59665f;
  --line: #e1e6e2; --line-strong: #c9d1cb; --field-line: #85908a; --accent: #0b7449; --accent-hover: #075c39; --accent-soft: #e0f3e8; --accent-text: #ffffff;
  --ink: #0f1c16; --ink-text: #f6f7f5; --ok: #10703f; --ok-bg: #def2e6; --warn: #8a4709; --warn-bg: #fcebd8; --danger: #a12a2a; --danger-bg: #fbe4e4;
  --note-bg: #e6f2eb; --focus: #0b7449; --header-bg: rgba(246, 247, 245, 0.86); --code-bg: #edf1ee; --band-bg: #0f1c16; --band-text: #f6f7f5;
  --hero-bg: radial-gradient(60% 90% at 0% 0%, #d9f0e3 0%, rgba(217, 240, 227, 0) 70%), radial-gradient(45% 70% at 100% 10%, #e3eee8 0%, rgba(227, 238, 232, 0) 70%), linear-gradient(180deg, #f0f5f2 0%, #f6f7f5 100%);
  --hero-dots: radial-gradient(rgba(17, 26, 22, 0.08) 1px, transparent 1.2px);
  --shadow-sm: 0 1px 2px rgba(16, 28, 22, 0.05), 0 1px 1px rgba(16, 28, 22, 0.03); --shadow: 0 4px 16px rgba(16, 28, 22, 0.07), 0 1px 3px rgba(16, 28, 22, 0.05); --shadow-lg: 0 18px 44px rgba(16, 28, 22, 0.12);
  color-scheme: light;
}
.theme-dark {
  --bg: #0b100e; --bg-soft: #0f1513; --surface: #141b18; --surface-2: #19221e; --text: #e8eeea; --text-soft: #c3ccc7; --muted: #97a39d;
  --line: #242e29; --line-strong: #37433d; --field-line: #7b8780; --accent: #5dd39a; --accent-hover: #86e1b5; --accent-soft: #15301f; --accent-text: #04160c;
  --ink: #dbe6e0; --ink-text: #0b100e; --ok: #7fd8a4; --ok-bg: #153020; --warn: #f2b378; --warn-bg: #3a2814; --danger: #f3a3a3; --danger-bg: #3b1d1d;
  --note-bg: #142a1e; --focus: #5dd39a; --header-bg: rgba(11, 16, 14, 0.86); --code-bg: #19221e; --band-bg: #19221e; --band-text: #e8eeea;
  --hero-bg: radial-gradient(60% 90% at 0% 0%, #133023 0%, rgba(19, 48, 35, 0) 70%), radial-gradient(45% 70% at 100% 10%, #121f1a 0%, rgba(18, 31, 26, 0) 70%), linear-gradient(180deg, #0f1714 0%, #0b100e 100%);
  --hero-dots: radial-gradient(rgba(232, 238, 234, 0.07) 1px, transparent 1.2px);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4); --shadow: 0 4px 16px rgba(0, 0, 0, 0.4), 0 1px 3px rgba(0, 0, 0, 0.3); --shadow-lg: 0 18px 44px rgba(0, 0, 0, 0.55);
  color-scheme: dark;
}

/* ------------------------------------------------------------------ Base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: var(--text-base)/var(--leading) var(--font-sans);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility;
  display: flex; flex-direction: column; min-height: 100vh; overflow-x: clip;
}
a { color: var(--accent); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-hover); text-decoration-thickness: 2px; }
h1, h2, h3, h4 { line-height: var(--leading-tight); color: var(--text); margin: 0 0 var(--space-3); font-weight: 650; letter-spacing: -0.015em; text-wrap: balance; }
/* The display weight: page titles and section titles. Panels, cards and the AI view keep lighter small headings. */
h1, h2, .display { font-family: var(--font-display); font-weight: 750; letter-spacing: -0.028em; }
h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-xl); margin-top: var(--space-6); }
h3 { font-size: var(--text-lg); margin-top: var(--space-5); }
h2:first-child, h3:first-child { margin-top: 0; }
p { margin: 0 0 var(--space-3); }
ul, ol { margin: 0 0 var(--space-3); padding-left: 1.3rem; }
li { margin-bottom: var(--space-1); }
hr { border: 0; border-top: 1px solid var(--line); margin: var(--space-6) 0; }
img, svg { max-width: 100%; }
blockquote { margin: var(--space-4) 0; padding: var(--space-3) var(--space-5); border-left: 3px solid var(--accent); background: var(--surface); border-radius: 0 var(--radius) var(--radius) 0; color: var(--text-soft); }
blockquote p:last-child { margin: 0; }
code { font: 0.88em var(--font-mono); background: var(--code-bg); padding: 0.12em 0.4em; border-radius: var(--radius-sm); overflow-wrap: anywhere; }
pre { background: var(--code-bg); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-3) var(--space-4); overflow-x: auto; font-size: var(--text-sm); line-height: 1.5; margin: 0 0 var(--space-4); }
pre code { padding: 0; background: none; font-size: inherit; }
kbd { font: 0.85em var(--font-mono); border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 4px; padding: 0 0.3em; }
table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; vertical-align: top; padding: var(--space-2) var(--space-3); border-bottom: 1px solid var(--line); }
th { font-size: var(--text-sm); color: var(--muted); font-weight: 600; }
details { border-bottom: 1px solid var(--line); padding: var(--space-3) 0; }
details summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: var(--space-3); align-items: center; min-height: 28px; }
details summary::-webkit-details-marker { display: none; }
details summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 1.25rem; line-height: 1; flex: none; }
details[open] summary::after { content: "–"; }
details > :not(summary) { margin-top: var(--space-2); }
.muted { color: var(--muted); }
.small { font-size: var(--text-sm); }
.tiny { font-size: var(--text-xs); }
.lead { font-size: var(--text-lg); color: var(--text-soft); max-width: var(--narrow); line-height: 1.55; }
.grow { flex: 1; min-width: 0; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 2px; }
main:focus { outline: none; }
.skip { position: absolute; left: 1rem; top: -4rem; z-index: 100; padding: var(--space-2) var(--space-4); border-radius: var(--radius); background: var(--accent); color: var(--accent-text); font-weight: 600; }
.skip:focus { top: 0.75rem; }
.test-banner { margin: 0; padding: var(--space-2) var(--space-4); text-align: center; font-size: var(--text-sm); background: var(--warn-bg); color: var(--warn); }

/* Motion: only when the system allows it (the reduce rule above wins otherwise), and never on the way in: content is
   visible before any animation runs, so a snapshot, a print or a browser without animations shows the same page. */
@media (prefers-reduced-motion: no-preference) {
  .tile, .cat-grid a, .city-list a, .feature, .stat, .mini-card, .product, .chip { transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, color 0.15s ease; }
  .tile:hover, .cat-grid a:hover, .city-list a:hover, a.product:hover { transform: translateY(-2px); }
  .view-switch a { transition: color 0.15s ease, background-color 0.2s ease, box-shadow 0.2s ease; }
  .spinner { animation: spin 0.8s linear infinite; }
}
@keyframes spin { to { transform: rotate(360deg); } }

/* In-house SVG (lib/art.js): icons take the text colour; illustrations take the theme. */
.art { display: block; width: 100%; height: auto; }
.art-paper { fill: var(--surface); stroke: var(--line-strong); stroke-width: 1.5; }
.art-paper-fill { fill: var(--ink-text); stroke: none; }
.art-paper-stroke { stroke: var(--surface); fill: none; stroke-width: 2; }
.art-ink { fill: var(--text); stroke: none; }
.art-ink-paper { fill: var(--ink); stroke: var(--ink); }
.art-muted { fill: var(--line-strong); stroke: none; }
.art-accent { fill: var(--accent); stroke: none; }
.art-accent-soft { fill: var(--accent-soft); stroke: none; }
.art-accent-stroke { stroke: var(--accent); fill: none; stroke-width: 2.2; }

/* ------------------------------------------------------------------ Layout */
.container { width: 100%; max-width: var(--content); margin: 0 auto; padding: 0 var(--space-4); }
main { flex: 1; width: 100%; max-width: var(--content); margin: 0 auto; padding: var(--space-6) var(--space-4) var(--space-10); }
main.narrow-page { max-width: calc(var(--narrow) + 2 * var(--space-4)); }
.narrow { max-width: var(--narrow); }
.section { margin: var(--space-10) 0 0; }
.section:first-child { margin-top: 0; }
.section__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--space-2) var(--space-4); margin-bottom: var(--space-4); }
.section__head h2 { margin: 0; font-size: var(--text-2xl); }
.section__head h3 { margin: 0; font-size: var(--text-lg); }
.section__head + .chips, .chips + .section__head { margin-top: var(--space-3); }
* + .section__head:not(:first-child) { margin-top: var(--space-6); }
.section__head .more { font-size: var(--text-sm); font-weight: 600; white-space: nowrap; text-decoration: none; }
.section__head .more:hover { text-decoration: underline; }
.eyebrow { display: inline-flex; align-items: center; gap: 0.4rem; font: 650 var(--text-xs)/1.4 var(--font-sans); letter-spacing: 0.07em; text-transform: uppercase; color: var(--accent); margin-bottom: var(--space-3); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-5); align-items: start; }
.three-col { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); }
@media (max-width: 860px) { .two-col, .three-col { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ Header */
.top { position: sticky; top: 0; z-index: 50; background: var(--header-bg); backdrop-filter: saturate(150%) blur(12px); -webkit-backdrop-filter: saturate(150%) blur(12px); border-bottom: 1px solid var(--line); }
.top__inner { max-width: var(--content); margin: 0 auto; padding: 0 var(--space-4); min-height: 64px; display: flex; align-items: center; gap: var(--space-5); }
.brand { display: inline-flex; align-items: center; gap: 0.55rem; font: 750 var(--text-lg)/1 var(--font-display); color: var(--text); text-decoration: none; letter-spacing: -0.02em; flex: none; order: 1; }
.brand:hover { color: var(--text); text-decoration: none; }
.brand__mark { width: 30px; height: 30px; border-radius: 8px; display: block; flex: none; }
.main-nav, .user-nav { display: flex; gap: var(--space-1); align-items: center; font-size: var(--text-sm); font-weight: 550; }
.main-nav { order: 2; }
.main-nav a, .user-nav a { color: var(--text-soft); text-decoration: none; padding: 0.4rem 0.65rem; border-radius: var(--radius-sm); white-space: nowrap; }
.main-nav a:hover, .user-nav a:hover { color: var(--text); background: var(--surface-2); }
.main-nav a[aria-current="page"] { color: var(--text); background: var(--surface-2); box-shadow: inset 0 -2px 0 var(--accent); border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.user-nav { flex: none; order: 3; margin-left: auto; }
.user-nav .linklike { color: var(--text-soft); text-decoration: none; font-weight: 550; padding: 0.4rem 0.65rem; }
.top__cta { order: 4; flex: none; }
.button.top__cta { padding: 0.45rem 0.9rem; font-size: var(--text-sm); }
.top .view-switch { order: 5; }
.top__links { display: contents; } /* one row on wide screens; the second row on phones */
.nav-toggle { display: none; }
/* Below about 1000px: two compact rows. The brand, the "list free" button and the switch share the first; the
   navigation (scrolling sideways when it must) and the account link share the second. */
@media (max-width: 1000px) {
  .top { position: static; }
  .top__inner { flex-wrap: wrap; min-height: 0; padding-top: var(--space-2); padding-bottom: 0; gap: var(--space-2) var(--space-3); }
  .brand { min-height: 44px; }
  .top__cta { order: 2; margin-left: auto; }
  .top .view-switch { order: 3; margin-left: auto; }
  .top__cta + .view-switch { margin-left: 0; }
  .top__links { order: 4; display: flex; align-items: center; width: 100%; gap: var(--space-1); }
  .main-nav { flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; margin: 0 calc(-1 * var(--space-2)); padding: 0 var(--space-2) var(--space-1); -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent); mask-image: linear-gradient(90deg, #000 88%, transparent); }
  .main-nav::-webkit-scrollbar { display: none; }
  .user-nav { margin-left: 0; padding-bottom: var(--space-1); padding-left: var(--space-2); border-left: 1px solid var(--line); }
  .main-nav a, .user-nav a, .user-nav .linklike { padding: 0.55rem 0.6rem; }
}

/* ------------------------------------------------------------------ The Human · AI switch */
.view-switch { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: var(--radius-full); background: var(--surface-2); font-size: var(--text-xs); font-weight: 650; letter-spacing: 0.01em; flex: none; }
.view-switch__label { color: var(--muted); font-weight: 600; padding: 0 0.4rem 0 0.55rem; }
.view-switch a { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.38rem 0.7rem 0.38rem 0.55rem; border-radius: var(--radius-full); color: var(--text-soft); text-decoration: none; border: 0; line-height: 1; min-height: 30px; }
.view-switch a svg { width: 14px; height: 14px; flex: none; }
.view-switch a:hover { color: var(--text); text-decoration: none; }
.view-switch a[aria-current] { background: var(--ink); color: var(--ink-text); box-shadow: var(--shadow-sm); }
.ai-peek { white-space: nowrap; }
/* On narrow screens the switch drops its label; on small phones its words too (the icons and titles stay). */
@media (max-width: 1000px) { .view-switch__label { display: none; } }
@media (max-width: 400px) { .view-switch a span { display: none; } .view-switch a { padding: 0.45rem 0.6rem; min-height: 36px; } }

/* ------------------------------------------------------------------ Footer */
.foot { border-top: 1px solid var(--line); background: var(--bg-soft); color: var(--muted); font-size: var(--text-sm); margin-top: auto; }
.foot__inner { max-width: var(--content); margin: 0 auto; padding: var(--space-8) var(--space-4) var(--space-6); }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: var(--space-6) var(--space-5); margin-bottom: var(--space-6); }
.footer-grid h2 { font: 650 var(--text-xs)/1.4 var(--font-sans); text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); margin: 0 0 var(--space-3); }
.footer-grid nav { display: flex; flex-direction: column; gap: 0.15rem; }
.footer-grid nav a { padding: 0.25rem 0; }
.foot a { color: var(--text-soft); text-decoration: none; }
.foot a:hover { color: var(--accent); text-decoration: underline; }
.foot .brand { margin-bottom: var(--space-3); }
.footer-about p { margin: 0 0 var(--space-2); max-width: 34rem; }
.footer-faces { margin-top: var(--space-3); }
.footer-faces__icons { display: inline-flex; gap: 0.15rem; vertical-align: -3px; margin-right: 0.35rem; color: var(--accent); }
.footer-faces__icons svg { width: 16px; height: 16px; }
.footer-faces a { color: var(--accent); text-decoration: underline; }
.footer-legal { border-top: 1px solid var(--line); padding-top: var(--space-4); display: flex; flex-direction: column; gap: var(--space-1); }
.footer-legal p { margin: 0; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-about { grid-column: 1 / -1; } }
@media (max-width: 340px) { .footer-grid { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ Buttons and controls */
button, .button {
  font: inherit; font-weight: 600; cursor: pointer; border-radius: var(--radius); padding: 0.62rem 1.1rem; display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem;
  text-decoration: none; border: 1px solid var(--line-strong); background: var(--surface); color: var(--text); line-height: 1.25; min-height: 42px; transition: background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
}
button:hover, .button:hover { border-color: var(--field-line); color: var(--text); text-decoration: none; }
button:disabled { opacity: 0.7; cursor: progress; }
.primary, button.primary, .button.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); box-shadow: var(--shadow-sm); }
.primary:hover, button.primary:hover, .button.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-text); }
.button.secondary { background: var(--accent-soft); border-color: transparent; color: var(--accent); }
.button.secondary:hover { background: var(--accent-soft); color: var(--accent-hover); }
.button.ghost, button.ghost { background: transparent; border-color: transparent; color: var(--accent); }
.button.small, button.small { padding: 0.35rem 0.8rem; font-size: var(--text-sm); min-height: 34px; }
.button.large { padding: 0.8rem 1.4rem; font-size: var(--text-lg); }
.button.danger, button.danger { color: var(--danger); border-color: var(--danger-bg); background: var(--danger-bg); }
.linklike { border: 0; background: none; color: var(--accent); padding: 0; text-decoration: underline; font-weight: 500; min-height: 0; box-shadow: none; }
.linklike:hover { background: none; }
form.inline { display: inline; }
/* A paragraph of buttons keeps a gap between them when they wrap onto a second line. */
p:has(> .button + .button) { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; }
.actions { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: 0 0 var(--space-4); }
.actions a, .actions button { display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem; padding: 0.55rem 1rem; min-height: 42px; border-radius: var(--radius); border: 1px solid var(--line-strong); text-decoration: none; font-weight: 600; color: var(--text); background: var(--surface); }
.actions a:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.actions a.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.actions a.primary:hover { background: var(--accent-hover); color: var(--accent-text); }
.actions a svg, .actions button svg { width: 17px; height: 17px; flex: none; }
/* A button at work */
.spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; flex: none; }
.is-busy { cursor: progress; }

/* Forms */
input[type="text"], input[type="search"], input[type="email"], input[type="password"], input[type="url"], input[type="number"], select, textarea {
  font: inherit; padding: 0.62rem 0.85rem; min-height: 44px; border-radius: var(--radius); border: 1px solid var(--field-line); background: var(--surface); color: var(--text); min-width: 0; width: 100%;
}
input::placeholder, textarea::placeholder { color: var(--muted); opacity: 1; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; border-color: var(--accent); }
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--danger); box-shadow: 0 0 0 3px var(--danger-bg); }
textarea { resize: vertical; line-height: 1.5; }
.stack { display: flex; flex-direction: column; gap: var(--space-4); }
.stack label, .field { display: flex; flex-direction: column; gap: 0.35rem; font-weight: 600; font-size: var(--text-sm); }
.stack label > input, .stack label > select, .stack label > textarea, .field > input, .field > textarea, .field > select { font-weight: 400; font-size: var(--text-base); }
.hint { font-weight: 400; color: var(--muted); font-size: var(--text-xs); }
.field__error { font-weight: 600; color: var(--danger); font-size: var(--text-xs); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }
.stack label.check, label.check { flex-direction: row; align-items: center; gap: 0.6rem; font-weight: 400; font-size: var(--text-base); }
fieldset.choices { border: 0; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.45rem; min-width: 0; }
fieldset.choices legend { font-weight: 600; font-size: var(--text-sm); margin-bottom: var(--space-2); }
.notice { background: var(--note-bg); color: var(--text); padding: var(--space-3) var(--space-4); border-radius: var(--radius); border-left: 4px solid var(--accent); }
.error { color: var(--warn); background: var(--warn-bg); padding: var(--space-3) var(--space-4); border-radius: var(--radius); border-left: 4px solid var(--warn); }
.warn { color: var(--warn); }
.add, .search { display: flex; gap: var(--space-2); margin: var(--space-4) 0; max-width: 40rem; }
.add input, .search input { flex: 1; }
.add button, .search button { flex: none; }
.search.filters { max-width: none; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-3); box-shadow: var(--shadow-sm); }
.search.filters input, .search.filters select { width: auto; flex: 1 1 11rem; }
.form-footer { display: flex; align-items: center; gap: var(--space-4); flex-wrap: wrap; }

/* ------------------------------------------------------------------ Surfaces */
.panel, .card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-6); margin-top: var(--space-5); box-shadow: var(--shadow-sm); }
.panel > h2:first-child, .panel > p:first-child, .card > h2:first-child { margin-top: 0; }
.panel h2 { font: 700 var(--text-lg)/var(--leading-tight) var(--font-sans); letter-spacing: -0.01em; margin-top: var(--space-5); }
.panel.highlight { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); background: linear-gradient(180deg, var(--accent-soft), var(--surface) 70%); }
.panel.danger { border-color: var(--danger-bg); }
.panel.compact { padding: var(--space-4); }
.surface { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-5); }

/* Chips and badges */
.chip { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.3rem 0.75rem; border-radius: var(--radius-full); font-size: var(--text-sm); border: 1px solid var(--line); background: var(--surface); color: var(--text); text-decoration: none; line-height: 1.4; }
a.chip { min-height: 34px; }
a.chip:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.chip.small { font-size: var(--text-xs); padding: 0.12rem 0.55rem; background: var(--surface-2); border-color: transparent; color: var(--text-soft); }
.chip .muted { font-size: 0.88em; font-variant-numeric: tabular-nums; }
.chips { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: var(--space-3) 0; }
/* A long list of chips shows its first few; the rest open under "Show N more" (lib/views: chipList). */
.chips-more { border: 0; padding: 0; margin: 0 0 var(--space-3); }
.chips-more > summary { display: inline-flex; justify-content: flex-start; gap: 0.35rem; font-size: var(--text-sm); color: var(--accent); min-height: 34px; }
.chips-more > summary::after { font-size: 1rem; color: var(--accent); }
.chips-more[open] > summary { margin-bottom: var(--space-1); }
.chips-more > .chips { margin-top: 0; }
.badge { display: inline-flex; align-items: center; gap: 0.3rem; font-size: var(--text-xs); font-weight: 600; padding: 0.22rem 0.6rem; border-radius: var(--radius-full); background: var(--surface-2); color: var(--muted); white-space: nowrap; line-height: 1.35; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.accent { background: var(--accent-soft); color: var(--accent); }
.badge.ready { background: var(--ink); color: var(--ink-text); padding-left: 0.5rem; }
.badge.ready svg { width: 12px; height: 12px; flex: none; }
.badges { display: flex; gap: 0.35rem; flex-wrap: wrap; align-items: center; }

/* Stats */
.stats { display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; padding: 0; margin: 0; list-style: none; }
.stats strong { font-size: var(--text-lg); }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-3); margin: var(--space-6) 0 0; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-4) var(--space-5); box-shadow: var(--shadow-sm); }
.stat__value { display: block; font: 750 var(--text-2xl)/1.1 var(--font-display); letter-spacing: -0.03em; color: var(--text); font-variant-numeric: tabular-nums; }
.stat__label { display: block; font-size: var(--text-sm); color: var(--muted); margin-top: var(--space-1); line-height: 1.4; }
@media (max-width: 860px) { .stat-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .stat { padding: var(--space-3) var(--space-4); } .stat__value { font-size: var(--text-xl); } }

/* Meter: how complete a listing is */
.meter { display: flex; flex-direction: column; gap: var(--space-2); margin: var(--space-3) 0; }
.meter__row { display: flex; justify-content: space-between; gap: var(--space-3); font-size: var(--text-sm); align-items: baseline; }
.meter progress { width: 100%; height: 8px; appearance: none; -webkit-appearance: none; border: 0; border-radius: var(--radius-full); background: var(--surface-2); overflow: hidden; }
.meter progress::-webkit-progress-bar { background: var(--surface-2); border-radius: var(--radius-full); }
.meter progress::-webkit-progress-value { background: var(--accent); border-radius: var(--radius-full); }
.meter progress::-moz-progress-bar { background: var(--accent); border-radius: var(--radius-full); }
.meter__missing { font-size: var(--text-sm); color: var(--muted); margin: 0; }

/* ------------------------------------------------------------------ Home */
/* The hero runs the full width of the window; its content keeps the page's width. */
.hero { position: relative; background: var(--hero-bg); border-bottom: 1px solid var(--line); margin: calc(-1 * var(--space-6)) calc(50% - 50vw) var(--space-6); padding: var(--space-10) var(--space-4) var(--space-8); overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: var(--hero-dots) 0 0 / 22px 22px; mask-image: radial-gradient(80% 90% at 70% 0%, rgba(0, 0, 0, 0.9), transparent 80%); -webkit-mask-image: radial-gradient(80% 90% at 70% 0%, rgba(0, 0, 0, 0.9), transparent 80%); pointer-events: none; }
.hero__inner { position: relative; max-width: calc(var(--content) - 2 * var(--space-4)); margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: var(--space-8); align-items: center; }
.hero h1 { font-size: var(--text-4xl); line-height: 1.03; letter-spacing: -0.035em; margin-bottom: var(--space-4); max-width: 16ch; }
.hero .lead { font-size: var(--text-lg); margin-bottom: var(--space-5); max-width: 33rem; }
.hero .add { margin: var(--space-4) 0 var(--space-3); max-width: 34rem; padding: 6px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: calc(var(--radius) + 6px); box-shadow: var(--shadow); }
.hero .add input { font-size: var(--text-lg); padding: 0.7rem 0.9rem; border-color: transparent; background: transparent; }
.hero .add input:focus-visible { outline-offset: 0; }
.hero .add button { padding: 0.7rem 1.25rem; font-size: var(--text-base); }
.hero__meta { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); font-size: var(--text-sm); color: var(--muted); margin: var(--space-2) 0 0; }
.hero__meta span::before { content: "✓"; color: var(--accent); margin-right: 0.35rem; font-weight: 700; }
.hero__aside { display: flex; flex-direction: column; gap: var(--space-3); }
.hero .search { margin: 0; max-width: none; }
.hero .search input { background: var(--surface); }
@media (max-width: 860px) { .hero__inner { grid-template-columns: 1fr; gap: var(--space-6); } .hero { padding-top: var(--space-7); padding-bottom: var(--space-6); } }
@media (max-width: 640px) {
  .add, .search { flex-direction: column; }
  /* Stacked, the flex basis of the filter fields would become their height (11rem each): let them size by content. */
  .search.filters input, .search.filters select { flex: none; width: 100%; }
  .two { grid-template-columns: 1fr; }
}

/* The example fact card on the home page */
.mini-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: var(--space-5); font-size: var(--text-sm); color: var(--text); text-decoration: none; display: block; }
.mini-card:hover { border-color: var(--accent); color: var(--text); text-decoration: none; }
.mini-card__title { display: flex; justify-content: space-between; gap: var(--space-3); align-items: start; margin-bottom: var(--space-1); }
.mini-card__title strong { font: 700 var(--text-xl)/1.2 var(--font-display); letter-spacing: -0.02em; }
.mini-card p { color: var(--text-soft); margin: var(--space-2) 0 0; }
.mini-card dl { display: grid; grid-template-columns: auto 1fr; gap: 0.45rem var(--space-4); margin: var(--space-4) 0 0; padding-top: var(--space-3); border-top: 1px solid var(--line); }
.mini-card dt { color: var(--muted); font: 600 var(--text-xs)/1.6 var(--font-sans); text-transform: uppercase; letter-spacing: 0.05em; }
.mini-card dd { margin: 0; overflow-wrap: anywhere; }
.mini-card__foot { margin: var(--space-4) 0 0; padding-top: var(--space-3); border-top: 1px dashed var(--line-strong); display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-3); font-size: var(--text-xs); color: var(--muted); }
.mini-card__label { display: inline-flex; font: 650 var(--text-xs)/1.4 var(--font-sans); text-transform: uppercase; letter-spacing: 0.07em; color: var(--accent); background: var(--accent-soft); padding: 0.2rem 0.55rem; border-radius: var(--radius-full); margin: 0 0 var(--space-3); }

/* Feature cards and steps */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); }
.feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-5); box-shadow: var(--shadow-sm); }
.feature__icon { width: 42px; height: 42px; border-radius: var(--radius); background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: var(--space-4); }
.feature__icon svg { width: 22px; height: 22px; }
.feature h3 { margin: 0 0 var(--space-2); font-size: var(--text-lg); }
.feature p { margin: 0; color: var(--text-soft); }
@media (max-width: 860px) { .features { grid-template-columns: 1fr; } }
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); list-style: none; padding: 0; margin: 0; }
.steps li { counter-increment: step; position: relative; padding: var(--space-5); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); margin: 0; }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--radius-full); background: var(--ink); color: var(--ink-text); font: 700 var(--text-sm)/1 var(--font-sans); margin-bottom: var(--space-3); }
.steps strong { display: block; font-size: var(--text-lg); margin-bottom: var(--space-1); }
.steps p { margin: 0; color: var(--text-soft); }
@media (max-width: 860px) {
  .steps { grid-template-columns: 1fr; gap: var(--space-2); }
  .steps li { display: grid; grid-template-columns: 32px 1fr; column-gap: var(--space-3); padding: var(--space-4); }
  .steps li::before { grid-row: span 2; margin: 0; }
}
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: var(--space-2); }
.cat-grid a { display: flex; justify-content: space-between; align-items: center; gap: var(--space-2); padding: var(--space-3) var(--space-4); min-height: 52px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); color: var(--text); text-decoration: none; font-weight: 500; }
.cat-grid a strong { font-weight: 600; }
.cat-grid a:hover, .tile:hover { border-color: color-mix(in srgb, var(--accent) 60%, var(--line)); box-shadow: var(--shadow); text-decoration: none; }
.cat-grid a .muted { font-variant-numeric: tabular-nums; font-size: var(--text-sm); }
.cat-grid a.is-empty { color: var(--muted); font-weight: 400; }
@media (max-width: 480px) { .cat-grid { grid-template-columns: 1fr 1fr; } .cat-grid a { flex-direction: column; align-items: flex-start; gap: 0.1rem; } }
.formats { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: var(--space-3); list-style: none; padding: 0; margin: var(--space-4) 0; }
.formats li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-3) var(--space-4); font-size: var(--text-sm); margin: 0; }
.formats code { display: inline-block; margin-bottom: 0.2rem; }
.cta-band { background: var(--band-bg); color: var(--band-text); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-7) var(--space-6); display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--space-4); margin-top: var(--space-10); }
.cta-band h2 { color: inherit; margin: 0 0 var(--space-1); font-size: var(--text-2xl); }
.cta-band p { margin: 0; opacity: 0.85; }
.cta-band .button { background: var(--accent); color: var(--accent-text); border-color: var(--accent); }
.cta-band .button:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.faq details { border-bottom: 1px solid var(--line); padding: var(--space-3) 0; }
.faq details p { color: var(--text-soft); margin: var(--space-2) 0 0; max-width: var(--narrow); }

/* ------------------------------------------------------------------ Listing tiles and hubs */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--space-3); }
.tile { display: flex; flex-direction: column; gap: 0.3rem; padding: var(--space-4) var(--space-5); border-radius: var(--radius-lg); background: var(--surface); border: 1px solid var(--line); color: var(--text); text-decoration: none; min-width: 0; box-shadow: var(--shadow-sm); }
.tile:hover { color: var(--text); }
.tile p { margin: 0.25rem 0 0; font-size: var(--text-sm); color: var(--text-soft); overflow-wrap: anywhere; }
/* The name first; the badges sit beside it when there is room and wrap under it when there is not. */
.tile-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.35rem var(--space-2); align-items: baseline; min-width: 0; }
.tile-head strong { font: 700 var(--text-lg)/1.25 var(--font-display); letter-spacing: -0.02em; flex: 1 1 11rem; min-width: 0; overflow-wrap: anywhere; }
.tile-head .badges { flex: 0 1 auto; }
.tile-head .badges:empty { display: none; }
.tile__meta { font-size: var(--text-sm); color: var(--muted); }
.tile .chips { margin: var(--space-2) 0 0; gap: 0.3rem; }
.empty { color: var(--text-soft); background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--radius-lg); padding: var(--space-7) var(--space-5); text-align: center; }
.empty__art { width: 120px; margin: 0 auto var(--space-3); }
.empty p { margin: 0 0 var(--space-1); }
.pager { display: flex; justify-content: space-between; align-items: center; margin-top: var(--space-5); gap: var(--space-3); }
.pager a { font-weight: 600; text-decoration: none; padding: 0.55rem 1rem; min-height: 42px; display: inline-flex; align-items: center; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--surface); }
.pager a:hover { border-color: var(--accent); }
.crumbs { font-size: var(--text-sm); color: var(--muted); margin-bottom: var(--space-4); overflow-wrap: anywhere; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--accent); text-decoration: underline; }
.crumbs span { color: var(--text-soft); }
.hub-head { margin-bottom: var(--space-5); }
.hub-head h1 { margin-bottom: var(--space-2); }
.hub-head .lead { margin-bottom: var(--space-3); font-size: var(--text-base); }
.hub-note { margin-top: var(--space-6); font-size: var(--text-sm); color: var(--muted); max-width: var(--narrow); }
.city-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: var(--space-2); list-style: none; padding: 0; margin: 0; }
.city-list li { margin: 0; }
.city-list a { display: flex; justify-content: space-between; padding: var(--space-3) var(--space-4); border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); color: var(--text); text-decoration: none; }
.city-list a:hover { border-color: var(--accent); }

/* ------------------------------------------------------------------ Business page (the fact card) */
.card-head { display: flex; gap: var(--space-4); align-items: start; flex-wrap: wrap; margin-bottom: var(--space-4); }
.card-head h1 { margin-bottom: var(--space-1); font-size: var(--text-3xl); overflow-wrap: anywhere; }
.card-head p { margin: 0; }
.card-head .badges { flex-basis: 100%; }
.logo { width: 64px; height: 64px; border-radius: var(--radius); object-fit: contain; background: #fff; border: 1px solid var(--line); flex: none; padding: 4px; }
.summary { font-size: var(--text-lg); color: var(--text-soft); max-width: var(--narrow); margin-bottom: var(--space-4); line-height: 1.5; }
.card-photo { margin: 0 0 var(--space-4); }
.card-photo img { display: block; width: auto; max-width: 100%; max-height: 260px; border-radius: var(--radius); object-fit: cover; background: var(--bg-soft); border: 1px solid var(--line); }
.card-photo figcaption { margin-top: var(--space-1); }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: var(--space-4) var(--space-5); margin: var(--space-5) 0; padding: var(--space-5) 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts > div { min-width: 0; }
.facts dt { font: 600 var(--text-xs)/1.5 var(--font-sans); text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-bottom: 0.15rem; }
.facts dd { margin: 0; overflow-wrap: anywhere; }
.facts dd .small { display: block; }
.open-now, .closed-now { display: inline-flex; align-items: center; gap: 0.4rem; font-weight: 600; font-size: var(--text-sm); }
.open-now::before, .closed-now::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px var(--ok-bg); }
.open-now { color: var(--ok); }
.closed-now { color: var(--warn); }
.closed-now::before { background: var(--warn); box-shadow: 0 0 0 3px var(--warn-bg); }
.hours { width: auto; min-width: 16rem; max-width: 30rem; font-size: var(--text-sm); }
.hours td, .hours th { padding: 0.4rem 0.75rem 0.4rem 0; border-bottom: 1px solid var(--line); }
.hours th { color: var(--text); font-weight: 500; }
.hours tr.today th, .hours tr.today td { font-weight: 700; }
.hours td.when { white-space: nowrap; font-variant-numeric: tabular-nums; }
.hours td:empty { padding: 0; width: 0; } /* hours as written on the website have no day column */
.hours td.when { white-space: normal; }
.hours tr th + td.when { white-space: nowrap; }
.card section { margin-top: var(--space-6); }
.card section h2 { font: 700 var(--text-lg)/var(--leading-tight) var(--font-sans); letter-spacing: -0.01em; margin: 0 0 var(--space-3); }
/* What a web shop sells: a sample of its products, as the shop publishes them */
.shop-line { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; margin: 0 0 var(--space-2); color: var(--text-soft); font-size: var(--text-sm); }
.products { list-style: none; padding: 0; margin: var(--space-4) 0 var(--space-3); display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: var(--space-3); }
.products li { margin: 0; min-width: 0; }
.product { display: flex; flex-direction: column; gap: 0.25rem; height: 100%; padding: var(--space-2) var(--space-2) var(--space-3); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--text); text-decoration: none; font-size: var(--text-sm); min-width: 0; }
a.product:hover { border-color: var(--accent); box-shadow: var(--shadow); color: var(--text); text-decoration: none; }
.product img, .product__ph { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; border-radius: calc(var(--radius) - 4px); background: #fff; margin-bottom: var(--space-1); }
.product__ph { display: grid; place-items: center; background: var(--surface-2); color: var(--line-strong); }
.product__ph svg { width: 34%; height: 34%; }
.product__name, .product__price, .product__stock { padding: 0 var(--space-1); }
.product__name { font-weight: 600; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.35; }
.product__price { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; margin-top: auto; }
.product__stock { font-size: var(--text-xs); color: var(--muted); }
.product__stock.in { color: var(--ok); }
.product__stock.out { color: var(--warn); }
ul.plain { list-style: none; padding: 0; margin: 0; }
ul.plain li { padding: 0.5rem 0; border-bottom: 1px solid var(--line); margin: 0; }
ul.plain li:last-child { border-bottom: 0; }
table.prices, table.list, table.sources { width: 100%; border-collapse: collapse; }
table.prices td, table.list td, table.list th, table.sources td, table.sources th { padding: 0.5rem 0.6rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
td.price { text-align: right; white-space: nowrap; color: var(--text-soft); font-variant-numeric: tabular-nums; }
td.url { color: var(--muted); overflow-wrap: anywhere; font-size: var(--text-sm); }
table.list form { margin: 0; }
table.list .actions-cell { white-space: nowrap; }
table.list td .small { overflow-wrap: anywhere; } /* long website addresses wrap instead of widening the table */
table.sources { font-size: var(--text-sm); }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.history { padding-left: 1.1rem; font-size: var(--text-sm); }
.history li { margin-bottom: 0.3rem; }
.meta-line { display: flex; flex-wrap: wrap; gap: var(--space-1) var(--space-3); font-size: var(--text-sm); color: var(--muted); margin: 0 0 var(--space-2); }
.source-list { font-size: var(--text-sm); }
.source-tag { display: inline-block; font-size: var(--text-xs); color: var(--muted); background: var(--surface-2); border-radius: var(--radius-sm); padding: 0.05rem 0.4rem; margin-left: 0.3rem; vertical-align: middle; }
.aside-grid { display: grid; grid-template-columns: 3fr 2fr; gap: var(--space-4); align-items: start; margin-top: var(--space-4); }
.aside-grid .panel { margin-top: 0; }
@media (max-width: 860px) { .aside-grid { grid-template-columns: 1fr; } }
.machine-links { list-style: none; padding: 0; margin: 0 0 var(--space-3); display: flex; flex-direction: column; gap: 0.5rem; font-size: var(--text-sm); }
.machine-links li { margin: 0; }
.machine-links code { font-size: 0.85em; }

/* ------------------------------------------------------------------ Account, auth and admin */
.auth { max-width: 26rem; margin: var(--space-6) auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-6); box-shadow: var(--shadow); }
.auth h1 { font-size: var(--text-2xl); }
.auth .lead { font-size: var(--text-base); }
.auth .stack + p, .auth form + p { margin-top: var(--space-4); }
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: var(--space-3); margin-bottom: var(--space-4); }
.page-head h1 { margin: 0; }
.page-head .meta-line { margin: var(--space-1) 0 0; }
.admin-nav { display: flex; gap: var(--space-2); flex-wrap: wrap; margin: 0 0 var(--space-5); font-size: var(--text-sm); border-bottom: 1px solid var(--line); }
.admin-nav a { text-decoration: none; color: var(--text-soft); padding: var(--space-2) var(--space-3); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.admin-nav a[aria-current] { font-weight: 700; color: var(--text); border-bottom-color: var(--accent); }
.verify-steps { list-style: none; padding: 0; margin: var(--space-3) 0; display: flex; flex-direction: column; gap: var(--space-3); }
.verify-steps li { background: var(--surface-2); border-radius: var(--radius); padding: var(--space-3) var(--space-4); }
.verify-steps pre { margin: var(--space-2) 0 0; }
.edit .field-head { display: flex; justify-content: space-between; gap: var(--space-2); align-items: baseline; }
.edit .field-head .source-tag { margin-left: 0; }
.edit fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-4); margin: 0; display: flex; flex-direction: column; gap: var(--space-4); }
.edit legend { font-weight: 700; padding: 0 var(--space-2); }

/* ------------------------------------------------------------------ Long text pages and docs */
.prose { max-width: var(--narrow); }
.prose h1 { margin-bottom: var(--space-4); }
.prose h2 { margin-top: var(--space-7); padding-top: var(--space-4); border-top: 1px solid var(--line); }
.prose li { margin-bottom: 0.4rem; }
.prose p, .prose li { color: var(--text-soft); }
.prose strong { color: var(--text); }
.prose .lead { color: var(--text-soft); }
.prose table { font-size: var(--text-sm); margin: var(--space-3) 0 var(--space-4); }
.toc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-4) var(--space-5); margin: var(--space-4) 0 var(--space-6); font-size: var(--text-sm); }
.toc h2 { font: 650 var(--text-xs)/1.4 var(--font-sans); text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); margin: 0 0 var(--space-2); border: 0; padding: 0; }
.toc ol { margin: 0; padding-left: 1.2rem; columns: 2; column-gap: var(--space-5); }
.toc li { break-inside: avoid; }
.toc a { text-decoration: none; }
@media (max-width: 640px) { .toc ol { columns: 1; } }
.docs { max-width: 52rem; }
.docs h2 { margin-top: var(--space-8); padding-top: var(--space-4); border-top: 1px solid var(--line); }
/* The "On this page" heading inside a docs article is a label, not a section: no rule above it, no gap. */
.prose .toc h2, .docs .toc h2 { margin-top: 0; padding-top: 0; border-top: 0; }
.docs h3 { margin-top: var(--space-5); }
.docs pre { font-size: var(--text-sm); }
.docs table { font-size: var(--text-sm); margin: var(--space-3) 0 var(--space-4); }
.docs table code { font-size: 0.85em; }
.docs .endpoint { display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap; margin: var(--space-3) 0 var(--space-2); font-family: var(--font-mono); font-size: var(--text-sm); }
.docs .method { font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 0.1rem 0.5rem; border-radius: var(--radius-sm); font-size: var(--text-xs); }
.summary-box { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--radius); padding: var(--space-4) var(--space-5); margin: var(--space-4) 0 var(--space-6); }
.summary-box h2 { border: 0; padding: 0; margin: 0 0 var(--space-2); font: 700 var(--text-base)/var(--leading-tight) var(--font-sans); }
.summary-box ul { margin: 0; }
.contact-card { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); margin: var(--space-4) 0; }
@media (max-width: 640px) { .contact-card { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ Error pages */
.error-page { max-width: 34rem; margin: var(--space-8) auto; text-align: center; }
.error-page__art { width: 150px; margin: 0 auto var(--space-4); }
.error-page .code { font: 650 var(--text-xs)/1.4 var(--font-sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: var(--space-2); }
.error-page h1 { font-size: var(--text-3xl); }
.error-page .actions { justify-content: center; margin-top: var(--space-5); }

/* ------------------------------------------------------------------ The AI view (lib/views/ai.js): lean, labelled, one column */
.view-ai { font-size: var(--text-sm); }
.ai-top { border-bottom: 1px solid var(--line); background: var(--surface); }
.ai-top__inner, .ai-main, .ai-foot__inner { max-width: 62rem; margin: 0 auto; padding-left: var(--space-4); padding-right: var(--space-4); }
.ai-top__inner { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); padding-top: var(--space-3); padding-bottom: var(--space-3); }
.ai-brand { font: 750 var(--text-base)/1 var(--font-display); letter-spacing: -0.02em; color: var(--text); text-decoration: none; }
.ai-tag { font: 700 var(--text-xs)/1 var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent); background: var(--accent-soft); padding: 0.32rem 0.5rem; border-radius: var(--radius-sm); }
.ai-top .view-switch { margin-left: auto; }
.ai-nav { display: flex; flex-wrap: wrap; gap: var(--space-1) var(--space-4); width: 100%; font-size: var(--text-sm); }
.ai-nav a, .ai-foot a { color: var(--text-soft); }
.ai-nav__account { margin-left: auto; display: inline-flex; gap: var(--space-3); }
.view-ai main.ai-main { max-width: 62rem; padding-top: var(--space-5); padding-bottom: var(--space-8); }
.ai-main h1 { font: 750 var(--text-2xl)/1.15 var(--font-display); letter-spacing: -0.025em; margin-bottom: var(--space-2); }
.ai-main h2 { font: 700 var(--text-xs)/1.5 var(--font-mono); margin: var(--space-6) 0 var(--space-2); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.ai-main h3 { font-size: var(--text-sm); margin: var(--space-4) 0 var(--space-2); }
.ai-intro { font-size: var(--text-base); color: var(--text-soft); max-width: none; }
.ai-crumbs { font-size: var(--text-xs); color: var(--muted); margin-bottom: var(--space-3); }
.ai-crumbs a { color: var(--muted); }
.ai-meta, .ai-empty { color: var(--muted); }
.ai-table { width: 100%; border-collapse: collapse; margin: 0 0 var(--space-3); }
.ai-table th, .ai-table td { padding: 0.4rem 0.75rem 0.4rem 0; border-bottom: 1px solid var(--line); vertical-align: top; text-align: left; font-size: var(--text-sm); }
.ai-table th[scope="row"] { width: 11rem; font: 600 var(--text-xs)/1.6 var(--font-mono); color: var(--muted); text-transform: none; letter-spacing: 0; }
.ai-table td { overflow-wrap: anywhere; }
.ai-table thead th { font: 600 var(--text-xs)/1.5 var(--font-mono); color: var(--muted); }
@media (max-width: 640px) { .ai-table th[scope="row"] { width: 34%; } }
.ai-list, .ai-products { padding-left: 1.3rem; margin: 0 0 var(--space-3); }
.ai-list li, .ai-products li { margin-bottom: var(--space-2); }
.ai-inline { list-style: none; padding: 0; margin: 0 0 var(--space-3); display: flex; flex-wrap: wrap; gap: 0.35rem 1rem; }
.ai-faq dt { font-weight: 600; margin-top: var(--space-3); }
.ai-faq dd { margin: 0.2rem 0 0; color: var(--text-soft); }
.ai-form { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: end; margin: 0 0 var(--space-3); }
.ai-form label { display: flex; flex-direction: column; gap: 0.25rem; font-size: var(--text-xs); font-weight: 600; color: var(--muted); flex: 1 1 12rem; }
.ai-form input, .ai-form select { font-size: var(--text-sm); padding: 0.45rem 0.6rem; min-height: 40px; }
.ai-form button { padding: 0.5rem 0.9rem; min-height: 40px; }
.ai-pager { margin: var(--space-3) 0; }
.ai-box { margin-top: var(--space-7); padding: var(--space-4) var(--space-5); border: 1px dashed var(--accent); border-radius: var(--radius); background: var(--accent-soft); }
.ai-box h2 { margin-top: 0; color: var(--accent); }
.ai-box .ai-table th, .ai-box .ai-table td { border-bottom-color: color-mix(in srgb, var(--accent) 25%, transparent); }
.ai-box code { background: var(--surface); }
.ai-passthrough { font-size: var(--text-base); }
.ai-foot { border-top: 1px solid var(--line); background: var(--bg-soft); color: var(--muted); font-size: var(--text-xs); margin-top: auto; }
.ai-foot__inner { padding-top: var(--space-5); padding-bottom: var(--space-6); display: flex; flex-direction: column; gap: var(--space-2); }
.ai-foot p, .ai-foot nav { margin: 0; }

/* ------------------------------------------------------------------ Style guide (/styleguide) */
main.sg-page { max-width: 1280px; }
.sg-nav { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0 0 var(--space-6); }
.sg-nav a { font-size: var(--text-xs); font-weight: 600; text-decoration: none; padding: 0.3rem 0.7rem; border-radius: var(--radius-full); border: 1px solid var(--line); background: var(--surface); color: var(--text-soft); }
.sg-nav a:hover { border-color: var(--accent); color: var(--accent); }
.sg-block { margin: 0 0 var(--space-8); }
.sg-block__head { margin-bottom: var(--space-3); }
.sg-block__head h2 { margin: 0 0 var(--space-1); font-size: var(--text-2xl); }
.sg-block__head p { margin: 0; max-width: var(--narrow); }
.sg-pair { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); align-items: start; }
.sg-pane { position: relative; background: var(--bg); color: var(--text); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: var(--space-6) var(--space-5) var(--space-5); overflow: hidden; min-width: 0; }
.sg-pane__label { position: absolute; top: 0; right: 0; font: 650 var(--text-xs)/1 var(--font-sans); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); background: var(--surface-2); padding: 0.35rem 0.7rem; border-radius: 0 0 0 var(--radius); }
.sg-pane > *:last-child { margin-bottom: 0; }
.sg-pane .panel, .sg-pane .card { margin-top: var(--space-3); }
.sg-pane .stat-grid { grid-template-columns: 1fr 1fr; margin-top: 0; }
.sg-pane .error-page { margin: var(--space-4) auto 0; }
.sg-row { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: center; }
.sg-row .view-switch { margin-left: 0; }
.sg-swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: var(--space-3); }
.sg-swatch { display: flex; flex-direction: column; gap: 0.25rem; font-size: var(--text-xs); color: var(--text-soft); }
.sg-swatch code { font-size: 0.75rem; }
.sg-swatch__chip { display: block; height: 44px; border-radius: var(--radius); border: 1px solid var(--line); }
.sg-bg { background: var(--bg); } .sg-surface { background: var(--surface); } .sg-surface-2 { background: var(--surface-2); } .sg-text { background: var(--text); }
.sg-text-soft { background: var(--text-soft); } .sg-muted { background: var(--muted); } .sg-line { background: var(--line); } .sg-accent { background: var(--accent); }
.sg-accent-soft { background: var(--accent-soft); } .sg-ink { background: var(--ink); } .sg-ok { background: var(--ok); } .sg-warn { background: var(--warn); } .sg-danger { background: var(--danger); }
.sg-icons { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-bottom: var(--space-4); }
.sg-icon { display: inline-flex; flex-direction: column; align-items: center; gap: 0.3rem; width: 72px; font-size: var(--text-xs); color: var(--text); }
.sg-icon svg { width: 24px; height: 24px; }
.sg-art { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: var(--space-3); }
.sg-art figure { margin: 0; text-align: center; }
.sg-art figcaption { font-size: var(--text-xs); color: var(--muted); margin-top: 0.3rem; }
@media (max-width: 860px) { .sg-pair { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ Small screens and print */
@media (max-width: 640px) {
  main { padding-top: var(--space-5); padding-bottom: var(--space-8); }
  .panel, .card, .auth { padding: var(--space-4); }
  .surface { padding: var(--space-4); }
  .section { margin-top: var(--space-8); }
  .section__head h2 { font-size: var(--text-xl); }
  .cta-band { padding: var(--space-5); }
  .hero { margin-top: calc(-1 * var(--space-5)); }
  .hero .lead { font-size: var(--text-base); }
  .hero .add { flex-direction: column; padding: 6px; }
  .hero .add button { width: 100%; }
  .summary { font-size: var(--text-base); }
  .logo { width: 52px; height: 52px; }
  /* The fact card's buttons: two to a row, the website first and full width. */
  .card .actions { display: grid; grid-template-columns: 1fr 1fr; }
  .card .actions a.primary { grid-column: 1 / -1; }
  /* Facts two to a column pair; long values (addresses, e-mail) still wrap. */
  .facts { grid-template-columns: 1fr 1fr; gap: var(--space-4) var(--space-3); }
  .products { grid-template-columns: 1fr 1fr; gap: var(--space-2); }
  .tile { padding: var(--space-4); }
  .grid { grid-template-columns: 1fr; }
}
@media (max-width: 400px) {
  .user-nav .button span.long, .top__cta span.long { display: none; }
}
/* Phones: the navigation fits one row ("Businesses", "AI agents"; About is in the footer), so nothing is cut off. The
   row still scrolls sideways if larger text settings make it too wide. */
.nav-short { display: none; }
@media (max-width: 560px) {
  .nav-long { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .nav-short { display: inline; }
  .main-nav a.nav-about { display: none; }
  .main-nav { -webkit-mask-image: none; mask-image: none; }
  /* Signed in, "Listings · Log out" is longer than "Log in": For AI agents is left to the footer too. */
  .top__links--user .main-nav a.nav-agents { display: none; }
  .main-nav a, .user-nav a, .user-nav .linklike { padding: 0.55rem 0.4rem; }
  .top__cta span.long { display: none; }
}
@media (max-width: 480px) { .view-switch a span { display: none; } .view-switch a { padding: 0.45rem 0.6rem; min-height: 36px; } }
@media (max-width: 400px) {
  .main-nav, .user-nav { font-size: 0.8125rem; gap: 0; }
  .main-nav a, .user-nav a, .user-nav .linklike { padding: 0.55rem 0.36rem; }
}
@media print {
  .top, .foot, .skip, .actions, .panel.highlight, .pager, .view-switch { display: none !important; }
  main { max-width: none; padding: 0; }
  a { color: inherit; text-decoration: none; }
}
