/* ==========================================================================
   VERUM · Formula first.
   Design system + page styles. One stylesheet, mobile-first.
   ========================================================================== */

:root {
  /* Colour */
  --paper:        #FAFAF8;
  --ink:          #1C1C1A;
  --ink-60:       #5A5A55;
  --ink-40:       #6C6C66;   /* 5.1:1 on paper, 4.6:1 on the grey cards */
  --sage:         #8B9D83;   /* fills, bars, active states; carries ink text, never sits as text */
  --sage-deep:    #56654F;   /* 5.9:1 on paper, safe for text and links */
  --sage-wash:    #EEF1EA;   /* full-width section bands */
  --sage-tint:    #E4EADF;   /* component fills; reads on paper and on the band */
  --sage-line:    rgba(139, 157, 131, 0.30);  /* graph-paper rules and dots */
  --forest:       #242A22;   /* footer ground, sage pulled down into charcoal */
  --forest-line:  rgba(250, 250, 248, 0.16);
  --grey:         #D8D8D3;   /* dividers, card grounds */
  --grey-soft:    #EFEFEC;
  --white:        #FFFFFF;

  /* Type */
  /* Three voices, deliberately distinct:
     serif for headline moments, grotesk for everything readable, mono for data. */
  --serif: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  /* Space */
  --gutter: 1.5rem;
  --measure: 34rem;
  --section: 4.25rem;

  /* Motion */
  --fast: 150ms cubic-bezier(.4, 0, .2, 1);
  --base: 220ms cubic-bezier(.4, 0, .2, 1);
}

@media (min-width: 40em) { :root { --gutter: 2.5rem; --section: 5.25rem; } }
@media (min-width: 64em) { :root { --gutter: 4rem;   --section: 6.75rem; } }

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.65;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; display: block; }
button, input, textarea, select { font: inherit; color: inherit; }

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.25em; }

/* Headings are focused by script for screen-reader flow; no visible ring. */
[tabindex="-1"]:focus, [tabindex="-1"]:focus-visible { outline: none; }

:focus-visible {
  outline: 2px solid var(--sage-deep);
  outline-offset: 3px;
  border-radius: 2px;
}
/* The footer ground is dark, so the ring lifts to full sage there. */
.footer :focus-visible { outline-color: var(--sage); }

::selection { background: var(--sage); color: var(--ink); }

/* --- Type scale ---------------------------------------------------------- */

h1, h2, h3, h4 { font-weight: 500; letter-spacing: -0.025em; line-height: 1.1; margin: 0; }

/* Headline voice. Fraunces is optical-size aware: the larger the setting, the
   more character it is allowed. Sub-headings stay on the grotesk so the two
   voices never blur into one. */
.display, .h1, .h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-variation-settings: "SOFT" 20, "WONK" 1;
}
.display {
  font-size: clamp(2.75rem, 10.5vw, 7rem);
  line-height: 0.92;
  letter-spacing: -0.022em;
  font-variation-settings: "opsz" 144, "SOFT" 40, "WONK" 1;
}
.h1 {
  font-size: clamp(1.95rem, 5.2vw, 3.1rem);
  line-height: 1.06;
  letter-spacing: -0.014em;
  font-variation-settings: "opsz" 96, "SOFT" 30, "WONK" 1;
}
.h2 {
  font-size: clamp(1.55rem, 3.4vw, 2.25rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  font-variation-settings: "opsz" 60, "SOFT" 24, "WONK" 1;
}
.h3 { font-size: clamp(1.15rem, 2vw, 1.4rem); letter-spacing: -0.015em; }

/* Product name on a detail page is a headline moment. */
.pdp .h1 { letter-spacing: -0.018em; }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

.lede {
  font-size: clamp(1.1rem, 2.1vw, 1.4rem);
  line-height: 1.5;
  letter-spacing: -0.017em;
}
.prose { max-width: var(--measure); }
.muted { color: var(--ink-60); }

.mono {
  font-family: var(--mono);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-60);
  margin: 0 0 1.75rem;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}
.eyebrow::before {
  content: "";
  width: 1.5rem;
  height: 2px;
  background: var(--sage);
  flex: none;
  transform: translateY(-0.28em);
}

/* Lab annotation: a short sage rule under any heading an eyebrow introduces. */
.eyebrow + .h1::after,
.eyebrow + .h2::after {
  content: "";
  display: block;
  width: 2.25rem;
  height: 2px;
  background: var(--sage);
  margin-top: 1.1rem;
}

/* --- Layout -------------------------------------------------------------- */

.wrap { width: 100%; max-width: 82rem; margin-inline: auto; padding-inline: var(--gutter); }
.wrap--narrow { max-width: 58rem; }

.section { padding-block: var(--section); }
.section--tight { padding-block: calc(var(--section) * 0.6); }

/* Ruled divider: a sage dash repeating against clinical grey, read at 1px. */
.rule {
  border: 0; margin: 0; height: 1px;
  background-image: repeating-linear-gradient(90deg,
    var(--sage) 0 0.375rem, var(--grey) 0.375rem 1.125rem);
}

/* Full-width sage band. Wraps a section without touching its own box. */
.band { background: var(--sage-wash); }

