/* Coinplastic pitch prototype
   Design system: design/Design Guide - Save a Seat for School.md
   Two moods, one system:
   - Kid-facing (cover + kid app): A Cleaner Planet mood, sticker style, black outlines, green and pink.
   - Company-facing (console + impact): Plastic Fisherman mood, clean teal and white, flat, lots of space.
   Readability rule: white text only on Deep Sea or Deep Pink. On Ocean Teal, Sky Blue, Leaf Green
   or Bloom Pink, use Ink text. */

:root {
  /* Brand colors */
  --ocean-teal: #2BAACA;
  --deep-sea:   #1B6F86;
  --sky-blue:   #56A7D8;
  --earth-blue: #4799CF;
  --leaf-green: #41B249;
  --forest:     #12552B;
  --bloom-pink: #E74D93;
  --deep-pink:  #C2306F;
  --ink:        #050708;
  --foam:       #E8F7FA;
  --white:      #FFFFFF;

  /* Cap-sorting colors (always in this order: Red · Yellow · Blue · White · Mixed) */
  --sort-red:    #E53935;
  --sort-yellow: #FDD835;
  --sort-blue:   #1E63D6;
  --sort-white:  #FFFFFF;
  --sort-mixed:  #9E9E9E;

  /* Supporting tints (derived, for surfaces only) */
  --foam-deep:  #D3EEF4;
  --leaf-tint:  #E3F5E4;
  --pink-tint:  #FCE4EF;
  --sun-tint:   #FFF6CC;
  --line:       #CFE6EC;
  --muted:      #4E5D63;   /* secondary text on white/Foam: ≥ 5:1 */

  /* Semantic */
  --bg-app: var(--foam);
  --surface: var(--white);
  --text: var(--ink);
  --text-secondary: var(--muted);
  --link: var(--deep-sea);
  --action-company: var(--deep-sea);
  --action-kid: var(--deep-pink);
  --success: var(--forest);

  /* Type */
  --font-head: "Bagel Fat One", "Arial Rounded MT Bold", system-ui, sans-serif;
  --font-label: "Chewy", "Comic Sans MS", system-ui, sans-serif;
  --font-body: "Nunito", ui-rounded, system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 20px;
  --outline: 2.5px solid var(--ink);
  --sticker-shadow: 4px 4px 0 var(--ink);

  /* White wave pattern for blue surfaces */
  --waves: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='48' viewBox='0 0 160 48'%3E%3Cpath d='M0 24 Q20 10 40 24 T80 24 T120 24 T160 24' fill='none' stroke='white' stroke-opacity='0.16' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--bg-app);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.45;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--deep-sea); outline-offset: 2px; border-radius: 10px; }

/* ---------- Bottle cap (points are shown as caps) ---------- */
.cap {
  --cap: var(--bloom-pink);
  display: inline-grid; place-items: center; border-radius: 50%;
  background: var(--cap); border: var(--outline);
  box-shadow: inset 0 0 0 4px var(--cap), inset 0 0 0 6px rgba(5, 7, 8, 0.25);
  color: var(--ink); font-weight: 900;
}

