/* Vinis — tokens */
:root {
  --bg: #f4f5f2;
  --surface: #ffffff;
  --surface-2: #eaece7;
  --ink: #15181b;
  --ink-2: #5b636b;
  --ink-3: #8a9299;
  --rule: #d7dbd4;
  --rule-strong: #b9bfb8;
  --accent: #1b6e49;
  --accent-ink: #ffffff;
  --accent-soft: #dcefe4;
  --warn: #b8621b;
  --warn-soft: #f6e6d6;
  --neg: #8a3b3b;
  --tag: #15181b;
  --tag-ink: #f4f5f2;
  --shadow: 0 -8px 30px rgba(21, 24, 27, 0.08);
  --sheet-shadow: 0 -12px 40px rgba(21, 24, 27, 0.25);

  --rott: #7b1e2f;
  --vitt: #d6b84a;
  --rose: #e58a96;
  --bubbel: transparent;
  --stark: #8a5a2a;
  --vivino: #b8372f;

  --font:
    "Familjen Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --gutter: 74px;
  --bottle: 34px;
  --pad: 16px;
  --tap: 44px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1113;
    --surface: #171a1d;
    --surface-2: #22262a;
    --ink: #eef0ec;
    --ink-2: #a2aab0;
    --ink-3: #6f777d;
    --rule: #2a2f33;
    --rule-strong: #3c4348;
    --accent: #56c78f;
    --accent-ink: #0f1113;
    --accent-soft: #163526;
    --warn: #e6a352;
    --warn-soft: #3a2a17;
    --neg: #d38a8a;
    --tag: #eef0ec;
    --tag-ink: #0f1113;
    --shadow: 0 -8px 30px rgba(0, 0, 0, 0.45);
    --sheet-shadow: 0 -12px 40px rgba(0, 0, 0, 0.6);
    --vitt: #e0c65a;
    --vivino: #e0605a;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1113;
  --surface: #171a1d;
  --surface-2: #22262a;
  --ink: #eef0ec;
  --ink-2: #a2aab0;
  --ink-3: #6f777d;
  --rule: #2a2f33;
  --rule-strong: #3c4348;
  --accent: #56c78f;
  --accent-ink: #0f1113;
  --accent-soft: #163526;
  --warn: #e6a352;
  --warn-soft: #3a2a17;
  --neg: #d38a8a;
  --tag: #eef0ec;
  --tag-ink: #0f1113;
  --shadow: 0 -8px 30px rgba(0, 0, 0, 0.45);
  --sheet-shadow: 0 -12px 40px rgba(0, 0, 0, 0.6);
  --vitt: #e0c65a;
  --vivino: #e0605a;
}

* {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(132px + env(safe-area-inset-bottom));
}
button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}
a {
  color: inherit;
}
[hidden] {
  display: none !important;
}

/* Header */
.top {
  padding: calc(14px + env(safe-area-inset-top)) var(--pad) 10px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--ink-2);
}
.brand .logo {
  color: var(--ink-2);
  flex: none;
}
.store-title {
  display: flex;
  align-items: baseline;
  gap: 8px;
  width: 100%;
  min-height: var(--tap);
  text-align: left;
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  padding: 4px 0;
}
.store-title .chev {
  flex: none;
  align-self: center;
  color: var(--ink-3);
}
.store-sub {
  margin: 8px 0 0;
  color: var(--ink-2);
  font-size: 15px;
  line-height: 1.35;
}
.list-seg {
  display: flex;
  width: 100%;
  margin-top: 6px;
}
.list-seg button {
  flex: 1;
  height: 40px;
  padding: 0 8px;
  font-size: 14px;
  white-space: nowrap;
}
.info-ex .list-ex {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
  text-align: right;
}

