/* ============================================================
   神秘酒吧事务司 —— 样式
   配色：暖暗酒吧 + 琥珀色边框 + 霓虹粉点缀
   手机适配：下面有 @media 分段，窄屏时面板铺满、按钮放底部
   ============================================================ */
:root {
  --bg: #120a0c;
  --panel: #2a1d1a;
  --panel-2: #3a2a24;
  --amber: #e0a96d;
  --amber-dark: #8a5a36;
  --text: #f6e7cf;
  --muted: #b79c80;
  --pink: #ff4f9a;
  --ok: #8ccf6a;
  --warn: #f2c14e;
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", "Noto Sans SC", sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body {
  margin: 0; height: 100%; overflow: hidden; background: var(--bg);
  color: var(--text); font-family: var(--font); touch-action: manipulation;
}
/* 底部留出按钮栏的高度，免得「酒单 / 图鉴」按钮挡住场景底部（出口名牌等） */
#game { position: fixed; inset: 0 0 calc(72px + env(safe-area-inset-bottom)) 0; }
#game canvas { image-rendering: pixelated; image-rendering: crisp-edges; display: block; }
#labels { position: fixed; inset: 0; pointer-events: none; z-index: 5; }
#ui { position: fixed; inset: 0; pointer-events: none; z-index: 10; }
#ui > * { pointer-events: auto; }
img.pixel { image-rendering: pixelated; image-rendering: crisp-edges; }

/* ---------- 像素风边框盒子 ---------- */
.pixel-box {
  background: var(--panel);
  border: 3px solid var(--amber);
  box-shadow: 0 0 0 3px #120a0c, 0 6px 0 3px #120a0c, 0 12px 30px rgba(0, 0, 0, .55);
  border-radius: 4px;
}

