/* ==========================================================
   TOS — TasteOverTime
   Global stylesheet
   ========================================================== */

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap");

/* ---------- Tokens ---------- */
:root {
  --bg: #FFFFFF;
  --surface: #F6F8FC;
  --surface-2: #EEF2F9;
  --border: #E2E7F0;
  --text: #111827;
  --muted: #5F6878;
  --faint: #A3ABBA;
  --accent: #175EF8;
  --accent-soft: rgba(23, 94, 248, 0.08);
  --radius: 18px;
  --header-h: 68px;
}

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

html,
body {
  margin: 0;
  background: #FFFFFF;
  color: var(--text);
}

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { margin: 0; line-height: 1.15; letter-spacing: -0.02em; }
p { margin: 0; }

/* ---------- Wrapper ---------- */
.larder {
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}

/* ---------- Eyebrow ---------- */
.eyebrow {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2.8px;
  text-transform: uppercase;
  color: var(--accent);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 28px;
  border-radius: 999px;
  background: var(--accent);
  color: #FFFFFF;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(23, 94, 248, 0.28);
}
.btn svg { width: 17px; height: 17px; fill: currentColor; flex-shrink: 0; }
.btn-sm { padding: 9px 16px; font-size: 13px; gap: 7px; }
.btn-sm svg { width: 14px; height: 14px; }

/* ---------- Header ---------- */
.top {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--border);
}

.top-in {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}

.logo img { height: 52px; width: 52px; margin-left: -8px; }

.top-right { display: flex; align-items: center; gap: 10px; }

.nav {
  display: none;
  position: absolute;
  top: var(--header-h);
  left: -20px;
  right: -20px;
  background: var(--bg);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 8px 0 16px;
}
.nav.open { display: block; }

.nav-in { display: flex; flex-direction: column; }
.nav-in a {
  padding: 12px 20px;
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
}
.nav-in a:hover { color: var(--accent); text-decoration: none; }
.nav-in a.on { color: var(--accent); }

.burger {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  cursor: pointer;
}
.burger span { display: block; height: 2px; background: var(--text); border-radius: 2px; }

/* ==========================================================
   Homepage
   ========================================================== */

/* ---------- Hero (typographic opener) ---------- */
.opener {
  padding-top: 72px;
  padding-bottom: 64px;
  text-align: left;
}

.opener h1 {
  margin-top: 18px;
  max-width: 820px;
  font-size: clamp(2.3rem, 6.4vw, 4.4rem);
  font-weight: 800;
  letter-spacing: -0.035em;
}
.opener h1 em { font-style: normal; color: var(--accent); }

.opener .lead {
  margin-top: 22px;
  max-width: 560px;
  font-size: 18px;
  color: var(--muted);
}

.opener-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 22px;
  margin-top: 34px;
}
.opener-note { font-size: 13px; color: var(--muted); }

/* Ticker of tallies under the hero */
.tallies {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 52px;
}
.tally-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 8px 8px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-size: 14px;
  font-weight: 500;
}
.tally-chip b {
  min-width: 34px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}

/* ---------- Photo band ---------- */
.plate {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.plate-in {
  display: grid;
  gap: 36px;
  padding-top: 56px;
  padding-bottom: 56px;
  align-items: center;
}
.plate-img {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 24px 60px rgba(17, 24, 39, 0.10);
  aspect-ratio: 4 / 5;
}
.plate-img img { width: 100%; height: 100%; object-fit: cover; }

.plate-copy h2 {
  margin-top: 14px;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
}
.plate-copy p { margin-top: 16px; color: var(--muted); font-size: 17px; }

.cats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 26px;
}
.cats span {
  padding: 7px 14px;
  border-radius: 8px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: 13px;
  font-weight: 500;
}
.cats span.on {
  background: var(--accent-soft);
  border-color: rgba(23, 94, 248, 0.35);
  color: var(--accent);
}

/* ---------- Section heading ---------- */
.sec-head { max-width: 620px; }
.sec-head h2 {
  margin-top: 14px;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
}
.sec-head p { margin-top: 14px; color: var(--muted); font-size: 17px; }

/* ---------- Method (numbered features) ---------- */
.method { padding-top: 88px; padding-bottom: 40px; }

.steps {
  list-style: none;
  margin: 44px 0 0;
  padding: 0;
  border-top: 1px solid var(--border);
}
.steps li {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 4px 18px;
  padding: 28px 0;
  border-bottom: 1px solid var(--border);
}
.step-no {
  grid-row: span 2;
  font-size: 40px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--border);
}
.steps li:hover .step-no { color: var(--accent); }
.steps h3 { font-size: 20px; font-weight: 700; }
.steps p { color: var(--muted); }

