        *, *::before, *::after { box-sizing: border-box; }
        body { font-family: 'Inter', sans-serif; background: #faf7f4; color: #252120; margin: 0; padding: 0; -webkit-font-smoothing: antialiased; }
        .tab-content { display: none; }
        .tab-content.active { display: block; }
        .day-card-body { max-height: 0; overflow: hidden; transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease; opacity: 0; }
        .day-card-body.open { max-height: 8000px; opacity: 1; }
        .chevron-icon { transition: transform 0.3s ease; }
        .chevron-icon.rotated { transform: rotate(180deg); }
        @keyframes pulse-alert { 0%, 100% { opacity: 1; } 50% { opacity: 0.85; } }
        .alert-pulse { animation: pulse-alert 2s ease-in-out infinite; }
        @keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }
        .today-highlight { background: linear-gradient(90deg, rgba(255, 215, 0, 0.15) 0%, rgba(255, 215, 0, 0.3) 50%, rgba(255, 215, 0, 0.15) 100%); background-size: 200% 100%; animation: shimmer 3s ease-in-out infinite; border-left: 4px solid #FFD700; }
        .bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; z-index: 50; }
        /* With destinations added, the tab count is dynamic and can exceed
           what fits at flex-1 on a phone (labels overlap once ~9 tabs are
           on screen) — scroll horizontally instead of squeezing. */
        .bottom-nav-row { overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
        .bottom-nav .nav-btn { flex: 0 0 auto !important; width: 66px; }
        .nav-btn.active { color: #C8102E; }
        .nav-btn.active .nav-indicator { width: 100%; }
        .nav-indicator { width: 0; height: 3px; transition: width 0.3s ease; border-radius: 2px; }
        .pass-dot { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; }
        .copy-toast { position: fixed; bottom: 90px; left: 50%; transform: translateX(-50%); background: #252120; color: #fefcfa; padding: 10px 20px; border-radius: 12px; font-size: 14px; z-index: 100; opacity: 0; transition: opacity 0.3s; pointer-events: none; }
        .copy-toast.show { opacity: 1; }
        .badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 9999px; font-size: 11px; font-weight: 600; letter-spacing: 0.02em; white-space: nowrap; }
        .timeline-item { position: relative; padding-left: 28px; padding-bottom: 14px; }
        .timeline-item::before { content: ''; position: absolute; left: 7px; top: 22px; bottom: 0; width: 2px; background: #eae5e0; }
        .timeline-item:last-child::before { display: none; }
        .timeline-dot { position: absolute; left: 0; top: 6px; width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid; background: #fefcfa; }
        .london-dot { border-color: #C8102E; }
        .paris-dot { border-color: #002395; }
        .travel-dot { border-color: #6b6460; }
        main { padding-bottom: 85px; }
        .sticky-header { position: sticky; top: 0; z-index: 40; }
        body::-webkit-scrollbar { width: 6px; }
        body::-webkit-scrollbar-thumb { background: #d8d2cc; border-radius: 3px; }

        .upload-zone { border: 2px dashed #d8d2cc; border-radius: 16px; background: #f4f0ec; transition: border-color 0.2s, background 0.2s; cursor: pointer; }
        .upload-zone:hover, .upload-zone.dragover { border-color: #002395; background: #e8ecf5; }
        .ticket-item { animation: fadeInItem 0.3s ease forwards; }
        @keyframes fadeInItem { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
        .cat-badge-flights { background: #fee2e2; color: #991b1b; }
        .cat-badge-hotels { background: #dbeafe; color: #1e40af; }
        .cat-badge-transport { background: #fef3c7; color: #92400e; }
        .cat-badge-activities { background: #ede9fe; color: #5b21b6; }
        .cat-badge-other { background: #f3f4f6; color: #374151; }
        .file-thumb { width: 48px; height: 48px; border-radius: 10px; object-fit: cover; flex-shrink: 0; background: #eae5e0; }

        .note-saved { color: #16a34a; font-size: 11px; opacity: 1; transition: opacity 0.6s ease; }
        .note-saved.fade { opacity: 0; }

        .od-section { margin-top: 10px; border-top: 1px solid #eae5e0; padding-top: 10px; }
        .od-section-title { font-size: 11px; font-weight: 600; color: #8a8380; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 6px; display: flex; align-items: center; gap: 5px; }
        .od-note-area { width: 100%; min-height: 56px; border: 1px solid #eae5e0; border-radius: 10px; padding: 8px 12px; font-size: 12px; color: #3a3532; background: #fefcfa; resize: vertical; font-family: inherit; box-sizing: border-box; outline: none; }
        .od-note-area:focus { border-color: #002395; box-shadow: 0 0 0 2px rgba(0,35,149,0.1); }
        .od-note-area::placeholder { color: #d8d2cc; }
        .od-save-status { font-size: 10px; color: #16a34a; margin-top: 3px; min-height: 14px; transition: opacity 0.5s; }
        .od-file-item { display: flex; align-items: center; gap: 8px; padding: 6px 10px; background: #f4f0ec; border-radius: 10px; margin-bottom: 5px; }
        .od-file-icon { font-size: 16px; flex-shrink: 0; }
        .od-file-name { font-size: 11px; font-weight: 600; color: #3a3532; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100px; }
        .od-file-desc { flex: 1; border: none; background: transparent; font-size: 11px; color: #6b6460; outline: none; min-width: 0; }
        .od-file-desc::placeholder { color: #d8d2cc; }
        .od-file-link { font-size: 10px; color: #002395; text-decoration: none; white-space: nowrap; }
        .od-file-del { background: none; border: none; cursor: pointer; font-size: 14px; color: #8a8380; padding: 0 2px; flex-shrink: 0; }
        .od-upload-btn { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: #002395; background: #e8ecf5; border: 1px dashed #002395; border-radius: 8px; padding: 5px 10px; cursor: pointer; margin-top: 4px; }
        .od-upload-btn:hover { background: #d0d8eb; }
        .od-link-item { display: flex; align-items: center; gap: 6px; padding: 5px 8px; background: #f4f0ec; border-radius: 8px; margin-bottom: 4px; }
        .od-link-text { flex: 1; font-size: 11px; color: #002395; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
        .od-link-del { background: none; border: none; cursor: pointer; font-size: 12px; color: #8a8380; padding: 0; }
        .od-add-link-row { display: flex; gap: 4px; margin-top: 4px; }
        .od-add-link-input { flex: 1; border: 1px solid #eae5e0; border-radius: 8px; padding: 5px 8px; font-size: 11px; outline: none; }
        .od-add-link-btn { background: #012169; color: white; border: none; border-radius: 8px; padding: 5px 10px; font-size: 11px; cursor: pointer; white-space: nowrap; }
        .od-uploading { font-size: 10px; color: #002395; margin-top: 3px; }

        .fp-tab { background: #f4f0ec; color: #6b6460; }
        .fp-tab.selected { background: #012169; color: white; }
        .fp-crumb { cursor: pointer; color: #002395; }
        .fp-crumb:not(:last-child)::after { content: ' / '; color: #8a8380; }
        .fp-crumb:last-child { color: #3a3532; font-weight: 600; cursor: default; }
        .fp-item { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 8px; cursor: pointer; font-size: 13px; color: #3a3532; }
        .fp-item:hover { background: #f4f0ec; }
        .fp-item.selected { background: #e8ecf5; }
        .fp-empty { font-size: 12px; color: #8a8380; text-align: center; padding: 24px 8px; }

        .reorder-tab-row { display: flex; align-items: center; gap: 8px; padding: 8px 10px; background: #f4f0ec; border-radius: 10px; touch-action: none; }
        .reorder-tab-row.dragging { opacity: 0.6; box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
        .reorder-drag-handle { cursor: grab; color: #8a8380; font-size: 16px; touch-action: none; user-select: none; }
        .reorder-arrow-btn { background: none; border: none; cursor: pointer; padding: 4px; color: #524c48; }
        .reorder-arrow-btn:disabled { opacity: 0.3; cursor: default; }

        .tl-row { display: flex; align-items: flex-start; gap: 10px; padding: 9px 0; border-bottom: 1px solid #f4f0ec; cursor: pointer; border-radius: 8px; transition: background 0.15s; }
        .tl-row:last-child { border-bottom: none; }
        .tl-row:hover { background: #f4f0ec; margin: 0 -6px; padding-left: 6px; padding-right: 6px; }
        .tl-time { font-size: 11px; font-weight: 700; color: #8a8380; width: 38px; flex-shrink: 0; padding-top: 2px; letter-spacing: 0.03em; }
        .tl-desc { flex: 1; font-size: 13px; color: #3a3532; line-height: 1.45; }
        .tl-desc.highlight { font-weight: 600; color: #252120; }
        .tl-icons { display: flex; gap: 3px; flex-shrink: 0; padding-top: 2px; }
        .tl-icon { font-size: 10px; opacity: 0.55; }
        .tl-icon.active { opacity: 1; }

        .ap-file-row { display:flex;align-items:center;gap:8px;padding:6px 10px;background:#f4f0ec;border-radius:10px;margin-bottom:5px; }
        .ap-file-name { font-size:11px;font-weight:600;color:#3a3532;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:90px; }
        .ap-file-desc-inp { flex:1;border:none;background:transparent;font-size:11px;color:#6b6460;outline:none;min-width:0; }
        .ap-file-link { font-size:10px;color:#002395;text-decoration:none;white-space:nowrap; }
        .ap-file-del { background:none;border:none;cursor:pointer;font-size:13px;color:#8a8380;padding:0 2px; }
        .ap-link-row { display:flex;align-items:center;gap:6px;padding:5px 8px;background:#f4f0ec;border-radius:8px;margin-bottom:4px; }
        .ap-link-anchor { flex:1;font-size:12px;color:#002395;text-decoration:none;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
        .ap-link-del { background:none;border:none;cursor:pointer;font-size:12px;color:#8a8380;padding:0; }
        #activity-panel { transition: transform 0.32s cubic-bezier(0.4,0,0.2,1); }

        /* FIX 2: Clocks row at bottom of banner */
        .banner-clocks-row { display: flex; justify-content: center; gap: 8px; padding: 6px 0 4px; }
        .clock-pill { display: flex; align-items: center; gap: 6px; background: rgba(0,0,0,0.3); border-radius: 8px; padding: 4px 10px; }
        .clock-pill .cp-city { font-size: 10px; font-weight: 600; color: rgba(255,255,255,0.8); white-space: nowrap; }
        .clock-pill .cp-time { font-size: 12px; font-weight: 700; color: #fff; font-family: 'Courier New', monospace; letter-spacing: 0.03em; }

        #ap-name-input { width: 100%; border: 1px solid transparent; background: transparent; font-size: 15px; font-weight: 600; color: #252120; line-height: 1.4; padding: 4px 8px; border-radius: 8px; font-family: inherit; outline: none; box-sizing: border-box; }
        #ap-name-input:focus { border-color: #002395; background: #faf7f4; }
        #ap-time-input { border: 1px solid transparent; background: transparent; font-size: 11px; font-weight: 700; color: #8a8380; text-transform: uppercase; letter-spacing: 0.08em; padding: 2px 6px; border-radius: 6px; font-family: inherit; outline: none; width: 90px; }
        #ap-time-input:focus { border-color: #002395; background: #faf7f4; }
        #ap-save-btn { display: inline-flex; align-items: center; gap: 5px; background: #012169; color: white; border: none; border-radius: 10px; padding: 8px 16px; font-size: 13px; font-weight: 600; cursor: pointer; margin-top: 8px; }
        #ap-save-btn:hover { opacity: 0.9; }
        #ap-save-status { font-size: 11px; color: #16a34a; margin-left: 10px; display: inline; transition: opacity 0.5s; }

        .ap-link-booking-section { margin-top: 14px; padding-top: 14px; border-top: 1px solid #eae5e0; }
        .ap-link-booking-title { font-size: 11px; font-weight: 700; color: #8a8380; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 8px; }
        .ap-link-check-row:hover { background: #f4f0ec; }
        #ap-linked-badges .linked-badge-inner { display: inline-flex; align-items: center; gap: 6px; background: #e8ecf5; color: #002395; font-size: 12px; font-weight: 600; padding: 6px 12px; border-radius: 20px; cursor: pointer; }
        #ap-linked-badges .linked-badge-inner:hover { background: #d0d8eb; }

        .traveller-card { background: white; border-radius: 12px; box-shadow: 0 1px 4px rgba(0,0,0,0.07); padding: 16px; cursor: pointer; display: flex; align-items: center; gap: 12px; transition: box-shadow 0.2s, transform 0.15s; border: 1px solid #eae5e0; }
        .traveller-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.1); transform: translateY(-1px); }
        .traveller-card .tc-icon { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(135deg, #012169, #002395); color: white; display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
        .traveller-card .tc-info { flex: 1; min-width: 0; }
        .traveller-card .tc-name { font-size: 14px; font-weight: 600; color: #252120; }
        .traveller-card .tc-age { font-size: 12px; color: #8a8380; }
        .traveller-card .tc-arrow { color: #d8d2cc; font-size: 18px; }
        #traveller-panel { position: fixed; top: 0; right: 0; bottom: 0; z-index: 9001; width: min(420px, 100vw); background: #fefcfa; box-shadow: -4px 0 32px rgba(0,0,0,0.15); overflow-y: auto; transform: translateX(100%); transition: transform 0.32s cubic-bezier(0.4,0,0.2,1); display: none; }
        #traveller-panel-overlay { display: none; position: fixed; inset: 0; z-index: 9000; background: rgba(0,0,0,0.25); }
        /* Booking/Ticket edit — same right-side sliding panel pattern as
           #activity-panel/#traveller-panel, replacing the old centered
           popup dialog so all three "edit" surfaces feel consistent. */
        #booking-edit-modal, #ticket-edit-modal, #add-day-modal, #day-map-modal { position: fixed; top: 0; right: 0; bottom: 0; z-index: 9001; width: min(420px, 100vw); background: #fefcfa; box-shadow: -4px 0 32px rgba(0,0,0,0.15); overflow-y: auto; transform: translateX(100%); transition: transform 0.32s cubic-bezier(0.4,0,0.2,1); display: none; }
        #booking-edit-overlay, #ticket-edit-overlay, #add-day-overlay, #day-map-overlay { display: none; position: fixed; inset: 0; z-index: 9000; background: rgba(0,0,0,0.25); }
        .tp-field-group { margin-bottom: 16px; }
        .tp-field-group label { display: block; font-size: 11px; font-weight: 700; color: #8a8380; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 6px; }
        .tp-field-group input, .tp-field-group textarea, .tp-field-group select { width: 100%; border: 1px solid #eae5e0; border-radius: 10px; padding: 10px 14px; font-size: 13px; color: #3a3532; background: #faf7f4; font-family: inherit; outline: none; box-sizing: border-box; }
        .tp-field-group input:focus, .tp-field-group textarea:focus, .tp-field-group select:focus { border-color: #002395; box-shadow: 0 0 0 2px rgba(0,35,149,0.1); }
        .pp-status-btn { flex: 1; padding: 10px 12px; border-radius: 10px; border: 1px solid #eae5e0; background: #faf7f4; font-size: 13px; font-weight: 600; color: #6b6460; cursor: pointer; transition: all 0.15s; }
        .pp-status-btn.active[data-status="buy"] { background: #fef3c7; border-color: #f59e0b; color: #92400e; }
        .pp-status-btn.active[data-status="owned"] { background: #dcfce7; border-color: #16a34a; color: #15803d; }
        .tp-field-group textarea { resize: vertical; min-height: 60px; }
        .tp-field-group .tp-inline { display: flex; align-items: center; gap: 10px; }
        .tp-field-group .tp-age-badge { font-size: 12px; font-weight: 600; color: #002395; background: #e8ecf5; padding: 4px 10px; border-radius: 20px; white-space: nowrap; }
        .tp-passport-warn { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 600; color: #dc2626; background: #fee2e2; padding: 3px 8px; border-radius: 12px; margin-top: 4px; }
        .doc-thumbnail-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
        .doc-thumb { width: 80px; height: 80px; border-radius: 10px; object-fit: cover; position: relative; overflow: hidden; background: #eae5e0; display: flex; align-items: center; justify-content: center; }
        .doc-thumb img { width: 100%; height: 100%; object-fit: cover; border-radius: 10px; }
        .doc-thumb .doc-pdf-icon { font-size: 28px; }
        .doc-thumb .doc-pdf-name { font-size: 8px; color: #6b6460; text-align: center; margin-top: 2px; max-width: 70px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
        .doc-remove-btn { position: absolute; top: 2px; right: 2px; width: 20px; height: 20px; background: rgba(0,0,0,0.6); color: white; border: none; border-radius: 50%; font-size: 11px; cursor: pointer; display: flex; align-items: center; justify-content: center; line-height: 1; }
        .doc-remove-btn:hover { background: #dc2626; }
        .upload-drop-zone { border: 2px dashed #d8d2cc; border-radius: 12px; padding: 24px; text-align: center; cursor: pointer; background: #f4f0ec; transition: border-color 0.2s, background 0.2s; }
        .upload-drop-zone:hover { border-color: #002395; background: #e8ecf5; }

        /* Overview traveller chips */
        .traveller-chip { display: inline-flex; align-items: center; gap: 6px; background: #e8ecf5; color: #002395; font-size: 12px; font-weight: 600; padding: 5px 12px; border-radius: 20px; }

    /* ── Login Gate ─────────────────────────────────── */
    #login-gate {
      position: fixed; inset: 0; z-index: 99999;
      display: flex; align-items: center; justify-content: center;
      background: radial-gradient(circle at top, #012169 0, #001233 40%, #000000 100%);
      color: #fff;
    }
    #login-gate.hidden { display: none !important; }
    #app-root.hidden   { display: none !important; }
    .lg-card {
      background: rgba(255,255,255,0.07); border-radius: 18px;
      padding: 28px 28px 22px; box-shadow: 0 18px 40px rgba(0,0,0,0.5);
      max-width: 360px; width: 90%; backdrop-filter: blur(18px); text-align: center;
    }
    .lg-icon  { font-size: 36px; margin-bottom: 10px; }
    .lg-title { font-size: 20px; font-weight: 700; margin-bottom: 4px; }
    .lg-sub   { font-size: 13px; opacity: .8; margin-bottom: 20px; }
    .lg-btn {
      width: 100%; border-radius: 999px; border: none; padding: 11px 14px;
      font-size: 14px; font-weight: 600; cursor: pointer;
      background: #fff; color: #012169;
      display: flex; align-items: center; justify-content: center; gap: 8px;
    }
    .lg-btn:hover { background: #e8e8e8; }
    .lg-err  { margin-top: 10px; font-size: 12px; color: #ffb3b3; min-height: 16px; }
    .lg-signout { display: block; margin: 4px auto 0; background: none; border: none; color: #9db4e0; font-size: 12px; text-decoration: underline; cursor: pointer; padding: 4px; }
    .lg-meta { margin-top: 14px; font-size: 11px; opacity: .6; }

    /* ── Trip Picker ────────────────────────────────── */
    #trip-picker { position: fixed; inset: 0; z-index: 9500; background: #faf7f4; overflow-y: auto; }
    #trip-picker.hidden { display: none !important; }
    .trip-tile { position: relative; }
    .trip-tile-delete-btn {
      position: absolute; top: 8px; right: 8px; background: rgba(255,255,255,0.9);
      border: none; border-radius: 8px; width: 26px; height: 26px; color: #dc2626;
      cursor: pointer; font-size: 13px; display: flex; align-items: center; justify-content: center;
    }
    .at-type-chip {
      border: 1px solid #d8d2cc; border-radius: 999px; padding: 6px 14px; font-size: 12px;
      font-weight: 600; background: #f4f0ec; color: #524c48; cursor: pointer;
    }
    .at-type-chip.selected { background: #002395; border-color: #002395; color: white; }
