@font-face {
  font-family: "SUIT";
  src: url("./assets/fonts/SUIT-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "SUIT";
  src: url("./assets/fonts/SUIT-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: "SUIT";
  src: url("./assets/fonts/SUIT-Bold.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: "SUIT";
  src: url("./assets/fonts/SUIT-ExtraBold.woff2") format("woff2");
  font-weight: 800 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --forest-950: #102d25;
  --forest-900: #153c31;
  --forest-800: #1b5341;
  --forest-700: #247054;
  --forest-100: #dff1e7;
  --ink: #18241f;
  --muted: #66756e;
  --paper: #f7f6f0;
  --surface: #ffffff;
  --surface-soft: #f0f3ee;
  --line: #dde4dc;
  --sun: #ffc857;
  --coral: #ff715b;
  --coral-dark: #df4d3f;
  --sky: #79b9d2;
  --berry: #d85f88;
  --shadow-sm: 0 8px 24px rgba(20, 47, 37, 0.08);
  --shadow-md: 0 18px 48px rgba(12, 34, 27, 0.16);
  --shadow-lg: 0 34px 90px rgba(5, 24, 18, 0.34);
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  font-family: "SUIT", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", sans-serif;
  color: var(--ink);
  background: linear-gradient(145deg, #14392f 0%, #245b47 48%, #173d32 100%);
}

body {
  overflow-x: hidden;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible {
  outline: 3px solid rgba(255, 200, 87, 0.72);
  outline-offset: 2px;
}

svg {
  display: block;
}

.page {
  position: relative;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 20px;
  isolation: isolate;
}

.page::before,
.page::after {
  content: "";
  position: fixed;
  z-index: -2;
  inset: 0;
  pointer-events: none;
}

.page::before {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(145deg, #14392f 0%, #245b47 48%, #173d32 100%);
  background-size: 48px 48px, 48px 48px, auto;
}

.page::after {
  inset: 8% 16%;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 50%;
  transform: rotate(-8deg);
  box-shadow:
    0 0 0 70px rgba(255, 255, 255, 0.018),
    0 0 0 150px rgba(255, 255, 255, 0.012);
}

.phone {
  width: min(100%, 430px);
  height: min(872px, calc(100dvh - 40px));
  min-height: 700px;
  display: grid;
  grid-template-rows: 82px minmax(0, 1fr) 78px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 28px;
  background: var(--paper);
  box-shadow: var(--shadow-lg), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 18px 12px;
  border-bottom: 1px solid rgba(27, 83, 65, 0.09);
  background: #f7f6f0;
}

.brand,
.row,
.section-title,
.recipe-meta,
.today,
.section-head,
.quest-meta,
.profile-title-row,
.rank-person,
.sheet-title-row,
.allergy-item,
.unlock-row {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
}

.mark {
  position: relative;
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 12px;
  background: var(--forest-800);
  color: #fff;
  box-shadow: 0 7px 18px rgba(27, 83, 65, 0.22);
  font-size: 15px;
  font-weight: 900;
}

.mark::after {
  content: "";
  position: absolute;
  width: 32px;
  height: 32px;
  right: -17px;
  bottom: -17px;
  border: 6px solid var(--sun);
  border-radius: 50%;
}

.brand-copy span,
.eyebrow,
.label,
.screen-kicker {
  display: block;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
}

.brand h1,
h2,
h3,
p {
  margin: 0;
  letter-spacing: 0;
}

.brand h1 {
  margin-top: 3px;
  font-size: 20px;
  line-height: 1;
}

.top-actions {
  display: flex;
  gap: 8px;
}

.icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--forest-800);
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.icon:hover {
  transform: translateY(-1px);
  border-color: #bfcfc5;
  background: #fff;
}

.content {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px 16px 30px;
  scrollbar-width: none;
  scroll-behavior: smooth;
}

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

.screen {
  animation: screen-in 280ms cubic-bezier(.22, .76, .28, 1) both;
}

@keyframes screen-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.quest-hero {
  position: relative;
  min-height: 248px;
  overflow: hidden;
  padding: 18px;
  border-radius: 8px;
  background:
    linear-gradient(130deg, rgba(255, 255, 255, 0.08), transparent 48%),
    var(--forest-900);
  color: #fff;
  box-shadow: var(--shadow-md);
}

.quest-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: linear-gradient(to left, #000, transparent 72%);
}

.quest-copy {
  position: relative;
  z-index: 2;
  width: 69%;
}

.quest-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
  color: #dff1e7;
  font-size: 11px;
  font-weight: 800;
}

.quest-hero h2 {
  margin-top: 14px;
  font-size: 29px;
  line-height: 1.08;
}

.quest-hero h3 {
  margin-top: 9px;
  color: var(--sun);
  font-size: 19px;
}

.quest-meta {
  gap: 8px;
  margin-top: 11px;
  color: #c9dacf;
  font-size: 12px;
  font-weight: 700;
}

.quest-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.quest-visual {
  position: absolute;
  z-index: 1;
  right: -7px;
  top: 27px;
  width: 132px;
  height: 132px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  background: #fff6dd;
  box-shadow:
    inset 0 0 0 10px rgba(255, 200, 87, 0.22),
    0 18px 38px rgba(7, 24, 19, 0.28);
}

.quest-visual::before,
.quest-visual::after {
  content: "";
  position: absolute;
  border-radius: 50%;
}

.quest-visual::before {
  width: 86px;
  height: 86px;
  border: 3px solid #263832;
  background: #33483f;
  box-shadow: inset 0 0 0 8px #20312b;
}

.quest-visual::after {
  width: 42px;
  height: 42px;
  background: var(--sun);
  box-shadow: inset -6px -5px 0 rgba(255, 145, 46, 0.3);
}

.quest-emoji {
  position: relative;
  z-index: 2;
  font-size: 32px;
  opacity: 0;
}

.quest-cta {
  position: absolute;
  z-index: 3;
  left: 18px;
  right: 18px;
  bottom: 16px;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px 0 16px;
  border: 0;
  border-radius: 13px;
  background: var(--sun);
  color: #223128;
  box-shadow: 0 9px 20px rgba(5, 24, 18, 0.18);
  font-size: 14px;
  font-weight: 900;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.quest-cta:hover,
.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(5, 24, 18, 0.2);
}

.cta-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.42);
}

.progress-panel {
  display: grid;
  grid-template-columns: 1fr 92px;
  gap: 16px;
  align-items: center;
  margin-top: 14px;
  padding: 17px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.progress-panel h3 {
  margin-top: 5px;
  font-size: 22px;
}

.progress-panel h3 b {
  color: var(--forest-700);
  font-size: 32px;
}

.progress-track {
  height: 7px;
  overflow: hidden;
  margin-top: 13px;
  border-radius: 999px;
  background: #e7ebe6;
}

.progress-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--coral);
}

.progress-caption {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.progress-ring {
  --progress: 0;
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--forest-700) calc(var(--progress) * 1%), #e6ece7 0);
}

.progress-ring::before {
  content: "";
  grid-area: 1 / 1;
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background: #fff;
}

.progress-ring strong {
  grid-area: 1 / 1;
  position: relative;
  color: var(--forest-700);
  font-size: 18px;
}

.section-block {
  margin-top: 20px;
}

.section-head {
  justify-content: space-between;
  margin-bottom: 10px;
}

.section-head h3 {
  font-size: 16px;
}

.section-head span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.reward-track {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.reward-slot {
  min-width: 0;
  text-align: center;
}

.reward-icon {
  position: relative;
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  margin: 0 auto;
  border: 1px dashed #c9d3cc;
  border-radius: 14px;
  background: #f4f6f2;
  color: #a4afa8;
  font-size: 22px;
}

.reward-slot.unlocked .reward-icon {
  border-style: solid;
  border-color: #cfe3d6;
  background: var(--forest-100);
  color: var(--forest-700);
}

.reward-slot.current .reward-icon {
  border: 2px solid var(--coral);
  background: #fff0ec;
  color: var(--coral-dark);
}

.reward-slot small {
  display: block;
  overflow: hidden;
  margin-top: 6px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quick-grid {
  display: grid;
  grid-template-columns: 1.18fr .82fr;
  gap: 10px;
  margin-top: 14px;
}

.quick-card {
  min-height: 128px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.quick-card.badge-card {
  background: #fff7e3;
  border-color: #f0dfb8;
}

.quick-card-icon {
  width: 35px;
  height: 35px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--surface-soft);
  color: var(--forest-700);
}

.badge-card .quick-card-icon {
  background: #ffe7a8;
  color: #8a5d00;
}

.quick-card h3 {
  margin-top: 14px;
  font-size: 15px;
}

.quick-card p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
  line-height: 1.45;
}

.map-screen {
  margin: -16px -16px -30px;
}

.map-hero {
  position: sticky;
  top: -16px;
  z-index: 6;
  padding: 18px 18px 15px;
  color: #fff;
  background: var(--forest-900);
  box-shadow: 0 12px 30px rgba(15, 47, 36, 0.17);
}

.map-hero.dessert {
  background: #713047;
}

.map-hero-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.map-hero .screen-kicker {
  color: #bcd2c7;
}

.map-hero.dessert .screen-kicker {
  color: #f4cddd;
}

.map-hero h2 {
  margin-top: 4px;
  font-size: 25px;
}

.map-stat {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 9px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 11px;
  font-weight: 800;
}

.map-progress {
  height: 5px;
  overflow: hidden;
  margin-top: 13px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.13);
}

.map-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--sun);
}

