@import url("https://fonts.googleapis.com/css2?family=Great+Vibes&family=DM+Sans:ital,opsz,wght@0,9..40,500;0,9..40,600;0,9..40,700&display=swap");

:root,
[data-theme="forest"] {
  --ink: #17212b;
  --canvas: #f7f8f6;
  --surface: #ffffff;
  --green: #176b5b;
  --green-light: #ddf3ec;
  --amber: #b86b00;
  --danger: #b3261e;
  --muted: #5a6570;
  --border: #d0d8d2;
  --map-block: #d4dfd7;
  --map-road: #b0beb4;
  --map-water: #c8ddd8;
  --status-bg: rgba(255, 255, 255, 0.92);
  --phone-shadow: 0 12px 40px rgba(23, 33, 43, 0.15);
  --chip-on-tint: #ffffff;
  --primary-on: #ffffff;
  --field-bg: #ffffff;
  --field-text: #17212b;
}

[data-theme="charcoal"] {
  --ink: #f5f5f7;
  --canvas: #1c1c1e;
  --surface: #2c2c2e;
  --green: #34c759;
  --green-light: rgba(52, 199, 89, 0.15);
  --amber: #ff9f0a;
  --danger: #ff453a;
  --muted: #98989d;
  --border: rgba(255, 255, 255, 0.1);
  --map-block: #2c2c2e;
  --map-road: rgba(255, 255, 255, 0.06);
  --status-bg: rgba(28, 28, 30, 0.92);
  --phone-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
  --chip-on-tint: #3a3a3c;
  --primary-on: #1c1c1e;
  --field-bg: #3a3a3c;
  --field-text: #f5f5f7;
}

:root {
  --phone-w: 390px;
  --phone-h: 844px;
  --radius-card: 16px;
  --radius-ctrl: 12px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --phone-gutter: 16px;
  --sheet-pad-x: 16px;
  --sheet-pad-top: 20px;
  --sheet-pad-bottom: 16px;
  --sheet-pad-bottom-full: 32px;
  --screen-pad-bottom: 28px;
  --btn-gap: 10px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font);
  background: #e8eae8;
  color: #17212b;
  line-height: 1.4;
}

.page-header {
  padding: 24px 32px 8px;
  max-width: 1400px;
  margin: 0 auto;
}

.page-header h1 {
  font-size: 1.5rem;
  margin: 0 0 8px;
}

.page-header p {
  margin: 0;
  color: #5a6570;
  max-width: 60ch;
}

.page-header .fine-print {
  color: #5a6570;
}

.mockup-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.mockup-nav a {
  font-size: 0.875rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid #dfe3ea;
  background: #ffffff;
  color: #17212b;
  text-decoration: none;
}

.mockup-nav a.is-active {
  background: #176b5b;
  color: #ffffff;
  border-color: transparent;
}

.page-turn {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 8px 32px 48px;
}

.page-turn a {
  font-weight: 600;
  color: #176b5b;
  text-decoration: none;
}

.page-turn a:hover {
  text-decoration: underline;
}

.theme-pickers {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.theme-group-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #5a6570;
  margin-bottom: 6px;
}

.theme-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.theme-btn {
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid #aeb4bc;
  background: #ffffff;
  color: #17212b;
  cursor: pointer;
}

.theme-btn.is-active[data-set-theme="forest"] {
  background: #176b5b;
  color: #ffffff;
  border-color: #176b5b;
}

.theme-btn.is-active[data-set-theme="charcoal"] {
  background: #1c1c1e;
  color: #f5f5f7;
  border-color: #3a3a3c;
  box-shadow: inset 0 0 0 1px #34c759;
}

.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  padding: 24px 32px 48px;
  max-width: 1400px;
  margin: 0 auto;
  align-items: flex-start;
}

.mockup-frame {
  scroll-margin-top: 120px;
  scroll-margin-bottom: 48px;
  border-radius: 16px;
  transition: box-shadow 0.35s ease;
  outline: none;
}

.mockup-frame--focus {
  box-shadow: 0 0 0 3px var(--green), 0 12px 40px rgba(0, 0, 0, 0.12);
}

