:root {
  color-scheme: light;
  --paper: #fff4d6;
  --paper-pale: #fffaf0;
  --panel: #ffffff;
  --ink: #183153;
  --ink-soft: #31527a;
  --muted: #58708f;
  --sky: #5cc8ff;
  --sky-dark: #1673a8;
  --leaf: #70c66b;
  --leaf-dark: #28723d;
  --sun: #ffd447;
  --sun-dark: #8b5b00;
  --coral: #ff7a59;
  --coral-dark: #a83d28;
  --grape: #9c83e8;
  --pink: #ff7eb3;
  --line: 3px solid var(--ink);
  --shadow-control: 0 3px 0 var(--ink);
  --shadow-card: 0 5px 0 var(--ink);
  --shadow-shell: 0 9px 0 var(--ink);
  --radius-sm: 11px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-shell: 30px;
  --display: "Fredoka", "Arial Rounded MT Bold", sans-serif;
  --body: "Nunito", "Avenir Next", sans-serif;
}

body[data-static-deploy] .crew-button,
body[data-static-deploy] .crew-live-strip,
body[data-static-deploy] .crew-dialog {
  display: none !important;
}

.tunetoy-footer {
  align-items: center;
  color: var(--ink-soft);
  display: flex;
  flex-wrap: wrap;
  font-size: .78rem;
  font-weight: 900;
  gap: 10px 18px;
  justify-content: center;
  margin: 8px auto 28px;
  padding: 0 20px;
}

.tunetoy-footer a {
  color: inherit;
  text-underline-offset: 3px;
}

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

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  background-color: var(--paper);
  background-image:
    radial-gradient(circle at 12% 19%, rgb(24 49 83 / 7%) 2px, transparent 2.5px),
    linear-gradient(90deg, transparent 49.8%, rgb(255 255 255 / 20%) 50%, transparent 50.2%);
  background-size: 27px 27px, 100% 100%;
  color: var(--ink);
  font-family: var(--body);
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

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

button {
  touch-action: manipulation;
}

button:not(:disabled),
a,
input {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 4px solid #1177b2;
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

.sr-only {
  border: 0 !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  height: 1px !important;
  margin: -1px !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  white-space: nowrap !important;
  width: 1px !important;
}

.skip-link {
  background: var(--panel);
  border: var(--line);
  border-radius: 0 0 var(--radius-sm) 0;
  color: var(--ink);
  font-weight: 900;
  left: 0;
  padding: 12px 18px;
  position: fixed;
  top: 0;
  transform: translateY(-130%);
  z-index: 1000;
}

.skip-link:focus {
  transform: translateY(0);
}

.page-sky {
  height: 210px;
  left: 0;
  overflow: hidden;
  pointer-events: none;
  position: absolute;
  right: 0;
  top: 0;
}

.page-sky::after {
  border: 3px dashed rgb(24 49 83 / 16%);
  border-radius: 50%;
  content: "";
  height: 440px;
  position: absolute;
  right: -120px;
  top: -355px;
  width: 740px;
}

.cloud {
  background: rgb(255 255 255 / 62%);
  border: 2px solid rgb(24 49 83 / 12%);
  border-radius: 999px;
  height: 27px;
  position: absolute;
  width: 86px;
}

.cloud::before,
.cloud::after {
  background: inherit;
  border: inherit;
  border-bottom: 0;
  border-radius: 50% 50% 0 0;
  content: "";
  position: absolute;
}

.cloud::before {
  height: 34px;
  left: 12px;
  top: -24px;
  width: 39px;
}

.cloud::after {
  height: 25px;
  right: 11px;
  top: -16px;
  width: 31px;
}

.cloud--one {
  left: 4%;
  top: 115px;
  transform: rotate(-3deg);
}

.cloud--two {
  right: 22%;
  top: 62px;
  transform: scale(.72) rotate(4deg);
}

.sun-doodle {
  background: var(--sun);
  border: var(--line);
  border-radius: 50%;
  box-shadow: 0 4px 0 var(--ink);
  height: 48px;
  position: absolute;
  right: 5%;
  top: 76px;
  transform: rotate(8deg);
  width: 48px;
}

.sun-doodle::before,
.sun-doodle::after {
  background: var(--ink);
  border-radius: 999px;
  content: "";
  height: 4px;
  left: 50%;
  position: absolute;
  top: 50%;
  width: 76px;
  z-index: -1;
}

.sun-doodle::before {
  transform: translate(-50%, -50%) rotate(18deg);
}

.sun-doodle::after {
  transform: translate(-50%, -50%) rotate(107deg);
}

.site-header {
  align-items: center;
  display: flex;
  gap: 24px;
  margin: 0 auto;
  max-width: 1540px;
  min-height: 92px;
  padding: 15px 28px 10px;
  position: relative;
  width: 100%;
  z-index: 5;
}

.brand {
  align-items: center;
  color: var(--ink);
  display: inline-flex;
  flex: 0 0 auto;
  font-family: var(--display);
  font-size: clamp(1.65rem, 2.2vw, 2.25rem);
  font-weight: 700;
  gap: 8px;
  letter-spacing: -.035em;
  line-height: 1;
  text-decoration: none;
}

.brand > span > span {
  color: var(--coral-dark);
}

.brand-mark {
  height: 49px;
  transform: rotate(-5deg);
  transition: transform 180ms ease-out;
  width: 44px;
}

.brand:hover .brand-mark {
  transform: rotate(4deg) translateY(-2px);
}

.header-tagline {
  color: var(--ink-soft);
  font-size: .9rem;
  font-weight: 900;
  margin: 0 auto 0 0;
  transform: rotate(-1deg);
}

.header-actions {
  align-items: center;
  display: flex;
  gap: 10px;
}

.tactile-button {
  align-items: center;
  background: var(--panel);
  border: var(--line);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-control);
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  font-family: var(--display);
  font-weight: 700;
  gap: 8px;
  justify-content: center;
  min-height: 46px;
  padding: 9px 15px;
  transition: box-shadow 100ms ease-out, transform 100ms ease-out, background 120ms ease-out;
}

.tactile-button:hover:not(:disabled) {
  box-shadow: 0 5px 0 var(--ink);
  transform: translateY(-2px);
}

.tactile-button:active:not(:disabled) {
  box-shadow: 0 1px 0 var(--ink);
  transform: translateY(2px);
}

.tactile-button:disabled {
  cursor: not-allowed;
  filter: grayscale(.35);
  opacity: .57;
}

.sound-button {
  border-radius: 999px;
  font-family: var(--body);
  font-size: .82rem;
  font-weight: 900;
  min-height: 44px;
  padding-inline: 14px;
}

.sound-button > span:first-child {
  font-size: 1.1rem;
}

.grownup-button {
  background: var(--sun);
  min-height: 46px;
}

.app-shell {
  margin: 0 auto;
  max-width: 1540px;
  padding: 8px 28px 52px;
  position: relative;
  width: 100%;
  z-index: 2;
}

.coach-ribbon {
  align-items: center;
  background: var(--panel);
  border: var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow-card);
  display: grid;
  gap: 18px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  margin: 0 12px 22px;
  min-height: 114px;
  padding: 14px 18px 14px 20px;
  position: relative;
}

.coach-ribbon::after {
  border: 3px dashed var(--coral);
  border-left: 0;
  border-radius: 0 20px 20px 0;
  bottom: 9px;
  content: "";
  opacity: .4;
  position: absolute;
  right: 9px;
  top: 9px;
  width: 140px;
  z-index: 0;
}

.pip-stage {
  align-self: end;
  height: 100px;
  margin-bottom: -14px;
  position: relative;
  width: 102px;
  z-index: 1;
}

.pip {
  animation: pip-bob 3.4s ease-in-out infinite;
  bottom: 0;
  color: var(--ink);
  height: 124px;
  left: -8px;
  position: absolute;
  transform-origin: 50% 85%;
  width: 116px;
}

@keyframes pip-bob {
  0%, 100% { transform: rotate(-2deg) translateY(0); }
  50% { transform: rotate(2deg) translateY(-5px); }
}

