/* ============================================================
   MaaS App Demo — Interactive phone mockup
   ============================================================ */

.phone-frame {
  width: 340px;
  height: 700px;
  background: #1f2937;
  border-radius: 48px;
  padding: 14px;
  box-shadow:
    0 40px 100px rgba(15, 23, 42, .35),
    0 0 0 1px rgba(15, 23, 42, .1),
    inset 0 0 0 2px rgba(255, 255, 255, .06);
  position: relative;
  margin: 0 auto;
}
.phone-frame::before {
  content: '';
  position: absolute;
  top: 22px; left: 50%;
  transform: translateX(-50%);
  width: 110px; height: 28px;
  background: #0f172a;
  border-radius: 0 0 18px 18px;
  z-index: 10;
}
.phone-screen {
  width: 100%; height: 100%;
  background: linear-gradient(180deg, #f0f9ff 0%, #ffffff 50%, #ecfeff 100%);
  border-radius: 36px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}
/* Status bar */
.phone-status {
  height: 44px;
  padding: 10px 24px 0;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 13px; font-weight: 600;
  color: var(--ink);
  flex-shrink: 0;
}
.phone-status-right { display: flex; gap: 5px; font-size: 11px; }

/* Bottom indicator */
.phone-home-bar {
  height: 5px; width: 130px;
  background: var(--ink);
  border-radius: 3px;
  margin: 8px auto 8px;
  flex-shrink: 0;
}

/* Screen area */
.phone-body {
  flex: 1;
  overflow: hidden;
  position: relative;
}
.phone-view {
  position: absolute;
  inset: 0;
  padding: 12px 16px 16px;
  display: none;
  flex-direction: column;
  animation: phoneFadeIn .3s ease;
}
.phone-view.active { display: flex; }
@keyframes phoneFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   View: Home / Search
   ============================================================ */
.maas-greeting {
  font-size: 13.5px;
  color: var(--muted);
  margin-bottom: 4px;
}
.maas-greeting-h {
  font-size: 22px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 14px;
  letter-spacing: -0.5px;
}
.maas-search {
  background: white;
  padding: 12px 16px;
  border-radius: 16px;
  display: flex; align-items: center; gap: 10px;
  border: 1.5px solid var(--brand-primary);
  box-shadow: 0 4px 12px rgba(14, 165, 233, .15);
  cursor: pointer;
  font-size: 14px; color: var(--ink);
  margin-bottom: 16px;
}
.maas-search-ico { color: var(--brand-primary); font-size: 16px; }

.maas-section-title {
  font-size: 13px; font-weight: 600;
  color: var(--ink); margin: 14px 0 8px;
  display: flex; justify-content: space-between; align-items: center;
}
.maas-section-title a { color: var(--brand-primary); font-size: 12px; text-decoration: none; }

.maas-quick {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.maas-quick-item {
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 8px;
  text-align: center;
  cursor: pointer;
  transition: all .15s ease;
}
.maas-quick-item:hover { border-color: var(--brand-primary); background: rgba(14, 165, 233, .04); }
.maas-quick-ico { font-size: 20px; }
.maas-quick-label { font-size: 11px; font-weight: 600; color: var(--ink-2); margin-top: 4px; }

.maas-modes {
  display: flex; gap: 6px; overflow-x: auto;
  padding-bottom: 4px; margin-bottom: 10px;
}
.maas-mode-chip {
  flex-shrink: 0;
  background: white;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 11.5px; font-weight: 600;
  color: var(--ink-2);
  cursor: pointer;
  display: flex; align-items: center; gap: 4px;
  transition: all .15s ease;
}
.maas-mode-chip.on {
  background: var(--ink);
  color: white;
  border-color: var(--ink);
}

.maas-map-preview {
  background: linear-gradient(135deg, #dbeafe 0%, #ecfdf5 100%);
  border-radius: 16px;
  height: 200px;
  position: relative;
  overflow: hidden;
  margin-top: auto;
  border: 1px solid var(--line);
}
.maas-map-preview::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(45deg, rgba(14, 165, 233, .05) 0 1px, transparent 1px 20px),
    repeating-linear-gradient(-45deg, rgba(16, 185, 129, .04) 0 1px, transparent 1px 30px);
}
.maas-map-marker {
  position: absolute;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--brand-primary);
  border: 3px solid white;
  box-shadow: 0 2px 8px rgba(14, 165, 233, .4);
  display: grid; place-items: center;
  color: white;
  font-size: 11px;
  font-weight: 700;
}
.maas-map-route {
  position: absolute;
  top: 50%; left: 16px; right: 16px;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-accent));
  border-radius: 2px;
}

