/* JAFCAM v2 — mobile-first base styles */
:root {
  --bg: #f6f5f1;
  --surface: #ffffff;
  --text: #1d2420;
  --muted: #5b655f;
  --border: #d9ddd6;
  --brand: #2f6b3a;
  --brand-ink: #ffffff;
  --brand-soft: #e3efe4;
  --danger: #a3261b;
  --danger-soft: #fbe9e7;
  --success-soft: #e6f2e7;
  --info-soft: #eef2f7;
  --focus: #1b5fd1;
  --radius: 10px;
  --tap: 44px;
  --nav-h: 64px;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--text);
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; overflow-x: hidden; }
body { background: var(--bg); min-height: 100dvh; font-size: 16px; }
img, svg { max-width: 100%; }
a { color: var(--brand); text-underline-offset: 2px; }
h1 { font-size: 1.5rem; line-height: 1.25; margin: 0 0 .5rem; overflow-wrap: anywhere; }
h2 { font-size: 1.1rem; margin: 0 0 .75rem; }
p { margin: 0 0 1rem; overflow-wrap: anywhere; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--surface); padding: .5rem 1rem; z-index: 50; }
.skip:focus { left: 8px; top: 8px; }
.lead { color: var(--muted); }
.muted { color: var(--muted); font-size: .95rem; }

/* ---------- public / auth ---------- */
.public { min-height: 100dvh; display: flex; flex-direction: column; align-items: center; padding: 16px 12px 32px; }
.public-header { width: 100%; max-width: 440px; padding: 8px 4px 16px; }
.brand { display: inline-flex; align-items: center; gap: .5rem; font-weight: 700; color: var(--text); text-decoration: none; min-height: var(--tap); }
.brand-mark { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--brand); color: var(--brand-ink); }
.card { width: 100%; max-width: 440px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 16px; }
.card-wide { max-width: 640px; }
.public-header:has(+ .card-wide) { max-width: 640px; }