/* ---------- Top bar ---------- */
.topbar {
  height: 64px; display: flex; align-items: center; gap: 24px;
  padding: 0 28px; background: var(--white); border-bottom: 1px solid var(--line);
  position: relative; z-index: 5;
}
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-head); font-size: 22px; font-weight: 400; color: var(--deep-sea); }
.brand-mark {
  width: 32px; height: 32px; border-radius: 50%; background: var(--bloom-pink); border: var(--outline);
  display: grid; place-items: center; font-family: var(--font-head); font-size: 15px; color: var(--ink);
  box-shadow: inset 0 0 0 3px var(--bloom-pink), inset 0 0 0 5px rgba(5, 7, 8, 0.25);
}
.scene-nav { display: flex; gap: 6px; margin-left: 12px; }
.scene-nav button {
  background: transparent; border: 0; color: var(--muted);
  padding: 8px 16px; border-radius: 999px; font-weight: 800; font-size: 14px;
}
.scene-nav button:hover { color: var(--ink); background: var(--foam); }
.scene-nav button[aria-current="true"] { color: var(--white); background: var(--deep-sea); }
.scene-nav .num { opacity: 0.7; margin-right: 6px; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.chip-demo {
  font-size: 13px; font-weight: 800; color: var(--ink);
  background: var(--sun-tint); border: 1.5px solid var(--ink); padding: 4px 12px; border-radius: 999px;
}
.btn-ghost {
  background: var(--white); border: 1.5px solid var(--line); color: var(--muted);
  padding: 7px 14px; border-radius: 999px; font-size: 13px; font-weight: 800;
}
.btn-ghost:hover { color: var(--ink); border-color: var(--deep-sea); }

/* ---------- Scenes ---------- */
.stage { position: relative; height: calc(100vh - 64px); }
.scene {
  position: absolute; inset: 0; padding: 28px 40px;
  opacity: 0; visibility: hidden; transform: translateX(24px);
  transition: opacity 0.35s ease, transform 0.35s ease, visibility 0.35s;
  overflow-y: auto;
}
.scene.active { opacity: 1; visibility: visible; transform: none; }
h1, h2, .screen-title { font-family: var(--font-head); font-weight: 400; letter-spacing: 0.005em; }

/* ---------- Cover (kid-facing, key-visual mood: high-contrast blue and white with waves) ---------- */
.cover { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; padding: 0 72px; color: var(--white); }
.cover-sky { position: absolute; inset: 0; z-index: -1; background-color: var(--deep-sea); background-image: var(--waves); background-size: 160px 48px; }
.cover h1 { font-size: clamp(48px, 6vw, 88px); line-height: 1.02; margin: 0 0 24px; }
.cover h1 .grad {
  color: var(--ink); background: var(--bloom-pink); border: 3px solid var(--ink); border-radius: 22px;
  padding: 0 18px; display: inline-block; margin: 6px 0; transform: rotate(-2deg); box-shadow: 6px 6px 0 var(--ink);
}
.cover p.lede { font-size: clamp(18px, 1.5vw, 22px); max-width: 40ch; margin: 0 0 28px; font-weight: 600; }
.cover-steps { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 30px; }
.cover-steps span {
  background: var(--white); color: var(--ink); border: 2px solid var(--ink); padding: 8px 16px; border-radius: 999px;
  font-weight: 700; font-size: 15px;
}
.cover-steps span b { color: var(--deep-pink); }
.stripe-band { display: flex; gap: 12px; height: auto; }
.stripe-band .cap { width: 34px; height: 34px; }
.hint { margin-top: 20px; color: var(--foam); font-size: 14px; font-weight: 600; }
.kbd { display: inline-block; border: 1.5px solid var(--foam); border-bottom-width: 3px; border-radius: 7px; padding: 0 7px; font-size: 13px; color: var(--white); margin: 0 2px; font-weight: 800; }

.coin-hero { position: relative; display: grid; place-items: center; height: 520px; }
.coin-big {
  width: 300px; height: 300px; border-radius: 50%; background: var(--bloom-pink); border: 4px solid var(--ink);
  display: grid; place-items: center; position: relative; padding: 32px;
  box-shadow: 10px 10px 0 var(--ink), inset 0 0 0 16px var(--bloom-pink), inset 0 0 0 20px rgba(5, 7, 8, 0.28);
  animation: float 6s ease-in-out infinite;
}
.coin-big .coin-label { text-align: center; color: var(--ink); }
.coin-big .coin-label .pc { font-family: var(--font-head); font-size: 96px; line-height: 1; }
.coin-big .coin-label .sub { font-family: var(--font-label); font-size: 26px; margin-top: 4px; }
.orbit {
  position: absolute; border-radius: 999px; padding: 10px 18px; font-weight: 800; font-size: 16px;
  background: var(--white); color: var(--ink); border: 2.5px solid var(--ink); box-shadow: var(--sticker-shadow);
}
.orbit.o1 { top: 40px; left: 10px; animation: float 5s ease-in-out infinite 0.4s; }
.orbit.o2 { top: 90px; right: 0; animation: float 5.5s ease-in-out infinite 1s; }
.orbit.o3 { bottom: 60px; left: 30px; animation: float 6.5s ease-in-out infinite 0.2s; }
.orbit.o4 { bottom: 30px; right: 30px; animation: float 5.8s ease-in-out infinite 1.4s; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ---------- Kid scene ---------- */
.kid-scene { display: grid; grid-template-columns: 1fr auto 1fr; gap: 40px; align-items: center; }
.narration h2, .side-panel h2 { font-size: 34px; line-height: 1.1; margin: 0 0 18px; color: var(--ink); }
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.steps li {
  display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start;
  padding: 12px 14px; border-radius: 18px; border: 2.5px solid transparent; color: var(--muted);
  transition: background 0.25s, border-color 0.25s, color 0.25s;
}
.steps li .n {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 900;
  background: var(--white); border: 2px solid var(--line); color: var(--muted); font-size: 15px;
}
.steps li strong { display: block; color: var(--ink); font-size: 17px; font-weight: 800; margin-bottom: 2px; }
.steps li.current { background: var(--white); border-color: var(--ink); color: var(--ink); box-shadow: var(--sticker-shadow); }
.steps li.current .n { background: var(--leaf-green); border: 2px solid var(--ink); color: var(--ink); }
.steps li.done .n { background: var(--forest); border-color: var(--forest); color: var(--white); }
.steps li.done .n::after { content: "✓"; }
.steps li.done .n span { display: none; }

.side-panel { align-self: center; display: grid; gap: 14px; }
.presenter-box { border: 2px dashed var(--muted); border-radius: var(--radius); padding: 18px; background: var(--white); }
.presenter-box .label { font-family: var(--font-label); font-size: 20px; color: var(--deep-pink); margin-bottom: 6px; }
.presenter-box p { margin: 0 0 12px; color: var(--muted); font-size: 15px; }
.rule-card { background: var(--white); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 14px 18px; }
.rule-card .k { font-size: 14px; font-weight: 800; color: var(--deep-sea); }
.rule-card .v { font-size: 20px; font-weight: 900; margin-top: 2px; color: var(--ink); }
.rule-card .v small { display: block; font-size: 14px; font-weight: 600; color: var(--muted); margin-top: 2px; }

/* Phone */
.phone {
  --h: min(760px, calc(100vh - 64px - 56px));
  height: var(--h); width: calc(var(--h) * 0.49);
  border-radius: 46px; padding: 12px; background: var(--ink);
  box-shadow: 0 24px 48px rgba(5, 7, 8, 0.18);
  position: relative;
}
.phone-notch { position: absolute; top: 20px; left: 50%; transform: translateX(-50%); width: 110px; height: 28px; border-radius: 20px; background: var(--ink); z-index: 3; }
.screen { width: 100%; height: 100%; border-radius: 36px; overflow: hidden; position: relative; background: var(--white); display: flex; flex-direction: column; }
.statusbar { height: 46px; flex: none; display: flex; justify-content: space-between; align-items: flex-end; padding: 0 26px 6px; font-size: 13px; font-weight: 800; }
.app-body { flex: 1; overflow-y: auto; padding: 8px 18px 18px; scrollbar-width: none; }
.app-body::-webkit-scrollbar { display: none; }
.app-tabbar { flex: none; display: flex; justify-content: space-around; padding: 10px 8px 16px; border-top: 2px solid var(--ink); background: var(--white); }
.app-tabbar button { background: none; border: 0; display: grid; justify-items: center; gap: 2px; font-size: 11px; font-weight: 800; color: var(--muted); padding: 4px 8px; }
.app-tabbar button .ic { font-size: 20px; line-height: 1; }
.app-tabbar button[aria-current="true"] { color: var(--deep-pink); }

.app-header { display: flex; align-items: center; justify-content: space-between; margin: 4px 0 14px; }
.app-header .hello { font-size: 13px; color: var(--muted); font-weight: 700; }
.app-header .name { font-family: var(--font-label); font-size: 26px; line-height: 1.1; }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; background: var(--deep-pink); color: var(--white); border: 2px solid var(--ink); }
.back { background: none; border: 0; color: var(--deep-sea); font-weight: 800; padding: 4px 0; font-size: 15px; }
.screen-title { font-size: 24px; margin: 6px 0 4px; line-height: 1.15; }
.screen-sub { color: var(--muted); font-size: 14px; margin: 0 0 16px; }

.balance-card {
  border-radius: 22px; padding: 16px 18px; color: var(--ink); position: relative; overflow: hidden;
  background: var(--leaf-green); border: var(--outline); box-shadow: var(--sticker-shadow);
}
.balance-card::after {
  content: ""; position: absolute; right: 14px; top: 14px; width: 54px; height: 54px; border-radius: 50%;
  background: var(--bloom-pink); border: var(--outline);
  box-shadow: inset 0 0 0 4px var(--bloom-pink), inset 0 0 0 6px rgba(5, 7, 8, 0.25);
}
.balance-card .lbl { font-family: var(--font-label); font-size: 18px; }
.balance-card .amt { font-family: var(--font-head); font-size: 44px; line-height: 1.1; margin-top: 2px; }
.balance-card .amt small { font-family: var(--font-body); font-size: 16px; font-weight: 900; margin-left: 4px; }
.balance-card .meta { font-size: 13px; font-weight: 700; margin-top: 4px; }
.bump { animation: bump 0.6s ease; }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.06); } 100% { transform: scale(1); } }