/* List */
main {
  padding: 0;
}
.list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--rule-strong);
}
.list-head {
  display: flex;
  align-items: center;
  padding: 0 var(--pad) 0 0;
  font-size: 13px;
  color: var(--ink-3);
}
.list-head-cols {
  flex: 1;
  display: grid;
  grid-template-columns: var(--gutter) var(--bottle) 1fr auto;
  column-gap: 12px;
  align-items: center;
}
.col-btn {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  min-height: 40px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-3);
  text-align: left;
}
.col-btn:first-child {
  padding-left: var(--pad);
}
.col-btn.right {
  justify-content: flex-end;
}
.col-btn[aria-sort] {
  color: var(--ink);
}
.col-btn .arr {
  font-size: 9px;
}
.col-btn .sortnote {
  font-weight: 400;
  color: var(--ink-3);
  margin-left: 4px;
}
.list-head > .head-btn {
  padding-left: 8px;
}
.head-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 32px;
  padding: 0 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
}
.head-btn .i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1.5px solid currentColor;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.list-head > span:first-child {
  padding-left: var(--pad);
}

.row {
  display: grid;
  grid-template-columns: var(--gutter) var(--bottle) minmax(0, 1fr) auto;
  grid-template-rows: auto auto auto auto;
  column-gap: 12px;
  width: 100%;
  text-align: left;
  padding: 12px var(--pad) 12px 0;
  border-bottom: 1px solid var(--rule);
  align-items: start;
}
.row:active {
  background: var(--surface-2);
}
.row.out {
  color: var(--ink-3);
}
.row.out .name {
  text-decoration: line-through;
  text-decoration-color: var(--ink-3);
  text-decoration-thickness: 1.5px;
}

/* Shelf gutter — the margin note */
.shelf {
  grid-row: 1 / span 4;
  padding-left: var(--pad);
  padding-top: 3px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-2);
  line-height: 1.2;
  border-right: 1px solid var(--rule);
  align-self: stretch;
}
.shelf .code {
  display: block;
  font-size: 11px;
  font-weight: 500;
  color: var(--ink-3);
  margin-top: 3px;
  letter-spacing: 0.02em;
}
.shelf .ts-word {
  display: block;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.15;
  color: var(--ink-2);
  padding-right: 6px;
}
.shelf.ts .code {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  margin-top: 4px;
}
.shelf.aisle .where {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  background: var(--tag);
  color: var(--tag-ink);
  padding: 4px 7px 5px;
  border-radius: 3px;
  margin-left: -2px;
  line-height: 1;
}
.shelf.aisle .where .w {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
  opacity: 0.8;
}
.shelf.aisle .where .n {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-top: 2px;
}
.shelf.display .where {
  display: inline-block;
  border: 1.5px solid var(--ink-2);
  padding: 1px 6px 2px;
  border-radius: 3px;
  font-size: 13px;
  margin-left: -2px;
}
.shelf.unknown .where {
  display: inline-block;
  border: 1.5px dashed var(--ink-3);
  color: var(--ink-3);
  padding: 1px 6px 2px;
  border-radius: 3px;
  font-size: 13px;
  margin-left: -2px;
}

.bottle {
  grid-column: 2;
  grid-row: 1 / span 4;
  align-self: start;
  height: 92px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}
.bottle img {
  width: var(--bottle);
  height: 92px;
  object-fit: contain;
  object-position: top center;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.25));
}
.row.out .bottle img {
  opacity: 0.45;
  filter: grayscale(1);
}

