File size: 31,320 Bytes
cd99321
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
@tailwind base;
@tailwind components;
@tailwind utilities;

html { height: 100%; overflow: hidden; background-color: var(--bg-primary); }
body { height: 100%; overflow: auto; overscroll-behavior: none; -webkit-overflow-scrolling: touch; }


/* Journey desktop feed: hide scrollbar (right column is a sticky map, a
   visible scrollbar on the left breaks the polarsteps-style reading feel). */
.journey-feed-scroll { scrollbar-width: none; -ms-overflow-style: none; }
.journey-feed-scroll::-webkit-scrollbar { display: none; }

/* Leaflet Popups β€” Enter-Animation vom Anchor-Tip */
.leaflet-popup {
  animation: trek-popover-enter 220ms cubic-bezier(0.23, 1, 0.32, 1);
  transform-origin: bottom center;
  will-change: transform, opacity;
}
.leaflet-popup-content-wrapper {
  border-radius: 14px !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18) !important;
  background: var(--bg-card) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--border-faint);
}
.leaflet-popup-tip {
  background: var(--bg-card) !important;
}
.leaflet-popup-close-button {
  transition: color 150ms cubic-bezier(0.23, 1, 0.32, 1), transform 150ms cubic-bezier(0.23, 1, 0.32, 1) !important;
}
.leaflet-popup-close-button:hover {
  transform: scale(1.15);
  color: var(--text-primary) !important;
}

/* Mapbox GL hover popup β€” the name/category/address card on marker hover.
   Matches the Leaflet map's white hover tooltip. pointer-events:none so moving
   onto the popup never steals the marker's mouseleave and causes flicker. */
.trek-map-popup { pointer-events: none; }
.trek-map-popup .mapboxgl-popup-content {
  padding: 7px 10px;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.16);
}
.trek-map-popup .mapboxgl-popup-tip {
  border-top-color: #fff;
  border-bottom-color: #fff;
  border-left-color: #fff;
  border-right-color: #fff;
}