.phone {
  width: var(--phone-w);
  height: var(--phone-h);
  background: var(--canvas);
  color: var(--ink);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--phone-shadow);
  display: flex;
  flex-direction: column;
  position: relative;
}

.phone-label {
  text-align: center;
  font-size: 0.85rem;
  font-weight: 600;
  margin-top: 12px;
  color: #5a6570;
}

.status {
  height: 44px;
  background: var(--status-bg);
  color: var(--ink);
  padding: 12px 24px;
  font-weight: 600;
  font-size: 15px;
  flex-shrink: 0;
}

.map-area {
  height: 420px;
  background: var(--map-block);
  position: relative;
  flex-shrink: 0;
  overflow: hidden;
}

.map-area::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.35) 0%, transparent 28%, transparent 72%, rgba(23, 33, 43, 0.06) 100%);
  pointer-events: none;
  z-index: 1;
}

[data-theme="charcoal"] .map-area::before {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, transparent 35%, transparent 70%, rgba(0, 0, 0, 0.25) 100%);
}

.map-grid {
  position: absolute;
  inset: 0;
  background-color: var(--map-block);
  background-image:
    linear-gradient(var(--map-road) 3px, transparent 3px),
    linear-gradient(90deg, var(--map-road) 3px, transparent 3px);
  background-size: 56px 56px;
  opacity: 1;
}

[data-theme="forest"] .map-grid {
  background-image:
    linear-gradient(var(--map-road) 3px, transparent 3px),
    linear-gradient(90deg, var(--map-road) 3px, transparent 3px),
    radial-gradient(ellipse 120px 80px at 78% 22%, var(--map-water, transparent) 0%, transparent 70%);
}

.map-car-pin {
  position: absolute;
  z-index: 4;
  pointer-events: none;
}

.map-car-pin--center {
  left: 50%;
  top: 46%;
  transform: translate(-50%, -100%);
}

.map-car-pin--saved {
  left: 52%;
  top: 38%;
  transform: translate(-50%, -100%);
}

.map-car-pin__shape {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--green);
  border: 3px solid #fff;
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25);
}

.map-car-pin__icon {
  width: 20px;
  height: 20px;
  transform: rotate(45deg);
  object-fit: contain;
}

.map-car-pin--large .map-car-pin__shape {
  width: 48px;
  height: 48px;
  border-width: 3px;
}

.map-car-pin--large .map-car-pin__icon {
  width: 24px;
  height: 24px;
}

.car-chip {
  position: absolute;
  top: 12px;
  left: 16px;
  right: 16px;
  background: var(--surface);
  color: var(--ink);
  padding: 10px 16px;
  border-radius: var(--radius-ctrl);
  font-weight: 500;
  font-size: 15px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  z-index: 3;
  border: 1px solid var(--border);
}

.sheet {
  flex: 1;
  min-height: 0;
  background: var(--surface);
  border-radius: var(--radius-card) var(--radius-card) 0 0;
  padding: var(--sheet-pad-top) var(--sheet-pad-x) var(--sheet-pad-bottom);
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
}

.phone:not(:has(.nav)) .sheet {
  padding-bottom: var(--sheet-pad-bottom-full);
}

.sheet.tint {
  background: var(--green-light);
}

.sheet h2 {
  margin: 0 0 8px;
  font-size: 1.25rem;
  color: var(--ink);
}

.sheet p {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 14px;
}

.btn-primary {
  display: block;
  width: 100%;
  border: none;
  background: var(--green);
  color: var(--primary-on);
  font-size: 17px;
  font-weight: 600;
  padding: 16px;
  border-radius: var(--radius-ctrl);
  cursor: default;
  margin-top: auto;
  margin-bottom: var(--btn-gap);
}

.screen-body .btn-primary,
.sheet--confirm .btn-primary,
.sheet--compact .btn-primary {
  margin-top: 20px;
}

.screen-body--center .btn-primary:first-of-type {
  margin-top: 28px;
}