.mini-wallets { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.mini { background: var(--white); border: 2px solid var(--ink); border-radius: 16px; padding: 10px 12px; }
.mini .t { font-size: 12px; font-weight: 800; color: var(--muted); }
.mini .v { font-size: 20px; font-weight: 900; }

.actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 18px 0 8px; }
.action {
  background: var(--white); border: 2px solid var(--ink); border-radius: 18px; padding: 12px 6px;
  display: grid; justify-items: center; gap: 6px; font-size: 13px; font-weight: 800; box-shadow: 3px 3px 0 var(--ink);
  transition: transform 0.1s, box-shadow 0.1s;
}
.action:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--ink); }
.action:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.action .ic { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-size: 20px; border: 2px solid var(--ink); }
.ic-magenta { background: var(--bloom-pink); }
.ic-indigo { background: var(--ocean-teal); }
.ic-ember { background: var(--leaf-green); }

.section-label { font-size: 14px; font-weight: 900; color: var(--ink); margin: 18px 0 8px; }
.history { display: grid; gap: 8px; }
.tx { display: grid; grid-template-columns: 36px 1fr auto; gap: 10px; align-items: center; background: var(--foam); border-radius: 16px; padding: 10px 12px; }
.tx .ic { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-size: 17px; background: var(--white); border: 1.5px solid var(--line); }
.tx .d { font-size: 14px; font-weight: 800; }
.tx .s { font-size: 12px; color: var(--muted); }
.tx .a { font-weight: 900; font-size: 14px; }
.tx .a.pos { color: var(--forest); }
.tx .a.neg { color: var(--ink); }
.tx .a.pend { color: var(--deep-pink); }