.atlas-tooltip {
  background: rgba(10, 10, 20, 0.6) !important;
  backdrop-filter: blur(20px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
  color: #f1f5f9 !important;
  border: 1px solid rgba(255,255,255,0.1) !important;
  border-radius: 14px !important;
  padding: 10px 14px !important;
  font-size: 12px !important;
  font-family: inherit !important;
  box-shadow: 0 8px 32px rgba(0,0,0,0.25) !important;
  transition: none !important;
}
.atlas-tooltip::before { border-top-color: rgba(10, 10, 20, 0.6) !important; }
html:not(.dark) .atlas-tooltip {
  background: rgba(255, 255, 255, 0.75) !important;
  color: #0f172a !important;
  border: 1px solid rgba(0,0,0,0.08) !important;
  box-shadow: 0 8px 32px rgba(0,0,0,0.1) !important;
}
html:not(.dark) .atlas-tooltip::before { border-top-color: rgba(255, 255, 255, 0.75) !important; }
.leaflet-tooltip.atlas-tooltip { opacity: 1 !important; }
.leaflet-tooltip-pane { transition: none !important; }
.leaflet-fade-anim .leaflet-tooltip { transition: none !important; opacity: 1 !important; }

.dark .leaflet-control-zoom a {
  background: rgba(10, 10, 20, 0.7) !important;
  color: #e2e8f0 !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
  backdrop-filter: blur(12px);
}
.dark .leaflet-control-zoom a:hover {
  background: rgba(30, 30, 40, 0.8) !important;
}
@media (max-width: 767px) {
  .leaflet-control-zoom { display: none !important; }
}

/* Dark mode overrides for pages using hardcoded slate-* Tailwind classes */
html.dark .bg-slate-50 { background-color: var(--bg-secondary) !important; }
html.dark .bg-white { background-color: var(--bg-card) !important; }
html.dark .bg-slate-100 { background-color: var(--bg-secondary) !important; }
html.dark .bg-slate-900.text-white { background-color: #e2e8f0 !important; color: #0f172a !important; }
html.dark .border-slate-200, html.dark .border-slate-300 { border-color: var(--border-primary) !important; }
html.dark .border-slate-100, html.dark .border-b-slate-100 { border-color: var(--border-secondary) !important; }
html.dark .text-slate-900 { color: var(--text-primary) !important; }
html.dark .text-slate-700 { color: var(--text-secondary) !important; }
html.dark .text-slate-600 { color: var(--text-muted) !important; }
html.dark .text-slate-500 { color: var(--text-muted) !important; }
html.dark .text-slate-400 { color: var(--text-faint) !important; }
html.dark .hover\:bg-slate-50:hover, html.dark .hover\:bg-slate-100:hover { background-color: var(--bg-hover) !important; }
html.dark .hover\:text-slate-900:hover { color: var(--text-primary) !important; }
html.dark .hover\:bg-slate-700:hover { background-color: var(--bg-hover) !important; }
html.dark .divide-slate-100 > :not([hidden]) ~ :not([hidden]) { border-color: var(--border-secondary) !important; }
html.dark .focus\:ring-slate-400:focus { --tw-ring-color: var(--text-faint) !important; }
html.dark input[class*="border-slate"], html.dark input[class*="text-slate"] { background: var(--bg-secondary) !important; color: var(--text-primary) !important; border-color: var(--border-primary) !important; }
html.dark .text-amber-900 { color: #fbbf24 !important; }
html.dark .text-amber-700 { color: #f59e0b !important; }
html.dark .bg-amber-50 { background-color: rgba(245,158,11,0.1) !important; }
html.dark .border-amber-200 { border-color: rgba(245,158,11,0.2) !important; }
html.dark .disabled\:bg-slate-400:disabled { background-color: var(--text-faint) !important; }
html.dark button.bg-slate-900 { background-color: #e2e8f0 !important; color: #0f172a !important; opacity: 1 !important; }
html.dark button.bg-slate-900:hover { background-color: #cbd5e1 !important; }
html.dark button.bg-slate-900:disabled { background-color: #ffffff !important; color: #000000 !important; opacity: 0.4 !important; }
html.dark span.bg-slate-900 { background-color: #e2e8f0 !important; color: #0f172a !important; }
html.dark span.bg-slate-100 { background-color: var(--bg-secondary) !important; color: var(--text-muted) !important; }
html.dark .border-b { border-bottom-color: var(--border-secondary) !important; }
/* Gray variants (CategoryManager, BackupPanel) */
html.dark .bg-gray-50 { background-color: var(--bg-secondary) !important; }
html.dark .bg-gray-100 { background-color: var(--bg-secondary) !important; }
html.dark .border-gray-200, html.dark .border-gray-300 { border-color: var(--border-primary) !important; }
html.dark .border-gray-100 { border-color: var(--border-secondary) !important; }
html.dark .text-gray-900 { color: var(--text-primary) !important; }
html.dark .text-gray-700 { color: var(--text-secondary) !important; }
html.dark .text-gray-600 { color: var(--text-muted) !important; }
html.dark .text-gray-500 { color: var(--text-muted) !important; }
html.dark .text-gray-400 { color: var(--text-faint) !important; }
html.dark .text-gray-300 { color: var(--text-faint) !important; }
html.dark .hover\:bg-gray-50:hover, html.dark .hover\:bg-gray-200:hover { background-color: var(--bg-hover) !important; }
html.dark .hover\:border-gray-200:hover, html.dark .hover\:border-gray-400:hover { border-color: var(--border-primary) !important; }
html.dark input.bg-white, html.dark input[class*="bg-white"] { background: var(--bg-secondary) !important; color: var(--text-primary) !important; }
html.dark .bg-gray-200 { background-color: var(--border-primary) !important; }
html.dark .border-gray-300.border-t-slate-600 { border-color: var(--border-primary) !important; border-top-color: var(--text-primary) !important; }
/* Modal buttons */
html.dark button[class*="text-slate-600"][class*="border-slate-200"] { color: var(--text-muted) !important; border-color: var(--border-primary) !important; }
html.dark button[class*="text-slate-600"][class*="border-slate-200"]:hover { background: var(--bg-hover) !important; }
/* Dashed borders */
html.dark .border-dashed.border-gray-300 { border-color: var(--border-primary) !important; }
html.dark .bg-slate-50\/60, html.dark [class*="bg-slate-50/"] { background-color: transparent !important; }

/* Reorder buttons: desktop = original style; mobile = always visible, larger touch targets */
.reorder-buttons {
  flex-direction: column;
  opacity: 0;
}
.reorder-buttons button {
  background: none !important;
  padding: 1px 2px;
}
@media (max-width: 767px) {
  .reorder-buttons {
    flex-direction: row !important;
    opacity: 1 !important;
    align-items: center;
    margin-left: auto;
  }
  .reorder-buttons button {
    background: var(--bg-tertiary) !important;
    border-radius: 6px;
    width: 32px;
    height: 32px;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }
  .note-edit-buttons {
    opacity: 1 !important;
  }
}

/* Ort-Zeile Hover: Sortier-Buttons anzeigen */
.place-row:hover .reorder-btns {
  opacity: 1 !important;
}

/* Ladeanimation */
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ── Press-Feedback + bessere Easings (Emil Kowalski) ─────────── */
/* Buttons sollen antworten wenn sie gedrΓΌckt werden. */
button:not(:disabled):not([data-no-press]),
[role="button"]:not([aria-disabled="true"]):not([data-no-press]) {
  transition-property: transform, color, background-color, border-color, box-shadow, opacity, filter !important;
  transition-duration: 180ms;
  transition-timing-function: cubic-bezier(0.23, 1, 0.32, 1);
}
button:not(:disabled):not([data-no-press]):active,
[role="button"]:not([aria-disabled="true"]):not([data-no-press]):active {
  transform: scale(0.97);
  transition-duration: 80ms;
}

/* Tailwind-Default-Easing durch ease-out-quint ersetzen.
   Eingebaute CSS-Easings sind kraftlos; ease-out-quint hat Punch. */
.transition,
.transition-all,
.transition-colors,
.transition-opacity,
.transition-transform,
.transition-shadow {
  transition-timing-function: cubic-bezier(0.23, 1, 0.32, 1);
}

/* Input-Focus transitions β€” border + ring faden weich ein */
input, textarea, select {
  transition: border-color 150ms cubic-bezier(0.23, 1, 0.32, 1),
              box-shadow 150ms cubic-bezier(0.23, 1, 0.32, 1),
              background-color 150ms cubic-bezier(0.23, 1, 0.32, 1);
}

/* Back-Button Icon-Slide on hover */
.trek-back-btn .trek-back-icon {
  transition: transform 200ms cubic-bezier(0.23, 1, 0.32, 1);
}
.trek-back-btn:hover .trek-back-icon {
  transform: translateX(-2px);
}

/* Global focus-visible ring β€” konsistent ΓΌberall */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}
button:focus-visible, [role="button"]:focus-visible, a:focus-visible {
  outline-offset: 3px;
}
input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: none;
}

/* Theme crossfade β€” beim Dark/Light switch, HauptflΓ€chen + Text faden ihre Farben.
   Sparingly: nur background-color und color bekommen eine Transition. */
html.trek-theme-transitioning,
html.trek-theme-transitioning body,
html.trek-theme-transitioning *:not(img):not(video):not(canvas):not([class*="trek-skeleton"]):not(.leaflet-layer) {
  transition:
    background-color 320ms cubic-bezier(0.23, 1, 0.32, 1),
    color 320ms cubic-bezier(0.23, 1, 0.32, 1),
    border-color 320ms cubic-bezier(0.23, 1, 0.32, 1),
    fill 320ms cubic-bezier(0.23, 1, 0.32, 1) !important;
}

/* Touch-GerΓ€te: iOS-Tap-Highlight weg (wir haben eigenes Press-Feedback) */
@media (hover: none) {
  button, [role="button"], a {
    -webkit-tap-highlight-color: transparent;
  }
}
html, body {
  -webkit-tap-highlight-color: transparent;
}

/* Tabular-nums global fΓΌr Time/Date/Currency/Counter */
time, .tabular-nums, [data-tabular],
input[type="number"], input[type="time"], input[type="date"], input[type="datetime-local"] {
  font-variant-numeric: tabular-nums;
}
/* Wenn Element explizit ease-in-out nutzt (z.B. Accordions), nicht ΓΌberschreiben.
   Tailwind setzt ease-in-out via eigener Klasse β€” die gewinnt durch letzte Deklaration. */

/* Press-Scale fΓΌr clickbare Divs (Cards, Tiles) β€” sanfter als Buttons */
[data-press]:active {
  transform: scale(0.985);
  transition-duration: 80ms;
}

/* ── Popover/Dropdown Enter-Animationen ─────────────────────────
   Emil: Popovers sollen von ihrem Trigger aus scalen, nicht vom Center.
   Start bei scale(0.95) β€” nichts in der echten Welt poppt aus dem Nichts. */
@keyframes trek-menu-enter {
  from { opacity: 0; transform: scale(0.95) translateY(-4px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes trek-popover-enter {
  from { opacity: 0; transform: scale(0.96); }
  to   { opacity: 1; transform: scale(1); }
}
@keyframes trek-modal-enter {
  from { opacity: 0; transform: scale(0.97); }
  to   { opacity: 1; transform: scale(1); }
}
@keyframes trek-backdrop-enter {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes trek-toast-enter {
  from { opacity: 0; transform: translateY(8px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes trek-progress-fill {
  from { width: 0%; }
  to   { width: var(--trek-progress-to, 0%); }
}

/* Pie-Chart Reveal β€” rotate + fade-in, gibt dem Kreisdiagramm ein "Draw"-GefΓΌhl */
@keyframes trek-pie-reveal {
  from { opacity: 0; transform: rotate(-90deg) scale(0.85); }
  to   { opacity: 1; transform: rotate(0deg) scale(1); }
}
.trek-pie-reveal {
  animation: trek-pie-reveal 900ms cubic-bezier(0.23, 1, 0.32, 1) both;
  transform-origin: center;
  will-change: transform, opacity;
}

/* Bar-Chart Reveal β€” horizontaler Fill von links */
@keyframes trek-bar-fill {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}
.trek-bar-fill {
  animation: trek-bar-fill 700ms cubic-bezier(0.23, 1, 0.32, 1) both;
  transform-origin: left center;
  will-change: transform;
}

/* Page-Transition β€” subtiler Fade-Up beim Mount */
@keyframes trek-page-enter {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.trek-page-enter {
  animation: trek-page-enter 220ms cubic-bezier(0.23, 1, 0.32, 1) both;
}

/* Skeleton shimmer β€” ein fließender Gradient-Strip ΓΌberquert den Platzhalter */
@keyframes trek-shimmer {
  from { background-position: -200% 0; }
  to   { background-position: 200% 0; }
}
.trek-skeleton {
  background: linear-gradient(
    90deg,
    var(--bg-tertiary) 0%,
    var(--bg-hover) 50%,
    var(--bg-tertiary) 100%
  );
  background-size: 200% 100%;
  animation: trek-shimmer 1.6s linear infinite;
  border-radius: 8px;
  color: transparent;
  user-select: none;
}
.dark .trek-skeleton {
  background: linear-gradient(
    90deg,
    rgba(255,255,255,0.04) 0%,
    rgba(255,255,255,0.08) 50%,
    rgba(255,255,255,0.04) 100%
  );
  background-size: 200% 100%;
}
.trek-menu-enter {
  animation: trek-menu-enter 200ms cubic-bezier(0.23, 1, 0.32, 1);
  transform-origin: top right;
  will-change: transform, opacity;
}
.trek-menu-enter-left {
  animation: trek-menu-enter 200ms cubic-bezier(0.23, 1, 0.32, 1);
  transform-origin: top left;
  will-change: transform, opacity;
}
.trek-popover-enter {
  animation: trek-popover-enter 180ms cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform, opacity;
}
.trek-modal-enter {
  animation: trek-modal-enter 220ms cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform, opacity;
}

/* Mobile-Drawer-Feel β€” Modal slidet von unten rein, wird unten am Screen angedockt */
@keyframes trek-drawer-enter {
  from { opacity: 0; transform: translateY(100%); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (max-width: 639px) {
  .trek-modal-enter {
    animation: trek-drawer-enter 320ms cubic-bezier(0.32, 0.72, 0, 1);
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    margin-top: auto !important;
    align-self: flex-end;
  }
}
.trek-backdrop-enter {
  animation: trek-backdrop-enter 180ms cubic-bezier(0.23, 1, 0.32, 1);
}
.trek-toast-enter {
  animation: trek-toast-enter 260ms cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform, opacity;
}

/* Stagger-Helpers fΓΌr Listen β€” Enter-Animation mit Offset */
@keyframes trek-fade-up {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.trek-stagger > * {
  animation: trek-fade-up 280ms cubic-bezier(0.23, 1, 0.32, 1) both;
}
.trek-stagger > *:nth-child(1) { animation-delay: 0ms; }
.trek-stagger > *:nth-child(2) { animation-delay: 40ms; }
.trek-stagger > *:nth-child(3) { animation-delay: 80ms; }
.trek-stagger > *:nth-child(4) { animation-delay: 120ms; }
.trek-stagger > *:nth-child(5) { animation-delay: 160ms; }
.trek-stagger > *:nth-child(6) { animation-delay: 200ms; }
.trek-stagger > *:nth-child(7) { animation-delay: 240ms; }
.trek-stagger > *:nth-child(8) { animation-delay: 280ms; }
.trek-stagger > *:nth-child(n+9) { animation-delay: 320ms; }

/* Reduced motion β€” Emil's Accessibility-Regel: fewer and gentler, not zero */
@media (prefers-reduced-motion: reduce) {
  .trek-menu-enter, .trek-menu-enter-left, .trek-popover-enter,
  .trek-modal-enter, .trek-toast-enter, .trek-stagger > * {
    animation: trek-backdrop-enter 120ms ease-out;
  }
  .trek-skeleton {
    animation: none;
    background: var(--bg-tertiary);
  }
  button:not(:disabled):not([data-no-press]):active,
  [role="button"]:not([aria-disabled="true"]):not([data-no-press]):active,
  [data-press]:active {
    transform: none;
  }
  /* Parallax & lift disablen */
  .group:hover img,
  .group:hover .cover-img { transform: none !important; }
  *:hover { translate: none !important; }
}

/* ── Design tokens ─────────────────────────────── */
:root {
  /* Easing curves β€” stΓ€rker als die CSS-Defaults, siehe easing.dev */
  --ease-out-quint: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out-quint: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);

  --safe-top: env(safe-area-inset-top, 0px);
  --nav-h: 0px;
  --bottom-nav-h: 0px;
  --font-system: 'Poppins', -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', system-ui, sans-serif;
  /* Secondary "subtext"/caption tier renders in Geist; primary text + headings stay Poppins. */
  --font-subtext: 'Geist Sans', 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-6: 24px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --shadow-card: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-elevated: 0 4px 16px rgba(0,0,0,0.1);

  /* Theme colors */
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #f1f5f9;
  --bg-elevated: rgba(250,250,250,0.82);
  --bg-card: #ffffff;
  --bg-input: #ffffff;
  --bg-hover: rgba(0,0,0,0.03);
  --bg-selected: #e2e8f0;
  --text-primary: #111827;
  --text-secondary: #374151;
  --text-muted: #6b7280;
  --text-faint: #9ca3af;
  --border-primary: #e5e7eb;
  --border-secondary: #f3f4f6;
  --border-faint: rgba(0,0,0,0.06);
  --accent: #111827;
  --accent-text: #ffffff;
  --sidebar-bg: rgba(250,250,250,0.82);
  --sidebar-shadow: 0 4px 32px rgba(0,0,0,0.10), 0 0 0 1px rgba(0,0,0,0.06);
  --tooltip-bg: rgba(255,255,255,0.96);
  --scrollbar-track: #f1f5f9;
  --scrollbar-thumb: #d1d5db;
  --scrollbar-hover: #9ca3af;

  /* Journey design tokens */
  --journal-bg: #FAFAFA;
  --journal-card: #FFFFFF;
  --journal-border: #E4E4E7;
  --journal-accent: #6366F1;
  --journal-text: #09090B;
  --journal-muted: #71717A;
  --journal-faint: #A1A1AA;
  --mood-amazing: #E8654A;
  --mood-good: #EF9F27;
  --mood-neutral: #94928C;
  --mood-tired: #6B9BD2;
  --mood-rough: #9B8EC4;
}

@media (max-width: 767px) {
  :root { --bottom-nav-h: calc(84px + env(safe-area-inset-bottom, 0px)); }
}

@media (min-width: 768px) {
  :root { --nav-h: calc(64px + env(safe-area-inset-top, 0px)); }
}

.dark {
  --bg-primary: #121215;
  --bg-secondary: #1a1a1e;
  --bg-tertiary: #1c1c21;
  --bg-elevated: rgba(19,19,22,0.82);
  --bg-card: #131316;
  --bg-input: #1c1c21;
  --bg-hover: rgba(255,255,255,0.06);
  --bg-selected: rgba(255,255,255,0.1);
  --text-primary: #f4f4f5;
  --text-secondary: #d4d4d8;
  --text-muted: #a1a1aa;
  --text-faint: #71717a;
  --border-primary: #27272a;
  --border-secondary: #1c1c21;
  --border-faint: rgba(255,255,255,0.07);
  --accent: #e4e4e7;
  --accent-text: #09090b;
  --sidebar-bg: rgba(19,19,22,0.82);
  --sidebar-shadow: 0 4px 32px rgba(0,0,0,0.4), 0 0 0 1px rgba(255,255,255,0.05);
  --tooltip-bg: rgba(19,19,22,0.96);
  --scrollbar-track: #131316;
  --scrollbar-thumb: #3f3f46;
  --scrollbar-hover: #52525b;

  /* Journey design tokens (dark) */
  --journal-bg: #09090B;
  --journal-card: #18181B;
  --journal-border: #27272A;
  --journal-accent: #818CF8;
  --journal-text: #FAFAFA;
  --journal-muted: #A1A1AA;
  --journal-faint: #52525B;
  --mood-amazing: #f28a6e;
  --mood-good: #f5b84d;
  --mood-neutral: #9a9a94;
  --mood-tired: #6db3f0;
  --mood-rough: #a9a3f0;
}

body {
  font-family: var(--font-system);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  transition: background-color 0.2s, color 0.2s;
}

/* Subtext tier in Geist. The faint text token is TREK's caption/secondary tier;
   a direct rule on the element beats the Poppins inherited from wrapper styles,
   giving the design's "Geist text Β· Poppins numbers" hierarchy. */
.text-content-faint { font-family: var(--font-subtext); }

/* ── Marker cluster custom styling ────────────── */
.marker-cluster-wrapper {
  background: transparent !important;
  border: none !important;
}

.marker-cluster-custom {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #111827;
  border: 2.5px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25), 0 0 0 2px rgba(17, 24, 39, 0.15);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.marker-cluster-custom:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 0 3px rgba(17, 24, 39, 0.2);
}

.marker-cluster-custom span {
  font-family:var(--font-system);
  font-size: 12px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1;
}

/* Hide default markercluster styles we don't need */
.marker-cluster-small,
.marker-cluster-medium,
.marker-cluster-large {
  background: transparent !important;
}
.marker-cluster-small div,
.marker-cluster-medium div,
.marker-cluster-large div {
  background: transparent !important;
}

/* ── Leaflet z-index ───────────────────────────── */
.leaflet-container {
  z-index: 0;
}
.leaflet-pane {
  z-index: 0 !important;
}
.leaflet-top, .leaflet-bottom {
  z-index: 1 !important;
}

/* ── iOS-style map tooltip ─────────────────────── */
.leaflet-tooltip.map-tooltip {
  background: var(--tooltip-bg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: none;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  padding: 5px 10px;
  font-family: var(--font-system);
  font-size: 11px;
  font-weight: 500;
  pointer-events: none;
  color: var(--text-primary);
}
.leaflet-tooltip.map-tooltip::before,
.leaflet-tooltip-left.map-tooltip::before,
.leaflet-tooltip-top.map-tooltip::before {
  display: none;
}

/* Scrollbars β€” styled on desktop, hidden on mobile */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-button {
  display: none;
  height: 0;
  width: 0;
}
::-webkit-scrollbar-track {
  background: var(--scrollbar-track);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--scrollbar-hover);
}

@media (max-width: 767px) {
  * { scrollbar-width: none; }
  ::-webkit-scrollbar { width: 0; height: 0; }
}

.route-info-pill { background: none !important; border: none !important; box-shadow: none !important; width: auto !important; height: auto !important; margin: 0 !important; }
.chat-scroll { overflow-y: auto !important; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.chat-scroll::-webkit-scrollbar { width: 0; background: transparent; }


/* Einheitliche Formular-Inputs */
.form-input {
  width: 100%;
  border: 1px solid var(--border-primary);
  border-radius: 10px;
  padding: 8px 14px;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  box-sizing: border-box;
  color: var(--text-primary);
  background: var(--bg-input);
  transition: border-color 0.15s;
}
.form-input:focus {
  border-color: var(--text-faint);
}
.form-input::placeholder {
  color: var(--text-faint);
}

/* Brand images: no save/copy/drag */
img[alt="TREK"] {
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
}

/* Weiche ÜbergÀnge */
.transition-smooth {
  transition: all 0.2s ease;
}



/* Tagesliste */
.day-list-item {
  transition: background-color 0.15s ease;
}

.day-list-item:hover {
  background-color: var(--bg-secondary);
}

.day-list-item.active {
  background-color: #4f46e5;
  color: white;
}

.scroll-container {
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track);
}

/* ── Dark-Mode: Tailwind-Klassen ─────────────── */
.dark .bg-slate-50 { background-color: #131316 !important; }
.dark .bg-slate-100 { background-color: #1c1c21 !important; }
.dark .bg-white { background-color: #09090b !important; }
.dark .bg-gray-50 { background-color: #131316 !important; }
.dark .bg-gray-100 { background-color: #1c1c21 !important; }
.dark .text-slate-900, .dark .text-gray-900, .dark .text-slate-800 { color: #f4f4f5 !important; }
.dark .text-slate-700, .dark .text-gray-700 { color: #d4d4d8 !important; }
.dark .text-slate-600, .dark .text-gray-600 { color: #a1a1aa !important; }
.dark .text-slate-500, .dark .text-gray-500 { color: #a1a1aa !important; }
.dark .text-slate-400, .dark .text-gray-400 { color: #71717a !important; }
.dark .border-slate-200, .dark .border-gray-200, .dark .border-slate-300 { border-color: #27272a !important; }
.dark .border-gray-100, .dark .border-slate-100 { border-color: #1c1c21 !important; }
.dark .hover\:bg-slate-50:hover, .dark .hover\:bg-gray-50:hover { background-color: #1c1c21 !important; }
.dark .bg-slate-50\/60 { background-color: transparent !important; }
.dark .divide-slate-100 > :not([hidden]) ~ :not([hidden]) { border-color: #27272a !important; }
.dark .bg-slate-100 { background-color: #27272a !important; }
.dark .bg-slate-900 { background-color: #e4e4e7 !important; color: #09090b !important; }
.dark .hover\:bg-slate-700:hover { background-color: #d4d4d8 !important; color: #09090b !important; }
.dark input, .dark textarea, .dark select {
  background-color: #1c1c21;
  color: #f4f4f5;
  border-color: #27272a;
}
.dark input::placeholder, .dark textarea::placeholder { color: #71717a; }
.dark .bg-emerald-50 { background-color: rgba(16,185,129,0.15) !important; }
.dark .bg-red-50 { background-color: rgba(239,68,68,0.15) !important; }

/* Ladebildschirm */
.dark .min-h-screen { background-color: var(--bg-primary) !important; }

/* Modal-Hintergrund */
.dark .trek-modal-backdrop { background: rgba(0,0,0,0.6); }

/* ── Dark: Fallback fΓΌr Komponenten die noch nicht auf CSS-Variablen umgestellt sind ── */
.dark {
  color-scheme: dark;
}


/* Toast-Animationen */
@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

@keyframes slide-in-right {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@keyframes slide-out-right {
  from { transform: translateX(0); opacity: 1; }
  to { transform: translateX(100%); opacity: 0; }
}

.toast-enter {
  animation: slide-in-right 0.3s ease-out forwards;
}

.toast-exit {
  animation: slide-out-right 0.3s ease-in forwards;
}

/* Modal-Hintergrund (eigener Namespace, sonst blenden Content-Blocker .modal-backdrop aus) */
.trek-modal-backdrop {
  backdrop-filter: blur(4px);
}

/* Fortschrittsbalken */
@keyframes progress-fill {
  from { width: 0; }
  to { width: var(--progress); }
}

/* Anmeldeseiten-Gradient */
.auth-gradient {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Bildanzeige-Overlay */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.95);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Markdown in Collab Notes */
.collab-note-md strong, .collab-note-md-full strong { font-weight: 700 !important; }
.collab-note-md em, .collab-note-md-full em { font-style: italic !important; }
.collab-note-md h1, .collab-note-md h2, .collab-note-md h3 { font-weight: 700 !important; margin: 0; }
.collab-note-md-full h1 { font-size: 1.3em !important; font-weight: 700 !important; margin: 0.8em 0 0.3em; }
.collab-note-md-full h2 { font-size: 1.15em !important; font-weight: 700 !important; margin: 0.8em 0 0.3em; }
.collab-note-md-full h3 { font-size: 1em !important; font-weight: 700 !important; margin: 0.8em 0 0.3em; }
.collab-note-md p, .collab-note-md-full p { margin: 0 0 0.3em; }
.collab-note-md ul, .collab-note-md-full ul { list-style-type: disc !important; padding-left: 1.4em !important; margin: 0.2em 0; }
.collab-note-md ol, .collab-note-md-full ol { list-style-type: decimal !important; padding-left: 1.4em !important; margin: 0.2em 0; }
.collab-note-md li, .collab-note-md-full li { display: list-item !important; margin: 0.1em 0; }
.collab-note-md code, .collab-note-md-full code { font-size: 0.9em; padding: 1px 5px; border-radius: 4px; background: var(--bg-secondary); }
.collab-note-md-full pre { padding: 10px 12px; border-radius: 8px; background: var(--bg-secondary); overflow-x: auto; margin: 0.5em 0; }
.collab-note-md-full pre code { padding: 0; background: none; }
.collab-note-md a, .collab-note-md-full a { color: #3b82f6; text-decoration: underline; word-break: break-all; }
.collab-note-md blockquote, .collab-note-md-full blockquote { border-left: 3px solid var(--border-primary); padding-left: 12px; margin: 0.5em 0; color: var(--text-muted); }
.collab-note-md-full table { border-collapse: collapse; width: 100%; margin: 0.5em 0; }
.collab-note-md-full th, .collab-note-md-full td { border: 1px solid var(--border-primary); padding: 4px 8px; font-size: 0.9em; }
.collab-note-md-full hr { border: none; border-top: 1px solid var(--border-primary); margin: 0.8em 0; }

/* Day-plan header action grid (edit / +transport / note / collapse) */
.dp-day-actions button {
  color: var(--text-faint);
  background: transparent;
  transition: background-color 0.12s ease, color 0.12s ease;
}
.dp-day-actions button:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}
/* Reveal the action grid only when hovering the day row (pointer devices).
   Touch devices (hover: none) keep it visible; the selected day stays visible too. */
@media (hover: hover) {
  .dp-day-actions { opacity: 0; transition: opacity 0.12s ease; }
  .dp-day-header:hover .dp-day-actions,
  .dp-day-header[data-selected="true"] .dp-day-actions { opacity: 1; }
}