.name {
  grid-column: 3;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.005em;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.meta {
  grid-column: 3;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-top: 3px;
  font-size: 14px;
  color: var(--ink-2);
}
.meta .sep {
  color: var(--ink-3);
}
.priceline {
  grid-column: 3;
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 2px 10px;
  margin-top: 6px;
  font-size: 16px;
}
.price {
  font-weight: 600;
  white-space: nowrap;
}
.value {
  color: var(--ink-2);
  white-space: nowrap;
}
.value.up {
  color: var(--accent);
  font-weight: 600;
}
.value.down {
  color: var(--ink-3);
}
.row.out .value.up {
  color: var(--ink-3);
  font-weight: 500;
}

/* Wine colour dot */
.dot {
  display: inline-block;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  vertical-align: -1px;
  background: var(--c);
  flex: none;
}
.dot.bubbel {
  background: transparent;
  box-shadow: inset 0 0 0 2.5px var(--ink-2);
}
.dot.bubbel.rosa {
  box-shadow: inset 0 0 0 2.5px var(--rose);
}

.vol-chip,
.new-chip {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  padding: 3px 5px;
  border-radius: 3px;
  border: 1.5px solid currentColor;
  color: var(--ink);
  vertical-align: 2px;
  margin-left: 2px;
}
.new-chip {
  border-style: none;
  background: var(--surface-2);
  color: var(--ink-2);
  padding: 4px 6px;
}

/* Score column */
.verdict {
  grid-column: 3;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 6px;
  margin-top: 7px;
}
.verdict .badge {
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 5px;
}
.row.out .verdict .badge {
  opacity: 0.6;
}

.score {
  grid-column: 4;
  grid-row: 1 / span 4;
  text-align: right;
  min-width: 52px;
  line-height: 1;
}
.score .n {
  display: block;
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.score.low .n {
  color: transparent;
  -webkit-text-stroke: 1.4px var(--ink-2);
  font-weight: 600;
}
.score .n.none {
  color: var(--ink-3);
}
.score .of {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  color: var(--ink-3);
  white-space: nowrap;
}
.score .vv,
.info-ex .vv {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-top: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-2);
  white-space: nowrap;
}
.score .vv .star,
.info-ex .vv .star {
  color: var(--vivino);
}
.score .iv {
  display: block;
  margin-top: 5px;
  font-size: 13px;
  color: var(--ink-3);
  white-space: nowrap;
}
.stock {
  display: block;
  margin-top: 8px;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-2);
  white-space: nowrap;
}
.stock.few {
  color: var(--warn);
  font-weight: 700;
}
.stock.none {
  color: var(--ink-3);
  font-weight: 600;
  text-transform: none;
}

.empty,
.foot {
  padding: 28px var(--pad);
  color: var(--ink-2);
  text-align: left;
  font-size: 15px;
}
.foot {
  font-size: 13px;
  color: var(--ink-3);
}

/* Bottom bar */
.bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--surface);
  border-top: 1px solid var(--rule);
  box-shadow: var(--shadow);
  padding-bottom: env(safe-area-inset-bottom);
  z-index: 10;
}
.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 10px var(--pad) 4px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.chips::-webkit-scrollbar {
  display: none;
}
.chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 40px;
  padding: 0 14px;
  border-radius: 20px;
  border: 1.5px solid var(--rule-strong);
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  background: var(--surface);
  white-space: nowrap;
}
.chip[aria-pressed="true"] {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.chip .dot {
  width: 10px;
  height: 10px;
}
.chip[aria-pressed="true"] .dot.bubbel {
  box-shadow: inset 0 0 0 2.5px var(--bg);
}
.chip-gap {
  flex: none;
  width: 1px;
  height: 24px;
  background: var(--rule-strong);
  align-self: center;
  margin: 0 2px;
}

.bar-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px var(--pad) 10px;
}
.bar-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 44px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1.5px solid var(--rule-strong);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}
.bar-btn svg {
  color: var(--ink-2);
  flex: none;
}
.bar-btn.active {
  border-color: var(--ink);
}
.bar-btn .count {
  display: inline-grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 11px;
  background: var(--ink);
  color: var(--bg);
  font-size: 13px;
}
.bar-row.searching .bar-btn {
  display: none;
}
.seg {
  display: inline-flex;
  background: var(--surface-2);
  border-radius: 10px;
  padding: 3px;
  gap: 2px;
}
.seg button {
  height: 38px;
  padding: 0 14px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-2);
}
.seg button[aria-checked="true"] {
  background: var(--surface);
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}
.search {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
  justify-content: flex-end;
}
.search-btn {
  width: var(--tap);
  height: var(--tap);
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--ink-2);
  flex: none;
}
.search.open .search-btn {
  color: var(--ink);
}
.search-input {
  flex: 1;
  min-width: 0;
  height: 42px;
  border: 1.5px solid var(--rule-strong);
  border-radius: 10px;
  padding: 0 12px;
  font: inherit;
  font-size: 16px;
  background: var(--bg);
  color: var(--ink);
}
.search-input::-webkit-search-cancel-button {
  -webkit-appearance: none;
}