.map-route {
  position: relative;
  min-height: 100%;
  padding: 24px 18px 50px;
  background:
    linear-gradient(90deg, rgba(27, 83, 65, 0.035) 1px, transparent 1px),
    linear-gradient(rgba(27, 83, 65, 0.035) 1px, transparent 1px),
    #eef3ed;
  background-size: 22px 22px;
}

.map-route.dessert {
  background:
    linear-gradient(90deg, rgba(154, 80, 111, 0.04) 1px, transparent 1px),
    linear-gradient(rgba(154, 80, 111, 0.04) 1px, transparent 1px),
    #f7eef2;
  background-size: 22px 22px;
}

.map-route::before {
  content: "";
  position: absolute;
  top: 40px;
  bottom: 30px;
  left: 50%;
  width: 5px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: repeating-linear-gradient(to bottom, #9fbead 0 13px, transparent 13px 21px);
}

.map-route.dessert::before {
  background: repeating-linear-gradient(to bottom, #d7a8bc 0 13px, transparent 13px 21px);
}

.chapter-marker {
  position: relative;
  z-index: 2;
  width: max-content;
  margin: 5px auto 18px;
  padding: 7px 12px;
  border: 1px solid #cfdbd3;
  border-radius: 999px;
  background: #fff;
  color: var(--forest-700);
  box-shadow: 0 7px 18px rgba(28, 69, 54, 0.09);
  font-size: 10px;
  font-weight: 900;
}

.map-route.dessert .chapter-marker {
  border-color: #e1c6d2;
  color: #934766;
}

.map-stop {
  position: relative;
  z-index: 2;
  width: 77%;
  min-height: 88px;
  display: grid;
  grid-template-columns: 58px 1fr 20px;
  gap: 10px;
  align-items: center;
  margin-bottom: 16px;
  padding: 11px 12px;
  border: 1px solid #dbe3dd;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 26px rgba(23, 61, 49, 0.09);
  text-align: left;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.map-stop:nth-of-type(even) {
  margin-left: auto;
}

.map-stop.right {
  margin-left: auto;
}

.map-stop:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 15px 34px rgba(23, 61, 49, 0.13);
}

.map-stop.cleared {
  border-color: #bad7c7;
  background: #f8fffa;
}

.map-stop.available {
  border: 2px solid var(--coral);
  box-shadow: 0 13px 28px rgba(223, 77, 63, 0.18);
}

.map-stop.skipped {
  border-style: dashed;
  border-color: #8cb7ca;
  background: #f4fbfe;
}

.map-stop.locked {
  border-color: #dfe3df;
  background: rgba(240, 242, 239, 0.92);
  color: #8b9690;
  box-shadow: none;
  cursor: not-allowed;
}

.node-badge {
  position: relative;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border: 5px solid #edf1ec;
  border-radius: 50%;
  background: #fff4d8;
  font-size: 25px;
  box-shadow: 0 5px 12px rgba(32, 68, 55, 0.1);
}

.map-stop.cleared .node-badge {
  border-color: #d7ecdf;
  background: var(--forest-700);
}

.map-stop.available .node-badge {
  border-color: #ffe1db;
  background: #fff;
  color: var(--coral-dark);
  animation: node-pulse 1.9s ease-in-out infinite;
}

.map-stop.locked .node-badge {
  border-color: #e2e6e2;
  background: #d8ded9;
  color: #7d8982;
}

@keyframes node-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 113, 91, 0.24); }
  50% { box-shadow: 0 0 0 8px rgba(255, 113, 91, 0); }
}

.node-copy {
  min-width: 0;
}

.node-num {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
}

