/* PlateWize: "the marked-up invoice" (docs/claude/website-interface.md §2). */
:root {
  --walk-in: #EEF1F3; --paper: #FFFFFF; --ink: #1D2B4F; --ink-soft: #55607A; --edge: #D5DAE1;
  --highlighter: #FFE45C; --done: #1F7A4D; --red-pen: #C8374A; --focus: #2457C5;
  --radius: 6px; --gutter: 16px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --walk-in: #12161F; --paper: #1B2130; --ink: #E7EAF2; --ink-soft: #A3ABBE; --edge: #2E3647;
    --highlighter: #8A7A1E; --done: #5CC08D; --red-pen: #F07A8A; --focus: #8AB0FF; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --walk-in: #12161F; --paper: #1B2130; --ink: #E7EAF2; --ink-soft: #A3ABBE; --edge: #2E3647;
  --highlighter: #8A7A1E; --done: #5CC08D; --red-pen: #F07A8A; --focus: #8AB0FF; color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--walk-in); color: var(--ink);
  font: 16px/1.5 "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, sans-serif;
}
h1 { font-size: 25px; line-height: 1.25; margin: 0 0 4px; }
h1.headline { font-size: 31px; }
h2 { font-size: 20px; margin: 28px 0 10px; }
h3 { font-size: 16px; margin: 0; }
a { color: inherit; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.hint { color: var(--ink-soft); }
p.hint { margin: 4px 0; }
.error { color: var(--red-pen); font-weight: 600; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; } .skip:focus { left: 8px; top: 8px; z-index: 50; background: var(--paper); padding: 8px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

/* Controls: flat; 44px tap targets */
button, .button {
  font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--edge); border-radius: var(--radius);
  min-height: 44px; padding: 8px 16px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 6px;
}
button:disabled { opacity: .55; cursor: default; }
button.primary, .button.primary { background: var(--ink); color: var(--paper); border-color: var(--ink); font-weight: 600; }
button.quiet { border-color: transparent; background: transparent; color: var(--ink-soft); }
button.danger { background: var(--red-pen); border-color: var(--red-pen); color: #fff; font-weight: 600; }
.admin-link { text-align: center; font-size: 14px; color: var(--ink-soft); }
.admin-link.active { color: var(--ink); font-weight: 700; }
.sidebar .reset { justify-content: center; font-size: 14px; min-height: 36px; }
button.link { border: 0; background: none; padding: 0 4px; min-height: 0; text-decoration: underline; color: var(--ink); }
input, select, textarea {
  font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--edge); border-radius: var(--radius);
  min-height: 44px; padding: 8px 10px; width: 100%;
}
label { display: grid; gap: 4px; align-content: start; font-weight: 600; }
label .hint { font-weight: 400; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 12px; }

/* Paper: invoices and sheets */
.paper { background: var(--paper); border: 1px solid var(--edge); border-radius: var(--radius); }
.panel { padding: 16px 20px; margin: 16px 0; }
.panel h2 { margin-top: 0; }

/* Highlighter swipe behind text that needs a look (never text color) */
.marker {
  background: linear-gradient(100deg, transparent 0 2%, var(--highlighter) 3% 96%, transparent 98%);
  padding: 0 6px; margin: 0 -2px; border-radius: 3px; box-decoration-break: clone; -webkit-box-decoration-break: clone;
}
.check { fill: none; stroke: var(--done); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; vertical-align: -4px;
  stroke-dasharray: 30; stroke-dashoffset: 0; animation: draw 250ms ease-out; }
@keyframes draw { from { stroke-dashoffset: 30; } }
.done-note { color: var(--done); font-weight: 600; display: flex; align-items: center; gap: 6px; }

/* Shell */
.shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; height: 100vh; padding: 20px 16px; border-right: 1px solid var(--edge); display: flex; flex-direction: column; gap: 12px; }
.brand { display: block; flex: none; padding: 4px 0; }
.brand img { display: block; width: 168px; max-width: 100%; height: auto; }
.restaurant-name { color: var(--ink-soft); }
.sidebar nav { display: grid; gap: 2px; margin-top: 8px; }
.sidebar nav a { text-decoration: none; padding: 10px 12px; border-radius: var(--radius); min-height: 44px; }
.sidebar nav a.active { background: var(--paper); font-weight: 700; box-shadow: inset 3px 0 0 var(--ink); }
.sidebar .add { margin-top: auto; justify-content: center; }
main { padding: 28px 32px 120px; max-width: 1280px; width: 100%; outline: none; }
.tabbar { display: none; }