/* Sheets */
.sheet {
  position: fixed;
  inset: auto 0 0 0;
  margin: 0;
  width: 100%;
  max-width: 100%;
  max-height: 92dvh;
  border: 0;
  border-radius: 18px 18px 0 0;
  background: var(--bg);
  color: var(--ink);
  padding: 0;
  box-shadow: var(--sheet-shadow);
  overflow: auto;
  overscroll-behavior: contain;
}
.sheet::backdrop {
  background: rgba(10, 12, 14, 0.5);
}
.sheet[open] {
  animation: rise 260ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes rise {
  from {
    transform: translateY(40px);
    opacity: 0.6;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
@media (prefers-reduced-motion: reduce) {
  .sheet[open] {
    animation: none;
  }
}
.sheet-grip {
  width: 40px;
  height: 4px;
  border-radius: 2px;
  background: var(--rule-strong);
  margin: 10px auto 0;
}
.sheet-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: var(--tap);
  height: var(--tap);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--ink-2);
}
@media (min-width: 720px) {
  .sheet {
    left: 50%;
    right: auto;
    width: 560px;
    transform: translateX(-50%);
    border-radius: 18px 18px 0 0;
  }
  .sheet[open] {
    animation: none;
  }
  body {
    max-width: 560px;
    margin: 0 auto;
  }
  .bar {
    left: 50%;
    right: auto;
    width: 560px;
    transform: translateX(-50%);
  }
}

/* Store sheet */
.stores {
  padding: 8px var(--pad) calc(24px + env(safe-area-inset-bottom));
}
.stores h2 {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-3);
  margin: 22px 0 8px;
}
.store-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--rule);
}
.store-opt {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 4px 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
  text-align: left;
  width: 100%;
}
.store-opt .sn {
  font-size: 20px;
  font-weight: 600;
}
.store-opt .sc {
  grid-column: 1;
  color: var(--ink-2);
  font-size: 14px;
}
.store-opt .mark {
  grid-column: 2;
  grid-row: 1 / span 2;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid var(--rule-strong);
}
.store-opt[aria-checked="true"] .mark {
  background: var(--ink);
  border-color: var(--ink);
  box-shadow: inset 0 0 0 5px var(--bg);
}
.theme-seg {
  width: 100%;
}
.theme-seg button {
  flex: 1;
}
.about {
  font-size: 14px;
  color: var(--ink-2);
  margin: 24px 0 0;
  line-height: 1.45;
}

/* Detail */
.detail-body {
  padding: 20px var(--pad) calc(28px + env(safe-area-inset-bottom));
}

.d-where {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 14px 16px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--rule);
  margin-top: 8px;
}
.d-where.aisle {
  background: var(--tag);
  color: var(--tag-ink);
  border-color: var(--tag);
}
.d-where.aisle .d-where-sub,
.d-where.aisle .d-stock {
  color: inherit;
  opacity: 0.75;
}
.d-where.unknown {
  border-style: dashed;
  border-width: 1.5px;
  border-color: var(--ink-3);
}
.d-where-main {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.15;
}
.d-where-sub {
  font-size: 14px;
  color: var(--ink-2);
  margin-top: 3px;
}
.d-stock {
  text-align: right;
  font-size: 15px;
  color: var(--ink-2);
  white-space: nowrap;
  align-self: center;
}
.d-stock .big {
  display: block;
  font-size: 26px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1;
  margin-bottom: 4px;
}
.d-stock.few .big {
  color: var(--warn);
}
.d-where.aisle .d-stock .big {
  color: inherit;
}

.d-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 64px;
  gap: 14px;
  margin-top: 22px;
  align-items: start;
}
.d-name {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0;
}
.d-producer {
  margin: 6px 0 0;
  font-size: 16px;
  color: var(--ink-2);
}
.d-meta {
  margin: 10px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  font-size: 15px;
  color: var(--ink-2);
  align-items: center;
}
.d-img {
  width: 64px;
  height: 120px;
  object-fit: contain;
  justify-self: end;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.15));
}