/* ============================================================
   View: Route Options
   ============================================================ */
.maas-trip-head {
  background: white;
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 12px;
  font-size: 12px;
  border: 1px solid var(--line);
}
.maas-trip-row { display: flex; align-items: center; gap: 10px; padding: 4px 0; }
.maas-trip-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--brand-primary);
  flex-shrink: 0;
}
.maas-trip-dot.dest { background: var(--brand-accent); }
.maas-trip-label { color: var(--muted); width: 32px; font-size: 10px; }
.maas-trip-place { font-weight: 600; color: var(--ink); font-size: 13px; }
.maas-trip-line {
  width: 2px; height: 14px;
  background: linear-gradient(180deg, var(--brand-primary), var(--brand-accent));
  margin-left: 14px;
  border-radius: 2px;
}

.maas-route-list {
  display: flex; flex-direction: column; gap: 8px;
  overflow-y: auto;
}
.maas-route-card {
  background: white;
  border-radius: 14px;
  padding: 12px;
  border: 1.5px solid var(--line);
  cursor: pointer;
  transition: all .15s ease;
}
.maas-route-card.recommended {
  border-color: var(--brand-primary);
  background: linear-gradient(135deg, white 0%, rgba(14, 165, 233, .03) 100%);
}
.maas-route-card:hover { border-color: var(--brand-primary); transform: translateX(2px); }
.maas-route-top {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 8px;
}
.maas-route-modes { display: flex; gap: 4px; align-items: center; }
.maas-route-mode {
  display: inline-grid; place-items: center;
  width: 26px; height: 26px;
  border-radius: 8px;
  background: var(--paper-3);
  font-size: 13px;
}
.maas-route-mode.rail { background: rgba(14, 165, 233, .15); color: var(--mode-rail); }
.maas-route-mode.bus { background: rgba(22, 163, 74, .15); color: var(--mode-bus); }
.maas-route-mode.boat { background: rgba(6, 182, 212, .15); color: var(--mode-boat); }
.maas-route-mode.taxi { background: rgba(245, 158, 11, .15); color: var(--mode-taxi); }
.maas-route-mode.moto { background: rgba(236, 72, 153, .15); color: var(--mode-moto); }
.maas-route-mode.walk { background: var(--paper-3); color: var(--mode-walk); }
.maas-route-arrow { color: var(--muted); font-size: 12px; }
.maas-route-tag {
  font-size: 10px; font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
}
.maas-route-tag.recommended { background: var(--brand-primary); color: white; }
.maas-route-tag.cheapest { background: var(--brand-accent); color: white; }
.maas-route-tag.fastest { background: var(--brand-warm); color: white; }

.maas-route-bottom {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 12px;
}
.maas-route-time { font-weight: 700; color: var(--ink); font-size: 14px; }
.maas-route-fare { font-weight: 700; color: var(--brand-accent); font-size: 14px; }

/* ============================================================
   View: Route Detail
   ============================================================ */
