/* ─────────────────────────────────────────────────────────────────────────
 * Vibramood · brand.css
 * Soft, hand-drawn-feeling SEL game for kids.
 * Aqua + Sage + Sand palette, with gentle paper texture and big rounded shapes.
 * ───────────────────────────────────────────────────────────────────────── */

:root {
  --vm-aqua:        #4FB7C7;
  --vm-aqua-700:    #3C8C99;
  --vm-aqua-200:    #BEE4EA;
  --vm-aqua-50:     #ECF7F9;

  --vm-sage:        #9CB58F;
  --vm-sage-700:    #6f8a64;
  --vm-sage-200:    #d2dccd;
  --vm-sage-50:     #f0f4ed;

  --vm-sand:        #E8D5B0;
  --vm-sand-700:    #c4a878;
  --vm-sand-50:     #fbf6ec;

  --vm-cream:       #FBF7EF;
  --vm-paper:       #FAF3E2;
  --vm-ink:         #2A3B47;
  --vm-ink-500:     #5d7785;
  --vm-ink-300:     #aab8c1;

  /* Reuse mobile-shell brand variables so .wm-btn.brand etc. look right. */
  --brand:      var(--vm-aqua);
  --brand-600:  var(--vm-aqua);
  --brand-700:  var(--vm-aqua-700);
  --brand-100:  var(--vm-aqua-200);
  --brand-50:   var(--vm-aqua-50);
}

/* App-wide soft cream surface */
.wm-app[data-vm] { background: var(--vm-cream); }
.wm-app[data-vm] .wm-header { background: rgba(251, 247, 239, .82); border-bottom-color: transparent; }
.wm-app[data-vm] .wm-tabs   { background: rgba(251, 247, 239, .95); border-top-color: rgba(0,0,0,.05); }
.wm-app[data-vm] .wm-tab.active { color: var(--vm-aqua-700); }
.wm-app[data-vm] .wm-h1, .wm-app[data-vm] .wm-h2 { color: var(--vm-ink); font-family: 'Fraunces', serif; }
.wm-app[data-vm] .wm-eyebrow { color: var(--vm-ink-500); }
.wm-app[data-vm] .wm-muted   { color: var(--vm-ink-500); }

/* ─── Header bits ─── */
.vm-hd {
  display: flex; align-items: center; gap: 10px;
  width: 100%;
}
.vm-hd-avatar {
  width: 36px; height: 36px; border-radius: 999px;
  background: linear-gradient(135deg, var(--vm-aqua-200), var(--vm-aqua));
  display: grid; place-items: center; flex: 0 0 36px;
  box-shadow: inset 0 -2px 4px rgba(0,0,0,.08), 0 2px 6px rgba(60,140,153,.18);
}
.vm-hd-meta { flex: 1; min-width: 0; }
.vm-hd-meta .name { font: 700 14px/1.1 'Quicksand', sans-serif; color: var(--vm-ink); }
.vm-hd-meta .sub  { font: 500 11px/1.2 'Inter', sans-serif; color: var(--vm-ink-500); margin-top: 2px; }
.vm-hd-chips { display: flex; gap: 6px; align-items: center; }
.vm-pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 5px 9px; border-radius: 999px;
  background: var(--vm-paper);
  border: 1px solid rgba(196, 168, 120, .35);
  font: 700 11px/1 'Quicksand', sans-serif;
  color: var(--vm-sand-700);
}
.vm-pill.aqua { background: var(--vm-aqua-50); border-color: var(--vm-aqua-200); color: var(--vm-aqua-700); }
.vm-pill.sage { background: var(--vm-sage-50); border-color: var(--vm-sage-200); color: var(--vm-sage-700); }
.vm-pill .dot { width: 6px; height: 6px; border-radius: 999px; background: currentColor; }
.vm-pill .num { font-variant-numeric: tabular-nums; font-weight: 800; }
.vm-pill svg  { color: currentColor; }