.btn-secondary {
  display: block;
  width: 100%;
  border: 1px solid var(--border);
  background: var(--canvas);
  color: var(--ink);
  font-size: 16px;
  font-weight: 500;
  padding: 12px;
  border-radius: var(--radius-ctrl);
  margin-bottom: 0;
}

.btn-secondary + .btn-secondary {
  margin-top: var(--btn-gap);
}

.sheet .btn-secondary:last-child,
.screen-body .btn-secondary:last-child {
  margin-bottom: 0;
}

.chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.chip {
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--chip-on-tint);
  color: var(--green);
}

.chip.warn {
  color: var(--amber);
}

.nav {
  display: flex;
  min-height: 84px;
  padding-bottom: 22px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

.nav span {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  padding: 10px 4px 0;
  font-size: 11px;
  color: var(--muted);
  cursor: pointer;
}

.nav span.active {
  color: var(--green);
  font-weight: 600;
}

.nav-icon {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.welcome-art,
.ob-illust {
  width: 100%;
  max-width: none;
  aspect-ratio: 4 / 3;
  margin: 0 auto 18px;
  border-radius: var(--radius-card);
  background: linear-gradient(145deg, var(--green-light) 0%, var(--surface) 55%);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

@keyframes ob-ring {
  0% {
    transform: scale(0.85);
    opacity: 0.55;
  }
  70% {
    transform: scale(1.35);
    opacity: 0;
  }
  100% {
    transform: scale(1.35);
    opacity: 0;
  }
}

/* Frame 02 — user dot, path to centered car pin */
.ob-illust--welcome-path .ob-map-user {
  position: absolute;
  left: 22%;
  top: 62%;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #3b82f6;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
  z-index: 3;
}

.ob-illust--welcome-path .ob-map-route {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
  overflow: visible;
}

.ob-illust--welcome-path .ob-map-route path {
  vector-effect: non-scaling-stroke;
}

.ob-illust--welcome-path .ob-map-car-pin--center {
  left: 50%;
  top: 42%;
}

.ob-illust--welcome-path .map-car-pin__shape {
  width: 34px;
  height: 34px;
}

.ob-illust--welcome-path .map-car-pin__icon {
  width: 17px;
  height: 17px;
}

/* Frame 04 — two phones + shared pin */
.ob-illust--dual-phone .ob-map-car-pin--shared {
  left: 50%;
  top: 40%;
  z-index: 5;
}

.ob-phone {
  position: absolute;
  bottom: 16%;
  width: 18%;
  height: 40%;
  border-radius: 11px;
  background: var(--ink);
  border: 2px solid color-mix(in srgb, var(--border) 80%, var(--ink));
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
  z-index: 3;
}

.ob-phone::before {
  content: "";
  position: absolute;
  top: 5px;
  left: 50%;
  width: 34%;
  height: 3px;
  margin-left: -17%;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.22);
  z-index: 2;
}

.ob-phone--left {
  left: 14%;
  transform: rotate(-8deg);
}

.ob-phone--right {
  right: 14%;
  transform: rotate(8deg);
}

.ob-phone-screen {
  display: block;
  position: absolute;
  inset: 8px 5px 6px;
  border-radius: 7px;
  background: linear-gradient(180deg, var(--green-light) 0%, var(--surface) 100%);
  overflow: hidden;
}

.ob-phone-screen .map-car-pin__shape {
  position: absolute;
  left: 50%;
  top: 58%;
  width: 16px;
  height: 16px;
  margin: -14px 0 0 -8px;
  border-width: 2px;
}

.ob-phone-screen .map-car-pin__icon {
  width: 9px;
  height: 9px;
}

.ob-phone-screen .ob-phone-map-pin {
  position: absolute;
  left: 50%;
  top: 58%;
  transform: translate(-50%, -100%);
}

/* Frame 05 — radar + pin */
.ob-radar {
  position: absolute;
  left: 50%;
  top: 46%;
  width: 100px;
  height: 100px;
  margin: -50px 0 0 -50px;
  border: 2px solid var(--green);
  border-radius: 50%;
  opacity: 0.35;
  animation: ob-ring 2.8s ease-out infinite;
}

.ob-radar::before {
  content: "";
  position: absolute;
  inset: 18px;
  border: 1px dashed var(--green);
  border-radius: 50%;
  opacity: 0.55;
  animation: ob-ring 2.8s ease-out 0.6s infinite;
}

.ob-map-pin--radar {
  position: absolute;
  left: 50%;
  top: 46%;
  width: 28px;
  height: 28px;
  margin: -24px 0 0 -14px;
  background: var(--green);
  border: 3px solid var(--surface);
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.22);
  z-index: 2;
  animation: ob-pin-pulse 2s ease-in-out infinite;
}

@keyframes ob-pin-pulse {
  0%,
  100% {
    transform: rotate(-45deg) translateY(0);
  }
  50% {
    transform: rotate(-45deg) translateY(-4px);
  }
}

.splash-kicker {
  margin: 0 0 4px;
  font-family: "DM Sans", system-ui, -apple-system, sans-serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.02em;
  text-transform: none;
  color: var(--ink);
}

.splash-title {
  margin: 0 0 12px;
  font-family: "Great Vibes", "Segoe Script", cursive;
  font-size: 3.75rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1;
  color: var(--ink);
}

.screen-body--hi {
  justify-content: flex-start;
  padding-top: 56px;
  padding-bottom: 32px;
}

.screen-body--hi .splash-kicker {
  margin-bottom: 6px;
  align-self: stretch;
  width: 100%;
  text-align: center;
}

.splash-tagline {
  margin: 0 0 20px;
  font-size: 17px;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: -0.01em;
  text-align: center;
  width: 100%;
}

.screen-body--hi > .btn-primary {
  margin-top: auto;
}

.splash-hero-center {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  padding: 16px 8px 8px;
}

.splash-hero-center .splash-title {
  margin-bottom: 16px;
}

.splash-hero-center .splash-rotator {
  justify-content: center;
  width: 100%;
}

.splash-hero-center .splash-line {
  text-align: center;
  padding: 0 12px;
}

.splash-rotator {
  position: relative;
  min-height: 48px;
  margin: 0 0 28px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.splash-line {
  position: absolute;
  left: 0;
  right: 0;
  margin: 0;
  padding: 0 8px;
  font-size: 16px;
  line-height: 1.45;
  color: var(--muted);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.splash-line.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.car-icon-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  background: transparent;
  border: none;
}

.car-icon-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.car-avatar .car-icon-badge {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.car-avatar-img {
  width: 26px;
  height: 26px;
  object-fit: contain;
}

.map-fab-wrap {
  position: absolute;
  left: 50%;
  right: auto;
  bottom: 28px;
  top: auto;
  transform: translateX(-50%);
  z-index: 4;
}

.fab-park {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  border: none;
  background: var(--green);
  color: #fff;
  font: inherit;
  cursor: default;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.28);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 10px;
}

.fab-park-icon {
  width: 28px;
  height: 28px;
}

.fab-park-label {
  font-size: 11px;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}

.history-day-label {
  margin: 16px 0 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.history-day-label:first-child {
  margin-top: 4px;
}

.history-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 14px 0 0;
}

.history-card {
  padding: 12px 12px;
  border-radius: var(--radius-ctrl);
  border: 1px solid var(--border);
  background: var(--surface);
  margin-bottom: 8px;
}

.history-card strong {
  display: block;
  font-size: 15px;
}

.history-card-time {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--green);
  margin-bottom: 4px;
}

.history-card-sub {
  display: block;
  font-size: 13px;
  color: var(--muted);
}

.list-actions-spaced {
  margin-top: 20px;
}

.group-hint {
  margin: -4px 0 12px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.4;
}

.fine-print--manual {
  margin-top: 14px;
  margin-bottom: 0;
}

.car-icon-opt svg {
  width: 100%;
  height: 100%;
}

.car-avatar-svg {
  width: 26px;
  height: 26px;
}

.list-row--car .list-row-body {
  flex: 1;
  min-width: 0;
}

.cars-top .list-row-body {
  flex: 1;
  min-width: 0;
}

.cars-top .car-avatar + .list-row-body {
  margin-left: 0;
}

.cars-header-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.phone--park-idle,
.phone--park-flow {
  display: flex;
  flex-direction: column;
}

.phone--park-idle .map-area--fill,
.phone--park-flow .map-area--fill {
  flex: 1;
  height: auto;
  min-height: 160px;
}

.map-fab-wrap {
  position: absolute;
  left: 50%;
  right: auto;
  bottom: 28px;
  top: auto;
  transform: translateX(-50%);
  z-index: 4;
}

.fab-park {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  border: none;
  background: var(--green);
  color: #fff;
  font: inherit;
  cursor: default;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.28);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 10px;
}

