
:root {
  --bg: #f6f3ee;
  --surface: #ffffff;
  --surface-soft: #faf8f4;
  --text: #1f2529;
  --muted: #6c7479;
  --border: #e6e0d8;
  --accent: #2f625d;
  --accent-soft: #e7f0ee;
  --shadow: 0 14px 38px rgba(29, 37, 41, .12);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
}

button, input { font: inherit; }

.app-shell {
  display: grid;
  grid-template-columns: 390px 1fr;
  height: 100vh;
  overflow: hidden;
}

.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--border);
  overflow-y: auto;
  padding: 24px 22px 32px;
  z-index: 5;
}

.sidebar-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.eyebrow {
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

h1 {
  margin: 5px 0 0;
  font-size: 30px;
  letter-spacing: -.04em;
}

h2 {
  margin: 0;
  font-size: 15px;
}

.intro {
  color: var(--muted);
  line-height: 1.5;
  font-size: 14px;
  margin: 12px 0 20px;
}

.search-wrap input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  outline: none;
  background: var(--surface-soft);
}

.search-wrap input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.panel {
  border-top: 1px solid var(--border);
  padding-top: 18px;
  margin-top: 18px;
}

.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.filter-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.filter-row {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  line-height: 1.25;
  cursor: pointer;
  padding: 6px 2px;
}

.filter-row input { accent-color: var(--accent); }

.text-button, .icon-button {
  border: 0;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
}

.text-button { font-size: 12px; }

.count-badge {
  font-size: 12px;
  color: var(--muted);
  background: var(--surface-soft);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 8px;
}

.place-list {
  display: grid;
  gap: 7px;
}

.place-card {
  border: 1px solid var(--border);
  background: var(--surface-soft);
  border-radius: 12px;
  padding: 10px 11px;
  cursor: pointer;
  transition: transform .12s ease, border-color .12s ease, background .12s ease;
}

.place-card:hover {
  transform: translateY(-1px);
  border-color: #cfc6bb;
  background: white;
}

.place-card-title {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-weight: 750;
  font-size: 13px;
}

.place-card-meta {
  color: var(--muted);
  font-size: 11px;
  margin-top: 4px;
}

.place-card-note {
  margin-top: 6px;
  font-size: 11px;
  line-height: 1.35;
}

.try-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  padding: 6px 0;
}

.try-row input { accent-color: var(--accent); }

.secondary-button {
  width: 100%;
  border: 1px solid var(--border);
  background: var(--surface-soft);
  color: var(--text);
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
}

.sidebar-footer { margin-top: 22px; }

.map-wrap {
  position: relative;
  min-width: 0;
}

#map {
  width: 100%;
  height: 100%;
}

.top-actions {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 3;
  display: flex;
  gap: 8px;
}