/* Lab graph paper. Fine enough to read as texture, not pattern. */
.gridpaper {
  background-image: radial-gradient(var(--sage-line) 1px, transparent 1.5px);
  background-size: 1.75rem 1.75rem;
  background-position: center top;
}
.band.gridpaper { background-image: radial-gradient(var(--sage-line) 1px, transparent 1.5px); background-color: var(--sage-wash); }

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--paper);
  padding: 0.75rem 1.25rem; z-index: 100;
}
.skip:focus { left: 0; }

/* --- Header -------------------------------------------------------------- */

.header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 250, 248, 0.88);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--grey);
}
.header__inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; height: 4.25rem;
}
.wordmark {
  font-size: 1.0625rem;
  font-weight: 500;
  letter-spacing: 0.34em;
  text-decoration: none;
  padding-right: 0.34em; /* balance the tracking */
}
.wordmark span { color: var(--sage-deep); }

.nav { display: none; gap: 0.35rem; align-items: center; }
@media (min-width: 56em) { .nav { display: flex; } }
.nav a {
  font-size: 0.875rem;
  text-decoration: none;
  color: var(--ink-60);
  position: relative;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  transition: color var(--fast), background var(--fast);
}
.nav a::after {
  content: ""; position: absolute; left: 0.85rem; right: 0.85rem; bottom: 0.3rem;
  height: 1.5px; background: var(--sage);
  transform: scaleX(0); transform-origin: left;
  transition: transform var(--fast);
}
.nav a:hover { color: var(--sage-deep); background: var(--sage-wash); }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { color: var(--sage-deep); background: var(--sage-tint); }

.menu-btn {
  display: inline-flex; align-items: center; gap: 0.55rem;
  background: none; border: 0; cursor: pointer; padding: 0.5rem 0;
  font-family: var(--mono); font-size: 0.6875rem;
  letter-spacing: 0.16em; text-transform: uppercase;
}
@media (min-width: 56em) { .menu-btn { display: none; } }
.menu-btn__bars { width: 18px; display: grid; gap: 4px; }
.menu-btn__bars i { display: block; height: 1px; background: var(--ink); transition: transform var(--fast); }
.menu-btn[aria-expanded="true"] .menu-btn__bars i:first-child { transform: translateY(2.5px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .menu-btn__bars i:last-child { transform: translateY(-2.5px) rotate(-45deg); }

.drawer { display: none; border-top: 1px solid var(--grey); background: var(--paper); }
.drawer[data-open="true"] { display: block; }
@media (min-width: 56em) { .drawer { display: none !important; } }
.drawer a {
  display: block; padding: 1rem 0; text-decoration: none;
  border-bottom: 1px solid var(--grey-soft); font-size: 1.0625rem;
}
.drawer a:last-child { border-bottom: 0; }

/* --- Buttons ------------------------------------------------------------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem;
  padding: 0.9rem 1.6rem;
  border: 1px solid var(--sage);
  background: var(--sage); color: var(--ink);
  font-size: 0.875rem; letter-spacing: 0.01em;
  text-decoration: none; cursor: pointer;
  transition: background var(--fast), color var(--fast), border-color var(--fast);
}
.btn:hover { background: var(--sage-deep); border-color: var(--sage-deep); color: var(--paper); }
.btn--ghost { background: transparent; color: var(--sage-deep); border-color: var(--sage); }
.btn--ghost:hover { background: var(--sage-wash); border-color: var(--sage-deep); color: var(--sage-deep); }
.btn--block { width: 100%; }
.btn[disabled] { opacity: 0.4; cursor: not-allowed; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.875rem; text-decoration: none;
  border-bottom: 1px solid var(--grey); padding-bottom: 0.3rem;
  transition: border-color var(--fast);
}
.link-arrow:hover { border-color: var(--ink); }
.link-arrow::after { content: "→"; transition: transform var(--fast); }
.link-arrow:hover::after { transform: translateX(3px); }

/* --- Hero ---------------------------------------------------------------- */

.hero {
  /* Full-height, but capped; past ~44rem the strip at the foot just drifts
     away from the text and leaves dead air in the middle. */
  min-height: min(calc(100svh - 4.25rem), 44rem);
  display: flex; flex-direction: column; justify-content: space-between;
  padding-block: clamp(3rem, 9vh, 6rem) 2rem;
}
.hero__top { display: grid; gap: 2.5rem; }
@media (min-width: 64em) {
  .hero__top { grid-template-columns: 1.35fr 1fr; align-items: end; gap: 4rem; }
}
.hero__title { margin-bottom: 0; }
.hero__title em { font-style: normal; color: var(--sage-deep); }
.hero__statement { max-width: 30rem; }

.hero__meta {
  margin-top: clamp(2.25rem, 6vh, 3.5rem);
  margin-bottom: 0;
  border-top: 1px solid var(--grey);
  padding-top: 1.25rem;
  display: grid; gap: 1.25rem;
}
@media (min-width: 48em) { .hero__meta { grid-template-columns: repeat(4, 1fr); gap: 2rem; } }
.hero__meta div { display: grid; gap: 0.3rem; }
.hero__meta dt, .hero__meta .k {
  font-family: var(--mono); font-size: 0.6875rem;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-40);
}
.hero__meta .v { font-size: 0.9375rem; }

/* --- Generic split ------------------------------------------------------- */

.split { display: grid; gap: 2rem; }
@media (min-width: 56em) {
  .split { grid-template-columns: 1fr 1.4fr; gap: 3rem; }
  .split--even { grid-template-columns: 1fr 1fr; }
  .split--wide-left { grid-template-columns: 1.4fr 1fr; }
}
.sticky-head { position: sticky; top: 6rem; align-self: start; }
@media (max-width: 55.99em) { .sticky-head { position: static; } }

/* Between tablet and desktop the shop's side rail squeezes the product column
   below three cards. Stack the category heading there so rows stay full. */
@media (max-width: 76em) {
  #results .split { grid-template-columns: 1fr; gap: 1.5rem; }
  #results .sticky-head { position: static; }
}

/* --- Promise list -------------------------------------------------------- */

.promises { list-style: none; margin: 0; padding: 0; display: grid; }
.promises li { border-top: 1px solid var(--grey); padding: 1.35rem 0; display: grid; gap: 0.4rem; }
.promises li:last-child { border-bottom: 1px solid var(--grey); }
@media (min-width: 40em) {
  .promises li { grid-template-columns: 3.5rem 1fr; gap: 0 2rem; align-items: baseline; }
  .promises li p { grid-column: 2; }
}
.promises .n { font-family: var(--mono); font-size: 0.75rem; color: var(--sage-deep); letter-spacing: 0.08em; }
.promises h3 { margin-bottom: 0.15rem; }

/* --- Product grid -------------------------------------------------------- */

.grid { display: grid; gap: 1px; }
@media (min-width: 34em) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 62em) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 82em) { .grid--4 { grid-template-columns: repeat(4, 1fr); } }
/* Declared last so they win over the wider defaults above. */
@media (min-width: 34em) { .grid--2 { grid-template-columns: repeat(2, 1fr); } }
/* auto-fit, not auto-fill: empty tracks collapse, so a two-product category
   spreads across the row instead of stranding a card-sized hole in it. */
