@font-face {
  font-family: Fraunces;
  font-style: normal;
  font-weight: 560 650;
  font-display: swap;
  src: url("fonts/fraunces-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: Outfit;
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/outfit-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #0b0a09;
  --card: #161513;
  --cream: #f4f0e6;
  --muted: #a39e93;
  --nav: #ddd6c8;
  --gold: #d6ae4e;
  --gold-ink: #1a1408;
  --line: rgba(244, 240, 230, 0.12);
  --serif: Fraunces, "Iowan Old Style", Palatino, "Palatino Linotype", serif;
  --sans: Outfit, "Avenir Next", "Segoe UI", sans-serif;
  color-scheme: dark;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--cream);
  font-family: var(--sans);
  font-size: 1.02rem;
  line-height: 1.45;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  height: auto;
}

button,
input,
select {
  font: inherit;
  color: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding-left: 1.15rem;
}

a {
  color: inherit;
}

.skip {
  position: absolute;
  left: 1rem;
  top: 0.75rem;
  transform: translateY(-160%);
  background: var(--gold);
  color: var(--gold-ink);
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  z-index: 40;
  font-weight: 600;
  text-decoration: none;
}

.skip:focus {
  transform: none;
}

.wrap {
  width: min(40rem, calc(100% - 1.5rem));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

button:disabled {
  opacity: 0.38;
  cursor: default;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  padding-top: env(safe-area-inset-top);
  background: rgba(11, 10, 9, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 3.6rem;
  padding-block: 0.45rem;
}

.mast {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.12rem;
  min-width: 0;
}

.app-title {
  color: var(--cream);
  font-family: var(--serif);
  font-weight: 650;
  font-size: 1.28rem;
  letter-spacing: -0.03em;
  line-height: 1.05;
  white-space: nowrap;
}

.byline {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 1.75rem;
  color: var(--nav);
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
}

.byline picture {
  display: block;
  line-height: 0;
  flex: 0 0 auto;
}

.byline img {
  display: block;
  width: auto;
  height: 20px;
  max-width: 22px;
  max-height: 22px;
  object-fit: contain;
}

.bar-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.help-link {
  width: 2.75rem;
  height: 2.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--gold);
  text-decoration: none;
  font-family: var(--serif);
  font-weight: 650;
  font-size: 1.25rem;
}

.help-link[aria-current="page"] {
  background: var(--gold);
  color: var(--gold-ink);
  border-color: var(--gold);
}

.lede a,
.guide a,
.welcome a,
.confirm a,
.legal a,
.noscript a {
  color: var(--gold);
  font-weight: 600;
}

.more-row {
  margin: 0.85rem 0 0.15rem;
}

.more-row .primary {
  text-decoration: none;
}

.welcome {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0.95rem 1rem 1rem;
  margin-bottom: 1rem;
}

.welcome p + .actions,
.share-form .actions {
  margin-top: 0.8rem;
}

.guide {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.1rem;
}

.guide h2 {
  font-family: var(--serif);
  font-weight: 650;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  margin-top: 0.4rem;
}

.guide ul,
.guide ol {
  display: grid;
  gap: 0.75rem;
}

.guide li::marker {
  color: var(--gold);
  font-weight: 600;
}

.share-form {
  margin-top: 0.4rem;
}

.field {
  display: grid;
  gap: 0.3rem;
  margin-top: 0.85rem;
}

.field span {
  color: var(--muted);
  font-size: 0.86rem;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.65rem 0.8rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--card);
  font-size: 1rem;
}

.field textarea {
  min-height: 6.5rem;
  resize: vertical;
  line-height: 1.4;
}

.confirm {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  margin-top: 1rem;
}

.confirm input {
  width: 1.35rem;
  height: 1.35rem;
  margin-top: 0.15rem;
  accent-color: var(--gold);
  flex: 0 0 auto;
}

.foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  margin-top: 1.4rem;
}

.foot-links a {
  color: var(--gold);
  font-weight: 600;
  text-decoration: none;
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
}

.foot-links + .more-row {
  margin-top: 0.35rem;
}

.more-row + .legal {
  margin-top: 0.85rem;
}

main {
  padding: 1rem 0 1.25rem;
}