.fab-park-icon {
  width: 28px;
  height: 28px;
}

.fab-park-label {
  font-size: 11px;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}

.sheet--slide-up {
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.18);
  border-top: 3px solid var(--green);
}

.sheet-hint {
  font-size: 12px;
  color: var(--muted);
  margin: 8px 0 0;
  line-height: 1.4;
}

.note-line {
  display: inline-block;
  margin: 0 0 10px;
  padding: 6px 10px;
  font-size: 13px;
  background: var(--surface);
  color: var(--ink);
  border-radius: var(--radius-ctrl);
  border: 1px solid var(--border);
}

.list-row--history {
  align-items: flex-start;
}

.history-when {
  flex-shrink: 0;
  width: 52px;
  text-align: right;
  padding-top: 2px;
}

.history-date {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.history-time {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  margin-top: 2px;
}

.expiry-note {
  font-size: 13px;
  color: var(--amber);
  margin-top: 16px;
  text-align: center;
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--radius-ctrl);
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  box-sizing: border-box;
}

.btn-join {
  margin-top: 8px;
}

.booking-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin: 12px 0 16px;
}

.booking-slot {
  padding: 8px 4px;
  font-size: 10px;
  text-align: center;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
}

.booking-slot.is-selected {
  background: var(--green-light);
  border-color: var(--green);
  color: var(--ink);
  font-weight: 600;
}

