/* 多语言电子菜单（P1）· 移动优先 · 无障碍（对比/字号）· 弱网可用
 * 色调方案（P1.1）：六套固定调色板，通过根元素 data-theme 切换。
 * 默认 :root = 中国红；各 [data-theme] 块覆盖同一组 CSS 变量。
 * 固定палitра（不随系统深浅色翻转）以保证品牌一致。见 SXCY_Themes。 */

:root,
[data-theme="chinese-red"] {
  --sxcy-bg: #faf7f2; --sxcy-fg: #1f1a15;
  --sxcy-header-bg: #8c1c13; --sxcy-header-fg: #ffffff;
  --sxcy-accent: #8c1c13; --sxcy-card: #ffffff;
  --sxcy-line: #eadfce; --sxcy-muted: #6b6257;
  --sxcy-tag-bg: #fdeee7; --sxcy-tag-fg: #a8432a; --sxcy-tag-border: #f3cbbb;
}
[data-theme="ink-wash"] {
  --sxcy-bg: #f6f5f2; --sxcy-fg: #20242a;
  --sxcy-header-bg: #2b2f36; --sxcy-header-fg: #f5f3ee;
  --sxcy-accent: #3a4048; --sxcy-card: #ffffff;
  --sxcy-line: #e2e0da; --sxcy-muted: #6a6f75;
  --sxcy-tag-bg: #eceae5; --sxcy-tag-fg: #4a4f56; --sxcy-tag-border: #d8d5cd;
}
[data-theme="celadon"] {
  --sxcy-bg: #f3f6f2; --sxcy-fg: #1f2a24;
  --sxcy-header-bg: #4a7c59; --sxcy-header-fg: #f4faf4;
  --sxcy-accent: #3f7a55; --sxcy-card: #ffffff;
  --sxcy-line: #dbe6dd; --sxcy-muted: #5f6f66;
  --sxcy-tag-bg: #e6f0e8; --sxcy-tag-fg: #3f6b4d; --sxcy-tag-border: #c7ddcc;
}
[data-theme="gold-noir"] {
  --sxcy-bg: #16130f; --sxcy-fg: #ece2cf;
  --sxcy-header-bg: #0f0d0a; --sxcy-header-fg: #e9cf92;
  --sxcy-accent: #c8a45a; --sxcy-card: #211c15;
  --sxcy-line: #3a3226; --sxcy-muted: #a3937a;
  --sxcy-tag-bg: #2a2114; --sxcy-tag-fg: #d9b877; --sxcy-tag-border: #4a3c24;
}
[data-theme="amber"] {
  --sxcy-bg: #fdf8f1; --sxcy-fg: #2a2018;
  --sxcy-header-bg: #c2410c; --sxcy-header-fg: #fff6ee;
  --sxcy-accent: #d1500f; --sxcy-card: #ffffff;
  --sxcy-line: #f0e3d3; --sxcy-muted: #7a6a5b;
  --sxcy-tag-bg: #fdecdd; --sxcy-tag-fg: #b1481a; --sxcy-tag-border: #f4d3b5;
}
[data-theme="slate"] {
  --sxcy-bg: #f4f6f8; --sxcy-fg: #1c2530;
  --sxcy-header-bg: #334155; --sxcy-header-fg: #f2f6fa;
  --sxcy-accent: #2563a8; --sxcy-card: #ffffff;
  --sxcy-line: #e2e8ee; --sxcy-muted: #64748b;
  --sxcy-tag-bg: #e7eef6; --sxcy-tag-fg: #2f5a86; --sxcy-tag-border: #cddcec;
}

/* —— 渲染模板（版式层）· data-template 切换；与 data-theme（色系）正交组合 ——
 * 默认 = modern。模板只改字体族/标题装饰/分隔线/留白/圆角，颜色仍由色系决定。见 SXCY_Templates。 */
:root {
  --sxcy-font-body: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  /* modern（现代）标题用几何无衬线 Manrope；正文保持系统栈（弱网/性能）。 */
  --sxcy-font-display: "Manrope", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  --sxcy-card-radius: 12px;
  --sxcy-h2-tracking: normal;
}