.node-title {
  display: block;
  overflow: hidden;
  margin-top: 3px;
  font-size: 14px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.node-state {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-top: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
}

.map-stop.available .node-state { color: var(--coral-dark); }
.map-stop.cleared .node-state { color: var(--forest-700); }
.map-stop.skipped .node-state { color: #397a98; }

.node-arrow {
  color: #9eaaa3;
}

.screen-heading {
  margin: 2px 2px 16px;
}

.screen-heading h2 {
  margin-top: 5px;
  font-size: 25px;
}

.screen-heading p:last-child {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.segment {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  border-radius: 13px;
  background: #e8ece7;
}

.segment button {
  min-height: 39px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.segment button.active {
  background: #fff;
  color: var(--forest-800);
  box-shadow: 0 5px 14px rgba(24, 55, 44, 0.1);
}

.podium {
  min-height: 244px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: end;
  gap: 8px;
  margin-top: 14px;
  padding: 18px 14px 0;
  overflow: hidden;
  border-radius: 8px;
  background: var(--forest-900);
  color: #fff;
  box-shadow: var(--shadow-md);
}

.podium-person {
  text-align: center;
}

.podium-person.first {
  order: 2;
}

.podium-person.second {
  order: 1;
}

.podium-person.third {
  order: 3;
}

.podium-avatar {
  position: relative;
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  margin: 0 auto 8px;
  border: 3px solid rgba(255,255,255,.65);
  border-radius: 50%;
  background: var(--sun);
  color: var(--forest-950);
  font-weight: 900;
}

.podium-person.first .podium-avatar {
  width: 62px;
  height: 62px;
  border-color: var(--sun);
  background: #fff4d0;
}

.podium-rank {
  position: absolute;
  right: -4px;
  bottom: -4px;
  width: 21px;
  height: 21px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  color: var(--forest-900);
  font-size: 10px;
  font-weight: 900;
}

.podium-person strong {
  display: block;
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.podium-person small {
  color: #c7d8cf;
  font-size: 10px;
}

.podium-block {
  height: 66px;
  margin-top: 9px;
  border-radius: 10px 10px 0 0;
  background: rgba(255, 255, 255, 0.11);
}

.podium-person.first .podium-block {
  height: 98px;
  background: rgba(255, 200, 87, 0.24);
}

.podium-person.third .podium-block {
  height: 50px;
}

.my-rank {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 11px;
  align-items: center;
  margin-top: 12px;
  padding: 13px;
  border: 1px solid #f0d5cd;
  border-radius: 8px;
  background: #fff4f0;
}

.my-rank-mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--coral);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
}

.my-rank strong,
.rank-person strong {
  display: block;
  font-size: 13px;
}

.my-rank span,
.rank-person span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.rank-score {
  color: var(--forest-700);
  font-size: 13px;
  font-weight: 900;
}

.rank-list {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.rank-row {
  display: grid;
  grid-template-columns: 28px 42px 1fr auto;
  gap: 9px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.rank-number {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  text-align: center;
}

.avatar {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #dcece3;
  color: var(--forest-800);
  font-weight: 900;
}

.profile-hero {
  position: relative;
  overflow: hidden;
  padding: 20px;
  border-radius: 8px;
  background: var(--forest-900);
  color: #fff;
  box-shadow: var(--shadow-md);
}

.profile-hero::after {
  content: "";
  position: absolute;
  width: 150px;
  height: 150px;
  right: -66px;
  top: -70px;
  border: 28px solid rgba(255, 200, 87, 0.13);
  border-radius: 50%;
}

.profile-main {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 13px;
  align-items: center;
}

.profile-avatar {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border: 3px solid rgba(255, 255, 255, 0.22);
  border-radius: 20px;
  background: var(--sun);
  color: var(--forest-950);
  font-size: 18px;
  font-weight: 900;
}

.profile-hero .eyebrow {
  color: #bdd2c7;
}

.profile-title-row {
  gap: 7px;
  margin-top: 3px;
}

.profile-title-row h2 {
  font-size: 21px;
}

.level-chip {
  padding: 4px 7px;
  border-radius: 999px;
  background: rgba(255, 200, 87, 0.15);
  color: var(--sun);
  font-size: 9px;
  font-weight: 900;
}

.profile-stats {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.profile-stat {
  text-align: center;
}

.profile-stat + .profile-stat {
  border-left: 1px solid rgba(255, 255, 255, 0.12);
}

.profile-stat strong {
  display: block;
  font-size: 18px;
}

.profile-stat span {
  display: block;
  margin-top: 3px;
  color: #bcd0c6;
  font-size: 9px;
  font-weight: 700;
}

.profile-section {
  margin-top: 16px;
}

.profile-section-card {
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.section-title {
  gap: 8px;
}

.section-title-icon {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--surface-soft);
  color: var(--forest-700);
}

.section-title h3 {
  font-size: 14px;
}

.section-title p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
}

.badge-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 13px;
}

.badge-item {
  min-height: 78px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 5px;
  border: 1px solid #e5e9e5;
  border-radius: 8px;
  background: #f6f7f5;
  color: #9aa39e;
  text-align: center;
}

.badge-item.earned {
  border-color: #d5e6dc;
  background: #eff8f2;
  color: var(--forest-700);
}

.badge-symbol {
  font-size: 22px;
  filter: grayscale(1);
  opacity: .5;
}

.badge-symbol svg {
  width: 22px;
  height: 22px;
}

.badge-item.earned .badge-symbol {
  filter: none;
  opacity: 1;
}

.badge-item span:last-child {
  font-size: 9px;
  font-weight: 850;
  line-height: 1.25;
}

.sticker-board {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 6px;
  margin-top: 13px;
}

.sticker-cell {
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid #e2e7e2;
  border-radius: 8px;
  background: #f7f8f6;
  font-size: 17px;
  transition: transform 150ms ease, border-color 150ms ease;
}

.sticker-cell:not(.locked):hover {
  transform: translateY(-2px) rotate(-2deg);
  border-color: #b9d6c5;
}

.sticker-cell.locked {
  color: #bdc5c0;
  cursor: default;
}

.sticker-detail {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 10px;
  align-items: center;
  margin-top: 10px;
  padding: 10px;
  border-radius: 12px;
  background: #eff7f2;
}

.sticker-detail-emoji {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: #fff;
  font-size: 23px;
}

.sticker-detail strong {
  display: block;
  font-size: 12px;
}

.sticker-detail span {
  color: var(--muted);
  font-size: 9px;
}

.allergy-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 12px;
}

.allergy-item {
  justify-content: space-between;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid #e1e6e2;
  border-radius: 8px;
  background: #fafbfa;
  font-size: 11px;
  font-weight: 800;
}

.allergy-check {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid #cad4cd;
  border-radius: 6px;
  color: transparent;
}

.allergy-item.active {
  border-color: #f0c7bd;
  background: #fff3ef;
  color: #a44335;
}

.allergy-item.active .allergy-check {
  border-color: var(--coral);
  background: var(--coral);
  color: #fff;
}

.skip-list {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.skip-row {
  width: 100%;
  display: grid;
  grid-template-columns: 34px 1fr 18px;
  gap: 9px;
  align-items: center;
  min-height: 48px;
  padding: 6px 9px;
  border: 1px solid #d7e4ea;
  border-radius: 8px;
  background: #f5fafc;
  text-align: left;
}

.skip-index {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: #dcecf3;
  color: #397a98;
  font-size: 10px;
  font-weight: 900;
}

.skip-row strong {
  font-size: 11px;
}

.tabs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  padding: 7px 10px calc(8px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(27, 83, 65, 0.1);
  background: #fafaf7;
}

.tabs button {
  position: relative;
  min-width: 0;
  min-height: 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 0;
  border-radius: 13px;
  background: transparent;
  color: #87938d;
  font-size: 9px;
  font-weight: 800;
  transition: color 150ms ease, background 150ms ease, transform 150ms ease;
}

.tabs button:hover {
  background: #edf1ed;
}

.tabs button.active {
  background: var(--forest-800);
  color: #fff;
  box-shadow: 0 8px 18px rgba(27, 83, 65, 0.22);
}

.tabs button.active::before {
  content: "";
  position: absolute;
  top: 6px;
  width: 16px;
  height: 2px;
  border-radius: 999px;
  background: var(--sun);
}

.tabs svg {
  width: 19px;
  height: 19px;
}

.modal {
  position: fixed;
  z-index: 40;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(7, 23, 18, 0.68);
  animation: modal-fade 180ms ease both;
}

@keyframes modal-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.sheet {
  width: min(100%, 430px);
  max-height: min(820px, calc(100dvh - 40px));
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 24px;
  background: var(--paper);
  box-shadow: var(--shadow-lg);
  scrollbar-width: none;
  animation: sheet-up 260ms cubic-bezier(.2, .8, .25, 1) both;
}

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

@keyframes sheet-up {
  from { opacity: 0; transform: translateY(20px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.recipe-cover {
  position: relative;
  min-height: 206px;
  overflow: hidden;
  padding: 18px;
  border-radius: 24px 24px 0 0;
  background: var(--forest-900);
  color: #fff;
}

.recipe-cover.dessert {
  background: #713047;
}

.recipe-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 22px 22px;
}

.sheet-title-row {
  position: relative;
  z-index: 2;
  justify-content: space-between;
}

.recipe-stage-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
  color: #d9e7df;
  font-size: 10px;
  font-weight: 850;
}

.recipe-cover .icon {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.09);
  color: #fff;
}

.recipe-dish {
  position: absolute;
  right: 22px;
  bottom: 18px;
  width: 116px;
  height: 116px;
  display: grid;
  place-items: center;
  border: 10px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  background: #fff8e5;
  box-shadow: 0 17px 38px rgba(0, 0, 0, 0.22);
}

.recipe-dish::before,
.recipe-dish::after {
  content: "";
  position: absolute;
}

.recipe-dish.meal-dish::before {
  width: 72px;
  height: 72px;
  border: 4px solid #253a33;
  border-radius: 50%;
  background: #344a41;
  box-shadow: inset 0 0 0 8px #20312b;
}

.recipe-dish.meal-dish::after {
  width: 31px;
  height: 31px;
  border-radius: 50%;
  background: var(--sun);
  box-shadow: inset -5px -4px 0 rgba(255, 145, 46, 0.3);
}

.recipe-dish.dessert-dish::before {
  width: 70px;
  height: 52px;
  border-radius: 8px 8px 14px 14px;
  background: linear-gradient(to bottom, #fff 0 22%, #ef9ab6 22% 58%, #f7d7a5 58% 100%);
  box-shadow: 0 8px 0 #d987a2;
}

.recipe-dish.dessert-dish::after {
  width: 18px;
  height: 18px;
  top: 18px;
  border-radius: 50%;
  background: #d94f58;
  box-shadow: 14px 6px 0 -5px #5c9b60;
}

.recipe-cover-copy {
  position: relative;
  z-index: 2;
  width: 65%;
  margin-top: 25px;
}

.recipe-cover h2 {
  font-size: 26px;
  line-height: 1.12;
}

.recipe-cover p {
  margin-top: 8px;
  color: #c6d8cf;
  font-size: 11px;
  line-height: 1.5;
}

.recipe-body {
  padding: 16px 18px 20px;
}

.recipe-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.recipe-meta-item {
  padding: 10px 7px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
  text-align: center;
}

.recipe-meta-item svg {
  margin: 0 auto 5px;
  color: var(--forest-700);
}

.recipe-meta-item strong {
  display: block;
  font-size: 11px;
}

.recipe-meta-item span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.warning {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin-top: 12px;
  padding: 11px;
  border: 1px solid #f0cbc2;
  border-radius: 11px;
  background: #fff1ed;
  color: #9e3f32;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.45;
}

.recipe-block {
  margin-top: 20px;
}

.recipe-block-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 10px;
}

.recipe-block h3 {
  font-size: 15px;
}

.recipe-block-head span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
}

.ingredient-list {
  display: grid;
  gap: 7px;
}

.ingredient-row {
  width: 100%;
  min-height: 42px;
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 9px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid #e1e6e2;
  border-radius: 10px;
  background: #fff;
  text-align: left;
  font-size: 11px;
  font-weight: 750;
}

.ingredient-check {
  width: 19px;
  height: 19px;
  display: grid;
  place-items: center;
  border: 1px solid #cbd5ce;
  border-radius: 6px;
  color: transparent;
}

.ingredient-row.checked {
  background: #f0f7f2;
  color: #738078;
  text-decoration: line-through;
}

.ingredient-row.checked .ingredient-check {
  border-color: var(--forest-700);
  background: var(--forest-700);
  color: #fff;
}

.tool-list,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.tool-chip,
.tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 9px;
  border-radius: 9px;
  background: #eaf4ee;
  color: var(--forest-700);
  font-size: 10px;
  font-weight: 800;
}

.tag-chip {
  background: #fff0ec;
  color: #a04437;
}

.step-list {
  display: grid;
  gap: 10px;
}

.step-row {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 10px;
  align-items: start;
}

.step-number {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--forest-900);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
}

.step-row p {
  padding-top: 5px;
  color: #3a4842;
  font-size: 11px;
  line-height: 1.55;
}

.sheet-actions {
  position: sticky;
  bottom: -20px;
  z-index: 4;
  margin: 22px -18px -20px;
  padding: 12px 18px calc(14px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: #f7f6f0;
}

.primary,
.secondary {
  width: 100%;
  min-height: 49px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 13px;
  font-size: 12px;
  font-weight: 900;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.primary {
  background: var(--coral);
  color: #fff;
  box-shadow: 0 10px 22px rgba(223, 77, 63, 0.25);
}

.secondary {
  margin-top: 8px;
  background: #e7ebe7;
  color: #53625a;
}

.reward-sheet {
  position: relative;
  overflow: hidden;
  padding: 28px 22px 22px;
  text-align: center;
}

.confetti {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.confetti i {
  position: absolute;
  width: 8px;
  height: 16px;
  border-radius: 3px;
  background: var(--sun);
  animation: confetti-fall 1.8s ease-out both;
}

.confetti i:nth-child(1) { left: 11%; top: 6%; transform: rotate(16deg); }
.confetti i:nth-child(2) { left: 24%; top: 14%; background: var(--coral); transform: rotate(-24deg); }
.confetti i:nth-child(3) { right: 18%; top: 8%; background: var(--sky); transform: rotate(28deg); }
.confetti i:nth-child(4) { right: 8%; top: 22%; background: var(--berry); transform: rotate(-12deg); }
.confetti i:nth-child(5) { left: 7%; top: 34%; background: var(--forest-700); transform: rotate(35deg); }

@keyframes confetti-fall {
  from { opacity: 0; translate: 0 -18px; }
  to { opacity: 1; translate: 0 0; }
}

.reward-burst {
  position: relative;
  width: 102px;
  height: 102px;
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
  border: 10px solid #fff4ce;
  border-radius: 50%;
  background: var(--sun);
  box-shadow: 0 15px 32px rgba(154, 104, 0, 0.2);
  font-size: 48px;
}

.reward-sheet .eyebrow {
  color: var(--forest-700);
}

.reward-sheet h2 {
  margin-top: 6px;
  font-size: 25px;
}

.reward-sheet > p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

.unlock-row {
  gap: 10px;
  margin-top: 18px;
  padding: 12px;
  border: 1px solid #d6e4da;
  border-radius: 12px;
  background: #eff7f2;
  text-align: left;
}

.unlock-icon {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #fff;
  color: var(--forest-700);
}

.unlock-row strong {
  display: block;
  font-size: 11px;
}

.unlock-row span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
}

.reward-total {
  margin-top: 13px;
  color: var(--forest-700);
  font-size: 12px;
  font-weight: 900;
}

/* Forest storybook theme */
:root {
  --forest-950: #173c32;
  --forest-900: #215446;
  --forest-800: #2f7159;
  --forest-700: #438c68;
  --forest-100: #dff4df;
  --ink: #27352f;
  --muted: #718078;
  --paper: #fbfaf3;
  --surface: #fffef9;
  --surface-soft: #eef7ee;
  --line: #dce8dc;
  --sun: #ffd66b;
  --coral: #ff8177;
  --coral-dark: #d95f59;
  --sky: #82cce0;
  --berry: #bd79aa;
  --lavender: #bcaee8;
  --peach: #ffc5a8;
  --shadow-sm: 0 8px 22px rgba(39, 86, 64, 0.09);
  --shadow-md: 0 18px 42px rgba(39, 86, 64, 0.15);
  --shadow-lg: 0 30px 80px rgba(12, 43, 33, 0.31);
}

html,
body {
  background: #204f43;
}

.page::before {
  background:
    linear-gradient(45deg, transparent 46%, rgba(255, 255, 255, 0.035) 47% 53%, transparent 54%) 0 0 / 72px 72px,
    linear-gradient(-45deg, transparent 46%, rgba(255, 213, 107, 0.04) 47% 53%, transparent 54%) 0 0 / 72px 72px,
    linear-gradient(135deg, #173f35 0%, #2e6b55 44%, #3d765b 70%, #214e43 100%);
}

.page::after {
  inset: auto 0 0;
  height: 25vh;
  border: 0;
  border-radius: 0;
  transform: none;
  background:
    linear-gradient(145deg, transparent 0 42%, rgba(21, 66, 50, 0.72) 43% 100%) 0 100% / 23% 100% repeat-x,
    linear-gradient(35deg, transparent 0 52%, rgba(255, 214, 107, 0.06) 53% 100%) 12% 100% / 31% 72% repeat-x;
  box-shadow: none;
}

.phone {
  border-color: rgba(255, 255, 255, 0.55);
  background: var(--paper);
  box-shadow: var(--shadow-lg), 0 0 0 7px rgba(255, 255, 255, 0.08);
}

.top {
  position: relative;
  z-index: 8;
  border-bottom-color: #e5eadf;
  background: #fffdf6;
}

.mark,
.icon,
.quest-cta,
.cta-icon,
.quick-card-icon,
.my-rank-mark,
.avatar,
.profile-avatar,
.section-title-icon {
  border-radius: 8px;
}

.mark {
  border: 1px solid rgba(34, 94, 71, 0.22);
  background: linear-gradient(145deg, #3b8061, #28654f);
  box-shadow: 0 7px 0 rgba(32, 91, 67, 0.14), 0 12px 24px rgba(47, 113, 89, 0.2);
}

.mark::before,
.mark::after {
  content: none;
}

.brand-symbol {
  width: 39px;
  height: 39px;
  overflow: visible;
  filter: drop-shadow(0 2px 1px rgba(22, 69, 51, 0.18));
}

.logo-leaf {
  fill: #a9dd7d;
  transform-origin: 25px 11px;
  animation: logo-leaf-wave 3.1s ease-in-out infinite;
}

.logo-stem,
.logo-steam,
.logo-rim,
.logo-smile,
.logo-shine {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.logo-stem {
  stroke: #d7efa5;
  stroke-width: 2;
}

.logo-steam {
  stroke: rgba(255, 255, 255, 0.82);
  stroke-width: 2.1;
  animation: logo-steam-rise 2.8s ease-in-out infinite;
}

.logo-rice {
  fill: #fff9df;
  stroke: #1d5944;
  stroke-width: 1.6;
}

.logo-bowl {
  fill: #ffd66b;
  stroke: #1d5944;
  stroke-width: 1.8;
}

.logo-rim {
  stroke: #1d5944;
  stroke-width: 1.7;
}

.logo-eye {
  fill: #345f4d;
}

.logo-cheek {
  fill: #ff9a8f;
  opacity: .75;
}

.logo-smile {
  stroke: #c7605c;
  stroke-width: 1.5;
}

.logo-shine {
  stroke: rgba(255, 255, 255, 0.7);
  stroke-width: 1.4;
}

@keyframes logo-leaf-wave {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(7deg); }
}

@keyframes logo-steam-rise {
  0%, 100% { transform: translateY(1px); opacity: .7; }
  50% { transform: translateY(-1.5px); opacity: 1; }
}

.icon {
  border-color: #dce7d9;
  background: #f6f3e8;
  box-shadow: 0 5px 13px rgba(51, 91, 71, 0.08);
}

.content {
  background: #fbfaf3;
}

.quest-hero {
  min-height: 258px;
  border: 1px solid #cce7cf;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 251, 211, 0.42) 49%, rgba(206, 239, 210, 0.75)),
    #eaf7e7;
  color: var(--ink);
  box-shadow: 0 15px 36px rgba(65, 126, 91, 0.13);
}

.quest-hero::before {
  inset: 0;
  background:
    linear-gradient(45deg, transparent 47%, rgba(72, 143, 106, 0.05) 48% 52%, transparent 53%) 0 0 / 24px 24px;
  mask-image: linear-gradient(to right, transparent 30%, #000);
}

.quest-hero::after {
  content: "";
  position: absolute;
  right: -24px;
  bottom: 47px;
  width: 180px;
  height: 40px;
  border-radius: 50% 50% 0 0;
  background: #b6dfa8;
  box-shadow: -72px 15px 0 #d8edbd, 36px 13px 0 #8fc885;
  opacity: 0.72;
}

.quest-copy {
  width: 64%;
}

.quest-label {
  border-color: #c1dfc4;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--forest-700);
  box-shadow: 0 4px 12px rgba(61, 120, 89, 0.08);
}

.quest-hero h2 {
  margin-top: 13px;
  color: #28453a;
  font-size: 30px;
}

.quest-hero h3 {
  color: var(--coral-dark);
}

.quest-meta {
  color: #668072;
}

.quest-visual {
  z-index: 2;
  top: 19px;
  right: 4px;
  width: 143px;
  height: 154px;
  display: block;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.quest-visual::before,
.quest-visual::after {
  content: none;
}

.forest-chef {
  position: absolute;
  z-index: 4;
  right: 18px;
  bottom: 8px;
  width: 93px;
  height: 112px;
  transform-origin: 50% 100%;
  animation: buddy-float 2.8s ease-in-out infinite;
}

.chef-hat {
  position: absolute;
  z-index: 3;
  top: 0;
  left: 25px;
  width: 46px;
  height: 28px;
  border: 2px solid #d8e4d5;
  border-radius: 50% 50% 28% 28%;
  background: #fffef8;
  box-shadow: -15px 7px 0 -4px #fffef8, 15px 7px 0 -4px #fffef8;
  animation: hat-wiggle 2.8s ease-in-out infinite;
}

.chef-face {
  position: absolute;
  z-index: 2;
  top: 24px;
  left: 17px;
  width: 62px;
  height: 60px;
  border: 2px solid #376a53;
  border-radius: 48% 52% 46% 54%;
  background: #ffe0ae;
  box-shadow: inset -7px -5px 0 rgba(240, 172, 115, 0.18), 0 7px 0 #fff8df;
}

.chef-face::before,
.chef-face::after {
  content: "";
  position: absolute;
  top: 36px;
  width: 9px;
  height: 5px;
  border-radius: 50%;
  background: #ff9e9b;
  opacity: 0.72;
}

.chef-face::before { left: 7px; }
.chef-face::after { right: 7px; }

.chef-face i {
  position: absolute;
  top: 23px;
  width: 5px;
  height: 7px;
  border-radius: 50%;
  background: #315343;
  animation: buddy-blink 4.2s infinite;
}

.chef-face i:first-child { left: 17px; }
.chef-face i:nth-child(2) { right: 17px; }

.chef-face b {
  position: absolute;
  left: 27px;
  top: 34px;
  width: 9px;
  height: 5px;
  border-bottom: 2px solid #a25a52;
  border-radius: 50%;
}

.chef-body {
  position: absolute;
  left: 20px;
  bottom: 0;
  width: 57px;
  height: 39px;
  border: 2px solid #376a53;
  border-radius: 48% 48% 9px 9px;
  background: #77bc7b;
  box-shadow: inset 0 -9px 0 rgba(44, 126, 83, 0.14);
}

.chef-body::after {
  content: "";
  position: absolute;
  left: 16px;
  top: 8px;
  width: 21px;
  height: 22px;
  border-radius: 7px 7px 4px 4px;
  background: #fff7dd;
}

.chef-spoon {
  position: absolute;
  z-index: 5;
  right: 1px;
  top: 58px;
  width: 6px;
  height: 47px;
  border-radius: 999px;
  background: #7f8f87;
  transform: rotate(19deg);
  transform-origin: 50% 100%;
  animation: spoon-wave 2.2s ease-in-out infinite;
}

.chef-spoon::before {
  content: "";
  position: absolute;
  left: -5px;
  top: -11px;
  width: 16px;
  height: 19px;
  border-radius: 50%;
  background: #9caaa3;
}

.buddy-shadow {
  position: absolute;
  z-index: 1;
  right: 22px;
  bottom: 2px;
  width: 84px;
  height: 12px;
  border-radius: 50%;
  background: rgba(45, 98, 69, 0.16);
  animation: shadow-breathe 2.8s ease-in-out infinite;
}

.quest-emoji {
  position: absolute;
  z-index: 6;
  top: 4px;
  right: 2px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #fff8db;
  box-shadow: 0 7px 16px rgba(52, 99, 73, 0.13);
  font-size: 21px;
  opacity: 1;
  animation: dish-bob 3s ease-in-out infinite;
}

.hero-spark,
.hero-leaf {
  position: absolute;
  z-index: 3;
}

.hero-spark {
  width: 8px;
  height: 8px;
  background: var(--sun);
  clip-path: polygon(50% 0, 61% 38%, 100% 50%, 61% 62%, 50% 100%, 39% 62%, 0 50%, 39% 38%);
  animation: sparkle 1.8s ease-in-out infinite;
}

.spark-one { left: 5px; top: 37px; }
.spark-two { right: 9px; top: 61px; animation-delay: .55s; }

.hero-leaf {
  width: 19px;
  height: 10px;
  border-radius: 90% 10% 90% 10%;
  background: #73b873;
  transform-origin: 0 50%;
  animation: leaf-sway 2.4s ease-in-out infinite;
}

.leaf-one { left: 1px; bottom: 43px; transform: rotate(24deg); }
.leaf-two { right: 0; bottom: 34px; transform: rotate(-38deg); animation-delay: .6s; }

.quest-cta {
  border: 2px solid #fff1ba;
  background: var(--sun);
  color: #354739;
  box-shadow: 0 9px 0 #e8b94c, 0 14px 23px rgba(55, 100, 72, 0.13);
  animation: cta-breathe 2.6s ease-in-out infinite;
}

.quest-cta:hover {
  transform: translateY(2px);
  box-shadow: 0 6px 0 #e8b94c, 0 10px 19px rgba(55, 100, 72, 0.14);
}

.cta-icon {
  background: rgba(255, 255, 255, 0.67);
}

.progress-panel,
.reward-track,
.quick-card,
.profile-section-card,
.rank-row {
  border-color: #dce9dc;
  background: #fffef9;
}

.progress-panel {
  background: linear-gradient(110deg, #fffef9 0 72%, #eef8e8 72%);
}

.progress-track {
  background: #e4eee2;
}

.progress-track span {
  background: linear-gradient(90deg, var(--coral), var(--sun), #7fcf91);
  background-size: 180% 100%;
  animation: progress-shine 2.8s linear infinite;
}

.progress-ring {
  background: conic-gradient(#73c18a calc(var(--progress) * 1%), #e7efe4 0);
  box-shadow: 0 7px 18px rgba(60, 128, 88, 0.12);
}

.reward-track {
  position: relative;
  overflow: hidden;
  background: linear-gradient(90deg, #fffef9, #f6f0ff);
}

.reward-track::before {
  content: "";
  position: absolute;
  top: 39px;
  left: 32px;
  right: 32px;
  border-top: 2px dashed #d9d2b9;
}

.reward-slot {
  position: relative;
  z-index: 1;
}

.reward-icon {
  border-radius: 50%;
  background: #f3f0e8;
}

.reward-slot.unlocked .reward-icon {
  background: #e2f4df;
}

.reward-slot.current .reward-icon {
  border-color: var(--coral);
  background: #fff0eb;
  animation: reward-hop 1.7s ease-in-out infinite;
}

.quick-card {
  position: relative;
  overflow: hidden;
}

.quick-card::after {
  content: "";
  position: absolute;
  right: -14px;
  bottom: -15px;
  width: 49px;
  height: 35px;
  border-radius: 50% 50% 0 0;
  background: #d9efdc;
}

.quick-card.badge-card {
  border-color: #f1dfaa;
  background: #fff7dc;
}

.quick-card.badge-card::after {
  background: #f2d6ee;
}

.quick-card-icon {
  background: #e6f3e7;
}

.badge-card .quick-card-icon {
  background: #f5dff1;
  color: #9a588a;
}

.map-hero {
  padding-bottom: 19px;
  background: linear-gradient(110deg, #245846, #3b8060 65%, #5f9d6d);
  box-shadow: 0 10px 24px rgba(24, 77, 53, 0.2);
}

.map-hero::before,
.map-hero::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.map-hero::before {
  right: 54px;
  top: 9px;
  width: 45px;
  height: 23px;
  border-radius: 50% 50% 5px 5px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-bottom: 0;
  transform: rotate(-9deg);
}

.map-hero::after {
  left: 0;
  right: 0;
  bottom: -6px;
  height: 12px;
  background:
    radial-gradient(circle at 6px 0, #3a7d5e 0 7px, transparent 8px) 0 0 / 18px 12px repeat-x;
}

.map-hero.dessert {
  background: linear-gradient(110deg, #8d4e79, #bd739e 63%, #e49b9d);
}

.map-hero.dessert::after {
  background:
    radial-gradient(circle at 6px 0, #bd739e 0 7px, transparent 8px) 0 0 / 18px 12px repeat-x;
}

.map-stat {
  border-color: rgba(255, 255, 255, 0.3);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
}

.map-progress span {
  background: linear-gradient(90deg, var(--sun), #a9e890);
}

.map-route,
.map-route.dessert {
  min-height: 2000px;
  padding: 35px 18px 60px;
  background:
    linear-gradient(32deg, transparent 43%, rgba(123, 185, 111, 0.055) 44% 52%, transparent 53%) 0 0 / 42px 42px,
    linear-gradient(-34deg, transparent 44%, rgba(255, 204, 127, 0.08) 45% 51%, transparent 52%) 0 0 / 54px 54px,
    #edf7e9;
}

.map-route.dessert {
  background:
    linear-gradient(32deg, transparent 43%, rgba(185, 121, 170, 0.055) 44% 52%, transparent 53%) 0 0 / 42px 42px,
    linear-gradient(-34deg, transparent 44%, rgba(255, 177, 170, 0.09) 45% 51%, transparent 52%) 0 0 / 54px 54px,
    #f9f0f3;
}

.map-route::before,
.map-route.dessert::before {
  top: 52px;
  bottom: 62px;
  width: 8px;
  border: 2px solid rgba(255, 255, 255, 0.75);
  background: repeating-linear-gradient(to bottom, #9fcf9e 0 15px, #d6e9b8 15px 25px);
  box-shadow: 0 0 0 2px rgba(92, 151, 102, 0.08);
}

.map-route.dessert::before {
  background: repeating-linear-gradient(to bottom, #dca8c4 0 15px, #f5d2c8 15px 25px);
}

.forest-goal {
  position: relative;
  z-index: 3;
  width: 74%;
  min-height: 60px;
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 10px;
  align-items: center;
  margin: 0 auto 25px;
  padding: 10px 12px;
  border: 2px solid #b9daae;
  border-radius: 8px;
  background: #fffcec;
  box-shadow: 0 9px 0 rgba(109, 157, 95, 0.12);
  text-align: left;
}

.forest-goal.trailhead {
  margin-top: 8px;
  margin-bottom: 0;
  border-color: #f1ce8b;
  background: #fff5dc;
}

.goal-crown {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--sun);
  color: #775c16;
  animation: goal-glow 2.2s ease-in-out infinite;
}

.forest-goal b,
.forest-goal small {
  display: block;
}

.forest-goal b {
  font-size: 12px;
}

.forest-goal small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
}

.chapter-marker {
  display: grid;
  gap: 2px;
  margin: 12px auto 22px;
  padding: 7px 13px;
  border-color: #bcd8bc;
  background: #fffef8;
  color: var(--forest-700);
  text-align: center;
  box-shadow: 0 6px 0 rgba(74, 132, 91, 0.1);
}

.chapter-marker span {
  color: #75a27e;
  font-size: 8px;
}

.chapter-marker b {
  font-size: 11px;
}

.map-route.dessert .chapter-marker {
  border-color: #e4bcd1;
  color: #9b557e;
}

.map-step {
  position: relative;
  z-index: 2;
  width: 100%;
  min-height: 91px;
  margin-bottom: 18px;
  animation: forest-step-in 420ms cubic-bezier(.2, .78, .24, 1) both;
  animation-delay: var(--delay);
}

.map-step .map-stop {
  margin-bottom: 0;
}

.map-step.right .map-stop {
  margin-left: auto;
}

.map-stop {
  width: 79%;
  min-height: 91px;
  border-color: #d7e6d5;
  background: rgba(255, 254, 248, 0.97);
  box-shadow: 0 8px 0 rgba(78, 130, 91, 0.1), 0 13px 25px rgba(41, 91, 65, 0.08);
}

.map-stop:hover:not(:disabled) {
  transform: translateY(-2px) rotate(-.35deg);
  box-shadow: 0 10px 0 rgba(78, 130, 91, 0.1), 0 18px 28px rgba(41, 91, 65, 0.11);
}

.map-step.right .map-stop:hover:not(:disabled) {
  transform: translateY(-2px) rotate(.35deg);
}

.map-stop.cleared {
  border-color: #a9d5ad;
  background: #f6fff1;
}

.map-stop.available {
  border-color: var(--coral);
  background: #fffaf0;
  box-shadow: 0 8px 0 #ffd4c6, 0 16px 30px rgba(229, 99, 86, 0.16);
}

.map-stop.skipped {
  border-color: var(--sky);
  background: #f3fbff;
}

.map-stop.locked {
  border-color: #dae2d8;
  background: rgba(239, 243, 236, 0.94);
  box-shadow: 0 6px 0 rgba(93, 113, 101, 0.06);
}

.node-badge {
  border-color: #edf2df;
  background: #fff6d6;
}

.map-stop.cleared .node-badge {
  border-color: #d5edd5;
  background: #70bd83;
}

.map-stop.available .node-badge {
  border-color: #ffe0d8;
  color: var(--coral-dark);
}

.map-stop.available .node-badge::after {
  content: "";
  position: absolute;
  right: -4px;
  top: -6px;
  width: 14px;
  height: 9px;
  border-radius: 90% 10% 90% 10%;
  background: #79c77d;
  transform: rotate(-24deg);
}

.forest-prop {
  position: absolute;
  z-index: 3;
  bottom: 4px;
  width: 47px;
  height: 55px;
  pointer-events: none;
  transform-origin: 50% 100%;
  animation: prop-sway 3s ease-in-out infinite;
}

.map-step.left .forest-prop { right: 1px; }
.map-step.right .forest-prop { left: 1px; animation-delay: .55s; }

.forest-prop.sprout::before {
  content: "";
  position: absolute;
  left: 22px;
  bottom: 3px;
  width: 4px;
  height: 33px;
  border-radius: 999px;
  background: #5d9b65;
}

.forest-prop.sprout i,
.forest-prop.sprout b {
  position: absolute;
  width: 22px;
  height: 13px;
  border-radius: 90% 10% 90% 10%;
  background: #77c47a;
}

.forest-prop.sprout i { left: 3px; top: 18px; transform: rotate(26deg); }
.forest-prop.sprout b { right: 1px; top: 9px; transform: scaleX(-1) rotate(20deg); background: #97d47d; }

.forest-prop.mushroom::before {
  content: "";
  position: absolute;
  left: 17px;
  bottom: 3px;
  width: 18px;
  height: 25px;
  border-radius: 45% 45% 6px 6px;
  background: #fff0cf;
  border: 2px solid #d8b993;
}

.forest-prop.mushroom::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 6px;
  width: 43px;
  height: 27px;
  border: 2px solid #b95e62;
  border-radius: 50% 50% 30% 30%;
  background: #f3847f;
  box-shadow: inset 10px 2px 0 -6px #fff5d8, inset -11px 8px 0 -7px #fff5d8;
}

.forest-prop.flower::before {
  content: "";
  position: absolute;
  left: 19px;
  top: 12px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--sun);
  box-shadow: 0 -10px 0 #fff, 0 10px 0 #fff, -10px 0 0 #fff, 10px 0 0 #fff;
}

.forest-prop.flower::after {
  content: "";
  position: absolute;
  left: 24px;
  top: 28px;
  width: 4px;
  height: 25px;
  border-radius: 999px;
  background: #6daf6e;
}

.forest-prop.tree::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0;
  width: 42px;
  height: 46px;
  background: #65ad6f;
  clip-path: polygon(50% 0, 95% 45%, 71% 43%, 100% 78%, 63% 73%, 50% 100%, 37% 73%, 0 78%, 29% 43%, 5% 45%);
}

.forest-prop.tree::after {
  content: "";
  position: absolute;
  left: 21px;
  bottom: 0;
  width: 9px;
  height: 17px;
  border-radius: 3px;
  background: #9c724f;
}

.forest-prop.berries::before,
.forest-prop.berries::after,
.forest-prop.berries i {
  content: "";
  position: absolute;
  width: 17px;
  height: 17px;
  border: 2px solid #8f4a78;
  border-radius: 50%;
  background: #cc75a8;
}

.forest-prop.berries::before { left: 7px; top: 22px; }
.forest-prop.berries::after { right: 7px; top: 22px; }
.forest-prop.berries i { left: 15px; top: 10px; }

.forest-prop.berries b {
  position: absolute;
  left: 22px;
  top: 0;
  width: 4px;
  height: 18px;
  border-radius: 999px;
  background: #5d9867;
}

.segment {
  border-color: #d8e7d8;
  background: #edf5e9;
}

.segment button {
  border-radius: 8px;
}

.podium {
  position: relative;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.25), transparent 38%),
    linear-gradient(120deg, #79bd91, #82cbd9 56%, #b7a9e1);
}

.podium::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 52px;
  background: #6da87c;
  clip-path: polygon(0 41%, 9% 20%, 18% 45%, 28% 14%, 39% 48%, 50% 9%, 61% 46%, 74% 16%, 84% 43%, 93% 19%, 100% 40%, 100% 100%, 0 100%);
  opacity: .55;
}

.podium-person {
  position: relative;
  z-index: 1;
}

.podium-person.first .podium-avatar {
  animation: winner-bob 2s ease-in-out infinite;
}

.podium-block {
  border-radius: 8px 8px 0 0;
  background: rgba(255, 255, 255, 0.26);
}

.podium-person.first .podium-block {
  background: rgba(255, 218, 109, 0.38);
}

.my-rank {
  border-color: #f0d8bf;
  background: #fff5e7;
}

.my-rank-mark {
  background: var(--coral);
}

.rank-row:nth-child(3n + 1) .avatar { background: #dff2df; color: #39775a; }
.rank-row:nth-child(3n + 2) .avatar { background: #e6e1f7; color: #6d5e9c; }
.rank-row:nth-child(3n) .avatar { background: #dff2f7; color: #397a8d; }

.profile-hero {
  background:
    linear-gradient(130deg, rgba(255,255,255,.14), transparent 48%),
    linear-gradient(115deg, #3d8264, #65a97a 68%, #8bc888);
}

.profile-hero::before {
  content: "";
  position: absolute;
  left: -20px;
  bottom: -15px;
  width: 100px;
  height: 38px;
  border-radius: 50% 50% 0 0;
  background: rgba(255, 225, 130, 0.16);
  box-shadow: 75px 8px 0 rgba(202, 231, 176, 0.16), 170px -2px 0 rgba(255, 196, 174, 0.13);
}

.profile-avatar {
  position: relative;
  background: var(--sun);
  box-shadow: 0 7px 0 rgba(38, 96, 66, 0.2);
}

.profile-avatar::after {
  content: "";
  position: absolute;
  top: -5px;
  right: 6px;
  width: 15px;
  height: 9px;
  border-radius: 90% 10% 90% 10%;
  background: #dff1a8;
  transform: rotate(-25deg);
}

.level-chip {
  background: rgba(255, 239, 181, 0.2);
}

.profile-section:nth-of-type(3n + 1) .section-title-icon { background: #e1f2df; color: #438c68; }
.profile-section:nth-of-type(3n + 2) .section-title-icon { background: #f5e2ef; color: #a05b8b; }
.profile-section:nth-of-type(3n) .section-title-icon { background: #dff1f6; color: #3c8196; }

.badge-item.earned {
  background: #f1faec;
}

.badge-item.earned:nth-child(3n + 2) {
  border-color: #e8d6ee;
  background: #faf2fc;
  color: #8b659c;
}

.sticker-cell:not(.locked) {
  background: #fff8dd;
  animation: sticker-peek 2.7s ease-in-out infinite;
}

.sticker-cell:nth-child(3n + 2):not(.locked) { animation-delay: .35s; }
.sticker-cell:nth-child(3n):not(.locked) { animation-delay: .7s; }

.tabs {
  border-top-color: #dae7d8;
  background: #fffdf6;
}

.tabs button {
  border-radius: 8px;
  color: #8b978f;
}

.tabs button:hover {
  background: #edf6e9;
}

.tabs button.active {
  background: #e1f2dc;
  color: var(--forest-800);
  box-shadow: inset 0 0 0 1px #c3dfbf, 0 6px 16px rgba(53, 117, 77, 0.1);
}

.tabs button.active::before {
  top: 5px;
  height: 3px;
  background: var(--coral);
}

.tabs button.active svg {
  animation: nav-bob 1.8s ease-in-out infinite;
}

.modal {
  background: rgba(23, 60, 50, 0.7);
  backdrop-filter: blur(3px);
}

.sheet {
  background: #fffdf7;
}

.recipe-cover {
  background: linear-gradient(125deg, #dff2d7, #fff4cf 52%, #ffd9c9);
  color: var(--ink);
}

.recipe-cover.dessert {
  background: linear-gradient(125deg, #f3dbea, #fff2db 52%, #dfeaf8);
}

.primary {
  background: var(--forest-800);
}

@keyframes buddy-float {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-7px) rotate(1deg); }
}

@keyframes hat-wiggle {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(3deg) translateY(-2px); }
}

@keyframes buddy-blink {
  0%, 44%, 48%, 100% { transform: scaleY(1); }
  46% { transform: scaleY(.1); }
}

@keyframes spoon-wave {
  0%, 100% { transform: rotate(19deg); }
  50% { transform: rotate(5deg); }
}

@keyframes shadow-breathe {
  0%, 100% { transform: scaleX(1); opacity: .7; }
  50% { transform: scaleX(.78); opacity: .4; }
}

@keyframes dish-bob {
  0%, 100% { transform: translateY(0) rotate(3deg); }
  50% { transform: translateY(-4px) rotate(-3deg); }
}

@keyframes sparkle {
  0%, 100% { transform: scale(.65) rotate(0); opacity: .5; }
  50% { transform: scale(1.2) rotate(45deg); opacity: 1; }
}

@keyframes leaf-sway {
  0%, 100% { rotate: -7deg; }
  50% { rotate: 8deg; }
}

@keyframes cta-breathe {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -2px; }
}

@keyframes progress-shine {
  to { background-position: -180% 0; }
}

@keyframes reward-hop {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

@keyframes forest-step-in {
  from { opacity: 0; transform: translateY(16px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes prop-sway {
  0%, 100% { transform: rotate(-2deg); }
  50% { transform: rotate(3deg); }
}

@keyframes goal-glow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 214, 107, .3); }
  50% { box-shadow: 0 0 0 8px rgba(255, 214, 107, 0); }
}

@keyframes winner-bob {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-6px) rotate(1deg); }
}

@keyframes sticker-peek {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-2px); }
}

@keyframes nav-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

@media (max-width: 560px) {
  .page {
    padding: 0;
  }

  .page::before,
  .page::after {
    display: none;
  }

  .phone {
    width: 100%;
    height: 100dvh;
    min-height: 100dvh;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .modal {
    align-items: flex-end;
    padding: 0;
  }

  .sheet {
    width: 100%;
    max-height: 92dvh;
    border: 0;
    border-radius: 24px 24px 0 0;
  }

  .recipe-cover {
    border-radius: 24px 24px 0 0;
  }
}

@media (max-height: 730px) and (min-width: 561px) {
  .phone {
    min-height: 660px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