.maas-detail-map {
  background: linear-gradient(135deg, #dbeafe 0%, #d1fae5 100%);
  border-radius: 14px;
  height: 140px;
  position: relative;
  margin-bottom: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
}
.maas-detail-map::before {
  content: '';
  position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(0deg, rgba(14, 165, 233, .06) 0 1px, transparent 1px 24px),
    repeating-linear-gradient(90deg, rgba(14, 165, 233, .06) 0 1px, transparent 1px 24px);
}
.maas-detail-map svg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
}

.maas-step {
  background: white;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 6px;
  display: flex; align-items: center; gap: 10px;
  border: 1px solid var(--line);
  font-size: 12.5px;
}
.maas-step-ico {
  width: 32px; height: 32px;
  border-radius: 10px;
  background: var(--paper-3);
  display: grid; place-items: center;
  font-size: 16px;
  flex-shrink: 0;
}
.maas-step.rail .maas-step-ico { background: rgba(14, 165, 233, .15); }
.maas-step.walk .maas-step-ico { background: var(--paper-3); }
.maas-step.moto .maas-step-ico { background: rgba(236, 72, 153, .15); }
.maas-step-body { flex: 1; }
.maas-step-name { font-weight: 600; color: var(--ink); font-size: 13px; }
.maas-step-meta { font-size: 11px; color: var(--muted); margin-top: 2px; }
.maas-step-time { font-size: 11.5px; color: var(--ink-2); font-weight: 600; }

