/* ============================================================
   TrippoMe Travel — site chrome (V2.33.0)
   统一页头 / 页脚 / 字体 / 版心，让 55 个功能页与首页（index.html）
   属于同一套视觉体系：米色纸面 · 深墨 · 单一品牌青 · Fraunces 标题。
   由 site-chrome.js 配合使用；html.tb-chrome 由页面 <head> 内的启动脚本加上。
   ============================================================ */

/* ---------- 本地字体（与首页同款，不依赖外部 CDN） ---------- */
@font-face {
  font-family: 'DM Sans'; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url('/vendor/fonts/dm-sans-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Fraunces'; font-style: normal; font-weight: 500 600; font-display: swap;
  src: url('/vendor/fonts/fraunces-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

html.tb-chrome {
  --tb-sans: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans', 'Noto Sans JP', 'Microsoft YaHei', sans-serif;
  --tb-serif: 'Fraunces', Georgia, 'Songti SC', 'Hiragino Mincho ProN', 'Yu Mincho', serif;
}

/* ---------- 隐藏页面自带的旧页头与旧语言切换（由统一页头接管） ---------- */
html.tb-chrome .top { display: none !important; }
html.tb-chrome [data-tb-old-lang] { display: none !important; }

/* ---------- 统一页头（对齐首页 header） ---------- */
html.tb-chrome .tb-bar {
  position: sticky; top: 0; z-index: 80;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 22px;
  padding: 14px 56px; background: var(--paper, #F6F3EE); border-bottom: 1px solid var(--line, #DDD6CA);
  color: var(--ink, #1D2A33); font-family: var(--tb-sans);
}
html.tb-chrome .tb-brand {
  display: flex; flex-direction: column; line-height: 1; text-decoration: none; color: inherit;
}
html.tb-chrome .tb-brand b {
  font-family: 'Fraunces', Georgia, serif; font-size: 28px; font-weight: 600; letter-spacing: -.02em;
}
html.tb-chrome .tb-brand small {
  font-size: 10px; font-weight: 700; letter-spacing: .28em; text-transform: uppercase;
  color: var(--brand, #1F5C5A); margin-top: 4px;
}
html.tb-chrome .tb-nav { display: flex; flex-wrap: wrap; gap: 4px 26px; font-size: 15px; font-weight: 500; margin-left: auto; }
html.tb-chrome .tb-nav a { color: var(--ink-soft, #4A5560); text-decoration: none; padding: 10px 0; }
html.tb-chrome .tb-nav a:hover { color: var(--brand, #1F5C5A); }
html.tb-chrome .tb-lang { display: flex; border: 1px solid var(--ink, #1D2A33); border-radius: 999px; overflow: hidden; background: var(--surface, #fff); }
html.tb-chrome .tb-lang button {
  min-height: 44px; padding: 0 14px; border: 0; background: transparent; color: var(--ink, #1D2A33);
  font-family: inherit; font-size: 14px; font-weight: 600; cursor: pointer; white-space: nowrap;
}
html.tb-chrome .tb-lang button[aria-pressed="true"] { background: var(--ink, #1D2A33); color: var(--paper, #F6F3EE); }
html.tb-chrome .tb-lang button:focus-visible { outline: 2px solid var(--brand, #1F5C5A); outline-offset: -3px; }

/* “仅中文”提示条（plan.html 等内部页） */
html.tb-chrome .tb-zhonly {
  padding: 12px 56px; font-size: 14px; line-height: 1.5; color: var(--ink-soft, #4A5560);
  background: var(--soft, #F6F3EE); border-bottom: 1px solid var(--line, #DDD6CA); font-family: var(--tb-sans);
}

/* ---------- 统一页脚（对齐首页 footer） ---------- */
html.tb-chrome .tb-foot {
  margin-top: 48px; padding: 40px 56px; border-top: 1px solid var(--line, #DDD6CA); background: var(--paper, #F6F3EE);
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px;
  font-size: 14px; color: var(--muted, #5B6670); font-family: var(--tb-sans);
}
html.tb-chrome .tb-foot a { color: inherit; text-decoration: none; margin-left: 18px; }
html.tb-chrome .tb-foot a:hover { color: var(--brand, #1F5C5A); }
html.tb-chrome .tb-foot small { flex-basis: 100%; font-size: 12px; opacity: .75; }

/* ---------- 精简模式：只注入一枚紧凑语言开关到页面自己的页头里 ---------- */
.tb-mini-lang { display: inline-flex; border: 1px solid currentColor; border-radius: 999px; overflow: hidden; margin-left: auto; }
.tb-mini-lang button { min-height: 36px; padding: 0 12px; border: 0; background: transparent; color: inherit; font-family: inherit; font-size: 13px; font-weight: 600; cursor: pointer; opacity: .72; }
.tb-mini-lang button[aria-pressed="true"] { background: var(--paper, #F6F3EE); color: var(--ink, #1D2A33); opacity: 1; }

/* ============================================================
   版心与字号：把各页 11–12px 的“后台小字”提升到首页的阅读尺度
   ============================================================ */
html.tb-chrome body { font-family: var(--tb-sans); font-size: 16px; line-height: 1.55; }
html.tb-chrome .wrap { max-width: 1280px; padding: 36px 56px 64px; }

html.tb-chrome h1 { font-family: var(--tb-serif); font-weight: 500; letter-spacing: -.03em; font-size: clamp(38px, 5vw, 60px); line-height: 1.05; }
html.tb-chrome h2 { font-family: var(--tb-serif); font-weight: 500; letter-spacing: -.02em; font-size: clamp(24px, 2.6vw, 30px); line-height: 1.15; }
html.tb-chrome .card h2,
html.tb-chrome .result h3,
html.tb-chrome .rc h3 { font-family: var(--tb-serif); font-weight: 600; letter-spacing: -.01em; line-height: 1.25; }
html.tb-chrome .card h2 { font-size: 22px; }
html.tb-chrome .result h3 { font-size: 18px; }
html.tb-chrome .rc h3 { font-size: 17px; }

html.tb-chrome .kick { font-size: 12px; font-weight: 700; letter-spacing: .14em; padding: 6px 12px; }
html.tb-chrome .lead { font-size: 17px; line-height: 1.55; max-width: 76ch; }
html.tb-chrome .privacy,
html.tb-chrome .hint,
html.tb-chrome .note { font-size: 13px; line-height: 1.6; }
html.tb-chrome .rc p,
html.tb-chrome .checks,
html.tb-chrome table { font-size: 14px; }
html.tb-chrome .rc p { line-height: 1.55; }
html.tb-chrome th, html.tb-chrome td { padding: 10px 9px; }

html.tb-chrome .chip { font-size: 14px; font-weight: 600; padding: 8px 14px; min-height: 40px; display: inline-flex; align-items: center; }
html.tb-chrome .btn { font-size: 14px; font-weight: 600; min-height: 44px; padding: 10px 16px; border-radius: 14px; }
html.tb-chrome .btn.sm { font-size: 13px; min-height: 36px; padding: 6px 11px; }
html.tb-chrome .badge { font-size: 12px; padding: 4px 9px; }
html.tb-chrome .links a { font-size: 13px; font-weight: 600; padding: 8px 13px; }
html.tb-chrome .tabs button { font-size: 14px; font-weight: 600; min-height: 40px; }
html.tb-chrome .field { font-size: 13px; }
html.tb-chrome .field input,
html.tb-chrome .field select,
html.tb-chrome .field textarea { font-size: 15px; }
html.tb-chrome .ledger input { font-size: 14px; min-height: 40px; }
html.tb-chrome .lrow { font-size: 14px; }
/* 「探索 / 搜索」这一族页面的卡片与筛选条 */
html.tb-chrome .kicker { font-size: 12px; padding: 6px 12px; }
html.tb-chrome .chips .lb,
html.tb-chrome .toolrow label,
html.tb-chrome .searchbar .go,
html.tb-chrome .recent { font-size: 13px; }
html.tb-chrome .toolrow select,
html.tb-chrome .toolrow input[type=number] { font-size: 14px; min-height: 40px; }
html.tb-chrome .resultline { font-size: 14px; }
html.tb-chrome .grid .card h3 { font-size: 17px; }
html.tb-chrome .grid .card .co { font-size: 13px; }
html.tb-chrome .grid .card .sum { font-size: 14px; line-height: 1.5; }
html.tb-chrome .grid .card .tags span { font-size: 12px; padding: 3px 9px; }
html.tb-chrome .grid .card .meta { font-size: 13px; }
html.tb-chrome .grid .card .cmp { font-size: 12px; }
html.tb-chrome .cmpbar .items span { font-size: 13px; }
html.tb-chrome table.cmpTable { font-size: 14px; }

/* 长编号 / 路径 / URL 在窄屏上断行，避免撑出横向滚动 */
html.tb-chrome .wrap { overflow-wrap: anywhere; }

@media (max-width: 1250px) {
  html.tb-chrome .tb-bar, html.tb-chrome .tb-foot, html.tb-chrome .tb-zhonly { padding-left: 24px; padding-right: 24px; }
  html.tb-chrome .wrap { padding-left: 24px; padding-right: 24px; }
}
@media (max-width: 760px) {
  html.tb-chrome .tb-bar { padding: 12px 16px; gap: 10px 14px; }
  html.tb-chrome .tb-brand b { font-size: 24px; }
  html.tb-chrome .tb-nav { gap: 2px 16px; font-size: 14px; margin-left: 0; order: 3; flex-basis: 100%; }
  html.tb-chrome .tb-lang { margin-left: auto; }
  html.tb-chrome .tb-foot, html.tb-chrome .tb-zhonly, html.tb-chrome .wrap { padding-left: 16px; padding-right: 16px; }
  html.tb-chrome h1 { font-size: clamp(32px, 9vw, 44px); }
  /* 手机上会撑出横向滚动的两类元素：分段按钮（如 12 个月份）与对比表 */
  html.tb-chrome .seg { display: flex; flex-wrap: wrap; max-width: 100%; }
  html.tb-chrome #side { overflow-x: auto; max-width: 100%; -webkit-overflow-scrolling: touch; }
}
@media print {
  html.tb-chrome .tb-bar, html.tb-chrome .tb-foot, html.tb-chrome .tb-zhonly { display: none !important; }
}