.d-value {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--rule-strong);
}
.d-price {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
}
.d-price .vol {
  font-size: 18px;
  font-weight: 500;
  color: var(--ink-2);
  letter-spacing: 0;
  margin-left: 6px;
}
.d-sentence {
  font-size: 20px;
  line-height: 1.3;
  margin: 8px 0 0;
}
.d-sentence.up strong {
  color: var(--accent);
}
.d-sentence.down strong {
  color: var(--neg);
}
.d-value small {
  display: block;
  margin-top: 6px;
  color: var(--ink-3);
  font-size: 14px;
}

.d-verdict {
  margin-top: 22px;
}
.d-verdict-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
}
.d-score {
  font-size: 44px;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
}
.d-score.low {
  color: transparent;
  -webkit-text-stroke: 1.6px var(--ink-2);
}
.d-score-of {
  font-size: 15px;
  color: var(--ink-2);
}
.d-band {
  position: relative;
  height: 10px;
  margin: 14px 0 6px;
  background: var(--surface-2);
  border-radius: 5px;
  overflow: visible;
}
.d-band .range {
  position: absolute;
  top: 0;
  bottom: 0;
  background: var(--ink-3);
  opacity: 0.55;
  border-radius: 5px;
}
.d-band .pt {
  position: absolute;
  top: -4px;
  width: 18px;
  height: 18px;
  margin-left: -9px;
  border-radius: 50%;
  background: var(--ink);
  border: 3px solid var(--bg);
}
.d-band-axis {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--ink-3);
}
.d-verdict p {
  margin: 10px 0 0;
  color: var(--ink-2);
  font-size: 15px;
  line-height: 1.4;
}

.d-source {
  margin-top: 0;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 10px;
}
.d-source-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}
.d-source-name {
  font-weight: 600;
  font-size: 16px;
}
.d-source-pts {
  font-weight: 700;
  font-size: 18px;
  white-space: nowrap;
}
.d-source-pts small {
  font-weight: 500;
  color: var(--ink-2);
  font-size: 14px;
}
.d-source-pts.big {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  font-size: 30px;
  letter-spacing: -0.03em;
  line-height: 1;
}
.d-source-pts.big .star {
  width: 18px;
  height: 18px;
  align-self: center;
  color: var(--vivino);
}
.d-source-pts.muted {
  font-weight: 500;
  color: var(--ink-3);
  font-size: 15px;
}
.d-source.low .d-source-pts.big {
  color: transparent;
  -webkit-text-stroke: 1.5px var(--ink-2);
}
.d-source.low .d-source-pts.big small {
  color: var(--ink-2);
  -webkit-text-stroke: 0;
}
.d-source + .d-source {
  margin-top: 10px;
}
.vv-bar {
  height: 6px;
  margin-top: 12px;
  border-radius: 3px;
  background: var(--surface-2);
  overflow: hidden;
}
.vv-bar span {
  display: block;
  height: 100%;
  background: var(--vivino);
  border-radius: 3px;
}
.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}
.badge {
  display: inline-block;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  padding: 5px 10px;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--ink-2);
}
.badge.b-fynd {
  background: var(--accent);
  color: var(--accent-ink);
}
.badge.b-mer {
  background: var(--accent-soft);
  color: var(--accent);
}
.badge.b-pris {
  background: var(--surface-2);
  color: var(--ink-2);
}
.badge.b-ej {
  background: var(--warn-soft);
  color: var(--warn);
}
.d-note {
  margin: 12px 0 0;
  font-size: 16px;
  line-height: 1.45;
}
.d-source-foot {
  margin: 10px 0 0;
  font-size: 13px;
  color: var(--ink-3);
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
}
.d-source-foot a {
  color: var(--ink-2);
}

.d-section {
  margin-top: 26px;
}
.d-section h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-3);
  margin: 0 0 8px;
}
.d-taste {
  font-size: 17px;
  line-height: 1.45;
  margin: 0;
}
.d-usage {
  font-size: 15px;
  color: var(--ink-2);
  margin: 8px 0 0;
  line-height: 1.45;
}