@media (min-width: 34em) { .grid--auto { grid-template-columns: repeat(auto-fit, minmax(13.5rem, 1fr)); } }

/* Sage pill: category marks, badges, any small piece of classification. */
.tag {
  display: inline-flex; align-items: center; gap: 0.35rem;
  font-family: var(--mono); font-size: 0.625rem;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--sage-deep); background: var(--sage-tint);
  padding: 0.3rem 0.6rem; border-radius: 999px;
  white-space: nowrap;
}
.tag--solid { background: var(--sage); color: var(--ink); }
.tag--quiet { background: transparent; box-shadow: inset 0 0 0 1px var(--sage); }

.card {
  position: relative;
  background: var(--paper);
  box-shadow: 0 0 0 1px var(--grey);
  padding: 1.1rem 1.15rem 1.25rem;
  display: flex; flex-direction: column; gap: 0.7rem;
  text-decoration: none;
  transition: background var(--fast), box-shadow var(--base), transform var(--base);
}
.card:hover {
  background: var(--white);
  box-shadow: 0 0 0 1px var(--sage-deep), 0 12px 24px -14px rgba(28, 28, 26, 0.28);
  transform: translateY(-2px);
  z-index: 1;
}
/* Photos come from many different brands, so the frame does the standardising:
   a white ground, a fixed 4:5 crop, and contained + padded artwork so every
   bottle sits at roughly the same visual scale. */
.card__figure {
  position: relative;
  background: var(--white);
  aspect-ratio: 4 / 5;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--grey-soft);
}
.card__tags {
  position: absolute; inset: 0.6rem 0.6rem auto; z-index: 2;
  display: flex; justify-content: space-between; align-items: flex-start; gap: 0.5rem;
}
.card__media { display: block; width: 100%; height: 100%; }
.card__figure img {
  width: 100%; height: 100%; object-fit: contain;
  padding: 9%;
  transition: transform var(--base);
}
.card:hover .card__figure img { transform: scale(1.03); }
.card__brand {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--sage-deep); margin: 0;
}
.card__name { font-size: 1.0625rem; letter-spacing: -0.018em; line-height: 1.25; margin: 0; }
.card__name a { text-decoration: none; }
.card__name a::after { content: ""; position: absolute; inset: 0; }
.card__fn { font-size: 0.875rem; color: var(--ink-60); margin: 0; }
.card__price { font-family: var(--mono); font-size: 0.9375rem; }
.card__buy {
  margin-top: auto; padding-top: 0.85rem; border-top: 1px solid var(--grey);
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  position: relative; z-index: 2;
}


/* --- Label-reading strip ------------------------------------------------- */

.demo {
  background: var(--sage-wash);
  border: 1px solid var(--sage);
  padding: 1.75rem;
}
@media (min-width: 40em) { .demo { padding: 2.5rem; } }
.demo__hint {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--ink-40); margin: 0 0 1.25rem;
}

/* Ingredient rows, shared by the home demo and the product page */
.ing { list-style: none; margin: 0; padding: 0; }
.ing > li { border-top: 1px solid var(--grey); }
.ing > li:last-child { border-bottom: 1px solid var(--grey); }

