/* Design „Logbuch“: Nachtblau auf Weiß, Messing als einziger Akzent. */

:root {
  --night: #0e2a3b;
  --night-2: #173d54;
  --sea: #2f6f86;
  --canvas: #ffffff;
  --paper: #ffffff;
  --tint: #f4f6f8;
  --ink: #1b2a33;
  --muted: #5f6b70;
  --line: #dde2e7;
  --brass: #b0874b;
  --port: #b23b2a;           /* Backbord: rot */
  --port-bg: #f8e3dd;
  --sand: #d7a94b;
  --sand-bg: #f7ecd2;
  --starboard: #2a7654;      /* Steuerbord: grün */
  --starboard-bg: #dff0e6;
  --focus: #8fc1d6;
  --radius: 10px;
  /* Moderne Groteskschriften, die auf den Geräten schon vorhanden sind */
  --display: "Avenir Next", "Segoe UI Variable Display", "SF Pro Display", "Helvetica Neue", system-ui, sans-serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  /* Foto: Frans Ruiter, Unsplash (unsplash.com/photos/8LQJXnnRgfY) */
  /* Beim Fototausch neuen Dateinamen wählen, sonst zeigen Browser bis zu 1 h das alte Bild. */
  --hero-image: url("/hero-istrien.jpg");

  /* Namen, die der Admin-Bereich verwendet */
  --navy: var(--night);
  --navy-dark: #081d29;
  --navy-soft: #e3edf1;
  --accent: var(--brass);
  --no: var(--port);
  --no-bg: var(--port-bg);
  --ok: #7a5a12;
  --ok-bg: var(--sand-bg);
  --yes: var(--starboard);
  --yes-bg: var(--starboard-bg);
  --bg: var(--canvas);
  --card: var(--paper);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font: 16px/1.55 var(--sans);
  color: var(--ink);
  background-color: var(--canvas);
}

a { color: var(--night-2); }

.wrap { max-width: 760px; margin: 0 auto; padding: 24px 16px 48px; }
.wrap.wide { max-width: 1100px; }
.wrap.narrow { max-width: 540px; padding-top: 12vh; }

h1, h2 { font-family: var(--display); font-weight: 500; letter-spacing: -.005em; color: var(--night); }
h1 { font-size: 2rem; line-height: 1.15; margin: .2em 0 .5em; }
h2 { font-size: 1.3rem; margin: 1.6rem 0 .6rem; }

.muted { color: var(--muted); }
.nowrap { white-space: nowrap; }
.pre { white-space: pre-line; }

/* --- Titelbereich ---------------------------------------------------------- */

.hero {
  position: relative;
  color: #fff;
  background: var(--night) var(--hero-image) center 55% / cover no-repeat;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(14, 42, 59, .62) 0%, rgba(14, 42, 59, .3) 40%, rgba(14, 42, 59, .88) 100%);
}
.hero-inner {
  position: relative;
  max-width: 760px;
  margin: 0 auto;
  padding: 22px 16px 84px;
}
.hero .eyebrow {
  margin: 3.2rem 0 0;
  color: #f1d9a8;
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .2em;
  text-transform: uppercase;
}
.hero h1 {
  color: #fff;
  font-size: clamp(2.2rem, 8vw, 3.4rem);
  font-weight: 600;
  letter-spacing: -.015em;
  margin: .15em 0 .35em;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .3);
}
.hero .intro { max-width: 32rem; margin: 0; color: rgba(255, 255, 255, .92); font-size: 1.05rem; }

.wave {
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 100%;
  height: 42px;
  fill: var(--canvas);
}

.lang-switch {
  float: right;
  margin: 0 0 .5rem .5rem;
  padding: .22rem .8rem;
  font-size: .85rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--night);
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 999px;
}
.lang-switch:hover { border-color: var(--night); }
.hero .lang-switch { color: #fff; background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .55); }
.hero .lang-switch:hover { background: rgba(255, 255, 255, .25); }

/* --- Hinweise ------------------------------------------------------------- */

.notice {
  margin: 0 0 1rem;
  padding: .7rem 1rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-left: 4px solid var(--brass);
  border-radius: 6px;
}
.alert {
  margin: 0 0 1rem;
  padding: .8rem 1rem;
  color: #6d2019;
  background: var(--port-bg);
  border: 1px solid #e6b6ae;
  border-radius: var(--radius);
}
.alert ul { margin: .4rem 0 0; padding-left: 1.2rem; }
.alert a { color: inherit; }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem;
  box-shadow: 0 10px 30px -22px rgba(14, 42, 59, .45);
}
.center { text-align: center; }
.anchor { color: var(--brass); margin-bottom: .2rem; }