/* ---------- 按钮 ---------- */
.btn {
  font: inherit; font-weight: 700; color: var(--text); cursor: pointer;
  background: var(--panel-2); border: 2px solid var(--amber); border-radius: 4px;
  padding: 10px 16px; min-height: 44px; box-shadow: 0 3px 0 #120a0c;
}
.btn:active { transform: translateY(2px); box-shadow: 0 1px 0 #120a0c; }
.btn-primary { background: #b8453a; border-color: #ffd98a; }
.btn-small { padding: 6px 12px; min-height: 36px; font-size: 14px; }
.btn-close { padding: 0; width: 40px; min-height: 40px; font-size: 24px; line-height: 1; }

/* ---------- 名字牌（小人头顶） ---------- */
.tag {
  position: fixed; transform: translate(-50%, -100%); white-space: nowrap;
  font-size: 12px; font-weight: 700; padding: 1px 6px; border-radius: 3px;
  background: rgba(18, 10, 12, .78); color: var(--text); border: 1px solid rgba(224, 169, 109, .5);
  text-shadow: 0 1px 0 #000;
}
.tag-self { color: #ffd98a; border-color: #ffd98a; }
.tag-npc { color: #ffb3d1; border-color: var(--pink); animation: bob 1.4s ease-in-out infinite; }
@keyframes bob { 50% { margin-top: -3px; } }
.tag-demo, .tag-self + .tag-demo {
  margin-left: 4px; font-size: 10px; color: #1a1010; background: var(--warn); border-radius: 2px; padding: 0 3px;
}
.tag-self { /* 面板里"你"的小标 */ }
.p-name .tag-self { margin-left: 4px; font-size: 10px; background: #ffd98a; color: #1a1010; border-radius: 2px; padding: 0 3px; }

/* ---------- 小标签 ---------- */
.tag-mini {
  display: inline-block; margin-left: 6px; padding: 1px 6px; font-size: 11px; font-weight: 700;
  border-radius: 3px; background: #4a3a30; color: var(--muted); vertical-align: middle;
}
.tag-mini.warn { background: var(--warn); color: #2a1a10; margin-left: 0; }
.tag-mini.ok { background: #2f5a34; color: #c9f0b4; margin: 0; }

/* ---------- 全屏覆盖层 ---------- */
.overlay { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; padding: 12px; }

/* ---------- 开始界面 ---------- */
.start-screen { background: rgba(10, 5, 8, .62); backdrop-filter: blur(2px); z-index: 20; pointer-events: auto; }
.start-card { width: min(92vw, 380px); padding: 26px 22px 20px; text-align: center; display: flex; flex-direction: column; gap: 14px; }
.start-logo {
  font-size: 52px; font-weight: 900; letter-spacing: 6px; color: #ff4f9a; line-height: 1;
  text-shadow: 0 0 10px rgba(255, 79, 154, .8), 0 3px 0 #7a1f4a;
}
.start-title { margin: 0; font-size: 24px; letter-spacing: 2px; }
.start-sub { color: var(--muted); font-size: 13px; margin-top: -8px; }
.name-input {
  font: inherit; font-size: 18px; text-align: center; color: var(--text);
  background: #1a1010; border: 2px solid var(--amber); border-radius: 4px; padding: 12px; outline: none;
}
.name-input:focus { border-color: #ffd98a; box-shadow: 0 0 0 3px rgba(255, 217, 138, .25); }
.start-card .btn { font-size: 18px; padding: 12px; }
/* 室外（街口、小巷）不显示酒单 / 图鉴 */
body.outdoor #btn-menu, body.outdoor #btn-collection { display: none; }
.via-title { color: var(--muted); font-size: 13px; margin-bottom: -6px; }
.via-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.via-btn { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 2px 6px; font: inherit; font-size: 13px;
  color: var(--muted); background: rgba(0, 0, 0, .25); border: 2px solid #4a3426; border-radius: 4px; cursor: pointer; }
.via-btn img { width: 39px; height: 27px; image-rendering: pixelated; opacity: .55; }
.via-btn:hover { border-color: var(--amber-dark); }
.via-btn.on { color: #ffd98a; border-color: #ffd98a; background: rgba(255, 217, 138, .08); }
.via-btn.on img { opacity: 1; }
.p-name .via-icon { width: 13px; height: 9px; margin-right: 5px; vertical-align: -1px; image-rendering: pixelated; }
.start-hint { color: var(--muted); font-size: 13px; line-height: 1.5; }
.start-hint.warn { color: var(--warn); }
code { background: #1a1010; padding: 1px 6px; border-radius: 3px; }

/* ---------- 常驻按钮 / 在场名单 ---------- */
.hud-title {
  z-index: 1;
  position: fixed; left: 16px; top: 14px; font-weight: 900; letter-spacing: 2px; font-size: 18px;
  color: #ff8fc0; text-shadow: 0 0 8px rgba(255, 79, 154, .7), 0 2px 0 #000; pointer-events: none !important;
}
.hud-bar {
  position: fixed; left: 50%; bottom: calc(14px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  display: flex; gap: 10px; z-index: 12;
}
.hud-bar .btn { min-width: 92px; font-size: 16px; }
.presence-panel {
  position: fixed; right: 12px; top: 12px; width: 230px; padding: 10px 12px; font-size: 14px; z-index: 11;
}
.panel-head { font-weight: 800; color: #ffd98a; margin-bottom: 6px; }
.panel-foot { margin-top: 8px; font-size: 11px; color: var(--muted); display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.panel-link { color: #ffd98a; font-size: 13px; font-weight: 700; text-decoration: none; padding: 4px 0; white-space: nowrap; }
.p-row { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-bottom: 1px dashed rgba(224, 169, 109, .25); }
.p-name { font-weight: 700; white-space: nowrap; }
.p-drink { color: var(--muted); font-size: 12px; text-align: right; }

/* ---------- 弹窗（酒单 / 图鉴） ---------- */
.modal-backdrop { background: rgba(10, 5, 8, .6); z-index: 20; }
.modal { width: min(94vw, 560px); max-height: min(86dvh, 720px); display: flex; flex-direction: column; padding: 14px; }
.modal-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.modal-head h2 { margin: 0; font-size: 20px; flex: 1; letter-spacing: 2px; color: #ffd98a; }
.coll-progress { font-size: 13px; color: var(--muted); }

.tabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 8px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: 1 1 0; font: inherit; font-weight: 700; font-size: 14px; text-align: center; color: var(--muted); cursor: pointer;
  background: #1a1010; border: 2px solid #4a3a30; border-radius: 4px; padding: 8px 4px; min-height: 40px; white-space: nowrap; min-width: 0;
}
.tab small { font-weight: 400; opacity: .7; margin-left: 3px; font-size: 11px; }
.tab.active { color: #1a1010; background: var(--amber); border-color: #ffd98a; }

.list { overflow-y: auto; flex: 1; min-height: 0; -webkit-overflow-scrolling: touch; padding-right: 2px; }
.drink-row {
  display: flex; align-items: center; gap: 12px; padding: 10px 6px;
  border-bottom: 1px dashed rgba(224, 169, 109, .3);
}
.row-icon { width: 36px; height: 30px; object-fit: contain; flex: none; }
.info { flex: 1; min-width: 0; }
.name-zh { font-weight: 800; font-size: 16px; }
.name-en { font-size: 12px; color: var(--muted); }
.ingredients { font-size: 12px; color: #d9c3a5; margin-top: 3px; line-height: 1.5; }
.row-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: none; }

/* ---------- 图鉴 ---------- */
.progress { height: 8px; background: #1a1010; border: 1px solid var(--amber-dark); border-radius: 2px; margin-bottom: 10px; }
.progress-fill { height: 100%; background: var(--amber); }
.collection-body { overflow-y: auto; flex: 1; min-height: 0; -webkit-overflow-scrolling: touch; }
.coll-section { margin: 10px 0 6px; font-weight: 800; color: #ffd98a; font-size: 14px; letter-spacing: 2px; }
.coll-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.coll-card {
  font: inherit; color: var(--text); text-align: center; background: var(--panel-2);
  border: 2px solid var(--amber-dark); border-radius: 4px; padding: 10px 4px 8px; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 3px; min-height: 104px;
}
button.coll-card:active { transform: translateY(2px); }
.coll-card.locked { background: #1a1315; border-color: #3a2e32; cursor: default; color: #5c4d52; }
.coll-card.locked .name-zh { color: #6a5a60; letter-spacing: 3px; }
.card-icon { width: 44px; height: 36px; object-fit: contain; margin-bottom: 2px; }
.coll-card .name-zh { font-size: 14px; }
.coll-card .name-en { font-size: 10px; line-height: 1.2; }

/* ---------- 对话框（RPG 风格） ---------- */
.dialogue-layer { z-index: 30; align-items: flex-end; padding-bottom: calc(14px + env(safe-area-inset-bottom)); cursor: pointer; }
.dialogue { position: relative; width: min(96vw, 720px); min-height: 150px; padding: 14px 16px 12px; background: #1b1216; }
.dlg-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 8px; font-size: 13px; }
.dlg-speaker { background: var(--amber); color: #1a1010; font-weight: 800; padding: 1px 8px; border-radius: 3px; }
.dlg-drink { color: var(--muted); }
.dlg-text { font-size: 18px; line-height: 1.7; min-height: 92px; }
.dlg-foot { display: flex; justify-content: space-between; align-items: center; color: var(--muted); font-size: 12px; }
.dlg-arrow { color: #ffd98a; font-size: 16px; animation: blink .8s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.dlg-skip {
  font: inherit; font-size: 12px; color: var(--muted);
  background: none; border: 1px solid #4a3a30; border-radius: 3px; padding: 4px 8px; cursor: pointer; min-height: 28px;
}

/* ---------- 提示 ---------- */
#toasts {
  position: fixed; top: 52px; left: 0; right: 0; z-index: 15; display: flex; flex-direction: column;
  align-items: center; gap: 6px; pointer-events: none;
}
.toast {
  background: rgba(27, 18, 22, .94); border: 2px solid var(--amber); border-radius: 4px; padding: 8px 14px;
  font-weight: 700; text-align: center; max-width: 92vw; animation: toast-in .25s ease-out; transition: opacity .5s;
  box-shadow: 0 3px 0 #120a0c;
}
.toast.out { opacity: 0; }
.toast-sub { font-size: 12px; color: var(--muted); font-weight: 400; margin-top: 2px; }
@keyframes toast-in { from { transform: translateY(-10px); opacity: 0; } }

/* ============================================================
   响应式
   ============================================================ */
/* 宽屏（电脑）：在场名单常驻右上角，"在场"按钮隐藏 */
@media (min-width: 900px) {
  .btn-presence { display: none; }
  .presence-panel { display: block !important; }
}
/* 窄屏（手机）：在场名单默认收起，点"在场"按钮展开，标题隐藏 */
@media (max-width: 899px) {
  .presence-panel { display: none; right: 50%; transform: translateX(50%); top: auto; bottom: calc(76px + env(safe-area-inset-bottom)); width: min(92vw, 340px); }
  .presence-panel.open { display: block; }
  .hud-title {
  z-index: 1; font-size: 15px; left: 12px; top: 12px; }
  .hud-bar .btn { min-width: 0; flex: 1; padding: 10px 14px; }
  .hud-bar { width: min(94vw, 420px); }
  .modal { width: 96vw; max-height: 88dvh; padding: 12px; }
  .dlg-text { font-size: 17px; min-height: 100px; }
  #toasts { top: 42px; }
  .tab small { display: none; }
}

/* ============================================================
   第二版新增：移动控制 / 地点名牌 / 邀请卡 / 更多名字牌样式
   ============================================================ */
#labels { transition: opacity .3s; }
#labels.hidden { opacity: 0; }
.tag-door { color: #ffd98a; border-color: rgba(255, 217, 138, .6); background: rgba(40, 24, 14, .82); font-size: 11px; }
.tag-sign {
  font-size: 15px; letter-spacing: 3px; color: #ffd0e8; background: rgba(40, 8, 30, .6); border-color: var(--pink);
  text-shadow: 0 0 6px var(--pink), 0 0 12px var(--pink);
}

/* 互动按钮：电脑上在底部按钮栏上方居中；手机上在右下方，拇指够得着 */
.interact-btn {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(76px + env(safe-area-inset-bottom));
  z-index: 13; display: flex; align-items: center; gap: 10px; font-size: 16px; padding: 10px 18px;
  animation: pop .18s ease-out;
}
.interact-btn[hidden] { display: none; }
.interact-btn .key {
  display: inline-block; min-width: 24px; height: 24px; line-height: 24px; text-align: center; border-radius: 4px;
  background: #ffd98a; color: #2a1810; font-size: 13px; font-weight: 900;
}
@keyframes pop { from { transform: translateX(-50%) translateY(6px); opacity: 0; } }

/* 屏幕方向键（触屏 / 窄屏才显示） */
.dpad { display: none; position: fixed; left: 14px; bottom: calc(80px + env(safe-area-inset-bottom)); width: 138px; height: 138px; z-index: 13; }
.dpad-btn {
  position: absolute; width: 46px; height: 46px; font-size: 18px; color: var(--text); touch-action: none;
  background: rgba(42, 29, 26, .85); border: 2px solid var(--amber); border-radius: 6px; padding: 0; user-select: none; -webkit-user-select: none;
}
.dpad-btn.on { background: var(--amber); color: #1a1010; }
.dpad-up { left: 46px; top: 0; } .dpad-down { left: 46px; top: 92px; }
.dpad-left { left: 0; top: 46px; } .dpad-right { left: 92px; top: 46px; }
@media (pointer: coarse), (max-width: 899px) {
  .dpad { display: block; }
  .interact-btn { left: auto; right: 14px; transform: none; bottom: calc(96px + env(safe-area-inset-bottom)); min-width: 128px; min-height: 52px; animation: none; }
}

/* 进场时的地点名牌 */
.location {
  position: fixed; top: 12px; left: 50%; transform: translateX(-50%) translateY(-8px); z-index: 14; pointer-events: none;
  padding: 6px 16px; font-weight: 800; letter-spacing: 2px; color: #ffd98a; opacity: 0; white-space: nowrap;
  background: rgba(20, 12, 14, .88); border: 2px solid var(--amber); border-radius: 4px; box-shadow: 0 3px 0 #120a0c;
  transition: opacity .4s, transform .4s;
}
.location { text-align: center; }
.location-sub { margin-top: 3px; font-size: 12px; font-weight: 500; letter-spacing: 1px; color: var(--text); opacity: .85; }
.location.show { opacity: 1; transform: translateX(-50%) translateY(0); }
@media (max-width: 899px) { .location { top: 44px; font-size: 14px; padding: 5px 12px; } #toasts { top: 84px; } }
@media (min-width: 900px) { #toasts { top: 58px; } }

/* "走进故事"邀请卡 */
.offer-layer { z-index: 25; align-items: flex-end; padding-bottom: calc(100px + env(safe-area-inset-bottom)); background: rgba(10, 5, 8, .25); pointer-events: auto; }
.offer { width: min(92vw, 380px); padding: 14px 16px; text-align: center; background: #241829; border-color: #c9a0ff; animation: pop2 .25s ease-out; }
.offer-tag { display: inline-block; background: #c9a0ff; color: #1a1020; font-size: 11px; font-weight: 800; padding: 1px 8px; border-radius: 3px; }
.offer-title { font-size: 20px; font-weight: 800; margin: 8px 0 2px; color: #f0dcff; letter-spacing: 2px; }
.offer-sub { font-size: 12px; color: var(--muted); margin-bottom: 12px; }
.offer-actions { display: flex; gap: 10px; justify-content: center; }
.offer-actions .btn-primary { background: #7a4ab8; border-color: #e0c8ff; }
@keyframes pop2 { from { transform: translateY(10px); opacity: 0; } }

.start-cancel { background: none; border: none; color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; padding: 4px; }

/* 声音开关：电脑在标题右边，手机在左上角标题下 */
.sound-btn {
  position: fixed; left: 172px; top: 8px; z-index: 12; min-height: 0; width: 38px; height: 34px; padding: 0;
  font-size: 16px; line-height: 1; background: rgba(42, 29, 26, .85);
}
@media (max-width: 899px) { .sound-btn { left: auto; right: 12px; top: 8px; } }

/* 过场短片：全屏黑底，视频等比居中；右下角"跳过" */
.cutscene-layer { z-index: 40; background: #000; display: grid; place-items: center; pointer-events: auto; }
.cutscene-video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.cutscene-title {
  position: fixed; left: 16px; top: calc(12px + env(safe-area-inset-top)); color: rgba(240, 228, 204, .55);
  font-size: 13px; letter-spacing: 2px; pointer-events: none;
}
.cutscene-skip {
  position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); min-height: 40px; padding: 8px 16px;
  background: rgba(30, 22, 20, .7); border-color: rgba(224, 169, 109, .7); font-size: 15px;
}
.offer-actions { flex-wrap: wrap; }

/* ============================================================
   外勤报告画板 · 报告卡片 · 提交表单 · 事务司护照
   ============================================================ */
.modal-body { overflow-y: auto; overscroll-behavior: contain; min-height: 0; }
.board-modal { width: min(96vw, 780px); max-height: 92dvh; background: #3a2618; border-color: #c99a62; }
.board-modal .modal-head h2 { color: #ffe2b0; }
.board-loading, .board-empty { padding: 28px 10px; text-align: center; color: var(--muted); }
.board-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 8px; }
.board-actions .btn { min-height: 40px; padding: 8px 14px; }
.board-admin-link { margin-left: auto; background: none; border: 0; color: var(--muted); font: inherit; font-size: 12px; text-decoration: underline; cursor: pointer; }
.board-frozen { color: var(--warn); font-size: 13px; }
.board-topic {
  display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-bottom: 8px; padding: 8px 10px;
  background: #5a2a1e; border: 2px dashed #ffd98a; border-radius: 3px; font-size: 14px;
}
.board-topic b { color: #ffd98a; letter-spacing: 1px; }
.board-topic span { color: #f0d8c0; font-size: 12px; }
.board-tabs .tab { font-size: 15px; }

/* 地图：小画布放大，保持像素颗粒 */
.board-map { position: relative; width: 100%; margin: 4px 0 12px; border: 3px solid #1a1010; box-shadow: 0 0 0 2px #c99a62; background: #111; overflow: hidden; }
.board-map-img { display: block; width: 100%; height: auto; image-rendering: pixelated; cursor: crosshair; }
.map-label { position: absolute; transform: translate(-50%, -50%); font-size: 11px; color: rgba(255, 226, 176, .7); pointer-events: none; text-shadow: 0 1px 0 #000; white-space: nowrap; }
.map-note { position: absolute; right: 6px; bottom: 4px; font-size: 10px; color: rgba(255, 255, 255, .35); pointer-events: none; }

/* 拍立得 */
.polaroid {
  --tilt: 0deg; position: relative; display: inline-flex; flex-direction: column; align-items: stretch; gap: 3px;
  padding: 5px 5px 6px; background: #f4efe2; border: 0; cursor: pointer; transform: rotate(var(--tilt)); font: inherit;
  box-shadow: 2px 2px 0 #1a1010, 4px 4px 0 rgba(0, 0, 0, .35); transition: transform .12s;
}
.polaroid:hover, .polaroid:focus-visible { transform: rotate(0deg) scale(1.05); z-index: 3; outline: none; }
.polaroid img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: #2a1d1a; image-rendering: auto; }
.polaroid .pin { position: absolute; left: 50%; top: -5px; width: 9px; height: 9px; margin-left: -4px; background: #c4302b; box-shadow: inset -2px -2px 0 #7a1a14, 0 1px 0 #000; }
.polaroid.gold { background: #f6e0a0; box-shadow: 0 0 0 2px #d4a548, 2px 2px 0 2px #1a1010; }
.polaroid.pinned .pin { background: #ffd98a; box-shadow: inset -2px -2px 0 #b8860b, 0 0 6px #ffd98a; }
.pol-cap { font-size: 12px; color: #2a1d1a; font-weight: 700; text-align: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pol-sample { position: absolute; right: 4px; top: 4px; font-size: 10px; font-weight: 800; color: #1a1010; background: var(--warn); padding: 0 4px; border-radius: 2px; }
.polaroid.mini { position: absolute; width: 42px; padding: 3px 3px 7px; transform: translate(-50%, -100%) rotate(var(--tilt)); }
.polaroid.mini:hover { transform: translate(-50%, -100%) scale(1.6); }
.pol-strip { display: flex; gap: 14px; overflow-x: auto; padding: 10px 4px 14px; scroll-snap-type: x proximity; }
.pol-strip .polaroid { flex: 0 0 132px; scroll-snap-align: start; }
.pol-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 16px 12px; padding: 10px 4px; }

/* 世界地图上的小旗 */
.flag { position: absolute; transform: translate(-1px, -100%); width: 22px; height: 22px; border: 0; padding: 0; background: none; cursor: pointer; }
.flag-pole { position: absolute; left: 0; bottom: 0; width: 2px; height: 22px; background: #1a1010; }
.flag-cloth { position: absolute; left: 2px; top: 0; min-width: 16px; height: 12px; padding: 0 3px; font-size: 9px; line-height: 12px; font-weight: 800; color: #1a1010; background: #ffd98a; box-shadow: 1px 1px 0 #1a1010; }
.flag.hot .flag-cloth { background: #ff7a6a; }
.country-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { font: inherit; font-size: 13px; color: var(--text); background: #2a1d1a; border: 2px solid var(--amber-dark); border-radius: 3px; padding: 4px 8px; cursor: pointer; }
.chip small { opacity: .7; margin-left: 4px; }
.chip.hot { border-color: #ff7a6a; }
.country-head { display: flex; align-items: center; gap: 10px; margin: 2px 0 4px; }
.country-head .btn { min-height: 34px; padding: 4px 10px; }
.country-head b { color: #ffd98a; font-size: 17px; }
.country-head span { color: var(--muted); font-size: 13px; }

/* 报告卡片 */
.report-card-modal { width: min(94vw, 460px); }
.rc-photo.polaroid.big { display: block; transform: rotate(-1deg); padding: 8px 8px 22px; margin: 4px auto 10px; cursor: default; }
.rc-photo.polaroid.big:hover { transform: rotate(-1deg); }
.rc-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 4px; }
.tag-mini.sample { background: var(--warn); color: #1a1010; margin: 0; }
.tag-mini.gold { background: #d4a548; color: #1a1010; margin: 0; }
.tag-mini.topic { background: #ff7a6a; color: #1a1010; margin: 0; }
.rc-bar { font-size: 22px; font-weight: 900; color: #ffd98a; letter-spacing: 1px; }
.rc-place { color: var(--text); font-size: 14px; margin-top: 2px; }
.rc-addr { color: var(--muted); font-size: 12px; margin-top: 2px; line-height: 1.5; }
.rc-meta { display: flex; justify-content: space-between; align-items: center; margin: 10px 0 6px; font-size: 13px; color: var(--muted); }
.rc-agent { font: inherit; font-weight: 800; color: #ffb3d1; background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline dotted; }
.rc-row { font-size: 14px; display: flex; gap: 8px; }
.rc-row b { color: var(--amber); }
.rc-review { margin: 8px 0; font-size: 15px; line-height: 1.6; color: #f6e7cf; }
.rc-actions { display: flex; gap: 10px; margin: 12px 0 8px; }
.rc-react { flex: 1; display: flex; justify-content: center; gap: 8px; }
.rc-react.on { background: #7a4ab8; border-color: #e0c8ff; }
.rc-count { opacity: .8; font-weight: 400; }
.rc-maps { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.rc-maps .btn { min-height: 36px; padding: 6px 12px; font-size: 14px; text-decoration: none; }

/* 提交表单 */
.submit-modal { width: min(96vw, 640px); }
.sub-grid { display: grid; grid-template-columns: 200px 1fr; gap: 14px; }
.sub-preview { display: flex; align-items: center; justify-content: center; min-height: 160px; color: #5a4a3a; font-size: 13px; transform: rotate(-2deg); }
.sub-preview.empty { border: 2px dashed #a08060; }
.sub-preview img { width: 100%; aspect-ratio: auto; max-height: 220px; object-fit: contain; }
.hidden-file { display: none; }
.sub-fields { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.f-label { font-size: 13px; color: #ffd98a; font-weight: 700; margin-top: 4px; }
.f-label i { font-style: normal; font-size: 11px; color: #1a1010; background: var(--warn); padding: 0 4px; border-radius: 2px; margin-left: 4px; }
.f-in { font: inherit; font-size: 15px; color: var(--text); background: #1a1010; border: 2px solid var(--amber-dark); border-radius: 3px; padding: 8px 10px; min-width: 0; width: 100%; }
.f-in:focus { outline: none; border-color: #ffd98a; }
.f-in[readonly] { opacity: .75; }
.f-pair { display: flex; gap: 6px; }
.f-pair .f-in { flex: 1; }
.sugg { display: flex; flex-direction: column; gap: 3px; }
.sugg-hint { font-size: 12px; color: var(--muted); }
.sugg-hint.ok { color: var(--ok); }
.gps-use { display: flex; gap: 6px; align-items: flex-start; cursor: pointer; line-height: 1.4; }
.gps-use input { margin-top: 2px; }
.consent { display: flex; gap: 8px; align-items: flex-start; margin: 12px 0 6px; padding: 8px 10px; font-size: 13px; line-height: 1.5; background: #3a2418; border: 2px solid var(--warn); border-radius: 3px; cursor: pointer; }
.consent input { margin-top: 3px; width: 18px; height: 18px; flex: none; }
.sub-foot { display: flex; justify-content: flex-end; align-items: center; gap: 10px; margin-top: 8px; }
.form-err { flex: 1; color: var(--warn); font-size: 13px; }
.sub-note { margin-top: 8px; font-size: 11px; color: var(--muted); }
.topic-modal { width: min(94vw, 460px); }
.topic-modal .f-in { margin-bottom: 6px; }

/* 事务司护照 */
.passport-modal { width: min(94vw, 520px); background: #1e2638; border-color: #9ab0d8; }
.passport-modal .modal-head h2 { color: #d8e4ff; }
.pp-cover { display: flex; gap: 14px; align-items: center; padding: 12px; margin-bottom: 10px; background: #151b2a; border: 2px solid #4a5a80; }
.pp-emblem { width: 52px; height: 52px; flex: none; display: grid; place-items: center; font-size: 30px; color: #d4a548; border: 3px double #d4a548; }
.pp-org { font-size: 12px; color: #9ab0d8; letter-spacing: 2px; }
.pp-name { font-size: 22px; font-weight: 900; color: #fff; display: flex; gap: 6px; align-items: center; }
.pp-sum { font-size: 13px; color: #b8c4e0; margin-top: 2px; }
.pp-section { margin: 12px 0; }
.pp-title { font-size: 14px; font-weight: 800; color: #d8e4ff; margin-bottom: 8px; border-bottom: 2px dashed #4a5a80; padding-bottom: 4px; }
.pp-title span { color: #9ab0d8; font-weight: 400; }
.pp-stamps { display: flex; flex-wrap: wrap; gap: 12px; padding: 4px; }
.pp-empty { color: #8a96b8; font-size: 13px; }
.stamp {
  --ink: #c4302b; --tilt: 0deg; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  color: var(--ink); transform: rotate(var(--tilt)); opacity: .92; padding: 6px;
  /* 像素描边：用阶梯状的阴影代替圆滑边框 */
  box-shadow: 0 -3px 0 0 var(--ink), 0 3px 0 0 var(--ink), -3px 0 0 0 var(--ink), 3px 0 0 0 var(--ink);
}
.stamp-city { width: 76px; height: 76px; border-radius: 50%; box-shadow: 0 0 0 3px var(--ink), inset 0 0 0 2px #1e2638, inset 0 0 0 4px var(--ink); }
.stamp-country { min-width: 84px; height: 54px; }
.stamp-gold { min-width: 110px; min-height: 60px; color: #ffd98a; background: rgba(212, 165, 72, .12); box-shadow: 0 -3px 0 0 #d4a548, 0 3px 0 0 #d4a548, -3px 0 0 0 #d4a548, 3px 0 0 0 #d4a548, 0 0 12px rgba(212, 165, 72, .5); }
.stamp-text { font-weight: 900; font-size: 14px; line-height: 1.2; word-break: break-word; }
.stamp-sub { font-size: 10px; opacity: .85; margin-top: 2px; }
.pp-foot { font-size: 11px; color: #8a96b8; margin-top: 8px; }

@media (max-width: 600px) {
  .sub-grid { grid-template-columns: 1fr; }
  .sub-preview { min-height: 120px; transform: none; }
  .pol-strip .polaroid { flex-basis: 112px; }
  .polaroid.mini { width: 32px; }
  .rc-bar { font-size: 19px; }
  .board-actions .btn { flex: 1; }
}