.ing__row {
  width: 100%; background: none; border: 0; text-align: left; cursor: pointer;
  display: grid; grid-template-columns: 1fr auto auto; align-items: center;
  gap: 0.75rem 1rem; padding: 1rem 0;
  transition: color var(--fast);
}
.ing__row:hover { color: var(--sage-deep); }
.ing__name { font-size: 0.9375rem; letter-spacing: -0.01em; }
.ing__inci { display: block; font-family: var(--mono); font-size: 0.6875rem; color: var(--ink-40); letter-spacing: 0.04em; margin-top: 0.15rem; }
/* The number is the point of the page, so it wears a chip. */
.ing__pct {
  font-family: var(--mono); font-size: 0.75rem; font-variant-numeric: tabular-nums;
  background: var(--sage-tint); color: var(--sage-deep);
  padding: 0.3rem 0.65rem; border-radius: 999px; letter-spacing: 0.02em;
  transition: background var(--fast), color var(--fast);
}
.ing__row:hover .ing__pct { background: var(--sage); color: var(--ink); }
.ing__toggle {
  width: 1rem; height: 1rem; position: relative; flex: none; color: var(--ink-40);
}
.ing__toggle::before, .ing__toggle::after {
  content: ""; position: absolute; inset: 50% 0 auto 0; height: 1px; background: currentColor;
}
.ing__toggle::after { transform: rotate(90deg); transition: transform var(--base), opacity var(--fast); }
.ing__row[aria-expanded="true"] .ing__toggle::after { transform: rotate(0deg); opacity: 0; }

.ing__panel {
  display: grid; grid-template-rows: 0fr;
  transition: grid-template-rows var(--base);
}
.ing__panel[data-open="true"] { grid-template-rows: 1fr; }
.ing__panel > div { overflow: hidden; }
.ing__panel[data-open="true"] > div {
  background: var(--sage-tint);
  border-left: 2px solid var(--sage);
}
.ing__panel p {
  max-width: 40rem; font-size: 0.9375rem; color: var(--ink-60);
  margin: 0; padding: 0 1.25rem 1.25rem;
}

/* Meter: a substantial sage bar with its figure sitting alongside it. */
.ing__meter {
  display: flex; align-items: center; gap: 0.85rem;
  padding: 1.25rem 1.25rem 1rem;
}
/* Fills use sage-deep: the bar carries information, so it has to clear 3:1
   against its own track. Full sage tops out at 2.9:1 on any light ground. */
.ing__meter .ing__track {
  flex: 1; height: 10px; background: var(--grey-soft);
  box-shadow: inset 0 0 0 1px var(--grey);
}
.ing__meter i {
  display: block; height: 100%; background: var(--sage-deep);
  width: 0; transition: width var(--base);
}
.ing__panel[data-open="true"] .ing__meter i { width: var(--w, 0%); }
.ing__meter .ing__value {
  font-family: var(--mono); font-size: 0.75rem; font-variant-numeric: tabular-nums;
  background: var(--sage); color: var(--ink);
  padding: 0.25rem 0.6rem; border-radius: 999px; flex: none;
}

.ing__pct--unknown {
  color: var(--ink-40); letter-spacing: 0.04em;
  background: transparent; box-shadow: inset 0 0 0 1px var(--grey);
}
.ing__row:hover .ing__pct--unknown { background: transparent; color: var(--ink-60); }

/* Shown in place of the meter when a brand publishes no figure. */
.ing__flag {
  font-family: var(--mono); font-size: 0.6875rem; line-height: 1.6;
  color: var(--ink-40); letter-spacing: 0.02em;
  padding: 1.25rem 1.25rem 0;
  margin: 0; max-width: 36rem;
}

/* Retailer's own checks: data about the listing, not the formula. */
.checks { list-style: none; margin: 0; padding: 0; }
.checks li {
  display: flex; justify-content: space-between; gap: 1.5rem;
  border-top: 1px solid var(--grey-soft); padding: 0.7rem 0;
  font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.01em;
}
.checks li span:first-child { color: var(--ink-40); }
.checks li span:last-child { text-align: right; }

/* --- Filters ------------------------------------------------------------- */

.filters { display: grid; gap: 1.25rem; }
.filter-group { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.filter-group__label {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-40); width: 100%;
  margin-bottom: 0.25rem;
}
@media (min-width: 48em) { .filter-group__label { width: 6.5rem; margin-bottom: 0; } }

.chip {
  display: inline-flex; align-items: center; gap: 0.45rem;
  border: 1px solid var(--grey); background: transparent; cursor: pointer;
  padding: 0.5rem 0.95rem; font-size: 0.8125rem; border-radius: 999px;
  transition: border-color var(--fast), background var(--fast), color var(--fast);
}
.chip:hover { border-color: var(--sage); background: var(--sage-wash); }
.chip[aria-pressed="true"] { background: var(--sage); border-color: var(--sage); color: var(--ink); }