/* ---------- Favourites mock (CSS bar chart) ---------- */
.favs { padding-top: 64px; padding-bottom: 88px; }
.favs-in {
  display: grid;
  gap: 40px;
  align-items: center;
}

.board {
  padding: 26px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  box-shadow: 0 20px 50px rgba(17, 24, 39, 0.07);
}
.board-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 18px;
}
.board-top strong { font-size: 16px; }
.board-top span { font-size: 12px; color: var(--muted); }

.dish { margin-top: 14px; }
.dish-row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 500;
}
.dish-row em { font-style: normal; color: var(--muted); font-weight: 600; }
.bar {
  height: 8px;
  margin-top: 7px;
  border-radius: 999px;
  background: var(--surface-2);
  overflow: hidden;
}
.bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
}
.dish:nth-child(n+4) .bar i { opacity: 0.55; }

/* ---------- Trust stats ---------- */
.pledge {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.pledge-in { padding-top: 64px; padding-bottom: 64px; }
.stats {
  display: grid;
  gap: 28px;
  margin-top: 36px;
}
.stat b {
  display: block;
  font-size: clamp(2.4rem, 6vw, 3.4rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--accent);
}
.stat span { display: block; margin-top: 10px; font-weight: 600; }
.stat p { margin-top: 4px; color: var(--muted); font-size: 15px; }

/* ---------- Closing CTA ---------- */
.serve {
  padding-top: 96px;
  padding-bottom: 96px;
  text-align: center;
}
.serve h2 {
  max-width: 640px;
  margin: 14px auto 0;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
}
.serve p { max-width: 480px; margin: 16px auto 0; color: var(--muted); }
.serve .btn { margin-top: 32px; }

/* ==========================================================
   Inner pages
   ========================================================== */
.inner-head { padding-top: 64px; padding-bottom: 36px; }
.inner-head h1 {
  margin-top: 14px;
  font-size: clamp(2.1rem, 5vw, 3.2rem);
  font-weight: 800;
}
.inner-head p { margin-top: 14px; max-width: 600px; color: var(--muted); font-size: 17px; }

.inner-body { padding-bottom: 88px; }

.cards { display: grid; gap: 16px; }
.cards + .cards { margin-top: 16px; }

.card {
  padding: 26px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.card h2,
.card h3 { font-size: 18px; font-weight: 700; }
.card p { margin-top: 10px; color: var(--muted); }
.card p + p { margin-top: 10px; }
.card .card-no {
  display: block;
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--accent);
}
.card.hl { background: var(--bg); border-color: rgba(23, 94, 248, 0.35); }
.card .big {
  display: block;
  margin-top: 12px;
  font-size: 20px;
  font-weight: 700;
  word-break: break-word;
}

.sub-label {
  margin: 40px 0 16px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2.8px;
  text-transform: uppercase;
  color: var(--muted);
}

.legal-meta { margin-top: 10px; font-size: 14px; color: var(--muted); }
.legal-note { margin-top: 28px; font-size: 14px; color: var(--muted); }

/* ---------- Footer ---------- */
.foot { border-top: 1px solid var(--border); }
.foot-in {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding-top: 36px;
  padding-bottom: 36px;
}
.foot-brand { display: flex; align-items: center; gap: 12px; }
.foot-brand img { width: 44px; height: 44px; margin-left: -6px; }
.foot-brand span { font-size: 14px; color: var(--muted); }
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.foot-links a { color: var(--text); font-size: 14px; font-weight: 500; }
.foot-links a:hover { color: var(--accent); text-decoration: none; }
.foot-copy { font-size: 13px; color: var(--faint); }

/* ==========================================================
   Desktop
   ========================================================== */
@media (min-width: 640px) {
  .stats { grid-template-columns: repeat(3, 1fr); }
  .cards.two { grid-template-columns: repeat(2, 1fr); }
  .steps li { grid-template-columns: 96px 1fr; }
  .step-no { font-size: 52px; }
}

@media (min-width: 760px) {
  .larder { padding-left: 32px; padding-right: 32px; }

  .burger { display: none; }

  .nav {
    display: block;
    position: static;
    border: none;
    background: transparent;
    padding: 0;
  }
  .nav-in { flex-direction: row; gap: 4px; }
  .nav-in a { padding: 8px 12px; font-size: 14px; }

  .opener { padding-top: 112px; padding-bottom: 88px; }

  .plate-in {
    grid-template-columns: 5fr 6fr;
    gap: 64px;
    padding-top: 80px;
    padding-bottom: 80px;
  }

  .favs-in { grid-template-columns: 1fr 1fr; gap: 64px; }

  .foot-in {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

@media (min-width: 960px) {
  .steps { display: grid; grid-template-columns: 1fr 1fr; column-gap: 48px; }
  .cards.three { grid-template-columns: repeat(3, 1fr); }
}