.label-muted {
  font-weight: 400;
  color: var(--muted);
  font-size: 0.9em;
}

.car-icon-picker {
  display: block;
  margin-bottom: 16px;
}

.car-icon-picker-vehicles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.car-icon-picker-vehicles--tints {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 0;
}

.car-icon-opt {
  width: 52px;
  height: 52px;
  padding: 4px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink);
  cursor: default;
  box-sizing: border-box;
}

.car-icon-opt svg {
  width: 100%;
  height: 100%;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.car-icon-opt.is-selected {
  border-color: var(--green);
  border-width: 2px;
  padding: 3px;
}

/* Twemoji sedan/SUV recolors (mockup — prod uses dedicated assets per color) */
.car-icon-img.car-tint--white {
  filter: grayscale(1) brightness(2.1) contrast(0.85);
}

.car-icon-img.car-tint--silver {
  filter: grayscale(1) brightness(1.45) contrast(0.95);
}

.car-icon-img.car-tint--gray {
  filter: grayscale(1) brightness(0.95) contrast(1.05);
}

.car-icon-img.car-tint--blue {
  filter: hue-rotate(155deg) saturate(1.35) brightness(1.05);
}

.car-icon-img.car-tint--yellow {
  filter: hue-rotate(35deg) saturate(1.35) brightness(1.15);
}

.car-icon-img.car-tint--dark-green {
  filter: hue-rotate(85deg) saturate(1.1) brightness(0.62) contrast(1.15);
}

.car-icon-img.car-tint--green {
  filter: hue-rotate(70deg) saturate(1.2);
}

.list-row--car {
  align-items: center;
}

.car-avatar {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: transparent;
}

.cars-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}

.group-pill {
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  color: var(--green);
  background: var(--green-light);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 14px;
  cursor: default;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  cursor: default;
}

.booking-strip {
  display: flex;
  gap: 8px;
  overflow: hidden;
  margin-bottom: 12px;
}

.booking-day {
  flex: 0 0 auto;
  min-width: 52px;
  padding: 8px 6px;
  text-align: center;
  border-radius: var(--radius-ctrl);
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 11px;
  color: var(--muted);
}