/* Round progress ring filling to 84 lb */
.ring-row { display: grid; grid-template-columns: 96px 1fr; gap: 14px; align-items: center; background: var(--leaf-tint); border-radius: 18px; padding: 12px; }
.ring {
  --p: 0; width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--leaf-green) calc(var(--p) * 1%), var(--white) 0);
  border: 2.5px solid var(--ink);
}
.ring > div { width: 66px; height: 66px; border-radius: 50%; background: var(--leaf-tint); border: 2px solid var(--ink); display: grid; place-items: center; text-align: center; line-height: 1.05; }
.ring b { font-size: 17px; font-weight: 900; }
.ring small { font-size: 10px; font-weight: 800; color: var(--forest); }
.ring-row .t { font-weight: 900; font-size: 15px; }
.ring-row .s { font-size: 12px; color: var(--muted); font-weight: 600; margin-top: 2px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 2.5px solid var(--ink); border-radius: 999px; padding: 13px 20px; font-weight: 900; font-size: 16px; width: 100%;
  background: var(--action-kid); color: var(--white); box-shadow: var(--sticker-shadow);
  transition: transform 0.1s, box-shadow 0.1s, background 0.2s;
}
.btn:hover { transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--ink); }
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }
.btn:disabled { background: var(--foam-deep); color: var(--muted); border-color: var(--line); box-shadow: none; cursor: not-allowed; transform: none; }
.btn.secondary { background: var(--white); color: var(--ink); }
.btn.teal { background: var(--deep-sea); }
.btn.small { width: auto; padding: 9px 16px; font-size: 14px; }

.counter-row { display: grid; grid-template-columns: 52px 1fr auto; gap: 12px; align-items: center; background: var(--white); border: 2px solid var(--ink); border-radius: 18px; padding: 12px; margin-bottom: 10px; }
.counter-row .ic { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; font-size: 26px; background: var(--foam); border: 2px solid var(--ink); }
.counter-row .t { font-weight: 900; }
.counter-row .s { font-size: 12px; color: var(--muted); }
.stepper { display: flex; align-items: center; gap: 8px; }
.stepper button { width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--ink); background: var(--white); font-size: 18px; font-weight: 900; line-height: 1; }
.stepper button:hover { background: var(--pink-tint); }
.stepper .val { min-width: 36px; text-align: center; font-size: 20px; font-weight: 900; }

.notice { border-radius: 16px; padding: 12px 14px; font-size: 13px; font-weight: 600; margin: 12px 0 16px; display: flex; gap: 10px; align-items: flex-start; color: var(--ink); }
.notice.info { background: var(--foam); }
.notice.warn { background: var(--sun-tint); }
.notice.ok { background: var(--leaf-tint); color: var(--forest); }

.qr-wrap { background: var(--white); border: var(--outline); border-radius: 20px; padding: 16px; display: grid; justify-items: center; margin: 4px 0 12px; }
.qr { display: grid; grid-template-columns: repeat(21, 1fr); width: 170px; height: 170px; }
.qr i { display: block; }
.qr i.on { background: var(--ink); }
.qr-id { color: var(--ink); font-weight: 900; font-size: 13px; margin-top: 10px; letter-spacing: 0.06em; }

.status-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 900; padding: 5px 10px; border-radius: 999px; border: 1.5px solid var(--ink); }
.status-pill.wait { background: var(--sun-tint); color: var(--ink); }
.status-pill.ok { background: var(--leaf-tint); color: var(--forest); }
.status-pill .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

.place { display: grid; grid-template-columns: 36px 1fr auto; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1.5px solid var(--line); font-size: 14px; }
.place:last-child { border-bottom: 0; }
.place .ic { font-size: 18px; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--foam); }
.place .s { font-size: 12px; color: var(--muted); }
.place .km { font-size: 12px; font-weight: 900; color: var(--deep-sea); }

.success-burst { text-align: center; padding: 24px 0 8px; }
.burst-coin {
  width: 120px; height: 120px; border-radius: 50%; margin: 0 auto 16px; background: var(--bloom-pink); border: 3px solid var(--ink);
  display: grid; place-items: center; color: var(--ink); font-family: var(--font-head); font-size: 32px;
  box-shadow: 6px 6px 0 var(--ink), inset 0 0 0 8px var(--bloom-pink), inset 0 0 0 11px rgba(5, 7, 8, 0.25);
  animation: pop 0.7s cubic-bezier(.2, 1.6, .4, 1) both;
}
.burst-coin.on-dark { color: var(--white); }
@keyframes pop { from { transform: scale(0.2) rotate(-30deg); opacity: 0; } to { transform: none; opacity: 1; } }
.success-burst .big { font-family: var(--font-head); font-size: 32px; line-height: 1.1; }
.success-burst .big.pos { color: var(--forest); }

.reward { width: 100%; text-align: left; display: grid; grid-template-columns: 46px 1fr; gap: 12px; align-items: center; background: var(--white); border: 2px solid var(--line); border-radius: 18px; padding: 12px; margin-bottom: 10px; }
.reward:hover { border-color: var(--ink); }
.reward[aria-pressed="true"] { border-color: var(--ink); background: var(--pink-tint); box-shadow: 3px 3px 0 var(--ink); }
.reward .logo { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 13px; color: var(--white); border: 2px solid var(--ink); }
.reward .t { font-weight: 900; }
.reward .s { font-size: 12px; color: var(--muted); }
.reward .rate { font-size: 12px; font-weight: 900; color: var(--deep-pink); margin-top: 2px; }
.logo.rbx { background: var(--deep-sea); }
.logo.gift { background: var(--bloom-pink); color: var(--ink); }
.logo.wmt { background: var(--forest); }