/* ---------- forms ---------- */
.form { display: grid; gap: 14px; margin-bottom: 1rem; }
.form.narrow { max-width: 420px; }
.grid-2 { grid-template-columns: minmax(0, 1fr); }
.field { display: grid; gap: 4px; min-width: 0; }
.field label, .field .label { font-weight: 600; font-size: .95rem; }
input, select { font: inherit; width: 100%; min-width: 0; min-height: var(--tap); padding: 8px 12px; border: 1px solid #a9b1aa; border-radius: 8px; background: #fff; color: var(--text); }
input[type="file"] { padding: 8px; }
input[aria-invalid="true"], select[aria-invalid="true"] { border-color: var(--danger); border-width: 2px; }
select:disabled { background: #f0f1ee; color: var(--muted); }
.hint { margin: 0; font-size: .875rem; color: var(--muted); }
.field-error { margin: 0; font-size: .9rem; color: var(--danger); font-weight: 600; }
.field-error::before { content: "⚠ "; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: var(--tap); padding: 8px 18px; border-radius: 8px; border: 2px solid transparent; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; max-width: 100%; text-align: center; }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-danger { background: var(--surface); color: var(--danger); border-color: #e2b4ae; }
.btn:disabled { opacity: .7; cursor: progress; }
.form .btn { width: 100%; }
.stack { display: grid; gap: 10px; margin-bottom: 1rem; }
.stack .btn { width: 100%; }
.inline-form { display: inline; margin: 0; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--brand); text-decoration: underline; cursor: pointer; min-height: var(--tap); }
.alert { border-radius: 8px; padding: 10px 12px; margin-bottom: 1rem; border-left: 4px solid; }
.alert-error { background: var(--danger-soft); border-color: var(--danger); }
.alert-success { background: var(--success-soft); border-color: var(--brand); }
.alert-info { background: var(--info-soft); border-color: #557; }
.list { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: 8px; }
.list-link { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-height: var(--tap); padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; text-decoration: none; color: var(--text); }

/* ---------- app shell ---------- */
.shell { min-height: 100dvh; }
.sidebar { display: none; }
.topbar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 52px; padding: 8px 16px; background: var(--surface); border-bottom: 1px solid var(--border); }
.topbar-farm { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.topbar-user { font-size: .85rem; color: var(--muted); flex-shrink: 0; }
.page { padding: 16px 16px calc(var(--nav-h) + 24px + env(safe-area-inset-bottom)); max-width: 960px; }
.page-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; margin-bottom: .5rem; }
.breadcrumb { font-size: .9rem; color: var(--muted); margin-bottom: .25rem; }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; }
.icon { width: 24px; height: 24px; flex-shrink: 0; }

.bottom-nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; background: var(--surface); border-top: 1px solid var(--border); padding-bottom: env(safe-area-inset-bottom); }
.bottom-nav ul { list-style: none; margin: 0; padding: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
.bottom-link { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: var(--nav-h); padding: 6px 2px; color: var(--muted); text-decoration: none; font-size: .72rem; font-weight: 600; border-top: 3px solid transparent; }
.bottom-link span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Active: indicator bar + tinted pill + filled icon + colour (never colour alone). Same box size = no layout shift. */
.bottom-link[aria-current="page"] { color: var(--brand); border-top-color: var(--brand); background: var(--brand-soft); }
.bottom-link[aria-current="page"] .icon, .nav-link[aria-current="page"] .icon { fill: currentColor; fill-opacity: .18; stroke-width: 2.2; }
.bottom-link[aria-current="page"] span { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }

.farm-chip { display: grid; gap: 4px; padding: 12px; border: 1px solid var(--border); border-radius: 8px; margin: 12px 0; }
.farm-name { font-weight: 700; overflow-wrap: anywhere; }
.switch-link { font-size: .9rem; }
.role-badge { display: inline-block; justify-self: start; font-size: .78rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); border: 1px solid #b9d3bc; white-space: nowrap; }
.side-nav { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.nav-link { display: flex; align-items: center; gap: 10px; min-height: var(--tap); padding: 8px 12px; border-radius: 8px; color: var(--text); text-decoration: none; font-weight: 600; border-left: 4px solid transparent; }
.nav-link:hover { background: #f0f2ee; }
.nav-link[aria-current="page"] { background: var(--brand-soft); color: var(--brand); border-left-color: var(--brand); }
.coming { margin-top: auto; font-size: .82rem; color: var(--muted); }

.checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.checklist li { display: flex; align-items: center; gap: 10px; min-height: 32px; }
.check { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--border); font-size: .8rem; font-weight: 700; flex-shrink: 0; }
.checklist li.done .check { background: var(--brand); border-color: var(--brand); color: #fff; }
.dl { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; margin: 0; }
.dl dt { font-weight: 600; }
.dl dd { margin: 0; overflow-wrap: anywhere; }
.members { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 8px; }
.member { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px 12px; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 12px; }
.member-main { display: grid; min-width: 0; }
.member-name { font-weight: 600; overflow-wrap: anywhere; }
.member-email { color: var(--muted); font-size: .9rem; overflow-wrap: anywhere; }
.member-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
.member-actions .btn { width: auto; }
.member .inline-form .btn { width: auto; }
.logo-preview { display: block; width: 96px; height: 96px; object-fit: contain; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 12px; background: #fff; }

@media (min-width: 480px) {
  .card { padding: 28px 28px; }
  .grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .span-2 { grid-column: 1 / -1; }
  .form .btn, .stack .btn { width: auto; justify-self: start; }
  .stack { grid-auto-flow: column; justify-content: start; }
}

@media (min-width: 768px) {
  .shell { display: grid; grid-template-columns: 240px minmax(0, 1fr); }
  .sidebar { display: flex; flex-direction: column; position: sticky; top: 0; height: 100dvh; overflow-y: auto; padding: 16px; background: var(--surface); border-right: 1px solid var(--border); }
  .bottom-nav { display: none; }
  .page { padding: 24px 32px 48px; }
  .topbar { padding: 8px 32px; }
  .topbar-farm { visibility: hidden; }
  .member { grid-template-columns: minmax(0, 1fr) auto auto; }
  .member-actions { grid-column: auto; }
  h1 { font-size: 1.75rem; }
}

@media (min-width: 1200px) {
  .shell { grid-template-columns: 280px minmax(0, 1fr); }
  .page { padding: 32px 48px 48px; }
}

/* ---------- V2-1 modules ---------- */
.page-title { min-width: 0; }
.page-title h1 { margin-bottom: .25rem; }
.sub { margin: 0 0 .5rem; }
.head-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cols { display: grid; gap: 0 16px; grid-template-columns: minmax(0, 1fr); }
.rows { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: var(--tap); padding: 10px 12px; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; color: var(--text); text-decoration: none; }
.row:hover { border-color: var(--brand); }
.row-main { display: grid; min-width: 0; }
.row-title { font-weight: 700; overflow-wrap: anywhere; }
.row-meta { color: var(--muted); font-size: .88rem; overflow-wrap: anywhere; }
.row-aside { flex-shrink: 0; }
.badge { display: inline-block; font-size: .76rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border); background: #f3f4f1; color: var(--text); white-space: nowrap; }
.badge-ok { background: var(--brand-soft); color: var(--brand); border-color: #b9d3bc; }
.badge-warn { background: #fff4dc; color: #7a4b00; border-color: #f0cf8c; }
.badge-bad { background: var(--danger-soft); color: var(--danger); border-color: #e2b4ae; }
.badge-info { background: var(--info-soft); color: #223a66; border-color: #c4cfe3; }
.full { color: var(--danger); font-weight: 700; }
.hist { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.hist li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; padding: 8px 0; border-bottom: 1px solid var(--border); min-width: 0; }
.hist li > * { overflow-wrap: anywhere; }
.hist li.voided > span:not(.muted), .hist li.voided > strong { text-decoration: line-through; color: var(--muted); }
.action { border: 1px solid var(--border); border-radius: 8px; margin: 0 0 10px; background: var(--surface); }
.action > summary { min-height: var(--tap); display: flex; align-items: center; padding: 8px 12px; font-weight: 600; cursor: pointer; list-style: none; }
.action > summary::before { content: "+"; display: inline-block; width: 1.25rem; font-weight: 700; color: var(--brand); }
.action[open] > summary::before { content: "−"; }
.action > summary::-webkit-details-marker { display: none; }
.action-body { padding: 0 12px 12px; }
.action-danger > summary { color: var(--danger); }
.void-form { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; width: 100%; margin: 4px 0; }
.void-form input { flex: 1 1 140px; min-width: 0; }
.void-form .btn { width: auto; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.filters input, .filters select { flex: 1 1 140px; width: auto; min-width: 0; }
.filters .btn { flex: 0 0 auto; }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 12px 0; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 12px; overflow-x: auto; }
.tabs a { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 12px; color: var(--text); text-decoration: none; border-bottom: 3px solid transparent; font-weight: 600; white-space: nowrap; }
.tabs a[aria-current="page"] { border-bottom-color: var(--brand); color: var(--brand); }
.empty { padding: 20px 16px; text-align: center; background: var(--surface); border: 1px dashed var(--border); border-radius: var(--radius); margin-bottom: 16px; }
.empty-title { font-weight: 700; margin-bottom: .25rem; }
.grid-3 { display: grid; gap: 10px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
fieldset.panel { margin: 0 0 12px; }
fieldset legend { font-weight: 600; padding: 0 4px; overflow-wrap: anywhere; }
fieldset legend input { width: auto; min-height: auto; margin-right: 6px; transform: scale(1.3); }
.quick { list-style: none; padding: 0; margin: 0 0 12px; display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.quick a { display: flex; align-items: center; justify-content: center; min-height: var(--tap); border: 1px solid var(--border); border-radius: 8px; text-decoration: none; font-weight: 600; }
.form > .field, .form > .grid-3 { min-width: 0; }
@media (max-width: 340px) { .grid-3 { grid-template-columns: minmax(0, 1fr); } }
@media (min-width: 900px) { .cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.bottom-link { font-size: .68rem; }
@media (max-width: 479px) {
  .dl { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .dl dt { margin-top: 8px; font-size: .85rem; color: var(--muted); }
}
.inline-void { flex-basis: 100%; }
.inline-void > summary { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 4px; color: var(--danger); font-weight: 600; cursor: pointer; list-style: none; }
.inline-void > summary::-webkit-details-marker { display: none; }

/* ---------- V2-2 health ---------- */
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr)); gap: 6px 12px; }
.check-item { display: flex; align-items: center; gap: 8px; min-height: var(--tap); padding: 4px 8px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); overflow-wrap: anywhere; }
.check-item input { width: 20px; height: 20px; min-height: 0; flex-shrink: 0; }
.question { display: grid; gap: 6px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg label { display: inline-flex; align-items: center; gap: 6px; min-height: var(--tap); padding: 0 12px; border: 1px solid var(--border); border-radius: 999px; }
.seg input { width: 18px; height: 18px; min-height: 0; }
.results { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 10px; }
.result { border: 1px solid var(--border); border-radius: 8px; padding: 12px; background: var(--surface); }
.result p { margin: 4px 0; overflow-wrap: anywhere; }
.result-head { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.chooser { grid-template-columns: minmax(0, 1fr); }
.inline-form select { width: auto; min-width: 0; }
.hist .inline-form { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }

/* ---------- V2-4 planner ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 130px), 1fr)); gap: 8px; margin: 0 0 16px; }
.stats > div { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px; min-width: 0; }
.stats dt { font-size: .8rem; color: var(--muted); }
.stats dd { margin: 0; font-weight: 700; font-size: 1.15rem; overflow-wrap: anywhere; }
.stats dd.warn { color: #7a4b00; }
.work-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.work-card { border: 1px solid var(--border); border-radius: 8px; padding: 12px; background: var(--surface); min-width: 0; }
.work-head { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; overflow-wrap: anywhere; }
.work-badges { display: inline-flex; flex-wrap: wrap; gap: 4px; }
.work-meta { margin: 4px 0 8px; overflow-wrap: anywhere; }
.work-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-start; margin-top: 8px; }
.work-actions > form { margin: 0; }
.work-actions > .action { flex-basis: 100%; margin: 0; }
.work-line .work-title { font-weight: 600; }
.small-link { display: inline-flex; align-items: center; min-height: var(--tap); }
.instructions summary { display: inline-flex; align-items: center; min-height: var(--tap); cursor: pointer; font-weight: 600; }
.instructions p, .instructions-text { white-space: pre-wrap; overflow-wrap: anywhere; }
.days { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 12px; }
@media (min-width: 900px) { .days { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1500px) { .days { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.month { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 120px), 1fr)); gap: 6px; }
.month a { display: grid; gap: 2px; min-height: var(--tap); padding: 8px; border: 1px solid var(--border); border-radius: 8px; text-decoration: none; color: var(--text); overflow-wrap: anywhere; }
.month li.today a { border-color: var(--brand); border-width: 2px; }
.load-days { display: flex; flex-wrap: wrap; gap: 4px; flex-basis: 100%; }
.load-day { font-size: .8rem; padding: 2px 6px; border: 1px solid var(--border); border-radius: 6px; white-space: nowrap; }
.load-day.over { background: #fff4dc; border-color: #f0cf8c; color: #7a4b00; font-weight: 700; }
.check { display: flex; align-items: center; gap: 8px; min-height: var(--tap); overflow-wrap: anywhere; }
.check input { width: 20px; height: 20px; min-height: 0; flex-shrink: 0; }

/* ---------- V2-5 slaughter & meat ---------- */
.label-card { display: grid; gap: 2px; border: 2px dashed var(--border); border-radius: 8px; padding: 12px; margin: 0 0 8px; max-width: 360px; overflow-wrap: anywhere; }
.label-card strong { font-size: 1.1rem; }
.work-card.voided { opacity: .7; }

/* ---------- V2-7 reports ---------- */
.table-scroll { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.report { border-collapse: collapse; font-size: .85rem; min-width: 100%; }
table.report th, table.report td { border-bottom: 1px solid var(--border); padding: 6px 8px; text-align: left; white-space: nowrap; }
table.report th { position: sticky; top: 0; background: var(--surface); }

/* ---------- top-right menu (Members, Settings, Account, language, Sign out) ---------- */
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.topbar-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.menu { position: relative; }
.menu-btn { display: inline-flex; align-items: center; justify-content: center; width: var(--tap); height: var(--tap); border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); cursor: pointer; list-style: none; }
.menu-btn::-webkit-details-marker { display: none; }
.menu-btn::marker { content: ""; }
.menu-btn:hover { background: var(--bg); }
.menu-btn:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.menu[open] > .menu-btn, .menu-btn.is-active { background: var(--brand-soft); border-color: var(--brand); color: var(--brand); }
/* The panel floats over the page: opening or closing never moves anything. */
.menu-panel { position: absolute; right: 0; top: calc(100% + 6px); z-index: 40; width: min(300px, calc(100vw - 24px)); max-height: calc(100dvh - 72px); overflow-y: auto; padding: 8px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 10px 30px rgba(0, 0, 0, .16); }
.menu-user { margin: 4px 8px 8px; font-weight: 700; overflow-wrap: anywhere; }
.menu-list { list-style: none; margin: 0; padding: 0; }
.menu-link { display: flex; align-items: center; gap: 10px; width: 100%; min-height: var(--tap); padding: 8px 10px; border: 0; border-radius: 8px; background: none; color: var(--text); font: inherit; font-weight: 600; text-align: left; text-decoration: none; cursor: pointer; }
.menu-link:hover { background: var(--bg); }
.menu-link:focus-visible, .lang-btn:focus-visible { outline: 3px solid var(--focus); outline-offset: -3px; }
.menu-link[aria-current="page"] { background: var(--brand-soft); color: var(--brand); box-shadow: inset 3px 0 0 var(--brand); }
.menu-link[aria-current="page"] .icon { fill: currentColor; fill-opacity: .18; stroke-width: 2.2; }
.menu-signout { margin: 4px 0 0; padding-top: 4px; border-top: 1px solid var(--border); }
.lang-switch { margin: 4px 0; padding-top: 4px; border-top: 1px solid var(--border); }
.lang-switch fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.lang-switch legend { padding: 4px 10px; font-size: .85rem; color: var(--muted); }
.lang-options { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 0 4px 4px; }
.lang-btn { min-height: var(--tap); padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); font: inherit; font-weight: 600; cursor: pointer; }
.lang-btn[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.lang-compact { margin: 0; padding: 0; border: 0; }
.lang-compact .lang-options { padding: 0; }
.lang-compact .lang-btn { min-width: var(--tap); font-size: .85rem; }
.public-header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
@media (max-width: 340px) { .topbar { padding: 6px 8px; } .topbar-user { display: none; } }
.public-footer { margin: 16px 0 24px; font-size: .8rem; color: var(--muted); text-align: center; }