.booking-day strong {
  display: block;
  font-size: 14px;
  color: var(--ink);
  margin-bottom: 2px;
}

.booking-day.is-busy {
  border-color: var(--green);
  background: var(--green-light);
}

.sheet-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 5;
}

.sheet-modal {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 6;
  padding: 20px 16px 28px;
  background: var(--surface);
  border-radius: var(--radius-card) var(--radius-card) 0 0;
  border-top: 1px solid var(--border);
}

.phone--sheet .screen-body {
  position: relative;
  flex: 1;
  min-height: 0;
}

.welcome-art__grid {
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 22px 22px;
}

.btn-google .google-mark {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.choice-card {
  text-align: left;
  width: 100%;
  padding: 14px 16px;
  margin-bottom: 10px;
  border-radius: var(--radius-ctrl);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  cursor: default;
}

.choice-card strong {
  display: block;
  font-size: 16px;
  margin-bottom: 4px;
}

.choice-card span {
  display: block;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.4;
}

.choice-card.is-selected {
  border-color: var(--green);
  box-shadow: 0 0 0 1px var(--green);
}

.screen-body {
  flex: 1;
  min-height: 0;
  padding: var(--phone-gutter);
  padding-bottom: var(--screen-pad-bottom);
  overflow: auto;
  display: flex;
  flex-direction: column;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 6px;
}

.field input,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-ctrl);
  font-size: 16px;
  font-family: inherit;
  background: var(--field-bg, var(--surface));
  color: var(--field-text, var(--ink));
  -webkit-text-fill-color: var(--field-text, var(--ink));
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--muted);
  opacity: 1;
}

body[data-appearance="light"] .btn-secondary {
  background: #ffffff;
  border-color: #b0beb4;
}

body[data-appearance="light"] .chip {
  border: 1px solid rgba(23, 107, 91, 0.2);
}

body[data-appearance="light"] .chip.warn {
  border-color: rgba(184, 107, 0, 0.35);
}

body[data-appearance="light"] .sheet.tint .chip {
  background: #ffffff;
  box-shadow: 0 1px 3px rgba(23, 33, 43, 0.08);
}

body[data-appearance="dark"] .btn-primary {
  font-weight: 700;
}

body[data-appearance="dark"] .btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.22);
}

body[data-appearance="dark"] .sheet:not(.tint) .chip,
body[data-appearance="dark"] .sheet--confirm:not(.tint) .chip {
  background: #3a3a3c;
  border: 1px solid rgba(255, 255, 255, 0.14);
}

body[data-theme="charcoal"] .sheet.tint {
  background: var(--green-light);
}

body[data-theme="charcoal"] .code-box {
  background: #3a3a3c;
  color: var(--green);
}

.screen-body--flush {
  padding-top: 8px;
}

.screen-body--center {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 32px 16px;
  text-align: center;
}

/* Onboarding: left-aligned copy; only hero illustration spans full width */
.screen-body--onboard {
  text-align: left;
  align-items: stretch;
}

.screen-body--onboard .ob-illust {
  align-self: stretch;
}

.screen-body--onboard .btn-primary,
.screen-body--onboard .btn-secondary {
  width: 100%;
}

.history-card--multiday {
  border-color: var(--green);
  background: color-mix(in srgb, var(--green-light) 40%, var(--surface));
}

.history-span-badge {
  display: inline-block;
  margin-top: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--green);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.join-banner {
  margin-top: 16px;
  padding: 14px;
  border-radius: var(--radius-ctrl);
  border: 1px dashed var(--green);
  background: color-mix(in srgb, var(--green-light) 35%, var(--surface));
}

.join-banner p {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.45;
}

.screen-title {
  margin: 0 0 8px;
  font-size: 1.35rem;
  color: var(--ink);
}

.screen-lead {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 15px;
}

