/* ===========================================================================
   月神Luna —— 全站樣式
   ---------------------------------------------------------------------------
   視覺主軸：夜空、月光金、銀白。三個館各有一個代表色：
     電子遊戲 紫（--c-slots）；我的最愛的愛心是玫瑰紅（--c-rose）。Luna 只有電子遊戲（2026-11-01）
   斷點：< 768 手機、768–1023 平板、≥ 1024 電腦。手機與平板用底部選單，電腦用頁首選單。
   =========================================================================== */

/* ---------- 1. 設計變數 ---------- */
:root {
  --bg-0: #05070f;
  --bg-1: #0a0f22;
  --bg-2: #10183a;
  --bg-3: #172150;
  --line: rgba(160, 176, 255, 0.12);
  --line-strong: rgba(160, 176, 255, 0.24);
  --text: #eef1fb;
  --text-2: #b9c1dd;
  --muted: #7f89b0;

  --gold-1: #fff3cf;
  --gold-2: #f2cf7e;
  --gold-3: #c99a3e;
  --moon: #dfe7ff;
  --grad-gold: linear-gradient(135deg, #fff3cf 0%, #f2cf7e 42%, #c99a3e 100%);
  --grad-panel: linear-gradient(180deg, rgba(25, 35, 78, 0.78), rgba(13, 19, 44, 0.78));

  --c-slots: #8f7dff;
  --c-rose: #ff5d8f;
  --ok: #3ddc97;
  --warn: #ffb547;
  --bad: #ff5a6a;

  --radius-s: 10px;
  --radius: 16px;
  --radius-l: 24px;
  --shadow: 0 14px 40px rgba(0, 0, 0, 0.45);
  --header-h: 64px;
  --tabbar-h: 62px;
  --safe-b: env(safe-area-inset-bottom, 0px);

  --font-sans: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
  --font-serif: "Noto Serif TC", "Songti TC", serif;
  --font-latin: "Cinzel", "Times New Roman", serif;
  color-scheme: dark;
}

/* ---------- 2. 基本設定 ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; -webkit-tap-highlight-color: transparent; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg-0);
  color: var(--text);
  font: 400 15px/1.7 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* 星空：固定在背後，不跟著捲動 */
body::before, body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
}
body::before {
  background:
    radial-gradient(1px 1px at 24px 36px, rgba(255, 255, 255, 0.7), transparent 70%),
    radial-gradient(1px 1px at 132px 92px, rgba(255, 255, 255, 0.45), transparent 70%),
    radial-gradient(1.6px 1.6px at 212px 168px, rgba(255, 238, 196, 0.65), transparent 70%),
    radial-gradient(1px 1px at 292px 44px, rgba(255, 255, 255, 0.5), transparent 70%),
    radial-gradient(1px 1px at 350px 228px, rgba(210, 220, 255, 0.45), transparent 70%),
    radial-gradient(1.2px 1.2px at 74px 210px, rgba(255, 255, 255, 0.35), transparent 70%);
  background-size: 380px 270px;
  opacity: 0.55;
}
body::after {
  background:
    radial-gradient(900px 620px at 88% -12%, rgba(143, 125, 255, 0.2), transparent 62%),
    radial-gradient(760px 560px at -12% 34%, rgba(47, 214, 195, 0.07), transparent 60%),
    radial-gradient(900px 700px at 50% 120%, rgba(255, 93, 143, 0.06), transparent 60%);
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.3; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 2px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
.num { font-variant-numeric: tabular-nums; }

.container { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 768px) { .container { padding: 0 24px; } }

/* 底部選單的空間由頁尾留（.site-footer 的 padding-bottom），main 不用再留一次 */
main { display: block; padding-bottom: 8px; }
@media (min-width: 1024px) { main { padding-bottom: 40px; } }

.icon { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon--fill { fill: currentColor; stroke: none; }
.gold-text { background: var(--grad-gold); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- 3. 按鈕、標籤、輸入框 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 22px; border-radius: 999px;
  font-weight: 700; font-size: 15px; letter-spacing: 0.02em; white-space: nowrap;
  transition: transform 0.15s ease, filter 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  user-select: none;
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn[disabled] { opacity: 0.45; cursor: not-allowed; }
.btn-sm { height: 36px; padding: 0 16px; font-size: 14px; }
.btn-lg { height: 52px; padding: 0 28px; font-size: 16px; }
.btn-block { width: 100%; }
.btn-gold { background: var(--grad-gold); color: #2b1d04; box-shadow: 0 6px 22px rgba(242, 207, 126, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.6); }
.btn-gold:hover { filter: brightness(1.07); }
.btn-ghost { border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.03); color: var(--text); }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(242, 207, 126, 0.5); }
.btn-text { height: auto; padding: 0; color: var(--gold-2); font-weight: 500; }
.btn-text:hover { text-decoration: underline; }
.btn-venue { background: var(--vc, var(--c-slots)); color: #fff; box-shadow: 0 8px 24px color-mix(in srgb, var(--vc, var(--c-slots)) 35%, transparent); }
.btn-venue:hover { filter: brightness(1.08); }
.btn .icon { width: 18px; height: 18px; }

.badge {
  display: inline-flex; align-items: center; gap: 4px;
  height: 22px; padding: 0 8px; border-radius: 999px;
  font-size: 12px; font-weight: 700; line-height: 1; letter-spacing: 0.03em; white-space: nowrap;
}
.badge-hot { background: linear-gradient(135deg, #ff7a9c, #ff3f6e); color: #fff; }
.badge-new { background: linear-gradient(135deg, #a898ff, #6d5cff); color: #fff; }
.badge-flag { background: var(--grad-gold); color: #2b1d04; }
.badge-soft { background: rgba(255, 255, 255, 0.08); color: var(--text-2); border: 1px solid var(--line); }
.badge-ok { background: rgba(61, 220, 151, 0.14); color: var(--ok); }
.badge-warn { background: rgba(255, 181, 71, 0.14); color: var(--warn); }

.chips { position: relative; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 0 6px; -webkit-overflow-scrolling: touch; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; height: 36px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(255, 255, 255, 0.03);
  color: var(--text-2); font-size: 14px; font-weight: 500; white-space: nowrap;
  transition: all 0.15s ease;
}
.chip:hover { color: var(--text); border-color: var(--line-strong); }
.chip.is-active { background: var(--grad-gold); color: #2b1d04; border-color: transparent; font-weight: 700; }
.chip:disabled { opacity: 0.4; cursor: not-allowed; }
.chip .count { opacity: 0.6; margin-left: 4px; font-size: 12px; }
.chip .icon { width: 15px; height: 15px; vertical-align: -2px; margin-right: 2px; }

.field { display: grid; gap: 6px; }
.field > span { font-size: 13px; color: var(--text-2); font-weight: 500; }
.input {
  width: 100%; height: 48px; padding: 0 16px;
  border-radius: 12px; border: 1px solid var(--line-strong);
  background: rgba(5, 8, 20, 0.6); color: var(--text); font-size: 16px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.input::placeholder { color: var(--muted); }
.input:focus { outline: none; border-color: var(--gold-2); box-shadow: 0 0 0 3px rgba(242, 207, 126, 0.15); }
.input-group { position: relative; display: flex; align-items: center; }
.input-group .input { padding-right: 120px; }
.input-group .input-addon { position: absolute; right: 6px; }
.input-prefix { position: absolute; left: 16px; color: var(--muted); font-size: 15px; pointer-events: none; }
.input-group .input.has-prefix { padding-left: 52px; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }

.check { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; color: var(--text-2); cursor: pointer; }
.check input { appearance: none; flex: none; width: 20px; height: 20px; margin: 2px 0 0; border-radius: 6px; border: 1.5px solid var(--line-strong); background: rgba(5, 8, 20, 0.6); display: grid; place-items: center; cursor: pointer; }
.check input:checked { background: var(--grad-gold); border-color: transparent; }
.check input:checked::after { content: ""; width: 10px; height: 6px; border: 2px solid #2b1d04; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
.check a { color: var(--gold-2); }

.toggle { position: relative; width: 48px; height: 28px; flex: none; }
.toggle input { appearance: none; position: absolute; inset: 0; margin: 0; border-radius: 999px; background: rgba(255, 255, 255, 0.12); cursor: pointer; transition: background 0.2s; }
.toggle input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: transform 0.2s; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35); }
.toggle input:checked { background: var(--ok); }
.toggle input:checked::after { transform: translateX(20px); }

.segmented { display: inline-flex; padding: 4px; gap: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); }
.seg { height: 36px; padding: 0 18px; border-radius: 999px; font-weight: 700; font-size: 14px; color: var(--text-2); }
.seg.is-active { background: var(--vc, var(--grad-gold)); color: #fff; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3); }

.card { background: var(--grad-panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04); }
.muted { color: var(--muted); }
.hint { font-size: 13px; color: var(--muted); }
.hint .icon { width: 15px; height: 15px; vertical-align: -3px; margin-right: 4px; }

/* ---------- 4. 預覽提示條、頁首 ---------- */
.preview-bar {
  position: relative; z-index: 51;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 30px; padding: 4px 40px; text-align: center;
  background: linear-gradient(90deg, rgba(143, 125, 255, 0.25), rgba(242, 207, 126, 0.22), rgba(143, 125, 255, 0.25));
  font-size: 12.5px; color: var(--gold-1);
}
.preview-bar button { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; opacity: 0.7; }
.preview-bar button:hover { opacity: 1; background: rgba(255, 255, 255, 0.1); }
.preview-bar .icon { width: 14px; height: 14px; }

/* 頁首、頁尾是 luna.js 填進這兩個空殼裡的；空殼本身不產生框，頁首才能一路黏在畫面最上面 */
#site-top, #site-bottom { display: contents; }
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: rgba(5, 8, 18, 0.72);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.header-inner { height: 100%; display: flex; align-items: center; gap: 24px; }

.brand { display: inline-flex; align-items: center; flex: none; }
.brand-logo { display: block; height: 52px; width: auto; filter: drop-shadow(0 2px 12px rgba(242, 207, 126, 0.18)); }

.main-nav { display: none; align-items: center; gap: 4px; margin-left: 12px; }
.nav-link { position: relative; padding: 8px 14px; border-radius: 999px; color: var(--text-2); font-weight: 500; font-size: 15px; transition: color 0.15s, background 0.15s; }
.nav-link:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.nav-link.is-active { color: var(--gold-2); }
.nav-link.is-active::after { content: ""; position: absolute; left: 50%; bottom: -1px; width: 22px; height: 3px; transform: translateX(-50%); border-radius: 3px; background: var(--grad-gold); box-shadow: 0 0 10px rgba(242, 207, 126, 0.6); }

.header-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.wallet-pill {
  display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 12px 0 6px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.04); border: 1px solid rgba(242, 207, 126, 0.32);
  transition: border-color 0.15s, background 0.15s;
}
.wallet-pill:hover { border-color: var(--gold-2); background: rgba(242, 207, 126, 0.07); }
.wallet-pill__coin { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--grad-gold); color: #2b1d04; }
.wallet-pill__coin .icon { width: 16px; height: 16px; }
.wallet-pill__label { font-size: 12px; color: var(--muted); display: none; }
.wallet-pill__amount { font-weight: 700; font-size: 15px; font-variant-numeric: tabular-nums; }
.wallet-pill .chev { width: 14px; height: 14px; color: var(--muted); }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, #2a3570, #171f48); border: 1px solid var(--line-strong); font-family: var(--font-serif); font-weight: 900; color: var(--gold-2); }
.avatar:hover { border-color: var(--gold-2); }

@media (max-width: 767px) {
  :root { --header-h: 56px; }
  .header-inner { gap: 12px; }
  .brand-logo { height: 40px; }
  .header-actions .btn-sm { height: 34px; padding: 0 13px; font-size: 13.5px; }
  .header-actions .avatar { width: 38px; height: 38px; flex: none; }
}
@media (min-width: 768px) {
  .wallet-pill__label { display: inline; }
}
@media (min-width: 1024px) {
  .main-nav { display: flex; }
}

/* ---------- 5. 手機底部選單 ---------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  height: calc(var(--tabbar-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  background: rgba(7, 10, 22, 0.92);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--line);
}
.tabbar__item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--muted); font-size: 11.5px; font-weight: 500; position: relative; }
.tabbar__item .icon { width: 24px; height: 24px; }
.tabbar__item.is-active { color: var(--gold-2); }
.tabbar__item.is-active::before { content: ""; position: absolute; top: 0; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--grad-gold); box-shadow: 0 0 10px rgba(242, 207, 126, 0.7); }
@media (min-width: 1024px) { .tabbar { display: none; } }

/* ---------- 6. 頁尾 ---------- */
.site-footer { margin-top: 48px; border-top: 1px solid var(--line); background: linear-gradient(180deg, rgba(10, 15, 34, 0.4), rgba(5, 7, 15, 0.95)); padding: 40px 0 calc(var(--tabbar-h) + var(--safe-b) + 24px); }
@media (min-width: 1024px) { .site-footer { padding-bottom: 32px; } }
.footer-top { display: grid; gap: 28px; }
.footer-brand p { margin-top: 14px; color: var(--muted); font-size: 14px; max-width: 360px; }
.footer-safe { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.safe-item { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.02); font-size: 13px; color: var(--text-2); }
.safe-item .icon { width: 18px; height: 18px; color: var(--gold-2); }
.age-badge { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--bad); color: var(--bad); display: grid; place-items: center; font-weight: 900; font-size: 12px; }
.footer-bottom { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); display: grid; gap: 6px; font-size: 12.5px; color: var(--muted); }

/* ---------- 7. 視窗、側邊抽屜、提示訊息 ---------- */
dialog.modal {
  width: min(460px, calc(100vw - 32px)); max-height: calc(100dvh - 48px);
  padding: 0; border: 1px solid var(--line-strong); border-radius: var(--radius-l);
  background: linear-gradient(180deg, #141c40, #0b1028); color: var(--text);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(242, 207, 126, 0.06);
  overflow: hidden;
}
dialog.modal[open] { animation: modal-in 0.22s ease-out; }
dialog.modal::backdrop { background: rgba(2, 4, 12, 0.66); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
@keyframes modal-in { from { opacity: 0; transform: translateY(14px) scale(0.98); } }
.modal__scroll { max-height: calc(100dvh - 48px); overflow-y: auto; overscroll-behavior: contain; }
.modal__body { padding: 28px 24px 24px; }
.modal__close { position: absolute; top: 12px; right: 12px; z-index: 3; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: rgba(5, 8, 20, 0.55); color: var(--text-2); }
.modal__close:hover { color: var(--text); background: rgba(255, 255, 255, 0.1); }
.modal__title { font: 900 22px/1.3 var(--font-serif); }
.modal__lead { margin-top: 6px; color: var(--text-2); font-size: 14px; }
dialog.modal--wide { width: min(720px, calc(100vw - 32px)); }

/* 手機：視窗從底部滑出 */
@media (max-width: 767px) {
  dialog.modal {
    width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 22px 22px 0 0;
    border-left: 0; border-right: 0; border-bottom: 0;
    padding-bottom: var(--safe-b);
  }
  dialog.modal[open] { animation: sheet-in 0.26s cubic-bezier(0.2, 0.8, 0.2, 1); }
  .modal__body { padding: 26px 18px 22px; }
  .modal__scroll { max-height: calc(100dvh - 40px); }
}
@keyframes sheet-in { from { transform: translateY(100%); } }

.form-stack { display: grid; gap: 14px; }
.form-foot { display: flex; justify-content: space-between; align-items: center; font-size: 13.5px; color: var(--muted); }
.divider { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 12.5px; margin: 6px 0; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* 館別圖示、視窗裡的說明框 */
.venue-head { display: flex; align-items: center; gap: 12px; }
.venue-icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: color-mix(in srgb, var(--vc) 22%, transparent); color: var(--vc); border: 1px solid color-mix(in srgb, var(--vc) 40%, transparent); flex: none; }
.venue-icon .icon { width: 26px; height: 26px; }
.note-box { margin-top: 16px; padding: 12px 14px; border-radius: 12px; background: rgba(242, 207, 126, 0.07); border: 1px solid rgba(242, 207, 126, 0.18); font-size: 14px; color: var(--text-2); }
.note-box .icon { width: 16px; height: 16px; vertical-align: -3px; margin-right: 4px; color: var(--gold-2); }
.modal-actions { display: grid; gap: 10px; margin-top: 18px; }

/* 錢包抽屜 */
.drawer-backdrop { position: fixed; inset: 0; z-index: 70; background: rgba(2, 4, 12, 0.6); backdrop-filter: blur(4px); opacity: 0; pointer-events: none; transition: opacity 0.2s; }
.drawer { position: fixed; z-index: 71; top: 0; right: 0; bottom: 0; width: min(380px, 100vw); background: linear-gradient(180deg, #141c40, #090d22); border-left: 1px solid var(--line-strong); box-shadow: var(--shadow); transform: translateX(100%); transition: transform 0.26s cubic-bezier(0.2, 0.8, 0.2, 1); display: flex; flex-direction: column; }
.drawer.is-open { transform: none; }
.drawer.is-open + .drawer-backdrop, .drawer-backdrop.is-open { opacity: 1; pointer-events: auto; }
.drawer__head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.drawer__head h3 { font: 900 19px var(--font-serif); }
.drawer__body { padding: 20px; overflow-y: auto; flex: 1; display: grid; gap: 14px; align-content: start; }
.main-balance { padding: 18px; border-radius: 18px; background: radial-gradient(120% 140% at 100% 0%, rgba(242, 207, 126, 0.22), transparent 55%), linear-gradient(135deg, #1d2758, #121a40); border: 1px solid rgba(242, 207, 126, 0.25); }
.main-balance small { color: var(--text-2); font-size: 13px; }
.main-balance .big { display: block; font-size: 32px; font-weight: 900; letter-spacing: 0.01em; font-variant-numeric: tabular-nums; margin-top: 2px; }
.vb-list { display: grid; gap: 8px; }
.vb-item { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--line); }
.vb-item .venue-icon { width: 38px; height: 38px; border-radius: 11px; }
.vb-item .venue-icon .icon { width: 20px; height: 20px; }
.vb-item__text { flex: 1; min-width: 0; }
.vb-item__text small { display: block; color: var(--muted); font-size: 12.5px; }
.vb-item__text b { font-variant-numeric: tabular-nums; }

.toasts { position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + var(--safe-b) + 14px); transform: translateX(-50%); z-index: 90; display: grid; gap: 8px; width: min(420px, calc(100vw - 32px)); pointer-events: none; }
@media (min-width: 1024px) { .toasts { bottom: 28px; } }
.toast { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: 14px; background: rgba(20, 28, 64, 0.96); border: 1px solid var(--line-strong); box-shadow: var(--shadow); font-size: 14px; animation: toast-in 0.25s ease-out; pointer-events: auto; }
.toast .icon { color: var(--gold-2); }
.toast--ok .icon { color: var(--ok); }
.toast--warn .icon { color: var(--warn); }
.toast.is-leaving { opacity: 0; transform: translateY(8px); transition: all 0.25s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } }

/* ---------- 8. 區塊標題、公告 ---------- */
.section { margin-top: 40px; }
@media (min-width: 768px) { .section { margin-top: 56px; } }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.section-title { display: flex; align-items: center; gap: 10px; font: 900 clamp(20px, 2.4vw, 27px)/1.25 var(--font-serif); letter-spacing: 0.04em; }
.section-title .icon { width: 22px; height: 22px; color: var(--gold-2); }
.section-sub { color: var(--muted); font-size: 14px; margin-top: 4px; }
.section-more { display: inline-flex; align-items: center; gap: 4px; color: var(--gold-2); font-size: 14px; font-weight: 500; white-space: nowrap; }
.section-more .icon { width: 16px; height: 16px; }
.section-more:hover { text-decoration: underline; }

.notice-bar { display: flex; align-items: center; gap: 10px; height: 42px; padding: 0 14px; margin-top: 16px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.025); overflow: hidden; }
.notice-bar > .icon { color: var(--gold-2); }
.notice-track { flex: 1; overflow: hidden; white-space: nowrap; mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.notice-track span { display: inline-block; padding-left: 100%; animation: marquee 32s linear -5s infinite; font-size: 14px; color: var(--text-2); }
.notice-track span b { color: var(--gold-2); font-weight: 500; }
@keyframes marquee { to { transform: translateX(-100%); } }

.page-hero { position: relative; padding: 28px 0 8px; }
.page-hero h1 { font: 900 clamp(28px, 4vw, 44px)/1.15 var(--font-serif); letter-spacing: 0.04em; }
.page-hero p { color: var(--text-2); margin-top: 8px; max-width: 640px; }
.eyebrow { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; letter-spacing: 0.12em; color: var(--gold-2); text-transform: uppercase; }
.eyebrow::before { content: ""; width: 18px; height: 1.5px; background: currentColor; }

/* ---------- 9. 首頁輪播 ---------- */
.hero { position: relative; margin-top: 16px; }
.hero__viewport { position: relative; touch-action: pan-y; height: 300px; border-radius: var(--radius-l); overflow: hidden; border: 1px solid var(--line); background: var(--bg-1); box-shadow: var(--shadow); }
@media (min-width: 768px) { .hero__viewport { height: 380px; } }
@media (min-width: 1024px) { .hero__viewport { height: 440px; } }
.hero-slide { position: absolute; inset: 0; opacity: 0; visibility: hidden; transition: opacity 0.8s ease, visibility 0.8s; }
.hero-slide.is-active { opacity: 1; visibility: visible; }
.hero-slide__bg { position: absolute; inset: 0; background-size: cover; background-position: center; transform: scale(1.06); transition: transform 7s ease-out; }
.hero-slide.is-active .hero-slide__bg { transform: scale(1); }
.hero-slide__shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(5, 7, 15, 0.92) 0%, rgba(5, 7, 15, 0.62) 38%, rgba(5, 7, 15, 0.05) 70%), linear-gradient(0deg, rgba(5, 7, 15, 0.75) 0%, transparent 45%); }
.hero-slide__figure { position: absolute; right: 2%; bottom: 0; height: 104%; width: auto; max-width: none; object-fit: contain; filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5)); transform: translateX(16px); opacity: 0; transition: transform 1s ease 0.15s, opacity 1s ease 0.15s; }
.hero-slide.is-active .hero-slide__figure { transform: none; opacity: 1; }
.hero-slide__content { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 10px; padding: 0 22px 34px; max-width: 620px; }
@media (min-width: 768px) { .hero-slide__content { padding: 0 48px 30px; } }
@media (min-width: 1024px) { .hero-slide__content { padding: 0 48px 30px 84px; max-width: 680px; } }
.hero-slide__logo { width: min(320px, 62vw); height: auto; filter: drop-shadow(0 6px 20px rgba(0, 0, 0, 0.6)); }
.hero-slide__title { font: 900 clamp(30px, 5vw, 54px)/1.1 var(--font-serif); letter-spacing: 0.04em; text-shadow: 0 4px 24px rgba(0, 0, 0, 0.6); }
.hero-slide__lead { color: var(--text-2); font-size: clamp(14px, 1.6vw, 17px); max-width: 460px; text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8); }
.hero-slide__actions { display: flex; gap: 10px; margin-top: 8px; flex-wrap: wrap; }
@media (max-width: 767px) {
  /* 人物整個露出來：不往右推出畫面（原本 -14% 會切掉黑帝斯這種拿長兵器、人在圖右邊的） */
  .hero-slide__figure { right: -2%; height: 96%; }
  .hero-slide__logo { width: min(250px, 58vw); }
  .hero-slide__lead { max-width: 62%; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .hero-slide__actions .btn-lg { height: 44px; padding: 0 18px; font-size: 14.5px; }
}
.hero__dots { position: absolute; left: 0; right: 0; bottom: 14px; z-index: 3; display: flex; justify-content: center; gap: 8px; }
.hero__dot { width: 8px; height: 8px; border-radius: 999px; background: rgba(255, 255, 255, 0.35); transition: all 0.3s; }
.hero__dot.is-active { width: 26px; background: var(--grad-gold); }
.hero__arrow { position: absolute; top: 50%; z-index: 3; width: 44px; height: 44px; margin-top: -22px; border-radius: 50%; display: none; place-items: center; background: rgba(5, 8, 20, 0.5); border: 1px solid var(--line-strong); color: var(--text); transition: background 0.15s; }
.hero__arrow:hover { background: rgba(5, 8, 20, 0.85); }
.hero__arrow--prev { left: 14px; }
.hero__arrow--next { right: 14px; }
@media (min-width: 1024px) { .hero__arrow { display: grid; } }

/* ---------- 12. 遊戲方塊 ---------- */
.game-row { display: grid; grid-auto-flow: column; grid-auto-columns: 136px; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-bottom: 4px; margin: 0 -16px; padding-left: 16px; padding-right: 16px; scroll-padding: 0 16px; }
.game-row::-webkit-scrollbar { display: none; }
.game-row > * { scroll-snap-align: start; }
@media (min-width: 768px) { .game-row { grid-auto-columns: 168px; gap: 16px; margin: 0; padding: 0 0 4px; } }
.row-wrap { position: relative; }

.game-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 12px; }
@media (min-width: 560px) { .game-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .game-grid { grid-template-columns: repeat(5, 1fr); gap: 20px 16px; } }
@media (min-width: 1200px) { .game-grid { grid-template-columns: repeat(6, 1fr); } }

.game-tile { position: relative; min-width: 0; }
.game-tile__media { position: relative; aspect-ratio: 1; border-radius: 16px; overflow: hidden; background: var(--bg-2); border: 1px solid var(--line); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3); transition: transform 0.2s ease, box-shadow 0.2s, border-color 0.2s; }
.game-tile__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.game-tile__open { position: absolute; inset: 0; z-index: 1; }
.game-tile__badges { position: absolute; left: 8px; top: 8px; z-index: 2; display: flex; flex-wrap: wrap; gap: 4px; pointer-events: none; }
/* 手機的遊戲方塊小，標籤縮小一點，兩個標籤擠得進同一行，不會蓋住遊戲圖 */
@media (max-width: 767px) {
  .game-tile__badges { left: 6px; top: 6px; gap: 3px; }
  .game-tile__badges .badge { height: 20px; padding: 0 6px; font-size: 11px; gap: 2px; }
  .game-tile__badges .badge .icon { width: 12px; height: 12px; }
}
/* 滑鼠移上去才出現；點按鈕開始遊戲，點其他地方看遊戲介紹 */
.game-tile__actions { position: absolute; inset: 0; z-index: 2; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 12px; background: linear-gradient(180deg, rgba(5, 7, 15, 0.25), rgba(5, 7, 15, 0.82)); opacity: 0; pointer-events: none; transition: opacity 0.2s; cursor: pointer; }
.game-tile__actions .btn { width: min(130px, 100%); }
.game-tile__info { display: flex; align-items: flex-start; justify-content: space-between; gap: 6px; padding: 9px 2px 0; }
.game-tile__name { font-size: 14.5px; font-weight: 700; line-height: 1.35; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }
.game-tile__sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* 愛心看起來一樣小，能點的範圍放大到 40px（手機手指好按） */
.fav-btn { flex: none; width: 40px; height: 40px; margin: -9px -9px -6px 0; border-radius: 50%; display: grid; place-items: center; color: var(--muted); }
.fav-btn:hover { color: var(--c-rose); }
.fav-btn.is-on { color: var(--c-rose); }
.fav-btn.is-on .icon { fill: currentColor; }
.fav-btn .icon { width: 18px; height: 18px; }
@media (hover: hover) {
  .game-tile:hover .game-tile__media { transform: translateY(-4px); border-color: rgba(242, 207, 126, 0.55); box-shadow: 0 16px 30px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(242, 207, 126, 0.25); }
  .game-tile:hover .game-tile__media img { transform: scale(1.06); }
  .game-tile:hover .game-tile__actions, .game-tile:focus-within .game-tile__actions { opacity: 1; pointer-events: auto; }
}

/* 遊戲介紹視窗 */
.game-detail__art { position: relative; aspect-ratio: 16 / 9; background: var(--bg-2); }
.game-detail__art img { width: 100%; height: 100%; object-fit: cover; }
.game-detail__art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, #0f1636 0%, transparent 45%); }
.game-detail__body { padding: 4px 24px 24px; margin-top: -26px; position: relative; z-index: 1; }
.game-detail__tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.game-detail__en { font: 600 13px var(--font-latin); letter-spacing: 0.12em; color: var(--muted); margin-top: 2px; }
.game-detail__desc { margin-top: 12px; color: var(--text-2); font-size: 14.5px; }
.jackpot-tiers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 14px; }
.jackpot-tiers div { text-align: center; padding: 8px 4px; border-radius: 10px; background: rgba(242, 207, 126, 0.07); border: 1px solid rgba(242, 207, 126, 0.2); }
.jackpot-tiers small { display: block; font-size: 11.5px; color: var(--muted); }
.jackpot-tiers b { font-size: 15px; color: var(--gold-2); }
/* 愛心＋開始遊戲同一列；手機上黏在視窗底部，不用往下滑找按鈕 */
.game-detail__actions { display: grid; grid-template-columns: auto 1fr; gap: 10px; margin-top: 16px; }
.fav-btn--big { width: 52px; height: 52px; margin: 0; border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.03); }
.fav-btn--big .icon { width: 22px; height: 22px; }
@media (max-width: 767px) {
  .game-detail__body { padding: 4px 18px 0; }
  .game-detail__actions { position: sticky; bottom: 0; z-index: 2; margin: 14px -18px 0; padding: 12px 18px calc(14px + var(--safe-b)); background: linear-gradient(180deg, rgba(11, 16, 40, 0.85), #0b1028 40%); border-top: 1px solid var(--line); }
  dialog.modal--wide { padding-bottom: 0; }
}

/* ---------- 16. 電子遊戲頁 ---------- */
/* 空的清單（遊戲搜尋沒結果、我的最愛是空的…） */
.empty-state { display: grid; justify-items: center; gap: 10px; text-align: center; padding: 48px 20px; border-radius: var(--radius); border: 1px dashed var(--line-strong); color: var(--text-2); }
.empty-state .icon { width: 40px; height: 40px; color: var(--muted); }
.empty-state h3 { font-size: 17px; color: var(--text); }

.slots-toolbar { position: sticky; top: var(--header-h); scroll-margin-top: var(--header-h); z-index: 20; padding: 14px 0 6px; background: linear-gradient(180deg, var(--bg-0) 78%, rgba(5, 7, 15, 0)); }
.toolbar-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.search { position: relative; flex: 1; max-width: 420px; }
@media (max-width: 767px) {
  /* 搜尋和玩法放同一行，少佔一行高度 */
  .toolbar-row { flex-wrap: nowrap; gap: 8px; }
  .search { min-width: 0; max-width: none; }
  .toolbar-row .sort-select { flex: none; width: 118px; padding-right: 32px; background-position: calc(100% - 18px) 18px, calc(100% - 13px) 18px; }
  /* iPhone 的輸入框字小於 16px，一點下去整頁會放大 */
  .toolbar-row .search .input, .toolbar-row .sort-select { font-size: 16px; }
  /* 分類一路滑到螢幕邊，看得出來還能往右滑 */
  .slots-toolbar .chips { margin: 0 -16px; padding-left: 16px; padding-right: 16px; scroll-padding: 0 16px; }
  /* 手機畫面矮，搜尋列和篩選列不要黏在上面佔位置 */
  .slots-toolbar { position: static; }
  .jackpot-banner { padding: 16px; gap: 10px; }
  .jackpot-banner h3 { font-size: 18px; }
  .jackpot-banner p { font-size: 13px; }
}
.search .icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.search .input { height: 42px; padding-left: 42px; border-radius: 999px; font-size: 15px; }
.sort-select { height: 42px; width: auto; border-radius: 999px; font-size: 14px; padding: 0 40px 0 16px; background-position: calc(100% - 20px) 18px, calc(100% - 15px) 18px; }
.to-top { position: fixed; right: 16px; bottom: calc(var(--tabbar-h) + var(--safe-b) + 16px); z-index: 55; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: rgba(20, 28, 64, 0.92); border: 1px solid var(--line-strong); color: var(--gold-2); box-shadow: var(--shadow); }
@media (min-width: 1024px) { .to-top { bottom: 28px; right: 28px; } }
.result-line { display: flex; align-items: center; justify-content: space-between; margin: 14px 0 12px; font-size: 13.5px; color: var(--muted); }
.result-line b { color: var(--text); }
.load-more { display: flex; justify-content: center; margin-top: 24px; }

.jackpot-banner { display: grid; gap: 14px; align-items: center; padding: 18px 20px; border-radius: var(--radius-l); border: 1px solid rgba(242, 207, 126, 0.3); background: radial-gradient(80% 140% at 0% 0%, rgba(242, 207, 126, 0.2), transparent 60%), var(--grad-panel); }
@media (min-width: 900px) { .jackpot-banner { grid-template-columns: auto 1fr auto; padding: 20px 28px; gap: 24px; } }
.jackpot-banner h3 { font: 900 20px var(--font-serif); }
.jackpot-banner p { font-size: 14px; color: var(--text-2); margin-top: 2px; }
.jackpot-banner .flag-thumbs { display: flex; }
.jackpot-banner .flag-thumbs img { width: 52px; height: 52px; border-radius: 12px; border: 2px solid #10183a; margin-left: -10px; box-shadow: 0 6px 14px rgba(0, 0, 0, 0.4); }
.jackpot-banner .flag-thumbs img:first-child { margin-left: 0; }

/* ---------- 17. 會員中心 ---------- */
.member-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; margin-top: 20px; }
@media (min-width: 1024px) { .member-layout { grid-template-columns: 280px minmax(0, 1fr); align-items: start; } }
.member-side { padding: 20px; position: sticky; top: calc(var(--header-h) + 20px); }
@media (max-width: 1023px) { .member-side { position: static; padding: 16px; } }
.member-id { display: flex; align-items: center; gap: 12px; }
.member-id .avatar { width: 52px; height: 52px; font-size: 20px; }
.member-id b { font-size: 17px; }
.member-menu { display: grid; gap: 2px; margin-top: 18px; }
@media (max-width: 1023px) {
  .member-menu { display: flex; overflow-x: auto; gap: 8px; scrollbar-width: none; margin-top: 14px; }
  .member-menu::-webkit-scrollbar { display: none; }
}
.mm-item { display: flex; align-items: center; gap: 12px; height: 46px; padding: 0 14px; border-radius: 12px; color: var(--text-2); font-weight: 500; white-space: nowrap; text-align: left; }
.mm-item:hover { background: rgba(255, 255, 255, 0.04); color: var(--text); }
.mm-item.is-active { background: rgba(242, 207, 126, 0.1); color: var(--gold-2); }
@media (max-width: 1023px) { .mm-item { flex: none; height: 38px; border: 1px solid var(--line); border-radius: 999px; } .mm-item .icon { display: none; } }
/* 手機：四個選項平分一排，「登出」不會被切到畫面外 */
@media (max-width: 767px) {
  .member-menu { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; overflow: visible; }
  .mm-item { justify-content: center; padding: 0 4px; font-size: 14px; }
}
.member-main { display: grid; gap: 16px; min-width: 0; }
.m-panel { padding: 20px; }
.m-panel h2 { font: 900 20px var(--font-serif); margin-bottom: 14px; }
.m-panel h2 small { font: 400 13px var(--font-sans); color: var(--muted); margin-left: 8px; }
.wallet-hero { display: grid; gap: 16px; }
@media (min-width: 768px) { .wallet-hero { grid-template-columns: 1.1fr 1fr; align-items: stretch; } }
.vb-cards { display: grid; gap: 10px; }
.vb-card { --vc: var(--c-slots); display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 14px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--line); }
.vb-card .venue-icon { width: 40px; height: 40px; border-radius: 12px; }
.vb-card .venue-icon .icon { width: 22px; height: 22px; }
.vb-card .grow { flex: 1; min-width: 0; }
.vb-card small { display: block; color: var(--muted); font-size: 12.5px; }
.vb-card b { font-size: 17px; font-variant-numeric: tabular-nums; }

.form-grid { display: grid; gap: 14px; }
@media (min-width: 768px) { .form-grid.two { grid-template-columns: 1fr 1fr; } }
/* 電腦版兩欄排版用的空格，手機上不要佔位置 */
@media (max-width: 767px) { .form-grid > span:empty { display: none; } }
.kv { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--muted); }

.record-list { display: grid; }
.record { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.record:last-child { border-bottom: 0; }
.record .venue-icon { width: 38px; height: 38px; border-radius: 11px; }
.record .venue-icon .icon { width: 19px; height: 19px; }
.record__title { font-weight: 500; font-size: 14.5px; }
.record__time { font-size: 12.5px; color: var(--muted); }
.record__amt { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.record__amt small { display: block; font-weight: 400; font-size: 12px; }
.amt-plus { color: var(--ok); }
.amt-minus { color: var(--text); }


/* ---------- 18. 遊戲視窗 ---------- */
body.play-page { overflow: hidden; height: 100dvh; padding: 0; }
body.play-page main { padding: 0; height: 100dvh; display: flex; flex-direction: column; }
.play-bar { flex: none; height: 52px; display: flex; align-items: center; gap: 12px; padding: 0 12px; background: rgba(5, 8, 18, 0.95); border-bottom: 1px solid var(--line); }
.play-bar__title { font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.play-bar__title small { color: var(--muted); font-weight: 400; margin-left: 6px; }
.play-bar__right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.play-bal { font-size: 13px; color: var(--muted); padding: 0 12px; height: 34px; display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; border: 1px solid var(--line); }
.play-bal b { color: var(--text); font-variant-numeric: tabular-nums; }
.icon-btn { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line); color: var(--text-2); }
.icon-btn:hover { color: var(--gold-2); border-color: var(--gold-2); }
.play-stage { position: relative; flex: 1; background: #000; overflow: hidden; }
.play-stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
/* 手機：遊戲佔滿整個畫面，不疊頁首（供應商建議）。回大廳用一顆小圓鈕，放在靠近左下（不貼死在角落，玩家才找得到）：
   iPhone 橫向時剛好落在遊戲左邊的黑邊裡、動態島下方，不擋遊戲畫面；遊戲左下的按鈕通常在它右邊 */
.play-exit {
  position: absolute; left: 8px; bottom: calc(14% + env(safe-area-inset-bottom)); z-index: 10;
  display: none; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  width: 46px; height: 46px; border-radius: 50%;
  border: 1.5px solid rgba(242, 207, 126, 0.7); background: rgba(5, 8, 18, 0.72);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  color: var(--gold-2); font-size: 10px; font-weight: 700; line-height: 1;
}
.play-exit .icon { width: 16px; height: 16px; }
.play-exit:active { transform: scale(0.94); }
body.play-page main { position: relative; }
@media (max-width: 767px), (orientation: landscape) and (max-height: 500px) {
  .play-bar { display: none; }
  .play-exit { display: flex; }
}
/* 全螢幕時頁首會不見，一樣用小圓鈕回大廳 */
main:fullscreen .play-bar { display: none; }
main:fullscreen .play-exit { display: flex; }

/* 手機全螢幕提示（page-play.js）：Android 點一下、iPhone 往上滑。「大廳」疊在它上面，一直按得到 */
.fs-hint { position: absolute; inset: 0; z-index: 9; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; background: rgba(3, 5, 12, 0.62); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); cursor: pointer; }
.fs-hint__card { display: flex; flex-direction: column; align-items: center; gap: 12px; color: var(--gold-1); font-size: 17px; text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7); }
.fs-hint__icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: rgba(242, 207, 126, 0.14); border: 1.5px solid rgba(242, 207, 126, 0.6); color: var(--gold-2); }
.fs-hint__icon .icon { width: 32px; height: 32px; }
.fs-hint[data-mode="swipe"] .fs-hint__icon { animation: fs-swipe 1.4s ease-in-out infinite; }
.fs-hint[data-mode="tap"] .fs-hint__icon { animation: fs-tap 1.6s ease-in-out infinite; }
@keyframes fs-swipe { 0%, 100% { transform: translateY(14px); opacity: 0.55; } 50% { transform: translateY(-14px); opacity: 1; } }
@keyframes fs-tap { 0%, 100% { transform: scale(1); } 50% { transform: scale(0.88); } }
/* iPhone 橫向：頁面要能往上滑（Safari 才會收起網址列）；遊戲畫面固定在畫面上，不跟著捲走 */
html.ios-swipe, html.ios-swipe body.play-page { height: auto; overflow: visible; }
html.ios-swipe body.play-page { min-height: 220vh; }
html.ios-swipe body.play-page main { position: fixed; inset: 0; height: auto; }
.play-placeholder { position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; }
.play-placeholder__bg { position: absolute; inset: 0; background-size: cover; background-position: center; filter: blur(2px) brightness(0.45); transform: scale(1.04); }
.play-placeholder__card { position: relative; max-width: 440px; padding: 26px 24px; border-radius: var(--radius-l); background: rgba(8, 12, 30, 0.82); border: 1px solid var(--line-strong); backdrop-filter: blur(10px); box-shadow: var(--shadow); }
.play-placeholder__card { width: 100%; }
.play-placeholder__card .btn { white-space: normal; height: auto; min-height: 48px; padding: 10px 18px; }
.play-placeholder__card > .icon { width: 40px; height: 40px; color: var(--gold-2); margin: 0 auto; }
.play-placeholder__card h2 { font: 900 22px var(--font-serif); margin-top: 10px; }
.play-placeholder__card p b { color: var(--gold-2); }
.play-placeholder__card p { color: var(--text-2); font-size: 14px; margin-top: 8px; }
.play-placeholder__card .btn { margin-top: 16px; }
.spinner { width: 42px; height: 42px; margin: 0 auto; border-radius: 50%; border: 3px solid rgba(242, 207, 126, 0.18); border-top-color: var(--gold-2); animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 19. 登入頁 ---------- */
.login-page main { padding: 0; }
.login { min-height: 100dvh; display: grid; grid-template-columns: minmax(0, 1fr); position: relative; }
@media (min-width: 1024px) { .login { grid-template-columns: 1.15fr 0.85fr; } }
.login-card .btn { white-space: normal; }
.login-art { position: relative; overflow: hidden; isolation: isolate; }
@media (max-width: 1023px) { .login-art { position: fixed; inset: 0; opacity: 0.4; } }
.login-reel { position: absolute; inset: -30% -6% -30% -14%; z-index: 0; display: flex; justify-content: center; gap: 18px; transform: rotate(-9deg); }
.login-col { display: flex; flex-direction: column; gap: 18px; width: clamp(130px, 13vw, 190px); flex: none; animation: reel-up 70s linear infinite; }
.login-col--rev { animation-direction: reverse; margin-top: -140px; }
.login-col img { width: 100%; aspect-ratio: 1; border-radius: 20px; border: 1px solid rgba(255, 255, 255, 0.12); box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5); }
@keyframes reel-up { to { transform: translateY(-50%); } }
.login-shade { position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, rgba(5, 7, 15, 0.3) 0%, rgba(5, 7, 15, 0.55) 60%, var(--bg-0) 100%), linear-gradient(0deg, rgba(5, 7, 15, 0.92) 0%, transparent 45%), radial-gradient(60% 50% at 70% 26%, rgba(242, 207, 126, 0.16), transparent 70%); }
@media (max-width: 1023px) { .login-shade { background: rgba(5, 7, 15, 0.55); } }
/* 月神徽記：掛在遊戲圖牆上方，慢慢浮動、光暈一明一暗 */
.login-emblem {
  position: absolute; z-index: 2; right: 8%; top: 7%;
  width: clamp(210px, 25vw, 380px); height: auto;
  filter: drop-shadow(0 0 40px rgba(242, 207, 126, 0.35));
  animation: emblem-float 8s ease-in-out infinite;
}
@keyframes emblem-float { 50% { transform: translateY(-10px); filter: drop-shadow(0 0 60px rgba(242, 207, 126, 0.5)); } }
@media (max-width: 1023px) { .login-emblem { right: -30px; top: -10px; width: 220px; } }
.login-tagline { position: absolute; z-index: 3; left: 8%; bottom: 9%; max-width: 520px; }
.login-tagline h2 { margin-top: 10px; font: 900 clamp(30px, 3.4vw, 46px)/1.25 var(--font-serif); letter-spacing: 0.04em; text-shadow: 0 6px 30px rgba(0, 0, 0, 0.7); }
@media (max-width: 1023px) { .login-tagline { display: none; } }