.swap-calc { background: var(--foam); border-radius: 18px; padding: 14px; margin: 6px 0 14px; display: grid; gap: 10px; }
.swap-calc .row { display: flex; justify-content: space-between; align-items: center; }
.swap-calc .row .l { color: var(--muted); font-size: 13px; font-weight: 800; }
.swap-calc .arrow { text-align: center; color: var(--deep-sea); font-weight: 900; }
.swap-calc .out { font-size: 20px; font-weight: 900; color: var(--deep-pink); }

.friends { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.friend { background: var(--white); border: 2px solid var(--line); border-radius: 18px; padding: 12px 6px; display: grid; justify-items: center; gap: 6px; font-size: 13px; font-weight: 800; }
.friend[aria-pressed="true"] { border-color: var(--ink); background: var(--pink-tint); box-shadow: 3px 3px 0 var(--ink); }
.friend .avatar { width: 44px; height: 44px; }

/* ---------- Company console (Plastic Fisherman mood: clean teal and white, flat) ---------- */
.partner-scene { display: grid; grid-template-rows: auto 1fr; gap: 20px; }
.console-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.console-head h2 { font-size: 38px; margin: 0; color: var(--deep-sea); line-height: 1.1; }
.console-head p { margin: 6px 0 0; color: var(--muted); max-width: 80ch; }
.console-head p.example-note { color: var(--ink); font-weight: 700; font-size: 14px; background: var(--sun-tint); display: inline-block; padding: 4px 12px; border-radius: 999px; max-width: none; }
.partner-switch { display: flex; gap: 4px; background: var(--white); padding: 5px; border-radius: 999px; border: 1.5px solid var(--line); }
.partner-switch button { border: 0; background: none; padding: 9px 18px; border-radius: 999px; font-weight: 800; color: var(--muted); }
.partner-switch button[aria-pressed="true"] { background: var(--deep-sea); color: var(--white); }

.grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 18px; min-height: 0; }
.card { background: var(--white); border-radius: 24px; padding: 22px 24px; min-width: 0; }
.card h3 { margin: 0 0 6px; font-size: 15px; font-weight: 900; color: var(--deep-sea); }
.card .big { font-size: 40px; font-weight: 900; line-height: 1.1; color: var(--ink); }
.card .delta { color: var(--forest); font-weight: 800; font-size: 14px; }
.card .note { color: var(--muted); font-size: 14px; margin-top: 6px; }
.span-3 { grid-column: span 3; } .span-4 { grid-column: span 4; } .span-5 { grid-column: span 5; }
.span-6 { grid-column: span 6; } .span-7 { grid-column: span 7; } .span-8 { grid-column: span 8; }

.coin-id { display: flex; align-items: center; gap: 14px; margin: 10px 0 16px; }
.coin-id .badge { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; color: var(--white); font-size: 15px; }
.coin-id .nm { font-size: 22px; font-weight: 900; }
.coin-id .tk { font-size: 13px; color: var(--muted); }
.rate-box { background: var(--foam); border-radius: 20px; padding: 16px; }
.rate-line { font-size: 26px; font-weight: 900; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.rate-line .eq { color: var(--muted); font-weight: 800; }
.rate-line .hot { color: var(--deep-sea); }
input[type="range"] { width: 100%; accent-color: var(--deep-sea); margin: 14px 0 4px; height: 24px; }
.range-legend { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); font-weight: 700; }
.live-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 900; color: var(--forest); margin-top: 10px; }
.live-tag .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

.bars { display: flex; align-items: flex-end; gap: 10px; height: 150px; margin-top: 14px; padding-bottom: 22px; position: relative; }
.bars .bar { flex: 1; background: var(--sky-blue); border-radius: 10px 10px 4px 4px; position: relative; transition: height 0.6s cubic-bezier(.2,.8,.2,1); min-height: 4px; }
.bars .bar:last-child { background: var(--deep-sea); }
.bars .bar span { position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%); font-size: 11px; color: var(--muted); font-weight: 800; white-space: nowrap; }
.bars .bar em { position: absolute; top: -20px; left: 50%; transform: translateX(-50%); font-size: 11px; font-style: normal; color: var(--ink); font-weight: 900; white-space: nowrap; }

.gc-row { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1.5px solid var(--foam-deep); }
.gc-row:last-child { border-bottom: 0; }
.gc-row .t { font-weight: 900; }
.gc-row .s { font-size: 13px; color: var(--muted); }
.seg { display: inline-flex; background: var(--foam); border-radius: 999px; padding: 3px; }
.seg button { border: 0; background: none; padding: 6px 12px; border-radius: 999px; font-size: 12px; font-weight: 900; color: var(--muted); }
.seg button[aria-pressed="true"] { background: var(--deep-sea); color: var(--white); }

.progress { height: 14px; border-radius: 999px; background: var(--foam); overflow: hidden; margin: 14px 0 8px; }
.progress > div { height: 100%; background: var(--sky-blue); border-radius: 999px; transition: width 0.8s cubic-bezier(.2,.8,.2,1); }
.donate-meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); font-weight: 700; margin-bottom: 14px; }