.section-label {
  margin: 20px 0 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.stack-back {
  margin: 0 0 8px;
  font-size: 15px;
  color: var(--green);
  font-weight: 500;
}

.stack-back[data-goto-frame] {
  cursor: pointer;
}

.flow-hint-link {
  color: var(--green);
  text-decoration: underline;
  cursor: pointer;
}

.hint {
  margin: 10px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.welcome-title {
  margin: 0 0 12px;
  font-size: 1.5rem;
  color: var(--ink);
}

.list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 12px;
  border-radius: var(--radius-ctrl);
  background: var(--surface);
  margin-bottom: 8px;
  border: 1px solid var(--border);
}

.list-row strong {
  display: block;
  font-weight: 600;
}

.list-sub {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin-top: 2px;
}

.list-meta {
  font-size: 13px;
  color: var(--muted);
  flex-shrink: 0;
}

.list-row--selected {
  border-color: var(--green);
}

.list-row--tap {
  cursor: default;
}

.list--plain .list-row {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  margin-bottom: 0;
}

.btn-compact {
  padding: 14px;
  width: 100%;
}

.screen-body .btn-primary.btn-compact {
  margin-top: 8px;
}

.segmented {
  display: flex;
  padding: 4px;
  background: var(--surface);
  border-radius: var(--radius-ctrl);
  border: 1px solid var(--border);
}

.segmented span {
  flex: 1;
  text-align: center;
  padding: 10px 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  border-radius: 8px;
}

.segmented span.is-on {
  background: var(--green);
  color: var(--primary-on);
  font-weight: 600;
}

.map-area--tall {
  height: 520px;
  flex-shrink: 0;
}

.sheet--compact {
  flex: 1;
  padding: var(--phone-gutter);
  padding-bottom: var(--sheet-pad-bottom-full);
  border-radius: var(--radius-card) var(--radius-card) 0 0;
}

.sheet--compact .btn-primary {
  margin-top: 16px;
}

.sheet--confirm {
  box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.2);
  padding-bottom: var(--sheet-pad-bottom-full);
}

.sheet--confirm .btn-primary {
  margin-top: 16px;
}

.code-box {
  background: var(--green-light);
  text-align: center;
  padding: 20px;
  border-radius: var(--radius-ctrl);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--green);
  margin: 16px 0;
}

.gallery-section {
  max-width: 1400px;
  margin: 0 auto;
  padding: 32px 32px 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: #17212b;
}

.gallery-section:first-of-type {
  padding-top: 16px;
}

.fine-print {
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 16px;
  line-height: 1.45;
}

.screen-body--onboard .btn-primary + .btn-secondary {
  margin-top: 12px;
}

.screen-body--onboard .btn-secondary + .fine-print--manual {
  margin-top: 14px;
  margin-bottom: 0;
}

.sheet .btn-secondary + .sheet-hint {
  margin-top: 12px;
}

.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.btn-primary.btn-danger {
  background: var(--danger);
  color: #ffffff;
  border: none;
}

.btn-danger-outline {
  background: var(--surface) !important;
  color: var(--danger) !important;
  border: 1px solid var(--danger) !important;
}

.screen-title--hero {
  margin-top: 48px;
}

.screen-lead--tight {
  margin-top: 0;
  margin-bottom: 12px;
}

.map-area--dim::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  pointer-events: none;
  z-index: 2;
}

.prose-block {
  font-size: 15px;
  color: var(--muted);
  line-height: 1.5;
  margin: 0 0 16px;
}

.prose-block strong {
  color: var(--ink);
}

/* Edge-flow frames (25+) */
.car-chip--btn {
  cursor: pointer;
  font: inherit;
  appearance: none;
  border: none;
  text-align: left;
}

.car-chip--btn:hover {
  filter: brightness(1.05);
}

.chip--btn {
  cursor: pointer;
  font: inherit;
}

.inline-banner {
  margin: 0 12px 8px;
  padding: 12px 14px;
  border-radius: var(--radius-ctrl);
  border: 1px solid var(--border);
  background: var(--surface);
}

.inline-banner--warn {
  border-color: var(--amber);
  background: color-mix(in srgb, var(--amber) 12%, var(--surface));
}

.inline-banner p {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--ink);
  line-height: 1.4;
}

.inline-banner__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.inline-banner.is-dismissed {
  display: none;
}