/* Concern marks: line icons, sage stroke, inheriting on active surfaces. */
.icon { width: 15px; height: 15px; flex: none; color: var(--sage-deep); }
.chip[aria-pressed="true"] .icon,
.option[aria-pressed="true"] .icon { color: var(--ink); }
.option__t .icon { width: 17px; height: 17px; }

.result-count { font-family: var(--mono); font-size: 0.75rem; color: var(--ink-40); letter-spacing: 0.06em; }

.empty { padding: 4rem 0; text-align: center; }

/* --- Product detail ------------------------------------------------------ */

.pdp { display: grid; gap: 2rem; }
@media (min-width: 60em) { .pdp { grid-template-columns: 1fr 1fr; gap: 3.25rem; align-items: start; } }
.pdp__media { background: var(--white); border: 1px solid var(--grey); aspect-ratio: 4 / 5; }
.pdp__media img { width: 100%; height: 100%; object-fit: contain; padding: 7%; }
@media (min-width: 60em) { .pdp__media { position: sticky; top: 6rem; } }
.pdp__brand {
  font-family: var(--mono); font-size: 0.8125rem; letter-spacing: 0.16em;
  text-transform: uppercase; margin: 0 0 0.6rem;
}
.pdp__brand a { color: var(--sage-deep); text-underline-offset: 0.3em; }
.pdp__price { font-family: var(--mono); font-size: 1rem; }
.pdp__buy { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; margin-top: 1.5rem; }
.pdp__note { font-family: var(--mono); font-size: 0.6875rem; color: var(--ink-40); letter-spacing: 0.06em; }

.spec { display: grid; gap: 0; margin: 2rem 0 0; }
.spec div { display: flex; justify-content: space-between; gap: 1.5rem; padding: 0.7rem 0; border-top: 1px solid var(--grey-soft); }
.spec dt { font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-40); }
.spec dd { margin: 0; font-size: 0.875rem; text-align: right; }

.chart { display: grid; gap: 1.1rem; }
.chart__row { display: grid; gap: 0.4rem; }
.chart__head { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; }
.chart__label { font-size: 0.875rem; }
.chart__val {
  font-family: var(--mono); font-size: 0.75rem; font-variant-numeric: tabular-nums;
  background: var(--sage-tint); color: var(--sage-deep);
  padding: 0.25rem 0.6rem; border-radius: 999px;
}
.chart__track { height: 12px; background: var(--grey-soft); box-shadow: inset 0 0 0 1px var(--grey); }
.chart__fill { height: 100%; background: var(--sage-deep); width: 0; transition: width 500ms cubic-bezier(.4, 0, .2, 1); }
.chart__none {
  font-size: 0.875rem; color: var(--ink-60); max-width: 36rem;
  border-left: 3px solid var(--sage); background: var(--sage-tint);
  padding: 1rem 1.25rem; margin: 0;
}
.chart__scale {
  display: flex; justify-content: space-between;
  font-family: var(--mono); font-size: 0.625rem; color: var(--ink-40);
  letter-spacing: 0.1em; border-top: 1px solid var(--grey); padding-top: 0.5rem;
}

/* --- Quiz ---------------------------------------------------------------- */

.quiz { max-width: none; }
.quiz__step, .quiz__progress { max-width: 46rem; }
#quiz-result { max-width: 66rem; }
.quiz__progress { display: flex; gap: 0.4rem; margin-bottom: 3rem; }
.quiz__progress i { flex: 1; height: 3px; background: var(--grey); transition: background var(--fast); }
.quiz__progress i[data-done="true"] { background: var(--sage-deep); }

.quiz__step { display: none; }
.quiz__step[data-active="true"] { display: block; animation: rise var(--base) both; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.options { display: grid; gap: 1px; margin: 2.25rem 0 0; }
@media (min-width: 44em) { .options { grid-template-columns: repeat(2, 1fr); } }
.option {
  position: relative;
  background: var(--paper); border: 0; box-shadow: 0 0 0 1px var(--grey); cursor: pointer; text-align: left;
  padding: 1.35rem 1.5rem; display: grid; gap: 0.3rem;
  transition: background var(--fast), box-shadow var(--fast);
}
.option:hover { background: var(--sage-tint); box-shadow: 0 0 0 1px var(--sage-deep); z-index: 1; }
.option__t { font-size: 1.0625rem; letter-spacing: -0.015em; display: flex; align-items: center; gap: 0.6rem; }
.option__d { font-size: 0.8125rem; color: var(--ink-60); }
.option[aria-pressed="true"] { background: var(--sage); color: var(--ink); }
.option[aria-pressed="true"] .option__d { color: rgba(28, 28, 26, 0.92); }

.quiz__nav { display: flex; gap: 1rem; align-items: center; margin-top: 2rem; }
.quiz__back { background: none; border: 0; cursor: pointer; font-size: 0.875rem; color: var(--ink-60); padding: 0.5rem 0; }
.quiz__back:hover { color: var(--ink); }

.readout {
  font-family: var(--mono); font-size: 0.75rem; color: var(--ink-60);
  border: 1px solid var(--sage); border-left-width: 3px; padding: 1.25rem; background: var(--sage-tint);
  display: grid; gap: 0.45rem; margin-bottom: 2.5rem;
}
.readout div { display: flex; justify-content: space-between; gap: 1rem; }
.readout .k { color: var(--ink-40); letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.625rem; }

/* --- Label comparison (philosophy) --------------------------------------- */

.labels { display: grid; gap: 1.5rem; }
@media (min-width: 52em) { .labels { grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--grey); border: 1px solid var(--grey); } }
/* Stacked variant, declared after the two-up rule so it wins: used where the
   comparison sits in a column beside the text rather than across the page. */