/* Company buttons: flat Deep Sea pills, no sticker outline */
.partner-scene .btn { background: var(--action-company); border-color: var(--action-company); box-shadow: none; }
.partner-scene .btn:hover { background: #155A6D; transform: none; box-shadow: none; }
.partner-scene .btn:active { transform: scale(0.98); }

/* ---------- Impact ---------- */
.impact-scene { display: grid; grid-template-rows: auto auto 1fr; gap: 22px; }
.impact-scene h2 { font-size: 42px; margin: 0; color: var(--deep-sea); line-height: 1.1; }
.kpis { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.kpi { background: var(--white); border-radius: 24px; padding: 20px; }
.kpi .v { font-size: clamp(28px, 2.6vw, 42px); font-weight: 900; line-height: 1.1; color: var(--ink); }
.kpi .l { color: var(--muted); font-weight: 800; font-size: 14px; margin-top: 4px; }
.loop-card { background: var(--white); border-radius: 28px; padding: 18px 24px; display: grid; grid-template-columns: 1fr 300px; gap: 24px; align-items: center; min-height: 0; }
.loop-card svg { width: 100%; height: auto; max-height: calc(100vh - 64px - 330px); }
.loop-card .why h3 { font-family: var(--font-head); font-weight: 400; font-size: 24px; margin: 0 0 12px; color: var(--deep-sea); }
.loop-card .why ul { margin: 0; padding-left: 20px; color: var(--muted); display: grid; gap: 8px; }
.loop-card .why li strong { color: var(--ink); }

/* ---------- Toast ---------- */
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 20px); opacity: 0;
  background: var(--ink); color: var(--white); padding: 12px 20px; border-radius: 999px; font-weight: 800;
  transition: opacity 0.25s, transform 0.25s; z-index: 50; pointer-events: none;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Company console on typical laptop heights (≤ 940px) ---------- */
@media (max-height: 940px) {
  .partner-scene { gap: 14px; }
  .console-head h2 { font-size: 32px; }
  .console-head p { margin-top: 4px; }
  .grid { gap: 14px; }
  .card { padding: 16px 20px; }
  .card .big { font-size: 34px; }
  .coin-id { margin: 6px 0 12px; }
  .bars { height: 120px; }
  .gc-row { padding: 8px 0; }
}

/* ---------- Short laptop screens (e.g. 1280×720 projectors) ---------- */
@media (max-height: 820px) {
  .scene { padding: 18px 32px; }
  .narration h2, .side-panel h2 { font-size: 26px; margin: 0 0 10px; }
  .steps { gap: 4px; }
  .steps li { padding: 7px 10px; font-size: 14px; grid-template-columns: 28px 1fr; }
  .steps li strong { font-size: 15px; }
  .steps li .n { width: 28px; height: 28px; font-size: 13px; }
  .side-panel { gap: 10px; }
  .presenter-box, .rule-card { padding: 11px 14px; }
  .rule-card .v { font-size: 17px; }
  .partner-scene { gap: 12px; }
  .console-head h2 { font-size: 28px; }
  .console-head p { font-size: 14px; }
  .grid { gap: 12px; }
  .card { padding: 14px 16px; border-radius: 18px; }
  .card .big { font-size: 30px; }
  .card .note { font-size: 13px; margin-top: 3px; }
  .coin-id { margin: 6px 0 10px; }
  .coin-id .badge { width: 46px; height: 46px; font-size: 14px; }
  .rate-box { padding: 12px; }
  .rate-line { font-size: 22px; }
  .bars { height: 110px; }
  .gc-row { padding: 7px 0; }
  .progress { margin: 10px 0 6px; }
  .donate-meta { margin-bottom: 10px; }
  .impact-scene { gap: 14px; }
  .impact-scene h2 { font-size: 32px; }
  .kpi { padding: 14px 16px; }
  .loop-card svg { max-height: calc(100vh - 64px - 260px); }
}

.presenter-row { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- Cap events: calendar + map (kid side, sticker style) ---------- */
.ev-next { width: 100%; border: 0; text-align: left; }
.ev-next .a { font-size: 12px; font-weight: 900; color: var(--deep-sea); }
.day-strip { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -18px 12px; padding: 2px 18px 4px; }
.day-strip::-webkit-scrollbar { display: none; }
.day {
  flex: none; width: 46px; display: grid; justify-items: center; gap: 0; padding: 6px 0 4px;
  background: var(--white); border: 2px solid var(--line); border-radius: 14px; font-weight: 800;
}
.day .dow { font-size: 10px; color: var(--muted); }
.day .num { font-size: 16px; font-weight: 900; line-height: 1.2; }
.day .dots { font-size: 12px; line-height: 0.8; color: var(--deep-pink); letter-spacing: 1px; }
.day:disabled { opacity: 0.45; cursor: default; }
.day[aria-pressed="true"] { border-color: var(--ink); background: var(--pink-tint); box-shadow: 2px 2px 0 var(--ink); }
.ev-map { position: relative; aspect-ratio: 320 / 190; border: var(--outline); border-radius: 18px; overflow: hidden; box-shadow: 3px 3px 0 var(--ink); }
.ev-map svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pin {
  position: absolute; transform: translate(-50%, -50%); width: 28px; height: 28px; padding: 0;
  border-radius: 50%; border: 2px solid var(--ink); background: var(--pin); color: var(--pin-ink);
  display: grid; place-items: center; font-size: 13px; line-height: 1; box-shadow: 2px 2px 0 var(--ink);
  transition: transform 0.15s ease;
}
.pin:hover { transform: translate(-50%, -50%) scale(1.1); }
.pin.sel { width: 36px; height: 36px; font-size: 17px; z-index: 2; }
.pin.sel::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; border: 2px solid var(--pin); animation: pinPulse 1.6s ease-out infinite; }
@keyframes pinPulse { from { transform: scale(0.8); opacity: 1; } to { transform: scale(1.5); opacity: 0; } }
.you { position: absolute; transform: translate(-50%, -50%); width: 14px; height: 14px; border-radius: 50%; background: var(--sort-blue); border: 3px solid var(--white); box-shadow: 0 0 0 2px var(--sort-blue); }
.ev-legend { display: flex; gap: 12px; font-size: 11px; font-weight: 800; color: var(--muted); margin: 8px 2px 0; }
.ev-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; border: 1.5px solid var(--ink); margin-right: 4px; vertical-align: -1px; }
.ev-list { display: grid; gap: 8px; }
.ev-row {
  width: 100%; text-align: left; display: grid; grid-template-columns: 36px 1fr auto; gap: 10px; align-items: center;
  background: var(--white); border: 2px solid var(--line); border-radius: 16px; padding: 10px 12px;
}
.ev-row:hover, .ev-row.sel { border-color: var(--ink); }
.ev-row .t { font-size: 14px; font-weight: 900; }
.ev-row .s { font-size: 12px; color: var(--muted); }
.ev-row .lb { font-size: 12px; font-weight: 900; color: var(--deep-sea); white-space: nowrap; }
.ev-ic { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-size: 17px; background: var(--pin); color: var(--pin-ink); border: 2px solid var(--ink); }
.ev-ic.big { width: 56px; height: 56px; font-size: 28px; box-shadow: 3px 3px 0 var(--ink); }
.ev-hero { display: flex; align-items: center; gap: 12px; margin: 8px 0 2px; }
.ev-hero .status-pill { background: var(--pin); color: var(--pin-ink); }
.ev-facts { display: grid; gap: 0; background: var(--foam); border-radius: 16px; padding: 4px 14px; margin-bottom: 4px; }
.ev-facts > div { display: grid; grid-template-columns: 1fr auto; gap: 10px; padding: 9px 0; font-size: 13px; font-weight: 800; border-bottom: 1.5px solid var(--line); }
.ev-facts > div:last-child { border-bottom: 0; }
.ev-facts .k { color: var(--muted); font-weight: 700; }
.ev-facts > div > span:last-child { text-align: right; }