.toast-bar {
  position: absolute;
  top: 36px;
  left: 10px;
  right: 10px;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  border-radius: var(--radius-ctrl);
  font-size: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.toast-bar--warn {
  border-color: var(--amber);
}

.btn-text {
  background: none;
  border: none;
  color: var(--green);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  white-space: nowrap;
}

.share-url-preview {
  font-family: ui-monospace, monospace;
  font-size: 11px;
  word-break: break-all;
  padding: 10px;
  border-radius: var(--radius-ctrl);
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--muted);
}

.share-targets {
  display: flex;
  gap: 8px;
  list-style: none;
  margin: 12px 0 16px;
  padding: 0;
}

.share-targets li {
  flex: 1;
  text-align: center;
  padding: 8px;
  border-radius: var(--radius-ctrl);
  background: var(--bg);
  font-size: 11px;
  color: var(--muted);
}

.sheet-modal--share {
  padding-bottom: 20px;
}

.empty-state {
  margin-top: 32px;
  text-align: center;
  padding: 24px 16px;
  border: 1px dashed var(--border);
  border-radius: var(--radius-card);
}

.empty-state p {
  margin: 0 0 16px;
  color: var(--muted);
}

.success-card {
  margin: 16px 0;
  padding: 16px;
  border-radius: var(--radius-card);
  border: 1px solid var(--green);
  background: color-mix(in srgb, var(--green-light) 40%, var(--surface));
}

.success-card__title {
  margin: 0 0 8px;
  font-weight: 600;
  color: var(--ink);
}

.success-card__body {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.45;
}

.field--error input {
  border-color: var(--danger);
}

.field-error {
  margin: 6px 0 0;
  font-size: 13px;
  color: var(--danger);
}

.sheet-action-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 4px 0 0;
}

.sheet-action {
  appearance: none;
  border: 1px solid transparent;
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  padding: 10px 6px;
  border-radius: var(--radius-ctrl);
  background: color-mix(in srgb, var(--green) 12%, var(--surface));
  color: var(--green);
  cursor: pointer;
  text-align: center;
}

body[data-appearance="dark"] .sheet.tint .sheet-action {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--green);
}

body[data-appearance="light"] .sheet.tint .sheet-action {
  background: #fff;
  border-color: rgba(23, 107, 91, 0.18);
  box-shadow: 0 1px 2px rgba(23, 33, 43, 0.06);
}

.map-prototype-links {
  position: absolute;
  inset: auto 0 10px;
  z-index: 5;
  height: 0;
  pointer-events: none;
}

.map-prototype-links__btn {
  appearance: none;
  border: none;
  margin: 0;
  padding: 6px 11px;
  border-radius: 999px;
  font: inherit;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
  pointer-events: auto;
  position: absolute;
  bottom: 0;
  max-width: calc(50% - 14px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.map-prototype-links__btn--left {
  left: 10px;
}

.map-prototype-links__btn--right {
  right: 10px;
}

.toast-bar.is-dismissed {
  display: none;
}

.toast-bar--sync {
  flex-wrap: wrap;
  row-gap: 4px;
}

.toast-bar--sync .inline-banner__dismiss {
  margin-left: auto;
}

.map-user-dot {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #3b82f6;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.2);
  top: 72%;
  left: 28%;
  z-index: 3;
}

.list-row--tap[data-goto-frame] {
  cursor: pointer;
}

/* Flow player (flow.html) — one phone, tap-through prototype */
.flow-header {
  padding-bottom: 8px;
}

.flow-header__row {
  margin: 0 0 8px;
}

.flow-header__hint {
  margin: 0 0 12px;
  font-size: 0.9rem;
  opacity: 0.85;
}

.flow-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 16px 48px;
  min-height: calc(100vh - 140px);
}

.flow-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: calc(var(--phone-w) + 32px);
}

.flow-screen[hidden] {
  display: none !important;
}

.flow-caption {
  margin: 0;
  font-size: 0.85rem;
  opacity: 0.75;
  text-align: center;
}

.flow-mode .phone {
  flex-shrink: 0;
}