.labels--stack { grid-template-columns: 1fr; gap: 1px; background: var(--grey); border: 1px solid var(--grey); }
.labels--stack .label-card { border: 0; }
.label-card { background: var(--paper); padding: 1.75rem; display: grid; gap: 1.25rem; align-content: start; }
@media (max-width: 51.99em) { .label-card { border: 1px solid var(--grey); } }
.label-card__tag {
  font-family: var(--mono); font-size: 0.625rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-40);
  display: flex; justify-content: space-between; gap: 1rem;
}
.label-card--them .label-card__tag strong { color: var(--ink-60); font-weight: 500; }
.label-card--us .label-card__tag strong { color: var(--sage-deep); font-weight: 500; }
.label-card h3 { font-size: 1.0625rem; }
.label-lines { list-style: none; margin: 0; padding: 0; display: grid; }
.label-lines li {
  font-family: var(--mono); font-size: 0.75rem; line-height: 1.5;
  padding: 0.6rem 0; border-top: 1px solid var(--grey-soft);
  display: flex; justify-content: space-between; gap: 1rem;
}
.label-lines li span:last-child { color: var(--ink-40); flex: none; }
.label-card--us .label-lines li span:last-child { color: var(--sage-deep); }
.label-card__foot { font-size: 0.8125rem; color: var(--ink-60); border-top: 1px solid var(--grey); padding-top: 1rem; }

/* --- Forms --------------------------------------------------------------- */