.sxcy-body {
  margin: 0;
  background: var(--sxcy-bg, #faf7f2);
  color: var(--sxcy-fg, #1f1a15);
  font-family: var(--sxcy-font-body);
  -webkit-text-size-adjust: 100%;
}

.sxcy-app {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 0 48px;
  min-height: 100vh;
}
.sxcy-app.sxcy-embed { min-height: 0; padding-bottom: 12px; }

/* —— Header —— */
.sxcy-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--sxcy-header-bg, #8c1c13);
  color: var(--sxcy-header-fg, #fff);
  padding: 14px 16px 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,.15);
}
.sxcy-venue { font-size: 22px; font-weight: 700; letter-spacing: .5px; font-family: var(--sxcy-font-display); }
.sxcy-tablectx { margin-top: 6px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.sxcy-table-badge {
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.4);
  border-radius: 999px;
  padding: 2px 12px;
  font-size: 14px;
  font-weight: 600;
}
.sxcy-table-area { font-size: 13px; opacity: .9; }

/* —— Language switcher —— */
.sxcy-langbar { margin-top: 10px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.sxcy-lang {
  appearance: none;
  border: 1px solid rgba(255,255,255,.5);
  background: transparent;
  color: var(--sxcy-header-fg, #fff);
  border-radius: 999px;
  padding: 5px 14px;
  font-size: 14px;
  min-height: 34px;
  cursor: pointer;
  transition: background .15s;
}
.sxcy-lang:hover { background: rgba(255,255,255,.15); }
.sxcy-lang-active { background: var(--sxcy-header-fg, #fff); color: var(--sxcy-header-bg, #8c1c13); font-weight: 700; border-color: var(--sxcy-header-fg, #fff); }

/* 语言下拉选择器 */
.sxcy-langsel-wrap {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(255,255,255,.5);
  border-radius: 999px;
  padding: 3px 10px 3px 12px;
  background: transparent;
  min-height: 34px;
  cursor: pointer;
  transition: background .15s;
}
.sxcy-langsel-wrap:hover { background: rgba(255,255,255,.15); }
.sxcy-langsel-icon { font-size: 14px; line-height: 1; opacity: .9; }
.sxcy-langsel {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: transparent;
  color: var(--sxcy-header-fg, #fff);
  font-size: 14px;
  line-height: 1.2;
  padding: 2px 18px 2px 2px;
  cursor: pointer;
  /* 自绘下拉箭头（用 header 前景色） */
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: right 6px center, right 1px center;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
.sxcy-langsel:focus { outline: 2px solid var(--sxcy-header-fg, #fff); outline-offset: 2px; }
/* 展开的选项在多数浏览器由系统渲染，强制深色文字保证可读 */
.sxcy-langsel option { color: #1d2327; background: #fff; }

/* 色调切换器（顾客可选） */
.sxcy-theme-toggle {
  appearance: none;
  margin-left: auto;
  border: 1px solid rgba(255,255,255,.5);
  background: transparent;
  color: var(--sxcy-header-fg, #fff);
  border-radius: 999px;
  width: 34px; height: 34px;
  font-size: 16px;
  cursor: pointer;
  line-height: 1;
}
.sxcy-theme-toggle:hover { background: rgba(255,255,255,.15); }
.sxcy-themebar { width: 100%; display: none; gap: 8px; flex-wrap: wrap; margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(255,255,255,.2); }
.sxcy-themebar.sxcy-open { display: flex; }
.sxcy-swatch {
  appearance: none; cursor: pointer;
  border: 2px solid transparent; border-radius: 8px;
  padding: 3px; background: rgba(255,255,255,.1);
  display: inline-flex; flex-direction: column; align-items: center; gap: 3px;
  min-width: 52px;
}
.sxcy-swatch-chips { display: flex; border-radius: 4px; overflow: hidden; width: 44px; height: 22px; }
.sxcy-swatch-chips i { flex: 1; display: block; }
.sxcy-swatch-name { font-size: 10px; color: var(--sxcy-header-fg, #fff); opacity: .9; }
.sxcy-swatch-active { border-color: var(--sxcy-header-fg, #fff); background: rgba(255,255,255,.22); }

/* —— Sections —— */
.sxcy-main { padding: 8px 16px 0; }
.sxcy-section { margin: 20px 0; }
.sxcy-h2 {
  font-size: 17px;
  font-weight: 700;
  font-family: var(--sxcy-font-display);
  letter-spacing: var(--sxcy-h2-tracking, normal);
  color: var(--sxcy-accent, #8c1c13);
  border-bottom: 2px solid var(--sxcy-accent, #8c1c13);
  padding-bottom: 6px;
  margin: 0 0 12px;
}

/* —— Dish rows —— */
.sxcy-dishlist { list-style: none; margin: 0; padding: 0; }
.sxcy-dish {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--sxcy-line, #eadfce);
}
.sxcy-dish-img {
  width: 68px; height: 68px;
  object-fit: cover;
  border-radius: 10px;
  flex: 0 0 auto;
  background: #eee;
}
.sxcy-dish-body { flex: 1 1 auto; min-width: 0; }
.sxcy-dish-line { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.sxcy-dish-name { font-size: 16px; font-weight: 600; line-height: 1.35; font-family: var(--sxcy-font-display); }
.sxcy-dish-price { font-size: 15px; font-weight: 700; color: var(--sxcy-accent, #8c1c13); white-space: nowrap; }
.sxcy-dish-note { font-size: 13px; color: var(--sxcy-muted, #6b6257); margin-top: 3px; line-height: 1.4; }

/* —— Tags —— */
.sxcy-tag { display: inline-block; font-size: 11px; line-height: 1.6; border-radius: 4px; padding: 0 5px; margin-left: 5px; vertical-align: middle; }
.sxcy-tag-spicy { background: transparent; padding: 0; }
.sxcy-allergens { display: inline-flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.sxcy-tag-allergen { background: var(--sxcy-tag-bg, #fdeee7); color: var(--sxcy-tag-fg, #a8432a); border: 1px solid var(--sxcy-tag-border, #f3cbbb); }
.sxcy-tag-allergen.sxcy-tag-may { opacity: .8; border-style: dashed; }
/* 分面徽章：膳食适宜 / 菜系 */
.sxcy-facets { display: inline-flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; margin-right: 6px; }
.sxcy-facets .sxcy-tag { margin-left: 0; }
.sxcy-tag-diet { background: #e6f4ea; color: #1e6b3a; border: 1px solid #bfe3cb; }
.sxcy-tag-cuisine { background: #eef1f7; color: #3a4a76; border: 1px solid #cdd6ea; }

/* —— L0 呈现层：区块供应时段 —— */
.sxcy-section-note { margin: 2px 0 8px; font-size: 13px; color: var(--sxcy-muted, #6b6b6b); }
.sxcy-avail { display: inline-block; font-size: 12px; font-weight: 500; margin-left: 8px; padding: 1px 8px; border-radius: 999px; vertical-align: middle; }
.sxcy-avail-on { background: #e6f4ea; color: #1e6b3a; }
.sxcy-avail-off { background: #f0eee9; color: #8a8477; }
.sxcy-section-off { opacity: .62; }

/* —— Set menus —— */
.sxcy-set-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.sxcy-set {
  border: 1px solid var(--sxcy-line, #eadfce);
  border-radius: var(--sxcy-card-radius, 12px);
  background: var(--sxcy-card, #fff);
  padding: 14px 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.sxcy-set-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.sxcy-set-name { font-size: 17px; margin: 0; font-weight: 700; font-family: var(--sxcy-font-display); }
.sxcy-set-price { font-size: 18px; font-weight: 800; color: var(--sxcy-accent, #8c1c13); white-space: nowrap; }
.sxcy-perperson { font-size: 12px; font-weight: 500; color: var(--sxcy-muted, #6b6257); margin-left: 2px; }
.sxcy-set-note { font-size: 13px; color: var(--sxcy-muted, #6b6257); margin: 6px 0 8px; }
.sxcy-set-items { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 4px 14px; }
.sxcy-set-items li { font-size: 14px; padding-left: 14px; position: relative; line-height: 1.5; }
.sxcy-set-items li::before { content: "·"; position: absolute; left: 2px; color: var(--sxcy-accent, #8c1c13); font-weight: 700; }

/* —— Footer / states —— */
.sxcy-footer { text-align: center; font-size: 12px; color: var(--sxcy-muted, #9a8f80); margin-top: 28px; padding: 0 16px; }
.sxcy-error, .sxcy-empty { padding: 40px 16px; text-align: center; color: var(--sxcy-muted, #6b6257); }
.sxcy-loading { opacity: .55; transition: opacity .15s; }

@media (min-width: 560px) {
  .sxcy-set-grid { grid-template-columns: 1fr 1fr; }
}

/* 色调为固定品牌палitра（不随系统深浅色翻转）；如需暗色，选「鎏金」主题。 */

/* ── P2 · 点餐 ── */
.sxcy-dish-actions, .sxcy-set-actions { margin-top: 8px; }
.sxcy-set-actions { text-align: right; }
.sxcy-add {
  appearance: none; cursor: pointer;
  border: 1.5px solid var(--sxcy-accent, #8c1c13); background: transparent;
  color: var(--sxcy-accent, #8c1c13); font-weight: 600; font-size: 14px;
  border-radius: 999px; padding: 5px 16px; min-height: 34px;
}
.sxcy-add:active { background: var(--sxcy-accent, #8c1c13); color: #fff; }

.sxcy-noscroll { overflow: hidden; }

/* 悬浮购物车条 */
.sxcy-cartbar {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: 14px; z-index: 40;
  width: min(92%, 680px);
  display: none; align-items: center; justify-content: space-between;
  background: var(--sxcy-accent, #8c1c13); color: #fff;
  border-radius: 999px; padding: 12px 20px; cursor: pointer;
  box-shadow: 0 6px 20px rgba(0,0,0,.28); font-size: 15px;
  transition: transform .12s;
}
.sxcy-cartbar.sxcy-bump { transform: translateX(-50%) scale(1.04); }
.sxcy-cartbar-count { display: inline-block; min-width: 22px; height: 22px; line-height: 22px; text-align: center; background: #fff; color: var(--sxcy-accent, #8c1c13); border-radius: 999px; font-weight: 700; margin-right: 4px; }
.sxcy-cartbar-cta { font-weight: 700; }

/* 结算浮层 */
.sxcy-overlay { position: fixed; inset: 0; z-index: 50; display: none; background: rgba(0,0,0,.45); }
.sxcy-overlay.sxcy-open { display: flex; align-items: flex-end; justify-content: center; }
.sxcy-sheet {
  width: 100%; max-width: 680px; max-height: 92vh; overflow-y: auto;
  background: var(--sxcy-bg, #faf7f2); color: var(--sxcy-fg, #1f1a15);
  border-radius: 18px 18px 0 0; padding: 18px 18px 28px;
  box-shadow: 0 -6px 24px rgba(0,0,0,.25);
}
@media (min-width: 560px) { .sxcy-overlay.sxcy-open { align-items: center; } .sxcy-sheet { border-radius: 16px; max-height: 88vh; } }
.sxcy-sheet-head { display: flex; justify-content: space-between; align-items: center; }
.sxcy-sheet-head h2 { margin: 4px 0; font-size: 18px; color: var(--sxcy-accent, #8c1c13); }
.sxcy-close { appearance: none; border: none; background: transparent; font-size: 20px; cursor: pointer; color: var(--sxcy-muted, #6b6257); }
.sxcy-co-table { font-size: 13px; color: var(--sxcy-muted, #6b6257); margin: 0 0 8px; }

.sxcy-co-item { border-bottom: 1px solid var(--sxcy-line, #eadfce); padding: 10px 0; }
.sxcy-co-top { display: flex; justify-content: space-between; gap: 10px; }
.sxcy-co-name { font-weight: 600; }
.sxcy-co-price { font-weight: 700; color: var(--sxcy-accent, #8c1c13); white-space: nowrap; }
.sxcy-co-ctrls { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; align-items: center; }
.sxcy-qtybox { display: inline-flex; align-items: center; border: 1px solid var(--sxcy-line, #eadfce); border-radius: 999px; background: var(--sxcy-card, #fff); }
.sxcy-q { appearance: none; border: none; background: transparent; width: 34px; height: 34px; font-size: 18px; cursor: pointer; color: var(--sxcy-accent, #8c1c13); }
.sxcy-qn { min-width: 26px; text-align: center; font-weight: 600; }
.sxcy-co-spicy, .sxcy-co-avoid { min-height: 34px; border: 1px solid var(--sxcy-line, #eadfce); border-radius: 8px; padding: 4px 8px; background: var(--sxcy-card, #fff); color: var(--sxcy-fg, #1f1a15); }
.sxcy-co-avoid { flex: 1; min-width: 120px; }

.sxcy-co-fields { margin: 14px 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sxcy-co-field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.sxcy-co-field.sxcy-co-wide { grid-column: 1 / -1; }
.sxcy-co-field input { min-height: 36px; border: 1px solid var(--sxcy-line, #eadfce); border-radius: 8px; padding: 4px 10px; background: var(--sxcy-card, #fff); color: var(--sxcy-fg, #1f1a15); }
.sxcy-co-voucher { grid-column: 1 / -1; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.sxcy-co-voucher input { flex: 1; min-width: 140px; min-height: 36px; border: 1px solid var(--sxcy-line, #eadfce); border-radius: 8px; padding: 4px 10px; background: var(--sxcy-card, #fff); color: var(--sxcy-fg, #1f1a15); }
.sxcy-vbtn { appearance: none; cursor: pointer; border: 1px solid var(--sxcy-accent, #8c1c13); background: transparent; color: var(--sxcy-accent, #8c1c13); border-radius: 8px; padding: 6px 14px; min-height: 36px; }
.sxcy-vok { color: #2e7d32; font-size: 13px; }
.sxcy-verr { color: #b3261e; font-size: 13px; }

/* ======================================================================
 * 渲染模板（版式层）· data-template；与色系（data-theme）自由组合。
 * modern = 上文默认。以下为 classic / chinese / french / japanese 的覆盖。
 * ====================================================================== */

/* —— 经典 Classic：拉丁衬线 · 居中花饰标题 · 典雅 —— */
[data-template="classic"] {
  /* 经典 · 西式高对比衬线：标题 Playfair Display，正文 Lora。 */
  --sxcy-font-display: "Playfair Display", Georgia, "Times New Roman", "Iowan Old Style", "Palatino Linotype", "Songti SC", "Noto Serif CJK SC", serif;
  --sxcy-font-body: "Lora", Georgia, "Times New Roman", "Songti SC", "Noto Serif CJK SC", serif;
  --sxcy-card-radius: 6px;
  --sxcy-h2-tracking: .03em;
}
[data-template="classic"] .sxcy-venue { font-weight: 600; letter-spacing: 1px; }
[data-template="classic"] .sxcy-h2 {
  text-align: center; border-bottom: 0; font-weight: 600;
  display: flex; align-items: center; gap: 12px; justify-content: center;
}
[data-template="classic"] .sxcy-h2::before,
[data-template="classic"] .sxcy-h2::after {
  content: ""; height: 1px; flex: 1 1 auto; max-width: 72px;
  background: currentColor; opacity: .45;
}
[data-template="classic"] .sxcy-dish-price,
[data-template="classic"] .sxcy-set-price { font-weight: 700; }

/* —— 中华 Chinese：宋体 · 印章方点标题 · 双线 —— */
[data-template="chinese"] {
  /* 中华 · 中文宋体：标题正文 Noto Serif SC（思源宋体），店名另用毛笔体 Ma Shan Zheng（见下）。 */
  --sxcy-font-display: "Noto Serif SC", "Songti SC", "STSong", SimSun, "Noto Serif CJK SC", "Source Han Serif SC", Georgia, serif;
  --sxcy-font-body: "Noto Serif SC", "Songti SC", "STSong", SimSun, "Noto Serif CJK SC", Georgia, serif;
  --sxcy-card-radius: 3px;
  --sxcy-h2-tracking: .06em;
}
[data-template="chinese"] .sxcy-venue { letter-spacing: 3px; font-family: "Ma Shan Zheng", "Noto Serif SC", "Songti SC", "STSong", serif; font-weight: 400; }
[data-template="chinese"] .sxcy-h2 {
  border-bottom: 3px double var(--sxcy-accent, #8c1c13);
  padding-left: 16px; position: relative; padding-bottom: 7px;
}
[data-template="chinese"] .sxcy-h2::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-60%);
  width: 9px; height: 9px; background: var(--sxcy-accent, #8c1c13); border-radius: 1px;
}

/* —— 法式 French：衬线 · 小型大写居中 · 点线菜列（à la carte）—— */
[data-template="french"] {
  /* 法式 · 优雅法式衬线：标题 Cormorant Garamond，正文 EB Garamond。 */
  --sxcy-font-display: "Cormorant Garamond", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Songti SC", serif;
  --sxcy-font-body: "EB Garamond", "Palatino Linotype", Palatino, Georgia, "Songti SC", serif;
  --sxcy-card-radius: 0px;
  --sxcy-h2-tracking: .22em;
}
[data-template="french"] .sxcy-venue { font-weight: 500; letter-spacing: 2px; }
[data-template="french"] .sxcy-h2 {
  text-align: center; text-transform: uppercase; font-size: 13.5px; font-weight: 600;
  color: var(--sxcy-fg, #1f1a15);
  border-top: 1px solid var(--sxcy-line, #eadfce);
  border-bottom: 1px solid var(--sxcy-line, #eadfce);
  padding: 7px 0; margin: 0 0 14px;
}
[data-template="french"] .sxcy-dish { border-bottom: 1px dotted var(--sxcy-line, #eadfce); }
[data-template="french"] .sxcy-dish-name { font-weight: 600; }
[data-template="french"] .sxcy-dish-note { font-style: italic; }
[data-template="french"] .sxcy-dish-price,
[data-template="french"] .sxcy-set-price { font-weight: 600; }
[data-template="french"] .sxcy-set { box-shadow: none; }

/* —— 和风 Japanese：明朝体 · 疏朗 · 左竖线标题 —— */
[data-template="japanese"] {
  /* 和风 · 日式明朝体 Shippori Mincho。 */
  --sxcy-font-display: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", YuMincho, "Songti SC", "Noto Serif CJK JP", serif;
  --sxcy-font-body: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", YuMincho, "Songti SC", "Noto Serif CJK JP", serif;
  --sxcy-card-radius: 0px;
  --sxcy-h2-tracking: .12em;
}
[data-template="japanese"] .sxcy-main { padding-top: 12px; }
[data-template="japanese"] .sxcy-section { margin: 30px 0; }
[data-template="japanese"] .sxcy-venue { font-weight: 500; letter-spacing: 4px; }
[data-template="japanese"] .sxcy-h2 {
  border-bottom: 0; border-left: 3px solid var(--sxcy-accent, #8c1c13);
  padding: 2px 0 2px 12px; font-weight: 500; color: var(--sxcy-fg, #1f1a15);
}
[data-template="japanese"] .sxcy-dish { border-bottom: 1px solid var(--sxcy-line, #eadfce); padding: 14px 0; }
[data-template="japanese"] .sxcy-set { box-shadow: none; border-width: 1px; }

/* —— 版式切换器（沿用色调切换器视觉，独立一栏）—— */
.sxcy-tplbar { width: 100%; display: none; gap: 8px; flex-wrap: wrap; margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(255,255,255,.2); }
.sxcy-tplbar.sxcy-open { display: flex; }
.sxcy-tpl {
  appearance: none; cursor: pointer;
  border: 1.5px solid rgba(255,255,255,.35); border-radius: 999px;
  background: rgba(255,255,255,.08); color: var(--sxcy-header-fg, #fff);
  font-size: 13px; padding: 4px 14px; min-height: 32px;
}
.sxcy-tpl-active { background: var(--sxcy-header-fg, #fff); color: var(--sxcy-header-bg, #8c1c13); font-weight: 700; border-color: var(--sxcy-header-fg, #fff); }
.sxcy-tpl-toggle {
  appearance: none; cursor: pointer; line-height: 1;
  border: 1px solid rgba(255,255,255,.5); background: transparent;
  color: var(--sxcy-header-fg, #fff); border-radius: 999px;
  width: 34px; height: 34px; font-size: 16px;
}
.sxcy-tpl-toggle:hover { background: rgba(255,255,255,.15); }

.sxcy-co-totals { border-top: 1px solid var(--sxcy-line, #eadfce); padding-top: 10px; }
.sxcy-co-totals > div { display: flex; justify-content: space-between; padding: 3px 0; font-size: 14px; }
.sxcy-co-disc span:last-child { color: #2e7d32; }
.sxcy-co-total { font-size: 17px; font-weight: 800; color: var(--sxcy-accent, #8c1c13); border-top: 1px dashed var(--sxcy-line, #eadfce); margin-top: 4px; padding-top: 6px; }
.sxcy-co-pay { font-size: 12px; color: var(--sxcy-muted, #6b6257); margin: 8px 0; text-align: center; }
.sxcy-co-actions { display: flex; gap: 10px; margin-top: 12px; }
.sxcy-co-back { flex: 0 0 auto; appearance: none; cursor: pointer; border: 1px solid var(--sxcy-line, #eadfce); background: var(--sxcy-card, #fff); color: var(--sxcy-fg, #1f1a15); border-radius: 10px; padding: 12px 18px; }
.sxcy-co-place { flex: 1; appearance: none; cursor: pointer; border: none; background: var(--sxcy-accent, #8c1c13); color: #fff; font-weight: 700; font-size: 16px; border-radius: 10px; padding: 12px; }
.sxcy-co-place:disabled { opacity: .6; }

.sxcy-cf-ok { font-size: 20px; font-weight: 800; color: #2e7d32; text-align: center; margin: 6px 0 10px; }
.sxcy-cf-no, .sxcy-cf-status, .sxcy-cf-sched { text-align: center; margin: 4px 0; }
.sxcy-cf-items { margin: 12px 0; }
.sxcy-cf-item { display: flex; justify-content: space-between; padding: 4px 0; border-bottom: 1px solid var(--sxcy-line, #eadfce); font-size: 14px; }

/* P6 内质旋机 · 五行平衡徽章（前门，仅守护性通过·五相俱全时显示） */
.sxcy-wuxing{display:inline-flex;align-items:center;gap:6px;margin:6px 0 2px;padding:3px 10px;border-radius:999px;background:rgba(0,0,0,.05);font-size:12px}
.sxcy-wuxing .sxcy-wx-dot{width:9px;height:9px;border-radius:50%;display:inline-block}
.sxcy-wuxing .sxcy-wx-dot.p-water{background:#1e3a8a}
.sxcy-wuxing .sxcy-wx-dot.p-wood{background:#166534}
.sxcy-wuxing .sxcy-wx-dot.p-fire{background:#991b1b}
.sxcy-wuxing .sxcy-wx-dot.p-earth{background:#92400e}
.sxcy-wuxing .sxcy-wx-dot.p-metal{background:#a16207}
.sxcy-wuxing .sxcy-wuxing-label{margin-left:2px;opacity:.85;letter-spacing:.02em}

/* 预订配送（0.23.0） */
.sxcy-dbar { margin: 12px 0 16px; padding: 10px 12px; border: 1px solid var(--sxcy-line, #eadfce); border-radius: 10px; background: var(--sxcy-card, #fff); }
.sxcy-dbar label { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-weight: 600; }
.sxcy-dbar select, .sxcy-co-field select { min-height: 36px; border: 1px solid var(--sxcy-line, #eadfce); border-radius: 8px; padding: 4px 8px; background: var(--sxcy-card, #fff); color: var(--sxcy-fg, #1f1a15); }
.sxcy-dnote { margin: 8px 0 0; font-size: 13px; color: var(--sxcy-accent, #8c1c13); }
.sxcy-left { margin-right: 8px; font-size: 12px; color: var(--sxcy-muted, #6b6257); }
.sxcy-soldout .sxcy-dish-name, .sxcy-soldout .sxcy-dish-price { opacity: .5; }
.sxcy-add[disabled] { opacity: .55; cursor: not-allowed; background: transparent; }
.sxcy-dwhen { margin: 0; }
.sxcy-dlab { display: block; font-size: 13px; margin-bottom: 4px; }
.sxcy-dpays { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.sxcy-dpay { font-size: 14px; }
.sxcy-dpayinfo { margin: 12px 0; padding: 10px 12px; border: 1px dashed var(--sxcy-line, #eadfce); border-radius: 10px; }
.sxcy-dpaytext { white-space: pre-wrap; font: inherit; margin: 6px 0; }
.sxcy-dpayqr { display: block; max-width: 220px; margin: 8px auto; }
.sxcy-co-fields > .sxcy-co-wide { grid-column: 1 / -1; }
.sxcy-co-fields > div.sxcy-co-wide:empty { display: none; }
.sxcy-co-field select { width: 100%; }
/* 就餐方式（堂食／预订配送）切换：0.24.0 */
.sxcy-modebar { display: flex; gap: 6px; margin: 12px 0 4px; padding: 4px; border: 1px solid var(--sxcy-line, #eadfce); border-radius: 12px; background: var(--sxcy-card, #fff); }
.sxcy-mode { flex: 1; min-height: 40px; border: 0; border-radius: 9px; background: transparent; color: var(--sxcy-fg, #1f1a15); font: inherit; font-weight: 600; cursor: pointer; }
.sxcy-mode-on { background: var(--sxcy-accent, #b0182b); color: #fff; }

/* 0.35.0 固定交付时段的地点单选 */
.sxcy-dpoints { display: grid; gap: .5rem; margin-top: .35rem; }
.sxcy-dpoint { display: flex; gap: .55rem; align-items: flex-start; padding: .6rem .75rem; border: 1px solid rgba(0,0,0,.15); border-radius: 10px; cursor: pointer; }
.sxcy-dpoint input { margin-top: .25rem; }
.sxcy-dpoint.sxcy-off { opacity: .5; cursor: not-allowed; }