h1 {
  font-family: var(--serif);
  font-weight: 650;
  font-size: clamp(2.4rem, 12vw, 3.4rem);
  letter-spacing: -0.04em;
  line-height: 0.95;
}

h1:focus {
  outline: none;
}

.lede,
.meta,
.summary,
.empty,
.note,
.why,
.asof,
.recipes-from {
  color: var(--muted);
}

.why {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.lede {
  margin-top: 0.45rem;
  max-width: 36rem;
}

.sections {
  display: flex;
  gap: 0.45rem;
  margin: 1rem 0 0.85rem;
  overflow-x: auto;
  padding-bottom: 0.2rem;
  scrollbar-width: none;
}

.sections::-webkit-scrollbar {
  display: none;
}

.chip,
.pick,
.icon-btn,
.primary,
.store,
.select-wrap select {
  min-height: 2.75rem;
}

.chip,
.ghost,
.primary,
.store,
.pick,
.icon-btn {
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--cream);
  padding: 0.45rem 0.9rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  cursor: pointer;
  white-space: nowrap;
}

.chip[aria-pressed="true"],
.pick.on,
.primary,
.store {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--gold-ink);
  font-weight: 600;
}

.tools {
  display: flex;
  gap: 0.55rem;
  align-items: center;
}

.search {
  flex: 1;
  min-width: 0;
  min-height: 2.75rem;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  font-size: 1rem;
}

.select-wrap select {
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  padding: 0 0.75rem;
  font-size: 0.95rem;
}

.stack {
  display: grid;
  gap: 0.8rem;
  margin-top: 0.9rem;
}

.card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--card);
  padding: 1.15rem 1rem 0.9rem;
}

.card::before,
.seasoning::before {
  content: "";
  position: absolute;
  top: 1px;
  left: 1px;
  right: 1px;
  height: 8px;
  background: repeating-linear-gradient(-45deg, transparent 0 4px, var(--gold) 4px 5.4px);
}

.card-hit {
  display: block;
  color: inherit;
  text-decoration: none;
  padding-top: 0.35rem;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.7rem;
  margin-bottom: 0.3rem;
}

.badge {
  color: var(--gold);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.allergen {
  display: inline-block;
  margin: 0.15rem 0 0.45rem;
  padding: 0.18rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--cream);
  font-size: 0.78rem;
  line-height: 1.35;
}

.card h2,
.detail h2,
.group h2,
.block h2 {
  font-family: var(--serif);
  font-weight: 650;
  font-size: 1.55rem;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.summary {
  margin-top: 0.4rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.detail .summary {
  display: block;
  -webkit-line-clamp: unset;
  overflow: visible;
}

.meta,
.rating-row {
  margin-top: 0.45rem;
}

.rating-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.7rem;
}

.starbar {
  position: relative;
  display: inline-block;
  color: rgba(244, 240, 230, 0.28);
  letter-spacing: 0.06em;
  font-size: 1rem;
  line-height: 1;
}

.starbar > span {
  position: absolute;
  left: 0;
  top: 0;
  overflow: hidden;
  white-space: nowrap;
  color: var(--gold);
}

.star-num,
.count {
  font-variant-numeric: tabular-nums;
}

.site-name {
  color: var(--nav);
}

.card .pick {
  width: 100%;
  margin-top: 0.85rem;
}

.back {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  margin-bottom: 0.35rem;
  color: var(--gold);
  text-decoration: none;
  font-weight: 600;
}

.detail h1 {
  font-size: clamp(2.1rem, 10vw, 3rem);
  margin-top: 0.15rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: 1rem 0;
}

.source {
  margin-top: 0.4rem;
}

.source a,
.credit a {
  color: var(--gold);
  font-weight: 600;
}

.credit {
  margin-top: 0.35rem;
  font-size: 0.92rem;
}

.seasoning {
  position: relative;
  overflow: hidden;
  margin: 1rem 0;
  padding: 1.15rem 1rem 1rem;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: #201c14;
}

.seasoning h2,
.block h2,
.group h2 {
  font-size: 1.35rem;
  margin-bottom: 0.45rem;
}

.try-label {
  margin-top: 0.75rem;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.seasoning ul {
  margin-top: 0.3rem;
}

.season-tip,
.note {
  margin-top: 0.7rem;
}

.ingredients {
  display: grid;
  gap: 0.45rem;
  margin-top: 0.45rem;
  padding: 0;
  list-style: none;
}

.ingredients li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--line);
}