/* --- Formular ------------------------------------------------------------- */

h2.section {
  display: flex;
  align-items: center;
  gap: .8rem;
  margin: 2.4rem 0 1rem;
  font-size: 1.3rem;
}
h2.section:first-child { margin-top: .6rem; }
h2.section::after {
  content: "";
  flex: 1;
  height: 5px;
  border-top: 1px solid var(--brass);
  border-bottom: 1px solid var(--brass);
  opacity: .6;
}

.question {
  margin: 0 0 1rem;
  padding: 1.1rem 1.2rem 1.2rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 1px 0 rgba(14, 42, 59, .04), 0 10px 24px -20px rgba(14, 42, 59, .5);
  scroll-margin-top: 1rem;
}
.question.has-error { border-color: var(--port); box-shadow: 0 0 0 2px var(--port-bg); }
.question fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.question legend { padding: 0; width: 100%; }
.legend-row { display: flex; align-items: flex-start; gap: .65rem; }
.q-label { font-family: var(--display); font-size: 1.1rem; font-weight: 500; line-height: 1.3; color: var(--night); }
.optional { color: var(--muted); font-size: .85rem; font-family: var(--sans); font-weight: normal; white-space: nowrap; }

.buoy {
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 1.9rem;
  height: 1.9rem;
  margin-top: -.05rem;
  font: 500 .8rem/1 var(--sans);
  color: var(--night);
  background: #fff;
  border: 1.5px solid var(--night);
  border-radius: 50%;
}

.desc { margin: .35rem 0 0; color: var(--muted); font-size: .95rem; }
.veggie { margin: .45rem 0 0; font-size: .95rem; }
.tag {
  display: inline-block;
  margin-right: .25rem;
  padding: .02rem .5rem;
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--night);
  background: var(--navy-soft);
  border-radius: 999px;
}

.allergens { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem; margin: .5rem 0 0; font-size: .78rem; }
.allergens-label { color: var(--muted); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; }
.allergen {
  padding: 0 .5rem;
  font-weight: 400;
  color: var(--night);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
}

/* Vegetarier sehen nur die vegetarischen Varianten */
.survey:not(.is-veg) .only-veg,
.survey.is-veg .only-meat { display: none; }

.options { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .85rem; }
.options.stack { flex-direction: column; }