/* Soundwave indicator */
.vm-wave {
  width: 22px; height: 14px;
  display: inline-flex; align-items: flex-end; gap: 2px;
}
.vm-wave i {
  width: 3px; border-radius: 2px; background: currentColor; opacity: .9;
  animation: vmwave 1100ms ease-in-out infinite;
}
.vm-wave i:nth-child(1) { height: 50%; animation-delay: 0ms; }
.vm-wave i:nth-child(2) { height: 90%; animation-delay: 140ms; }
.vm-wave i:nth-child(3) { height: 65%; animation-delay: 280ms; }
.vm-wave i:nth-child(4) { height: 80%; animation-delay: 420ms; }
.vm-wave.off i { animation: none; height: 30%; opacity: .35; }
@keyframes vmwave {
  0%, 100% { transform: scaleY(.5); }
  50%      { transform: scaleY(1); }
}
@media (prefers-reduced-motion: reduce) {
  .vm-wave i { animation: none; }
}

/* ─── Mood orbs (Check-in) ─── */
.vm-checkin-hero {
  position: relative;
  padding: 18px 18px 8px;
  background: linear-gradient(180deg, #f6efde 0%, var(--vm-cream) 70%);
  border-radius: 24px;
  overflow: hidden;
  text-align: center;
}
.vm-checkin-hero::after {
  content: ''; position: absolute; right: -20px; top: -20px;
  width: 110px; height: 110px; border-radius: 999px;
  background: radial-gradient(circle, #ffd98a 0%, #ffd98a 50%, transparent 70%);
  opacity: .55; pointer-events: none;
}
.vm-checkin-hero .greeting { font: 700 13px/1.2 'Quicksand', sans-serif; color: var(--vm-sand-700); letter-spacing: .04em; }
.vm-checkin-hero .ask { font: 600 24px/1.2 'Fraunces', serif; color: var(--vm-ink); margin-top: 4px; }

.vm-mood-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.vm-mood {
  position: relative;
  background: var(--vm-cream);
  border: 1.5px solid rgba(0,0,0,.06);
  border-radius: 22px;
  padding: 14px 8px 12px;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.vm-mood:active { transform: scale(.96); }
.vm-mood .face { width: 64px; height: 64px; }
.vm-mood .label { font: 700 14px/1 'Quicksand', sans-serif; color: var(--vm-ink); }
.vm-mood .help  { font: 500 11px/1.2 'Inter', sans-serif; color: var(--vm-ink-500); }
.vm-mood.active {
  transform: scale(1.04);
  box-shadow: 0 14px 30px -10px rgba(60, 140, 153, .35), 0 4px 10px rgba(0,0,0,.06);
  border-color: var(--vm-aqua-200);
  background: #fff;
}
.vm-mood.active::after {
  content: '';
  position: absolute; inset: -1.5px;
  border-radius: 22px;
  border: 2.5px solid var(--mood-color, var(--vm-aqua));
  pointer-events: none;
}

.vm-intensity {
  background: #fff;
  border: 1px solid rgba(0,0,0,.06);
  border-radius: 20px;
  padding: 16px 18px;
  display: flex; flex-direction: column; gap: 10px;
}
.vm-intensity .row { display: flex; justify-content: space-between; align-items: center; }
.vm-intensity .row .lbl { font: 700 13px/1 'Quicksand', sans-serif; color: var(--vm-ink); }
.vm-intensity .row .val { font: 700 13px/1 'Quicksand', sans-serif; color: var(--mood-color, var(--vm-aqua-700)); }
.vm-intensity .track {
  position: relative; height: 10px; border-radius: 999px;
  background: var(--vm-sand-50);
  border: 1px solid rgba(196, 168, 120, .3);
}
.vm-intensity .track .fill {
  position: absolute; left: 0; top: 0; bottom: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--mood-color, var(--vm-aqua-200)), var(--mood-color, var(--vm-aqua)));
  width: var(--pct, 50%);
}
.vm-intensity .track .knob {
  position: absolute; top: 50%; transform: translate(-50%, -50%);
  left: var(--pct, 50%);
  width: 22px; height: 22px; border-radius: 999px;
  background: #fff;
  border: 3px solid var(--mood-color, var(--vm-aqua));
  box-shadow: 0 2px 6px rgba(0,0,0,.16);
}
.vm-intensity .ticks { display: flex; justify-content: space-between; font: 500 11px/1 'Inter', sans-serif; color: var(--vm-ink-500); }

/* ─── Onboarding ─── */
.vm-onboard {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 16px;
  padding: 12px 4px 4px;
}
.vm-onboard .eyebrow { font: 700 11px/1 'Quicksand', sans-serif; color: var(--vm-sand-700); letter-spacing: .14em; text-transform: uppercase; }
.vm-onboard h1 { font: 600 26px/1.18 'Fraunces', serif; color: var(--vm-ink); margin: 0; max-width: 320px; }
.vm-onboard p  { font: 500 14px/1.45 'Inter', sans-serif; color: var(--vm-ink-500); margin: 0; max-width: 320px; }

.vm-vibra-carousel {
  display: flex; gap: 8px; padding: 6px 8px 12px;
  width: 100%; justify-content: center; align-items: flex-end;
}
.vm-vibra-slot {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 6px; border-radius: 18px;
  cursor: pointer;
  transition: transform .2s ease;
  opacity: .55; filter: saturate(.8);
}
.vm-vibra-slot.active { opacity: 1; filter: none; transform: translateY(-6px); }
.vm-vibra-slot .name { font: 700 12px/1 'Quicksand', sans-serif; color: var(--vm-ink); }

.vm-name-field {
  width: 100%; max-width: 320px;
  background: #fff;
  border: 1.5px solid rgba(0,0,0,.08);
  border-radius: 16px;
  padding: 14px 16px;
  display: flex; align-items: center; gap: 10px;
}
.vm-name-field input {
  border: 0; outline: 0; flex: 1; min-width: 0;
  font: 600 16px/1.2 'Quicksand', sans-serif; color: var(--vm-ink);
  background: transparent;
}
.vm-name-field .lbl {
  font: 700 11px/1 'Quicksand', sans-serif; color: var(--vm-sand-700); letter-spacing: .1em; text-transform: uppercase;
  padding-right: 10px; border-right: 1px solid rgba(0,0,0,.08);
}

/* ─── Map ─── */
.vm-map-wrap {
  position: relative;
  width: 100%;
  border-radius: 24px;
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 70% 10%, #fff7e1 0%, transparent 60%),
    linear-gradient(180deg, #eaf6f8 0%, #f4ecdb 100%);
  border: 1px solid rgba(196, 168, 120, .25);
  aspect-ratio: 540 / 460;
}
.vm-map-wrap svg.bg { position: absolute; inset: 0; width: 100%; height: 100%; }
.vm-island {
  position: absolute;
  transform: translate(-50%, -50%);
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  cursor: pointer;
  transition: transform .2s ease;
}
.vm-island:active { transform: translate(-50%, -50%) scale(.96); }
.vm-island .face { width: 76px; height: 76px; }
.vm-island.locked .face { filter: grayscale(.6) brightness(.92); opacity: .65; }
.vm-island .label {
  background: rgba(255, 255, 255, .92);
  border: 1px solid rgba(0,0,0,.06);
  padding: 4px 9px;
  border-radius: 999px;
  font: 700 11px/1 'Quicksand', sans-serif;
  color: var(--vm-ink);
  white-space: nowrap;
  display: flex; align-items: center; gap: 6px;
  box-shadow: 0 4px 10px rgba(0,0,0,.08);
}
.vm-island .label .pts { font: 700 10px/1 'Inter', sans-serif; color: var(--vm-sage-700); }
.vm-island.locked .label .pts { color: var(--vm-ink-300); }
.vm-island.recommended .label {
  background: var(--vm-aqua);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 8px 18px -4px rgba(60, 140, 153, .55);
}
.vm-island.recommended .label .pts { color: rgba(255,255,255,.85); }
.vm-island.recommended::before {
  content: '';
  position: absolute; left: 50%; top: 38px;
  width: 120px; height: 120px; border-radius: 999px;
  background: radial-gradient(circle, rgba(79,183,199,.35) 0%, transparent 60%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  animation: vmpulse 2.4s ease-in-out infinite;
  z-index: -1;
}
@keyframes vmpulse {
  0%, 100% { transform: translate(-50%, -50%) scale(.9); opacity: .35; }
  50%      { transform: translate(-50%, -50%) scale(1.15); opacity: .65; }
}
.vm-app-static .vm-island.recommended::before { animation: none; }

.vm-map-cta {
  display: flex; gap: 10px; align-items: center;
  background: #fff;
  border: 1.5px solid var(--vm-aqua-200);
  border-radius: 20px;
  padding: 14px 16px;
}
.vm-map-cta .face { width: 52px; height: 52px; flex: 0 0 52px; }
.vm-map-cta .body { flex: 1; min-width: 0; }
.vm-map-cta .body .lbl { font: 700 11px/1 'Quicksand', sans-serif; color: var(--vm-aqua-700); letter-spacing: .1em; text-transform: uppercase; }
.vm-map-cta .body .title { font: 700 15px/1.2 'Quicksand', sans-serif; color: var(--vm-ink); margin-top: 4px; }
.vm-map-cta .body .sub { font: 500 12px/1.3 'Inter', sans-serif; color: var(--vm-ink-500); margin-top: 2px; }

/* ─── Biome ─── */
.vm-biome-hero {
  position: relative;
  border-radius: 24px;
  padding: 18px 18px 20px;
  background: linear-gradient(170deg, #d6e6cf 0%, #c2d6b9 100%);
  color: var(--vm-ink);
  overflow: hidden;
}
.vm-biome-hero::after {
  content: '';
  position: absolute; right: -50px; bottom: -60px;
  width: 200px; height: 200px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><g fill='none' stroke='%23ffffff' stroke-width='1.4' opacity='.45'><path d='M50 10c-12 18-12 36 0 54 12-18 12-36 0-54z'/><path d='M30 30c8 8 20 8 28 0M30 50c8 8 20 8 28 0M30 70c8 8 20 8 28 0'/></g></svg>");
  background-size: contain;
  background-repeat: no-repeat;
  opacity: .6;
}
.vm-biome-hero .row { display: flex; align-items: flex-start; gap: 14px; position: relative; }
.vm-biome-hero .face { width: 78px; height: 78px; flex: 0 0 78px; }
.vm-biome-hero .copy { flex: 1; min-width: 0; }
.vm-biome-hero .eyebrow { font: 700 11px/1 'Quicksand', sans-serif; color: var(--vm-sage-700); letter-spacing: .12em; text-transform: uppercase; }
.vm-biome-hero h2 { font: 600 24px/1.15 'Fraunces', serif; color: var(--vm-ink); margin: 6px 0 6px; }
.vm-biome-hero p  { font: 500 13px/1.45 'Inter', sans-serif; color: var(--vm-ink); opacity: .8; margin: 0; max-width: 320px; }
.vm-biome-progress {
  position: relative;
  display: flex; align-items: center; gap: 10px;
  margin-top: 14px;
}
.vm-biome-progress .bar { flex: 1; height: 8px; border-radius: 999px; background: rgba(255,255,255,.55); overflow: hidden; }
.vm-biome-progress .bar i { display: block; height: 100%; background: #fff; border-radius: 999px; }
.vm-biome-progress .lbl { font: 700 11px/1 'Quicksand', sans-serif; color: var(--vm-ink); }

.vm-breath {
  position: relative;
  border-radius: 24px;
  padding: 20px 18px 18px;
  background: #fff;
  border: 1.5px solid var(--vm-aqua-200);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.vm-breath .title { font: 700 14px/1 'Quicksand', sans-serif; color: var(--vm-aqua-700); letter-spacing: .04em; }
.vm-breath .desc  { font: 500 12px/1.4 'Inter', sans-serif; color: var(--vm-ink-500); text-align: center; max-width: 280px; }
.vm-breath-circle {
  width: 150px; height: 150px;
  border-radius: 999px;
  background: radial-gradient(circle at 35% 30%, #d8eef2 0%, var(--vm-aqua-200) 60%, var(--vm-aqua) 100%);
  display: grid; place-items: center;
  position: relative;
  box-shadow: 0 16px 30px -10px rgba(60, 140, 153, .35);
  animation: vmbreath 6s ease-in-out infinite;
}
.vm-breath-circle::after {
  content: '';
  position: absolute; inset: -10px;
  border-radius: 999px;
  border: 1.5px dashed rgba(60, 140, 153, .4);
  animation: vmbreath 6s ease-in-out infinite reverse;
}
.vm-breath-circle .ph {
  font: 700 14px/1 'Quicksand', sans-serif;
  color: #fff;
  text-align: center;
}
.vm-breath-circle .ph small { display: block; font-size: 11px; font-weight: 500; opacity: .9; margin-top: 4px; }
@keyframes vmbreath {
  0%, 100% { transform: scale(.92); }
  50%      { transform: scale(1.08); }
}
.vm-app-static .vm-breath-circle,
.vm-app-static .vm-breath-circle::after { animation: none; }

.vm-act-row {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
}
.vm-act {
  background: #fff;
  border: 1px solid rgba(0,0,0,.06);
  border-radius: 18px;
  padding: 12px;
  display: flex; flex-direction: column; gap: 6px;
  cursor: pointer;
  transition: transform .15s ease;
}
.vm-act:active { transform: scale(.97); }
.vm-act .ico {
  width: 36px; height: 36px; border-radius: 12px;
  background: var(--vm-sage-50);
  color: var(--vm-sage-700);
  display: grid; place-items: center;
}
.vm-act .title { font: 700 13px/1.2 'Quicksand', sans-serif; color: var(--vm-ink); }
.vm-act .sub { font: 500 11px/1.3 'Inter', sans-serif; color: var(--vm-ink-500); }
.vm-act .dur { font: 600 10px/1 'Inter', sans-serif; color: var(--vm-aqua-700); margin-top: auto; }

.vm-finish-btn {
  width: 100%;
  background: var(--vm-aqua);
  color: #fff;
  border: 0;
  padding: 16px;
  border-radius: 18px;
  font: 700 15px/1 'Quicksand', sans-serif;
  letter-spacing: .02em;
  box-shadow: 0 14px 28px -10px rgba(60, 140, 153, .55);
  cursor: pointer;
  transition: transform .15s ease, background .15s ease;
}
.vm-finish-btn:active { transform: scale(.98); background: var(--vm-aqua-700); }

/* ─── Journal & Collection ─── */
.vm-tabs-seg {
  display: flex; gap: 6px;
  background: #fff;
  border: 1px solid rgba(0,0,0,.06);
  padding: 5px;
  border-radius: 999px;
}
.vm-tabs-seg button {
  flex: 1;
  background: transparent;
  border: 0;
  padding: 10px 12px;
  border-radius: 999px;
  font: 700 12px/1 'Quicksand', sans-serif;
  color: var(--vm-ink-500);
  cursor: pointer;
}
.vm-tabs-seg button.active {
  background: var(--vm-aqua);
  color: #fff;
  box-shadow: 0 6px 14px -6px rgba(60, 140, 153, .5);
}

.vm-week {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px;
}
.vm-week .day {
  background: var(--vm-cream);
  border: 1px solid rgba(0,0,0,.06);
  border-radius: 14px;
  padding: 8px 4px 10px;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.vm-week .day .lbl { font: 700 10px/1 'Quicksand', sans-serif; color: var(--vm-ink-500); letter-spacing: .08em; text-transform: uppercase; }
.vm-week .day .face { width: 36px; height: 36px; }

.vm-mood-card {
  background: #fff;
  border: 1px solid rgba(0,0,0,.06);
  border-radius: 18px;
  padding: 12px 14px;
  display: flex; align-items: center; gap: 12px;
}
.vm-mood-card .face { width: 44px; height: 44px; flex: 0 0 44px; }
.vm-mood-card .copy { flex: 1; min-width: 0; }
.vm-mood-card .copy .day { font: 700 13px/1 'Quicksand', sans-serif; color: var(--vm-ink); }
.vm-mood-card .copy .note { font: 500 12px/1.35 'Inter', sans-serif; color: var(--vm-ink-500); margin-top: 4px; }
.vm-mood-card .badge { font: 700 10px/1 'Quicksand', sans-serif; color: var(--mood-color, var(--vm-aqua-700)); padding: 4px 8px; border-radius: 999px; background: var(--mood-tint, var(--vm-aqua-50)); }

.vm-summary {
  border-radius: 18px;
  padding: 14px 16px;
  background: linear-gradient(135deg, var(--vm-aqua-50), #fff);
  border: 1px solid var(--vm-aqua-200);
  display: flex; align-items: center; gap: 12px;
}
.vm-summary .ico {
  width: 40px; height: 40px; border-radius: 14px;
  background: var(--vm-aqua); color: #fff;
  display: grid; place-items: center;
}
.vm-summary .body .ttl { font: 700 13px/1 'Quicksand', sans-serif; color: var(--vm-aqua-700); }
.vm-summary .body .sub { font: 500 12px/1.3 'Inter', sans-serif; color: var(--vm-ink); margin-top: 4px; }

.vm-collection {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.vm-coll-card {
  position: relative;
  background: #fff;
  border: 1px solid rgba(0,0,0,.06);
  border-radius: 16px;
  padding: 10px 6px 8px;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  cursor: pointer;
  transition: transform .15s ease;
}
.vm-coll-card:active { transform: scale(.97); }
.vm-coll-card .face { width: 56px; height: 56px; }
.vm-coll-card .name { font: 700 12px/1 'Quicksand', sans-serif; color: var(--vm-ink); }
.vm-coll-card .meta { font: 500 9px/1 'Inter', sans-serif; color: var(--vm-ink-500); letter-spacing: .08em; text-transform: uppercase; }
.vm-coll-card.locked { background: var(--vm-cream); }
.vm-coll-card.locked .name { color: var(--vm-ink-300); }
.vm-coll-card.locked .meta { opacity: .5; }
.vm-coll-card.companion::after {
  content: '';
  position: absolute; right: 8px; top: 8px;
  width: 8px; height: 8px; border-radius: 999px;
  background: var(--vm-aqua);
  box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--vm-aqua-200);
}

/* ─── Settings strip (used in header overlay) ─── */
.vm-low-stim {
  position: relative;
}
/* Low-stim global effect (desaturate + remove some shadows) */
.wm-app.vm-low-stim {
  filter: saturate(.7);
}
.wm-app.vm-low-stim .vm-breath-circle,
.wm-app.vm-low-stim .vm-breath-circle::after,
.wm-app.vm-low-stim .vm-island.recommended::before { animation: none; }
.wm-app.vm-low-stim .vm-mood-card, .wm-app.vm-low-stim .vm-act, .wm-app.vm-low-stim .vm-mood { box-shadow: none; }

/* Large-font mode */
.wm-app.vm-big .wm-h1 { font-size: 30px; }
.wm-app.vm-big .vm-mood .label, .wm-app.vm-big .vm-coll-card .name, .wm-app.vm-big .vm-act .title { font-size: 15px; }
.wm-app.vm-big .vm-mood .help, .wm-app.vm-big .vm-act .sub, .wm-app.vm-big .vm-mood-card .copy .note { font-size: 13px; }