.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.stats { color: var(--ink-soft); margin: 0; }
.back { display: inline-block; margin-bottom: 12px; text-decoration: none; color: var(--ink-soft); min-height: 44px; line-height: 44px; }
.empty { padding: 24px; margin-top: 20px; max-width: 640px; }
.empty h2 { margin-top: 0; }
.dragging { outline: 3px dashed var(--ink-soft); outline-offset: 8px; border-radius: var(--radius); }

/* Needs-a-look slips */
.slips { list-style: none; padding: 0; margin: 0; display: flex; gap: 12px; flex-wrap: wrap; }
.slip { display: grid; gap: 2px; padding: 14px 16px; min-width: 180px; text-decoration: none; transform: rotate(-.4deg); }
.slips li:nth-child(2n) .slip { transform: rotate(.5deg); }
.slip:hover { border-color: var(--ink-soft); }
.slip .marker { font-weight: 700; justify-self: start; }

/* Row lists */
.section-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.section-head h2 { margin-bottom: 10px; }
.rows { list-style: none; padding: 0; margin: 0; }
.rows li + li { border-top: 1px solid var(--edge); }
.row-link { display: grid; grid-template-columns: minmax(0, 2fr) auto auto auto 16px; gap: 16px; align-items: center; padding: 12px 16px; text-decoration: none; min-height: 52px; }
.row-link:hover { background: color-mix(in srgb, var(--walk-in) 50%, var(--paper)); }
.row-link .name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.chips { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips a { display: inline-block; padding: 8px 12px; border: 1px solid var(--edge); border-radius: 999px; text-decoration: none; background: var(--paper); }

/* Search with autocomplete */
.search { position: relative; width: min(340px, 100%); }
.search ul { position: absolute; z-index: 20; top: calc(100% + 4px); left: 0; right: 0; list-style: none; margin: 0; padding: 4px; box-shadow: 0 8px 24px rgb(0 0 0 / .12); }
.search li { padding: 10px; border-radius: 4px; cursor: pointer; display: grid; }
.search li.active, .search li:hover { background: var(--walk-in); }
.search-empty { position: absolute; top: calc(100% + 4px); left: 0; right: 0; padding: 10px; z-index: 20; }

/* One invoice */
.tabs { display: none; }
.split { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.read { padding: 20px; }
.invoice-head { border-bottom: 1px solid var(--edge); padding-bottom: 12px; margin-bottom: 4px; }
.total { font-size: 20px; margin: 8px 0; display: flex; align-items: center; gap: 12px; }
.total .num { position: relative; font-weight: 700; padding: 2px 8px; }
.circle { position: absolute; inset: -8px -10px; width: calc(100% + 20px); height: calc(100% + 16px); fill: none; stroke: var(--done);
  stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: 400; animation: circle 600ms ease-out; }
@keyframes circle { from { stroke-dashoffset: 400; } }
.ok-stamp { color: var(--done); font-weight: 700; font-size: 22px; transform: rotate(-8deg); display: inline-block; }
.items { list-style: none; padding: 0; margin: 0; }
.item { padding: 14px 0; border-bottom: 1px solid var(--edge); }
.item.focused { background: color-mix(in srgb, var(--highlighter) 18%, transparent); margin: 0 -20px; padding: 14px 20px; }
.item.excluded h3, .item.excluded .paid { text-decoration: line-through; color: var(--ink-soft); }
.item-head { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.tag { font-size: 14px; color: var(--ink-soft); white-space: nowrap; }
.paid, .cost { margin: 4px 0; }
.item details { margin-top: 6px; }
.item summary { cursor: pointer; color: var(--ink-soft); min-height: 32px; }
.row-check { margin-top: 10px; padding: 12px; border-left: 3px solid var(--highlighter); background: color-mix(in srgb, var(--walk-in) 60%, var(--paper)); border-radius: 0 var(--radius) var(--radius) 0; }
.question { font-weight: 600; margin: 0 0 4px; }
.crop { width: 100%; max-height: 180px; object-fit: contain; object-position: left; display: block; border: 1px solid var(--edge); border-radius: 4px; margin-bottom: 10px; background: #fff; }
.pack-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.separate { margin-top: 20px; }
.separate h2 { font-size: 16px; color: var(--ink-soft); }
.separate ul { list-style: none; padding: 0; margin: 0; }
.separate li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; }
.notes { margin-top: 16px; color: var(--ink-soft); }
.original { position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow: auto; }
.pages img { display: block; width: 100%; border-radius: var(--radius); border: 1px solid var(--edge); margin-bottom: 12px; background: #fff; }
.understood { margin-top: 10px; padding: 10px 12px; background: var(--paper); border: 1px solid var(--edge); border-radius: var(--radius); }
.understood p { margin: 4px 0; }
.check-label { display: flex; gap: 8px; align-items: center; font-weight: 400; margin-top: 6px; }
.check-label input { width: 20px; min-height: 20px; height: 20px; }
.saved-bar { position: fixed; left: 50%; transform: translateX(-50%); bottom: 20px; z-index: 45; display: flex; gap: 12px; align-items: center;
  background: var(--ink); color: var(--paper); padding: 8px 8px 8px 16px; border-radius: var(--radius); box-shadow: 0 8px 24px rgb(0 0 0 / .2); max-width: calc(100vw - 32px); }
.saved-bar .check { stroke: var(--paper); }
.saved-bar button { min-height: 36px; }
.saved-bar button.quiet { color: var(--paper); }
.answered { color: var(--done); margin: 4px 0; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.answered .link { color: var(--ink); }
.similar { margin-top: 14px; padding: 12px; border: 1px solid var(--edge); border-radius: var(--radius); }
.similar ul { list-style: none; padding: 0; margin: 8px 0; max-height: 200px; overflow: auto; }
.similar li { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; border-top: 1px solid var(--edge); }
.question-pages { display: flex; gap: 8px; overflow-x: auto; margin: 8px 0 12px; }
.question-pages img { max-height: 260px; border: 1px solid var(--edge); border-radius: 4px; background: #fff; }
@media (max-width: 760px) { .saved-bar { bottom: 80px; } }
.delivery-rows { display: grid; gap: 8px; margin: 8px 0; }
.delivery-row { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 8px; }
.not-food summary { padding: 12px 16px; cursor: pointer; font-weight: 600; }
.row-plain { display: grid; grid-template-columns: minmax(0, 2fr) auto auto auto; gap: 12px; align-items: center; padding: 8px 16px; border-top: 1px solid var(--edge); }
.row-plain .item-actions { display: flex; gap: 6px; }
.rename { display: grid; gap: 6px; width: min(480px, 100%); }
.page-head .link { margin-left: 8px; }
.recost { margin: 16px 0; }
@media (max-width: 760px) { .delivery-row { grid-template-columns: 1fr 1fr; } .delivery-row label:first-child { grid-column: 1 / -1; } .row-plain { grid-template-columns: 1fr auto; } }
.advanced summary { cursor: pointer; font-weight: 600; }
.advanced label { margin-top: 12px; }
.notice { padding: 10px 12px; border-left: 3px solid var(--ink-soft); background: var(--walk-in); border-radius: 0 var(--radius) var(--radius) 0; }
.cost-progress { margin: 16px 0; padding: 16px; border: 1px solid var(--edge); border-radius: var(--radius); background: color-mix(in srgb, var(--walk-in) 50%, var(--paper)); }
.progress-head { display: flex; justify-content: space-between; align-items: baseline; }
.bar { height: 6px; border-radius: 3px; background: var(--edge); margin: 10px 0 12px; overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--done); transition: width 400ms ease; }
.steps-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.steps-list li { display: flex; gap: 10px; align-items: center; }
.steps-list li.pending { color: var(--ink-soft); }
.steps-list li.running { font-weight: 600; }
.step-mark { width: 20px; display: inline-flex; justify-content: center; }
.pending-dot { width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--edge); display: inline-block; }
.working { display: flex; gap: 8px; align-items: center; color: var(--ink-soft); }
.dots { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--ink-soft); border-top-color: transparent; animation: spin 900ms linear infinite; display: inline-block; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Sheets */
.sheet-backdrop { position: fixed; inset: 0; background: rgb(15 20 35 / .45); display: grid; place-items: end center; z-index: 40; padding: 16px; }
.sheet { width: min(560px, 100%); max-height: calc(100vh - 32px); overflow: auto; padding: 20px; animation: rise 200ms ease-out; }
.sheet h2 { margin-top: 0; }
.sheet .later { margin-top: 8px; }
@keyframes rise { from { transform: translateY(24px); opacity: 0; } }
.checks div { padding: 10px 0; border-top: 1px solid var(--edge); }
.checks dt { font-weight: 700; } .checks dd { margin: 2px 0 8px; }

/* Upload queue */
.queue { position: fixed; right: 16px; bottom: 16px; width: min(420px, calc(100vw - 32px)); background: var(--paper); border: 1px solid var(--edge);
  border-radius: var(--radius); box-shadow: 0 10px 30px rgb(0 0 0 / .15); z-index: 30; padding: 12px 14px; }
.queue header { display: grid; gap: 2px; margin-bottom: 6px; }
.queue header .hint { font-size: 14px; }
.queue ul { list-style: none; padding: 0; margin: 0; max-height: 40vh; overflow: auto; }
.queue-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "file actions" "body body"; gap: 4px 8px; align-items: center; padding: 8px 0; border-top: 1px solid var(--edge); }
.queue-item .file { grid-area: file; }
.queue-item .item-actions { grid-area: actions; display: flex; gap: 6px; align-items: center; }
.queue-item .item-actions > * { min-height: 36px; }
.queue-item .stage, .queue-item .progress-line { grid-area: body; }
.queue-item .file { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.queue-item .stage { color: var(--ink-soft); font-size: 14px; }
.queue-item.failed .stage, .queue-item.rejected .stage { color: var(--red-pen); }
.queue-item.needs_clarification .stage { color: var(--ink); }
.processing { padding: 4px 16px; }
.processing .queue-item:first-child { border-top: 0; }
.upload-list { list-style: none; padding: 0; margin: 0; }
.progress-line { display: grid; gap: 4px; }
.progress-line .bar { margin: 2px 0 0; }
.stage-row { display: flex; justify-content: space-between; gap: 12px; color: var(--ink-soft); font-size: 14px; }

/* Configuration */
.model-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.model-table { width: 100%; border-collapse: collapse; }
.model-table th, .model-table td { text-align: left; padding: 8px 6px; border-top: 1px solid var(--edge); vertical-align: middle; }
.steps { list-style: none; padding: 0; counter-reset: step; max-width: 720px; }
.steps li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 20px; counter-increment: step; }
.steps li + li { border-top: 1px solid var(--edge); }
.steps li strong::before { content: counter(step) "  "; color: var(--ink-soft); }
.steps p { margin: 2px 0 0; }

/* Phone: bottom tab bar with the central + Add invoice */
@media (max-width: 760px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: static; height: auto; flex-direction: row; align-items: center; justify-content: space-between; padding: 12px var(--gutter); border-right: 0; border-bottom: 1px solid var(--edge); }
  .sidebar nav, .sidebar .add, .sidebar .reset, .sidebar .admin-link { display: none; }
  .brand img { width: 40px; }  /* the plate alone (main.tsx) */
  .restaurant-switch select { min-width: 0; }
  main { padding: 16px var(--gutter) 140px; }
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr) 44px; position: fixed; left: 0; right: 0; bottom: 0; background: var(--paper);
    border-top: 1px solid var(--edge); z-index: 35; padding-bottom: env(safe-area-inset-bottom); }
  .tabbar { grid-template-columns: 1fr 1fr 64px 1fr 1fr 48px; }
  .tabbar a { text-align: center; padding: 12px 2px; text-decoration: none; font-size: 14px; min-height: 52px; }
  .tabbar a.active { font-weight: 700; box-shadow: inset 0 3px 0 var(--ink); }
  .tab-add { border-radius: 50%; width: 52px; height: 52px; margin: -14px auto 0; background: var(--ink); color: var(--paper); font-size: 28px; justify-content: center; padding: 0; }
  .queue { bottom: 72px; right: var(--gutter); }
  .row-link { grid-template-columns: minmax(0, 1fr) auto 16px; gap: 4px 12px; }
  .row-link > .hint { grid-column: 1; font-size: 14px; }
  .row-link > .num { grid-row: 1; grid-column: 2; }
  .row-link > [aria-hidden] { grid-row: 1; grid-column: 3; }
  .tabs { display: flex; gap: 8px; margin-bottom: 12px; }
  .tabs button[aria-selected="true"] { background: var(--ink); color: var(--paper); }
  .split { grid-template-columns: minmax(0, 1fr); }
  .hide-phone { display: none; }
  .read { padding: 16px; }
  .item.focused { margin: 0 -16px; padding: 14px 16px; }
  .original { position: static; max-height: none; }
  .model-grid, .pack-fields { grid-template-columns: minmax(0, 1fr); }
  .steps li { flex-direction: column; align-items: flex-start; }
  .sheet-backdrop { padding: 0; }
  .sheet { border-radius: 12px 12px 0 0; max-height: 90vh; }
  h1.headline { font-size: 25px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}


/* The uploads card folded to one line */
.queue-title { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.queue.folded { padding: 0; }
.queue-open { width: 100%; justify-content: space-between; border: 0; background: transparent; min-height: 48px; }

/* Deleting: the Undo bar after a delete or restore, and Settings → Recently deleted */
.undo-bar { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 40; display: flex; align-items: center; gap: 12px;
  max-width: min(560px, calc(100vw - 2 * var(--gutter))); padding: 10px 12px 10px 16px; border: 1px solid var(--edge); border-radius: var(--radius);
  box-shadow: 0 6px 24px rgb(0 0 0 / 0.18); }
.undo-bar.error { border-color: var(--red-pen); }
.undo-bar > span { flex: 1; }
@media (max-width: 760px) { .undo-bar { bottom: 76px; } }
.deleted-row { display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: center; padding: 8px 0; }
@media (max-width: 560px) { .deleted-row { grid-template-columns: 1fr auto; } .deleted-row .small { grid-column: 1; } }
button.danger, .link.danger { color: var(--red-pen); }
button.quiet.danger { background: transparent; border-color: transparent; }
button.danger:not(.quiet):not(.link) { color: #fff; }
.place-fields { display: grid; grid-template-columns: 2fr 1.4fr 1.4fr; gap: 10px; margin: 8px 0 4px; }
.place-fields label { display: grid; gap: 4px; }
@media (max-width: 640px) { .place-fields { grid-template-columns: 1fr; } }
.step-body h2.next-part { margin-top: 18px; }
.undecided { margin-top: 4px; }
.undecided .ingredient-search { margin-top: 6px; }

/* Settings: a number with its unit beside it, and a checkbox on one line with its words */
.inline-input { display: flex; gap: 6px; align-items: center; }
.inline-input input[type="number"] { width: 6em; }
.check-row { display: flex; gap: 8px; align-items: center; margin: 12px 0; }
.check-row input { width: auto; min-height: 0; }

/* Left menu: a count on the right of Menus, Recipes and Invoices, and a mark when something needs you (!) or is being
   worked on (a spinner). The words are in the tooltip. Settings sits at the bottom. */
.sidebar nav a { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.nav-mark { display: inline-flex; align-items: center; gap: 6px; }
.nav-count { font-size: 13px; color: var(--ink-soft); font-variant-numeric: tabular-nums; font-weight: 400; }
.nav-todo { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; font-size: 12px; font-weight: 700;
  background: var(--est-bg); color: var(--est-ink); border: 1px solid var(--est-edge); }
.nav-todo.small { width: 14px; height: 14px; font-size: 10px; margin-left: 3px; vertical-align: 2px; }
.nav-busy { width: 13px; height: 13px; border-radius: 50%; border: 2px solid var(--edge); border-top-color: var(--ink); animation: spin 0.9s linear infinite; }
.nav-soon { font-size: 11px; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.04em; }
.sidebar .nav-bottom { margin-top: 4px; border-top: 1px solid var(--edge); padding-top: 8px; }
@media (prefers-reduced-motion: reduce) { .nav-busy { animation: none; } }

/* Sales (coming soon) */
.sales-soon h2 { margin-top: 0; }
.sales-ideas-head { margin-top: 28px; }
.sales-ideas { list-style: none; padding: 0; display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.sales-ideas li { display: flex; gap: 12px; padding: 14px 16px; }
.sales-ideas h3 { margin: 0 0 4px; font-size: 16px; }
.sales-ideas p { margin: 0; color: var(--ink-soft); font-size: 14px; line-height: 1.45; }
.sales-icon { font-size: 22px; line-height: 1; }

/* A credit note: its lines, negative amounts on the right. */
.credit-lines { list-style: none; padding: 0; }
.credit-lines li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--edge); }

/* Uploads: the batch at a glance, and a list that stays a sensible height however many files there are. */
.batch-summary { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 4px 0 8px; }
.batch-summary .chip { border: 1px solid var(--edge); border-radius: 999px; padding: 2px 10px; background: var(--paper); min-height: 32px; }
.batch-summary .chip.chosen { background: var(--walk-in); border-color: var(--ink); }
.upload-list { max-height: 50vh; overflow-y: auto; }
.upload-list .file-name { display: block; word-break: break-all; }
/* Signing in, and who's signed in */
.sign-in { min-height: 100vh; display: grid; place-content: center; gap: 16px; padding: 24px; justify-items: center; }
.sign-in .panel { width: min(420px, 92vw); display: grid; gap: 12px; }
.local-only { color: var(--est-ink); }
.signed-in { margin: 8px 0 0; color: var(--ink-soft); overflow-wrap: anywhere; }
.people-table { width: 100%; border-collapse: collapse; }
.people-table td { padding: 6px 4px; border-top: 1px solid var(--edge); }
.invite-form { display: flex; flex-wrap: wrap; gap: 8px; }
.invite-form input { flex: 1; min-width: 12em; }
.copyable, .join-code { user-select: all; font-size: 14px; }
.join-code { font-size: 18px; letter-spacing: .1em; font-weight: 700; }
/* Help: ask about your numbers */
.help-button { position: fixed; right: 20px; bottom: 20px; z-index: 45;  /* above an open item window (.sheet-backdrop 40): ask about it */
  border-radius: 999px; padding: 8px 16px; box-shadow: 0 2px 8px rgba(0,0,0,.15); }
.help-panel { position: fixed; right: 16px; bottom: 16px; z-index: 46; width: min(420px, calc(100vw - 32px)); max-height: min(640px, calc(100vh - 32px));
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto; gap: 8px; padding: 12px 14px; box-shadow: 0 6px 24px rgba(0,0,0,.18); }
.help-panel header { display: flex; justify-content: space-between; align-items: baseline; }
.help-turns { overflow-y: auto; display: grid; gap: 12px; align-content: start; }
.help-q { margin: 0; font-weight: 600; }
.help-a { margin: 4px 0; white-space: pre-wrap; }
.help-proposal { display: flex; gap: 8px; align-items: center; justify-content: space-between; border: 1px solid var(--est-edge); background: var(--est-bg);
  border-radius: var(--radius); padding: 6px 8px; margin-top: 4px; }
.help-proposal p { margin: 0; }
.help-ask { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; }
.help-ask .hint { grid-column: 1 / -1; }
@media (max-width: 760px) { .help-button { bottom: 76px; } }
.sign-in .google { width: 100%; padding: 10px; font-weight: 600; }
.sign-in .or { text-align: center; margin: 0; }
.sign-in form { display: grid; gap: 10px; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--edge); margin: -4px 0 4px; }
.auth-tabs button { border: 0; background: none; padding: 10px; border-bottom: 3px solid transparent; font-weight: 600; color: var(--ink-soft); }
.auth-tabs button.active { border-bottom-color: var(--ink); color: var(--ink); }

/* Printing a sheet or the agenda: no floating Help on the page */
@media print { .help-button, .help-panel { display: none !important; } }