.amt {
  color: var(--gold);
  white-space: nowrap;
}

.tag {
  color: var(--muted);
  font-size: 0.86rem;
}

.steps {
  margin-top: 0.4rem;
  display: grid;
  gap: 0.65rem;
  padding-left: 1.2rem;
}

.steps li {
  padding-left: 0.2rem;
}

.aisle-label {
  margin: 1.1rem 0 0.45rem;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.pantry {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.check {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  width: 100%;
  text-align: left;
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 16px;
  padding: 0.8rem 0.85rem;
  cursor: pointer;
}

.check input {
  width: 1.35rem;
  height: 1.35rem;
  margin-top: 0.15rem;
  accent-color: var(--gold);
  flex: 0 0 auto;
}

.check.on .item-name {
  color: var(--muted);
  text-decoration: line-through;
}

.item-name {
  font-weight: 600;
}

.best {
  margin-top: 0.25rem;
}

.best a {
  color: var(--gold);
}

.price-note {
  margin: 0.7rem 0;
  color: var(--gold);
}

.chosen {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.55rem;
}

.store-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.cook {
  min-height: calc(100dvh - 4.5rem);
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.cook-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.season-reminder {
  color: var(--gold);
  font-size: 0.95rem;
}

.season-reminder span {
  display: block;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
}

.step-text {
  flex: 1;
  display: flex;
  align-items: center;
  font-family: var(--serif);
  font-weight: 560;
  font-size: clamp(1.7rem, 7.2vw, 2.45rem);
  letter-spacing: -0.03em;
  line-height: 1.25;
  min-height: 12rem;
}

.cook-nav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0.5rem;
  align-items: center;
}

.cook-nav .primary {
  min-height: 3.1rem;
}

.counter {
  text-align: center;
  font-variant-numeric: tabular-nums;
  color: var(--nav);
}

.wake {
  justify-self: center;
}

.tabbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 12;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.25rem;
  padding: 0.35rem 0.5rem calc(0.35rem + env(safe-area-inset-bottom));
  background: var(--bg);
  border-top: 1px solid var(--line);
}

.tab {
  position: relative;
  min-height: 3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.1rem;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 12px;
}

.tab[aria-current="page"] {
  color: var(--gold-ink);
  background: var(--gold);
}

.tab svg {
  width: 1.25rem;
  height: 1.25rem;
  display: block;
}

.badge-count {
  position: absolute;
  top: 0.15rem;
  right: calc(50% - 1.7rem);
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.25rem;
  border-radius: 999px;
  background: var(--cream);
  color: var(--gold-ink);
  font-size: 0.68rem;
  line-height: 1.15rem;
  text-align: center;
}

.tab[aria-current="page"] .badge-count {
  background: var(--bg);
  color: var(--cream);
}

.legal {
  margin-top: 1.4rem;
  color: var(--muted);
  font-size: 0.92rem;
  padding-bottom: calc(0.6rem + env(safe-area-inset-bottom));
}

.cook-page .legal {
  padding-bottom: calc(0.6rem + env(safe-area-inset-bottom));
}

body.has-tabs {
  padding-bottom: calc(5.6rem + env(safe-area-inset-bottom));
}

body.has-tabs .legal {
  padding-bottom: 0;
}

.status {
  position: fixed;
  left: 50%;
  bottom: calc(5.2rem + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  display: none;
  width: min(22rem, calc(100% - 1.5rem));
  margin: 0;
  padding: 0.7rem 0.9rem;
  border-radius: 14px;
  background: var(--cream);
  color: var(--gold-ink);
  font-weight: 600;
  text-align: center;
  z-index: 20;
  pointer-events: none;
}

.status.show {
  display: block;
}

.status[hidden] {
  display: none !important;
}

.noscript {
  padding-top: 2rem;
}

.noscript .legal {
  padding-bottom: 2rem;
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.primary:focus-visible,
.store:focus-visible,
.chip[aria-pressed="true"]:focus-visible,
.pick.on:focus-visible,
.tab[aria-current="page"]:focus-visible {
  outline-color: var(--cream);
}

@media (max-width: 359px) {
  .wrap {
    width: calc(100% - 1rem);
  }

  .card h2 {
    font-size: 1.35rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