.form { display: grid; gap: 1.75rem; max-width: 36rem; }
.field { display: grid; gap: 0.5rem; }
.field label {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-60);
}
.field input, .field textarea, .field select {
  background: transparent; border: 0; border-bottom: 1px solid var(--grey);
  padding: 0.7rem 0; font-size: 1rem; border-radius: 0;
  transition: border-color var(--fast);
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-bottom-color: var(--sage-deep);
}
.field textarea { resize: vertical; min-height: 7rem; }
.field__error { font-family: var(--mono); font-size: 0.6875rem; color: #8C3B2E; min-height: 1em; }
.field[data-invalid="true"] input, .field[data-invalid="true"] textarea { border-bottom-color: #8C3B2E; }

.form__status {
  font-family: var(--mono); font-size: 0.75rem; color: var(--sage-deep);
  border-left: 2px solid var(--sage); padding-left: 0.9rem;
}

.aside-box { border: 1px solid var(--grey); padding: 1.75rem; display: grid; gap: 0.75rem; align-content: start; }

/* --- Footer -------------------------------------------------------------- */

.footer {
  background: var(--forest); color: var(--paper);
  border-top: 3px solid var(--sage);
  padding-block: 3.5rem 2.5rem;
}
.footer .muted { color: rgba(250, 250, 248, 0.72); }
.footer__top { display: grid; gap: 2.5rem; }
@media (min-width: 52em) { .footer__top { grid-template-columns: 1.4fr 0.8fr 0.8fr 1.2fr; gap: 2.5rem; } }
@media (min-width: 52em) and (max-width: 74em) { .footer__top { grid-template-columns: repeat(2, 1fr); gap: 2.5rem 3rem; } }
.footer h4 {
  font-family: var(--mono); font-size: 0.6875rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: rgba(250, 250, 248, 0.6); font-weight: 400; margin-bottom: 1rem;
}
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.footer__note { font-size: 0.875rem; color: rgba(250, 250, 248, 0.72); margin: 0 0 0.6rem; max-width: 22rem; }
.footer__mono { font-family: var(--mono); font-size: 0.75rem; color: var(--sage); letter-spacing: 0.04em; margin: 0; }
.footer ul a { font-size: 0.9375rem; text-decoration: none; color: rgba(250, 250, 248, 0.72); transition: color var(--fast); }
.footer ul a:hover { color: var(--paper); }
.footer__bottom {
  margin-top: 2.75rem; padding-top: 1.5rem; border-top: 1px solid var(--forest-line);
  display: flex; flex-wrap: wrap; gap: 0.75rem 2rem; justify-content: space-between;
  font-family: var(--mono); font-size: 0.6875rem; color: rgba(250, 250, 248, 0.6); letter-spacing: 0.06em;
}
.footer__bottom span:last-child { color: var(--sage); }

/* --- Reveal -------------------------------------------------------------- */

[data-reveal] { opacity: 0; transform: translateY(10px); }
[data-reveal].is-in { opacity: 1; transform: none; transition: opacity var(--base), transform var(--base); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
}

/* --- Shop catalogue ------------------------------------------------------ */

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

.toolbar {
  display: grid; gap: 0.75rem;
  grid-template-columns: 1fr auto;
  align-items: center;
  margin-bottom: 1rem;
}
/* Narrow: search takes its own row, sort and the filter button share the next.
   Sorting stays reachable on mobile; only the facets collapse. */
.toolbar .search { grid-column: 1 / -1; }
@media (min-width: 48em) {
  .toolbar { grid-template-columns: 1fr auto auto; gap: 1rem; }
  .toolbar .search { grid-column: auto; }
}

.search { position: relative; display: flex; align-items: center; }
.search__icon {
  position: absolute; left: 0.9rem; width: 16px; height: 16px;
  color: var(--ink-40); pointer-events: none;
}
.search input {
  width: 100%; background: var(--paper);
  border: 1px solid var(--grey); border-radius: 999px;
  padding: 0.7rem 1rem 0.7rem 2.6rem;
  font-size: 0.9375rem;
  transition: border-color var(--fast), box-shadow var(--fast);
}
.search input::placeholder { color: var(--ink-40); }
.search input:focus {
  outline: none; border-color: var(--sage-deep);
  box-shadow: 0 0 0 1px var(--sage-deep);
}
.search input::-webkit-search-cancel-button { cursor: pointer; }

.toolbar__sort { display: flex; align-items: center; gap: 0.6rem; }
.toolbar__sort label {
  font-family: var(--mono); font-size: 0.6875rem;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-40);
}
.toolbar__sort select {
  background: var(--paper); border: 1px solid var(--grey); border-radius: 999px;
  padding: 0.65rem 0.9rem; font-size: 0.875rem; cursor: pointer;
  transition: border-color var(--fast);
}
.toolbar__sort select:hover { border-color: var(--sage); }

.facets-toggle { padding: 0.65rem 1.1rem; }
.facets-toggle[data-count]:not([data-count=""])::after {
  content: attr(data-count);
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 1.15rem; height: 1.15rem; margin-left: 0.15rem;
  background: var(--sage); color: var(--ink);
  border-radius: 999px; font-family: var(--mono); font-size: 0.625rem;
}
@media (min-width: 64em) { .facets-toggle { display: none; } }

.catalog { display: grid; gap: 1.5rem; margin-top: 1.5rem; }
@media (min-width: 64em) { .catalog { grid-template-columns: 14rem 1fr; gap: 3rem; } }

.facets { display: none; }
.facets[data-open="true"] { display: grid; }
@media (min-width: 64em) {
  .facets { display: grid !important; align-content: start; gap: 1.75rem; position: sticky; top: 6rem; }
}
@media (max-width: 63.99em) {
  .facets[data-open="true"] {
    gap: 1.5rem; padding: 1.5rem;
    background: var(--paper); border: 1px solid var(--grey);
  }
}

.facet { display: grid; gap: 0.75rem; }
.facet__title {
  font-family: var(--mono); font-size: 0.6875rem; font-weight: 400;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-40);
  margin: 0;
}
.facet__chips { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.facet .chip { padding: 0.4rem 0.8rem; font-size: 0.8125rem; }
.facet__clear {
  justify-self: start; background: none; border: 0; cursor: pointer;
  font-size: 0.8125rem; color: var(--sage-deep); padding: 0;
  border-bottom: 1px solid var(--sage); line-height: 1.4;
}
.facet__clear:hover { border-color: var(--sage-deep); }

#shop-count { display: block; }

/* --- Storefront ---------------------------------------------------------- */

.btn--lg { padding: 1.05rem 2rem; font-size: 0.9375rem; }
.btn--sm { padding: 0.5rem 0.9rem; font-size: 0.8125rem; }
.btn.is-added { background: var(--sage-deep); border-color: var(--sage-deep); color: var(--paper); }

.hero__cta {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 1rem 1.75rem; margin-top: 2rem;
}

/* Trust markers: four claims, equal weight, transparency among them. */
.trust-strip {
  list-style: none; margin: clamp(2.25rem, 6vh, 3.5rem) 0 0; padding: 1.25rem 0 0;
  border-top: 1px solid var(--grey);
  display: grid; gap: 1.1rem;
}
@media (min-width: 40em) { .trust-strip { grid-template-columns: repeat(2, 1fr); gap: 1.25rem 2rem; } }
@media (min-width: 64em) { .trust-strip { grid-template-columns: repeat(4, 1fr); } }
.trust-strip li { display: flex; align-items: flex-start; gap: 0.7rem; }
.trust-strip .icon { width: 20px; height: 20px; margin-top: 0.1rem; }
.trust-strip span { display: grid; gap: 0.15rem; font-size: 0.8125rem; color: var(--ink-60); line-height: 1.45; }
.trust-strip strong { font-weight: 500; font-size: 0.9375rem; color: var(--ink); }

/* Section head with an action on the right. */
.row-head { display: grid; gap: 1rem; }
@media (min-width: 48em) {
  .row-head { grid-template-columns: 1fr auto; align-items: end; gap: 2rem; }
}

/* Quiz, given the room it deserves. */
.quiz-banner { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 56em) { .quiz-banner { grid-template-columns: 1.35fr 1fr; gap: 3.5rem; } }
.quiz-banner__aside {
  background: var(--paper); border: 1px solid var(--sage);
  padding: 1.75rem;
}

.quiz-prompt {
  display: grid; gap: 1.5rem; align-items: center;
  background: var(--sage-tint); border-left: 3px solid var(--sage-deep);
  padding: 1.75rem;
}
@media (min-width: 52em) { .quiz-prompt { grid-template-columns: 1fr auto; gap: 2.5rem; padding: 2rem 2.25rem; } }
.quiz-prompt__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.5rem; }

