:root {
  color-scheme: dark;
  --bg: #101820;
  --panel: #17232d;
  --panel-strong: #1e2d38;
  --text: #f8f4e8;
  --muted: #a9b8bf;
  --line: rgba(255, 255, 255, 0.12);
  --accent: #ffcc4d;
  --accent-2: #ff7a59;
  --green: #7ddc9c;
  --blue: #80bfff;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(255, 204, 77, 0.18), transparent 34rem),
    radial-gradient(circle at top right, rgba(255, 122, 89, 0.16), transparent 28rem),
    var(--bg);
  color: var(--text);
}

button,
select {
  font: inherit;
}

a {
  color: inherit;
}

.app {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 56px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  align-items: center;
  gap: 24px;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 32px;
  background: linear-gradient(135deg, rgba(30, 45, 56, 0.94), rgba(16, 24, 32, 0.9));
  box-shadow: var(--shadow);
}

.eyebrow,
.section-kicker {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 12px;
  font-size: clamp(2.7rem, 9vw, 6rem);
  line-height: 0.9;
  letter-spacing: -0.08em;
}

.lede {
  max-width: 760px;
  margin-bottom: 24px;
  color: var(--muted);
  font-size: clamp(1.04rem, 2.4vw, 1.35rem);
  line-height: 1.55;
}

.hero-meta,
.feed-status,
.card-topline,
.badges,
.source-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-meta span,
.feed-status span,
.chain-pill,
.score-pill,
.badge,
.source-link,
.tab,
.star-button {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
}

.mascot-card {
  justify-self: end;
  width: 196px;
  border: 1px solid rgba(255, 204, 77, 0.26);
  border-radius: 28px;
  background:
    radial-gradient(circle at 50% 22%, rgba(255, 204, 77, 0.2), transparent 76px),
    rgba(255, 255, 255, 0.06);
  padding: 18px;
  text-align: center;
}

.krow {
  position: relative;
  width: 104px;
  height: 116px;
  margin: 0 auto 12px;
}

.krow-head,
.krow-body {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  background: #0b1117;
  border: 3px solid rgba(248, 244, 232, 0.92);
}

.krow-head {
  top: 0;
  width: 82px;
  height: 70px;
  border-radius: 46px 46px 38px 38px;
}

.krow-head::before,
.krow-head::after {
  content: "";
  position: absolute;
  top: 14px;
  width: 28px;
  height: 28px;
  background: #0b1117;
  border-left: 3px solid rgba(248, 244, 232, 0.92);
  border-top: 3px solid rgba(248, 244, 232, 0.92);
}

.krow-head::before {
  left: 8px;
  transform: rotate(26deg);
}

.krow-head::after {
  right: 8px;
  transform: rotate(64deg);
}

.krow-eye {
  position: absolute;
  top: 30px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
}

.krow-eye:first-child {
  left: 24px;
}

.krow-eye:nth-child(2) {
  right: 24px;
}

.krow-beak {
  position: absolute;
  left: 50%;
  top: 41px;
  width: 0;
  height: 0;
  transform: translateX(-50%);
  border-left: 12px solid transparent;
  border-right: 12px solid transparent;
  border-top: 16px solid var(--accent);
}

.krow-body {
  bottom: 0;
  width: 92px;
  height: 70px;
  border-radius: 50px 50px 32px 32px;
}

.krow-body::before,
.krow-body::after {
  content: "";
  position: absolute;
  top: 14px;
  width: 34px;
  height: 48px;
  border-radius: 50%;
  background: #0b1117;
  border: 3px solid rgba(248, 244, 232, 0.82);
}

.krow-body::before {
  left: -18px;
  transform: rotate(-18deg);
}

.krow-body::after {
  right: -18px;
  transform: rotate(18deg);
}

.krow-bag {
  position: absolute;
  left: 50%;
  top: 22px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 34px;
  height: 28px;
  transform: translateX(-50%);
  border-radius: 8px;
  background: var(--accent-2);
  color: var(--text);
  font-size: 1rem;
  font-weight: 900;
}

.mascot-name {
  margin-bottom: 4px;
  color: var(--accent);
  font-weight: 900;
}