.clocks {
  display: grid;
  gap: 10px;
  margin-top: 4px;
}
.clock {
  display: grid;
  grid-template-columns: 84px 1fr auto;
  align-items: center;
  gap: 12px;
  font-size: 15px;
}
.clock .lbl {
  color: var(--ink-2);
}
.clock .segs {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 2px;
  height: 12px;
}
.clock .segs i {
  display: block;
  background: var(--surface-2);
  border-radius: 2px;
}
.clock .segs i.on {
  background: var(--ink);
}
.clock .v {
  min-width: 2ch;
  text-align: right;
  font-weight: 600;
}

.pairs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.pair {
  font-size: 15px;
  padding: 7px 12px;
  border: 1.5px solid var(--rule-strong);
  border-radius: 18px;
}

.d-other {
  margin-top: 26px;
  padding: 12px 16px;
  border-left: 3px solid var(--rule-strong);
  font-size: 15px;
  color: var(--ink-2);
  line-height: 1.45;
}
.d-other strong {
  color: var(--ink);
}

.d-links {
  margin-top: 28px;
  display: grid;
  gap: 10px;
}
.d-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  padding: 0 16px;
  border-radius: 10px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
}
.d-link.quiet {
  background: transparent;
  color: var(--ink-2);
  border: 1.5px solid var(--rule-strong);
}
.d-artnr {
  margin-top: 14px;
  font-size: 13px;
  color: var(--ink-3);
}

/* Sort picker */
.picker,
.filters,
.info {
  padding: 8px var(--pad) calc(24px + env(safe-area-inset-bottom));
}
.picker h2,
.filters h2,
.info h2 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 18px 0 10px;
}
.picker-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--rule);
}
.pick {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 54px;
  padding: 0 2px;
  border-bottom: 1px solid var(--rule);
  font-size: 18px;
  text-align: left;
}
.pick .mark {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid var(--rule-strong);
  flex: none;
}
.pick[aria-checked="true"] {
  font-weight: 600;
}
.pick[aria-checked="true"] .mark {
  background: var(--ink);
  border-color: var(--ink);
  box-shadow: inset 0 0 0 5px var(--bg);
}

/* Filter sheet */
.filters {
  padding-bottom: 0;
}
.filter-body {
  padding-bottom: 12px;
}
.fgroup {
  margin-top: 16px;
}
.fgroup h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-3);
  margin: 0 0 8px;
}
.fchips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.fchips .chip {
  height: 38px;
  padding: 0 12px;
  font-size: 15px;
}
.fchips .chip .n {
  margin-left: 7px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-3);
}
.fchips .chip[aria-pressed="true"] .n {
  color: inherit;
  opacity: 0.7;
}
.fchips .badge-chip.b-fynd[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.fchips .badge-chip.b-ej[aria-pressed="true"] {
  background: var(--warn);
  border-color: var(--warn);
  color: var(--bg);
}
.filter-foot {
  position: sticky;
  bottom: 0;
  display: flex;
  gap: 10px;
  padding: 12px 0 calc(16px + env(safe-area-inset-bottom));
  background: var(--bg);
  border-top: 1px solid var(--rule);
}
.filter-foot button {
  height: 50px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
}
.filter-foot .ghost {
  flex: 0 0 auto;
  padding: 0 18px;
  border: 1.5px solid var(--rule-strong);
  color: var(--ink-2);
}
.filter-foot .ghost:disabled {
  opacity: 0.4;
  cursor: default;
}
.filter-foot .primary {
  flex: 1;
  background: var(--ink);
  color: var(--bg);
}

/* Info sheet */
.info-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--ink-2);
}
.info-body strong {
  color: var(--ink);
}
.info-body p {
  margin: 6px 0 0;
}
.info-row {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 14px;
  align-items: start;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
}
.info-row:first-child {
  border-top: 0;
  padding-top: 0;
}
.info-ex {
  display: flex;
  justify-content: flex-end;
  text-align: right;
  padding-top: 2px;
}
.info-ex .score {
  grid-column: auto;
  grid-row: auto;
}
.info-ex .score .n {
  font-size: 26px;
}
.info-ex .value {
  font-size: 14px;
  white-space: nowrap;
}
.info-ex.badges-col {
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}
.info-ex .badge {
  font-size: 12px;
  padding: 4px 8px;
}
.info-ex .stock {
  margin-top: 0;
  font-size: 15px;
}