/* Shop by brand. */
.brand-row {
  margin-top: 2rem;
  display: grid; gap: 1px;
  grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
}
.brand-card {
  background: var(--paper); box-shadow: 0 0 0 1px var(--grey);
  padding: 1rem 1.1rem; text-decoration: none;
  display: grid; gap: 0.3rem; align-content: center; min-height: 5rem;
  transition: background var(--fast), box-shadow var(--fast);
}
.brand-card:hover { background: var(--white); box-shadow: 0 0 0 1px var(--sage-deep); z-index: 1; }
.brand-card__name { font-size: 0.9375rem; letter-spacing: -0.012em; line-height: 1.25; }
.brand-card__meta {
  font-family: var(--mono); font-size: 0.625rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--ink-40);
}

/* --- Cart ---------------------------------------------------------------- */

.cart-link {
  display: inline-flex; align-items: center; gap: 0.45rem;
  text-decoration: none; font-size: 0.875rem; color: var(--ink-60);
  padding: 0.45rem 0.85rem; border-radius: 999px;
  transition: color var(--fast), background var(--fast);
}
.cart-link:hover { color: var(--sage-deep); background: var(--sage-wash); }
.cart-link .icon { width: 17px; height: 17px; color: currentColor; }
.cart-count[hidden] { display: none; }
.cart-count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 1.25rem; height: 1.25rem; padding: 0 0.35rem;
  background: var(--sage); color: var(--ink);
  border-radius: 999px; font-family: var(--mono); font-size: 0.625rem;
}

/* --- Full ingredient breakdown (secondary, expandable) ------------------- */

.breakdown { border: 1px solid var(--sage); background: var(--paper); }
.breakdown__summary {
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
  padding: 1.35rem 1.5rem; cursor: pointer; list-style: none;
  transition: background var(--fast);
}
.breakdown__summary::-webkit-details-marker { display: none; }
.breakdown__summary:hover { background: var(--sage-wash); }
.breakdown__label { display: grid; gap: 0.35rem; }
.breakdown__hint {
  font-family: var(--mono); font-size: 0.75rem; color: var(--ink-60); letter-spacing: 0.02em;
}
.breakdown__chevron { width: 1rem; height: 1rem; position: relative; flex: none; color: var(--sage-deep); }
.breakdown__chevron::before, .breakdown__chevron::after {
  content: ""; position: absolute; inset: 50% 0 auto 0; height: 2px; background: currentColor;
}
.breakdown__chevron::after { transform: rotate(90deg); transition: transform var(--base), opacity var(--fast); }
.breakdown[open] .breakdown__chevron::after { transform: rotate(0deg); opacity: 0; }
.breakdown__body { padding: 0.5rem 1.5rem 2rem; border-top: 1px solid var(--grey); }
@media (min-width: 48em) {
  .breakdown__summary { padding: 1.5rem 2rem; }
  .breakdown__body { padding: 1.5rem 2rem 2.5rem; }
}
.breakdown[open] .breakdown__body { animation: rise var(--base) both; }

/* --- Cart panel ---------------------------------------------------------- */

.header__end { display: flex; align-items: center; gap: 0.4rem; }
.cart-link { background: none; border: 0; cursor: pointer; font-family: inherit; }

.cart-panel { display: none; border-top: 1px solid var(--grey); background: var(--paper); }
.cart-panel[data-open="true"] { display: block; }
.cart-panel__inner { padding-block: 1.5rem; max-width: 30rem; margin-left: auto; }
.cart-panel__empty { font-size: 0.9375rem; }
.cart-panel__list { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; gap: 0.75rem; }
.cart-panel__list li {
  display: grid; grid-template-columns: auto 1fr auto; gap: 0.75rem;
  align-items: baseline; font-size: 0.9375rem;
}
.cart-panel__q { font-family: var(--mono); font-size: 0.75rem; color: var(--sage-deep); }
.cart-panel__brand {
  display: block; font-family: var(--mono); font-size: 0.625rem;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-40); margin-top: 0.15rem;
}
.cart-panel__line { font-family: var(--mono); font-size: 0.8125rem; }
.cart-panel__total {
  display: flex; justify-content: space-between; gap: 1rem;
  border-top: 1px solid var(--grey); padding-top: 0.85rem; margin: 0;
  font-family: var(--mono); font-size: 0.875rem;
}
.cart-panel__note { font-size: 0.6875rem; margin: 0.6rem 0 0; }

/* --- Footer brand list --------------------------------------------------- */

.footer__brandlist {
  font-size: 0.8125rem; line-height: 1.9; color: rgba(250, 250, 248, 0.72);
  margin: 0; max-width: 24rem;
}
.footer__brandlist a { text-decoration: none; transition: color var(--fast); }
.footer__brandlist a:hover { color: var(--paper); text-decoration: underline; }
.footer__brandlist span { color: var(--sage); }
