/* ============================================================
   Home – travel-journal map + flat station timeline
   ============================================================ */
.home { --mk-fill: var(--navy); --mk-ink: #fffcf6; --mk-ring: #fffcf6; --mk-sel: var(--accent); --mk-sel-ink: #1c2445;
  --map-ripple: color-mix(in srgb, var(--map-water-2) 70%, var(--map-land-edge)); --map-ink: var(--ink); }
:root[data-theme='dark'] .home { --mk-fill: #f4efe2; --mk-ink: #151e42; --mk-ring: #0d1330; --map-ripple: var(--map-land-edge); }
@media (prefers-color-scheme: dark) { :root:not([data-theme='light']) .home { --mk-fill: #f4efe2; --mk-ink: #151e42; --mk-ring: #0d1330; --map-ripple: var(--map-land-edge); } }

/* ---------- map card ---------- */
.map-card { margin: 4px 0 0; position: relative; }
.map-stage {
  position: relative; height: clamp(300px, 47vh, 460px); border-radius: var(--r-xl); overflow: hidden; isolation: isolate;
  background: radial-gradient(120% 90% at 50% 40%, var(--map-water) 0%, var(--map-water) 55%, var(--map-water-2) 100%);
  border: 1px solid var(--line); box-shadow: var(--sh-2);
}
.map-canvas { position: absolute; inset: 0; overflow: hidden; border-radius: inherit; }
.map-base-svg { position: absolute; max-width: none; pointer-events: none; transform-origin: 0 0; will-change: transform; }
.map-svg { z-index: 1; }
.map-canvas.is-moving .stub, .map-canvas.is-moving .home-chip { opacity: 0; }
.stub, .home-chip { transition: opacity .15s; }
.map-svg { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: pan-y; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; }
.map-canvas:not(.has-geo) .map-svg { background: linear-gradient(100deg, transparent 30%, color-mix(in srgb, var(--surface) 22%, transparent) 50%, transparent 70%) 0 0 / 250% 100%; animation: mapShimmer 1.6s linear infinite; }
@keyframes mapShimmer { to { background-position: -150% 0; } }
.map-paper {
  position: absolute; inset: 0; pointer-events: none; z-index: 2; border-radius: inherit;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.35 0 0 0 0 0.28 0 0 0 0 0.16 0 0 0 .5 0'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: .22; mix-blend-mode: multiply;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.35), inset 0 0 60px rgba(80, 60, 20, .10);
}
:root[data-theme='dark'] .map-paper { opacity: .10; mix-blend-mode: screen; box-shadow: inset 0 0 70px rgba(0, 0, 0, .45); }
@media (prefers-color-scheme: dark) { :root:not([data-theme='light']) .map-paper { opacity: .10; mix-blend-mode: screen; box-shadow: inset 0 0 70px rgba(0, 0, 0, .45); } }

/* geography */
.map-base * { vector-effect: non-scaling-stroke; }
.map-grat { fill: none; stroke: var(--map-grat); stroke-width: 1; }
.map-ripple { fill: none; stroke: var(--map-ripple); stroke-linejoin: round; }
.map-ripple.r1 { stroke-width: 5; opacity: .40; }
.map-ripple.r2 { stroke-width: 11; opacity: .18; }
.map-ripple.r3 { stroke-width: 19; opacity: .08; }
.map-land { fill: var(--map-land); stroke: none; }
.map-coast { fill: none; stroke: var(--map-land-edge); stroke-width: 1; stroke-linejoin: round; }
.map-borders { fill: none; stroke: var(--map-border); stroke-width: 1; stroke-dasharray: 4 3; }
.map-states { fill: none; stroke: var(--map-state); stroke-width: .8; }
.map-canvas.has-geo .map-base { animation: fade .5s var(--ease); }

/* compass */
.map-compass { pointer-events: none; opacity: .55; }
.cmp-ring { fill: none; stroke: var(--map-land-edge); stroke-width: 1; stroke-dasharray: 2 2.5; }
.cmp-star { fill: var(--map-land); stroke: var(--map-land-edge); stroke-width: .9; }
.cmp-n { fill: var(--ink-2); }
.cmp-t { font: 700 9px/1 var(--font-ui); fill: var(--ink-2); text-anchor: middle; }

/* route */
.map-route path { fill: none; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
.leg { stroke: var(--route-plan); stroke-width: 2.2; stroke-dasharray: 1.5 6.5; }
.leg.is-booked { stroke: var(--route); stroke-width: 2.6; stroke-dasharray: none; }
.leg.is-option { stroke-dasharray: 1.5 6.5; }
.stub { stroke: var(--route-plan); stroke-width: 2; stroke-dasharray: 1.5 6; opacity: .9; }
.stub.is-booked { stroke: var(--route); stroke-dasharray: 6 4; }

.map-deco { pointer-events: none; }
.badge circle, .lbadge circle { fill: var(--surface); stroke: var(--route-plan); stroke-width: 1.3; stroke-dasharray: 2.5 2; }
.badge, .lbadge { color: var(--ink); }
.badge[data-status='booked'] circle, .lbadge[data-status='booked'] circle { fill: var(--route); stroke: var(--mk-ring); stroke-dasharray: none; stroke-width: 1.5; }
.badge[data-status='booked'], .lbadge[data-status='booked'] { color: var(--surface); }
.badge[data-status='none'] circle { stroke: var(--warn); }
.b-q { font: 800 13px/1 var(--font-ui); fill: var(--warn); text-anchor: middle; dominant-baseline: central; }
.badge, .lbadge { filter: drop-shadow(0 1px 1.5px rgba(28, 36, 69, .18)); }

.home-chip rect { fill: var(--surface); stroke: var(--line-2); stroke-width: 1; }
.home-chip { color: var(--ink); filter: drop-shadow(0 1px 2px rgba(28, 36, 69, .16)); }
.home-chip[data-status='none'] rect { stroke-dasharray: 3 2.5; }
.hc-t { font: 700 12px/1 var(--font-ui); fill: var(--ink); dominant-baseline: central; letter-spacing: .01em; }

/* labels */
.lbl { cursor: pointer; }
.lbl-t { font: 600 14px/1 var(--font-display);  fill: var(--ink); dominant-baseline: central; paint-order: stroke; stroke: var(--label-halo); stroke-width: 4px; stroke-linejoin: round; letter-spacing: -.005em; }
.lbl-hl { fill: var(--accent); opacity: 0; transform: skewX(-8deg); transform-box: fill-box; transform-origin: center; transition: opacity .2s; }
.lbl.is-sel .lbl-hl { opacity: .85; }
.lbl.is-sel .lbl-t { stroke: transparent; fill: #1c2445; }

/* markers */
.mk { cursor: pointer; outline: none; }
.mk-hit { fill: transparent; }
.mk-glow { fill: none; }
.mk-dot { fill: var(--mk-fill); stroke: var(--mk-ring); stroke-width: 2.5; filter: drop-shadow(0 1.5px 2px rgba(20, 26, 55, .35)); transition: fill .2s; }
.mk-num { font: 800 12px/1 var(--font-ui); fill: var(--mk-ink); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.mk-body { transform-box: fill-box; transform-origin: center; transition: transform .25s var(--ease); }
.mk:hover .mk-body { transform: scale(1.08); }
.mk.is-sel .mk-body { transform: scale(1.2); animation: mkPop .45s var(--ease); }
.mk.is-sel .mk-dot { fill: var(--mk-sel); stroke: #1c2445; stroke-width: 2; }
.mk.is-sel .mk-num { fill: var(--mk-sel-ink); }
.mk-pulse { fill: none; stroke: var(--accent); stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.mk.is-sel .mk-pulse { animation: mkPulse 2.2s ease-out infinite; }
.mk-focus { fill: none; stroke: #3a67d8; stroke-width: 2.5; opacity: 0; }
.mk:focus-visible .mk-focus { opacity: 1; }
@keyframes mkPop { 0% { transform: scale(1); } 45% { transform: scale(1.38); } 100% { transform: scale(1.2); } }
@keyframes mkPulse { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(2.3); } }
:root[data-theme='dark'] .mk-glow { fill: rgba(246, 200, 58, .16); }
@media (prefers-color-scheme: dark) { :root:not([data-theme='light']) .mk-glow { fill: rgba(246, 200, 58, .16); } }
:root[data-theme='dark'] .mk-focus { stroke: #f6c83a; }
@media (prefers-color-scheme: dark) { :root:not([data-theme='light']) .mk-focus { stroke: #f6c83a; } }
.map-canvas.is-paused * { animation-play-state: paused !important; }

/* companion (SVG layer below labels/markers) */
.map-buddy { pointer-events: none; }
.buddy { pointer-events: none; transition: opacity .38s; }
.buddy.is-hidden, .buddy.is-fading { opacity: 0; }
.buddy-inner { transform-box: fill-box; transform-origin: 50% 90%; }
.buddy-img { filter: drop-shadow(0 3px 3px rgba(20, 26, 55, .28)); transform-box: fill-box; transform-origin: 50% 100%; animation: buddyBreathe 3.6s ease-in-out infinite; }
.buddy.is-moving .buddy-img { animation: buddyHop .46s ease-in-out infinite; }
.buddy.is-hop .buddy-img { animation: buddyJump .55s var(--ease) 1, buddyBreathe 3.6s ease-in-out .55s infinite; }
@keyframes buddyBreathe { 50% { transform: translateY(-1.5px) rotate(-1.2deg); } }
@keyframes buddyHop { 0%, 100% { transform: translateY(0) rotate(1.5deg); } 50% { transform: translateY(-3.5px) rotate(-1.5deg); } }
@keyframes buddyJump { 40% { transform: translateY(-10px) scale(1.04, .98); } 70% { transform: translateY(0) scale(1.03, .96); } }

/* map overlays */
.map-fit { position: absolute; top: 10px; right: 10px; z-index: 4; width: 44px; height: 44px; border-radius: 14px; border: 1px solid var(--line); background: color-mix(in srgb, var(--surface) 92%, transparent); color: var(--ink); display: grid; place-items: center; box-shadow: var(--sh-1); animation: fade .2s; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.map-error { position: absolute; z-index: 5; left: 50%; top: 42%; transform: translate(-50%, -50%); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; text-align: center; box-shadow: var(--sh-2); width: min(280px, calc(100% - 32px)); display: grid; gap: 8px; justify-items: center; font-size: 14px; }
.map-empty { position: absolute; inset: 0; display: grid; place-items: center; z-index: 3; pointer-events: none; }
.map-empty span { background: var(--surface); padding: 8px 14px; border-radius: 999px; font-weight: 700; color: var(--ink-2); box-shadow: var(--sh-1); font-size: 14px; }

.map-pill {
  position: absolute; z-index: 4; left: 50%; bottom: 10px; transform: translate(-50%, 16px); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 2px; max-width: calc(100% - 20px); min-width: 220px; padding: 3px;
  background: color-mix(in srgb, var(--surface) 94%, transparent); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--sh-2);
  backdrop-filter: blur(10px) saturate(1.3); -webkit-backdrop-filter: blur(10px) saturate(1.3);
  transition: transform .32s var(--ease), opacity .25s;
}
.map-pill.is-on { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
.pill-arrow { width: 44px; height: 44px; flex: none; border: 0; border-radius: 14px; background: transparent; color: var(--ink); display: grid; place-items: center; -webkit-tap-highlight-color: transparent; }
.pill-arrow:hover:not(:disabled) { background: var(--surface-3); }
.pill-arrow:disabled { opacity: .28; cursor: default; }
.pill-text { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; gap: 9px; animation: pillIn .3s var(--ease); }
.pill-idx { flex: none; font: 800 11.5px/1 var(--font-ui); letter-spacing: .02em; color: #fff; background: var(--accent); border-radius: 999px; padding: 5px 7px; font-variant-numeric: tabular-nums; }
.pill-main { min-width: 0; display: flex; flex-direction: column; line-height: 1.15; }
.pill-name { font-family: var(--font-display); font-weight: 650; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.01em; }
.pill-meta { font-size: 12px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
@keyframes pillIn { from { opacity: 0; transform: translateX(6px); } }

/* ---------- trip heading ---------- */
.trip-head { margin: 12px 2px 10px; display: flex; align-items: center; gap: 10px; }
.trip-head-main { flex: 1 1 auto; min-width: 0; }
.trip-add { flex: none; }
.trip-name { font-family: var(--font-display); font-weight: 650; font-size: 22px; letter-spacing: -0.02em; line-height: 1.15; display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; }
.trip-name .demo-badge { font-family: var(--font-ui); }
.trip-meta { color: var(--ink-3); font-size: 13px; margin-top: 2px; font-weight: 600; }

/* ---------- stations timeline ---------- */
.stations { --tl-x: 77px; position: relative; }
.st-card {
  position: relative; z-index: 1; display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 0;
  min-height: 68px; padding: 6px 6px 6px 2px; border-radius: var(--r-l); background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--sh-1); text-decoration: none; color: inherit; -webkit-tap-highlight-color: transparent;
  transition: border-color .2s, box-shadow .2s, transform .12s;
}
.st-card:active { transform: scale(.99); }
.st-card:hover { border-color: var(--line-2); }
.st-card.is-selected { border-color: color-mix(in srgb, var(--accent) 80%, var(--line-2)); box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 45%, transparent), var(--sh-1); }
.st-thumb { position: relative; width: 56px; height: 56px; }
.st-img { width: 56px; height: 56px; border-radius: 13px; object-fit: cover; background: var(--surface-3); }
.st-thumb .place-fallback { font-size: 17px; }
.st-num { position: absolute; left: -5px; top: -5px; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 999px; background: var(--mk-fill); color: var(--mk-ink); font: 800 11.5px/22px var(--font-ui); text-align: center; box-shadow: 0 0 0 2px var(--surface); }
.st-card.is-selected .st-num { background: var(--accent); color: #fff; }
.st-main { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.st-name { font-family: var(--font-display); font-weight: 650; font-size: 17px; letter-spacing: -.012em; line-height: 1.1; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow-wrap: anywhere; }
.st-meta { display: flex; align-items: center; gap: 7px; min-width: 0; font-size: 13px; color: var(--ink-2); font-weight: 550; }
.st-when { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.st-dot { margin: 0 4px; color: var(--ink-3); }
.st-stay { flex: none; display: inline-flex; align-items: center; gap: 3px; height: 20px; padding: 0 6px 0 5px; border-radius: 999px; font-size: 11.5px; font-weight: 700; }
.st-stay.tone-ok { background: var(--ok-bg); color: var(--ok); }
.st-stay.tone-info { background: var(--info-bg); color: var(--ink); }
.st-stay.tone-warn { background: var(--warn-bg); color: var(--warn); }
.st-more { display: grid; place-items: center; min-width: 44px; min-height: 52px; color: var(--ink); border-radius: 12px; }
.st-more-ico { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-3); transition: background .15s, transform .2s var(--ease); }
.st-card:hover .st-more-ico { background: var(--accent); color: #fff; transform: translateX(2px); }

.conn-row {
  position: relative; display: flex; align-items: center; gap: 2px; min-height: 48px; padding: 4px 4px 4px 3px;
  text-decoration: none; color: inherit; border-radius: 14px; -webkit-tap-highlight-color: transparent;
}
.conn-row::before { content: ''; position: absolute; left: var(--tl-x); top: -10px; bottom: -10px; border-left: 2px dotted var(--line-2); transform: translateX(-1px); z-index: 0; }
.conn-row.is-first::before { top: 50%; }
.conn-row.is-last::before { bottom: 50%; }
.conn-row:hover { background: color-mix(in srgb, var(--surface-3) 60%, transparent); }
.conn-row .tl { flex: 1 1 auto; min-width: 0; position: relative; z-index: 1; gap: 24px; }
.conn-go { flex: none; color: var(--ink-3); width: 22px; display: grid; place-items: center; }
.conn-row.is-local { min-height: 44px; padding-top: 2px; padding-bottom: 2px; }
.conn-row.is-local .tl-bubble { width: 26px; height: 26px; margin: 0 3px; }
.conn-row.is-local .tl-head { font-size: 13px; }

/* TransferLine (shared component; styles live with its owner) */
.tl { display: flex; align-items: center; gap: 12px; min-width: 0; }
.tl-bubble { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--bg); color: var(--ink); border: 1.5px dashed var(--route-plan); }
.tl.is-booked .tl-bubble { background: var(--navy); color: var(--surface); border: 2px solid var(--bg); box-shadow: 0 0 0 1.5px var(--navy); }
.tl.is-option .tl-bubble { border-style: dotted; }
.tl.is-none .tl-bubble { border-color: var(--warn); color: var(--warn); }
.tl-q { font: 800 15px/1 var(--font-ui); }
.tl-body { min-width: 0; display: flex; flex-direction: column; gap: 1px; flex: 1 1 auto; }
.tl-top { display: flex; align-items: center; gap: 6px; min-width: 0; }
.tl-head { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.tl-chip { height: 19px; font-size: 10.5px; padding: 0 6px; flex: none; }
.tl-sub { font-size: 12.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 550; }
.tl.is-none .tl-sub { color: var(--warn); }
.tl-compact { gap: 10px; }
.tl-cico { flex: none; width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: var(--surface-3); color: var(--ink); }
.tl-compact.is-booked .tl-cico { background: var(--navy); color: var(--surface); }
.tl-compact.is-none .tl-cico { color: var(--warn); }

.add-stop-row {
  width: 100%; margin-top: 10px; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 6px 12px;
  border: 1.5px dashed var(--line-2); border-radius: var(--r-l); background: transparent; color: var(--ink); text-align: left;
  -webkit-tap-highlight-color: transparent; transition: background .15s, border-color .15s;
}
.add-stop-row:hover { background: var(--surface); border-color: var(--ink-3); }
.add-ico { width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; flex: none; }
.add-t { font-weight: 700; font-size: 15px; min-width: 0; line-height: 1.25; }
.add-after { font-weight: 550; color: var(--ink-3); font-size: 13.5px; }
.home-credit { margin: 10px 4px 0; font-size: 10.5px; color: var(--ink-3); text-align: center; opacity: .8; }

@media (min-width: 560px) {
  .st-card { min-height: 76px; }
}
.as-attrib { margin: 4px 2px 0; font-size: 10.5px; color: var(--ink-3); text-align: right; }


/* ---------- Ablauf: head, drag & drop, tray, activity timeline ---------- */
.stations-wrap { margin-top: 4px; }
.stations-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 10px 2px 8px; }
.stations-title { font-size: 12px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--ink-3); }
.conn-link { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; gap: 6px; min-height: 44px; padding-left: 12px; text-decoration: none; color: inherit; border-radius: 12px; position: relative; z-index: 1; }
.conn-link .tl { flex: 1 1 auto; min-width: 0; gap: 14px; }
.conn-more { flex: none; font-size: 11px; font-weight: 800; color: var(--ink-2); background: var(--surface-3); border-radius: 999px; padding: 2px 7px; }
.conn-grip, .st-grip {
  flex: none; width: 44px; height: 44px; border: 0; padding: 0; background: none; border-radius: 9px; color: var(--ink-3);
  display: grid; place-items: center; cursor: grab; touch-action: none; -webkit-user-select: none; user-select: none; position: relative; z-index: 2;
}
.st-grip { height: 58px; }
.conn-grip:hover, .st-grip:hover { color: var(--ink); background: var(--surface-3); }
.conn-grip.is-empty { cursor: default; pointer-events: none; }
.conn-grip:active, .st-grip:active { cursor: grabbing; }
.st-body { display: grid; grid-template-columns: 56px minmax(0, 1fr); align-items: center; gap: 12px; min-height: 58px; padding: 0; border: 0; background: none; color: inherit; text-align: left; border-radius: 12px; -webkit-tap-highlight-color: transparent; }
.st-acts-toggle { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; color: var(--ink-3); }
.st-chev { display: inline-grid; transition: transform .22s var(--ease); }
.st-card.is-open .st-chev { transform: rotate(180deg); }
.st-card.is-open { border-bottom-left-radius: 6px; border-bottom-right-radius: 6px; }
.st-card.is-open .st-acts-toggle { color: var(--ink); }

.drop-indicator { display: none; position: absolute; left: 48px; right: 4px; top: 0; height: 4px; border-radius: 4px; background: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 30%, transparent); z-index: 5; pointer-events: none; }
.drop-indicator::before { content: ''; position: absolute; left: -6px; top: -4px; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); }
.dnd-ghost { box-shadow: 0 18px 40px rgba(20, 26, 55, .28) !important; border-radius: var(--r-l); opacity: .96; background: var(--surface); transition: none !important; }
.is-drag-source { opacity: .35; }
body.is-dragging, body.is-dragging * { cursor: grabbing !important; -webkit-user-select: none; user-select: none; }

.drop-hint { display: none; }
.is-dragging-transfer .conn-row.is-drop-zone { outline: 2px dashed color-mix(in srgb, var(--accent) 70%, var(--line-2)); outline-offset: -2px; }
.conn-row.is-drop-zone.is-over { background: color-mix(in srgb, var(--accent) 22%, var(--surface)); outline-style: solid !important; }
.conn-row.is-drop-zone.is-over .drop-hint { display: block; position: absolute; right: 36px; top: 50%; transform: translateY(-50%); z-index: 3; font-size: 11.5px; font-weight: 800; color: var(--accent); background: var(--accent); padding: 3px 8px; border-radius: 999px; }

.tray { margin: 0 0 10px; padding: 4px 10px 10px 12px; border-radius: var(--r-l); background: var(--surface-2); border: 1.5px dashed var(--line-2); }
.tray.is-over { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, var(--surface)); }
.tray-h { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; min-height: 44px; }
.tray-n { font-size: 11px; font-weight: 800; background: var(--accent); color: #fff; border-radius: 999px; padding: 1px 7px; }
.tray-h .infotip { margin-left: auto; }
.tray-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.tray-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; max-width: 100%; padding: 6px 12px; border-radius: 999px; border: 1.5px dashed var(--route-plan); background: var(--surface); color: var(--ink); font-weight: 700; font-size: 13.5px; text-align: left; touch-action: none; cursor: grab; -webkit-user-select: none; user-select: none; box-shadow: var(--sh-1); }
.tray-chip.is-booked { border-style: solid; border-color: var(--navy); }
.tray-chip small { font-weight: 650; color: var(--ink-3); font-size: 12.5px; margin-left: 3px; }
.tray-chip > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.st-acts { position: relative; z-index: 1; margin: -2px 0 6px 46px; padding: 8px 10px 6px 12px; background: var(--surface-2); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 var(--r-l) var(--r-l); animation: accIn .22s var(--ease); }
.ta-day + .ta-day { margin-top: 6px; }
.ta-date { font-size: 11.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin: 4px 0 2px; }
.ta-list { list-style: none; margin: 0; padding: 0; position: relative; }
.ta-list::before { content: ''; position: absolute; left: 55px; top: 8px; bottom: 8px; border-left: 2px solid var(--line); }
.ta-item { display: grid; grid-template-columns: 40px 28px minmax(0, 1fr) 44px; align-items: center; gap: 4px; min-height: 48px; }
.ta-time { font-size: 12.5px; font-weight: 750; color: var(--ink-2); text-align: right; padding-right: 2px; }
.ta-dot { position: relative; z-index: 1; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); border: 1.5px solid var(--line-2); color: var(--ink); }
.ta-item.is-done .ta-dot { background: var(--ok-bg); border-color: var(--ok); color: var(--ok); }
.ta-main { min-width: 0; display: flex; flex-direction: column; gap: 1px; padding: 6px 4px; min-height: 44px; justify-content: center; border: 0; background: none; text-align: left; color: inherit; border-radius: 10px; }
.ta-main:hover { background: var(--surface-3); }
.ta-text { font-weight: 650; font-size: 14.5px; line-height: 1.25; overflow-wrap: anywhere; }
.ta-item.is-done .ta-text { color: var(--ink-3); text-decoration: line-through; text-decoration-color: var(--line-2); }
.ta-sub { font-size: 12px; color: var(--ink-3); font-weight: 550; }
.ta-sub:empty { display: none; }
.ta-check { width: 44px; height: 44px; display: grid; place-items: center; cursor: pointer; }
.ta-check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.ta-check input:checked + .check-box { background: var(--ok); border-color: var(--ok); color: #fff; }
.ta-check input:focus-visible + .check-box { box-shadow: var(--focus); }
.ta-empty { font-size: 13.5px; color: var(--ink-3); padding: 6px 2px; }
.ta-add { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 8px; border: 0; background: none; font-weight: 750; font-size: 13.5px; color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: 4px; }

/* add menu & sheets – one inset list, plain glyphs */
.am-list { display: flex; flex-direction: column; gap: 0; background: var(--fill-group); border-radius: 12px; overflow: hidden; }
.am-opt { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 60px; padding: 10px 12px 10px 16px; border-radius: 0; border: 0; background: transparent; color: var(--ink); text-align: left; box-shadow: none; }
.am-opt + .am-opt { border-top: .5px solid var(--line); }
.am-opt:hover { background: color-mix(in srgb, var(--ink) 4%, transparent); }
.am-opt.am-slim { min-height: 52px; }
.am-opt.is-current { background: transparent; }
.am-opt.is-current .am-txt strong { color: var(--accent); }
.am-ico { width: 24px; height: 24px; flex: none; border-radius: 0; display: grid; place-items: center; background: none; color: var(--accent); }
.am-slim .am-ico { width: 24px; height: 24px; border-radius: 0; color: var(--ink-3); }
.am-slim.is-current .am-ico { color: var(--accent); }
.am-place, .am-transfer, .am-activity { background: none; color: var(--accent); }
.am-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.am-txt strong { font-size: 16px; font-weight: 500; }
.am-txt span { font-size: 13px; color: var(--ink-3); line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.am-chev { color: var(--ink-3); flex: none; }
.mode-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.mode-tile { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 64px; padding: 6px 2px; border-radius: 10px; border: 0; background: color-mix(in srgb, var(--ink) 5%, transparent); color: var(--ink-2); font-size: 12px; font-weight: 500; }
.mode-tile .icon { color: var(--ink-3); }
.mode-tile.on { background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); font-weight: 600; }
.mode-tile.on .icon { color: var(--accent); }
.cat-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.cat-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px; border-radius: 10px; border: 0; background: color-mix(in srgb, var(--ink) 5%, transparent); color: var(--ink); font-weight: 400; font-size: 15px; }
.cat-chip .icon { color: var(--ink-3); }
.cat-chip.on { background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); font-weight: 500; }
.cat-chip.on .icon { color: var(--accent); }
@media (max-width: 370px) { .mode-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { .dnd-ghost { transform: none; } }
.st-line3 { display: flex; align-items: center; gap: 8px; min-width: 0; flex-wrap: wrap; row-gap: 3px; }
.st-line3 { flex-wrap: nowrap; }
.st-acts-toggle { white-space: nowrap; }
@media (max-width: 400px) { .st-acts-word { display: none; } }

/* one-line transfer rows on Home (plan notes live in the detail views) */
.tl.is-short .tl-head { font-size: 14px; }
.conn-row .tl-chip { margin-left: 2px; }
.trip-meta .demo-badge { margin-right: 7px; vertical-align: 1px; }
.trip-name { overflow-wrap: anywhere; }
.trip-meta { display: flex; flex-wrap: wrap; align-items: center; row-gap: 3px; }
.trip-meta-t { white-space: nowrap; }
@media (max-width: 380px) { .trip-add { padding-left: 12px; padding-right: 14px; } }

/* ===== Clean map (Apple-like) ===== */
.home { --mk-fill: #1c1c1e; --mk-ink: #fff; --mk-ring: #fff; --mk-sel: var(--accent); --mk-sel-ink: #fff; }
:root[data-theme='dark'] .home { --mk-fill: #fff; --mk-ink: #1c1c1e; --mk-ring: #1c1c1e; }
@media (prefers-color-scheme: dark) { :root:not([data-theme='light']) .home { --mk-fill: #fff; --mk-ink: #1c1c1e; --mk-ring: #1c1c1e; } }
.map-stage { background: var(--map-water); border: 0; box-shadow: none; border-radius: 14px; height: clamp(280px, 44vh, 440px); }
.map-paper, .map-ripple, .map-compass { display: none; }
.map-borders { stroke-dasharray: none; stroke-width: .8; }
.map-coast { display: none; }
.map-land { stroke: var(--map-land-edge); stroke-width: .8; stroke-linejoin: round; } /* coast drawn with the land fill: one pass over the geometry */
.lbl-t { font: 600 13px/1 var(--font-ui); letter-spacing: -.01em; stroke-width: 3.5px; }
.lbl-hl { transform: none; }
.lbl.is-sel .lbl-t { fill: #fff; }
.mk-dot { filter: drop-shadow(0 1px 2px rgba(0,0,0,.25)); stroke-width: 2; }
.mk.is-sel .mk-dot { stroke: #fff; }
.mk-num { font-weight: 700; }
.badge, .lbadge, .home-chip { filter: drop-shadow(0 1px 2px rgba(0,0,0,.14)); }
.badge circle, .lbadge circle { stroke-dasharray: none; stroke: var(--line-2); }
.hc-t { font-weight: 600; }
.map-pill { border: 0; border-radius: 14px; box-shadow: 0 4px 16px rgba(0,0,0,.12); }
.pill-name { font-weight: 600; font-size: 15px; }
.pill-idx { font-weight: 600; border-radius: 6px; }
.map-fit { border: 0; border-radius: 10px; }

/* ===== Station card: photo · Zeitraum · Hotel · Mietwagen (clean) ===== */
.stations { --tl-x: 72px; }
.st-card { grid-template-columns: 36px minmax(0, 1fr) 36px; gap: 0; padding: 8px 0 8px 0; min-height: 0; border: 0; border-radius: 14px; box-shadow: none; background: var(--surface); }
.st-card.is-selected { box-shadow: 0 0 0 2px var(--accent); }
.st-card.is-open { border-radius: 14px 14px 0 0; }
.st-body { grid-template-columns: 72px minmax(0, 1fr); gap: 12px; align-items: start; min-height: 72px; }
.st-thumb, .st-img { width: 72px; height: 72px; }
.st-img { border-radius: 10px; }
.st-num { left: 5px; top: 5px; min-width: 22px; height: 22px; border-radius: 11px; font: 600 12px/22px var(--font-ui); background: rgba(0,0,0,.62); color: #fff; box-shadow: none; backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.st-card.is-selected .st-num { background: var(--accent); color: #fff; }
.st-main { gap: 3px; padding-top: 1px; }
.st-top { display: flex; align-items: center; gap: 6px; min-width: 0; }
.st-name { flex: 1 1 auto; min-width: 0; font: 600 17px/1.2 var(--font-ui); letter-spacing: -0.022em; -webkit-line-clamp: 1; }
.st-acts-toggle { flex: none; display: inline-flex; align-items: center; gap: 2px; font-size: 13px; font-weight: 500; color: var(--ink-3); }
.st-line { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 14px; line-height: 1.3; color: var(--ink-2); white-space: nowrap; }
.st-line .icon { flex: none; color: var(--ink-3); }
.st-line.is-open { color: var(--warn); }
.st-line.is-open .icon { color: var(--warn); }
.st-ell { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.st-ok { color: var(--ok) !important; }
.st-more { min-width: 36px; min-height: 44px; align-self: center; display: grid; place-items: center; color: var(--ink-3); }
.st-line3, .st-meta, .st-stay { display: none; }

/* connections: quiet single line */
.conn-row { min-height: 44px; padding-top: 2px; padding-bottom: 2px; }
.conn-link { border: 0; background: none; text-align: left; font: inherit; color: inherit; padding-left: 20px; }
.tl-bubble { width: 28px; height: 28px; border: 1px solid var(--line-2); background: var(--surface); }
.tl.is-booked .tl-bubble { background: var(--accent); color: #fff; border-color: var(--accent); box-shadow: none; }
.tl.is-none .tl-bubble { border-style: dashed; color: var(--ink-3); border-color: var(--line-2); }
.tl.is-none .tl-sub, .tl.is-none .tl-head { color: var(--ink-3); }
.tl-head { font-weight: 500; font-size: 15px; }
.tl-sub { font-size: 13px; font-weight: 400; }
.conn-row::before { border-left: 1.5px solid var(--line-2); }
.conn-go { color: var(--ink-3); }
.st-acts { margin-left: 0; border: 0; border-top: .5px solid var(--line); background: var(--surface); border-radius: 0 0 14px 14px; padding: 6px 12px 6px 48px; }
.ta-dot { border-width: 1px; }
.ta-date { font-weight: 600; letter-spacing: .02em; }
.ta-add { color: var(--accent); text-decoration: none; font-weight: 500; }
.tray { border-width: 1px; background: var(--surface); }
.tray-chip { border-width: 1px; box-shadow: none; font-weight: 500; }
.add-stop-row { border: 0; background: var(--surface); border-radius: 14px; color: var(--accent); }
.add-stop-row .add-ico { background: none; color: var(--accent); width: 24px; }
.add-t { font-weight: 500; }
.trip-name { font: 700 24px/1.15 var(--font-ui); letter-spacing: -0.028em; }
.trip-meta { font-weight: 400; font-size: 14px; }

/* transfer key facts sheet */
.kf-title { display: inline-flex; align-items: center; gap: 8px; }
.kf-route { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; color: var(--ink-3); font-size: 15px; margin-bottom: 12px; }
.kf-group { background: var(--surface-2); border-radius: 12px; overflow: hidden; }
.kf-group + .kf-group { margin-top: 10px; }
.kf-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; min-height: 44px; padding: 11px 14px; }
.kf-row + .kf-row { border-top: .5px solid var(--line); }
.kf-k { color: var(--ink-3); font-size: 15px; flex: none; }
.kf-v { font-size: 16px; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; min-width: 0; display: flex; flex-direction: column; align-items: flex-end; }
.kf-sub { font-size: 13px; font-weight: 400; color: var(--ink-3); overflow-wrap: anywhere; }
.kf-empty { color: var(--ink-3); padding: 8px 0; }
.trip-add { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--accent); color: #fff; display: grid; place-items: center; flex: none; }
.st-name { -webkit-line-clamp: 2; }
.st-top { align-items: flex-start; }
.st-acts-toggle { padding-top: 2px; }

/* ===== Equal-height station cards, facts side by side ===== */
.st-card { grid-template-columns: minmax(0, 1fr) 40px; height: 88px; padding: 0 0 0 10px; align-items: center; position: relative; }
.st-card.is-open { height: 88px; }
.st-body { grid-template-columns: 68px minmax(0, 1fr); gap: 12px; align-items: center; min-height: 0; height: 88px; }
.st-thumb, .st-img { width: 68px; height: 68px; }
.st-main { gap: 4px; padding-top: 0; justify-content: center; }
.st-name { -webkit-line-clamp: 1; line-clamp: 1; white-space: nowrap; display: block; overflow: hidden; text-overflow: ellipsis; }
.st-top { align-items: center; }
.st-acts-toggle { padding-top: 0; }
.st-facts { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 16px; max-height: 42px; overflow: hidden; min-width: 0; }
.st-facts-2 { display: flex; align-items: center; gap: 16px; min-width: 0; max-width: 100%; }
.st-line { font-size: 14px; }
.st-hotel { min-width: 0; flex: 0 1 auto; }
.st-car { flex: none; }
/* drag handle sits on the photo corner (keeps the card compact) */
.st-grip { position: absolute; left: 4px; bottom: 4px; width: 44px; height: 44px; display: grid; place-items: end start; padding: 6px; background: none; z-index: 3; }
.st-grip-dot { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: rgba(0,0,0,.5); color: #fff; backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.st-grip:hover { background: none; }
.st-grip:focus-visible .st-grip-dot { box-shadow: var(--focus); }
.st-more { min-width: 40px; }
.stations { --tl-x: 44px; }
.conn-link { padding-left: 0; }
.st-acts { padding-left: 90px; }

/* start date row */
.start-row { position: relative; display: flex; align-items: center; gap: 10px; min-height: 48px; margin-top: 10px; padding: 0 12px 0 14px; background: var(--surface); border-radius: 12px; color: var(--ink); }
.start-row > .icon { color: var(--accent); flex: none; }
.start-k { font-size: 16px; }
.start-v { margin-left: auto; font-size: 16px; font-weight: 500; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.start-row.is-empty .start-v { color: var(--accent); }
.start-end { color: var(--ink-3); font-weight: 400; }
.start-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; font-size: 16px; cursor: pointer; border: 0; z-index: 1; }
.start-clear { position: relative; z-index: 2; width: 36px; height: 44px; margin-right: -8px; border: 0; background: none; color: var(--ink-3); display: grid; place-items: center; }
@media (max-width: 380px) { .start-end { display: none; } }
.st-card { padding-left: 18px; }
.stations { --tl-x: 52px; }
.st-grip { left: 12px; bottom: 6px; }
.st-acts { padding-left: 98px; }
.ta-item.is-transfer .ta-dot { border-color: var(--line-2); }
.ta-status { display: grid; place-items: center; min-width: 44px; }
.ta-adds { display: flex; gap: 4px 16px; flex-wrap: wrap; }
.saved-list { display: flex; flex-direction: column; background: var(--surface-2); border-radius: 12px; overflow: hidden; }
.saved-item { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 10px 12px; border: 0; background: none; color: var(--ink); text-align: left; font: inherit; }
.saved-item + .saved-item { border-top: .5px solid var(--line); }
.saved-item .icon { color: var(--ink-3); flex: none; }
.saved-item.on { background: color-mix(in srgb, var(--accent) 10%, transparent); }
.saved-t { flex: 1; min-width: 0; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.saved-ok { color: var(--accent) !important; }
.st-acts { padding: 6px 12px 8px 12px; }
.ta-list::before { left: 65px; }
.ta-item { grid-template-columns: 44px 28px minmax(0, 1fr) 44px; gap: 2px 8px; }
.ta-text { overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto; }
.ta-date { padding-left: 2px; }
.ta-adds { padding-left: 52px; }
/* timeline: dots on the far left, full width for text */
.st-acts { padding: 4px 12px 8px 14px; }
.ta-item { grid-template-columns: 28px minmax(0, 1fr) 44px; gap: 2px 10px; }
.ta-list::before { left: 13px; }
.ta-date { padding-left: 0; margin-top: 8px; }
.ta-adds { padding-left: 34px; }
.ta-t { font-weight: 600; color: var(--accent); margin-right: 8px; }
/* transfers between places are fixed (no drag handle) */
.conn-link { padding-left: 38px; }
.kf-edit .kf-route { margin-bottom: 0; }
/* place handle: long-press to drag, normal scrolling otherwise */
.st-grip { touch-action: pan-y; -webkit-touch-callout: none; }
.st-grip-dot { transition: transform .45s ease, background .2s; }
.st-grip.is-holding .st-grip-dot { transform: scale(1.35); background: var(--accent); }
.st-car-ico { flex: none; display: inline-grid; place-items: center; color: var(--ink-3); }

/* ---------- fullscreen map ---------- */
.map-expand { opacity: .92; }
.map-full { position: fixed; inset: 0; z-index: 60; background: var(--map-water); animation: mfIn .22s var(--ease); overscroll-behavior: contain; }
@keyframes mfIn { from { opacity: 0; transform: scale(.985); } to { opacity: 1; transform: none; } }
.map-full .map-canvas { position: absolute; inset: 0; }
.map-full .map-svg { touch-action: none; cursor: grab; }
.map-full .map-svg:active { cursor: grabbing; }
.mf-top { position: absolute; z-index: 3; top: calc(var(--safe-t) + 10px); left: 10px; right: 10px; display: flex; align-items: center; gap: 8px; pointer-events: none; }
.mf-top > * { pointer-events: auto; }
.mf-btn { flex: none; width: 44px; height: 44px; border-radius: 12px; border: 0; display: grid; place-items: center; color: var(--ink); background: color-mix(in srgb, var(--surface) 92%, transparent); box-shadow: var(--sh-1); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); cursor: pointer; }
.mf-btn:active { transform: scale(.96); }
.mf-filters { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 4px 24px 4px 2px; margin-right: -10px; min-width: 0; -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 22px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 22px), transparent); }
.mf-filters::-webkit-scrollbar { display: none; }
.mf-chip { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 11px 0 8px; border: 0; border-radius: 999px; font: 600 13px/1 var(--font-ui); color: var(--ink); background: color-mix(in srgb, var(--surface) 92%, transparent); box-shadow: var(--sh-1); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); opacity: .5; transition: opacity .15s; cursor: pointer; }
.mf-chip.is-on { opacity: 1; }
.mf-chip-dot { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--poi-c); }
.mf-chip.t-city .mf-chip-dot { background: none; }
.mf-chip.t-city .mf-chip-dot::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--ink); box-shadow: 0 0 0 1.5px var(--surface); }
.mf-zoom { position: absolute; z-index: 3; right: 10px; top: calc(var(--safe-t) + 66px); display: flex; flex-direction: column; gap: 8px; }
.mf-card { position: absolute; z-index: 3; left: 10px; right: 10px; bottom: calc(var(--safe-b) + 12px); max-width: 520px; margin: 0 auto; display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 12px; border-radius: 16px; background: var(--surface); box-shadow: var(--sh-3); animation: sheetUp .24s var(--ease); }
.mf-card-ico { flex: none; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--poi-c); }
.mf-card-ico.t-city { background: var(--ink); color: var(--surface); }
.mf-card-num { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--mk-sel); color: var(--mk-sel-ink); font: 800 14px/1 var(--font-ui); }
.mf-card-main { flex: 1; min-width: 0; }
.mf-card-name { margin: 0; font: 600 16px/1.25 var(--font-ui); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.mf-card-sub { margin: 2px 0 0; font-size: 13px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mf-card .mf-ext { width: 40px; height: 40px; box-shadow: none; background: transparent; color: var(--ink-3); }
.mf-card .btn { flex: none; }

/* POI symbols */
.t-park { --poi-c: #34c759; } .t-sight { --poi-c: #ff9500; } .t-fun { --poi-c: #af52de; } .t-city { --poi-c: var(--ink); }
.poi { cursor: pointer; outline: none; }
.poi-hit { fill: transparent; }
.poi-dot { fill: var(--poi-c); stroke: var(--surface); stroke-width: 1.6; transform-box: fill-box; transform-origin: center; transition: transform .2s var(--ease); }
.poi.t-city .poi-dot { stroke-width: 1.5; }
.poi-ico { color: #fff; pointer-events: none; }
.poi-t { fill: var(--ink-2, var(--ink)); dominant-baseline: central; paint-order: stroke; stroke: var(--label-halo); stroke-width: 3.5px; stroke-linejoin: round; }
.poi.t-city.r-1 .poi-t { fill: var(--ink); }
.poi.t-park .poi-t { fill: color-mix(in srgb, #1f7a37 80%, var(--ink)); }
.poi.is-sel .poi-dot { transform: scale(1.35); stroke: var(--accent); stroke-width: 2.5; }
.poi.is-sel .poi-t { fill: var(--accent); font-weight: 700; }
.poi:focus-visible .poi-dot { stroke: var(--accent); stroke-width: 3; }
:root[data-theme='dark'] .poi.t-park .poi-t { fill: #7ee29a; }
@media (prefers-color-scheme: dark) { :root:not([data-theme='light']) .poi.t-park .poi-t { fill: #7ee29a; } }
html:has(.map-full) .toasts { bottom: calc(var(--safe-b) + 92px); }

/* ---------- route variants (segmented switch above the map) ---------- */
.variants { display: flex; align-items: stretch; gap: 8px; margin: 2px 0 10px; }
.var-seg { flex: 1; min-width: 0; display: flex; gap: 2px; padding: 2px; border-radius: 11px; background: rgba(118, 118, 128, .12); overflow-x: auto; scrollbar-width: none; }
.var-seg::-webkit-scrollbar { display: none; }
.var-opt { flex: 1 0 auto; min-width: 0; max-width: 100%; min-height: 44px; padding: 4px 12px; border: 0; border-radius: 9px; background: transparent; color: var(--ink); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; cursor: pointer; transition: background .18s, box-shadow .18s; -webkit-tap-highlight-color: transparent; }
.var-opt.is-on { background: var(--surface); box-shadow: 0 1px 3px rgba(0, 0, 0, .12), 0 0 0 .5px rgba(0, 0, 0, .04); }
.var-opt.is-busy { opacity: .6; }
.var-t { font: 600 14px/1.2 var(--font-ui); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.var-n { font: 500 11.5px/1.2 var(--font-ui); color: var(--ink-3); }
.var-add { flex: none; width: 48px; border: 0; border-radius: 11px; background: rgba(118, 118, 128, .12); color: var(--accent); display: grid; place-items: center; cursor: pointer; }
:root[data-theme='dark'] .var-seg, :root[data-theme='dark'] .var-add { background: rgba(118, 118, 128, .24); }
:root[data-theme='dark'] .var-opt.is-on { background: #636366; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .var-seg, :root:not([data-theme='light']) .var-add { background: rgba(118, 118, 128, .24); }
  :root:not([data-theme='light']) .var-opt.is-on { background: #636366; }
}
.am-variant { background: none; color: var(--accent); }
.var-seg { position: relative; }