.mascot-copy {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.feed-status {
  gap: 6px;
  margin-top: 12px;
}

.feed-status span {
  padding: 7px 10px;
  color: var(--muted);
  font-size: 0.76rem;
}

.feed-status strong {
  color: var(--accent);
  font-size: 0.86rem;
}

.hero-meta span,
.chain-pill,
.score-pill,
.badge,
.source-link {
  padding: 8px 11px;
}

.star-button {
  display: inline-grid;
  place-items: center;
  min-width: 38px;
  min-height: 34px;
  margin-left: auto;
  padding: 6px 10px;
  cursor: pointer;
  color: var(--muted);
  font-size: 1.1rem;
}

.intro-card,
.filters,
.product-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(23, 35, 45, 0.86);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.18);
}

.intro-card {
  display: grid;
  grid-template-columns: minmax(180px, 0.35fr) 1fr;
  gap: 24px;
  margin: 20px 0;
  padding: 24px;
}

.intro-card h2 {
  margin-bottom: 0;
}

#weeklyIntro {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.65;
}

.filters {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 16px;
}

label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel-strong);
  color: var(--text);
  padding: 11px 12px;
}

.section-tabs {
  display: flex;
  gap: 8px;
  margin: 18px 0;
  overflow-x: auto;
  padding-bottom: 4px;
}

.tab {
  cursor: pointer;
  padding: 10px 14px;
  white-space: nowrap;
}

.tab.active {
  border-color: rgba(255, 204, 77, 0.68);
  background: rgba(255, 204, 77, 0.16);
  color: var(--accent);
}

.product-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.product-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  align-items: stretch;
  padding: 0;
  overflow: hidden;
}

.product-thumb {
  width: 100%;
  aspect-ratio: 16 / 10;
  min-height: 0;
  background: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid var(--line);
}

.product-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
  background: rgba(255, 255, 255, 0.04);
}

.product-body {
  display: grid;
  align-content: start;
  gap: 14px;
  min-width: 0;
  padding: 20px;
}

.product-card h2 {
  margin-bottom: 0;
  font-size: 1.25rem;
  line-height: 1.25;
}

.summary,
.context,
details,
.local-signals {
  color: var(--muted);
  line-height: 1.55;
}

.summary,
.context {
  margin-bottom: 0;
}

.score-pill {
  border-color: rgba(125, 220, 156, 0.44);
  color: var(--green);
}

.star-button[aria-pressed="true"] {
  border-color: rgba(255, 204, 77, 0.68);
  background: rgba(255, 204, 77, 0.16);
  color: var(--accent);
}

.product-card.is-starred {
  border-color: rgba(255, 204, 77, 0.34);
}

.badge.limited,
.badge.regional {
  border-color: rgba(255, 122, 89, 0.5);
  color: var(--accent-2);
}

.badge.collab {
  border-color: rgba(128, 191, 255, 0.55);
  color: var(--blue);
}

.badge.seasonal {
  border-color: rgba(255, 204, 77, 0.55);
  color: var(--accent);
}

.badge.bogo,
.badge.deal {
  border-color: rgba(125, 220, 156, 0.5);
  color: var(--green);
}

details {
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

summary {
  cursor: pointer;
  color: var(--text);
  font-weight: 800;
}

.reasons {
  margin-bottom: 0;
  padding-left: 18px;
}

.local-signals {
  border-left: 3px solid rgba(255, 204, 77, 0.55);
  padding-left: 12px;
}

.source-link:hover,
.tab:hover,
.star-button:hover {
  border-color: rgba(255, 255, 255, 0.28);
}

.empty {
  grid-column: 1 / -1;
  border: 1px dashed var(--line);
  border-radius: 24px;
  padding: 28px;
  color: var(--muted);
  text-align: center;
}

@media (max-width: 760px) {
  .app {
    width: min(100% - 20px, 1120px);
    padding-top: 12px;
  }

  .hero,
  .intro-card {
    border-radius: 22px;
    padding: 20px;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .mascot-card {
    justify-self: start;
    width: 100%;
  }

  .intro-card,
  .filters,
  .product-list {
    grid-template-columns: 1fr;
  }
}