/* Detail extras */
.d-img {
  width: 84px;
  height: 200px;
}
.d-head {
  grid-template-columns: minmax(0, 1fr) 84px;
}
.d-other h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-3);
  margin: 0 0 6px;
}
.d-other ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 4px;
}

/* Add a store */
.add-store {
  margin-top: 4px;
}
.site-search {
  width: 100%;
  margin-top: 4px;
}
.site-results {
  display: flex;
  flex-direction: column;
  margin-top: 6px;
}
.site-opt {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 2px 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--rule);
  text-align: left;
  width: 100%;
}
.site-opt .sn {
  font-size: 17px;
  font-weight: 600;
}
.site-opt .sc {
  grid-column: 1;
  color: var(--ink-2);
  font-size: 14px;
}
.site-opt .plus {
  grid-column: 2;
  grid-row: 1 / span 2;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid var(--rule-strong);
  display: grid;
  place-items: center;
  color: var(--ink-2);
  font-size: 20px;
  line-height: 1;
}
.site-opt[disabled] {
  opacity: 0.6;
  cursor: default;
}
.add-note {
  margin: 10px 0 0;
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.4;
}
.store-opt .status {
  grid-column: 1;
  font-size: 13px;
  color: var(--accent);
  font-weight: 600;
}
.store-opt .rm {
  grid-column: 3;
  grid-row: 1 / span 2;
  min-height: 36px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1.5px solid var(--rule-strong);
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.store-opt .rm.armed {
  border-color: var(--warn);
  color: var(--warn);
}
.store-opt.has-rm {
  grid-template-columns: 1fr auto auto;
}
.store-opt.has-rm .mark {
  grid-column: 2;
}

/* Vivino as the main grade: star, colour and label say where it comes from */
.score .n.vv-main {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--vivino);
}
.score .n.vv-main .star {
  width: 16px;
  height: 16px;
}
.score.low .n.vv-main {
  color: transparent;
  -webkit-text-stroke: 1.4px var(--vivino);
}
.score.low .n.vv-main .star {
  color: var(--vivino);
}
.score .of.vv-of {
  color: var(--vivino);
  font-weight: 600;
}

/* Favourites */
.list li {
  position: relative;
}
.fav-btn {
  position: absolute;
  right: 6px;
  bottom: 4px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  color: var(--ink-3);
  border-radius: 50%;
}
.fav-btn .fstar {
  fill: transparent;
}
.fav-btn[aria-pressed="true"] {
  color: var(--vitt);
}
.fav-btn[aria-pressed="true"] .fstar {
  fill: currentColor;
}
.fav-btn:active {
  background: var(--surface-2);
}
.row {
  padding-right: 16px;
}
.score .stock {
  padding-right: 0;
}
.list li .row .score {
  padding-bottom: 30px;
}
.favs-seg {
  flex: 0 0 auto !important;
  padding: 0 12px !important;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.favs-seg svg {
  color: var(--vitt);
}
.shelf.elsewhere .where {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.15;
}
.row.borrowed {
  background: var(--surface-2);
}
.d-link.d-fav {
  display: inline-flex;
  gap: 10px;
  justify-content: center;
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--rule-strong);
}
.d-link.d-fav .fstar {
  fill: transparent;
  color: var(--ink-2);
}
.d-link.d-fav.on {
  border-color: var(--vitt);
}
.d-link.d-fav.on .fstar {
  fill: var(--vitt);
  color: var(--vitt);
}
.d-where.borrowed {
  border-style: dashed;
}
.info-ex .fav-ex {
  font-size: 22px;
  color: var(--vitt);
}
