/* ============================================================
   旅遊行程網站 - Design System (prototype-aligned v2)
   下次旅遊只需替換 --color-primary / --color-primary-mid / --color-primary-text
   ============================================================ */
:root {
  /* ── App vars (keep all existing) ── */
  --color-primary:      #F5E2CE;
  --color-primary-mid:  #C4703A;
  --color-primary-text: #8B4A1E;
  --color-bg:           #FAF7F2;
  --color-bg-card:      #FFFCF8;
  --color-surface:      #FFFCF8;
  --color-border:       #E8DDD0;
  --color-border-light: #F0EAE0;
  --color-text-primary: #2C1F14;
  --color-text-secondary:#6B4F3A;
  --color-text-hint:    #A08060;
  --color-meal:         #5DCAA5;
  --color-meal-bg:      #E1F5EE;
  --color-meal-text:    #0F6E56;
  --color-urgent:       #FF4D4F;
  --color-urgent-bg:    #FFF1F0;
  --radius-card:        12px;
  --radius-badge:       8px;
  --tab-bar-height:     64px;
  --safe-bottom:        env(safe-area-inset-bottom, 0px);
  --shadow-card:        0 1px 8px rgba(44,31,20,0.06), 0 2px 12px rgba(44,31,20,0.04);
  --shadow-card-lg:     0 6px 24px rgba(44,31,20,0.10), 0 2px 8px rgba(44,31,20,0.06);
  --transition:         0.15s ease;

  /* ── Prototype variable aliases ── */
  --accent:        #C4703A;
  --accent-dark:   #8B4A1E;
  --accent-light:  #F5E2CE;
  --accent-mid:    #D4844A;
  --bg:            #FAF7F2;
  --surface:       #FFFCF8;
  --surface-alt:   #F5F0EB;
  --border:        #E8DDD0;
  --border-light:  #F0EAE0;
  --text-1:        #2C1F14;
  --text-2:        #6B4F3A;
  --text-3:        #A08060;
  --meal:          #2E9B6A;
  --meal-bg:       #E8F5EE;
  --urgent:        #C84040;
  --urgent-bg:     #FFF0F0;
  --cat-sight:     #C4703A;
  --cat-activity:  #D4844A;
  --cat-food:      #2E9B6A;
  --cat-transport: #9A8070;
  --cat-stay:      #7A6355;
  --cat-shopping:  #B06030;
  --shadow-sm:     0 1px 4px rgba(44,31,20,.05), 0 1px 2px rgba(44,31,20,.04);
  --shadow-md:     0 2px 12px rgba(44,31,20,.07), 0 1px 6px rgba(44,31,20,.04);
  --shadow-lg:     0 8px 24px rgba(44,31,20,.10), 0 2px 8px rgba(44,31,20,.06);
  --r:             12px;
  --tab-h:         64px;
  --safe:          env(safe-area-inset-bottom, 0px);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
button { border: none; background: none; outline: none; cursor: pointer; font-family: inherit; -webkit-appearance: none; appearance: none; }
a { color: inherit; text-decoration: none; }

html, body {
  height: 100%;
  font-family: 'Noto Sans TC', 'Noto Sans KR', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--color-bg);
  color: var(--text-1);
  font-size: 15px;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
  overflow: hidden;
}

/* ── App PWA structure ── */
#app {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-width: 480px;
  margin: 0 auto;
  position: relative;
}

/* ── Scroll area ── */
#tab-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding-bottom: calc(var(--tab-h) + var(--safe) + 16px);
}
#tab-content::-webkit-scrollbar { display: none; }

/* ── Tab bar ── */
#tab-bar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  height: calc(var(--tab-h) + var(--safe));
  padding-bottom: var(--safe);
  background: var(--surface);
  border-top: 1px solid var(--border-light);
  box-shadow: 0 -4px 20px rgba(44,31,20,.06);
  display: flex;
  align-items: flex-start;
  justify-content: space-around;
  z-index: 100;
}

.tab-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 2px 6px;
  gap: 3px;
  cursor: pointer;
  color: var(--text-3);
  font-size: 10px;
  font-weight: 500;
  transition: color var(--transition);
  -webkit-tap-highlight-color: transparent;
}
.tab-item.active { color: var(--accent); }
.tab-icon { width: 22px; height: 22px; display: flex; align-items: center; justify-content: center; }
.tab-label { font-size: 10px; font-weight: 500; white-space: nowrap; }

/* ── Tab panels ── */
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ════════════════════════════════════
   HERO
════════════════════════════════════ */
.hero {
  position: relative;
  height: 310px;
  overflow: hidden;
  background: linear-gradient(150deg, var(--accent) 0%, var(--accent-dark) 100%);
}
.hero.hero-noimg {
  background: linear-gradient(150deg, var(--accent) 0%, var(--accent-dark) 100%);
}
.hero-img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(20,12,6,0.10) 0%,
    rgba(20,12,6,0.20) 40%,
    rgba(20,12,6,0.68) 100%
  );
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px 22px 28px;
}
.hero-eyebrow {
  font-size: 11px;
  letter-spacing: 0.22em;
  color: rgba(255,255,255,0.65);
  text-transform: uppercase;
  margin-bottom: 10px;
}
.hero-city {
  font-size: 38px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.5px;
  line-height: 1.05;
  text-shadow: 0 2px 16px rgba(0,0,0,0.3);
}
.hero-dates {
  font-size: 14px;
  color: rgba(255,255,255,0.82);
  margin-top: 8px;
  letter-spacing: 0.03em;
}
.hero-badge {
  position: absolute;
  top: 20px;
  right: 18px;
  background: rgba(255,255,255,0.18);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.28);
  border-radius: 14px;
  padding: 10px 14px;
  text-align: center;
  color: #fff;
}
.hero-badge-num {
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.5px;
}
.hero-badge-label {
  font-size: 9px;
  letter-spacing: 0.12em;
  opacity: 0.75;
  margin-top: 3px;
  text-transform: uppercase;
}