.maas-detail-foot {
  margin-top: auto;
  background: white;
  border-radius: 16px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: center;
}
.maas-detail-fare { font-size: 20px; font-weight: 800; color: var(--ink); }
.maas-detail-fare small { font-size: 11px; color: var(--muted); font-weight: 500; display: block; }
.maas-detail-cta {
  background: var(--brand-primary);
  color: white;
  border: 0;
  padding: 10px 20px;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 700; font-size: 13px;
  cursor: pointer;
}
.maas-detail-cta:hover { background: #0284c7; }

/* ============================================================
   View: Payment
   ============================================================ */
.maas-pay-amount {
  text-align: center;
  margin: 14px 0 20px;
}
.maas-pay-amount-label { font-size: 12px; color: var(--muted); }
.maas-pay-amount-n { font-size: 38px; font-weight: 800; color: var(--ink); letter-spacing: -1px; }
.maas-pay-amount-cur { font-size: 14px; color: var(--muted); margin-left: 4px; }

.maas-pay-method {
  background: white;
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 8px;
  display: flex; align-items: center; gap: 12px;
  border: 1.5px solid var(--line);
  cursor: pointer;
  font-size: 13px;
}
.maas-pay-method.on {
  border-color: var(--brand-primary);
  background: rgba(14, 165, 233, .04);
}
.maas-pay-ico {
  width: 36px; height: 24px;
  border-radius: 5px;
  display: grid; place-items: center;
  font-size: 11px; font-weight: 800;
  color: white;
  flex-shrink: 0;
}
.maas-pay-ico.visa { background: linear-gradient(135deg, #1a1f71 0%, #1565c0 100%); }
.maas-pay-ico.qr { background: white; color: var(--ink); border: 1px solid var(--ink); font-size: 9px; }
.maas-pay-ico.mm { background: linear-gradient(135deg, #ec4899 0%, #f59e0b 100%); }
.maas-pay-body { flex: 1; }
.maas-pay-name { font-weight: 600; color: var(--ink); font-size: 12.5px; }
.maas-pay-meta { font-size: 11px; color: var(--muted); margin-top: 1px; }
.maas-pay-check { color: var(--brand-primary); font-size: 16px; }
.maas-pay-method:not(.on) .maas-pay-check { color: var(--line-2); }

.maas-pay-confirm {
  margin-top: auto;
  background: var(--brand-accent);
  color: white;
  border: 0;
  padding: 14px;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.maas-pay-confirm:hover { background: #059669; }

/* ============================================================
   View: In Trip
   ============================================================ */
.maas-trip-status {
  background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-secondary) 100%);
  color: white;
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 12px;
}
.maas-trip-status-label { font-size: 11px; opacity: .85; letter-spacing: 1px; text-transform: uppercase; }
.maas-trip-status-h { font-size: 18px; font-weight: 700; margin: 4px 0; }
.maas-trip-status-time { font-size: 26px; font-weight: 800; letter-spacing: -1px; }
.maas-trip-status-time small { font-size: 12px; font-weight: 500; opacity: .85; margin-left: 4px; }

.maas-trip-progress {
  background: white;
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 12px;
  border: 1px solid var(--line);
}
.maas-trip-progress-h {
  font-size: 12px; font-weight: 700;
  color: var(--ink); margin-bottom: 12px;
}
.maas-trip-line-stations {
  position: relative;
  padding-left: 26px;
}
.maas-trip-line-stations::before {
  content: ''; position: absolute;
  left: 7px; top: 8px; bottom: 8px;
  width: 3px; background: var(--brand-primary);
  border-radius: 2px;
}
.maas-trip-station {
  position: relative;
  font-size: 12px;
  padding: 4px 0;
  display: flex; justify-content: space-between;
  color: var(--ink-3);
}
.maas-trip-station::before {
  content: ''; position: absolute;
  left: -23px; top: 8px;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: white;
  border: 2.5px solid var(--brand-primary);
}
.maas-trip-station.passed { color: var(--muted); }
.maas-trip-station.passed::before { background: var(--brand-primary); }
.maas-trip-station.current { font-weight: 700; color: var(--ink); }
.maas-trip-station.current::before {
  background: var(--brand-warm);
  border-color: var(--brand-warm);
  width: 14px; height: 14px;
  left: -25px; top: 7px;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, .25);
}

.maas-trip-actions {
  margin-top: auto;
  display: flex; gap: 8px;
}
.maas-trip-action {
  flex: 1;
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.maas-trip-action:hover { border-color: var(--brand-primary); }
.maas-trip-action-ico { font-size: 18px; }

/* ============================================================
   Phone screen header / back button
   ============================================================ */
.phone-app-head {
  display: flex; align-items: center; gap: 10px;
  padding-bottom: 12px;
}
.phone-back {
  background: white;
  border: 1px solid var(--line);
  width: 32px; height: 32px;
  border-radius: 50%;
  font-size: 16px;
  color: var(--ink);
  cursor: pointer;
}
.phone-back:hover { background: var(--paper-2); }
.phone-app-title {
  font-size: 15px; font-weight: 700;
  color: var(--ink);
}

/* ============================================================
   Demo container styles (when embedded in slide)
   ============================================================ */
.maas-demo-wrap {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 40px;
  align-items: center;
  margin: 20px 0;
}
@media (max-width: 980px) { .maas-demo-wrap { grid-template-columns: 1fr; } }
.maas-demo-info {
  display: flex; flex-direction: column;
  gap: 14px;
}
.maas-demo-step {
  background: white;
  padding: 14px 16px;
  border-radius: 12px;
  border-left: 3px solid var(--line);
  cursor: pointer;
  transition: all .2s ease;
}
.maas-demo-step.active {
  border-left-color: var(--brand-primary);
  background: linear-gradient(90deg, rgba(14, 165, 233, .08) 0%, transparent 80%);
  transform: translateX(4px);
}
.maas-demo-step h4 {
  font-size: 14px; font-weight: 700;
  color: var(--ink); margin-bottom: 4px;
}
.maas-demo-step p {
  font-size: 12.5px; color: var(--muted);
  line-height: 1.5;
}
.maas-demo-step .step-num {
  display: inline-grid; place-items: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--paper-3);
  color: var(--muted);
  font-size: 11px; font-weight: 700;
  margin-right: 8px;
}
.maas-demo-step.active .step-num {
  background: var(--brand-primary);
  color: white;
}