.floating-button {
  border: 1px solid rgba(0,0,0,.08);
  background: rgba(255,255,255,.95);
  color: var(--text);
  box-shadow: 0 8px 20px rgba(0,0,0,.12);
  border-radius: 10px;
  padding: 9px 12px;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.status-box {
  position: absolute;
  right: 16px;
  bottom: 18px;
  z-index: 3;
  background: rgba(31,37,41,.92);
  color: white;
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 12px;
  max-width: 360px;
  box-shadow: var(--shadow);
}

.info-window {
  max-width: 280px;
  line-height: 1.4;
}

.info-window h3 {
  margin: 0 0 4px;
  font-size: 16px;
}

.info-window .info-meta {
  color: #6c7479;
  font-size: 12px;
  margin-bottom: 8px;
}

.info-window .info-note {
  font-size: 12px;
  margin: 8px 0;
}

.info-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.info-actions button,
.info-actions a {
  appearance: none;
  text-decoration: none;
  border: 1px solid #d8d2ca;
  background: #fff;
  color: #263136;
  border-radius: 8px;
  padding: 7px 8px;
  font-size: 11px;
  cursor: pointer;
}

.info-actions .primary {
  background: #2f625d;
  border-color: #2f625d;
  color: #fff;
}

.mobile-only { display: none; }

@media (max-width: 820px) {
  .app-shell {
    display: block;
    position: relative;
  }

  .map-wrap {
    height: 100vh;
  }

  .sidebar {
    position: absolute;
    inset: 0 auto 0 0;
    width: min(92vw, 390px);
    transform: translateX(-102%);
    transition: transform .2s ease;
    box-shadow: var(--shadow);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .mobile-only { display: inline-flex; }
}


.primary-floating {
  background: #2f625d;
  color: #fff;
  border-color: #2f625d;
}

.place-dialog {
  width: min(92vw, 520px);
  border: 0;
  border-radius: 16px;
  padding: 0;
  box-shadow: 0 24px 70px rgba(0,0,0,.28);
}

.place-dialog::backdrop {
  background: rgba(20, 28, 31, .48);
  backdrop-filter: blur(2px);
}

.place-form {
  padding: 22px;
}

.dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.dialog-head h2 {
  margin: 3px 0 0;
  font-size: 22px;
}

.form-field {
  display: grid;
  gap: 6px;
  margin-bottom: 14px;
  font-size: 13px;
  font-weight: 600;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #d8d2ca;
  border-radius: 10px;
  padding: 10px 11px;
  background: #fff;
  color: #263136;
  font: inherit;
  font-weight: 400;
}

.form-field textarea {
  resize: vertical;
  min-height: 78px;
}

.form-check {
  margin: 4px 0 10px;
}

.form-hint {
  margin: 8px 0 4px;
  font-size: 11px;
  color: #6c7479;
}

.form-message {
  min-height: 18px;
  margin-top: 6px;
  font-size: 12px;
  color: #a43d35;
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 12px;
}

.primary-button {
  border: 1px solid #2f625d;
  background: #2f625d;
  color: #fff;
  border-radius: 10px;
  padding: 9px 12px;
  cursor: pointer;
}

.primary-button:disabled {
  opacity: .65;
  cursor: wait;
}

.info-actions .danger {
  color: #a43d35;
  border-color: #e4bbb5;
}

@media (max-width: 820px) {
  .top-actions {
    right: 10px;
    left: 10px;
    flex-wrap: wrap;
  }

  .primary-floating {
    order: 3;
  }

  .place-dialog {
    width: min(94vw, 520px);
  }
}


.day-filter-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.day-filter-button {
  border: 1px solid var(--border);
  background: var(--surface-soft);
  color: var(--text);
  border-radius: 10px;
  padding: 8px 9px;
  font-size: 12px;
  cursor: pointer;
  text-align: left;
  transition: border-color .12s ease, background .12s ease, color .12s ease;
}

.day-filter-button:hover {
  border-color: #bfb6aa;
  background: #fff;
}

.day-filter-button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.day-select {
  border: 1px solid #d8d2ca;
  background: #fff;
  color: #263136;
  border-radius: 8px;
  padding: 7px 8px;
  font-size: 11px;
  cursor: pointer;
  max-width: 180px;
}


.location-panel {
  margin-top: 16px;
}

.location-button {
  width: 100%;
  border: 1px solid var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 10px;
  padding: 10px 12px;
  font-weight: 700;
  cursor: pointer;
}

.location-button:hover {
  background: #dceae7;
}

.location-button:disabled {
  opacity: .65;
  cursor: wait;
}

.location-text {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.distance-sort-button:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.distance-sort-button.active {
  background: var(--accent);
  color: white;
  border-radius: 999px;
  padding: 4px 8px;
}

.info-distance {
  margin-top: 6px;
  color: #2f625d;
  font-size: 12px;
  font-weight: 700;
}


.order-controls {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
}

.order-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 27px;
  height: 27px;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.order-button {
  width: 28px;
  height: 27px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  border-radius: 7px;
  cursor: pointer;
  font-weight: 800;
}

.order-button:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
}

.order-button:disabled {
  opacity: .35;
  cursor: default;
}

.place-card-name {
  min-width: 0;
}

.place-card-badges {
  flex-shrink: 0;
  white-space: nowrap;
}


/* v0.5.1: AdvancedMarkerElement nutzt PinElement-Inhalte direkt aus der Maps API. */


.info-time {
  margin-top: 6px;
  color: #7c3aed;
  font-size: 12px;
  font-weight: 700;
}

.time-editor {
  margin-top: 10px;
  padding: 10px;
  border: 1px solid #e4ded5;
  background: #faf8f4;
  border-radius: 10px;
}

.time-editor-disabled {
  opacity: .72;
}

.time-editor-title {
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 8px;
}

.time-editor-hint {
  font-size: 11px;
  color: #6c7479;
}

.time-editor-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.time-editor-row label {
  display: grid;
  gap: 4px;
  font-size: 10px;
  color: #6c7479;
}

.time-editor-row input[type="time"] {
  width: 100%;
  border: 1px solid #d8d2ca;
  border-radius: 8px;
  background: #fff;
  color: #263136;
  padding: 7px 8px;
  font: inherit;
  font-size: 12px;
}

.time-editor-actions {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.time-editor-actions button {
  border: 1px solid #2f625d;
  background: #2f625d;
  color: #fff;
  border-radius: 8px;
  padding: 7px 8px;
  font-size: 11px;
  cursor: pointer;
}

.time-editor-actions .secondary-time-button {
  background: #fff;
  color: #5e666b;
  border-color: #d8d2ca;
}

@media (max-width: 520px) {
  .time-editor-row {
    grid-template-columns: 1fr;
  }
}


.route-panel {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
}

.route-info {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
  margin-bottom: 8px;
}

.route-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.route-button {
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
  border-radius: 9px;
  padding: 8px 9px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.secondary-route-button {
  background: #fff;
  color: var(--accent);
}

.route-button:disabled {
  opacity: .42;
  cursor: not-allowed;
}

.route-hint {
  margin-top: 7px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.35;
}

@media (max-width: 420px) {
  .route-actions {
    grid-template-columns: 1fr;
  }
}

/* v0.8: echte Route über Google Routes API */


.route-start-row {
  display: grid;
  gap: 5px;
  margin-bottom: 8px;
}

.route-start-row label {
  font-size: 10px;
  color: var(--muted);
  font-weight: 700;
}

.route-start-select {
  width: 100%;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  border-radius: 9px;
  padding: 8px 9px;
  font-size: 11px;
}


/* =========================================================
   v0.9 – Mobile UI / Bedienoptimierung
   Desktop bleibt unverändert. Die folgenden Regeln greifen
   ausschließlich bis 820 px.
   ========================================================= */

.mobile-sheet-handle,
.mobile-bottom-nav,
.mobile-scrim,
.mobile-locate-fab {
  display: none;
}

@media (max-width: 820px) {
  :root {
    --mobile-nav-height: 68px;
  }

  body {
    overflow: hidden;
    overscroll-behavior: none;
  }

  .app-shell {
    display: block;
    height: 100dvh;
    overflow: hidden;
  }

  .map-wrap {
    height: 100dvh;
  }

  #map {
    height: 100%;
  }

  /* Bottom Sheet statt seitlicher Vollbild-Sidebar */
  .sidebar {
    position: fixed;
    z-index: 20;
    left: 8px;
    right: 8px;
    top: auto;
    bottom: calc(var(--mobile-nav-height) + 8px);
    width: auto;
    height: min(72dvh, 680px);
    max-height: calc(100dvh - var(--mobile-nav-height) - 28px);
    padding: 14px 16px 28px;
    border: 1px solid var(--border);
    border-radius: 22px 22px 16px 16px;
    box-shadow: 0 -10px 40px rgba(29, 37, 41, .22);
    transform: translateY(calc(100% + var(--mobile-nav-height) + 36px));
    transition: transform .22s ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .sidebar.open {
    transform: translateY(0);
  }

  .mobile-sheet-handle {
    display: block;
    width: 42px;
    height: 5px;
    margin: -4px auto 10px;
    border-radius: 999px;
    background: #c8c4be;
  }

  .sidebar-header {
    position: sticky;
    top: -14px;
    z-index: 3;
    margin: 0 -16px 8px;
    padding: 12px 16px 10px;
    background: rgba(255,255,255,.96);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(8px);
  }

  .sidebar-header h1 {
    font-size: 21px;
  }

  .sidebar-header .eyebrow {
    font-size: 10px;
  }

  .intro {
    margin-top: 8px;
  }

  .mobile-view-hidden {
    display: none !important;
  }

  /* Feste Bottom-Navigation */
  .mobile-bottom-nav {
    display: grid;
    position: fixed;
    z-index: 30;
    left: 0;
    right: 0;
    bottom: 0;
    height: calc(var(--mobile-nav-height) + env(safe-area-inset-bottom));
    grid-template-columns: repeat(3, 1fr);
    padding: 5px 10px calc(5px + env(safe-area-inset-bottom));
    background: rgba(255,255,255,.97);
    border-top: 1px solid var(--border);
    box-shadow: 0 -8px 24px rgba(29,37,41,.10);
    backdrop-filter: blur(14px);
  }

  .mobile-nav-button {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--muted);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
  }

  .mobile-nav-button.active {
    background: var(--accent-soft);
    color: var(--accent);
  }

  .mobile-nav-icon {
    font-size: 20px;
    line-height: 1;
  }

  /* Hintergrundabdunklung beim geöffneten Sheet */
  .mobile-scrim {
    display: block;
    position: fixed;
    z-index: 15;
    inset: 0 0 var(--mobile-nav-height);
    background: rgba(16, 24, 28, .28);
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease;
  }

  .mobile-scrim.visible {
    opacity: 1;
    pointer-events: auto;
  }

  /* Standort als schwebender Kartenbutton */
  .mobile-locate-fab {
    display: inline-flex;
    position: absolute;
    z-index: 6;
    right: 14px;
    bottom: calc(var(--mobile-nav-height) + 18px);
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(0,0,0,.08);
    border-radius: 50%;
    background: rgba(255,255,255,.97);
    box-shadow: 0 7px 20px rgba(0,0,0,.16);
    font-size: 21px;
    cursor: pointer;
  }

  /* Kartenaktionen auf dem Handy kompakter */
  .top-actions {
    top: 12px;
    right: 12px;
    left: 12px;
    display: flex;
    justify-content: flex-end;
    gap: 7px;
    pointer-events: none;
  }

  .top-actions .floating-button {
    pointer-events: auto;
    padding: 8px 10px;
    font-size: 12px;
  }

  #fitBtn {
    display: none;
  }

  .primary-floating {
    order: initial;
  }

  /* Legende macht auf kleiner Karte zu viel Fläche */
  .map-legend {
    display: none;
  }

  .status-box {
    left: 12px;
    right: 72px;
    bottom: calc(var(--mobile-nav-height) + 18px);
    max-width: none;
    font-size: 11px;
    padding: 8px 10px;
  }

  /* Touch-Ziele */
  .place-card {
    padding: 13px 12px;
    border-radius: 14px;
  }

  .place-card-title {
    font-size: 14px;
  }

  .place-card-meta,
  .place-card-note {
    font-size: 12px;
  }

  .order-button {
    width: 38px;
    height: 36px;
    font-size: 18px;
  }

  .order-number {
    height: 36px;
    min-width: 36px;
  }

  .day-filter-button {
    min-height: 42px;
    font-size: 12px;
  }

  .route-button,
  .location-button,
  .secondary-button {
    min-height: 42px;
  }

  .filter-row {
    min-height: 36px;
  }

  .filter-row input {
    width: 18px;
    height: 18px;
  }

  /* InfoWindow-Aktionen besser fingerbedienbar */
  .info-window {
    max-width: min(78vw, 320px);
  }

  .info-actions {
    gap: 8px;
  }

  .info-actions button,
  .info-actions a,
  .day-select {
    min-height: 38px;
    padding: 9px 10px;
    font-size: 12px;
  }

  .time-editor-actions button {
    min-height: 38px;
  }

  /* Formular auf kleinen Screens */
  .place-dialog {
    width: min(94vw, 520px);
    max-height: 88dvh;
    overflow-y: auto;
  }

  .form-field input,
  .form-field select,
  .form-field textarea {
    min-height: 44px;
    font-size: 16px; /* verhindert iOS-Zoom */
  }
}

@media (max-width: 420px) {
  .sidebar {
    left: 5px;
    right: 5px;
    bottom: calc(var(--mobile-nav-height) + 5px);
    height: 74dvh;
  }

  .filter-list,
  .day-filter-list {
    grid-template-columns: 1fr 1fr;
  }

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


/* =========================================================
   v0.9.1 – Android Map Visibility Hotfix
   Stabilisiert die Google-Maps-Fläche auf Android/Chrome,
   unabhängig von der dynamischen Browser-Adressleiste.
   ========================================================= */

@media (max-width: 820px) {
  html,
  body {
    width: 100%;
    height: 100%;
    min-height: 100%;
  }

  body {
    position: fixed;
    inset: 0;
    overflow: hidden;
  }

  .app-shell {
    position: fixed !important;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 100%;
    display: block !important;
    overflow: hidden;
  }

  .map-wrap {
    position: absolute !important;
    inset: 0 0 var(--mobile-nav-height) 0;
    width: 100%;
    height: auto !important;
    min-height: 0 !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    overflow: hidden;
  }

  #map {
    position: absolute !important;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    min-height: 300px;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
  }

  .mobile-bottom-nav {
    height: calc(var(--mobile-nav-height) + env(safe-area-inset-bottom, 0px));
  }

  .sidebar {
    max-height: calc(100% - var(--mobile-nav-height) - 28px);
  }

  .mobile-locate-fab {
    bottom: 18px;
  }

  .status-box {
    bottom: 18px;
  }

  .mobile-scrim {
    inset: 0 0 var(--mobile-nav-height) 0;
  }
}


/* =========================================================
   v0.9.2 – Mobile Interaction Hotfix
   Scrim liegt über der Karte, aber unter dem Bottom Sheet.
   ========================================================= */

@media (max-width: 820px) {
  .app-shell {
    z-index: 1;
  }

  .map-wrap {
    z-index: 1;
  }

  .mobile-scrim {
    z-index: 10 !important;
  }

  .sidebar {
    z-index: 20 !important;
    pointer-events: auto !important;
  }

  .mobile-bottom-nav {
    z-index: 30 !important;
  }

  .sidebar.open,
  .sidebar.open * {
    pointer-events: auto;
  }
}


/* =========================================================
   v0.9.6 – Tagesagenda & Tagesmarker
   ========================================================= */

.custom-marker-wrapper {
  transition: opacity .15s ease, transform .15s ease;
}

.agenda-panel {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
}

.agenda-heading {
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 8px;
}

.day-agenda {
  display: grid;
  gap: 7px;
}

.agenda-empty {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
  padding: 8px 0;
}

.agenda-item {
  display: grid;
  grid-template-columns: 32px 1fr 34px;
  gap: 8px;
  align-items: center;
  padding: 9px;
  border: 1px solid var(--border);
  background: var(--surface-soft);
  border-radius: 11px;
  cursor: pointer;
}

.agenda-item:hover {
  background: #fff;
  border-color: #cfc6bb;
}

.agenda-order {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.agenda-main {
  min-width: 0;
}

.agenda-title {
  font-size: 12px;
  font-weight: 750;
  line-height: 1.25;
}

.agenda-meta {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.35;
}

.agenda-visited-button {
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--muted);
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  font-weight: 800;
}

.agenda-visited-button.visited {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

@media (max-width: 820px) {
  .agenda-item {
    grid-template-columns: 36px 1fr 40px;
    min-height: 58px;
    padding: 10px;
  }

  .agenda-order,
  .agenda-visited-button {
    width: 36px;
    height: 36px;
  }

  .agenda-title {
    font-size: 13px;
  }

  .agenda-meta {
    font-size: 11px;
  }
}


/* =========================================================
   v0.9.8 – Tagesagenda final
   ========================================================= */

.agenda-place-wrap {
  display: grid;
}

.agenda-leg {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 8px;
  align-items: center;
  min-height: 30px;
  padding: 2px 9px;
  color: var(--muted);
  font-size: 10px;
}

.agenda-leg span:first-child {
  text-align: center;
  font-size: 15px;
  color: var(--accent);
}

.agenda-item-visited {
  opacity: .62;
}

.agenda-item-visited .agenda-title {
  text-decoration: line-through;
  text-decoration-thickness: 1px;
}

.agenda-summary {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  margin-top: 6px;
  padding: 10px;
  border-radius: 11px;
  background: var(--accent-soft);
  color: var(--text);
  font-size: 11px;
}

.agenda-summary span {
  color: var(--muted);
  text-align: right;
}

.agenda-estimate-note {
  margin-top: 5px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.35;
}

@media (max-width: 820px) {
  .agenda-leg {
    grid-template-columns: 36px 1fr;
    min-height: 34px;
    font-size: 11px;
  }

  .agenda-summary {
    font-size: 12px;
    padding: 11px;
  }

  .agenda-estimate-note {
    font-size: 10px;
  }
}


/* =========================================================
   v0.9.10 – Suchvorschläge
   ========================================================= */

.search-wrap {
  position: relative;
}

.search-suggestions {
  display: none;
  margin-top: 6px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(29, 37, 41, .12);
  overflow: hidden;
  max-height: 320px;
  overflow-y: auto;
  z-index: 6;
}

.search-suggestions.visible {
  display: block;
}

.search-suggestion-item {
  width: 100%;
  display: grid;
  grid-template-columns: 28px 1fr auto;
  gap: 8px;
  align-items: center;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: #fff;
  padding: 9px 10px;
  text-align: left;
  cursor: pointer;
}

.search-suggestion-item:last-child {
  border-bottom: 0;
}

.search-suggestion-item:hover,
.search-suggestion-item:focus {
  background: var(--surface-soft);
  outline: none;
}

.search-suggestion-icon {
  font-size: 18px;
  text-align: center;
}

.search-suggestion-content {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.search-suggestion-name {
  font-size: 12px;
  font-weight: 750;
  color: var(--text);
}

.search-suggestion-meta {
  font-size: 10px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-suggestion-tip {
  font-size: 13px;
}

.search-suggestion-empty {
  padding: 10px;
  color: var(--muted);
  font-size: 11px;
}

@media (max-width: 820px) {
  .search-suggestions {
    max-height: 42dvh;
  }

  .search-suggestion-item {
    min-height: 52px;
    padding: 10px 11px;
  }

  .search-suggestion-name {
    font-size: 13px;
  }

  .search-suggestion-meta {
    font-size: 11px;
  }
}


/* v0.9.13 – optionale Ortsdetails */
.info-extra-details {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  display: grid;
  gap: 5px;
  font-size: 12px;
}

.info-detail a {
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}

.info-detail a:hover {
  text-decoration: underline;
}


/* =========================================================
   v0.9.14 – Google Places beim Hinzufügen
   ========================================================= */
.google-place-search { margin-bottom: 14px; }
.form-section-label { font-size: 12px; font-weight: 800; margin-bottom: 7px; }
.google-place-autocomplete { min-height: 44px; }
.google-place-autocomplete gmp-place-autocomplete { width: 100%; }
.google-place-selection {
  display: grid; gap: 2px; margin-top: 8px; padding: 9px 10px;
  border-radius: 10px; background: var(--accent-soft); font-size: 11px;
}
.google-place-selection[hidden] { display: none; }
.google-place-selection span { color: var(--muted); }
.manual-place-divider {
  display: flex; align-items: center; gap: 8px; margin: 14px 0 10px;
  color: var(--muted); font-size: 10px;
}
.manual-place-divider::before, .manual-place-divider::after {
  content: ""; flex: 1; height: 1px; background: var(--border);
}


/* =========================================================
   v0.9.15 – Heute
   ========================================================= */
.mini-action-button {
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  padding: 7px 11px;
  font: inherit;
  font-size: 11px;
  font-weight: 750;
  cursor: pointer;
  white-space: nowrap;
}
.mini-action-button:hover,
.mini-action-button:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
}

/* v0.9.16 – Nächster Ort */
.panel-title-row {
  flex-wrap: wrap;
}
#nextPlaceButton {
  margin-left: 0;
}

/* v0.9.17 – Backup & Import */
.backup-section { margin-top:18px; padding-top:16px; border-top:1px solid var(--border); }
.backup-section h3 { margin:0 0 4px; }
.backup-actions { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin-top:10px; }
@media (max-width:820px) { .backup-actions { grid-template-columns:1fr; } }

/* =========================================================
   V1.0.0 Phase 1 – Supabase Auth
   ========================================================= */
.auth-gate {
  position: fixed; inset: 0; z-index: 10000;
  display: grid; place-items: center;
  background: rgba(244, 246, 245, .98);
  padding: 20px;
}
.auth-gate.is-hidden { display: none; }
.auth-card {
  width: min(420px, 100%);
  background: white; border: 1px solid var(--border);
  border-radius: 18px; padding: 24px;
  box-shadow: 0 18px 55px rgba(0,0,0,.12);
}
.auth-card h1 { margin: 4px 0 8px; }
.auth-card p { margin: 0 0 18px; }
.auth-card .primary-button { width: 100%; margin-top: 8px; }
.account-actions { display:flex; align-items:center; gap:8px; margin-left:auto; }
.account-email { font-size: .78rem; max-width: 150px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
@media (max-width: 820px) { .account-email { display:none; } }



/* V1.0 Build-Anzeige – dezent im App-Header */
.app-version {
  display: inline-block;
  margin: -2px 0 8px;
  padding: 3px 7px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(47, 105, 96, .06);
  color: var(--accent);
  font-size: 10px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: .02em;
}

/* =========================================================
   v1.3.0 – Mobile Tages-Timeline
   ========================================================= */
.agenda-day-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 8px;
}

.agenda-day-kicker {
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.agenda-day-title {
  margin-top: 2px;
  font-size: 14px;
  font-weight: 850;
  line-height: 1.2;
}

.agenda-day-stats {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.35;
}

.agenda-progress-badge {
  flex: 0 0 auto;
  min-width: 44px;
  padding: 6px 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  text-align: center;
}

.agenda-progress-track {
  height: 5px;
  overflow: hidden;
  margin: 0 0 12px;
  border-radius: 999px;
  background: var(--surface-soft);
}

.agenda-progress-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
  transition: width .2s ease;
}

.agenda-timeline {
  display: grid;
  gap: 0;
}

.agenda-timeline-row {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 8px;
}

.agenda-time-column {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
}

.agenda-time {
  width: 100%;
  min-height: 17px;
  color: var(--text);
  font-size: 9px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
}

.agenda-time-open {
  color: var(--muted);
  font-weight: 650;
}

.agenda-timeline-dot {
  position: relative;
  z-index: 2;
  width: 27px;
  height: 27px;
  margin-top: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--accent);
  border-radius: 50%;
  background: #fff;
  color: var(--accent);
  font-size: 10px;
  font-weight: 850;
}

.agenda-timeline-dot.visited {
  background: var(--accent);
  color: #fff;
}

.agenda-timeline-line {
  position: absolute;
  top: 47px;
  bottom: -24px;
  width: 2px;
  background: var(--border);
}

.agenda-content-column {
  min-width: 0;
  padding-bottom: 8px;
}

.agenda-timeline .agenda-item {
  grid-template-columns: 28px minmax(0, 1fr) 32px;
  gap: 6px;
  padding: 7px 8px;
  min-height: 0;
}

.agenda-timeline .agenda-leg {
  grid-template-columns: 22px 1fr;
  padding-left: 7px;
  min-height: 27px;
}

@media (max-width: 820px) {
  .agenda-day-title { font-size: 16px; }
  .agenda-day-stats { font-size: 11px; }
  .agenda-progress-badge { font-size: 12px; }
  .agenda-timeline-row { grid-template-columns: 64px minmax(0, 1fr); gap: 9px; }
  .agenda-time { font-size: 10px; }
  .agenda-timeline-dot { width: 31px; height: 31px; font-size: 11px; }
  .agenda-timeline-line { top: 51px; bottom: -26px; }
  .agenda-timeline .agenda-item { grid-template-columns: 30px minmax(0, 1fr) 34px; gap: 6px; padding: 8px; min-height: 0; }
}

/* =========================================================
   v1.4.0 – Desktop UI redesign
   Compact, sectioned sidebar. Mobile layout remains unchanged.
   ========================================================= */
.desktop-only { display: flex; }

@media (min-width: 821px) {
  .app-shell { grid-template-columns: 360px 1fr; }

  .sidebar {
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 18px 16px 12px;
    scrollbar-width: thin;
    scrollbar-color: #c9c3ba transparent;
  }
  .sidebar::-webkit-scrollbar { width: 6px; }
  .sidebar::-webkit-scrollbar-track { background: transparent; }
  .sidebar::-webkit-scrollbar-thumb { background: #c9c3ba; border-radius: 999px; }

  .sidebar-header { flex: 0 0 auto; align-items: flex-start; }
  .sidebar-header h1 { font-size: 27px; }
  .sidebar .app-version { margin-top: 2px; }
  .desktop-intro { display: none; }

  .search-wrap { flex: 0 0 auto; margin-top: 14px; }
  .search-wrap input { padding: 11px 13px; }

  .desktop-sidebar-actions {
    flex: 0 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 9px;
  }
  .desktop-primary-action,
  .desktop-secondary-action {
    border-radius: 10px;
    padding: 9px 10px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 750;
  }
  .desktop-primary-action { border: 1px solid var(--accent); background: var(--accent); color: #fff; }
  .desktop-secondary-action { border: 1px solid var(--border); background: var(--surface-soft); color: var(--text); }
  .desktop-sidebar-actions #locateBtn,
  .desktop-sidebar-actions #distanceSortBtn { width: 100%; }
  .desktop-location-status {
    grid-column: 1 / -1;
    min-height: 0;
    margin: -1px 2px 0;
    font-size: 11px;
    line-height: 1.35;
    color: var(--text-muted);
  }

  /* Reorder desktop information architecture without touching mobile DOM order. */
  .sidebar-header { order: 1; }
  .search-wrap { order: 2; }
  .desktop-sidebar-actions { order: 3; }
  .desktop-plan-section { order: 4; }
  [data-desktop-section="categories"] { order: 5; }
  [data-desktop-section="filters"] { order: 6; }
  .desktop-places-panel { order: 7; }
  [data-desktop-section="try"] { order: 8; }
  .sidebar-footer { order: 9; }
  .desktop-intro { order: 2; }

  .panel {
    flex: 0 0 auto;
    margin-top: 9px;
    padding-top: 9px;
  }
  .desktop-collapsible {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0;
    background: var(--surface-soft);
    overflow: hidden;
  }
  .desktop-collapsible > .panel-title-row,
  .desktop-collapsible > h2 {
    min-height: 38px;
    margin: 0;
    padding: 9px 10px;
    cursor: pointer;
    background: var(--surface-soft);
  }
  .desktop-collapsible > h2 {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .desktop-collapsible-heading { user-select: none; }
  .desktop-section-toggle {
    margin-left: auto;
    border: 0;
    background: transparent;
    color: var(--muted);
    width: 28px;
    height: 24px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform .16s ease;
  }
  .desktop-section-toggle span { display: block; transition: transform .16s ease; }
  .desktop-collapsible:not(.desktop-collapsed) .desktop-section-toggle span { transform: rotate(180deg); }
  .desktop-collapsible.desktop-collapsed > :not(.panel-title-row):not(h2) { display: none !important; }
  .desktop-collapsible:not(.desktop-collapsed) > :not(.panel-title-row):not(h2) { margin-left: 10px; margin-right: 10px; }
  .desktop-collapsible:not(.desktop-collapsed) > :last-child { margin-bottom: 10px; }


  /* v1.4.0 test fixes: keep the two day actions together and allow the
     complete desktop sidebar to scroll down to secondary sections/footer. */
  .desktop-plan-section > .plan-title-row {
    align-items: center;
    flex-wrap: nowrap;
  }
  .desktop-plan-section > .plan-title-row > h2 {
    flex: 0 0 auto;
    margin-right: auto;
  }
  .plan-header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
  }
  .plan-header-actions .mini-action-button {
    white-space: nowrap;
    padding-left: 9px;
    padding-right: 9px;
  }

  /* The place list stays compact while the complete sidebar remains scrollable. */
  .desktop-places-panel {
    display: flex;
    flex-direction: column;
    flex: 0 0 auto;
    min-height: 0;
    overflow: visible;
    border-top: 1px solid var(--border);
    margin-top: 10px;
    padding-top: 9px;
  }
  .desktop-places-panel .panel-title-row { flex: 0 0 auto; margin-bottom: 7px; }
  .desktop-places-panel .place-list {
    max-height: 360px;
    overflow-y: auto;
    padding-right: 4px;
    scrollbar-width: thin;
    scrollbar-color: #c9c3ba transparent;
  }
  .desktop-places-panel .place-list::-webkit-scrollbar { width: 5px; }
  .desktop-places-panel .place-list::-webkit-scrollbar-track { background: transparent; }
  .desktop-places-panel .place-list::-webkit-scrollbar-thumb { background: #c9c3ba; border-radius: 999px; }
  .place-card { padding: 8px 10px; }
  .place-card-note { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

  /* Less-used sections stay available, but no longer dominate the sidebar. */
  .desktop-secondary-section { flex: 0 0 auto; }
  .sidebar-footer { margin-top: 9px; }
  .sidebar-footer .backup-section { margin-top: 0; }

  /* The map already exposes these actions on desktop; sidebar duplicates make them faster. */
  .top-actions { top: 14px; left: 14px; }
}

@media (max-width: 820px) {
  .desktop-only { display: none !important; }
  .desktop-collapsed > * { display: revert; }
}

/* v1.4.0 – Places section can be collapsed on desktop as well. */
@media (min-width: 821px) {
  .desktop-places-panel.desktop-collapsible {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0;
    background: var(--surface-soft);
    overflow: hidden;
  }
  .desktop-places-panel.desktop-collapsible > .panel-title-row {
    min-height: 38px;
    margin: 0;
    padding: 9px 10px;
    background: var(--surface-soft);
  }
  .desktop-places-panel.desktop-collapsible:not(.desktop-collapsed) > .place-list {
    margin: 0 6px 8px 10px;
  }
}


/* v1.5.0 – trip-specific "In Budapest probieren" */
.try-summary { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:8px; font-size:12px; }
.compact-button { width:auto; padding:7px 9px; white-space:nowrap; }
.try-progress { height:6px; overflow:hidden; border-radius:999px; background:var(--surface-soft); margin-bottom:8px; }
.try-progress span { display:block; height:100%; background:var(--accent); border-radius:inherit; transition:width .2s ease; }
.try-item { display:flex; align-items:center; gap:8px; border-top:1px solid var(--border); padding:8px 0; }
.try-item-main { display:flex; align-items:flex-start; gap:8px; flex:1; min-width:0; cursor:pointer; }
.try-item-main input { margin-top:3px; accent-color:var(--accent); }
.try-item-text { min-width:0; display:grid; gap:2px; font-size:13px; }
.try-item-text small { color:var(--muted); font-size:11px; line-height:1.3; }
.try-item.is-tried .try-item-text strong { text-decoration:line-through; opacity:.65; }
.try-edit-button { flex:0 0 auto; border:0; background:transparent; color:var(--muted); cursor:pointer; font-size:17px; padding:4px 6px; border-radius:8px; }
.try-edit-button:hover { background:var(--surface-soft); color:var(--text); }
.try-empty { color:var(--muted); font-size:12px; padding:8px 0 2px; }
.try-dialog-actions .secondary-button { width:auto; }
.dialog-spacer { flex:1; }
.danger-button { border:1px solid #c95d55; background:#fff; color:#a43d35; border-radius:10px; padding:9px 12px; cursor:pointer; }


/* v1.5.0 – mobile "In Budapest probieren" collapsible, closed by default */
.mobile-try-toggle {
  margin-left:auto; border:0; background:transparent; color:var(--muted); cursor:pointer;
  padding:4px 7px; border-radius:8px; font-size:16px; line-height:1;
}
@media (max-width: 820px) {
  .mobile-try-collapsible > h2 { display:flex; align-items:center; gap:8px; cursor:pointer; user-select:none; }
  .mobile-try-toggle span { display:block; transition:transform .16s ease; }
  .mobile-try-collapsible:not(.mobile-try-collapsed) .mobile-try-toggle span { transform:rotate(180deg); }
  .mobile-try-collapsible.mobile-try-collapsed > #tryList { display:none !important; }
}

/* v1.6.0 – Mobile Heute-Ansicht */
@media (max-width: 820px) {
  .mobile-bottom-nav { grid-template-columns: repeat(4, 1fr); }
  .today-overview-panel { padding: 0; background: transparent; border: 0; box-shadow: none; }
  .today-overview { display: grid; gap: 14px; padding-bottom: 8px; }
  .today-preview-note { padding: 9px 12px; border-radius: 12px; background: #fff7dc; color: #705b18; font-size: 12px; font-weight: 700; }
  .today-day-card, .today-next-card, .today-plan-card { background: #fff; border: 1px solid #e4e7e4; border-radius: 16px; padding: 14px; }
  .today-day-card { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; background: #f6faf9; }
  .today-kicker, .today-card-label { color: #2f625d; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
  .today-day-card h2 { margin: 3px 0 2px; font-size: 19px; }
  .today-day-label { color: #68716f; font-size: 13px; }
  .today-day-number { white-space: nowrap; color: #68716f; font-size: 13px; }
  .today-next-main { width: 100%; display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; border: 0; background: transparent; padding: 12px 0; text-align: left; color: inherit; }
  .today-next-icon { width: 44px; height: 44px; border-radius: 12px; background: #edf5f3; display: grid; place-items: center; font-size: 22px; }
  .today-next-main strong { display: block; font-size: 16px; }
  .today-next-main small { display: block; margin-top: 3px; color: #68716f; font-size: 12px; }
  .today-chevron { font-size: 26px; color: #64706e; }
  .today-next-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
  .today-next-time { flex: 0 0 auto; padding: 5px 9px; border-radius: 999px; background: #edf5f3; color: #2f625d; font-size: 12px; font-weight: 800; }
  .today-done-button { width: 100%; min-height: 46px; margin: 2px 0 10px; border: 0; border-radius: 12px; background: #2f625d; color: #fff; font: inherit; font-size: 14px; font-weight: 800; cursor: pointer; }
  .today-done-button:active { transform: translateY(1px); }
  .today-location-hint { margin-top: 9px; color: #68716f; font-size: 11px; line-height: 1.35; }
  .today-next-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .today-action-button { margin: 0; min-height: 44px; padding: 9px 8px; font-size: 13px; }
  .today-plan-head { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
  .today-plan-head span { color: #68716f; font-size: 12px; }
  .today-progress { height: 6px; border-radius: 999px; background: #edf0ee; overflow: hidden; margin: 10px 0 12px; }
  .today-progress span { display: block; height: 100%; background: #2f625d; border-radius: inherit; }
  .today-timeline { display: grid; }
  .today-timeline-item { display: grid; grid-template-columns: 28px 48px 1fr; gap: 5px; align-items: center; min-height: 40px; border-bottom: 1px solid #edf0ee; font-size: 13px; }
  .today-timeline-item:last-child { border-bottom: 0; }
  .today-timeline-item.next .today-place-name { font-weight: 800; color: #244e4a; }
  .today-timeline-item.visited .today-place-name { color: #8a9290; text-decoration: line-through; }
  .today-check { border: 0; background: transparent; color: #2f625d; font-size: 21px; padding: 0; }
  .today-time { color: #697270; font-variant-numeric: tabular-nums; }
  .today-open-plan { width: 100%; margin-top: 12px; }
  .today-complete-card { padding: 14px; border-radius: 14px; background: #eaf6ef; color: #286344; font-weight: 700; }
  .today-empty { padding: 14px 0; color: #6d7573; font-size: 13px; }
}


/* v1.6.0 fix2 – Heute ist ein vollwertiges mobiles Sheet-Panel, kein Inline-Element */
@media (max-width: 820px) {
  #todayOverviewPanel.mobile-only {
    display: block;
    width: 100%;
  }
  #todayOverviewPanel.mobile-view-hidden {
    display: none !important;
  }
}
@media (min-width: 821px) {
  #todayOverviewPanel { display: none !important; }
}

/* v1.6.0 – prominenter Hinweis für bereits vorhandene Google-Orte */
.google-place-selection.is-existing {
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 14px;
  border: 2px solid var(--accent);
  background: var(--accent-soft);
  font-size: 12px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .08);
}
.google-place-selection.is-existing .existing-place-icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 20px;
  font-weight: 900;
}
.google-place-selection.is-existing .existing-place-copy { display: grid; gap: 4px; min-width: 0; }
.google-place-selection.is-existing .existing-place-copy > strong {
  color: var(--text);
  font-size: 16px;
  line-height: 1.2;
}
.google-place-selection.is-existing .existing-place-name {
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
}
.google-place-selection.is-existing .existing-place-hint {
  margin-top: 4px;
  color: var(--text);
  font-weight: 700;
  line-height: 1.35;
}
#savePlaceBtn.existing-place-action { font-weight: 800; }
@media (max-width: 760px) {
  .google-place-selection.is-existing { padding: 15px 13px; border-radius: 12px; }
  .google-place-selection.is-existing .existing-place-copy > strong { font-size: 17px; }
  .google-place-selection.is-existing .existing-place-hint { font-size: 13px; }
}


/* v1.6.4: mobile distance sorting in Places */
.places-title-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 760px) {
  .mobile-distance-sort.mobile-only {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 6px 10px;
    border: 1px solid #d8d2c8;
    border-radius: 999px;
    background: #fff;
    color: #333;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
  }
  .mobile-distance-sort.mobile-only.active {
    border-color: #1f6f5f;
    background: #e9f5f1;
    color: #155548;
  }
  .mobile-distance-sort.mobile-only:disabled {
    opacity: .45;
    cursor: not-allowed;
  }
}


/* v1.7.0: Drag & Drop der Tagesplanung (Maus + Touch über Pointer Events) */
.agenda-item {
  position: relative;
}

.agenda-drag-handle {
  flex: 0 0 32px;
  width: 32px;
  min-height: 40px;
  border: 0;
  background: transparent;
  color: #78817f;
  font-size: 19px;
  font-weight: 900;
  line-height: 1;
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  border-radius: 8px;
}

.agenda-drag-handle:hover,
.agenda-drag-handle:focus-visible {
  background: #eef4f2;
  color: var(--accent);
  outline: none;
}

.agenda-drag-active {
  opacity: .72;
  transform: scale(.99);
}

.agenda-drag-active .agenda-item {
  box-shadow: 0 7px 20px rgba(25, 52, 48, .16);
  border-color: var(--accent);
}

body.agenda-dragging {
  cursor: grabbing;
  user-select: none;
  -webkit-user-select: none;
}

body.agenda-dragging .agenda-drag-handle { cursor: grabbing; }

@media (max-width: 760px) {
  .agenda-drag-handle {
    flex-basis: 36px;
    width: 36px;
    min-height: 44px;
    font-size: 20px;
  }
}


/* v1.7.1: kompakteres Drag & Drop mit sichtbarer Zielposition */
.agenda-timeline .agenda-drag-handle {
  width: 28px;
  min-height: 32px;
  padding: 0;
  font-size: 17px;
}

.agenda-timeline .agenda-visited-button {
  width: 30px;
  height: 30px;
}

.agenda-place-wrap {
  position: relative;
  transition: transform .14s ease;
}

.agenda-drag-active {
  position: relative;
  z-index: 20;
  opacity: .88;
  transform: scale(1.015);
}

.agenda-drag-active .agenda-item {
  background: #fff;
  box-shadow: 0 10px 24px rgba(25, 52, 48, .22);
  border-color: var(--accent);
}

.agenda-drop-before::before,
.agenda-drop-after::after {
  content: "";
  position: absolute;
  z-index: 30;
  left: 66px;
  right: 4px;
  height: 3px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 2px #fff;
  pointer-events: none;
}
.agenda-drop-before::before { top: -5px; }
.agenda-drop-after::after { bottom: 3px; }

body.agenda-dragging .agenda-place-wrap:not(.agenda-drag-active) .agenda-item {
  transition: transform .12s ease, border-color .12s ease;
}

@media (max-width: 820px) {
  .agenda-timeline .agenda-drag-handle {
    width: 30px;
    min-height: 34px;
    font-size: 18px;
  }
  .agenda-timeline .agenda-visited-button {
    width: 32px;
    height: 32px;
  }
  .agenda-drop-before::before,
  .agenda-drop-after::after { left: 72px; }
}


/* v1.7.3: Live-Reordering statt Drop-Linie */
.agenda-drop-before::before,
.agenda-drop-after::after {
  display: none !important;
  content: none !important;
}

.agenda-place-wrap {
  transition: none;
}

.agenda-drag-placeholder .agenda-item {
  opacity: .28;
  background: #eef4f2;
  border: 1.5px dashed rgba(31, 111, 95, .55);
  box-shadow: none;
}

.agenda-drag-placeholder .agenda-item > * {
  visibility: hidden;
}

.agenda-drag-placeholder .agenda-time-column {
  opacity: .55;
}

.agenda-drag-ghost {
  position: fixed !important;
  z-index: 9999 !important;
  margin: 0 !important;
  pointer-events: none !important;
  opacity: .96;
  background: #fff !important;
  border-color: var(--accent) !important;
  box-shadow: 0 16px 34px rgba(25, 52, 48, .25) !important;
  transform: translate3d(0,0,0) rotate(.25deg);
  transform-origin: center;
  transition: opacity .12s ease, box-shadow .12s ease;
  will-change: transform;
}

.agenda-drag-ghost .agenda-drag-handle {
  cursor: grabbing;
}

.agenda-drag-ghost-out {
  opacity: 0;
}

body.agenda-dragging {
  overflow: hidden;
  touch-action: none;
}


/* v1.9.1: kompakte Cluster für nahe beieinanderliegende Orte. */
.map-marker-cluster {
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  border: 3px solid rgba(255, 255, 255, 0.96);
  border-radius: 999px;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #2f625d;
  color: #fff;
  font: 700 14px/1 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.28);
  transform: translateY(-2px);
  user-select: none;
}

/* v1.10.0 – Aktivitäten im Tagesplan */
.activity-add-button { white-space: nowrap; }
.agenda-activity-item { border: 1px solid rgba(124,58,237,.22); background: linear-gradient(135deg, rgba(124,58,237,.08), rgba(255,255,255,.98)); }
.agenda-timeline-dot.activity { background: #7c3aed; color: #fff; font-size: 14px; }
.activity-status { display:inline-flex; padding:2px 7px; border-radius:999px; font-size:10px; font-weight:800; text-transform:uppercase; letter-spacing:.03em; background:#eef2f7; color:#475569; }
.activity-status.booked { background:#dcfce7; color:#166534; }
.agenda-activity-note { margin-top:5px; font-size:11px; line-height:1.35; color:#5f6765; }
.agenda-activity-menu { border:0; background:transparent; border-radius:8px; min-width:34px; min-height:34px; cursor:pointer; font-size:17px; color:#6d28d9; }
.agenda-activity-menu:hover { background:rgba(124,58,237,.1); }
.activity-place-selection { display:grid; gap:3px; margin-top:8px; padding:10px 12px; border:1px solid rgba(124,58,237,.25); border-radius:10px; background:rgba(124,58,237,.06); }
.activity-place-selection[hidden] { display:none; }
.activity-place-selection span { font-size:12px; color:#5f6765; }
.activity-info-window .info-title { color:#5b21b6; }
@media (max-width: 760px) { .agenda-day-header .activity-add-button { align-self:flex-start; font-size:12px; padding:7px 9px; } }

/* v1.10.1 – Aktivitätsdialog mobil kompakter und ohne unnötiges Scrollen */
@media (max-width: 760px) {
  .activity-dialog {
    width: min(94vw, 520px);
    max-height: none;
    overflow: visible;
  }

  .activity-dialog .place-form {
    padding: 18px 16px 16px;
  }

  .activity-dialog .dialog-head {
    margin-bottom: 14px;
  }

  .activity-dialog .dialog-head h2 {
    font-size: 21px;
  }

  .activity-dialog .form-field {
    min-width: 0;
    margin-bottom: 10px;
    gap: 4px;
  }

  .activity-dialog .google-place-autocomplete,
  .activity-dialog .google-place-autocomplete gmp-place-autocomplete {
    display: block;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    overflow: hidden;
  }

  .activity-dialog .form-field small {
    display: block;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
    line-height: 1.3;
    font-size: 11px;
  }

  .activity-dialog .form-grid {
    gap: 8px;
  }

  .activity-dialog .form-grid .form-field {
    margin-bottom: 8px;
  }

  .activity-dialog .form-field input,
  .activity-dialog .form-field select,
  .activity-dialog .form-field textarea {
    padding: 8px 10px;
  }

  .activity-dialog .form-field textarea {
    min-height: 64px;
  }

  .activity-dialog .dialog-actions {
    margin-top: 8px;
  }
}

@media (max-width: 420px) {
  .activity-dialog .place-form {
    padding-inline: 14px;
  }
}

/* v1.10.2 – Google Places Web Component strikt an mobile Dialogbreite binden */
@media (max-width: 760px) {
  .activity-dialog {
    box-sizing: border-box;
    overflow-x: hidden !important;
  }

  .activity-dialog .place-form {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }

  .activity-dialog .form-field {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }

  .activity-dialog #activityPlaceAutocomplete {
    display: block;
    box-sizing: border-box;
    inline-size: 100%;
    width: 100%;
    max-inline-size: 100%;
    max-width: 100%;
    min-inline-size: 0;
    min-width: 0;
    overflow: hidden;
  }

  .activity-dialog #activityPlaceAutocomplete > gmp-place-autocomplete {
    display: block !important;
    box-sizing: border-box !important;
    inline-size: 100% !important;
    width: 100% !important;
    max-inline-size: 100% !important;
    max-width: 100% !important;
    min-inline-size: 0 !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }

  .activity-dialog #activityPlaceAutocomplete + .activity-place-selection,
  .activity-dialog .form-field small {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: normal;
  }
}

/* v1.10.3 – mobile Aktivitätsdialog: vertikales Scrollen wieder zulassen,
   horizontales Überlaufen weiterhin verhindern */
@media (max-width: 760px) {
  .activity-dialog {
    max-height: 88dvh;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  .activity-dialog .place-form {
    overflow-x: hidden;
    overflow-y: visible;
  }

  .activity-dialog .dialog-actions {
    padding-bottom: max(4px, env(safe-area-inset-bottom));
  }
}

/* v1.10.4 – Aktivitätsdialog mobil: Formular als eigener Scrollbereich,
   Aktionen dauerhaft erreichbar. */
@media (max-width: 760px) {
  .activity-dialog {
    width: min(94vw, 520px);
    height: auto;
    max-height: 88dvh;
    padding: 0;
    overflow: hidden !important;
    box-sizing: border-box;
  }

  .activity-dialog .place-form {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    max-height: 88dvh;
    padding: 18px 16px 0;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
  }

  .activity-dialog .dialog-actions {
    position: sticky;
    z-index: 5;
    bottom: 0;
    margin: 12px -16px 0;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    background: #fff;
    border-top: 1px solid var(--border);
    box-shadow: 0 -8px 18px rgba(20, 28, 31, .06);
  }
}

@media (max-width: 420px) {
  .activity-dialog .place-form {
    padding-left: 14px;
    padding-right: 14px;
  }
  .activity-dialog .dialog-actions {
    margin-left: -14px;
    margin-right: -14px;
    padding-left: 14px;
    padding-right: 14px;
  }
}


/* v1.11.0 – In-App-Fußnavigation und lokaler Testmodus */
.navigation-actions { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin-top:10px; }
.navigation-start-button { font-weight:700; }
.navigation-start-button.navigation-stop-active { border-color:#b3261e; background:#fff4f3; color:#b3261e; }
#navigationTestBtn.active { outline:3px solid rgba(47,98,93,.2); }
.navigation-panel[hidden] { display:none !important; }
.navigation-panel {
  position:absolute; z-index:45; top:76px; left:50%; transform:translateX(-50%);
  width:min(560px, calc(100% - 32px)); box-sizing:border-box; padding:14px 16px;
  background:rgba(255,255,255,.97); border:1px solid var(--border); border-radius:16px;
  box-shadow:0 12px 34px rgba(20,28,31,.18); backdrop-filter:blur(8px);
}
.navigation-panel-head { display:flex; justify-content:space-between; gap:12px; align-items:flex-start; }
.navigation-eyebrow { font-size:.72rem; text-transform:uppercase; letter-spacing:.08em; opacity:.65; margin-bottom:2px; }
.navigation-stop-button { border:0; background:transparent; font-size:1.15rem; cursor:pointer; padding:4px 7px; }
.navigation-instruction { font-size:1.08rem; font-weight:750; line-height:1.3; margin-top:12px; }
.navigation-meta { margin-top:7px; font-size:.9rem; }
.navigation-progress { margin-top:6px; font-size:.8rem; opacity:.7; }
@media (max-width:820px) {
  .navigation-actions { grid-template-columns:1fr; }
  .navigation-panel { top:12px; width:calc(100% - 24px); border-radius:14px; padding:12px 14px; }
  .navigation-instruction { font-size:1rem; }
}

/* v1.11.1 – praxisnaher Navigationsmodus */
.navigation-active .map-legend,
.navigation-active .top-actions { opacity:.18; pointer-events:none; }
.navigation-panel { width:min(620px, calc(100% - 28px)); }
.navigation-guidance { display:flex; gap:14px; align-items:center; margin-top:10px; }
.navigation-maneuver-icon { flex:0 0 58px; width:58px; height:58px; display:grid; place-items:center; font-size:2.25rem; font-weight:800; background:#eef5ff; border-radius:14px; }
.navigation-guidance-text { min-width:0; flex:1; }
.navigation-maneuver-distance { font-size:1.35rem; font-weight:800; line-height:1.05; }
.navigation-instruction { margin-top:4px; font-size:1.08rem; }
.navigation-footer { display:flex; align-items:end; justify-content:space-between; gap:12px; margin-top:8px; }
.navigation-recenter-button { border:1px solid var(--border); background:#fff; border-radius:999px; padding:8px 11px; font-weight:700; white-space:nowrap; }
.navigation-position-arrow { --nav-heading:0deg; width:34px; height:34px; display:grid; place-items:center; border-radius:50%; background:rgba(66,133,244,.16); filter:drop-shadow(0 2px 4px rgba(0,0,0,.25)); }
.navigation-arrow-shape { display:block; color:#1769e0; font-size:30px; line-height:1; transform:rotate(var(--nav-heading)); transform-origin:center; text-shadow:0 0 0 #fff; }
@media (max-width:820px) {
  .navigation-panel { top:8px; width:calc(100% - 16px); padding:10px 12px; border-radius:16px; }
  .navigation-panel-head { align-items:center; }
  .navigation-eyebrow { display:none; }
  .navigation-guidance { gap:10px; margin-top:7px; }
  .navigation-maneuver-icon { flex-basis:52px; width:52px; height:52px; font-size:2rem; }
  .navigation-maneuver-distance { font-size:1.22rem; }
  .navigation-instruction { font-size:1rem; margin-top:2px; }
  .navigation-meta { margin-top:0; }
}


/* v1.11.3 – Richtungskarte, dynamischer Zoom, Manöver und GPS-Qualität */
.navigation-map-controls { display:flex; align-items:center; justify-content:flex-end; gap:7px; flex-wrap:wrap; }
.navigation-heading-button { border:1px solid var(--border); background:#fff; border-radius:999px; padding:8px 11px; font-weight:700; white-space:nowrap; }
.navigation-gps-quality { display:inline-flex; align-items:center; gap:5px; border-radius:999px; padding:6px 9px; font-size:.78rem; font-weight:750; background:#eef1f3; white-space:nowrap; }
.navigation-gps-quality::before { content:""; width:8px; height:8px; border-radius:50%; background:#8a9499; }
.navigation-gps-quality[data-level="good"]::before { background:#2e9d55; }
.navigation-gps-quality[data-level="medium"]::before { background:#d49a16; }
.navigation-gps-quality[data-level="poor"]::before { background:#cf4b45; }
.navigation-maneuver-icon { font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
@media (max-width:820px) {
  .navigation-footer { align-items:center; }
  .navigation-map-controls { gap:5px; }
  .navigation-heading-button, .navigation-recenter-button { padding:7px 9px; font-size:.78rem; }
  .navigation-gps-quality { padding:5px 7px; font-size:.72rem; }
}

/* v1.11.5 Tagesnavigation: Aktionen nach Erreichen eines Stopps */
.navigation-arrival-actions { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin-top:10px; }
.navigation-arrival-actions[hidden] { display:none !important; }
.navigation-arrival-button { border-radius:12px; padding:10px 12px; font-weight:750; cursor:pointer; }
.navigation-arrival-button.primary { border:1px solid #1769e0; background:#1769e0; color:#fff; }
.navigation-arrival-button.secondary { border:1px solid var(--border); background:#fff; color:inherit; }
.navigation-arrival-button:disabled { opacity:.58; cursor:default; }
@media (max-width:700px) { .navigation-arrival-actions { grid-template-columns:1fr; } }


/* v1.11.9 – mobile Karteninteraktion: keine App-Ebene blockiert Maps-Gesten. */
.navigation-active #map { pointer-events: auto !important; }
.navigation-active .map-wrap { pointer-events: auto; }
.navigation-active .navigation-panel { pointer-events: auto; }
@media (max-width: 820px) {
  body.navigation-active #map { pointer-events: auto !important; }
  body.navigation-active .mobile-scrim:not(.visible) { pointer-events: none !important; }
}


/* v1.12.0 – kompakte Navigationskarte */
.navigation-panel {
  padding: 9px 11px;
  border-radius: 14px;
}
.navigation-panel-head { min-height: 28px; align-items:center; }
.navigation-title-wrap { min-width:0; flex:1; }
.navigation-head-actions { display:flex; align-items:center; gap:2px; }
.navigation-expand-button,
.navigation-stop-button {
  width:34px; height:34px; display:grid; place-items:center; padding:0;
  border:0; border-radius:999px; background:transparent; font-size:1.05rem; cursor:pointer;
}
.navigation-expand-button:hover,.navigation-stop-button:hover { background:rgba(20,28,31,.06); }
.navigation-guidance { margin-top:4px; gap:9px; }
.navigation-maneuver-icon { flex-basis:46px; width:46px; height:46px; font-size:1.75rem; border-radius:12px; }
.navigation-maneuver-distance { font-size:1.12rem; }
.navigation-instruction {
  margin-top:1px; font-size:.94rem; line-height:1.22;
  display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden;
}
.navigation-footer { margin-top:6px; align-items:center; }
.navigation-summary { display:flex; align-items:center; gap:7px; flex-wrap:wrap; min-width:0; }
.navigation-meta,.navigation-eta,.navigation-progress { margin:0; font-size:.76rem; white-space:nowrap; }
.navigation-eta { opacity:.78; }
.navigation-progress { opacity:.72; }
.navigation-map-controls { flex-wrap:nowrap; }
.navigation-heading-button,.navigation-recenter-button { padding:5px 8px; font-size:.72rem; }
.navigation-gps-quality { padding:4px 6px; font-size:.68rem; }
/* Im kompakten Zustand bleibt der Zielname verfügbar, aber sehr dezent. */
.navigation-panel:not(.expanded) .navigation-eyebrow { display:none; }
.navigation-panel:not(.expanded) .navigation-title-wrap { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }
.navigation-panel:not(.expanded) .navigation-panel-head { position:absolute; right:9px; top:7px; z-index:2; }
.navigation-panel:not(.expanded) .navigation-guidance { padding-right:72px; margin-top:0; }
.navigation-panel:not(.expanded) .navigation-arrival-actions { margin-top:7px; }
/* Details im erweiterten Zustand */
.navigation-panel.expanded { padding:11px 13px; }
.navigation-panel.expanded .navigation-guidance { margin-top:7px; }
.navigation-panel.expanded .navigation-maneuver-icon { flex-basis:52px; width:52px; height:52px; font-size:2rem; }
.navigation-panel.expanded .navigation-instruction { font-size:1rem; -webkit-line-clamp:3; }
.navigation-panel.expanded .navigation-meta,.navigation-panel.expanded .navigation-eta,.navigation-panel.expanded .navigation-progress { font-size:.8rem; }
@media (max-width:820px) {
  .navigation-panel { top:8px; width:calc(100% - 16px); padding:8px 10px; border-radius:14px; }
  .navigation-panel:not(.expanded) .navigation-guidance { padding-right:70px; }
  .navigation-panel:not(.expanded) .navigation-footer { gap:6px; }
  .navigation-panel:not(.expanded) .navigation-map-controls { gap:4px; }
  .navigation-panel:not(.expanded) .navigation-heading-button { max-width:86px; overflow:hidden; text-overflow:ellipsis; }
}
@media (max-width:390px) {
  .navigation-panel:not(.expanded) .navigation-gps-quality { display:none; }
  .navigation-summary { gap:5px; }
}

/* v1.12.2 – kompakter, transparenter Zielbildschirm mit Konfetti */
.navigation-success[hidden] { display:none !important; }
.navigation-success {
  position:fixed; inset:0; z-index:120; display:grid; place-items:center;
  padding:18px; background:rgba(18,27,32,.16); backdrop-filter:blur(2px);
  overflow:hidden;
}
.navigation-success-card {
  position:relative; z-index:2; width:min(330px, calc(100vw - 44px)); box-sizing:border-box;
  padding:18px 18px 16px; text-align:center;
  background:rgba(255,255,255,.78);
  -webkit-backdrop-filter:blur(14px) saturate(145%); backdrop-filter:blur(14px) saturate(145%);
  border:1px solid rgba(255,255,255,.72); border-radius:20px;
  box-shadow:0 12px 34px rgba(20,28,31,.20);
  animation:navigation-success-pop .42s cubic-bezier(.2,.9,.25,1.2) both;
}
.navigation-success-icon { font-size:2rem; line-height:1; margin-bottom:7px; }
.navigation-success-card h2 { margin:0; font-size:1.3rem; line-height:1.12; }
.navigation-success-name { display:block; margin-top:8px; font-size:1rem; }
.navigation-success-note { margin:5px 0 13px; font-size:.9rem; line-height:1.3; opacity:.68; }
.navigation-success-button {
  width:auto; min-width:0; border:0; border-radius:12px; padding:9px 14px; cursor:pointer;
  background:rgba(23,105,224,.92); color:#fff; font:inherit; font-size:.92rem; font-weight:800;
  box-shadow:0 4px 12px rgba(23,105,224,.18);
}
@media (max-width:380px) {
  .navigation-success-card { width:min(300px, calc(100vw - 32px)); padding:16px 15px 14px; }
}
.navigation-confetti { position:absolute; inset:0; z-index:1; pointer-events:none; overflow:hidden; }
.navigation-confetti-piece {
  position:absolute; top:-24px; width:9px; height:16px; border-radius:2px;
  background:var(--confetti-color); opacity:0;
  animation:navigation-confetti-fall var(--confetti-duration) ease-in var(--confetti-delay) forwards;
}
@keyframes navigation-success-pop {
  from { opacity:0; transform:translateY(18px) scale(.94); }
  to { opacity:1; transform:translateY(0) scale(1); }
}
@keyframes navigation-confetti-fall {
  0% { opacity:0; transform:translate3d(0,-20px,0) rotate(0deg); }
  10% { opacity:1; }
  100% { opacity:0; transform:translate3d(var(--confetti-drift),105vh,0) rotate(var(--confetti-rotate)); }
}
@media (prefers-reduced-motion: reduce) {
  .navigation-success-card { animation:none; }
  .navigation-confetti-piece { animation:none; display:none; }
}


/* v1.13.1 – Navigation pausieren + Online-/Offline-Status */
.navigation-pause-button { border:0; background:transparent; border-radius:9px; padding:5px 7px; font-size:.76rem; font-weight:750; cursor:pointer; white-space:nowrap; }
.navigation-pause-button:hover { background:rgba(20,28,31,.06); }
.navigation-panel.paused .navigation-guidance { opacity:.58; }
.navigation-panel.paused .navigation-maneuver-icon { filter:grayscale(.45); }
.navigation-connectivity { display:inline-flex; align-items:center; border-radius:999px; padding:4px 6px; font-size:.68rem; font-weight:750; white-space:nowrap; }
.navigation-connectivity[data-state="online"] { color:#267d43; background:rgba(46,157,85,.10); }
.navigation-connectivity[data-state="offline"] { color:#b33b35; background:rgba(207,75,69,.12); }
@media (max-width:700px) {
  .navigation-pause-button { padding:4px 6px; font-size:.7rem; }
  .navigation-panel:not(.expanded) .navigation-connectivity[data-state="online"] { display:none; }
  .navigation-connectivity { padding:3px 5px; font-size:.64rem; }
}


/* v1.13.3 – Stopps überspringen / direkt zu späterem Tagesstopp */
.navigation-skip-button { border:1px solid var(--border); background:#fff; color:inherit; border-radius:999px; padding:5px 8px; font-size:.72rem; cursor:pointer; white-space:nowrap; }
.navigation-panel:not(.expanded) .navigation-skip-button { display:none; }
.navigation-skip-dialog { width:min(430px, calc(100vw - 24px)); max-height:min(70vh, 560px); border:0; border-radius:18px; padding:0; box-shadow:0 18px 60px rgba(0,0,0,.24); color:inherit; background:var(--surface, #fff); }
.navigation-skip-dialog[hidden] { display:none !important; }
.navigation-skip-dialog::backdrop { background:rgba(12,18,22,.32); backdrop-filter:blur(2px); }
.navigation-skip-head { display:flex; align-items:flex-start; gap:12px; padding:16px 16px 12px; border-bottom:1px solid var(--border); }
.navigation-skip-head > div { flex:1; min-width:0; }
.navigation-skip-head strong { display:block; font-size:1rem; }
.navigation-skip-head small { display:block; margin-top:3px; opacity:.7; line-height:1.3; }
.navigation-skip-head button { width:34px; height:34px; border:0; border-radius:999px; background:transparent; cursor:pointer; font-size:1rem; }
.navigation-skip-list { display:grid; gap:8px; padding:12px 14px 16px; overflow:auto; max-height:calc(70vh - 85px); }
.navigation-skip-target { display:grid; grid-template-columns:32px 1fr; align-items:center; gap:8px; width:100%; text-align:left; border:1px solid var(--border); background:#fff; color:inherit; border-radius:12px; padding:10px 12px; cursor:pointer; }
.navigation-skip-target:hover { background:rgba(20,28,31,.04); }
.navigation-skip-target > span:first-child { font-size:1.25rem; }
.navigation-skip-target strong,.navigation-skip-target small { display:block; }
.navigation-skip-target small { margin-top:2px; opacity:.65; }

/* v1.13.4 – mobile Navigationsleiste: Status und Aktionen sauber trennen */
@media (max-width: 820px) {
  .navigation-panel.expanded .navigation-footer {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    align-items: stretch;
  }

  .navigation-panel.expanded .navigation-summary {
    display: flex;
    width: 100%;
    gap: 6px 10px;
    flex-wrap: wrap;
    align-items: center;
  }

  .navigation-panel.expanded .navigation-map-controls {
    display: flex;
    width: 100%;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
  }

  .navigation-panel.expanded .navigation-connectivity,
  .navigation-panel.expanded .navigation-gps-quality,
  .navigation-panel.expanded .navigation-skip-button,
  .navigation-panel.expanded .navigation-heading-button,
  .navigation-panel.expanded .navigation-recenter-button {
    flex: 0 0 auto;
  }

  .navigation-panel.expanded .navigation-heading-button,
  .navigation-panel.expanded .navigation-skip-button,
  .navigation-panel.expanded .navigation-recenter-button {
    padding: 6px 9px;
    font-size: .74rem;
  }
}

@media (max-width: 430px) {
  .navigation-panel.expanded .navigation-map-controls {
    display: grid;
    grid-template-columns: auto auto 1fr;
  }

  .navigation-panel.expanded .navigation-skip-button,
  .navigation-panel.expanded .navigation-heading-button,
  .navigation-panel.expanded .navigation-recenter-button {
    justify-self: stretch;
    text-align: center;
  }
}


/* v1.14.1 – intelligente Tagesnavigation: Pufferberechnung + mobile Lesbarkeit */
.navigation-schedule {
  margin-top: 5px;
  padding: 6px 9px;
  border-radius: 10px;
  background: #eef7f1;
  color: #245b36;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.3;
}
.navigation-schedule.tight { background: #fff6df; color: #7a5600; }
.navigation-schedule.late { background: #fff0f0; color: #9b2c2c; }
.navigation-schedule[hidden] { display: none !important; }
@media (max-width: 700px) {
  .navigation-schedule { width: 100%; box-sizing: border-box; font-size: 11.5px; }
}

.navigation-schedule-time,
.navigation-schedule-eta {
  display: block;
  white-space: normal;
  overflow-wrap: anywhere;
}
.navigation-schedule-eta { margin-top: 2px; font-weight: 700; }
@media (max-width: 700px) {
  .navigation-schedule { font-size: 12px; line-height: 1.35; padding: 7px 10px; }
}

/* v1.14.2 – Navigation: luftigere mobile Karte und eigener Chevron */
.navigation-panel {
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(20,28,31,.15);
}
.navigation-expand-button {
  position: relative;
  width: 40px;
  height: 40px;
  background: rgba(20,28,31,.055);
  transition: background .18s ease, transform .18s ease;
}
.navigation-expand-button:hover { background: rgba(20,28,31,.09); }
.navigation-chevron {
  display: block;
  width: 9px;
  height: 9px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform .2s ease;
}
.navigation-panel.expanded .navigation-chevron {
  transform: translateY(2px) rotate(225deg);
}
.navigation-schedule {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(46,157,85,.085);
  font-size: 13px;
  line-height: 1.4;
  font-weight: 700;
}
.navigation-schedule.tight { background: rgba(232,174,39,.14); color:#72520a; }
.navigation-schedule.late { background: rgba(207,75,69,.11); color:#8c3230; }
.navigation-schedule-time { font-weight: 800; }
.navigation-schedule-eta { margin-top: 3px; font-weight: 650; }

@media (max-width: 820px) {
  .navigation-panel,
  .navigation-panel.expanded {
    width: calc(100% - 28px);
    top: 14px;
    padding: 18px 18px 16px;
    border-radius: 22px;
  }
  .navigation-panel-head { min-height: 40px; gap: 10px; }
  .navigation-title-wrap strong { font-size: 1.05rem; line-height: 1.18; }
  .navigation-head-actions { gap: 5px; }
  .navigation-pause-button { padding: 7px 9px; font-size: .76rem; }
  .navigation-stop-button { width: 40px; height: 40px; }

  .navigation-panel.expanded .navigation-guidance { margin-top: 12px; gap: 14px; }
  .navigation-panel.expanded .navigation-maneuver-icon {
    flex-basis: 58px; width:58px; height:58px; border-radius:16px;
  }
  .navigation-panel.expanded .navigation-maneuver-distance { font-size: 1.28rem; }
  .navigation-panel.expanded .navigation-instruction { font-size: 1.02rem; line-height:1.3; }

  .navigation-panel.expanded .navigation-footer { margin-top: 12px; gap: 12px; }
  .navigation-panel.expanded .navigation-summary { gap: 8px 12px; }
  .navigation-panel.expanded .navigation-meta,
  .navigation-panel.expanded .navigation-eta { font-size: .82rem; }
  .navigation-panel.expanded .navigation-progress {
    flex-basis: 100%;
    margin-top: 1px;
    font-size: .78rem;
  }
  .navigation-panel.expanded .navigation-schedule { flex-basis: 100%; width:100%; box-sizing:border-box; }

  .navigation-panel.expanded .navigation-map-controls {
    display:grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    width:100%;
  }
  .navigation-panel.expanded .navigation-connectivity,
  .navigation-panel.expanded .navigation-gps-quality,
  .navigation-panel.expanded .navigation-skip-button,
  .navigation-panel.expanded .navigation-heading-button,
  .navigation-panel.expanded .navigation-recenter-button {
    min-height: 38px;
    box-sizing:border-box;
    display:flex;
    align-items:center;
    justify-content:center;
    width:100%;
    border-radius: 12px;
  }
  .navigation-panel.expanded .navigation-connectivity,
  .navigation-panel.expanded .navigation-gps-quality { padding: 7px 9px; font-size:.75rem; }
  .navigation-panel.expanded .navigation-skip-button,
  .navigation-panel.expanded .navigation-heading-button,
  .navigation-panel.expanded .navigation-recenter-button { padding: 8px 10px; font-size:.78rem; }
}

@media (max-width: 430px) {
  .navigation-panel.expanded .navigation-map-controls { grid-template-columns: 1fr 1fr; }
  .navigation-panel.expanded .navigation-skip-button,
  .navigation-panel.expanded .navigation-heading-button,
  .navigation-panel.expanded .navigation-recenter-button { justify-self:stretch; }
}


/* v1.14.3 – Navigation: mehr Kartenfläche bei gleicher visueller Sprache */
@media (max-width: 820px) {
  .navigation-panel,
  .navigation-panel.expanded {
    width: calc(100% - 24px);
    top: 12px;
    padding: 13px 14px 12px;
    border-radius: 20px;
  }
  .navigation-panel-head { min-height: 34px; gap: 8px; }
  .navigation-title-wrap strong { font-size: 1rem; }
  .navigation-head-actions { gap: 4px; }
  .navigation-pause-button { padding: 6px 8px; }
  .navigation-expand-button,
  .navigation-stop-button { width: 36px; height: 36px; }

  .navigation-panel.expanded .navigation-guidance { margin-top: 8px; gap: 11px; }
  .navigation-panel.expanded .navigation-maneuver-icon {
    flex-basis: 52px; width: 52px; height: 52px; border-radius: 15px;
  }
  .navigation-panel.expanded .navigation-maneuver-distance { font-size: 1.18rem; }
  .navigation-panel.expanded .navigation-instruction {
    font-size: .96rem; line-height: 1.24;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .navigation-panel.expanded .navigation-footer { margin-top: 8px; gap: 8px; }
  .navigation-panel.expanded .navigation-summary { gap: 5px 10px; }
  .navigation-panel.expanded .navigation-schedule {
    margin-top: 5px; padding: 8px 10px; border-radius: 12px; font-size: 12px; line-height: 1.32;
  }
  .navigation-panel.expanded .navigation-progress { margin-top: 0; }

  /* Status + Hauptaktionen in einer kompakten Zeile; Position nur bei Bedarf darunter. */
  .navigation-panel.expanded .navigation-map-controls {
    grid-template-columns: auto auto 1fr 1fr;
    gap: 6px;
    align-items: center;
  }
  .navigation-panel.expanded .navigation-connectivity,
  .navigation-panel.expanded .navigation-gps-quality {
    width: auto; min-height: 34px; padding: 6px 8px; font-size: .72rem; border-radius: 11px;
  }
  .navigation-panel.expanded .navigation-skip-button,
  .navigation-panel.expanded .navigation-heading-button {
    width: 100%; min-height: 34px; padding: 6px 8px; font-size: .74rem; border-radius: 11px;
  }
  .navigation-panel.expanded .navigation-recenter-button {
    grid-column: 1 / -1; width: auto; min-height: 34px; padding: 6px 12px; justify-self: start;
  }
}

@media (max-width: 430px) {
  .navigation-panel.expanded .navigation-map-controls {
    grid-template-columns: auto auto 1fr;
  }
  .navigation-panel.expanded .navigation-heading-button { grid-column: 3; }
  .navigation-panel.expanded .navigation-skip-button { grid-column: 1 / 3; grid-row: 2; }
  .navigation-panel.expanded .navigation-heading-button { grid-row: 2; }
  .navigation-panel.expanded .navigation-recenter-button { grid-column: 1 / -1; }
}


/* v1.14.4 – Position neben GPS, damit bei aktivem Recenter keine Zusatzzeile entsteht */
@media (max-width: 820px) {
  .navigation-panel.expanded .navigation-map-controls {
    grid-template-columns: auto auto auto 1fr 1fr;
  }
  .navigation-panel.expanded .navigation-recenter-button {
    grid-column: auto;
    grid-row: auto;
    width: auto;
    min-height: 34px;
    padding: 6px 9px;
    justify-self: stretch;
    white-space: nowrap;
  }
}

@media (max-width: 430px) {
  .navigation-panel.expanded .navigation-map-controls {
    grid-template-columns: auto auto auto;
  }
  .navigation-panel.expanded .navigation-connectivity { grid-column: 1; grid-row: 1; }
  .navigation-panel.expanded .navigation-gps-quality { grid-column: 2; grid-row: 1; }
  .navigation-panel.expanded .navigation-recenter-button { grid-column: 3; grid-row: 1; }
  .navigation-panel.expanded .navigation-skip-button { grid-column: 1 / 3; grid-row: 2; }
  .navigation-panel.expanded .navigation-heading-button { grid-column: 3; grid-row: 2; }
}


/* v1.14.5 – Navigationskarte: vollständige Anweisung + kompaktere Controls */
@media (max-width: 820px) {
  .navigation-panel.expanded .navigation-instruction {
    display: block;
    -webkit-line-clamp: unset;
    -webkit-box-orient: initial;
    overflow: visible;
    text-overflow: clip;
  }
  .navigation-panel.expanded .navigation-map-controls {
    grid-template-columns: auto minmax(92px, auto) minmax(98px, auto) 1fr 1fr;
  }
  .navigation-panel.expanded .navigation-gps-quality {
    min-width: 92px;
    overflow: visible;
    text-overflow: clip;
    white-space: nowrap;
  }
}

@media (max-width: 430px) {
  .navigation-panel.expanded .navigation-map-controls {
    grid-template-columns: auto minmax(104px, auto) 1fr;
  }
  .navigation-panel.expanded .navigation-connectivity { grid-column: 1; grid-row: 1; }
  .navigation-panel.expanded .navigation-gps-quality { grid-column: 2; grid-row: 1; }
  .navigation-panel.expanded .navigation-recenter-button { grid-column: 3; grid-row: 1; }
  .navigation-panel.expanded .navigation-skip-button { grid-column: 1 / 3; grid-row: 2; }
  .navigation-panel.expanded .navigation-heading-button { grid-column: 3; grid-row: 2; }
}


/* v1.15.0 – Tages-Timeline */
.agenda-header-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
}
.agenda-leg {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: center;
  gap: 5px;
  min-height: 30px;
  padding: 5px 8px 4px 8px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.3;
}
.agenda-leg span:first-child { text-align: center; }
.agenda-estimate-note {
  margin-top: 7px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.35;
}
@media (max-width: 820px) {
  .agenda-header-actions { flex-direction: column; align-items: flex-end; gap: 5px; }
  .agenda-leg { font-size: 11px; min-height: 32px; }
  .agenda-estimate-note { font-size: 10px; }
}


/* v1.16.0 – „Was jetzt?“ */
.today-what-now-card {
  background: linear-gradient(135deg, #f3f9f7 0%, #ffffff 72%);
  border: 1px solid #cfe1dc;
  border-radius: 16px;
  padding: 14px;
  box-shadow: 0 6px 18px rgba(47, 98, 93, .07);
}
.today-what-now-head { display:flex; align-items:flex-start; justify-content:space-between; gap:10px; }
.today-what-now-subtitle { margin-top:3px; color:#68716f; font-size:11px; }
.today-what-now-main {
  width:100%; display:grid; grid-template-columns:44px minmax(0,1fr) auto;
  gap:10px; align-items:center; border:0; background:transparent; padding:13px 0;
  text-align:left; color:inherit; cursor:pointer;
}
.today-what-now-main strong { display:block; font-size:17px; line-height:1.2; }
.today-what-now-main small { display:block; margin-top:4px; color:#68716f; font-size:12px; line-height:1.35; }
.today-what-now-actions { display:grid; grid-template-columns:1.2fr .8fr; gap:8px; }


/* v1.17.0 – Öffnungszeiten im Tagesplan */
.agenda-opening-status,
.today-opening-status {
  display:inline-flex; align-items:center; width:max-content; max-width:100%;
  margin-top:5px; padding:3px 7px; border-radius:999px;
  font-size:10px; font-weight:800; line-height:1.2;
}
.agenda-opening-status.ok, .today-opening-status.ok { background:#eaf6ef; color:#286344; }
.agenda-opening-status.warning, .today-opening-status.warning { background:#fff1e8; color:#9a4d19; }
.agenda-opening-status.info, .today-opening-status.info { background:#eef3f2; color:#53615e; }
.today-opening-status { font-size:11px; }


/* v1.18.0 – Wetterintegration */
.today-day-side { display:flex; flex-direction:column; align-items:flex-end; gap:7px; }
.today-weather-summary {
  white-space:nowrap; padding:5px 8px; border-radius:10px;
  background:#edf5f3; color:#2f625d; font-size:11px;
}
.today-weather-summary.muted { color:#68716f; background:#f1f3f2; }
.weather-badge {
  display:inline-flex; width:max-content; max-width:100%; align-items:center;
  margin-top:5px; padding:3px 7px; border-radius:999px;
  background:#eef4f8; color:#3f5f72; font-size:10px; font-weight:800; line-height:1.2;
}
.today-status-row { display:flex; flex-wrap:wrap; gap:5px; align-items:center; }
.today-status-row .weather-badge, .today-status-row .today-opening-status { margin-top:5px; }
@media (max-width:820px) {
  .weather-badge { font-size:11px; }
  .today-weather-summary { font-size:11px; }
}


/* v1.19.0 – PWA / Offline-Basis */
.app-connectivity {
  display:inline-flex; align-items:center; width:max-content;
  margin-top:5px; padding:3px 7px; border-radius:999px;
  background:#eaf6ef; color:#286344; font-size:10px; font-weight:800;
}
.app-connectivity.offline { background:#fff1e8; color:#9a4d19; }


/* v1.19.0 – PWA / Offline-Basis */
.app-connectivity { display:inline-flex; align-items:center; width:max-content; margin-top:5px; padding:3px 7px; border-radius:999px; background:#eaf6ef; color:#286344; font-size:10px; font-weight:800; }
.app-connectivity.offline { background:#fff1e8; color:#9a4d19; }


/* v1.19.3 – Offline-Routen */
.offline-route-panel { margin-top:10px; padding:10px; border:1px solid #dce5e2; border-radius:12px; background:#f8fbfa; }
.offline-route-title { margin-bottom:8px; font-size:12px; font-weight:800; color:#355e59; }
.offline-prepare-button { width:100%; }
.offline-route-status { display:grid; gap:3px; margin-top:8px; color:#596562; font-size:10px; line-height:1.35; }
.offline-route-status small { margin-top:4px; color:#78817f; }
@media (max-width:820px) { .offline-route-status { font-size:11px; } }


/* v1.20.0 – Budapest Offline-Karte */
#offlineMap { display:none; position:absolute; inset:0; width:100%; height:100%; z-index:1; background:#f5f1e8; }
#offlineMap.offline-map-active { display:block; }
#map.map-hidden { visibility:hidden; }
#offlineMap .maplibregl-ctrl-bottom-left, #offlineMap .maplibregl-ctrl-bottom-right { font-size:9px; }


/* v1.21.0 – Wetterausbau */
.weather-now-card{display:flex;align-items:center;gap:14px;padding:14px;margin-bottom:10px;border:1px solid var(--border);border-radius:14px;background:linear-gradient(135deg,#f4f8fb,#fff)}
.weather-now-icon{font-size:34px}.weather-now-main{display:grid;gap:2px}.weather-now-main span,.weather-now-main small{color:var(--muted);font-size:11px}.weather-now-main strong{font-size:24px}
.trip-weather-strip{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;margin-bottom:12px}.trip-weather-day{display:grid;gap:4px;padding:8px;border:1px solid var(--border);border-radius:10px;background:var(--surface-soft);font-size:10px}.trip-weather-day span{font-weight:700}.trip-weather-day small{color:var(--muted)}
.agenda-weather-card{margin:10px 0 14px;padding:12px;border:1px solid var(--border);border-radius:12px;background:#f7fafb}.agenda-weather-card>div:first-child{display:flex;justify-content:space-between;gap:10px}.agenda-weather-card>div:first-child span{color:var(--muted);font-size:11px}
.weather-periods{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;margin-top:10px}.weather-period{display:grid;gap:3px;padding:8px;border-radius:9px;background:#fff;font-size:10px}.weather-period>span:first-child{font-weight:700}.weather-period small{display:block;color:var(--muted);font-weight:400}
@media(max-width:820px){.trip-weather-strip{grid-template-columns:repeat(5,120px);overflow-x:auto;padding-bottom:4px}.weather-periods{grid-template-columns:repeat(3,1fr)}.weather-period{padding:7px 5px}}



/* v1.23.0 – Was jetzt? 2.0 */
.what-now-status {
  display:inline-flex; align-items:center; width:max-content; max-width:100%;
  margin-top:10px; padding:5px 9px; border-radius:999px;
  font-size:11px; font-weight:800;
  background:#eef3f2; color:#53615e;
}
.what-now-status.urgent { background:#fff0df; color:#8a4b00; }
.what-now-status.warning { background:#fff1e8; color:#9a4d19; }
.what-now-status.ok { background:#eaf6ef; color:#286344; }
.what-now-done {
  width:100%; margin-top:8px; border:0; background:transparent;
  color:var(--accent); font-size:12px; font-weight:800; padding:7px; cursor:pointer;
}


/* v1.24.0 – In meiner Nähe */
.today-nearby-card {
  margin-top:10px; padding:14px; border:1px solid var(--border);
  border-radius:16px; background:#fff;
}
.today-nearby-head { display:flex; align-items:flex-start; justify-content:space-between; gap:10px; }
.today-nearby-refresh {
  flex:0 0 34px; width:34px; height:34px; border:1px solid var(--border);
  border-radius:50%; background:var(--surface-soft); color:var(--accent);
  font-size:20px; line-height:1; cursor:pointer;
}
.today-nearby-list { display:grid; margin-top:8px; }
.today-nearby-row {
  width:100%; display:grid; grid-template-columns:38px minmax(0,1fr) auto;
  gap:9px; align-items:center; padding:10px 2px; border:0;
  border-bottom:1px solid #edf0ee; background:transparent; color:inherit;
  text-align:left; cursor:pointer;
}
.today-nearby-row:last-child { border-bottom:0; }
.today-nearby-icon { display:grid; place-items:center; width:34px; height:34px; border-radius:50%; background:#eef4f2; font-size:18px; }
.today-nearby-copy { min-width:0; }
.today-nearby-copy strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:13px; }
.today-nearby-copy small { display:block; margin-top:3px; color:#68716f; font-size:11px; line-height:1.35; }
.today-nearby-empty { padding:12px 0 8px; color:#68716f; font-size:12px; line-height:1.4; }
.today-nearby-all, .today-nearby-locate { margin-top:8px; }

/* v1.24.1 – Öffnungszeiten in „In meiner Nähe“ */
.today-nearby-opening { display:block; margin-top:4px; font-size:11px; font-weight:800; }
.today-nearby-opening.open { color:#28714c; }
.today-nearby-opening.soon { color:#946300; }
.today-nearby-opening.unknown { color:#737b79; font-weight:700; }
.today-nearby-opening.closed { color:#a14d4d; font-weight:700; }


/* v1.25.0 – Machbarkeit der Tagesplanung */
.feasibility-card { margin-top:10px; padding:13px 14px; border:1px solid var(--border); border-radius:16px; background:#fff; }
.feasibility-card.ok { border-color:#b9ddc8; background:#f5fbf7; }
.feasibility-card.warning { border-color:#ead7a3; background:#fffaf0; }
.feasibility-card.danger { border-color:#e5b9b9; background:#fff6f6; }
.feasibility-card.info { border-color:#cbd8dc; background:#f6fafb; }
.feasibility-head { display:flex; gap:10px; align-items:flex-start; }
.feasibility-icon { flex:0 0 28px; width:28px; height:28px; display:grid; place-items:center; border-radius:50%; background:#e8f2ef; color:#315e57; font-weight:900; }
.feasibility-card.warning .feasibility-icon { background:#fff0c9; color:#8b6200; }
.feasibility-card.danger .feasibility-icon { background:#f8dddd; color:#9a3838; }
.feasibility-head strong { display:block; font-size:13px; }
.feasibility-head small { display:block; margin-top:2px; color:#68716f; font-size:11px; line-height:1.35; }
.feasibility-issues { display:grid; gap:6px; margin-top:10px; }
.feasibility-issue { display:grid; grid-template-columns:20px 1fr; gap:5px; font-size:11px; line-height:1.4; }
.feasibility-issue.danger { color:#8e3434; }
.feasibility-issue.warning { color:#7b610d; }
.feasibility-more { margin-top:3px; font-size:11px; font-weight:700; color:#68716f; }
.feasibility-note { margin-top:9px; padding-top:8px; border-top:1px solid rgba(0,0,0,.06); color:#7a817f; font-size:10px; line-height:1.35; }


/* v1.26.0 – Freie Zeit nutzen */
.free-time-card { margin-top:10px; padding:14px; border:1px solid #c8ddd7; border-radius:16px; background:#f7fbfa; }
.free-time-card.leave { border-color:#ead7a3; background:#fffaf0; }
.free-time-kicker { margin-bottom:7px; color:#5f6d69; font-size:11px; font-weight:800; text-transform:uppercase; letter-spacing:.03em; }
.free-time-head { display:flex; align-items:flex-start; justify-content:space-between; gap:10px; }
.free-time-head strong, .free-time-card.leave > strong { display:block; font-size:14px; }
.free-time-head small { display:block; margin-top:3px; color:#68716f; font-size:11px; }
.free-time-stay { flex:0 0 auto; padding:5px 8px; border-radius:999px; background:#e5f2ee; color:#2f625d; font-size:10px; font-weight:800; }
.free-time-opening { margin-top:9px; font-size:11px; font-weight:800; }
.free-time-opening.open { color:#28714c; } .free-time-opening.soon { color:#946300; } .free-time-opening.unknown { color:#737b79; }
.free-time-next, .free-time-main, .free-time-advice { margin-top:7px; color:#5f6966; font-size:11px; line-height:1.45; }
.free-time-map { margin-top:10px; width:100%; }


/* v1.27.0 – Reise-/Statusübersicht */
.trip-status-card { margin-top:10px; padding:14px; border:1px solid var(--border); border-radius:18px; background:#fff; }
.trip-status-head { display:flex; justify-content:space-between; align-items:flex-start; gap:10px; }
.trip-status-total { padding:5px 8px; border-radius:999px; background:#eef4f2; color:#42635d; font-size:10px; font-weight:800; white-space:nowrap; }
.trip-status-stats { display:grid; grid-template-columns:repeat(4,1fr); gap:6px; margin-top:12px; }
.trip-status-stats > div { padding:8px 4px; border-radius:11px; background:var(--surface-soft); text-align:center; }
.trip-status-stats strong { display:block; font-size:15px; }
.trip-status-stats span { display:block; margin-top:2px; color:#727a78; font-size:9px; line-height:1.2; }
.trip-status-progress { height:5px; margin:10px 1px 6px; overflow:hidden; border-radius:999px; background:#e8ecea; }
.trip-status-progress span { display:block; height:100%; border-radius:inherit; background:#4e756e; }
.trip-status-days { display:grid; margin-top:4px; }
.trip-status-day { display:grid; grid-template-columns:28px minmax(0,1fr) auto auto; gap:8px; align-items:center; width:100%; padding:9px 2px; border:0; border-bottom:1px solid #edf0ee; background:transparent; color:inherit; text-align:left; cursor:pointer; }
.trip-status-day:last-child { border-bottom:0; }
.trip-status-day-number { display:grid; place-items:center; width:26px; height:26px; border-radius:50%; background:#eef4f2; color:#42635d; font-size:11px; font-weight:900; }
.trip-status-day-copy { min-width:0; }
.trip-status-day-copy strong { display:block; font-size:12px; }
.trip-status-day-copy small { display:block; margin-top:2px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#747c79; font-size:10px; }
.trip-status-day-side { display:flex; gap:7px; align-items:center; font-size:11px; white-space:nowrap; }
@media (max-width:380px) { .trip-status-stats { grid-template-columns:repeat(2,1fr); } .trip-status-day-side > span:first-child { display:none; } }


/* v1.27.1 – Reiseübersicht in den Plan integriert */
.plan-trip-overview { margin:8px 0 12px; }
.plan-trip-overview .trip-status-card { margin-top:0; }


/* v1.28.0 – UI/UX Refresh: Plan */
.plan-trip-overview { margin:0 0 18px; }
.plan-trip-overview .trip-status-card { padding:13px 14px 10px; border-radius:16px; }
.trip-status-summary { display:flex; gap:7px 14px; align-items:center; flex-wrap:wrap; margin-top:10px; padding:9px 0 7px; color:#68716f; font-size:11px; line-height:1.25; }
.trip-status-summary span { white-space:nowrap; }
.trip-status-summary strong { color:#252b2a; font-size:12px; }
.plan-trip-overview .trip-status-progress { margin:3px 0 7px; height:4px; }
.plan-trip-overview .trip-status-day { padding:8px 2px; }
.plan-trip-overview .trip-status-day-number { width:24px; height:24px; font-size:10px; }
.plan-trip-overview .trip-status-day-copy strong { font-size:12px; }
.plan-trip-overview .trip-status-day-copy small { font-size:9.5px; }

.desktop-plan-section .plan-title-row { margin-top:2px; padding-top:14px; border-top:1px solid #e6e9e7; align-items:center; }
.desktop-plan-section .plan-title-row h2 { margin:0; font-size:17px; }
.desktop-plan-section .plan-header-actions { gap:6px; }
.desktop-plan-section .mini-action-button { min-height:34px; padding:6px 10px; border-radius:999px; font-size:11px; }

.desktop-plan-section .day-filter-list {
  display:flex;
  flex-wrap:nowrap;
  gap:7px;
  margin:10px -2px 14px;
  padding:2px 2px 6px;
  overflow-x:auto;
  overscroll-behavior-x:contain;
  scrollbar-width:none;
  -webkit-overflow-scrolling:touch;
}
.desktop-plan-section .day-filter-list::-webkit-scrollbar { display:none; }
.desktop-plan-section .day-filter-button {
  flex:0 0 auto;
  min-width:auto;
  min-height:38px;
  padding:7px 12px;
  border-radius:999px;
  white-space:nowrap;
  font-size:12px;
}
.desktop-plan-section .day-filter-button.active { box-shadow:0 2px 8px rgba(47,98,93,.16); }

.desktop-plan-section .agenda-panel,
.desktop-plan-section .route-panel { border-radius:16px; }
.desktop-plan-section .agenda-heading { font-size:12px; letter-spacing:.02em; }

@media (max-width:700px) {
  .plan-trip-overview .trip-status-card { padding:12px; }
  .plan-trip-overview .trip-status-head { align-items:center; }
  .plan-trip-overview .trip-status-total { font-size:9.5px; }
  .trip-status-summary { gap:6px 12px; font-size:10.5px; }
  .desktop-plan-section .plan-title-row { display:flex; gap:8px; }
  .desktop-plan-section .plan-header-actions { margin-left:auto; flex-wrap:nowrap; }
  .desktop-plan-section .mini-action-button { padding:6px 9px; }
}


/* v1.29.0 – UI/UX Refresh: Heute */
.today-overview { display:grid; gap:10px; }
.today-overview > * { margin-top:0 !important; margin-bottom:0 !important; }

.today-day-card {
  padding:11px 13px;
  border-radius:16px;
  background:linear-gradient(135deg,#f7fbfa,#fff);
}
.today-day-card h2 { margin:2px 0 0; font-size:17px; line-height:1.2; }
.today-day-label { display:none; }
.today-kicker { font-size:10px; letter-spacing:.05em; }
.today-day-number { font-size:10px; }
.today-weather-summary { margin-top:4px; font-size:11px; }

.today-what-now-card {
  padding:14px;
  border-radius:18px;
  border-color:#b9d5ce;
  box-shadow:0 5px 18px rgba(47,98,93,.08);
}
.today-what-now-card .today-card-label { font-size:12px; }
.today-what-now-subtitle { font-size:10px; }
.today-what-now-main { padding:11px 0 9px; }
.today-what-now-main strong { font-size:15px; }
.today-what-now-main small { margin-top:3px; font-size:10.5px; }
.today-what-now-actions { grid-template-columns:minmax(0,1.5fr) minmax(0,1fr); gap:7px; }
.today-what-now-actions .primary-button { font-weight:800; }
.what-now-done { margin-top:6px; }

.free-time-card { padding:12px 13px; border-radius:15px; }
.today-nearby-card { padding:12px 13px; border-radius:15px; }
.today-nearby-list { gap:5px; }
.today-nearby-item { padding-top:7px; padding-bottom:7px; }

.today-plan-card { padding:12px 13px; border-radius:15px; }
.today-plan-head { align-items:center; }
.today-plan-head strong { font-size:12px; }
.today-plan-head span { font-size:10px; }
.today-progress { height:4px; margin:7px 0 8px; }
.today-timeline { max-height:145px; overflow:auto; }
.today-timeline-item { min-height:34px; padding-top:5px; padding-bottom:5px; }
.today-open-plan { margin-top:8px; min-height:36px; }

.today-overview .feasibility-card.warning,
.today-overview .feasibility-card.danger { padding:11px 12px; border-radius:14px; }
.today-overview .feasibility-note { display:none; }

@media (max-width:700px) {
  .today-overview-panel { padding-top:0; }
  .today-day-card { gap:8px; }
  .today-day-side { min-width:auto; }
}


/* v1.30.0 – Globaler UI/UX Refresh */
.mobile-nav-icon svg {
  width:25px;
  height:25px;
  display:block;
  fill:none;
  stroke:currentColor;
  stroke-width:1.8;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.mobile-header-meta { display:flex; align-items:center; gap:7px; margin-top:6px; }

@media (max-width:700px) {
  .sidebar-header {
    min-height:auto;
    padding-top:12px;
    padding-bottom:12px;
    align-items:flex-start;
  }
  .sidebar-header .eyebrow { font-size:10px; letter-spacing:.07em; }
  .sidebar-header h1 { margin:3px 0 0; font-size:25px; line-height:1.05; }
  .sidebar-header .app-version,
  .sidebar-header .app-connectivity {
    margin:0;
    min-height:25px;
    padding:3px 8px;
    font-size:10px;
    line-height:17px;
  }
  .sidebar-header .account-actions { margin-left:auto; }
  .sidebar-header #logoutButton { padding:5px 7px; font-size:11px; }
  .sidebar-header #mobileClose {
    width:34px;
    height:34px;
    margin-left:2px;
    font-size:21px;
  }

  .mobile-bottom-nav {
    padding-top:5px;
    padding-bottom:max(5px,env(safe-area-inset-bottom));
    min-height:67px;
    border-top:1px solid rgba(31,48,45,.08);
    box-shadow:0 -4px 18px rgba(31,48,45,.06);
  }
  .mobile-nav-button {
    gap:3px;
    min-height:55px;
    padding:5px 8px;
    border-radius:16px;
    color:#69716f;
    font-size:10.5px;
    font-weight:700;
  }
  .mobile-nav-button.active {
    background:#e8f2ef;
    color:#2f625d;
  }
  .mobile-nav-button.active .mobile-nav-icon { transform:translateY(-1px); }
  .mobile-nav-icon {
    display:grid;
    place-items:center;
    width:27px;
    height:27px;
    font-size:0;
  }
}


/* v1.31.0 – UI/UX Refresh: Orte */
.search-wrap { position:relative; }
.search-wrap .places-search-icon {
  position:absolute; left:13px; top:50%; transform:translateY(-50%);
  z-index:1; color:#65706d; font-size:22px; line-height:1; pointer-events:none;
}
.search-wrap input { padding-left:40px; min-height:45px; border-radius:14px; }
.places-section-subtitle { margin-top:2px; color:var(--muted); font-size:10px; }
.places-title-actions { align-self:center; }

.place-list { gap:8px; }
.place-card {
  display:grid; grid-template-columns:38px minmax(0,1fr); gap:10px;
  padding:11px 12px; border-radius:14px; background:#fff;
}
.place-card-leading {
  display:grid; place-items:center; width:36px; height:36px;
  border-radius:11px; background:var(--accent-soft); font-size:18px;
}
.place-card-content { min-width:0; }
.place-card-title { align-items:center; gap:6px; }
.place-card-name { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:13px; font-weight:800; }
.place-card-chevron { color:#89918f; font-size:20px; line-height:1; }
.place-card-meta { display:flex; gap:8px; flex-wrap:wrap; margin-top:2px; font-size:10.5px; }
.place-card-status { display:flex; flex-wrap:wrap; gap:5px; margin-top:7px; }
.place-status-chip {
  display:inline-flex; align-items:center; min-height:22px; padding:3px 7px;
  border-radius:999px; background:#f1f3f2; color:#626b68; font-size:9.5px; font-weight:750;
}
.place-status-chip.planned { background:#e8f2ef; color:#315f58; }
.place-status-chip.visited { background:#e8f4ea; color:#397047; }
.place-status-chip.tip { background:#fff5d9; color:#85630a; }
.place-status-chip.own { background:#eef1f6; color:#596273; }
.place-card-note {
  display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical;
  overflow:hidden; margin-top:7px; color:#606966; font-size:10.5px;
}
@media (max-width:700px) {
  [data-mobile-view="places"].search-wrap { margin-top:2px; margin-bottom:2px; }
  .desktop-places-panel[data-mobile-view="places"] { padding-top:14px; margin-top:12px; }
  .desktop-places-panel .panel-title-row { margin-bottom:9px; }
  .place-card { grid-template-columns:36px minmax(0,1fr); padding:10px 11px; }
}


/* v1.32.0 – UI/UX Refresh: Karte */
.map-toolbar {
  display:flex; align-items:center; gap:7px;
  padding:5px; border:1px solid rgba(255,255,255,.65);
  border-radius:16px; background:rgba(255,255,255,.82);
  box-shadow:0 8px 24px rgba(31,48,45,.13);
  backdrop-filter:blur(14px);
}
.map-toolbar .floating-button {
  display:inline-flex; align-items:center; justify-content:center; gap:6px;
  min-height:39px; margin:0; padding:7px 10px;
  border:0; border-radius:11px; box-shadow:none; background:transparent;
  font-size:12px; font-weight:750;
}
.map-toolbar .primary-floating { background:#2f625d; color:#fff; }
.map-toolbar-flag { font-size:15px; }
.map-toolbar-plus { font-size:18px; line-height:1; }
.map-fit-button { color:#5f6966; }

.map-round-action svg {
  width:23px; height:23px; fill:none; stroke:currentColor;
  stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round;
}

@media (max-width:820px) {
  .map-toolbar {
    top:14px; left:50%; right:auto; transform:translateX(-50%);
    max-width:calc(100vw - 24px); gap:3px; padding:4px;
    border-radius:15px;
  }
  .map-toolbar .floating-button { min-height:38px; padding:7px 10px; font-size:11.5px; white-space:nowrap; }
  .map-toolbar .map-add-button { padding-left:11px; padding-right:11px; }
  .map-toolbar .map-fit-button { width:38px; padding-left:0; padding-right:0; }
  .map-fit-label { display:none; }

  .mobile-locate-fab.map-round-action {
    display:grid; place-items:center; width:50px; height:50px;
    padding:0; border:1px solid rgba(47,98,93,.12);
    border-radius:50%; background:rgba(255,255,255,.96);
    color:#2f625d; box-shadow:0 7px 20px rgba(31,48,45,.16);
    font-size:0;
  }
}


/* v1.32.1 – Standort-FAB kollisionsfrei */
@media (max-width:820px) {
  .mobile-locate-fab.map-round-action {
    right:78px;
    bottom:18px;
  }
}


/* v1.32.2 – Standort-FAB oberhalb der Kartensteuerung */
@media (max-width:820px) {
  .mobile-locate-fab.map-round-action {
    right:14px;
    bottom:84px;
  }
}


/* v1.33.0 – Cleanup & Polish */
.trip-status-legend {
  display:flex; flex-wrap:wrap; gap:5px 9px; align-items:center;
  margin:3px 0 4px; color:#77807d; font-size:9px;
}
.trip-status-legend > span:first-child { font-weight:800; color:#606966; }
@media (max-width:700px) {
  .desktop-plan-section .plan-header-actions:empty { display:none; }
  .trip-status-legend { gap:4px 7px; }
}


/* v1.33.2 – Orte-Kopfzeile stabil halten */
.desktop-places-panel .panel-title-row {
  display:grid;
  grid-template-columns:minmax(0, 1fr) auto;
  align-items:center;
  gap:10px;
}
.desktop-places-panel .places-title-actions {
  display:flex;
  flex-wrap:nowrap;
  align-items:center;
  justify-content:flex-end;
  gap:7px;
  margin-left:auto;
}
.desktop-places-panel .mobile-distance-sort,
.desktop-places-panel .count-badge {
  flex:0 0 auto;
  white-space:nowrap;
}
@media (max-width:700px) {
  .desktop-places-panel .panel-title-row {
    grid-template-columns:minmax(0, 1fr) auto;
  }
  .desktop-places-panel .places-title-actions {
    display:flex !important;
    width:auto;
    margin-top:0;
  }
}