/* ════════════════════════════════════
   SECTION TITLE
════════════════════════════════════ */
.section-title {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 20px 18px 10px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--text-3);
}
.section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.section-title .st-icon {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

/* ════════════════════════════════════
   COUNTDOWN CARD
════════════════════════════════════ */
.countdown-card {
  margin: 6px 16px 4px;
  padding: 18px 20px 16px;
  background: var(--accent-light);
  border-radius: var(--r);
  border: 1px solid rgba(196,112,58,0.2);
}
.countdown-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--accent-dark);
  opacity: 0.65;
  margin-bottom: 12px;
}
.countdown-blocks {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 4px;
}
.cb { display: flex; flex-direction: column; align-items: center; min-width: 52px; }
.cb-num {
  font-size: 32px;
  font-weight: 700;
  color: var(--accent-dark);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  letter-spacing: -1px;
}
.cb-unit {
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-dark);
  opacity: 0.55;
  letter-spacing: 0.3px;
  margin-top: 3px;
}
.cb-sep {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent-dark);
  opacity: 0.3;
  line-height: 1;
  padding-top: 2px;
}
.countdown-done {
  font-size: 18px;
  font-weight: 600;
  color: var(--accent-dark);
  padding: 8px 0;
  text-align: center;
}

/* ════════════════════════════════════
   DAY QUICK OVERVIEW (Home)
════════════════════════════════════ */
.day-overview-list {
  margin: 0 16px;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.dov-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  border-bottom: 0.5px solid var(--border-light);
  cursor: pointer;
  transition: background .12s;
  -webkit-tap-highlight-color: transparent;
}
.dov-item:last-child { border-bottom: none; }
.dov-item:active { background: var(--surface-alt); }
.dov-day-badge {
  font-size: 10px;
  font-weight: 700;
  background: var(--accent-light);
  color: var(--accent-dark);
  padding: 3px 9px;
  border-radius: 6px;
  white-space: nowrap;
  flex-shrink: 0;
}
.dov-date { font-size: 11px; color: var(--text-3); flex-shrink: 0; }
.dov-info { flex: 1; min-width: 0; }
.dov-title { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dov-spots { font-size: 11px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.dov-arrow { color: var(--text-3); flex-shrink: 0; width: 14px; height: 14px; }

/* ════════════════════════════════════
   INFO CARDS (Flight / Hotel)
════════════════════════════════════ */
.info-card {
  margin: 0 16px 10px;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.flight-rows { padding: 14px 16px; }
.flight-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
}
.flight-row + .flight-row { border-top: 0.5px solid var(--border-light); }
.flight-dir {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
  white-space: nowrap;
  flex-shrink: 0;
}
.flight-dir.go  { background: var(--accent-light); color: var(--accent-dark); }
.flight-dir.ret { background: var(--accent); color: #fff; }
.flight-code { font-size: 13px; font-weight: 700; color: var(--accent-dark); flex-shrink: 0; }
.flight-route { font-size: 13px; color: var(--text-2); flex: 1; }
.flight-meta { font-size: 11px; color: var(--text-3); padding-top: 8px; border-top: 0.5px solid var(--border-light); margin-top: 6px; }

.hotel-rows { padding: 14px 16px; }
.hotel-name-main { font-size: 15px; font-weight: 600; margin-bottom: 2px; }
.hotel-name-ko { font-size: 12px; color: var(--text-2); margin-bottom: 10px; }
.hotel-row {
  display: flex;
  gap: 8px;
  font-size: 13px;
  padding: 5px 0;
  border-bottom: 0.5px solid var(--border-light);
}
.hotel-row:last-child { border-bottom: none; }
.hotel-key { color: var(--text-3); font-size: 12px; flex-shrink: 0; min-width: 34px; }

/* ════════════════════════════════════
   ITINERARY TAB — Day Tabs
════════════════════════════════════ */
.day-tabs-wrap {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.day-tabs {
  display: flex;
  padding: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.day-tabs::-webkit-scrollbar { display: none; }
.day-tab-btn {
  flex: 1;
  padding: 10px 4px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-2);
  border-bottom: 2px solid transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  transition: all .18s;
  -webkit-tap-highlight-color: transparent;
}
.day-tab-btn small { font-size: 10px; color: var(--text-3); }
.day-tab-btn.active {
  color: var(--accent-dark);
  border-bottom-color: var(--accent);
}
.day-tab-btn.active small { color: var(--accent); opacity: 0.85; }

/* ── Day header ── */
.day-header-block {
  padding: 14px 16px 12px;
  background: var(--surface);
  border-bottom: 0.5px solid var(--border);
}
.day-header-title { font-size: 16px; font-weight: 700; margin-bottom: 3px; }
.day-header-date { font-size: 12px; color: var(--text-2); }

/* ── Meal dots ── */
.meal-dots-bar { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 16px 4px; }
.meal-dot-badge {
  font-size: 11px;
  background: var(--meal-bg);
  color: var(--meal);
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 600;
}

/* ── Timeline ── */
.timeline { padding: 8px 16px 8px 14px; }
.tl-item { display: flex; gap: 10px; align-items: flex-start; padding-bottom: 10px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 16px;
  align-self: stretch;
}
.tl-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  position: relative; z-index: 1;
  background: #CEB49A;
  margin-top: 16px;
}
.tl-dot.urgent {
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(196,112,58,0.25);
}
.tl-dot.tl-dot-meal {
  background: #3E8A60;
  box-shadow: 0 0 0 2px rgba(62,138,96,0.2);
}
.meal-tl-card { opacity: 0.92; }
/* 編排模式：ac-header-top 要 flex:1 才能靠右對齊箭頭 */
.edit-mode .ac-header-top { flex: 1; min-width: 0; margin-bottom: 0; }
.tl-line {
  width: 1.5px;
  flex: 1;
  background: #CEB49A;
  opacity: 0.35;
}
.tl-item:last-child .tl-line { display: none; }

/* ── Activity Card (with category accent bar) ── */
.activity-card {
  flex: 1;
  min-width: 0;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  position: relative;
}
.activity-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 3.5px;
  border-radius: 12px 0 0 12px;
}
.cat-sight::before    { background: var(--cat-sight); }
.cat-activity::before { background: var(--cat-activity); }
.cat-food::before     { background: var(--cat-food); }
.cat-transport::before{ background: var(--cat-transport); }
.cat-stay::before     { background: var(--cat-stay); }
.cat-shopping::before { background: var(--cat-shopping); }

.ac-header {
  padding: 14px 14px 12px 18px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.ac-header-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}
.ac-tags { display: flex; gap: 4px; flex-wrap: wrap; flex: 1; min-width: 0; align-items: center; }
.ac-tag {
  display: inline-flex;
  align-items: center;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 20px;
  line-height: 1;
}
.tag-s { background: #FEF3E8; color: #9A4A18; }
.tag-a { background: #FDE8D8; color: #8B3A16; }
.tag-f { background: #E8F5EE; color: #1E7A52; }
.tag-t { background: #F5F1EC; color: #7A6355; }
.tag-h { background: #EDE8E2; color: #6B4F3A; }
.tag-p { background: #FCF0E8; color: #954018; }
.tag-l { background: #EFF5EC; color: #3E6A3A; }

.time-badge {
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  padding: 4px 10px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  line-height: 1.3;
  flex-shrink: 0;
  white-space: nowrap;
}
.ac-chevron { color: var(--text-3); flex-shrink: 0; transition: transform .2s; }
.activity-card.meal-injected { border-style: dashed; }

/* 拖拉把手 */
.tl-drag-handle { display: none; align-items: center; justify-content: center; width: 28px; flex-shrink: 0; color: var(--text-3); cursor: grab; padding: 4px 0; }
.tl-drag-handle:active { cursor: grabbing; }
.edit-mode .tl-drag-handle { display: flex; }
.edit-mode .ac-header { display: flex; align-items: center; gap: 0; }

/* 編排按鈕 */
.edit-mode-btn { font-size: 12px; padding: 4px 10px; border-radius: 14px; border: 1px solid var(--border-light); background: var(--surface); color: var(--text-2); cursor: pointer; }
.edit-mode-btn.active { background: var(--accent-light); color: var(--accent-dark); border-color: var(--accent-light); }

/* SortableJS ghost / chosen */
.tl-ghost { opacity: 0.4; background: var(--accent-light); border-radius: var(--r); }
.tl-chosen { box-shadow: 0 4px 16px rgba(0,0,0,0.12); }
.activity-card.open .ac-chevron { transform: rotate(180deg); }
.ac-name { font-size: 15px; font-weight: 600; margin-top: 2px; line-height: 1.3; }
.ac-name-ko { font-size: 11px; color: var(--text-2); margin-top: 2px; }
.ac-desc {
  font-size: 13px; color: var(--text-2); margin-top: 4px; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.ac-detail {
  display: none;
  padding: 0 14px 14px 18px;
  border-top: 0.5px solid var(--border-light);
}
.activity-card.open .ac-detail { display: block; }
.detail-row {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 13px;
  padding: 7px 0;
  border-bottom: 0.5px solid var(--border-light);
  color: var(--text-1);
}
.detail-row:last-child { border-bottom: none; }
.dr-icon { width: 14px; height: 14px; flex-shrink: 0; color: var(--text-2); margin-top: 2px; }
.map-links { display: flex; gap: 10px; padding: 6px 0; border-bottom: 0.5px solid var(--border-light); }
.map-link {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; color: var(--accent-dark);
  opacity: 0.85;
}
.ac-note {
  font-size: 12px; color: var(--text-2);
  background: var(--bg); padding: 8px 10px;
  border-radius: 8px; margin: 6px 0 2px;
  border-left: 3px solid var(--accent-light);
}

/* ── Meal Section ── */
.meal-section-header {
  font-size: 14px; font-weight: 600;
  padding: 16px 16px 8px;
  border-top: 6px solid var(--bg);
}
.restaurant-card {
  margin: 0 16px 10px;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.rc-header {
  display: flex; align-items: center;
  gap: 10px; padding: 12px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.rc-header:active { background: var(--surface-alt); }
.rc-thumb {
  width: 44px; height: 44px;
  border-radius: 8px; object-fit: cover;
  flex-shrink: 0; background: var(--meal-bg);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}
.rc-info { flex: 1; min-width: 0; }
.rc-name { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-name-ko { font-size: 11px; color: var(--text-2); }
.rc-meta { font-size: 12px; color: var(--text-3); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Subtab nav ── */
.subtab-nav {
  display: flex;
  padding: 0 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 20;
}
.subtab-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 12px 4px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-3);
  border-bottom: 2px solid transparent;
  transition: all .15s;
}
.subtab-btn.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}
.subtab-panel { display: none; }
.subtab-panel.active { display: block; }

/* ── Weather banner ── */
.weather-banner {
  margin: 12px 16px 4px;
  padding: 16px;
  background: linear-gradient(135deg, #E8F4FD 0%, #D4EAF8 100%);
  border-radius: var(--r);
  border: 0.5px solid #B8D8F0;
}
.weather-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.weather-chip {
  font-size: 11px; font-weight: 600;
  padding: 3px 10px; border-radius: 20px;
  background: rgba(32,96,160,0.1); color: #2060A0;
}

/* ── Exchange card ── */
.exchange-card {
  margin: 0 16px 10px;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  padding: 14px 16px;
}
.exchange-shop-name { font-size: 14px; font-weight: 600; }
.exchange-shop-detail { font-size: 12px; color: var(--text-2); margin-top: 2px; }

/* ── Transport card ── */
.transport-card {
  margin: 0 16px 10px;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.transport-header {
  background: var(--accent-light);
  padding: 10px 16px;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-dark);
  letter-spacing: 0.5px;
}
.transport-rows { padding: 4px 16px 12px; }
.transport-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  padding: 8px 0;
  border-bottom: 0.5px solid var(--border-light);
}
.transport-row:last-child { border-bottom: none; }
.transport-icon { font-size: 16px; flex-shrink: 0; width: 22px; }
.transport-detail { flex: 1; }
.transport-main { font-weight: 500; }
.transport-sub { font-size: 11px; color: var(--text-2); margin-top: 1px; }

/* ── Checklist ── */
.checklist-group {
  margin: 0 16px 12px;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.checklist-group-title {
  padding: 8px 16px 6px;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-3);
  letter-spacing: 1px;
  text-transform: uppercase;
  background: var(--surface-alt);
  border-bottom: 0.5px solid var(--border-light);
}
.checklist-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-bottom: 0.5px solid var(--border-light);
  cursor: pointer;
}
.checklist-item:last-child { border-bottom: none; }
.checklist-item input[type="checkbox"] {
  accent-color: var(--accent);
  width: 17px; height: 17px;
  flex-shrink: 0;
}
.checklist-text { font-size: 13px; }
.checklist-sub { font-size: 11px; color: var(--text-3); margin-top: 1px; }

/* ── Urgent banner ── */
.urgent-banner {
  background: var(--urgent-bg);
  color: var(--urgent);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 18px 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ── Info rows ── */
.info-section { padding: 0 16px 12px; }
.info-row {
  display: flex;
  gap: 10px;
  font-size: 13px;
  padding: 8px 0;
  border-bottom: 0.5px solid var(--border-light);
  color: var(--text-1);
}
.info-row:last-child { border-bottom: none; }
.info-key {
  font-size: 11px;
  color: var(--text-3);
  flex-shrink: 0;
  min-width: 52px;
  padding-top: 1px;
}
.info-val { flex: 1; line-height: 1.5; }

/* ── Notice ── */
.info-notice {
  margin: 12px 16px;
  padding: 12px 14px;
  background: #FFFBF0;
  border: 1px solid #F5E0A0;
  border-radius: var(--r);
  font-size: 13px;
  color: #8B6820;
  line-height: 1.7;
}

/* ════════════════════════════════════
   APP-SPECIFIC: Chinese tag classes (backward compat)
════════════════════════════════════ */
.tag-景點       { background:#FEF3E8; color:#9A4A18; }
.tag-體驗活動   { background:#FDE8D8; color:#8B3A16; }
.tag-餐飲       { background:#FFF3E0; color:#B85C20; }
.tag-宵夜       { background:#2C1F14; color:#F5E2CE; }
.tag-購物       { background:#FCF0E8; color:#954018; }
.tag-打卡       { background:#EFF5EC; color:#456830; }
.tag-在地體驗   { background:#FDE8D8; color:#8B3A16; }
.tag-在地小吃   { background:#FFF3E0; color:#B05820; }
.tag-放鬆休閒   { background:#EFF5EC; color:#3E6A3A; }
.tag-夜景       { background:#201A14; color:#F0DDD0; }
.tag-文化體驗   { background:#FEF3E8; color:#9A4A18; }
.tag-交通       { background:#F5F1EC; color:#7A6355; }
.tag-住宿       { background:#EDE8E2; color:#6B4F3A; }

/* ── Badge ── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
}
.badge-primary { background: var(--accent-light); color: var(--accent-dark); }
.badge-meal    { background: var(--meal-bg); color: var(--meal); }
.badge-urgent  { background: #FFF0F0; color: #D07070; }
.badge-gray    { background: #F0F0F0; color: var(--text-2); }

/* ── Clickable links ── */
.clickable-address { color: var(--accent-dark); text-decoration: none; opacity: 0.85; }
.clickable-address:hover { opacity: 1; text-decoration: underline; }
.clickable-address:active { opacity: 0.6; }
.clickable-tel { color: var(--accent-dark); text-decoration: none; font-weight: 600; }
.clickable-tel:active { opacity: 0.7; }

/* ── Divider / empty state ── */
.divider { height: 0.5px; background: var(--border); margin: 0 16px; }
.empty-state {
  text-align: center;
  padding: 48px 16px;
  color: var(--text-3);
  font-size: 14px;
}

/* ── Restaurant pool wrapper ── */
.restaurant-pool { padding: 0 0 8px; }

/* ── Restaurant card open state ── */
.restaurant-card .ac-detail {
  padding: 0 14px 14px 14px;
}
.restaurant-card.open .ac-detail { display: block; }
.restaurant-card.open .ac-chevron { transform: rotate(180deg); }

/* ── Meal assign buttons ── */
.meal-assign-section { margin-top: 10px; }
.meal-assign-label { font-size: 11px; color: var(--text-2); margin-bottom: 6px; }
.meal-btns { display: flex; gap: 6px; }
.meal-btn {
  flex: 1;
  padding: 6px 4px;
  font-size: 12px;
  font-weight: 600;
  border: 1.5px solid var(--color-meal);
  color: var(--color-meal-text);
  background: #fff;
  border-radius: 8px;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.meal-btn.assigned { background: var(--color-meal); color: #fff; }
.meal-btn.disabled {
  border-color: var(--border);
  color: var(--text-3);
  cursor: not-allowed;
  background: var(--bg);
}

/* ── Restaurant thumb placeholder ── */
.restaurant-thumb-placeholder {
  width: 44px; height: 44px;
  border-radius: 8px;
  background: var(--meal-bg);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

/* ── Todo (home, inside info-card) ── */
/* Amber warning banner for destination todos */
.todo-section-banner {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--accent-light);
  border-bottom: 0.5px solid rgba(196,112,58,0.25);
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-dark);
  letter-spacing: 0.4px;
  text-transform: uppercase;
}
.todo-banner-icon {
  font-size: 12px;
  opacity: 0.8;
}
/* Preparation section title */
.todo-section-title {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-3);
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 10px 16px 4px;
  border-top: 0.5px solid var(--border-light);
}
.todo-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-bottom: 0.5px solid var(--border-light);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.todo-item:last-child { border-bottom: none; }
.todo-checkbox {
  -webkit-appearance: none;
  appearance: none;
  width: 18px; height: 18px;
  border: 1.5px solid #CACACA;
  border-radius: 5px;
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  background: #fff;
  transition: all 0.15s ease;
}
.todo-checkbox:checked {
  background: var(--accent);
  border-color: var(--accent);
}
.todo-checkbox:checked::after {
  content: '';
  position: absolute;
  left: 5px; top: 2px;
  width: 5px; height: 9px;
  border: 2px solid #fff;
  border-top: none; border-left: none;
  transform: rotate(45deg);
}
.todo-body { flex: 1; min-width: 0; }
.todo-label { display: block; font-size: 13px; color: var(--text-1); line-height: 1.4; }
.todo-done .todo-label { text-decoration: line-through; color: var(--text-3); }
.todo-note {
  display: block;
  font-size: 12px;
  color: var(--accent);
  margin-top: 3px;
  text-decoration: none;
  line-height: 1.4;
}
.todo-note:hover { text-decoration: underline; }
.todo-done .todo-note { opacity: 0.4; }
.todo-progress-badge {
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-dark);
  background: var(--accent-light);
  padding: 1px 8px;
  border-radius: 10px;
  margin-left: 4px;
  text-transform: none;
  letter-spacing: 0;
}

/* ── TICKETS ── */
.ticket-card { padding: 16px; }
.ticket-card--pinned { border-left: 3px solid var(--accent); }
@keyframes ticket-highlight-flash {
  0%   { background: var(--accent-light); }
  100% { background: #fff; }
}
.ticket-card--highlight { animation: ticket-highlight-flash 1.5s ease forwards; }
.ticket-header-row { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 4px; }
.ticket-name { font-size: 15px; font-weight: 600; }
.ticket-note { font-size: 13px; color: var(--text-2); margin-bottom: 12px; }
.pass-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: var(--accent-light);
  color: var(--accent-dark);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  border: 1px solid rgba(196,112,58,0.2);
}
.pass-chip:active { opacity: 0.7; }
.ticket-pinned-label { color: var(--accent); }
.ticket-footer { display: flex; align-items: center; gap: 8px; }
.btn-drive {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-light);
  color: var(--accent-dark);
  border-radius: 8px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}
.ticket-no-drive { font-size: 12px; color: var(--text-3); font-style: italic; }
.btn-booking { background: #fff; border: 1.5px solid var(--border); color: var(--accent); }
.ticket-detail { display: flex; flex-direction: column; gap: 6px; }
.ticket-detail-row { font-size: 13px; color: var(--text-2); }
.pass-map-thumb {
  position: relative;
  margin: 10px 0;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  border: 0.5px solid var(--border);
}
.pass-map-thumb img {
  width: 100%;
  max-width: 100%;
  display: block;
  max-height: 220px;
  object-fit: cover;
  object-position: top;
}
.pass-map-hint {
  position: absolute;
  bottom: 8px;
  right: 10px;
  font-size: 11px;
  color: #fff;
  background: rgba(0,0,0,0.45);
  padding: 2px 8px;
  border-radius: 10px;
}
.pass-includes, .redemption-list {
  margin: 10px 0;
  border: 0.5px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.pass-includes summary, .redemption-list summary {
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  background: var(--bg);
  color: var(--text-2);
}
.pass-includes ul { padding: 8px 12px 10px 28px; }
.pass-includes li { font-size: 13px; color: var(--text-1); padding: 2px 0; }
.pass-warning {
  font-size: 11px;
  color: var(--urgent);
  padding: 4px 12px 10px;
}
.redemption-item {
  padding: 10px 14px;
  border-bottom: 0.5px solid var(--border-light);
}
.redemption-item:last-child { border-bottom: none; }
.redemption-name { font-size: 13px; font-weight: 600; }
.redemption-note { font-size: 11px; color: var(--text-2); margin-top: 1px; }
.redemption-addr { font-size: 11px; color: var(--text-3); margin-top: 2px; }

/* ── Weather (functional) ── */
.weather-current {
  margin: 8px 16px 12px;
  padding: 20px;
  background: var(--surface);
  border-radius: var(--r);
  color: var(--text-1);
  text-align: center;
  box-shadow: var(--shadow-card);
  border: 0.5px solid var(--border-light);
}
.weather-icon-big { font-size: 48px; margin-bottom: 4px; }
.weather-temp-big { font-size: 42px; font-weight: 300; line-height: 1.1; color: var(--text-1); }
.weather-desc { font-size: 14px; margin-top: 6px; color: var(--text-2); }
.weather-meta { font-size: 12px; margin-top: 4px; color: var(--text-3); }
.weather-clothing {
  font-size: 12px;
  background: var(--accent-light);
  border-radius: 8px;
  padding: 6px 12px;
  margin-top: 10px;
  color: var(--accent-dark);
}
.forecast-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin: 0 16px 12px;
}
.forecast-cell {
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: 10px;
  padding: 10px 4px;
  text-align: center;
  box-shadow: var(--shadow-card);
}
.forecast-cell.trip-day {
  background: var(--accent-light);
  border-color: var(--accent);
}
.fc-date { font-size: 11px; color: var(--text-2); margin-bottom: 6px; line-height: 1.3; }
.forecast-cell.trip-day .fc-date { color: var(--accent-dark); font-weight: 600; }
.fc-icon { font-size: 22px; margin-bottom: 5px; line-height: 1; }
.fc-temp-max { font-size: 13px; font-weight: 600; color: var(--text-1); }
.fc-temp-min { font-size: 11px; color: var(--text-3); margin-top: 1px; }
.fc-rain { font-size: 10px; color: var(--text-3); margin-top: 5px; }

/* ── Exchange (functional) ── */
.exchange-hero {
  margin: 12px 16px;
  padding: 20px;
  background: linear-gradient(135deg, var(--accent-light) 0%, var(--accent) 100%);
  border-radius: var(--r);
  box-shadow: var(--shadow-sm);
}
.rate-big { font-size: 20px; color: var(--text-1); }
.rate-big strong { font-size: 28px; color: var(--accent-dark); }
.rate-reverse { font-size: 13px; color: var(--text-2); margin-top: 4px; }
.rate-updated { font-size: 11px; color: var(--text-3); margin-top: 4px; }
.rate-loading { padding: 16px; color: var(--text-3); font-size: 13px; }
.calc-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.calc-input {
  flex: 1;
  padding: 10px 12px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 15px;
  background: var(--bg);
  color: var(--text-1);
  text-align: right;
}
.calc-input:focus { border-color: var(--accent); outline: none; }
.calc-arrow { font-size: 18px; color: var(--text-3); }
.calc-result {
  flex: 1;
  font-size: 15px;
  font-weight: 700;
  color: var(--accent-dark);
  text-align: right;
  background: var(--accent-light);
  padding: 10px 12px;
  border-radius: 8px;
  min-width: 0;
}
.calc-hint { font-size: 11px; color: var(--text-3); text-align: right; margin-top: 4px; }
.quick-krw {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}
.quick-krw-btn {
  padding: 5px 10px;
  font-size: 12px;
  border: 1.5px solid var(--accent);
  border-radius: 20px;
  background: transparent;
  color: var(--accent-dark);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  font-family: inherit;
}
.quick-krw-btn:active {
  background: var(--accent);
  color: #fff;
}
/* ── Bill Counter ── */
.bill-counter-card { padding: 0 16px; }
.bill-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 0.5px solid var(--border-light);
}
.bill-label {
  flex: 1;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}
.bill-stepper {
  display: flex;
  align-items: center;
  gap: 8px;
}
.bill-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  background: transparent;
  color: var(--accent-dark);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  transition: background 0.15s;
}
.bill-btn:active { background: var(--accent); color: #fff; }
.bill-count {
  min-width: 24px;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-1);
}
.bill-sub {
  min-width: 72px;
  text-align: right;
  font-size: 12px;
  color: var(--text-3);
}
.bill-total-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 0 16px;
}
.bill-total-label {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-1);
}
.bill-total-nums {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}
.bill-total-krw {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent-dark);
}
.bill-total-twd {
  font-size: 12px;
  color: var(--text-2);
}
.bill-reset-btn {
  padding: 6px 12px;
  font-size: 12px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: transparent;
  color: var(--text-3);
  cursor: pointer;
  font-family: inherit;
}
.bill-reset-btn:active { background: var(--border); }
.tip-item { font-size: 13px; color: var(--text-2); padding: 5px 0; border-bottom: 0.5px solid var(--border); }
.tip-item:last-child { border-bottom: none; }
.exchange-name { font-size: 14px; font-weight: 600; margin-bottom: 4px; }

/* ── Exchange location collapsible ── */
.exloc-card {
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  margin: 0 16px 8px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.exloc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 14px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.exloc-header-left { flex: 1; min-width: 0; }
.exloc-name { font-size: 14px; font-weight: 600; color: var(--text-1); margin-bottom: 4px; }
.exloc-area {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  background: var(--accent-light);
  color: var(--accent-dark);
  padding: 2px 8px;
  border-radius: 20px;
}
.exloc-chevron { color: var(--text-3); flex-shrink: 0; transition: transform .2s; }
.exloc-card.open .exloc-chevron { transform: rotate(180deg); }
.exloc-detail {
  display: none;
  padding: 0 14px 14px;
  border-top: 0.5px solid var(--border-light);
}
.exloc-card.open .exloc-detail { display: block; }
.exloc-note { font-size: 12px; color: var(--text-3); margin-top: 6px; }

/* ── Transport (functional) ── */
.transfer-item {
  padding: 12px 0;
  border-bottom: 0.5px solid var(--border);
}
.transfer-item:last-child { border-bottom: none; }
.transfer-name { font-size: 14px; font-weight: 600; margin-top: 4px; }
.transfer-meta { font-size: 13px; color: var(--text-2); margin-top: 2px; }
.transfer-note { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.local-transport-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 0.5px solid var(--border);
}
.local-transport-item:last-child { border-bottom: none; }
.local-icon { font-size: 22px; flex-shrink: 0; width: 28px; }
.local-info { flex: 1; }
.local-name { font-size: 14px; font-weight: 600; }
.local-desc { font-size: 12px; color: var(--text-2); margin-top: 2px; }
.local-meta { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.transport-anchors {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 16px 18px 8px;
}
.transport-anchor-btn {
  flex: 1;
  min-width: 0;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 20px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  cursor: pointer;
  white-space: nowrap;
  text-align: center;
}
.transport-anchor-btn:active { background: var(--accent-light); }

.station-ref-wrap { border: none; }
.station-ref-summary {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--accent);
  cursor: pointer;
  list-style: none;
  padding: 2px 0;
}
.station-ref-summary::-webkit-details-marker { display: none; }
.station-ref-grid { display: flex; flex-direction: column; gap: 5px; margin-top: 8px; }
.station-ref-row { display: flex; align-items: center; gap: 6px; font-size: 12px; }
.sref-zh { width: 60px; font-weight: 600; color: var(--text-1); flex-shrink: 0; }
.sref-ko { width: 72px; color: var(--text-2); flex-shrink: 0; font-size: 11px; }
.sref-codes { display: flex; flex-wrap: wrap; gap: 4px; }
.sref-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1px 6px;
  font-size: 11px;
  color: var(--text-2);
}
.sref-badge b { color: var(--accent); font-weight: 700; }

.station-access-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 4px; }
.station-access-row { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.sa-icon { width: 20px; text-align: center; flex-shrink: 0; }
.sa-mode { font-weight: 600; width: 52px; flex-shrink: 0; color: var(--text-1); }
.sa-duration { color: var(--accent); font-weight: 600; flex-shrink: 0; white-space: nowrap; min-width: 72px; }
.sa-note { color: var(--text-2); font-size: 12px; flex: 1; min-width: 0; }

.luggage-storage-item {
  padding: 12px 14px;
  background: var(--bg);
  border-radius: 10px;
  margin-bottom: 8px;
}
.luggage-storage-item:last-child { margin-bottom: 0; }
.storage-name { font-size: 14px; font-weight: 600; margin-bottom: 8px; color: var(--text-1); }
.luggage-storage-item .detail-row {
  padding: 3px 0;
  border-bottom: none;
  font-size: 12.5px;
  color: var(--text-2);
}
.luggage-storage-item .ac-note {
  margin-top: 8px;
  font-size: 12px;
}

/* ── Luggage ── */
.luggage-category {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  margin: 0 16px 10px;
  box-shadow: var(--shadow-sm);
}
.luggage-progress-bar {
  position: absolute;
  top: 0; left: 0;
  height: 3px;
  background: var(--accent);
  border-radius: 0;
  transition: width 0.3s;
}
.luggage-progress {
  font-size: 12px;
  color: var(--text-3);
  font-weight: normal;
  margin-left: 6px;
}
.luggage-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-bottom: 0.5px solid var(--border);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.luggage-item:last-child { border-bottom: none; }
.luggage-item:active { background: var(--bg); }
.luggage-checkbox {
  -webkit-appearance: none;
  appearance: none;
  width: 18px; height: 18px;
  border: 1.5px solid #CACACA;
  border-radius: 5px;
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  background: #fff;
  transition: all 0.15s ease;
}
.luggage-checkbox:checked {
  background: var(--accent);
  border-color: var(--accent);
}
.luggage-checkbox:checked::after {
  content: '';
  position: absolute;
  left: 5px; top: 2px;
  width: 5px; height: 9px;
  border: 2px solid #fff;
  border-top: none; border-left: none;
  transform: rotate(45deg);
}
.luggage-item.checked span { text-decoration: line-through; color: var(--text-3); }
.luggage-item span { font-size: 14px; }

/* ── Info page ── */
.entry-deadline {
  font-size: 13px;
  color: var(--urgent);
  font-weight: 600;
  margin-bottom: 10px;
}
.entry-steps {
  font-size: 13px;
  padding-left: 18px;
  color: var(--text-1);
  line-height: 2;
}
.entry-steps li { margin-bottom: 2px; }
.entry-sub {
  display: inline-block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-2);
  line-height: 1.9;
  padding-left: 4px;
}
.entry-notes { margin-top: 12px; margin-bottom: 4px; display: flex; flex-direction: column; gap: 6px; }
.entry-note-item {
  font-size: 12px;
  color: var(--accent-dark);
  background: var(--accent-light);
  border-radius: 8px;
  padding: 7px 10px;
  line-height: 1.5;
}
.entry-errors { margin-top: 8px; }
.entry-errors ul {
  font-size: 12px;
  color: var(--urgent);
  padding-left: 18px;
  line-height: 2;
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}
.adapter-type { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.adapter-voltage { font-size: 13px; color: var(--text-2); margin-bottom: 4px; }
.adapter-note { font-size: 13px; color: var(--text-2); }
.adapter-section-label { font-size: 12px; font-weight: 600; color: var(--text-2); margin-top: 14px; margin-bottom: 2px; }
.adapter-imgs { display: flex; gap: 10px; margin-top: 6px; overflow-x: auto; padding-bottom: 4px; }
.adapter-img-wrap { flex: 0 0 auto; text-align: center; }
.adapter-img-wrap img { width: 100px; height: 90px; object-fit: contain; border-radius: 8px; background: var(--bg); border: 0.5px solid var(--border-light); }
.adapter-img-label { font-size: 11px; color: var(--text-3); margin-top: 5px; max-width: 100px; }
.adapter-warning { margin-top: 8px; font-size: 13px; color: var(--urgent); font-weight: 600; }
.info-open-btn { display: inline-flex; align-items: center; gap: 6px; background: var(--accent-light); color: var(--accent-dark); border-radius: 8px; padding: 7px 14px; font-size: 13px; font-weight: 600; text-decoration: none; margin: 8px 0; }

/* Phrases */
.phrases-table { padding: 0; }
.phrase-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 12px;
  border-bottom: 0.5px solid var(--border);
}
.phrase-row:last-child { border-bottom: none; }
.phrase-situation {
  flex-shrink: 0;
  width: 56px;
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-dark);
}
.phrase-content { flex: 1; min-width: 0; }
.phrase-zh { font-size: 13px; font-weight: 500; }
.phrase-ko { font-size: 13px; color: var(--text-2); margin-top: 1px; }
.phrase-en { font-size: 11px; color: var(--text-3); }
.phrase-cat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px 12px 16px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.2px;
  color: var(--text-2);
  background: #fff;
  border-bottom: 0.5px solid var(--border);
  border-left: 3px solid var(--accent);
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s;
}
.phrase-cat-header:active { background: var(--bg); }
.cat-chevron {
  font-size: 15px;
  color: var(--text-3);
  transition: transform 0.2s;
  transform: rotate(0deg);
  flex-shrink: 0;
}
.phrase-cat-header.open .cat-chevron { transform: rotate(90deg); }
.phrase-cat-rows { overflow: hidden; }
.phrase-actions { display: flex; gap: 5px; flex-shrink: 0; align-items: center; }
.phrase-speak {
  flex-shrink: 0;
  border: none;
  background: transparent;
  font-size: 16px;
  line-height: 1;
  padding: 2px 4px;
  border-radius: 6px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  opacity: 0.75;
}
.phrase-speak:active { opacity: 1; }
.phrase-copy {
  flex-shrink: 0;
  border: none;
  background: var(--accent-light);
  color: var(--accent-dark);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* Announcement Board */
.announce-edit-toggle {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 2px 4px;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
}
.announce-edit-toggle.is-done { color: var(--accent-dark); }
.announce-add-row-btn {
  display: block;
  width: 100%;
  padding: 11px 14px;
  text-align: left;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent);
  background: transparent;
  border: none;
  border-top: 0.5px solid var(--border);
  cursor: pointer;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
}
.announce-card { padding: 0; overflow: hidden; margin-bottom: 8px; }
.announce-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 0.5px solid var(--border);
}
.announce-item:last-child { border-bottom: none; }
.announce-num {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}
.announce-body { flex: 1; min-width: 0; }
.announce-text { font-size: 13px; color: var(--text-1, #3D2B1A); line-height: 1.5; }
.announce-link { color: var(--accent-dark); text-decoration: none; display: block; }
.announce-link:active { opacity: 0.7; }
.announce-link-arrow { font-size: 11px; opacity: 0.6; }
.announce-del {
  flex-shrink: 0;
  border: none;
  background: transparent;
  color: var(--text-3);
  font-size: 14px;
  cursor: pointer;
  padding: 0 2px;
  line-height: 1;
  -webkit-tap-highlight-color: transparent;
}
.announce-del:active { color: #c0392b; }
.announce-empty { padding: 16px; text-align: center; font-size: 13px; color: var(--text-3); }
.announce-form-wrap { padding: 16px 14px; border-top: 0.5px solid var(--border); display: flex; flex-direction: column; gap: 10px; }
.announce-form-btns { margin-top: 6px; }
.announce-input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 11px 12px;
  font-size: 13px;
  font-family: inherit;
  color: var(--text-1, #3D2B1A);
  background: #fff;
  resize: none;
  box-sizing: border-box;
}
.announce-url-input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 11px 12px;
  font-size: 13px;
  font-family: inherit;
  color: var(--text-2);
  background: #fff;
  box-sizing: border-box;
}
.announce-input:focus, .announce-url-input:focus { outline: none; border-color: var(--accent); }
.announce-form-btns { display: flex; gap: 8px; justify-content: flex-end; }
.announce-save-btn {
  padding: 7px 18px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}
.announce-cancel-btn {
  padding: 7px 14px;
  background: transparent;
  color: var(--text-3);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 13px;
  font-family: inherit;
  cursor: pointer;
}

/* Reference Board */
.ref-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 0.5px solid var(--border);
}
.ref-item:last-child { border-bottom: none; }
.ref-icon { flex-shrink: 0; margin-top: 2px; }
.ref-body { flex: 1; min-width: 0; }
.ref-title {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-dark);
  text-decoration: none;
  line-height: 1.4;
}
.ref-title:active { opacity: 0.7; }
.ref-desc { font-size: 11px; color: var(--text-3); margin-top: 2px; }

/* Emergency */
.emergency-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 0;
  border-bottom: 0.5px solid var(--border);
  font-size: 13px;
}
.emergency-row:last-child { border-bottom: none; }
.emergency-num {
  font-size: 15px;
  font-weight: 700;
  color: var(--urgent);
  text-decoration: none;
}

/* Situation */
.situation-item { padding: 14px 16px; border-bottom: 0.5px solid var(--border); }
.situation-item:last-child { border-bottom: none; }
.situation-title { font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--urgent); }
.situation-steps { font-size: 13px; color: var(--text-2); padding-left: 16px; }
.situation-steps li { margin-bottom: 4px; }

/* Airline info */
.airline-info { padding: 14px 16px; }
.airline-info-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 0.5px solid var(--border); font-size: 13px; }
.airline-info-row:last-child { border-bottom: none; }
.airline-info-key { color: var(--text-2); }
.airline-info-val { font-weight: 500; }

/* ── Activity card thumbnail ── */
.ac-thumb {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  flex-shrink: 0;
  margin-right: 10px;
}
.ac-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.25s ease;
}
.ac-thumb:active img { transform: scale(1.06); }
.ac-thumb-ph { display: flex; align-items: center; justify-content: center; cursor: default; }

/* ── Lightbox ── */
#lightbox-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 9999;
  align-items: center;
  justify-content: center;
}
#lightbox-overlay.active { display: flex; }
.lb-bg {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.88);
}
.lb-content {
  position: relative;
  z-index: 1;
  max-width: 92vw;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
#lb-img {
  max-width: 92vw;
  max-height: 78vh;
  object-fit: contain;
  border-radius: 10px;
  display: block;
}
.lb-close {
  position: absolute;
  top: -44px; right: 0;
  color: #fff;
  font-size: 22px;
  padding: 8px 12px;
  cursor: pointer;
  line-height: 1;
}
#lb-caption {
  color: rgba(255,255,255,0.75);
  font-size: 13px;
  text-align: center;
  max-width: 80vw;
}

/* ── btn-ticket ── */
.btn-ticket {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-light);
  color: var(--accent-dark);
  border-radius: 8px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  margin-top: 8px;
}

/* ── Copy toast ── */
.copy-toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.72);
  color: white;
  padding: 8px 18px;
  border-radius: 20px;
  font-size: 13px;
  z-index: 300;
  pointer-events: none;
  animation: fadeInOut 1.5s ease forwards;
}
@keyframes fadeInOut {
  0%   { opacity: 0; transform: translateX(-50%) translateY(8px); }
  20%  { opacity: 1; transform: translateX(-50%) translateY(0); }
  80%  { opacity: 1; }
  100% { opacity: 0; }
}

/* ── Card (generic, used by tickets/weather/etc) ── */
.card {
  background: var(--surface);
  border: 0.5px solid var(--border-light);
  border-radius: var(--r);
  margin: 0 16px 10px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

/* ── Utilities ── */
.mt4 { margin-top: 4px; }
.mt8 { margin-top: 8px; }
.mt12 { margin-top: 12px; }
.pb16 { padding-bottom: 16px; }
.ml4 { margin-left: 4px; }
.info-label {
  color: var(--text-2);
  flex-shrink: 0;
  min-width: 36px;
}
.detail-icon { width: 18px; flex-shrink: 0; color: var(--text-2); margin-top: 1px; }

/* ════════════════════════════════════
   DESKTOP RWD
════════════════════════════════════ */
@media (min-width: 600px) {
  html, body {
    overflow: hidden;
    background: var(--bg);
  }
  #app {
    max-width: 100%;
    height: 100%;
  }
  #tab-bar {
    left: 0;
    right: 0;
    transform: none;
    max-width: 100%;
    background: var(--surface);
    border-top: 0.5px solid var(--border);
    justify-content: center;
  }
  .tab-item {
    flex: 0 0 auto;
    width: 96px;
    padding: 10px 0 6px;
  }
  .hero {
    height: clamp(300px, 45vh, 480px);
  }
  .hero-overlay {
    padding: 24px max(24px, calc(50vw - 460px)) 40px;
  }
  .countdown-card {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
  }
  .section-title {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 4px;
    padding-right: 4px;
  }
  .card {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
  }
  .transport-anchors {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 4px;
    padding-right: 4px;
  }
  .day-tabs-wrap,
  .timeline,
  .restaurant-pool,
  .day-header-block,
  .subtab-nav {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
  }
  .subtab-nav {
    border-radius: var(--r);
    margin-top: 8px;
    border: 0.5px solid var(--border);
  }
  .info-card,
  .day-overview-list,
  .checklist-group,
  .luggage-category,
  .restaurant-card,
  .exloc-card,
  .weather-current,
  .forecast-grid {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
  }
}

/* ── Toast 通知 ── */
.toast-msg {
  position: fixed;
  bottom: calc(var(--tab-h) + var(--safe) + 16px);
  left: 50%;
  transform: translateX(-50%) translateY(16px);
  background: rgba(40, 30, 20, 0.88);
  color: #fff;
  font-size: 13px;
  padding: 10px 18px;
  border-radius: 20px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
  z-index: 9999;
}
.toast-msg.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