.coach-copy {
  min-width: 0;
  position: relative;
  z-index: 2;
}

.eyebrow {
  color: var(--leaf-dark);
  display: block;
  font-size: .72rem;
  font-weight: 900;
  letter-spacing: .105em;
  line-height: 1.2;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.coach-copy h1 {
  font-family: var(--display);
  font-size: clamp(1.55rem, 3vw, 2.55rem);
  letter-spacing: -.035em;
  line-height: 1.02;
  margin: 0;
}

.coach-copy p {
  color: var(--ink-soft);
  font-size: clamp(.88rem, 1.3vw, 1.02rem);
  font-weight: 800;
  line-height: 1.4;
  margin: 5px 0 0;
}

.surprise-button {
  background: var(--coral);
  border-radius: 18px;
  box-shadow: 0 5px 0 var(--ink);
  font-size: 1.05rem;
  min-height: 58px;
  padding-inline: 21px;
  position: relative;
  white-space: nowrap;
  z-index: 2;
}

.surprise-button > span {
  font-size: 1.25rem;
}

.explorer-tablet {
  background: var(--panel);
  border: var(--line);
  border-radius: var(--radius-shell);
  box-shadow: var(--shadow-shell);
  display: grid;
  grid-template-columns: minmax(330px, 390px) minmax(0, 1fr);
  min-height: 740px;
  overflow: hidden;
  position: relative;
}

.explorer-tablet::before,
.explorer-tablet::after {
  border: var(--line);
  border-radius: 50%;
  content: "";
  height: 13px;
  position: absolute;
  top: 14px;
  width: 13px;
  z-index: 20;
}

.explorer-tablet::before {
  background: var(--grape);
  left: 16px;
}

.explorer-tablet::after {
  background: var(--sun);
  right: 16px;
}

.mission-rail {
  background:
    linear-gradient(rgb(255 255 255 / 42%), rgb(255 255 255 / 42%)),
    repeating-linear-gradient(0deg, transparent 0 31px, rgb(24 49 83 / 7%) 31px 33px),
    var(--paper);
  border-right: var(--line);
  min-width: 0;
  padding: 37px 22px 24px;
  position: relative;
}

.mission-rail::after {
  border-left: 3px dashed rgb(24 49 83 / 18%);
  bottom: 0;
  content: "";
  left: 47px;
  pointer-events: none;
  position: absolute;
  top: 0;
}

.rail-heading,
.sticker-pocket-heading {
  align-items: center;
  display: flex;
  gap: 14px;
  justify-content: space-between;
  position: relative;
  z-index: 1;
}

.rail-heading h2,
.mission-picker h3,
.sticker-pocket h3 {
  font-family: var(--display);
  letter-spacing: -.02em;
  margin: 0;
}

.rail-heading h2 {
  font-size: 1.55rem;
}

.progress-badge {
  align-items: center;
  background: var(--sun);
  border: var(--line);
  border-radius: 15px;
  box-shadow: var(--shadow-control);
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 61px;
  min-width: 70px;
  padding: 5px 9px;
  transform: rotate(2deg);
}

.progress-badge strong {
  font-family: var(--display);
  font-size: 1.2rem;
  line-height: 1;
}

.progress-badge span {
  font-size: .64rem;
  font-weight: 900;
  margin-top: 3px;
  text-transform: uppercase;
}

.trail-progress {
  align-items: center;
  display: flex;
  margin: 17px 3px 18px;
  position: relative;
  z-index: 1;
}

.trail-dot {
  align-items: center;
  background: var(--panel);
  border: 2.5px solid var(--ink);
  border-radius: 50%;
  display: inline-flex;
  flex: 0 0 auto;
  font-family: var(--display);
  font-size: .72rem;
  height: 28px;
  justify-content: center;
  transition: transform 160ms ease-out, background 160ms ease-out;
  width: 28px;
}

.trail-dot.is-complete {
  background: var(--leaf);
}

.trail-dot.is-current {
  background: var(--sun);
  box-shadow: 0 3px 0 var(--ink);
  transform: translateY(-2px) scale(1.08);
}

.trail-line {
  border-top: 3px dashed var(--ink-soft);
  flex: 1 1 auto;
  margin-inline: 3px;
  opacity: .5;
}

.active-mission {
  background: color-mix(in srgb, var(--mission-accent, var(--leaf)) 26%, white);
  border: var(--line);
  border-radius: 20px 20px 24px 18px;
  box-shadow: var(--shadow-card);
  margin: 0 3px 24px;
  padding: 17px;
  position: relative;
  transform: rotate(-.65deg);
  z-index: 2;
}

.active-mission::before {
  background: rgb(255 255 255 / 65%);
  border: 2px solid rgb(24 49 83 / 30%);
  content: "";
  height: 18px;
  left: 50%;
  position: absolute;
  top: -10px;
  transform: translateX(-50%) rotate(2deg);
  width: 73px;
}

.mission-sticker {
  align-items: center;
  background: var(--mission-accent, var(--leaf));
  border: var(--line);
  border-radius: 50% 46% 50% 43%;
  box-shadow: var(--shadow-control);
  display: flex;
  float: left;
  font-size: 2.1rem;
  height: 70px;
  justify-content: center;
  margin: -3px 13px 6px -3px;
  transform: rotate(-7deg);
  width: 70px;
}

.mission-kicker {
  color: var(--ink-soft);
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.active-mission h3 {
  font-family: var(--display);
  font-size: 1.5rem;
  letter-spacing: -.02em;
  line-height: 1.05;
  margin: 2px 0 5px;
}

.active-mission-copy p {
  color: var(--ink-soft);
  font-size: .93rem;
  font-weight: 800;
  line-height: 1.42;
  margin: 0;
  min-height: 4em;
}

.spotted-button {
  background: var(--coral);
  border-radius: 16px;
  clear: both;
  font-size: 1.02rem;
  margin-top: 15px;
  min-height: 53px;
  width: 100%;
}

.mission-safety {
  color: var(--ink-soft);
  font-size: .71rem;
  font-weight: 900;
  line-height: 1.35;
  margin: 12px 2px 0;
  text-align: center;
}

.mission-picker {
  position: relative;
  z-index: 2;
}

.mission-picker > h3 {
  font-size: 1.05rem;
  margin: 0 4px 10px;
}

.mission-list {
  display: grid;
  gap: 8px;
}

.mission-card {
  align-items: center;
  background: var(--panel);
  border: 2.5px solid var(--ink);
  border-radius: 14px;
  box-shadow: 0 2px 0 var(--ink);
  color: var(--ink);
  cursor: pointer;
  display: grid;
  gap: 10px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  min-height: 56px;
  padding: 6px 8px;
  text-align: left;
  transition: box-shadow 100ms, transform 100ms, background 120ms;
  width: 100%;
}

.mission-card:hover {
  box-shadow: 0 4px 0 var(--ink);
  transform: translateY(-1px) rotate(.2deg);
}

.mission-card:active {
  box-shadow: 0 1px 0 var(--ink);
  transform: translateY(1px);
}

.mission-card.is-active {
  background: color-mix(in srgb, var(--mission-accent) 27%, white);
}

.mission-card.is-crew-placed:not(.is-complete) .mission-card-state {
  background: var(--sky);
  font-size: .82rem;
}

.mission-list-empty {
  align-items: center;
  background: #fff7d6;
  border: 2px dashed var(--ink);
  border-radius: 14px;
  display: grid;
  gap: 3px 9px;
  grid-template-columns: auto 1fr;
  padding: 12px;
}

.mission-list-empty > span {
  font-size: 1.5rem;
  grid-row: 1 / 3;
}

.mission-list-empty strong {
  font-family: var(--display);
  font-size: .82rem;
}

.mission-list-empty small,
.kit-empty {
  font-size: .65rem;
  font-weight: 800;
}

.kit-empty {
  color: rgb(255 255 255 / 72%);
  grid-column: 1 / -1;
  line-height: 1.35;
  padding: 5px;
  text-align: center;
}

.mission-card.is-complete .mini-sticker {
  background: var(--leaf);
}

.mini-sticker {
  align-items: center;
  background: color-mix(in srgb, var(--mission-accent) 65%, white);
  border: 2px solid var(--ink);
  border-radius: 50%;
  display: flex;
  font-size: 1.3rem;
  height: 40px;
  justify-content: center;
  width: 40px;
}

.mission-card-copy {
  display: grid;
  line-height: 1.15;
  min-width: 0;
}

.mission-card-copy strong {
  font-family: var(--display);
  font-size: .93rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mission-card-copy small {
  color: var(--muted);
  font-size: .69rem;
  font-weight: 900;
  margin-top: 3px;
}

.mission-card-state {
  align-items: center;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 50%;
  display: flex;
  font-family: var(--display);
  font-size: .72rem;
  height: 27px;
  justify-content: center;
  width: 27px;
}

.mission-card.is-complete .mission-card-state {
  background: var(--leaf);
}

.sticker-pocket {
  background: var(--ink);
  border-radius: 17px;
  box-shadow: 0 4px 0 #09182a;
  color: white;
  margin-top: 22px;
  padding: 15px;
  position: relative;
  z-index: 2;
}

.sticker-pocket::before {
  border: 2px dashed rgb(255 255 255 / 32%);
  border-radius: 12px;
  bottom: 6px;
  content: "";
  left: 6px;
  pointer-events: none;
  position: absolute;
  right: 6px;
  top: 6px;
}

.sticker-pocket-heading {
  padding-inline: 3px;
}

.sticker-pocket-heading h3 {
  font-size: 1.02rem;
}

.sticker-pocket-heading span {
  color: #d5e3f5;
  font-size: .7rem;
  font-weight: 900;
}

.sticker-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-top: 12px;
  position: relative;
}

.kit-sticker {
  align-items: center;
  background: #486582;
  border: 2px dashed #9fb2c8;
  border-radius: 50%;
  color: #c6d2df;
  display: flex;
  font-family: var(--display);
  font-size: .92rem;
  height: 39px;
  justify-content: center;
  transform: rotate(-3deg);
}

.kit-sticker:nth-child(even) {
  transform: rotate(4deg);
}

.kit-sticker.is-earned {
  background: var(--sticker-color);
  border: 2px solid white;
  box-shadow: 0 2px 0 #09182a;
  color: var(--ink);
  font-size: 1.15rem;
}

.map-side {
  background: #f8fbff;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 36px 22px 20px;
}

.map-toolbar,
.search-strip,
.category-row {
  flex: 0 0 auto;
}

.has-google-map:not(.is-list-view) .category-row {
  display: none;
}

.map-toolbar {
  align-items: center;
  display: flex;
  gap: 16px;
  justify-content: space-between;
  margin: 0 2px 13px;
}

.view-switcher {
  background: var(--paper);
  border: 2.5px solid var(--ink);
  border-radius: 14px;
  box-shadow: 0 2px 0 var(--ink);
  display: flex;
  padding: 3px;
}

.view-tab {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: 9px;
  color: var(--ink-soft);
  cursor: pointer;
  display: inline-flex;
  font-size: .82rem;
  font-weight: 900;
  gap: 6px;
  min-height: 44px;
  padding: 7px 13px;
}

.view-tab.is-active {
  background: var(--panel);
  box-shadow: 0 2px 0 rgb(24 49 83 / 25%);
  color: var(--ink);
}

.map-mode {
  align-items: center;
  background: #e7f7e6;
  border: 2px solid var(--ink);
  border-radius: 999px;
  color: var(--leaf-dark);
  display: inline-flex;
  font-size: .72rem;
  font-weight: 900;
  gap: 7px;
  min-height: 34px;
  padding: 6px 12px;
}

.mode-light {
  background: var(--leaf);
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  height: 11px;
  width: 11px;
}

.map-mode[data-mode="loading"] {
  background: #fff4c3;
  color: var(--sun-dark);
}

.map-mode[data-mode="loading"] .mode-light {
  animation: mode-pulse 1s ease-in-out infinite;
  background: var(--sun);
}

.map-mode[data-mode="real"] {
  background: #e1f5ff;
  color: var(--sky-dark);
}

.map-mode[data-mode="real"] .mode-light {
  background: var(--sky);
}

@keyframes mode-pulse {
  50% { opacity: .4; transform: scale(.75); }
}

.search-strip {
  align-items: stretch;
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 1fr) auto;
  margin-bottom: 11px;
}

.place-search {
  align-items: center;
  background: var(--panel);
  border: var(--line);
  border-radius: 17px;
  box-shadow: var(--shadow-control);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  min-width: 0;
  overflow: hidden;
}

.search-icon {
  font-family: var(--display);
  font-size: 1.5rem;
  margin-left: 14px;
  transform: rotate(-15deg);
}

.place-search input {
  background: transparent;
  border: 0;
  font-size: .87rem;
  font-weight: 800;
  height: 49px;
  min-width: 0;
  outline: none;
  padding: 7px 11px;
  width: 100%;
}

.place-search input::placeholder {
  color: #69809b;
  opacity: 1;
}

.place-search button {
  align-self: stretch;
  background: var(--sky);
  border: 0;
  border-left: 2.5px solid var(--ink);
  cursor: pointer;
  font-family: var(--display);
  font-weight: 700;
  min-width: 84px;
  padding-inline: 15px;
}

.place-search button:hover:not(:disabled) {
  background: #82d5ff;
}

.locate-button {
  background: var(--sun);
  border-radius: 17px;
  min-height: 55px;
}

.category-row {
  display: flex;
  gap: 8px;
  margin-bottom: 13px;
  overflow-x: auto;
  padding: 1px 2px 5px;
  scrollbar-width: thin;
}

.category-chip {
  background: var(--panel);
  border: 2px solid var(--ink);
  border-radius: 999px;
  box-shadow: 0 2px 0 var(--ink);
  cursor: pointer;
  flex: 0 0 auto;
  font-size: .76rem;
  font-weight: 900;
  min-height: 44px;
  padding: 7px 12px;
}

.category-chip:hover {
  transform: translateY(-1px);
}

.category-chip.is-active {
  background: var(--leaf);
}

.map-workspace {
  flex: 1 1 auto;
  min-height: 560px;
  position: relative;
}

.map-view,
.list-view {
  height: 100%;
  min-height: 560px;
}

.map-view {
  background: #e8f5ce;
  border: var(--line);
  border-radius: 22px;
  box-shadow: 0 5px 0 var(--ink);
  overflow: hidden;
  position: relative;
}

.google-map,
.practice-map {
  height: 100%;
  inset: 0;
  min-height: 560px;
  position: absolute;
  width: 100%;
}

.google-map {
  opacity: 0;
  pointer-events: none;
  transition: opacity 240ms ease-out;
  z-index: 1;
}

.google-map.is-ready {
  opacity: 1;
  pointer-events: auto;
}

.practice-map {
  background: #f3e6bd;
  cursor: crosshair;
  overflow: hidden;
  z-index: 2;
}

.has-google-map .practice-map {
  display: none;
}

.has-google-map .google-map {
  z-index: 2;
}

.practice-map-art {
  height: 100%;
  left: 0;
  position: absolute;
  top: 0;
  width: 100%;
}

.crayon-trail {
  animation: trail-march 14s linear infinite;
}

@keyframes trail-march {
  to { stroke-dashoffset: -220; }
}

.practice-pois,
.demo-discoveries {
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.practice-poi {
  align-items: center;
  background: transparent;
  border: 0;
  color: var(--ink);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  left: var(--x);
  padding: 0;
  pointer-events: auto;
  position: absolute;
  top: var(--y);
  transform: translate(-50%, -72%);
  z-index: 3;
}

.practice-poi:hover,
.practice-poi:focus-visible {
  z-index: 8;
}

.practice-poi:hover .poi-pin,
.practice-poi:focus-visible .poi-pin {
  box-shadow: 0 7px 0 var(--ink);
  transform: translateY(-4px) rotate(3deg) scale(1.08);
}

.practice-poi:active .poi-pin {
  box-shadow: 0 2px 0 var(--ink);
  transform: translateY(2px);
}

.poi-pin {
  align-items: center;
  background: var(--sun);
  border: var(--line);
  border-radius: 50% 50% 50% 12px;
  box-shadow: 0 5px 0 var(--ink);
  display: flex;
  height: 58px;
  justify-content: center;
  transform: rotate(-45deg);
  transition: transform 130ms ease-out, box-shadow 130ms ease-out;
  width: 58px;
}

.poi-pin span {
  font-size: 1.55rem;
  transform: rotate(45deg);
}

.practice-poi:nth-child(3n + 2) .poi-pin {
  background: var(--sky);
}

.practice-poi:nth-child(3n + 3) .poi-pin {
  background: var(--coral);
}

.poi-label {
  background: var(--panel);
  border: 2px solid var(--ink);
  border-radius: 8px;
  box-shadow: 0 2px 0 var(--ink);
  font-family: var(--display);
  font-size: clamp(.58rem, .85vw, .74rem);
  line-height: 1.05;
  margin-top: -2px;
  max-width: 110px;
  padding: 5px 7px;
  white-space: nowrap;
}

.demo-marker {
  align-items: center;
  background: var(--sun);
  border: var(--line);
  border-radius: 50%;
  box-shadow: 0 4px 0 var(--ink);
  display: flex;
  font-size: 1.35rem;
  height: 48px;
  justify-content: center;
  pointer-events: none;
  position: absolute;
  transform: translate(-50%, -50%);
  width: 48px;
  z-index: 7;
}

.demo-marker.is-pending {
  animation: marker-hop 620ms ease-in-out infinite alternate;
}

.demo-marker.is-confirmed {
  background: var(--leaf);
  transform: translate(-50%, -50%) rotate(-6deg);
}

@keyframes marker-hop {
  to { transform: translate(-50%, -66%) rotate(5deg); }
}

.map-tip {
  align-items: center;
  backdrop-filter: blur(5px);
  background: rgb(255 250 240 / 94%);
  border: 2.5px solid var(--ink);
  border-radius: 14px;
  bottom: 14px;
  box-shadow: 0 3px 0 var(--ink);
  display: flex;
  font-size: .75rem;
  font-weight: 900;
  gap: 9px;
  left: 50%;
  max-width: calc(100% - 28px);
  padding: 8px 13px;
  position: absolute;
  transform: translateX(-50%);
  width: max-content;
  z-index: 12;
}

.map-tip > span:first-child {
  font-size: 1.05rem;
}

.list-view {
  background:
    radial-gradient(rgb(24 49 83 / 5%) 2px, transparent 2px),
    var(--paper-pale);
  background-size: 24px 24px;
  border: var(--line);
  border-radius: 22px;
  box-shadow: 0 5px 0 var(--ink);
  overflow: auto;
  padding: clamp(20px, 4vw, 38px);
}

.list-view-heading {
  align-items: start;
  display: flex;
  gap: 24px;
  justify-content: space-between;
  margin-bottom: 22px;
}

.list-view-heading h2 {
  font-family: var(--display);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  letter-spacing: -.035em;
  line-height: 1.05;
  margin: 0;
}

.list-view-heading p {
  color: var(--ink-soft);
  font-size: .87rem;
  font-weight: 800;
  line-height: 1.4;
  margin: 7px 0 0;
  max-width: 600px;
}

.result-count {
  background: var(--sky);
  border: 2.5px solid var(--ink);
  border-radius: 999px;
  box-shadow: 0 2px 0 var(--ink);
  flex: 0 0 auto;
  font-size: .75rem;
  font-weight: 900;
  padding: 8px 12px;
}

.place-list {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
}

.place-card {
  align-items: center;
  background: var(--panel);
  border: var(--line);
  border-radius: 17px;
  box-shadow: var(--shadow-control);
  cursor: pointer;
  display: grid;
  gap: 13px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  min-height: 105px;
  padding: 12px;
  text-align: left;
  transition: transform 100ms, box-shadow 100ms;
  width: 100%;
}

.place-card:hover {
  box-shadow: 0 5px 0 var(--ink);
  transform: translateY(-2px) rotate(-.2deg);
}

.place-card:active {
  box-shadow: 0 1px 0 var(--ink);
  transform: translateY(2px);
}

.place-emoji {
  align-items: center;
  background: var(--sun);
  border: 2.5px solid var(--ink);
  border-radius: 50%;
  display: flex;
  font-size: 1.65rem;
  height: 58px;
  justify-content: center;
  width: 58px;
}

.place-card-copy {
  display: grid;
  min-width: 0;
}

.place-card-copy strong {
  font-family: var(--display);
  font-size: 1.05rem;
  line-height: 1.1;
}

.place-card-copy small {
  color: var(--leaf-dark);
  font-size: .66rem;
  font-weight: 900;
  letter-spacing: .06em;
  margin: 3px 0;
  text-transform: uppercase;
}

.place-card-copy > span {
  color: var(--ink-soft);
  display: -webkit-box;
  font-size: .73rem;
  font-weight: 800;
  line-height: 1.3;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.place-arrow {
  font-family: var(--display);
  font-size: 1.4rem;
}

.spot-confirm {
  align-items: center;
  background: var(--panel);
  border: var(--line);
  border-radius: 20px;
  bottom: 16px;
  box-shadow: 0 7px 0 var(--ink);
  display: grid;
  gap: 14px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  left: 50%;
  max-width: calc(100% - 28px);
  opacity: 0;
  padding: 13px 15px;
  position: absolute;
  transform: translate(-50%, 24px);
  transition: opacity 180ms ease-out, transform 180ms ease-out;
  width: min(760px, calc(100% - 28px));
  z-index: 30;
}

.spot-confirm.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.spot-confirm-icon {
  align-items: center;
  background: var(--sun);
  border: var(--line);
  border-radius: 50%;
  display: flex;
  font-size: 1.6rem;
  height: 56px;
  justify-content: center;
  transform: rotate(-5deg);
  width: 56px;
}

.spot-confirm h2 {
  font-family: var(--display);
  font-size: 1.15rem;
  line-height: 1.05;
  margin: 0;
}

.spot-confirm p {
  color: var(--ink-soft);
  font-size: .74rem;
  font-weight: 800;
  line-height: 1.3;
  margin: 4px 0 0;
}

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

.confirm-spot {
  background: var(--leaf);
  white-space: nowrap;
}

.cancel-spot {
  background: transparent;
  border: 0;
  color: var(--ink-soft);
  cursor: pointer;
  font-size: .74rem;
  font-weight: 900;
  min-height: 44px;
  padding: 6px 9px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.privacy-note {
  align-items: center;
  display: flex;
  gap: 10px;
  margin: 13px 5px 0;
  min-height: 36px;
}

.privacy-shield {
  align-items: center;
  background: var(--leaf);
  border: 2px solid var(--ink);
  border-radius: 50%;
  display: flex;
  flex: 0 0 auto;
  font-size: .55rem;
  height: 27px;
  justify-content: center;
  width: 27px;
}

.privacy-note p {
  color: var(--ink-soft);
  font-size: .72rem;
  font-weight: 800;
  line-height: 1.35;
  margin: 0;
}

.privacy-note button {
  background: transparent;
  border: 0;
  color: var(--sky-dark);
  cursor: pointer;
  flex: 0 0 auto;
  font-size: .7rem;
  font-weight: 900;
  margin-left: auto;
  min-height: 40px;
  padding: 5px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.toast {
  background: var(--ink);
  border: 3px solid white;
  border-radius: 17px;
  bottom: 24px;
  box-shadow: 0 6px 0 rgb(24 49 83 / 30%);
  color: white;
  font-family: var(--display);
  font-size: .95rem;
  font-weight: 700;
  left: 50%;
  max-width: min(92vw, 560px);
  opacity: 0;
  padding: 13px 19px;
  pointer-events: none;
  position: fixed;
  text-align: center;
  transform: translate(-50%, 30px);
  transition: opacity 200ms ease-out, transform 200ms ease-out;
  width: max-content;
  z-index: 200;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.confetti {
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  position: fixed;
  z-index: 180;
}

.confetti-piece,
.confetti-star {
  animation: confetti-drop 1.5s cubic-bezier(.22, .65, .38, 1) var(--delay) both;
  background: var(--color);
  border: 1.5px solid var(--ink);
  height: 13px;
  left: var(--x);
  position: absolute;
  top: -30px;
  width: 9px;
}

.confetti-star {
  background: transparent;
  border: 0;
  height: auto;
  width: auto;
}

.confetti-star::before {
  color: var(--color);
  content: "★";
  font-size: 19px;
  -webkit-text-stroke: 1px var(--ink);
}

@keyframes confetti-drop {
  0% { opacity: 0; transform: translateY(0) rotate(0); }
  12% { opacity: 1; }
  100% { opacity: 0; transform: translateY(92vh) rotate(var(--spin)); }
}

.grownup-dialog {
  background: transparent;
  border: 0;
  color: var(--ink);
  max-height: calc(100vh - 30px);
  max-width: min(680px, calc(100vw - 28px));
  padding: 0;
  width: 100%;
}

.grownup-dialog::backdrop {
  backdrop-filter: blur(5px);
  background: rgb(24 49 83 / 58%);
}

.dialog-card {
  background:
    radial-gradient(rgb(24 49 83 / 5%) 2px, transparent 2px),
    var(--paper-pale);
  background-size: 25px 25px;
  border: var(--line);
  border-radius: 26px;
  box-shadow: 0 8px 0 var(--ink);
  max-height: calc(100vh - 46px);
  overflow: auto;
  padding: clamp(22px, 5vw, 38px);
  position: relative;
}

.dialog-close {
  align-items: center;
  background: var(--panel);
  border: 2.5px solid var(--ink);
  border-radius: 50%;
  box-shadow: 0 2px 0 var(--ink);
  cursor: pointer;
  display: flex;
  font-family: var(--display);
  font-size: 1.35rem;
  height: 42px;
  justify-content: center;
  position: absolute;
  right: 15px;
  top: 15px;
  width: 42px;
}

.dialog-key {
  align-items: center;
  background: var(--sun);
  border: var(--line);
  border-radius: 50%;
  box-shadow: var(--shadow-control);
  display: flex;
  font-size: 1.65rem;
  height: 60px;
  justify-content: center;
  margin-bottom: 15px;
  transform: rotate(-7deg);
  width: 60px;
}

.dialog-card > h2 {
  font-family: var(--display);
  font-size: clamp(1.7rem, 5vw, 2.6rem);
  letter-spacing: -.04em;
  line-height: 1.02;
  margin: 0;
  max-width: 510px;
}

.dialog-card > p {
  color: var(--ink-soft);
  font-size: .92rem;
  font-weight: 800;
  line-height: 1.5;
}

.dialog-section {
  background: var(--panel);
  border: 2.5px solid var(--ink);
  border-radius: 17px;
  box-shadow: var(--shadow-control);
  margin: 17px 0;
  padding: 16px;
}

.dialog-section h3 {
  font-family: var(--display);
  font-size: 1.05rem;
  margin: 0 0 5px;
}

.dialog-section p {
  color: var(--ink-soft);
  font-size: .78rem;
  font-weight: 800;
  line-height: 1.45;
  margin: 0;
}

.adult-check {
  align-items: center;
  background: #eaf7ff;
  border: 2px solid var(--ink);
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  font-size: .81rem;
  font-weight: 900;
  gap: 10px;
  margin: 14px 0 11px;
  padding: 10px;
}

.adult-check input {
  accent-color: var(--leaf-dark);
  height: 24px;
  margin: 0;
  width: 24px;
}

.dialog-location {
  background: var(--sky);
  min-height: 49px;
  width: 100%;
}

.location-status {
  background: #fff7d6;
  border: 2px solid var(--ink);
  border-radius: 10px;
  color: var(--ink) !important;
  margin-top: 11px !important;
  padding: 10px;
}

.map-setup-note code {
  background: var(--ink);
  border-radius: 6px;
  color: white;
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .73rem;
  margin-top: 10px;
  padding: 5px 8px;
}

.reset-section {
  align-items: center;
  display: flex;
  gap: 18px;
  justify-content: space-between;
}

.reset-button {
  background: var(--panel);
  border: 2px solid var(--coral-dark);
  border-radius: 11px;
  color: var(--coral-dark);
  cursor: pointer;
  flex: 0 0 auto;
  font-size: .75rem;
  font-weight: 900;
  min-height: 42px;
  padding: 8px 11px;
}

.reset-button.is-armed {
  background: var(--coral);
  border-color: var(--ink);
  color: var(--ink);
}

.dialog-footnote {
  font-size: .72rem !important;
  text-align: center;
}

.dialog-done {
  background: var(--sun);
  min-height: 51px;
  width: 100%;
}

/* Private family crew ----------------------------------------------------- */
.coach-actions {
  align-items: stretch;
  display: flex;
  gap: 10px;
  position: relative;
  z-index: 2;
}

.crew-button {
  background: var(--sky);
  border-radius: 18px;
  box-shadow: 0 5px 0 var(--ink);
  font-size: 1rem;
  min-height: 58px;
  padding-inline: 18px;
  white-space: nowrap;
}

.crew-button-dot,
.crew-live-signal {
  background: var(--panel);
  border: 2px solid var(--ink);
  border-radius: 50%;
  height: 13px;
  width: 13px;
}

.crew-button.is-live {
  background: var(--leaf);
}

.crew-button.is-live .crew-button-dot,
.crew-live-signal {
  animation: crew-signal 1.8s ease-in-out infinite;
  background: var(--leaf);
}

@keyframes crew-signal {
  50% { box-shadow: 0 0 0 5px rgb(112 198 107 / 28%); }
}

.crew-button-count {
  align-items: center;
  background: var(--ink);
  border-radius: 999px;
  color: white;
  display: inline-flex;
  font: 900 .7rem/1 var(--body);
  height: 22px;
  justify-content: center;
  min-width: 22px;
  padding: 3px 5px;
}

.crew-live-strip {
  align-items: center;
  background: #dff4ff;
  border: var(--line);
  border-radius: 19px;
  box-shadow: var(--shadow-card);
  display: grid;
  gap: 14px;
  grid-template-columns: auto minmax(90px, 1fr) auto auto;
  margin: -7px 12px 22px;
  padding: 9px 11px;
  position: relative;
}

.crew-live-strip::before {
  border: 2px dashed rgb(24 49 83 / 22%);
  border-radius: 14px;
  bottom: 5px;
  content: "";
  left: 5px;
  pointer-events: none;
  position: absolute;
  right: 5px;
  top: 5px;
}

.crew-live-room,
.crew-open-button {
  position: relative;
  z-index: 1;
}

.crew-live-room {
  align-items: center;
  background: transparent;
  border: 0;
  cursor: pointer;
  display: flex;
  gap: 9px;
  min-height: 46px;
  padding: 3px 7px;
  text-align: left;
}

.crew-live-room > span:last-child {
  display: grid;
}

.crew-live-room strong {
  font-family: var(--display);
  font-size: 1rem;
  line-height: 1.05;
}

.crew-live-room small {
  color: var(--ink-soft);
  font-size: .68rem;
  font-weight: 900;
}

.crew-live-signal {
  flex: 0 0 auto;
}

.crew-live-strip[data-connection="reconnecting"] .crew-live-signal,
.crew-connection-pill[data-state="reconnecting"] span {
  background: var(--sun);
}

.crew-mini-roster {
  align-items: center;
  display: flex;
  min-width: 0;
  padding-left: 8px;
  position: relative;
  z-index: 1;
}

.crew-mini-avatar {
  align-items: center;
  background: var(--avatar-color, white);
  border: 2.5px solid var(--ink);
  border-radius: 50%;
  display: flex;
  font-size: 1.15rem;
  height: 39px;
  justify-content: center;
  margin-left: -8px;
  position: relative;
  width: 39px;
}

.crew-mini-avatar.is-offline {
  filter: grayscale(1);
  opacity: .56;
}

.crew-quick-reactions,
.crew-reaction-buttons {
  display: flex;
  gap: 7px;
  position: relative;
  z-index: 1;
}

.crew-quick-reactions button,
.crew-reaction-buttons button {
  align-items: center;
  background: var(--panel);
  border: 2px solid var(--ink);
  border-radius: 12px;
  box-shadow: 0 2px 0 var(--ink);
  cursor: pointer;
  display: inline-flex;
  font-weight: 900;
  justify-content: center;
  min-height: 44px;
  padding: 6px 10px;
  transition: transform 100ms, box-shadow 100ms;
}

.crew-quick-reactions button {
  font-size: 1.1rem;
  width: 44px;
}

.crew-quick-reactions button:hover,
.crew-reaction-buttons button:hover {
  box-shadow: 0 4px 0 var(--ink);
  transform: translateY(-2px) rotate(-2deg);
}

.crew-open-button {
  background: var(--ink);
  border: 2px solid var(--ink);
  border-radius: 12px;
  color: white;
  cursor: pointer;
  font-size: .75rem;
  font-weight: 900;
  min-height: 44px;
  padding: 7px 12px;
}

.crew-role-status {
  align-items: center;
  background: rgb(255 255 255 / 72%);
  border: 2.5px dashed var(--ink);
  border-radius: 12px;
  clear: both;
  color: var(--ink);
  display: flex;
  font-size: .78rem;
  font-weight: 900;
  gap: 7px;
  justify-content: center;
  margin-top: 13px;
  min-height: 44px;
  padding: 7px 10px;
  width: 100%;
}

.crew-role-status.is-host {
  background: var(--sun);
  border-style: solid;
}

.demo-marker.is-crew {
  appearance: none;
  background: var(--sky);
  border-style: dashed;
  color: var(--ink);
  cursor: pointer;
  font-size: 1.1rem;
  height: 44px;
  opacity: .92;
  padding: 0;
  pointer-events: auto;
  width: 44px;
}

.demo-marker.is-crew:hover,
.demo-marker.is-crew:focus-visible {
  box-shadow: 0 6px 0 var(--ink);
  transform: translate(-50%, -58%) rotate(4deg);
}

.demo-marker.is-crew.is-complete {
  background: var(--leaf);
  border-style: solid;
}

.demo-marker.is-crew.is-complete::after {
  align-items: center;
  background: var(--sun);
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  content: "✓";
  display: flex;
  font: 900 .55rem/1 var(--body);
  height: 17px;
  justify-content: center;
  position: absolute;
  right: -5px;
  top: -5px;
  width: 17px;
}

.crew-dialog {
  background: transparent;
  border: 0;
  color: var(--ink);
  max-height: calc(100vh - 24px);
  max-width: min(940px, calc(100vw - 24px));
  padding: 0;
  width: 100%;
}

.crew-dialog::backdrop {
  backdrop-filter: blur(6px);
  background: rgb(24 49 83 / 62%);
}

.crew-dialog-card {
  background:
    radial-gradient(rgb(24 49 83 / 5%) 2px, transparent 2px),
    var(--paper-pale);
  background-size: 25px 25px;
  border: var(--line);
  border-radius: 27px;
  box-shadow: 0 9px 0 var(--ink);
  max-height: calc(100vh - 42px);
  overflow: auto;
  padding: clamp(22px, 4vw, 38px);
  position: relative;
}

.crew-dialog-flag {
  align-items: center;
  background: var(--sky);
  border: var(--line);
  border-radius: 50%;
  box-shadow: var(--shadow-control);
  display: flex;
  font-size: 1.8rem;
  height: 62px;
  justify-content: center;
  margin-bottom: 15px;
  transform: rotate(-7deg);
  width: 62px;
}

.crew-entry > h2,
.crew-room-header h2 {
  font-family: var(--display);
  font-size: clamp(1.8rem, 5vw, 2.75rem);
  letter-spacing: -.04em;
  line-height: 1.02;
  margin: 0;
}

.crew-entry > p,
.crew-room-header p {
  color: var(--ink-soft);
  font-size: .9rem;
  font-weight: 800;
  line-height: 1.45;
  margin: 7px 44px 18px 0;
  max-width: 690px;
}

.explorer-picker {
  border: 0;
  display: grid;
  gap: 9px;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin: 22px 0;
  padding: 0;
}

.explorer-picker legend {
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.explorer-choice {
  align-items: center;
  background: var(--panel);
  border: 2.5px solid var(--ink);
  border-radius: 15px;
  box-shadow: 0 3px 0 var(--ink);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  font-size: .7rem;
  font-weight: 900;
  gap: 5px;
  justify-content: center;
  min-height: 94px;
  padding: 8px 5px;
  position: relative;
  text-align: center;
}

.explorer-choice input {
  opacity: 0;
  position: absolute;
}

.explorer-choice:has(input:checked) {
  background: #dff4ff;
  box-shadow: 0 5px 0 var(--ink);
  transform: translateY(-2px) rotate(-1deg);
}

.explorer-choice:has(input:focus-visible) {
  outline: 4px solid #1177b2;
  outline-offset: 3px;
}

.explorer-face {
  align-items: center;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 50%;
  display: flex;
  font-size: 1.65rem;
  height: 48px;
  justify-content: center;
  width: 48px;
}

.crew-entry-actions {
  display: grid;
  gap: 15px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.create-crew-card,
.join-crew-card {
  background: var(--panel);
  border: var(--line);
  border-radius: 19px;
  box-shadow: var(--shadow-card);
  padding: 18px;
}

.create-crew-card {
  background: #e8f8e5;
  transform: rotate(-.35deg);
}

.join-crew-card {
  background: #e9f6ff;
  transform: rotate(.35deg);
}

.entry-step {
  color: var(--leaf-dark);
  font-size: .65rem;
  font-weight: 900;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.create-crew-card h3,
.join-crew-card h3,
.crew-panel h3,
.crew-cheers h3 {
  font-family: var(--display);
  font-size: 1.15rem;
  margin: 3px 0 4px;
}

.create-crew-card p,
.join-crew-card p,
.crew-cheers p,
.crew-host-controls p {
  color: var(--ink-soft);
  font-size: .75rem;
  font-weight: 800;
  line-height: 1.4;
  margin: 0;
}

.crew-grownup-check {
  align-items: center;
  background: rgb(255 255 255 / 72%);
  border: 2px solid var(--ink);
  border-radius: 11px;
  cursor: pointer;
  display: flex;
  font-size: .77rem;
  font-weight: 900;
  gap: 9px;
  margin: 14px 0 11px;
  padding: 9px;
}

.crew-grownup-check input {
  accent-color: var(--leaf-dark);
  height: 22px;
  margin: 0;
  width: 22px;
}

.create-crew-button,
.join-crew-button {
  background: var(--coral);
  min-height: 49px;
  width: 100%;
}

.join-crew-card > label {
  display: block;
  font-size: .7rem;
  font-weight: 900;
  margin: 13px 0 4px;
}

.join-crew-card input {
  background: white;
  border: var(--line);
  border-radius: 12px;
  box-shadow: 0 3px 0 var(--ink);
  font-family: var(--display);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: .25em;
  min-height: 50px;
  padding: 7px 12px;
  text-align: center;
  text-transform: uppercase;
  width: 100%;
}

.join-crew-button {
  background: var(--sky);
  margin-top: 11px;
}

.crew-entry-safety {
  background: var(--ink);
  border-radius: 13px;
  color: white !important;
  font-size: .73rem !important;
  margin: 19px 0 0 !important;
  max-width: none !important;
  padding: 11px 14px;
  text-align: center;
}

.crew-form-status {
  color: var(--coral-dark) !important;
  font-size: .8rem !important;
  font-weight: 900 !important;
  margin: 10px 0 0 !important;
  min-height: 1.2em;
  text-align: center;
}

.crew-room-header {
  align-items: start;
  display: flex;
  gap: 20px;
  justify-content: space-between;
}

.room-code-copy {
  background: var(--sun);
  border: 2.5px solid var(--ink);
  border-radius: 10px;
  box-shadow: 0 3px 0 var(--ink);
  cursor: pointer;
  font-family: var(--display);
  font-size: .85em;
  letter-spacing: .08em;
  margin-left: 6px;
  min-height: 43px;
  padding: 4px 9px;
  vertical-align: middle;
}

.room-code-copy small {
  display: block;
  font: 900 .55rem/1 var(--body);
  letter-spacing: 0;
  text-transform: uppercase;
}

.crew-connection-pill {
  align-items: center;
  background: #e8f8e5;
  border: 2px solid var(--ink);
  border-radius: 999px;
  display: inline-flex;
  flex: 0 0 auto;
  font-size: .69rem;
  font-weight: 900;
  gap: 6px;
  margin-right: 40px;
  min-height: 35px;
  padding: 6px 10px;
}

.crew-connection-pill span {
  background: var(--leaf);
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  height: 10px;
  width: 10px;
}

.crew-role-card {
  align-items: center;
  background: #fff7d6;
  border: var(--line);
  border-radius: 17px;
  box-shadow: 0 4px 0 var(--ink);
  display: flex;
  gap: 13px;
  margin-top: 17px;
  padding: 12px 15px;
}

.crew-role-card[data-role="explorer"] {
  background: #e9f6ff;
}

.crew-role-icon {
  align-items: center;
  background: var(--sun);
  border: 2px solid var(--ink);
  border-radius: 50%;
  display: flex;
  flex: 0 0 auto;
  font-size: 1.35rem;
  height: 46px;
  justify-content: center;
  transform: rotate(-4deg);
  width: 46px;
}

.crew-role-card[data-role="explorer"] .crew-role-icon {
  background: var(--sky);
  transform: rotate(4deg);
}

.crew-role-card strong {
  display: block;
  font-family: var(--display);
  font-size: 1rem;
}

.crew-role-card p {
  color: var(--ink-soft);
  font-size: .7rem;
  font-weight: 800;
  line-height: 1.35;
  margin: 2px 0 0;
}

.crew-room-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: .75fr 1.25fr;
  margin-top: 18px;
}

.crew-panel,
.crew-cheers,
.crew-host-controls {
  background: var(--panel);
  border: var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow-card);
  padding: 16px;
}

.crew-roster-panel {
  background: #e9f6ff;
}

.crew-missions-panel {
  background: #fff7d6;
}

.crew-panel-heading {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: space-between;
}

.crew-panel-heading > span {
  background: white;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-size: .65rem;
  font-weight: 900;
  padding: 5px 8px;
}

.crew-roster {
  display: grid;
  gap: 8px;
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
}

.crew-roster-member {
  align-items: center;
  background: white;
  border: 2px solid var(--ink);
  border-radius: 12px;
  display: grid;
  gap: 9px;
  grid-template-columns: auto 1fr auto;
  min-height: 50px;
  padding: 6px 8px;
}

.crew-roster-member.is-offline {
  filter: grayscale(.8);
  opacity: .6;
}

.crew-roster-avatar {
  align-items: center;
  background: var(--avatar-color, var(--paper));
  border: 2px solid var(--ink);
  border-radius: 50%;
  display: flex;
  font-size: 1.15rem;
  height: 36px;
  justify-content: center;
  width: 36px;
}

.crew-roster-member strong {
  font-family: var(--display);
  font-size: .82rem;
}

.crew-roster-member > span:nth-child(2) {
  display: grid;
  line-height: 1.15;
}

.crew-roster-member small {
  color: var(--ink-soft);
  font-size: .6rem;
  font-weight: 900;
}

.crew-mission-board {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.crew-board-mission {
  align-items: center;
  background: white;
  border: 2px solid var(--ink);
  border-radius: 12px;
  display: grid;
  gap: 8px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  min-height: 48px;
  padding: 5px 7px;
}

.crew-board-mission > span:first-child {
  align-items: center;
  background: var(--mission-color, var(--paper));
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  display: flex;
  font-size: 1rem;
  height: 32px;
  justify-content: center;
  width: 32px;
}

.crew-board-mission strong {
  font-family: var(--display);
  font-size: .78rem;
}

.crew-board-mission small {
  color: var(--ink-soft);
  display: block;
  font-size: .58rem;
  font-weight: 900;
}

.crew-board-mission button {
  background: var(--panel);
  border: 2px solid var(--ink);
  border-radius: 9px;
  cursor: pointer;
  font-size: .65rem;
  font-weight: 900;
  min-height: 36px;
  padding: 5px 7px;
}

.crew-board-actions {
  display: flex;
  gap: 5px;
  justify-content: flex-end;
}

.crew-board-actions .is-remove {
  border-color: var(--coral-dark);
  color: var(--coral-dark);
}

.crew-board-mission.is-placed {
  background: #e9f6ff;
}

.crew-board-mission.is-unplaced {
  border-style: dashed;
}

.crew-board-mission.is-complete {
  background: #dff3d9;
}

.crew-quest-empty {
  align-items: center;
  background: rgb(255 255 255 / 64%);
  border: 2px dashed var(--ink);
  border-radius: 13px;
  display: grid;
  gap: 3px 9px;
  grid-template-columns: auto 1fr;
  padding: 15px;
}

.crew-quest-empty > span {
  font-size: 1.8rem;
  grid-row: 1 / 3;
}

.crew-quest-empty strong {
  font-family: var(--display);
  font-size: .85rem;
}

.crew-quest-empty small {
  color: var(--ink-soft);
  font-size: .62rem;
  font-weight: 800;
}

.crew-cheers {
  align-items: center;
  background: #f0eaff;
  display: flex;
  gap: 20px;
  justify-content: space-between;
  margin-top: 14px;
}

.crew-reaction-buttons {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.crew-reaction-buttons button {
  font-size: .7rem;
}

.crew-reaction-buttons button span {
  font-size: 1rem;
  margin-right: 4px;
}

.crew-host-controls {
  align-items: center;
  background: #fff1e9;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  margin-top: 14px;
}

.crew-host-controls > div:last-child {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

.crew-lock-button,
.crew-end-button,
.crew-leave-button {
  background: white;
  border: 2px solid var(--ink);
  border-radius: 10px;
  cursor: pointer;
  font-size: .7rem;
  font-weight: 900;
  min-height: 42px;
  padding: 7px 10px;
}

.crew-lock-button.is-locked {
  background: var(--sun);
}

.crew-end-button {
  border-color: var(--coral-dark);
  color: var(--coral-dark);
}

.crew-end-button.is-armed {
  background: var(--coral);
  border-color: var(--ink);
  color: var(--ink);
}

.crew-room-footer {
  align-items: center;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  margin-top: 17px;
}

.crew-room-footer p {
  color: var(--ink-soft);
  font-size: .7rem;
  font-weight: 800;
  line-height: 1.35;
  margin: 0;
}

.crew-leave-button {
  flex: 0 0 auto;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.crew-reaction-pop {
  align-items: center;
  animation: crew-reaction-pop 1.8s ease-out both;
  background: var(--panel);
  border: var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow-card);
  display: flex;
  font-family: var(--display);
  font-size: .88rem;
  font-weight: 700;
  gap: 8px;
  left: 50%;
  padding: 10px 16px;
  pointer-events: none;
  position: fixed;
  top: 18%;
  transform: translateX(-50%);
  z-index: 250;
}

.crew-reaction-pop span {
  font-size: 1.5rem;
}

@keyframes crew-reaction-pop {
  0% { opacity: 0; transform: translate(-50%, 24px) scale(.85) rotate(-3deg); }
  20%, 72% { opacity: 1; transform: translate(-50%, 0) scale(1) rotate(1deg); }
  100% { opacity: 0; transform: translate(-50%, -22px) scale(.94); }
}

@media (max-width: 1180px) {
  .explorer-tablet {
    grid-template-columns: 340px minmax(0, 1fr);
  }

  .mission-rail {
    padding-inline: 18px;
  }

  .place-list {
    grid-template-columns: 1fr;
  }

  .spot-confirm {
    align-items: start;
    grid-template-columns: auto 1fr;
  }

  .spot-confirm-actions {
    grid-column: 1 / -1;
    justify-content: flex-end;
  }
}

@media (max-width: 930px) {
  .site-header,
  .app-shell {
    padding-inline: 18px;
  }

  .explorer-tablet {
    grid-template-columns: 1fr;
  }

  .mission-rail {
    border-bottom: var(--line);
    border-right: 0;
    display: grid;
    gap: 16px 18px;
    grid-template-columns: minmax(270px, .9fr) minmax(320px, 1.1fr);
    padding: 35px 20px 23px;
  }

  .rail-heading,
  .trail-progress,
  .active-mission {
    grid-column: 1;
  }

  .mission-picker {
    grid-column: 2;
    grid-row: 1 / span 3;
  }

  .mission-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sticker-pocket {
    grid-column: 1 / -1;
    margin-top: 0;
  }

  .kit-sticker {
    height: 43px;
  }

  .map-side {
    padding-top: 24px;
  }

  .explorer-picker {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .crew-room-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 740px) {
  .header-tagline,
  .sound-label {
    display: none;
  }

  .site-header {
    gap: 12px;
  }

  .header-actions {
    margin-left: auto;
  }

  .sound-button {
    min-width: 44px;
    padding-inline: 8px;
  }

  .grownup-button {
    font-size: .78rem;
    min-height: 44px;
    padding-inline: 11px;
  }

  .coach-ribbon {
    gap: 12px;
    grid-template-columns: 72px minmax(0, 1fr);
    margin-inline: 0;
    padding: 13px;
  }

  .coach-ribbon::after {
    display: none;
  }

  .pip-stage {
    height: 82px;
    width: 72px;
  }

  .pip {
    height: 103px;
    left: -15px;
    width: 96px;
  }

  .coach-actions {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: .8fr 1.2fr;
    width: 100%;
  }

  .crew-button,
  .surprise-button {
    min-height: 49px;
    padding-inline: 12px;
  }

  .crew-live-strip {
    gap: 9px;
    grid-template-columns: minmax(0, 1fr) auto;
    margin-inline: 0;
  }

  .crew-mini-roster {
    justify-content: flex-end;
  }

  .crew-quick-reactions {
    grid-column: 1;
  }

  .crew-open-button {
    grid-column: 2;
  }

  .crew-entry-actions {
    grid-template-columns: 1fr;
  }

  .crew-cheers,
  .crew-host-controls,
  .crew-room-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .crew-reaction-buttons,
  .crew-host-controls > div:last-child {
    justify-content: flex-start;
  }

  .crew-connection-pill {
    margin-right: 36px;
  }

  .mission-rail {
    display: block;
  }

  .mission-picker {
    margin-top: 0;
  }

  .mission-list {
    display: flex;
    gap: 9px;
    margin: 0 -4px;
    overflow-x: auto;
    padding: 3px 4px 8px;
    scroll-snap-type: x mandatory;
  }

  .mission-card {
    flex: 0 0 220px;
    scroll-snap-align: start;
  }

  .sticker-pocket {
    margin-top: 16px;
  }

  .map-toolbar {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .map-mode {
    align-self: flex-start;
  }

  .view-switcher {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .view-tab {
    justify-content: center;
  }

  .search-strip {
    grid-template-columns: 1fr;
  }

  .locate-button {
    min-height: 48px;
  }

  .map-workspace,
  .map-view,
  .list-view,
  .google-map,
  .practice-map {
    min-height: 520px;
  }

  .map-tip {
    bottom: 10px;
    font-size: .69rem;
    width: calc(100% - 20px);
  }

  .poi-pin {
    height: 49px;
    width: 49px;
  }

  .poi-pin span {
    font-size: 1.3rem;
  }

  .poi-label {
    font-size: .57rem;
    max-width: 92px;
  }

  .privacy-note {
    align-items: start;
    flex-wrap: wrap;
  }

  .privacy-note p {
    flex: 1 1 240px;
  }

  .privacy-note button {
    margin-left: 36px;
  }
}

@media (max-width: 520px) {
  .site-header {
    min-height: 78px;
    padding-block: 11px 7px;
  }

  .brand {
    font-size: 1.42rem;
    gap: 5px;
  }

  .brand-mark {
    height: 40px;
    width: 35px;
  }

  .grownup-button {
    font-size: 0;
    gap: 0;
    min-width: 44px;
    padding: 7px;
  }

  .grownup-button > span {
    font-size: 1rem;
  }

  .app-shell {
    padding-inline: 10px;
  }

  .coach-ribbon {
    border-radius: 19px;
  }

  .coach-copy h1 {
    font-size: 1.42rem;
  }

  .coach-copy p {
    font-size: .79rem;
  }

  .coach-actions {
    gap: 7px;
  }

  .crew-button,
  .surprise-button {
    font-size: .83rem;
  }

  .crew-live-strip {
    padding: 8px;
  }

  .crew-mini-avatar {
    font-size: 1rem;
    height: 34px;
    width: 34px;
  }

  .crew-quick-reactions {
    gap: 5px;
  }

  .crew-quick-reactions button {
    height: 42px;
    min-height: 42px;
    width: 42px;
  }

  .crew-open-button {
    padding-inline: 8px;
  }

  .crew-dialog-card {
    padding: 22px 13px;
  }

  .explorer-picker {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .explorer-choice {
    min-height: 84px;
  }

  .crew-room-header {
    display: block;
  }

  .crew-connection-pill {
    margin: 10px 0 0;
  }

  .room-code-copy {
    margin: 8px 0 0;
  }

  .crew-board-mission {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .crew-board-actions {
    grid-column: 1 / -1;
    width: 100%;
  }

  .crew-board-mission button {
    flex: 1;
    min-height: 42px;
  }

  .crew-reaction-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .crew-host-controls > div:last-child {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .explorer-tablet {
    border-radius: 23px;
  }

  .mission-rail {
    padding: 33px 13px 18px;
  }

  .rail-heading h2 {
    font-size: 1.35rem;
  }

  .active-mission {
    margin-inline: 0;
    padding: 15px;
  }

  .mission-sticker {
    font-size: 1.8rem;
    height: 61px;
    width: 61px;
  }

  .active-mission-copy p {
    font-size: .85rem;
  }

  .sticker-grid {
    gap: 6px;
  }

  .kit-sticker {
    height: 36px;
  }

  .map-side {
    padding: 24px 10px 14px;
  }

  .place-search {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .place-search button {
    border-left: 0;
    border-top: 2.5px solid var(--ink);
    grid-column: 1 / -1;
    min-height: 43px;
  }

  .place-search input {
    font-size: .8rem;
  }

  .category-row {
    margin-right: -10px;
  }

  .map-workspace,
  .map-view,
  .list-view,
  .google-map,
  .practice-map {
    min-height: 470px;
  }

  .practice-poi:nth-child(4),
  .practice-poi:nth-child(7) {
    display: none;
  }

  .spot-confirm {
    align-items: center;
    bottom: 10px;
    gap: 9px;
    grid-template-columns: auto 1fr;
    padding: 11px;
    width: calc(100% - 18px);
  }

  .spot-confirm-icon {
    font-size: 1.25rem;
    height: 46px;
    width: 46px;
  }

  .spot-confirm-actions {
    display: grid;
    grid-template-columns: 1fr auto;
    width: 100%;
  }

  .confirm-spot {
    min-height: 47px;
  }

  .list-view {
    padding: 20px 13px;
  }

  .list-view-heading {
    display: block;
  }

  .result-count {
    display: inline-block;
    margin-top: 12px;
  }

  .place-card {
    gap: 9px;
    grid-template-columns: auto minmax(0, 1fr);
  }

  .place-arrow {
    display: none;
  }

  .place-emoji {
    height: 50px;
    width: 50px;
  }

  .dialog-card {
    padding: 22px 15px;
  }

  .dialog-card > h2,
  .dialog-card > .eyebrow {
    padding-right: 36px;
  }

  .reset-section {
    align-items: stretch;
    flex-direction: column;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }

  .confetti {
    display: none;
  }
}

@media (forced-colors: active) {
  .practice-map-art {
    opacity: .45;
  }
}