.login-side { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; padding: 40px 16px calc(28px + var(--safe-b)); }
.login-card { width: min(420px, 100%); padding: 32px 26px 26px; border-radius: 28px; background: linear-gradient(180deg, rgba(22, 30, 68, 0.9), rgba(10, 14, 34, 0.94)); border: 1px solid var(--line-strong); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(242, 207, 126, 0.06); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.login-brand { display: flex; justify-content: center; }
.login-brand img { width: min(290px, 84%); height: auto; filter: drop-shadow(0 4px 24px rgba(242, 207, 126, 0.22)); }
.login-title { margin-top: 24px; font: 900 22px/1.3 var(--font-serif); text-align: center; }
.login-lead { margin: 4px 0 22px; text-align: center; color: var(--text-2); font-size: 14px; }
.login-help { margin-top: 16px; text-align: center; font-size: 13.5px; color: var(--muted); }
.login-legal { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); }
.login-legal .age-badge { width: 26px; height: 26px; font-size: 10.5px; }
.input-group--icon .input { padding-right: 52px; }
.input-group--icon .input-addon { right: 6px; border: 0; }
.form-error { padding: 10px 12px; border-radius: 10px; background: rgba(255, 90, 106, 0.1); border: 1px solid rgba(255, 90, 106, 0.3); color: #ff9aa5; font-size: 13.5px; }

/* ---------- 20. 少動畫模式 ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
  .notice-track span { animation: none; padding-left: 0; }
}