/* ---------- Client logos (real files in assets/logos/; dashed placeholder until added) ---------- */
.logo-slot { display: inline-flex; align-items: center; height: var(--logo-h, 44px); }
.logo-slot img { height: 100%; width: auto; display: block; }
.logo-slot.missing img { display: none; }
.logo-slot.missing::after {
  content: attr(data-name) " logo"; display: inline-flex; align-items: center; height: 100%;
  padding: 0 12px; border: 1.5px dashed var(--muted); border-radius: 999px;
  font-size: 12px; font-weight: 800; color: var(--muted); white-space: nowrap;
}
.client-logos, .cover-logos, .footer-logos { display: flex; align-items: center; gap: 14px; }
.client-logos { --logo-h: 64px; background: var(--white); border-radius: 999px; padding: 10px 18px; }
.cover-foot { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 16px; }
.cover-foot .stripe-band { margin: 0; }
.cover-logos { --logo-h: 40px; background: var(--white); border-radius: 999px; padding: 6px 12px; width: max-content; }
.footer-logos { --logo-h: 24px; position: absolute; left: 20px; top: 50%; transform: translateY(-50%); gap: 10px; }
.footer-logos .logo-slot.missing::after { font-size: 10px; padding: 0 8px; }

/* ---------- Marketplace (company-facing: flat teal and white) ---------- */
.market-scene { display: grid; grid-template-rows: auto 1fr; gap: 18px; }
.market-head { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.market-head .eyebrow { font-size: 14px; font-weight: 900; color: var(--deep-sea); }
.market-head h2 { font-size: 40px; margin: 2px 0 4px; color: var(--deep-sea); line-height: 1.1; }
.market-head p { margin: 0; color: var(--muted); max-width: 720px; }
.market-grid { align-items: start; }
.market-scene .btn { background: var(--action-company); border-color: var(--action-company); box-shadow: none; }
.market-scene .btn:hover { background: #155A6D; transform: none; box-shadow: none; }
.product-line { display: flex; justify-content: space-between; align-items: baseline; font-size: 17px; margin-top: 4px; }
.product-line .price { font-size: 26px; font-weight: 900; color: var(--ink); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field { display: grid; gap: 4px; margin-top: 12px; }
.field > span { font-size: 13px; font-weight: 800; color: var(--muted); }
.field input, .field select {
  font: inherit; font-size: 15px; font-weight: 700; color: var(--ink); background: var(--foam);
  border: 1.5px solid var(--line); border-radius: 12px; padding: 8px 12px; width: 100%; min-width: 0;
}
.field input:focus, .field select:focus { outline: 3px solid var(--deep-sea); outline-offset: 1px; }
.color-pick { display: flex; gap: 8px; align-items: center; height: 40px; }
.color-pick button { width: 30px; height: 30px; border-radius: 50%; background: var(--sw); border: 2px solid var(--ink); padding: 0; }
.color-pick button[aria-checked="true"] { box-shadow: 0 0 0 3px var(--white), 0 0 0 5px var(--deep-sea); }
.plaque {
  margin: 6px 0 14px; padding: 12px 16px; border-radius: 10px; text-align: center;
  background: linear-gradient(135deg, #F4F7F8, #DCE4E7); border: 2px solid var(--ink);
  box-shadow: inset 0 0 0 4px #F4F7F8, inset 0 0 0 5px rgba(5, 7, 8, 0.25);
}
.plaque .pl-top { font-size: 11px; font-weight: 900; letter-spacing: 0.12em; text-transform: uppercase; color: var(--deep-sea); }
.plaque .pl-school { font-family: var(--font-head); font-size: 22px; line-height: 1.15; color: var(--ink); margin: 2px 0; overflow-wrap: anywhere; }
.plaque .pl-line { font-size: 14px; font-weight: 800; color: var(--ink); }
.plaque .pl-by { font-size: 12px; font-weight: 700; color: var(--muted); margin-top: 2px; }
.note.fine { font-size: 12px; margin-top: 8px; }

.track-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.track-head h3 { margin: 0; }
.tag-demo { font-size: 11px; font-weight: 800; color: var(--ink); background: var(--sun-tint); border-radius: 999px; padding: 2px 8px; margin-left: 6px; vertical-align: 2px; }
.pledge-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.pledge-tabs button { display: inline-flex; align-items: center; gap: 6px; border: 1.5px solid var(--line); background: var(--white); border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 800; color: var(--muted); }
.pledge-tabs button i { width: 10px; height: 10px; border-radius: 50%; border: 1.5px solid var(--ink); }
.pledge-tabs button[aria-pressed="true"] { background: var(--deep-sea); border-color: var(--deep-sea); color: var(--white); }
.track-top { margin-top: 14px; }
.track-title { font-size: 22px; font-weight: 900; color: var(--ink); }
.track-title .pct { font-size: 14px; font-weight: 900; color: var(--white); background: var(--deep-sea); border-radius: 999px; padding: 3px 10px; margin-left: 6px; vertical-align: 3px; }
.track-body { display: grid; grid-template-columns: 1.25fr 1fr; gap: 18px; align-items: center; margin-top: 10px; }
.bench-wrap { background: var(--foam); border-radius: 18px; padding: 14px 16px 8px; }
.bench-svg { width: 100%; height: auto; display: block; max-height: 190px; }
.track-stats { display: grid; gap: 10px; }
.track-stats > div { display: grid; border-bottom: 1.5px solid var(--foam-deep); padding-bottom: 8px; }
.track-stats > div:last-child { border-bottom: 0; }
.track-stats .k { font-size: 13px; font-weight: 800; color: var(--muted); }
.track-stats b { font-size: 26px; font-weight: 900; line-height: 1.15; }
.track-stats b small { font-size: 14px; color: var(--muted); }
.track-stats .s { font-size: 12px; color: var(--muted); }
.beam-row { display: grid; grid-template-columns: repeat(17, 1fr); gap: 4px; margin: 12px 0 4px; }
.beam-row i { height: 10px; border-radius: 4px; background: var(--foam-deep); }
.beam-row i.on { background: var(--b); box-shadow: inset 0 0 0 1.5px var(--ink); }
.stages { list-style: none; margin: 12px 0 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; position: relative; }
.stages li { display: grid; justify-items: center; text-align: center; gap: 2px; position: relative; }
.stages li::before { content: ""; position: absolute; top: 14px; left: -50%; right: 50%; height: 3px; background: var(--foam-deep); z-index: 0; }
.stages li:first-child::before { display: none; }
.stages li.done::before, .stages li.current::before { background: var(--deep-sea); }
.stages .dot { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 900; background: var(--white); border: 2px solid var(--line); color: var(--muted); position: relative; z-index: 1; }
.stages li.done .dot { background: var(--deep-sea); border-color: var(--deep-sea); color: var(--white); }
.stages li.current .dot { border-color: var(--deep-sea); color: var(--deep-sea); box-shadow: 0 0 0 4px var(--foam-deep); }
.stages .t { font-size: 12px; font-weight: 900; color: var(--ink); line-height: 1.2; }
.stages .s { font-size: 11px; color: var(--muted); line-height: 1.2; }
.demo-controls { display: flex; align-items: center; gap: 8px; margin-top: 14px; padding-top: 12px; border-top: 1.5px dashed var(--line); font-size: 13px; font-weight: 800; color: var(--muted); flex-wrap: wrap; }
.demo-controls .btn-ghost:disabled { opacity: 0.45; cursor: default; }
@media (max-height: 820px) {
  .market-head h2 { font-size: 30px; }
  .client-logos { --logo-h: 48px; padding: 8px 14px; }
  .field { margin-top: 8px; }
  .plaque { padding: 8px 12px; margin: 4px 0 10px; }
  .plaque .pl-school { font-size: 18px; }
  .bench-svg { max-height: 140px; }
  .track-stats b { font-size: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