.opt {
  position: relative;
  flex: 1 1 0;
  min-width: 7rem;
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .6rem .8rem;
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
}
.options.stack .opt { flex: none; }
.opt input { margin: 0; width: 1.05rem; height: 1.05rem; flex: none; accent-color: var(--night); }
.opt:hover { border-color: var(--night-2); }
.opt:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 1px; }
.opt:has(input:checked) { border-color: var(--night); background: #e6eef2; font-weight: 500; }

/* Bewertung als Balken aus drei Feldern */
.options.vote {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  overflow: hidden;
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 8px;
}
.vote .opt {
  justify-content: center;
  min-width: 0;
  padding: .7rem .4rem .6rem;
  text-align: center;
  line-height: 1.25;
  border: 0;
  border-right: 1px solid var(--line);
  border-radius: 0;
}
.vote .opt:last-child { border-right: 0; }
.vote .opt input { position: absolute; opacity: 0; pointer-events: none; }
.vote .opt:hover { background: var(--tint); }
.vote .opt:has(input:checked) { color: #fff; background: var(--night); }
@supports not selector(:has(*)) {
  .vote .opt input { position: static; opacity: 1; pointer-events: auto; }
}

.variant {
  margin-top: 1rem;
  padding: .75rem .85rem .85rem;
  background: var(--tint);
  border: 1px solid var(--line);
  border-radius: 8px;
}
.variant-label { margin: 0; font-weight: 500; font-size: .92rem; }
.variant .options { margin-top: .5rem; }
.variant.has-error { border-color: var(--port); }
.variant.has-error .variant-label { color: var(--port); }

input[type=text], input[type=number], textarea, select {
  width: 100%;
  padding: .6rem .7rem;
  font: inherit;
  color: inherit;
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 8px;
}
.question input[type=text], .question input[type=number], .question textarea, .question select { margin-top: .75rem; }
textarea { min-height: 5rem; resize: vertical; }
input:focus, textarea:focus, select:focus { outline: 3px solid var(--focus); border-color: var(--night); }

.error-msg { margin: .5rem 0 0; color: var(--port); font-weight: 500; font-size: .95rem; }

.actions {
  position: sticky;
  bottom: 0;
  padding: 1.25rem 0 .75rem;
  background: linear-gradient(to bottom, transparent, var(--canvas) 40%);
}

.btn {
  display: inline-block;
  padding: .6rem 1.1rem;
  font: inherit;
  font-weight: 500;
  color: var(--night);
  text-decoration: none;
  background: #fff;
  border: 1.5px solid var(--night);
  border-radius: 8px;
  cursor: pointer;
}
.btn:hover { background: var(--navy-soft); }
.btn.primary { color: #fff; background: var(--night); }
.btn.primary:hover { background: var(--navy-dark); }
.btn.small { padding: .3rem .6rem; font-size: .85rem; }
.btn.danger { color: var(--port); border-color: var(--port); }
.btn.danger:hover { background: var(--port-bg); }
.actions .btn {
  width: 100%;
  padding: .9rem;
  font-size: 1.05rem;
  letter-spacing: .02em;
  border-bottom: 3px solid var(--brass);
  box-shadow: 0 8px 20px -8px rgba(14, 42, 59, .55);
}

/* --- Admin ----------------------------------------------------------------- */

.admin-nav {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}
.admin-nav a {
  margin-bottom: -1px;
  padding: .5rem .8rem;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
}
.admin-nav a:hover { color: var(--night); }
.admin-nav a.active { color: var(--night); font-weight: 600; border-color: var(--brass); }
.admin-nav .spacer { flex: 1; }

.add-form { margin: 1rem 0 1.5rem; }
.add-form label { font-weight: 600; }
.row { display: flex; gap: .5rem; margin-top: .4rem; max-width: 480px; }

.table-wrap {
  overflow-x: auto;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.table { width: 100%; border-collapse: collapse; }
.table th, .table td {
  padding: .6rem .75rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}
.table th {
  font-size: .75rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--muted);
  background: var(--tint);
}
.table tbody tr:last-child td { border-bottom: 0; }
.table tr.highlight td { background: var(--navy-soft); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
.table td.has-no { background: var(--port-bg); }

.status {
  display: inline-block;
  padding: .1rem .55rem;
  font: 600 .75rem/1.4 var(--sans);
  white-space: nowrap;
  vertical-align: middle;
  border-radius: 999px;
}
.status-open { color: var(--muted); background: var(--tint); }
.status-started { color: var(--ok); background: var(--ok-bg); }
.status-submitted { color: var(--yes); background: var(--yes-bg); }

.link-cell { min-width: 19rem; }
input.link { padding: .35rem .5rem; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .8rem; }
.link-actions { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .4rem; }

.meta p { margin-top: 0; }
.answers dt { margin-top: .75rem; font-weight: 600; }
.answers dt:first-child { margin-top: 0; }
.answers dd { margin: .1rem 0 0; white-space: pre-line; }
.answers dd.vote-0 { color: var(--port); font-weight: 600; }
.answers dd.vote-2 { color: var(--starboard); font-weight: 600; }

.summary-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1rem; }
.summary-grid h2 { margin-top: 0; font-size: 1.05rem; }
ul.plain { margin: 0; padding: 0; list-style: none; }
ul.plain li { margin: .35rem 0; }

.names { display: block; font-size: .8rem; font-weight: normal; color: var(--muted); }

.bar {
  display: flex;
  max-width: 16rem;
  height: .45rem;
  margin-top: .35rem;
  overflow: hidden;
  background: var(--tint);
  border-radius: 999px;
}
.bar .b0 { background: var(--port); }
.bar .b1 { background: var(--sand); }
.bar .b2 { background: var(--starboard); }

@media (max-width: 560px) {
  h1 { font-size: 1.6rem; }
  .hero .eyebrow { margin-top: 2.4rem; }
  .q-label { font-size: 1.1rem; }
  .vote .opt { padding: .65rem .2rem .55rem; font-size: .88rem; }
  .row { flex-direction: column; }
}

/* --- Speiseplan (nach Abschluss der Umfrage) ------------------------------- */

[hidden] { display: none !important; }

.hero-cta {
  margin-top: 1.2rem;
  color: var(--night);
  background: #fff;
  border-color: #fff;
}
.hero-cta:hover { background: var(--navy-soft); }

.recipe-intro { margin: -.2rem 0 1rem; color: var(--muted); font-size: .95rem; }
.recipe-intro p { margin: .3rem 0; }

.recipe {
  margin: 0 0 .75rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 1px 0 rgba(14, 42, 59, .04), 0 10px 24px -20px rgba(14, 42, 59, .5);
}
.recipe > summary {
  display: flex;
  align-items: flex-start;
  gap: .7rem;
  padding: 1rem 1.1rem;
  cursor: pointer;
  list-style: none;
}
.recipe > summary::-webkit-details-marker { display: none; }
.recipe > summary::after { content: "+"; margin-left: auto; color: var(--muted); font-size: 1.3rem; line-height: 1; }
.recipe[open] > summary::after { content: "–"; }
.recipe > summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: var(--radius); }
.recipe-head { display: flex; flex-direction: column; gap: .15rem; }
.recipe-meta { color: var(--muted); font-size: .85rem; }
.recipe-body { padding: .2rem 1.1rem 1.1rem; border-top: 1px solid var(--line); }
.recipe-body h4 { margin: 1rem 0 .4rem; font-family: var(--display); font-weight: 500; color: var(--night); }
.recipe-body ul, .recipe-body ol { margin: .3rem 0 .6rem; padding-left: 1.2rem; }
.recipe-body li { margin: .2rem 0; }
.recipe-body blockquote {
  margin: .8rem 0;
  padding: .55rem .8rem;
  font-size: .92rem;
  background: var(--tint);
  border-left: 3px solid var(--brass);
  border-radius: 4px;
}
.recipe-body blockquote p { margin: .2rem 0; }
.recipes.compact .recipe > summary { padding: .75rem 1rem; }

.my-votes .votes-section {
  margin: 1.1rem 0 .3rem;
  font-family: var(--display);
  font-size: 1rem;
  font-weight: 500;
  color: var(--night);
}
.my-votes .votes-section:first-child { margin-top: 0; }
.vote-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .2rem .75rem;
  padding: .45rem 0;
  font-size: .92rem;
  border-bottom: 1px solid var(--line);
}
.vote-a { font-weight: 500; }
.vote-a.vote-0 { color: var(--muted); }
.vote-variant { width: 100%; color: var(--muted); font-size: .82rem; }

/* --- Einkaufsassistent ------------------------------------------------------ */

.shop-bar {
  position: sticky;
  top: 0;
  z-index: 5;
  padding: 12px 16px;
  color: #fff;
  background: var(--night);
}
.shop-bar-inner { display: flex; align-items: center; gap: .8rem; max-width: 760px; margin: 0 auto; }
.shop-back {
  display: inline-grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  color: #fff;
  font-size: 1.2rem;
  text-decoration: none;
  border: 1.5px solid rgba(255, 255, 255, .5);
  border-radius: 50%;
}
.shop-bar-title { flex: 1; min-width: 0; }
.shop-bar h1 { margin: 0; font-size: 1.2rem; color: #fff; }
.shop-bar p { margin: 0; font-size: .82rem; color: rgba(255, 255, 255, .8); }
.shop-bar .lang-switch { float: none; margin: 0; color: #fff; background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .55); }

.shop-controls { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin: 0 0 1rem; }
.seg { display: inline-flex; overflow: hidden; background: #fff; border: 1.5px solid var(--line); border-radius: 8px; }
.seg button {
  padding: .45rem .8rem;
  font: inherit;
  font-size: .9rem;
  color: var(--ink);
  background: #fff;
  border: 0;
  border-right: 1px solid var(--line);
  cursor: pointer;
}
.seg button:last-child { border-right: 0; }
.seg button[aria-pressed="true"] { color: #fff; background: var(--night); }
.shop-progress { margin: 0 0 0 auto; color: var(--muted); font-size: .9rem; }

.cat {
  margin: 0 0 1rem;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.cat > summary {
  display: flex;
  justify-content: space-between;
  padding: .75rem 1rem;
  font-family: var(--display);
  font-size: 1.08rem;
  font-weight: 500;
  color: var(--night);
  background: var(--tint);
  cursor: pointer;
  list-style: none;
}
.cat > summary::-webkit-details-marker { display: none; }
.cat-count { color: var(--muted); font-family: var(--sans); font-size: .85rem; }
.cat-empty { margin: 0; padding: .7rem 1rem; color: var(--muted); font-size: .9rem; }

.items { margin: 0; padding: 0; list-style: none; }
.item { border-top: 1px solid var(--line); }
.item:first-child { border-top: 0; }
.item-main {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: .45rem .75rem;
  align-items: start;
  padding: .7rem 1rem;
}
.item-toggle {
  padding: 0;
  font: inherit;
  color: inherit;
  text-align: left;
  background: none;
  border: 0;
  cursor: pointer;
}
.item-toggle:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.item-name { font-weight: 500; }
.item-who { display: block; margin-top: .1rem; font-size: .8rem; color: var(--muted); }
.item-amount { text-align: right; white-space: nowrap; }
.item-amount strong { font-weight: 500; }
.item-amount .orig { display: block; font-size: .76rem; color: var(--muted); }
.item-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: .4rem; }

/* st-*: eigene Namen, damit die Status-Plaketten des Admin-Bereichs nicht greifen */
.item.st-claimed { box-shadow: inset 3px 0 0 var(--brass); }
.item.mine { background: #fbf8f1; }
.item.st-done { background: var(--tint); }
.item.st-done .item-name { color: var(--muted); text-decoration: line-through; }
.item.unneeded .item-name, .item.unneeded .item-amount { color: var(--muted); }

.badge {
  display: inline-block;
  margin-left: .35rem;
  padding: 0 .45rem;
  font-size: .68rem;
  font-weight: 500;
  letter-spacing: .05em;
  text-transform: uppercase;
  vertical-align: middle;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
}
.badge.added { color: #7a5a12; border-color: var(--brass); }

.item-details { padding: 0 1rem 1rem; font-size: .92rem; }
.details-title {
  margin: 0 0 .3rem;
  font: 500 .75rem/1.4 var(--sans);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}
.usage { margin: 0 0 .6rem; padding: 0; list-style: none; }
.usage li { display: flex; justify-content: space-between; gap: .75rem; padding: .25rem 0; border-bottom: 1px dotted var(--line); }
.usage li.other { color: var(--muted); font-style: italic; }
.warn { color: var(--port); }
.item-note { margin: .3rem 0; color: var(--muted); }
.amount-form { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin-top: .6rem; }
.amount-form label { display: flex; align-items: center; gap: .4rem; }
.amount-form input { width: 6.5rem; margin: 0; padding: .35rem .5rem; }

.add-item { border-top: 1px solid var(--line); }
.add-item > summary { padding: .6rem 1rem; color: var(--night-2); font-size: .9rem; cursor: pointer; }
.add-item form { display: grid; grid-template-columns: 1fr 5.5rem 6rem auto; gap: .4rem; padding: 0 1rem 1rem; }
.add-item input { margin: 0; padding: .4rem .5rem; }

.toast {
  position: fixed;
  left: 50%;
  bottom: 1rem;
  z-index: 10;
  max-width: calc(100% - 32px);
  padding: .6rem 1rem;
  color: #fff;
  background: var(--night);
  border-radius: 8px;
  transform: translateX(-50%);
  box-shadow: 0 10px 30px -10px rgba(14, 42, 59, .6);
}

@media (max-width: 560px) {
  .shop-progress { width: 100%; margin: 0; }
  .add-item form { grid-template-columns: 1fr 1fr; }
  .add-item form input[name="name"] { grid-column: 1 / -1; }
}

/* --- Schnelleinstieg Kategorien ------------------------------------------------ */

.cat-nav {
  position: sticky;
  top: var(--bar-h, 0px);
  z-index: 4;
  display: flex;
  gap: .4rem;
  margin: 0 -16px 1rem;
  padding: .55rem 16px;
  overflow-x: auto;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.cat-nav::-webkit-scrollbar { display: none; }
.cat-nav:empty { display: none; }
.cat-chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .35rem .5rem .35rem .8rem;
  font-size: .88rem;
  white-space: nowrap;
  color: var(--night);
  text-decoration: none;
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  scroll-snap-align: start;
}
.cat-chip:hover { border-color: var(--night-2); }
.cat-chip:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; }
.cat-chip[aria-current="true"] { color: #fff; background: var(--night); border-color: var(--night); }
.chip-count {
  min-width: 1.35rem;
  padding: 0 .35rem;
  font-size: .75rem;
  line-height: 1.35rem;
  text-align: center;
  color: var(--muted);
  background: var(--tint);
  border-radius: 999px;
}
.cat-chip[aria-current="true"] .chip-count { color: var(--night); background: #fff; }
.cat-chip.done:not([aria-current="true"]) { color: var(--muted); }
.cat { scroll-margin-top: var(--sticky-h, 120px); }
