  :root {
    --frame-a: #26262a; --frame-b: #121214;
    --back-a: #151517;  --back-b: #0a0a0c;
    --floor-a: #1e1e21; --floor-b: #0c0c0e;
    --lip-top: #3a3a3f; --lip-face: #131315;
    --rail-a: #ececf0;  --rail-b: #6a6a72;
    --led: #fff8ea;     --glow: rgba(255, 244, 214, .5);
    --door-a: #17171a;  --door-b: #0e0e10; --door-line: #2e2e33;
    --sign-a: #f2f2f6;  --sign-b: #84848c;
    --card-a: #f7f1e3;  --card-b: #ece2cc; --ink: #2b2419;
  }
  body.theme-wood {
    --frame-a: #6b4a2e; --frame-b: #3f2a16;
    --back-a: #4a3423;  --back-b: #241812;
    --floor-a: #553a22; --floor-b: #2c1c10;
    --lip-top: #c99a5f; --lip-face: #6e4a26;
    --rail-a: #e8c87e;  --rail-b: #8a6428;
    --led: #fff1d6;     --glow: rgba(255, 205, 140, .5);
    --door-a: #5a3c22;  --door-b: #38240f; --door-line: #241708;
    --sign-a: #ffe9bd;  --sign-b: #b0813f;
  }
  * { margin: 0; padding: 0; box-sizing: border-box; }

  /* ========== VIP 櫃體材質主題（Pro 專屬，覆寫上方變數） ========== */
  /* 1. 檜木組子細工 Hinoki Kumiko：淺金檜木 + 麻葉紋組子格 + 和紙透光 + 3000K 暖白光 */
  body.vip-hinoki {
    --frame-a: #c99f5f; --frame-b: #8a6434;
    --back-a: #e6cc9a;  --back-b: #c4a266;
    --floor-a: #d8b678; --floor-b: #a07840;
    --lip-top: #e8c88e; --lip-face: #96703a;
    --rail-a: #8a6428;  --rail-b: #5a4018;
    --led: #fff2d0;     --glow: rgba(255, 214, 150, .55);
    --door-a: #d8b274;  --door-b: #a07840; --door-line: #7a5a28;
    --sign-a: #fff3d0;  --sign-b: #b0813f;
  }
  body.vip-hinoki .shelf { border-color: #8a6434; }
  /* 麻葉紋（Asanoha）組子格：雙層六角星 SVG 交織 + 縱向檜木格柵立柱 + 和紙漫射透光 */
  body.vip-hinoki .back::after {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background:
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='52' height='46'><g fill='none' stroke='%239a7434' stroke-width='1.5' stroke-opacity='.55'><path d='M26 4 L48 42 L4 42 Z'/><path d='M26 42 L4 4 L48 4 Z'/></g></svg>") 0 0 / 52px 46px,
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='52' height='46'><g fill='none' stroke='%239a7434' stroke-width='1.2' stroke-opacity='.3'><path d='M26 4 L48 42 L4 42 Z'/><path d='M26 42 L4 4 L48 4 Z'/></g></svg>") 26px 23px / 52px 46px,
      repeating-linear-gradient(90deg, rgba(96,64,22,.17) 0 5px, transparent 5px 64px),
      linear-gradient(180deg, rgba(255,246,224,.34), rgba(255,246,224,.10));
  }

  /* 2. 輪島塗黑漆金蒔繪 Wajima Urushi & Maki-e：溜塗黑漆 + 青海波金粉暗紋 + 2700K 琥珀金光 */
  body.vip-urushi {
    --frame-a: #2c1416; --frame-b: #0e0607;
    --back-a: #1e0e10;  --back-b: #090405;
    --floor-a: #261114; --floor-b: #100708;
    --lip-top: #7a5626; --lip-face: #2c1c0c;
    --rail-a: #f0d090;  --rail-b: #8a6428;
    --led: #ffd9a0;     --glow: rgba(255, 178, 96, .52);
    --door-a: #201012;  --door-b: #0d0607; --door-line: #8a6428;
    --sign-a: #ffe9b0;  --sign-b: #b88946;
  }
  body.vip-urushi .shelf { border-color: #170a0b; }
  /* 溜塗鏡面：左上角曲面高光（漆面反射） */
  body.vip-urushi .back {
    background:
      radial-gradient(ellipse 95% 42% at 16% -6%, rgba(255,214,170,.12), transparent 62%),
      linear-gradient(180deg, var(--back-a), var(--back-b) 75%);
  }

  /* 3. 燒杉浮造 Yakisugi：炭化雪松立體紋理 + 古銅件 + 冷調聚光 */
  body.vip-yakisugi {
    --frame-a: #322c26; --frame-b: #141110;
    --back-a: #1c1815;  --back-b: #0b0a08;
    --floor-a: #241f1a; --floor-b: #0f0d0b;
    --lip-top: #524a40; --lip-face: #1c1815;
    --rail-a: #bab2a6;  --rail-b: #5e584e;
    --led: #e6eeff;     --glow: rgba(186, 208, 255, .34);
    --door-a: #241f1a;  --door-b: #120f0d; --door-line: #3e382e;
    --sign-a: #dad4c6;  --sign-b: #6e675c;
  }
  body.vip-yakisugi .shelf { border-color: #0e0c0a; }
  /* 浮造（Uzukuri）年輪木紋：凹凸深紋 SVG + 縱向木板拼接縫 + 炭化顆粒 */
  body.vip-yakisugi .back::after {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background:
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='130' height='130'><g fill='none' stroke-linecap='round'><path d='M16 0 C 10 32, 24 62, 15 92 C 9 112, 19 122, 16 130' stroke='%23000000' stroke-opacity='.5' stroke-width='3'/><path d='M23 0 C 17 32, 31 62, 22 92 C 16 112, 26 122, 23 130' stroke='%23786a56' stroke-opacity='.22' stroke-width='1.4'/><path d='M52 0 C 46 30, 60 64, 51 94 C 45 112, 55 124, 52 130' stroke='%23000000' stroke-opacity='.45' stroke-width='2.6'/><path d='M59 0 C 53 30, 67 64, 58 94 C 52 112, 62 124, 59 130' stroke='%23786a56' stroke-opacity='.2' stroke-width='1.2'/><path d='M90 0 C 84 34, 98 60, 89 92 C 83 114, 93 122, 90 130' stroke='%23000000' stroke-opacity='.5' stroke-width='3.2'/><path d='M97 0 C 91 34, 105 60, 96 92 C 90 114, 100 122, 97 130' stroke='%23786a56' stroke-opacity='.22' stroke-width='1.4'/><path d='M122 0 C 116 30, 130 64, 121 94 C 115 114, 125 124, 122 130' stroke='%23000000' stroke-opacity='.45' stroke-width='2.4'/></g></svg>") 0 0 / 130px 130px,
      repeating-linear-gradient(90deg, rgba(0,0,0,.6) 0 2px, rgba(130,115,95,.12) 2px 4px, transparent 4px 108px),
      url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='matrix' values='0 0 0 0 0.05 0 0 0 0 0.04 0 0 0 0 0.035 0 0 0 0.5 0'/></filter><rect width='140' height='140' filter='url(%23n)'/></svg>");
  }

  /* ---- VIP 視覺加強：頂光燈池、漆面流光、金屬描邊、呼吸燈帶 ---- */
  @keyframes vipLedBreath { 0%, 100% { opacity: .8; } 50% { opacity: 1; } }
  body.vip-hinoki .led, body.vip-urushi .led, body.vip-yakisugi .led {
    animation: vipLedBreath 3.4s ease-in-out infinite;
  }
  /* 檜木：和紙暖光池 + 欄間（Ranma）木格橫樑 + 原木倒角層板 */
  body.vip-hinoki .cabinet {
    box-shadow: 0 40px 80px rgba(0,0,0,.7),
                0 0 46px rgba(236,200,130,.22),
                inset 0 2px 0 rgba(255,255,255,.35),
                inset 0 -4px 10px rgba(0,0,0,.35);
  }
  body.vip-hinoki .back::before {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(ellipse 74% 58% at 50% 0%, rgba(255,240,205,.44), transparent 70%);
  }
  body.vip-hinoki .shelf { box-shadow: inset 0 0 0 1px rgba(255,232,180,.42); }
  body.vip-hinoki .lip {
    background: linear-gradient(180deg, #f4dcaa, #b8894a);
    box-shadow: 0 3px 6px rgba(0,0,0,.5), inset 0 1.5px 0 rgba(255,248,225,.85);
    border-radius: 3px;
  }
  body.vip-hinoki .header::after {
    content: ''; position: absolute; left: 12px; right: 12px; bottom: -11px; height: 10px;
    background:
      repeating-linear-gradient(90deg, rgba(122,84,34,.55) 0 3px, rgba(255,240,210,.18) 3px 5px, transparent 5px 16px),
      linear-gradient(180deg, rgba(150,110,55,.5), rgba(96,64,22,.55));
    border-top: 1px solid rgba(122,84,34,.55); border-bottom: 1px solid rgba(96,64,22,.65);
    border-radius: 2px; pointer-events: none; z-index: 3;
  }
  /* 輪島塗：漆面流光掃過 + 雙金線描邊 + 黃銅門扣（金具）+ 金粉微塵閃爍 */
  body.vip-urushi .cabinet {
    box-shadow: 0 40px 80px rgba(0,0,0,.82),
                0 0 50px rgba(160,60,40,.17),
                inset 0 0 0 1px rgba(214,170,94,.4),
                inset 0 0 0 3px rgba(14,6,7,.9),
                inset 0 0 0 4px rgba(214,170,94,.22),
                inset 0 2px 0 rgba(255,220,170,.15),
                inset 0 -4px 10px rgba(0,0,0,.62);
  }
  body.vip-urushi .back::before {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(115deg, transparent 32%, rgba(255,236,200,.06) 45%, rgba(255,236,200,.14) 50%, rgba(255,236,200,.06) 55%, transparent 68%);
    background-size: 260% 100%;
    animation: urushiSweep 6.5s ease-in-out infinite;
  }
  @keyframes urushiSweep { 0% { background-position: 130% 0; } 100% { background-position: -130% 0; } }
  body.vip-urushi .shelf { box-shadow: inset 0 0 0 1px rgba(214,170,94,.5), inset 0 0 0 3px rgba(10,5,6,.8), inset 0 0 0 4px rgba(214,170,94,.24); }
  body.vip-urushi .lip { background: linear-gradient(180deg, #8a6428, #3a240e); box-shadow: 0 3px 6px rgba(0,0,0,.65), inset 0 1px 0 rgba(240,208,144,.5); }
  body.vip-urushi .door::before {
    content: ''; position: absolute; top: 50%; transform: translateY(-50%);
    width: 24px; height: 36px; border-radius: 4px;
    background: linear-gradient(160deg, #e8c87e, #8a6428 58%, #c8a05a);
    border: 1px solid rgba(90,60,20,.85);
    box-shadow: inset 0 1px 0 rgba(255,240,200,.75), 0 2px 5px rgba(0,0,0,.65);
  }
  body.vip-urushi .door.l::before { right: 5px; }
  body.vip-urushi .door.r::before { left: 5px; }
  body.vip-urushi .door.l::after { right: 15px; }
  body.vip-urushi .door.r::after { left: 15px; }
  body.vip-urushi .cabinet::before {
    content: ''; position: absolute; inset: 6px; border-radius: 10px;
    pointer-events: none; z-index: 41;
    background-image:
      radial-gradient(rgba(255,222,150,.55) .8px, transparent 1.3px),
      radial-gradient(rgba(255,222,150,.35) .8px, transparent 1.3px);
    background-size: 92px 92px, 134px 134px;
    background-position: 12px 22px, 64px 74px;
    animation: goldDust 4.2s ease-in-out infinite;
  }
  @keyframes goldDust { 0%, 100% { opacity: .16; } 50% { opacity: .5; } }
  /* 燒杉：冷調聚光燈池 + 黑鐵鍛造層板（古銅鉚釘）+ 鍛鐵門件 */
  body.vip-yakisugi .cabinet {
    box-shadow: 0 40px 80px rgba(0,0,0,.85),
                0 0 42px rgba(140,165,210,.15),
                inset 0 2px 0 rgba(255,255,255,.08),
                inset 0 -4px 10px rgba(0,0,0,.62);
  }
  body.vip-yakisugi .back::before {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(ellipse 56% 62% at 50% 0%, rgba(200,220,255,.24), transparent 72%);
  }
  body.vip-yakisugi .shelf { box-shadow: inset 0 0 0 1px rgba(170,158,140,.3); }
  body.vip-yakisugi .lip {
    background: linear-gradient(180deg, #3c362e, #16130f);
    box-shadow: 0 3px 6px rgba(0,0,0,.75), inset 0 1px 0 rgba(200,180,150,.28);
  }
  body.vip-yakisugi .lip::after {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(circle at 50% 50%, #9a8a68 1.1px, #241f18 1.7px, transparent 2.2px);
    background-size: 48px 100%; background-position: 14px 0; background-repeat: repeat-x;
  }
  body.vip-yakisugi .door::before {
    content: ''; position: absolute; top: 50%; transform: translateY(-50%);
    width: 20px; height: 32px; border-radius: 3px;
    background: linear-gradient(160deg, #4a443a, #1a1712);
    border: 1px solid rgba(150,135,110,.4);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 2px 4px rgba(0,0,0,.6);
  }
  body.vip-yakisugi .door.l::before { right: 6px; }
  body.vip-yakisugi .door.r::before { left: 6px; }

  /* ---- 舞台級獨立筒燈：每格頂部聚光束 + 層板倒影光池 ---- */
  body.vip-hinoki .slot::before, body.vip-urushi .slot::before, body.vip-yakisugi .slot::before {
    content: ''; position: absolute; left: 50%; top: -10px; transform: translateX(-50%);
    width: 96%; height: 82%; pointer-events: none; z-index: 3;
    clip-path: polygon(43% 0, 57% 0, 96% 100%, 4% 100%);
    transition: opacity .5s;
  }
  body.vip-hinoki .slot::before { background: linear-gradient(180deg, rgba(255,238,200,.26), rgba(255,238,200,.06) 58%, transparent 85%); }
  body.vip-urushi .slot::before { background: linear-gradient(180deg, rgba(255,214,150,.24), rgba(255,214,150,.05) 58%, transparent 85%); }
  body.vip-yakisugi .slot::before { background: linear-gradient(180deg, rgba(205,225,255,.20), rgba(205,225,255,.05) 58%, transparent 85%); }
  body.vip-hinoki .slot::after, body.vip-urushi .slot::after, body.vip-yakisugi .slot::after {
    content: ''; position: absolute; bottom: -5px; left: 50%; transform: translateX(-50%);
    width: 74%; height: 13px; border-radius: 50%; pointer-events: none; z-index: 1;
    transition: opacity .5s;
  }
  body.vip-hinoki .slot::after { background: radial-gradient(ellipse at center, rgba(255,238,200,.22), transparent 70%); }
  body.vip-urushi .slot::after { background: radial-gradient(ellipse at center, rgba(255,214,150,.20), transparent 70%); }
  body.vip-yakisugi .slot::after { background: radial-gradient(ellipse at center, rgba(205,225,255,.16), transparent 70%); }

  /* ---- 夜酌賞酒模式：環境轉暗，只照亮已開瓶 / 4 星以上藏酒 ---- */
  body.vip-night .cabinet { box-shadow: 0 40px 90px rgba(0,0,0,.92), inset 0 2px 0 rgba(255,255,255,.04); }
  body.vip-night .back { filter: brightness(.52); transition: filter .5s; }
  body.vip-night .floor { filter: brightness(.55); }
  body.vip-night .led { opacity: .35; animation: none; }
  body.vip-night .slot::before, body.vip-night .slot::after { opacity: 0; }
  body.vip-night .slot .bottle {
    opacity: .7; filter: brightness(.48) saturate(.6) drop-shadow(0 3px 3px rgba(0,0,0,.4));
    transition: filter .5s, opacity .5s;
  }
  body.vip-night .slot[data-status="opened"]::before,
  body.vip-night .slot[data-rating="4"]::before,
  body.vip-night .slot[data-rating="5"]::before,
  body.vip-night .slot[data-status="opened"]::after,
  body.vip-night .slot[data-rating="4"]::after,
  body.vip-night .slot[data-rating="5"]::after { opacity: 1; }
  body.vip-night .slot[data-status="opened"] .bottle,
  body.vip-night .slot[data-rating="4"] .bottle,
  body.vip-night .slot[data-rating="5"] .bottle {
    opacity: 1; filter: brightness(1.1) saturate(1.05) drop-shadow(0 0 16px rgba(255,228,160,.4));
  }

  /* ---- 藏主專屬黃銅銘牌（VIP 主題下顯示；參觀時顯示對方名號） ---- */
  .owner-plate { display: none; }
  body.vip-hinoki .owner-plate, body.vip-urushi .owner-plate, body.vip-yakisugi .owner-plate {
    display: inline-flex; align-items: center; justify-content: center;
    max-width: 76vw; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
    font-size: 10.5px; letter-spacing: 2.5px; padding: 3px 14px; border-radius: 3px;
    font-family: "Hiragino Mincho ProN", "HiraMinProN-W6", "Songti TC", "PMingLiU", serif;
  }
  body.vip-hinoki .owner-plate {
    background: linear-gradient(160deg, #f4e2b2, #c8a05a); color: #4a3410;
    border: 1px solid #8a6428;
    box-shadow: inset 0 1px 0 rgba(255,250,230,.85), 0 2px 5px rgba(0,0,0,.35);
    text-shadow: 0 1px 0 rgba(255,248,220,.7);
  }
  body.vip-urushi .owner-plate {
    background: linear-gradient(160deg, #221013, #0a0506); color: #e8c87e;
    border: 1px solid rgba(214,170,94,.7);
    box-shadow: inset 0 0 8px rgba(0,0,0,.8), 0 2px 6px rgba(0,0,0,.6);
    text-shadow: 0 0 6px rgba(232,192,127,.35);
  }
  body.vip-yakisugi .owner-plate {
    background: linear-gradient(160deg, #2e2a24, #12100d); color: #cfc8ba;
    border: 1px solid #4a443a;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 2px 5px rgba(0,0,0,.6);
  }

  /* ---- 夜酌掣 + 10 秒試看預覽浮動條 ---- */
  .night-btn {
    border: 1px solid rgba(232,192,127,.4); background: rgba(20,16,10,.6);
    color: #e8c87e; border-radius: 999px; padding: 6px 12px;
    font-size: 12px; cursor: pointer; font-family: inherit; letter-spacing: .5px;
    transition: .2s; white-space: nowrap;
  }
  .night-btn.on {
    background: linear-gradient(160deg, #c8a06a, #8a6428); color: #1d150d;
    font-weight: 700; border-color: transparent; box-shadow: 0 0 14px rgba(232,192,127,.35);
  }
  .vip-preview-bar {
    position: fixed; top: 12px; left: 50%; transform: translateX(-50%);
    z-index: 300; display: flex; align-items: center; justify-content: center; gap: 10px;
    background: linear-gradient(160deg, #2a2116, #16110b);
    border: 1px solid rgba(232,192,127,.55); border-radius: 999px;
    padding: 8px 10px 8px 16px; max-width: 94vw; flex-wrap: wrap;
    box-shadow: 0 10px 34px rgba(0,0,0,.6), 0 0 24px rgba(232,192,127,.18);
    font-size: 12.5px; color: #f4dfb2;
  }
  .vip-preview-bar b { color: #ffe9b5; }
  .vip-preview-bar .btn { padding: 6px 12px; font-size: 12px; border-radius: 999px; }
  .vpb-close { background: none; border: none; color: #c8a06a; font-size: 18px; cursor: pointer; padding: 0 6px; line-height: 1; }

  /* VIP 材質色板（deco drawer 內） */
  .vip-theme-row { display: flex; gap: 7px; margin: 2px 0 12px; }
  .vip-theme-swatch {
    flex: 1; border-radius: 10px; border: 2px solid #3a3a40; cursor: pointer;
    padding: 6px 3px 5px; text-align: center; font-family: inherit;
    background: #141417; color: #ccc; transition: .18s; font-size: 11px;
  }
  .vip-theme-swatch small { display: block; font-size: 9px; opacity: .58; margin-top: 1px; letter-spacing: .3px; }
  .vip-theme-swatch .sw-chip { display: block; height: 24px; border-radius: 6px; margin-bottom: 4px; }
  .vip-theme-swatch.on { border-color: #f0d090; box-shadow: 0 0 12px rgba(232,192,127,.3); color: #f4dfb2; }
  .sw-std     { background: linear-gradient(160deg, #3a3a3f, #18191b); }
  .sw-hinoki  { background: linear-gradient(160deg, #ecd6a4, #b88946); }
  .sw-urushi  { background: linear-gradient(160deg, #38181a, #0c0607); box-shadow: inset 0 0 0 1.5px rgba(214,170,94,.65); }
  .sw-yakisugi{ background: repeating-linear-gradient(87deg, #17140f 0 3px, #3a342a 3px 6px, #241f18 6px 20px); }
  body {
    min-height: 100vh;
    font-family: "Hiragino Sans", "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
    color: #ddd6c8;
    background: radial-gradient(1100px 620px at 50% -10%, #262019, #100d0a 62%);
    transition: background .5s, color .5s;
    padding: 40px 12px calc(96px + env(safe-area-inset-bottom));
  }
  body.theme-wood {
    color: #efe4d0;
    background: radial-gradient(1100px 620px at 50% -10%, #3a2c1c, #16100a 62%);
  }
  header.navbar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    max-width: 560px;
    margin: 0 auto 12px;
    padding: 0 2px;
    height: auto;
  }
  .brand-logo img {
    height: 68px;
    width: auto;
    display: block;
    mix-blend-mode: lighten;
  }


  /* ---- 視覺隱藏但供搜尋引擎與 Google 審核爬蟲讀取的語意標題 ---- */
  .sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
  }

  /* ---- 未登入空酒櫃內嵌極簡用途說明（融合原生設計，登入後自動隱藏） ---- */
  .ce-brand {
    font-size: 13px; font-weight: 700; letter-spacing: 2.5px; color: #e8c07a; margin-bottom: 8px;
  }
  .ce-sub {
    font-size: 12.5px; line-height: 1.85; color: #cfc7b6; opacity: .82;
    max-width: 340px; margin: 0 auto 14px;
  }
  .ce-pills {
    display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-bottom: 20px;
  }
  .ce-pills span {
    font-size: 11px; padding: 3px 10px; border-radius: 999px;
    background: rgba(200,160,106,.1); color: #d9b87c; border: 1px solid rgba(200,160,106,.24);
  }
  .ce-en {
    margin-top: 18px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.07);
    font-size: 11px; line-height: 1.65; color: #9a907e; opacity: .78;
    max-width: 340px; margin-left: auto; margin-right: auto;
  }

  /* ---- 獨立完整條款頁面模式（?legal=privacy / ?legal=disclaimer） ---- */
  .legal-page {
    max-width: 680px; margin: 16px auto 28px; padding: 24px 22px;
    background: linear-gradient(180deg, #201f1d, #151413);
    border: 1px solid #3a352c; border-radius: 14px;
    color: #e6dfd1; line-height: 1.9; font-size: 13.5px;
  }
  .legal-page h1 {
    font-size: 20px; color: #f0d9a0; letter-spacing: 1px; margin-bottom: 6px;
  }
  .legal-page .lp-meta {
    font-size: 12px; opacity: .65; margin-bottom: 18px; padding-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,.1);
  }
  .legal-page h2 {
    font-size: 15px; color: #e8c07a; margin: 18px 0 8px; letter-spacing: .5px;
  }
  .legal-page p, .legal-page li {
    font-size: 13px; line-height: 1.85; opacity: .92;
  }
  .legal-page ul { padding-left: 18px; margin-bottom: 10px; }
  .legal-page .lp-back {
    display: inline-block; margin-bottom: 14px; color: #e8c07a; text-decoration: none;
    font-size: 13px; border: 1px solid rgba(232,192,127,.4); padding: 5px 12px; border-radius: 999px;
  }

  /* ---------- 精簡版 3 層控制區 ---------- */
  .cab-head {
    display: flex; justify-content: space-between; align-items: center;
    max-width: 560px; margin: 0 auto 12px;
    border-bottom: 1px solid rgba(255,255,255,.1); padding-bottom: 8px;
  }
  .cab-tabs { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
  .cab-tab {
    background: none; border: none; color: inherit; opacity: .5;
    font-size: 15px; font-weight: 700; letter-spacing: 1.5px;
    cursor: pointer; padding: 4px 0; position: relative; font-family: inherit; transition: .2s;
  }
  .cab-tab.on { opacity: 1; color: #f0d9a0; }
  .cab-tab.on::after {
    content: ''; position: absolute; left: 0; right: 0; bottom: -9px;
    height: 2px; background: #c8a06a; border-radius: 2px;
  }
  .cab-count {
    font-size: 11px; opacity: .65; background: rgba(255,255,255,.07);
    padding: 2px 8px; border-radius: 999px; letter-spacing: .5px; white-space: nowrap;
  }
  .cab-likes {
    font-size: 11px; color: #f0d9a0; background: rgba(168,53,44,.22);
    border: 1px solid rgba(168,53,44,.48);
    padding: 2px 9px; border-radius: 999px; letter-spacing: .5px; white-space: nowrap;
    cursor: pointer; transition: .2s;
  }
  .cab-likes:hover { background: rgba(168,53,44,.38); }
  .toolbar { display: flex; background: rgba(0,0,0,.45); border: 1px solid rgba(255,255,255,.16); border-radius: 999px; padding: 2px; flex-shrink: 0; }
  .theme-sel {
    border: none; background: transparent; color: inherit;
    padding: 6px 10px; border-radius: 999px;
    font-size: 12.5px; letter-spacing: .5px; font-family: inherit;
    cursor: pointer; outline: none; max-width: 172px;
  }
  .theme-sel:focus { box-shadow: 0 0 0 1.5px rgba(232,192,127,.6); border-radius: 999px; }
  .theme-sel option { background: #1b1b20; color: #eee; }
  .toolbar button {
    border: none; background: transparent; color: inherit; opacity: .6;
    padding: 4px 10px; border-radius: 999px; cursor: pointer;
    font-size: 11.5px; letter-spacing: .5px; transition: .2s;
  }
  .toolbar button.active { background: #b8b8c0; color: #121214; opacity: 1; font-weight: 700; }
  body.theme-wood .toolbar button.active { background: #d9ac74; color: #241708; }

  /* ---------- 未登入：空酒櫃引導卡 ---------- */
  .cab-empty {
  width: 100%; max-width: 100%; flex: 0 0 100%; margin: 16px auto; padding: 46px 22px; text-align: center;
  background: linear-gradient(180deg, #232326, #17171a); border: 1px dashed #4a4438; border-radius: 16px;
  }
  .cab-empty .ce-seal { font-size: 36px; margin-bottom: 10px; }
  .cab-empty p { font-size: 14.5px; line-height: 1.9; opacity: .88; margin-bottom: 20px; }

  /* ---------- 酒款詳情卡：分享開關 + 刪除 ---------- */
  .s-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.1); }
  .s-share { display: flex; align-items: center; gap: 8px; font-size: 12.5px; cursor: pointer; opacity: .9; }
  .s-del { background: none; border: 1px solid rgba(200,80,70,.55); color: #d98c84; border-radius: 8px; padding: 7px 12px; font-size: 12.5px; cursor: pointer; font-family: inherit; transition: .2s; }
  .s-del:hover { background: rgba(200,80,70,.15); }

  /* ---------- Pro 升級提示 ---------- */
  .pro-modal { width: 420px; text-align: center; }
  .pro-modal p { font-size: 13px; line-height: 2; opacity: .85; margin: 6px 0 18px; }
  .pro-modal .btnrow { display: flex; gap: 10px; }
  .pro-modal .btnrow .btn { flex: 1; }

  /* ---------- 探索牆空狀態 ---------- */
  .feed-empty { text-align: center; padding: 44px 20px; }
  .feed-empty p { font-size: 14.5px; opacity: .85; margin-bottom: 18px; letter-spacing: 1px; }

  /* ---------- 櫃體 ---------- */
  .cabinet {
    position: relative;
    width: 100%;
    margin: 0 auto;
    padding: 14px 18px 18px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,.07);
    background: linear-gradient(180deg, var(--frame-a), var(--frame-b));
    box-shadow: 0 40px 80px rgba(0,0,0,.7),
                inset 0 2px 0 rgba(255,255,255,.08),
                inset 0 -4px 10px rgba(0,0,0,.5);
    transition: background .5s;
  }
  /* 展示玻璃微反光 */
  .cabinet::after {
    content: ''; position: absolute; inset: 8px; border-radius: 9px;
    pointer-events: none; z-index: 40; opacity: .55;
    background: linear-gradient(112deg,
      rgba(255,255,255,.09) 0%, rgba(255,255,255,.025) 24%, transparent 40%);
  }

  /* 頂部招牌 + 櫃頂 VIP 5 格展示槽（Top Display Shelf） */
  .header {
    height: auto; min-height: 64px; padding: 10px 0 8px;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 7px;
    border-bottom: 1px solid rgba(0,0,0,.55);
    box-shadow: 0 1px 0 rgba(255,255,255,.05);
    position: relative; z-index: 2;
  }
  .header-top {
    position: relative; width: 100%;
    display: flex; align-items: center; justify-content: center;
    min-height: 36px;
  }
  .vip-shelf {
    display: inline-flex; align-items: flex-end; justify-content: center;
    gap: 8px;
    padding: 5px 14px 5px;
    border-radius: 7px;
    background: linear-gradient(180deg, rgba(0,0,0,.52), rgba(0,0,0,.24));
    border: 1px solid rgba(255,255,255,.07);
    box-shadow: inset 0 2px 6px rgba(0,0,0,.68), 0 1px 0 rgba(255,255,255,.06);
    position: relative;
  }
  .vip-shelf::after {
    content: '';
    position: absolute; left: 10px; right: 10px; bottom: 0; height: 1.5px;
    background: linear-gradient(90deg, transparent, rgba(232,192,127,.5), transparent);
  }
  .vip-slot {
    width: 34px; height: 36px; border-radius: 5px;
    display: flex; align-items: center; justify-content: center;
    position: relative;
    transition: transform .2s ease, border-color .2s ease, background .2s ease;
  }
  .vip-shelf.editing .vip-slot {
    cursor: pointer;
    border: 1px dashed rgba(232,192,127,.48);
    background: rgba(200,160,106,.07);
  }
  .vip-shelf.editing .vip-slot.active-slot {
    border: 1.5px solid #f0d090;
    background: rgba(200,160,106,.24);
    transform: translateY(-2px);
    box-shadow: 0 0 10px rgba(232,192,127,.38);
  }
  .vip-slot-empty-dot {
    width: 4px; height: 4px; border-radius: 50%;
    background: rgba(255,255,255,.15);
  }
  .vip-shelf.editing .vip-slot-empty-dot {
    width: auto; height: auto; background: none;
    font-size: 13px; color: rgba(232,192,127,.72);
  }
  .vip-shelf.editing .vip-slot-empty-dot::before { content: '+'; }

  /* 拉絲香檳金立體金屬字塊（A-Z） */
  .vip-tile-char {
    width: 30px; height: 32px; border-radius: 4px;
    display: flex; align-items: center; justify-content: center;
    font-family: "Cinzel", "Times New Roman", "Hiragino Mincho ProN", serif;
    font-size: 18px; font-weight: 800; letter-spacing: 0;
    color: #24190c;
    background: linear-gradient(145deg, #f7e3b2 0%, #c89d54 48%, #f1d294 55%, #9e732c 100%);
    border: 1px solid rgba(255,244,214,.72);
    box-shadow:
      0 3px 5px rgba(0,0,0,.72),
      inset 0 1px 0 rgba(255,255,255,.75),
      inset 0 -1.5px 1px rgba(74,48,14,.65),
      0 0 8px rgba(232,192,127,.22);
    text-shadow: 0 1px 0 rgba(255,248,228,.6);
    user-select: none;
  }
  .vip-tile-prop {
    width: 32px; height: 34px;
    display: flex; align-items: center; justify-content: center;
    filter: drop-shadow(0 3px 4px rgba(0,0,0,.78));
  }
  .vip-tile-prop svg {
    width: 30px; height: 34px; display: block; overflow: visible;
  }

  /* VIP 裝飾設定彈窗（5 槽位 + 三分頁單手操作） */
  .vip-slots-bar {
    display: flex; justify-content: center; gap: 10px;
    margin: 10px 0 12px;
  }
  .vip-pick-slot {
    width: 54px; height: 58px; border-radius: 10px;
    border: 1.5px solid #3a3a40; background: #141417;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 2px; cursor: pointer; transition: .18s; color: #ddd6c8; font-family: inherit;
  }
  .vip-pick-slot.on {
    border-color: #f0d090; background: rgba(200,160,106,.18);
    box-shadow: 0 0 14px rgba(232,192,127,.28); transform: translateY(-2px);
  }
  .vip-pick-slot small { font-size: 9.5px; opacity: .58; }
  .vip-tabs {
    display: flex; gap: 6px; margin-bottom: 12px;
  }
  .vip-tab-btn {
    flex: 1; padding: 7px 6px; border-radius: 8px;
    border: 1px solid #3a3a40; background: #1b1b20; color: #ccc;
    font-size: 12.5px; font-weight: 600; cursor: pointer; font-family: inherit;
    transition: .15s;
  }
  .vip-tab-btn.on {
    background: linear-gradient(160deg, #c8a06a, #8a6428);
    border-color: transparent; color: #1d150d; font-weight: 700;
  }
  .vip-alpha-grid {
    display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px;
  }
  .vip-alpha-btn {
    height: 38px; border-radius: 7px;
    border: 1px solid rgba(232,192,127,.35);
    background: linear-gradient(145deg, #2a241b, #191612);
    color: #f4dfb2;
    font-family: "Cinzel", "Times New Roman", serif;
    font-size: 16px; font-weight: 700; cursor: pointer; transition: .15s;
  }
  .vip-alpha-btn:hover, .vip-alpha-btn.on {
    background: linear-gradient(145deg, #f3d492, #b88946);
    color: #1f160a; border-color: #ffe8b5;
  }
  .logo {
    font-size: 27px; font-weight: 700; letter-spacing: 9px; text-indent: 9px;
    background: linear-gradient(180deg, var(--sign-a) 18%, var(--sign-b) 52%, var(--sign-a) 58%, var(--sign-b));
    -webkit-background-clip: text; background-clip: text; color: transparent;
    filter: drop-shadow(0 2px 3px rgba(0,0,0,.75));
  }
  /* 朱紅篆刻印章「藏珍」 */
  .seal {
    position: absolute; right: 20px; top: 50%;
    transform: translateY(-50%) rotate(-3deg);
    width: 40px; height: 40px; border-radius: 7px;
    background: linear-gradient(145deg, #d43a2f, #a51f1a);
    box-shadow: inset 0 0 7px rgba(0,0,0,.4), inset 0 0 2px rgba(255,255,255,.25), 0 2px 6px rgba(0,0,0,.55);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 0; padding: 2px;
  }
  .seal i {
    font-style: normal; color: #fdf6ec; font-size: 14px; font-weight: 700;
    font-family: "Hiragino Mincho ProN", "HiraMinProN-W6", "Songti TC", "PMingLiU", serif;
    line-height: 1.02; text-shadow: 0 0 1px rgba(0,0,0,.4);
  }

  /* ---------- 單層展示格 ---------- */
  .shelf {
    position: relative; height: 300px; margin-top: 12px;
    border: 7px solid #0a0a0b; border-radius: 6px;
    perspective: 700px; background: #050506;
    overflow: hidden;
  }
  body.theme-wood .shelf { border-color: #1c1108; }
  .back {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, var(--back-a), var(--back-b) 75%);
    box-shadow: inset 0 22px 42px rgba(0,0,0,.75),
                inset 0 -14px 28px rgba(0,0,0,.6),
                inset 12px 0 22px rgba(0,0,0,.45),
                inset -12px 0 22px rgba(0,0,0,.45);
  }
  body.theme-wood .back {
    background:
      repeating-linear-gradient(92deg, rgba(0,0,0,.16) 0 2px, transparent 2px 28px),
      linear-gradient(180deg, var(--back-a), var(--back-b) 75%);
  }
  /* 頂部 LED 燈帶 */
  .led {
    position: absolute; top: 6px; left: 12px; right: 12px; height: 3px;
    border-radius: 2px; background: var(--led); opacity: .96; z-index: 1;
    box-shadow: 0 2px 9px 3px var(--glow), 0 12px 30px 11px var(--glow);
  }
  /* 透視層板平面 */
  .floor {
    position: absolute; left: 8px; right: 8px; bottom: 4px; height: 104px;
    border-radius: 4px; transform: rotateX(58deg); transform-origin: bottom;
    background: linear-gradient(180deg, var(--floor-a), var(--floor-b));
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06);
    z-index: 2;
  }
  .slots {
    position: absolute; left: 18px; right: 18px; bottom: 9px;
    display: flex; justify-content: space-evenly; align-items: flex-end;
    z-index: 3;
  }
  .slot { position: relative; display: flex; justify-content: center; }

  /* CSS 接觸陰影（懸停時縮小變淡） */
  .ground {
    position: absolute; bottom: -3px; left: 50%;
    transform: translateX(-50%);
    width: 78%; height: 15px; border-radius: 50%;
    background: radial-gradient(ellipse at center,
      rgba(0,0,0,.68) 0%, rgba(0,0,0,.3) 48%, transparent 72%);
    filter: blur(2px); z-index: 1;
    transition: transform .3s, opacity .3s;
  }
  .bottle {
    height: 212px; display: block; position: relative; z-index: 2;
    transform-origin: bottom center;
    transition: transform .3s cubic-bezier(.2,.75,.3,1.15), filter .3s;
    filter: drop-shadow(0 3px 3px rgba(0,0,0,.3));
  }
  .slot:hover .bottle, .slot.active .bottle {
    transform: translateY(-14px) scale(1.05);
    filter: drop-shadow(0 16px 13px rgba(0,0,0,.5));
  }
  .slot:hover .ground, .slot.active .ground { transform: translateX(-50%) scale(.72); opacity: .5; }

  /* 層板前緣（遮住酒瓶底部 2px） */
  .lip {
    position: absolute; left: 6px; right: 6px; bottom: 6px; height: 5px;
    border-radius: 2px; z-index: 5;
    background: linear-gradient(180deg, var(--lip-top), var(--lip-face));
    box-shadow: 0 3px 6px rgba(0,0,0,.6), 0 1px 0 rgba(0,0,0,.4);
  }

  /* ---------- 底部櫃門 ---------- */
  .base {
    height: 86px; margin-top: 12px; padding: 10px 12px;
    display: flex; gap: 10px;
    border-radius: 6px; border: 1px solid rgba(0,0,0,.6);
    background: linear-gradient(180deg, var(--frame-a), var(--frame-b));
    box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  }
  .door {
    flex: 1; position: relative; border-radius: 4px;
    border: 2px solid var(--door-line);
    background: linear-gradient(180deg, var(--door-a), var(--door-b));
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.55), inset 0 8px 14px rgba(0,0,0,.35);
  }
  .door::after {
    content: ''; position: absolute; top: 50%; transform: translateY(-50%);
    width: 4px; height: 26px; border-radius: 2px;
    background: linear-gradient(180deg, var(--rail-a), var(--rail-b));
    box-shadow: 0 1px 2px rgba(0,0,0,.7);
  }
  .door.l::after { right: 13px; }
  .door.r::after { left: 13px; }

  /* ---------- 酒款資料 Bottom Sheet（固定在屏幕底部滑出，不遮酒櫃） ---------- */
  .sheet {
    position: fixed; left: 50%; bottom: 0; z-index: 95;
    transform: translate(-50%, 105%);
    width: min(620px, 96vw);
    background: linear-gradient(180deg, var(--card-a), var(--card-b));
    color: var(--ink); border-top: 3px solid #a8352c; border-radius: 16px 16px 0 0;
    box-shadow: 0 -14px 44px rgba(0,0,0,.55);
    padding: 10px 18px calc(16px + env(safe-area-inset-bottom));
    transition: transform .32s cubic-bezier(.2,.75,.3,1);
    text-align: left;
  }
  .sheet.show { transform: translate(-50%, 0); }
  .sheet .grab { width: 44px; height: 5px; border-radius: 3px; background: rgba(0,0,0,.22); margin: 0 auto 10px; }
  .sheet .s-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
  .sheet .s-close { cursor: pointer; font-size: 22px; line-height: 1; opacity: .55; padding: 0 4px; }
  .sheet .s-close:hover { opacity: 1; }
  .cname { font-size: 16px; font-weight: 700; letter-spacing: .5px; }
  .cname .sub { display: block; font-size: 12px; font-weight: 500; opacity: .65; margin-top: 2px; }
  .s-likecount {
    font-size: 11.5px; color: #a8352c; font-weight: 700;
    background: rgba(168,53,44,.12); border: 1px solid rgba(168,53,44,.25);
    padding: 2px 9px; border-radius: 999px; white-space: nowrap;
  }
  .sheet dl { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px 14px; margin: 11px 0 9px; }
  .sheet dl > div {
    display: flex; justify-content: space-between; gap: 6px;
    border-bottom: 1px dashed rgba(0,0,0,.15); padding-bottom: 3px;
  }
  .sheet dt { font-size: 11.5px; opacity: .6; white-space: nowrap; }
  .sheet dd { font-size: 12px; font-weight: 600; text-align: right; }
  .note-wrap { margin-top: 6px; }
  .note { font-size: 12.5px; line-height: 1.6; opacity: .85; }
  .note-edit-btn { display: inline-flex; align-items: center; gap: 4px; background: rgba(43,36,25,.08); border: 1px dashed rgba(43,36,25,.32); color: var(--ink); border-radius: 6px; padding: 3px 9px; font-size: 11.5px; cursor: pointer; font-family: inherit; margin-top: 5px; transition: .2s; }
  .note-edit-btn:hover { background: rgba(43,36,25,.16); border-style: solid; }
  .note-editor { display: none; margin-top: 6px; }
  .note-editor textarea { width: 100%; background: rgba(255,255,255,.78); border: 1px solid #a8352c; color: var(--ink); border-radius: 8px; padding: 8px 10px; font-size: 12.5px; line-height: 1.5; font-family: inherit; resize: vertical; }
  .note-editor textarea:focus { outline: none; box-shadow: 0 0 0 2px rgba(168,53,44,.2); }
  .note-ed-btns { display: flex; justify-content: flex-end; gap: 6px; margin-top: 6px; }
  .note-ed-btns button { border-radius: 6px; padding: 4px 12px; font-size: 12px; cursor: pointer; font-family: inherit; }
  .note-cancel { background: transparent; border: 1px solid rgba(43,36,25,.35); color: var(--ink); }
  .note-save { background: #a8352c; border: none; color: #f7f1e3; font-weight: 700; }
  @media (max-width: 600px) {
    .sheet dl { grid-template-columns: repeat(2, 1fr); }
    .bottle { height: 222px; }
    .car-nav { display: none; }
  }

  /* ---------- 影酒入櫃（拍照 + 去背 + OCR） ---------- */
  .fab {
    position: fixed; right: 22px; bottom: calc(88px + env(safe-area-inset-bottom)); z-index: 90;
    width: 64px; height: 64px; border-radius: 50%; border: none; cursor: pointer;
    background: linear-gradient(160deg, #c8a06a, #8a6428); color: #1d150d;
    font-size: 24px; box-shadow: 0 12px 26px rgba(0,0,0,.6); transition: .25s;
  }
  .fab small { display: block; font-size: 9.5px; letter-spacing: 1px; margin-top: -2px; }
  .fab:hover { transform: translateY(-3px) scale(1.06); }

  .modal-mask {
    position: fixed; inset: 0; background: rgba(0,0,0,.74); backdrop-filter: blur(4px);
    z-index: 100; display: none; align-items: center; justify-content: center;
  }
  .modal-mask.show { display: flex; }
  .modal {
    width: 580px; max-width: 94vw; max-height: 92vh; overflow: auto;
    background: linear-gradient(180deg, #232326, #161618);
    border: 1px solid #3a3a3f; border-radius: 14px; padding: 20px 22px;
    color: #ddd6c8; box-shadow: 0 30px 80px rgba(0,0,0,.85);
  }
  .modal h2 { font-size: 18px; letter-spacing: 2px; margin-bottom: 14px; display: flex; justify-content: space-between; align-items: center; }
  .modal .close { cursor: pointer; opacity: .6; font-size: 24px; line-height: 1; }
  .modal .close:hover { opacity: 1; }
  .steps { display: flex; gap: 6px; margin-bottom: 16px; }
  .steps span {
    flex: 1; text-align: center; font-size: 11.5px; padding: 5px 0;
    border-radius: 99px; background: #2a2a2e; opacity: .5;
  }
  .steps span.on { opacity: 1; background: #8a6428; color: #ffe9c4; font-weight: 700; }

  .guide {
    position: relative; height: 240px; border: 2px dashed #555; border-radius: 10px;
    display: flex; align-items: center; justify-content: center; overflow: hidden;
    background: #101012; margin-bottom: 12px;
  }
  .guide img {
    max-height: 100%; max-width: 100%; object-fit: contain;
    position: relative; z-index: 1;
    touch-action: none; cursor: grab; will-change: transform;
    user-select: none; -webkit-user-drag: none;
  }
  .guide.dragging img { cursor: grabbing; }
  .guide .corner { position: absolute; width: 26px; height: 26px; border: 3px solid #c8a06a; z-index: 2; }
  .guide .tl { top: 10px; left: 10px; border-right: 0; border-bottom: 0; }
  .guide .tr { top: 10px; right: 10px; border-left: 0; border-bottom: 0; }
  .guide .bl { bottom: 10px; left: 10px; border-right: 0; border-top: 0; }
  .guide .br { bottom: 10px; right: 10px; border-left: 0; border-top: 0; }
  .guide .hint { position: absolute; bottom: 8px; left: 0; right: 0; text-align: center; font-size: 12px; opacity: .65; z-index: 3; }


  /* ---- 即時相機取景層（Live Camera Viewfinder） ---- */
  .cam-live {
    position: absolute; inset: 0; z-index: 1; background: #000;
    display: none; overflow: hidden;
  }
  .guide.cam-on .cam-live { display: block; }
  .cam-live video {
    width: 100%; height: 100%; object-fit: cover; display: block;
  }
  .cam-live video.mirror { transform: scaleX(-1); }

  /* 正面酒瓶輪廓引導線（橢圓瓶身：標準 / 胖身切換） */
  .g-silhouette {
    fill: rgba(236, 194, 127, 0.06);
    stroke: #ecc27f; stroke-width: 2.8; stroke-dasharray: 9 6;
    stroke-linecap: round; stroke-linejoin: round;
    filter: drop-shadow(0 1px 3px rgba(0,0,0,.9));
    transition: rx .25s ease, ry .25s ease, x .25s ease, y .25s ease, width .25s ease, height .25s ease;
  }


  /* 背面酒標特寫框 ＋ 中央十字準心 */
  .guide.back .crosshair {
    position: absolute; left: 50%; top: calc(50% - 10px);
    width: 44px; height: 44px; transform: translate(-50%, -50%);
    z-index: 3; pointer-events: none;
  }
  .guide.back .crosshair::before,
  .guide.back .crosshair::after {
    content: ''; position: absolute; background: #ecc27f;
    box-shadow: 0 0 6px rgba(0,0,0,.9);
  }
  .guide.back .crosshair::before {
    left: 50%; top: 0; width: 2px; height: 100%; transform: translateX(-50%);
  }
  .guide.back .crosshair::after {
    top: 50%; left: 0; height: 2px; width: 100%; transform: translateY(-50%);
  }
  .guide.back .crosshair i {
    position: absolute; left: 50%; top: 50%; width: 10px; height: 10px;
    transform: translate(-50%, -50%); border-radius: 50%;
    border: 2px solid #ecc27f; background: rgba(236, 194, 127, 0.2);
  }

  /* 快門掣：置於取景框下方正中，仿原生相機；翻轉／關閉為框內右上角小圓掣 */
  .cam-bar {
    display: none; justify-content: center; align-items: center;
    margin: 12px 0 4px;
  }
  .cam-bar.show { display: flex; }
  .cam-tools {
    position: absolute; top: 10px; right: 10px;
    display: none; gap: 8px; z-index: 6;
  }
  .guide.cam-on .cam-tools { display: flex; }
  .cam-tools .btn {
    width: 36px; height: 36px; border-radius: 50%; padding: 0;
    background: rgba(10,10,12,.55); color: #fff;
    border: 1.5px solid rgba(255,255,255,.55);
    font-size: 15px; line-height: 1; backdrop-filter: blur(4px);
  }
  .cam-tools .btn:active { transform: scale(.9); }
  .btn.shutter {
    width: 76px; height: 76px; border-radius: 50%; padding: 0;
    background: #fff; color: transparent; border: none;
    box-shadow: 0 0 0 5px rgba(255,255,255,.38), 0 6px 22px rgba(0,0,0,.6), inset 0 0 0 4px #b98f4e;
  }
  .btn.shutter:active { transform: scale(.9); box-shadow: 0 0 0 5px rgba(255,255,255,.3), 0 3px 12px rgba(0,0,0,.55), inset 0 0 0 4px #b98f4e; }

  /* ---- Step 1：整支清酒瓶 SVG 虛線輪廓（四合瓶） ---- */
  .guide.front { height: min(54vh, 480px); }
  .guide.front .bottle-svg {
    position: absolute; top: 2px; left: 0; right: 0; margin: 0 auto; z-index: 2;
    height: calc(100% - 46px); max-width: 90%;
    pointer-events: none;
  }
  .g-bottle, .g-line, .g-base {
    fill: none; stroke: #ecc27f; stroke-linecap: round;
    filter: drop-shadow(0 1px 3px rgba(0,0,0,.85));
  }
  .g-bottle { stroke-width: 3; stroke-dasharray: 11 8; }
  .g-line   { stroke-width: 2.5; stroke-dasharray: 14 8; opacity: .85; }
  .g-base   { stroke-width: 4.5; stroke-dasharray: 18 9; }
  .g-txt    { fill: #ecc27f; font-size: 17px; letter-spacing: 2px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.9)); }

  /* ---- 圓柱酒瓶曲面參考線（肩線、標貼區弧線、中軸線） ---- */
  .g-curve {
    fill: none; stroke: rgba(236, 194, 127, 0.52); stroke-width: 1.6;
    stroke-dasharray: 5 5; stroke-linecap: round;
    transition: d .25s ease, opacity .25s ease;
  }
  .g-axis {
    fill: none; stroke: rgba(236, 194, 127, 0.34); stroke-width: 1.3;
    stroke-dasharray: 4 6; stroke-linecap: round;
  }
  .g-lblzone {
    fill: rgba(236, 194, 127, 0.04); stroke: rgba(236, 194, 127, 0.42);
    stroke-width: 1.4; stroke-dasharray: 6 5;
    transition: d .25s ease;
  }

  /* ---- Step 2：背面標籤特寫矩形框（支援直度 / 橫度 / 全幅雙標切換 + 圓柱曲面弧線） ---- */
  .guide.back { height: min(50vh, 420px); }
  .guide.back .label-frame {
    position: absolute; z-index: 2;
    top: 14px; bottom: 38px; left: 50%; width: min(64%, 230px);
    transform: translateX(-50%);
    border: 2.5px dashed rgba(236,194,127,.92); border-radius: 12px; pointer-events: none;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.36);
    transition: all .25s cubic-bezier(.2, .75, .3, 1);
  }
  .guide.back.mode-horz .label-frame {
    top: 22px; bottom: 44px; width: calc(100% - 28px); max-width: none;
  }
  .guide.back.mode-wide .label-frame {
    top: 16px; bottom: 38px; width: calc(100% - 24px); max-width: none;
  }
  /* 圓柱酒瓶背面上下弧度參考線（輔助對齊圓柱曲率） */
  .guide.back .label-frame::before,
  .guide.back .label-frame::after {
    content: ''; position: absolute; left: 8%; right: 8%; height: 14px;
    border: 1.5px dashed rgba(236,194,127,.48); pointer-events: none;
  }
  .guide.back .label-frame::before {
    top: 6px; border-bottom: none; border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  }
  .guide.back .label-frame::after {
    bottom: 6px; border-top: none; border-radius: 0 0 50% 50% / 0 0 100% 100%;
  }
  /* 旋轉 90° 快速修正按鈕（應對橫向酒標或手機誤轉方向） */
  .guide.back .rot-btn {
    position: absolute; left: 10px; bottom: 36px; z-index: 4;
    display: none; align-items: center; gap: 4px;
    padding: 5px 10px; border-radius: 999px; cursor: pointer;
    border: 1px solid rgba(236,194,127,.55); background: rgba(0,0,0,.68); color: #f0d9a0;
    font-size: 11.5px; font-family: inherit; backdrop-filter: blur(4px);
  }
  .guide.back.has-img .rot-btn { display: inline-flex; }

  /* ---- 相片縮放/平移控制器（疊喺 guide 上） ---- */
  .zoom-ctl {
    position: absolute; right: 8px; bottom: 36px; z-index: 4;
    display: none; flex-direction: column; gap: 6px;
  }
  .guide.has-img .zoom-ctl { display: flex; }
  .zbtn {
    width: 34px; height: 34px; border-radius: 50%; cursor: pointer;
    border: 1px solid rgba(255,255,255,.3); background: rgba(0,0,0,.6); color: #fff;
    font-size: 17px; line-height: 1; backdrop-filter: blur(4px);
    display: flex; align-items: center; justify-content: center;
  }
  .zbtn:active { background: rgba(200,160,106,.75); }

  .btnrow { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
  .btn {
    border: 1px solid #4a4a52; background: #26262b; color: #ddd6c8;
    padding: 9px 14px; border-radius: 8px; cursor: pointer;
    font-size: 13.5px; letter-spacing: 1px; transition: .2s; font-family: inherit;
  }
  .btn:hover { background: #33333a; }
  .btn.primary { background: linear-gradient(160deg, #c8a06a, #8a6428); border: none; color: #1d150d; font-weight: 700; }
  .btn:disabled { opacity: .4; cursor: not-allowed; }

  .progress-list { font-size: 13.5px; line-height: 2.3; margin-bottom: 10px; }
  .progress-list li { list-style: none; opacity: .4; }
  .progress-list li.run { opacity: 1; color: #ffd9a0; }
  .progress-list li.run::before { content: '▸ '; }
  .progress-list li.done { opacity: .88; }
  .progress-list li .pdots::after { content: ''; margin-left: 6px; }
  .progress-list li.run .pdots::after { content: '…'; animation: pdot 1s ease-in-out infinite; }
  .progress-list li.done .pdots::after { content: '✓'; color: #9fc98f; font-weight: 700; animation: none; }
  @keyframes pdot { 0%, 100% { opacity: .2 } 50% { opacity: 1 } }
  #ocrStatus { font-size: 12px; opacity: .7; min-height: 18px; }

  .result { display: flex; gap: 16px; }
  .result .preview {
    flex: 0 0 150px; height: 222px; border-radius: 8px; border: 1px solid #3a3a3f;
    background: radial-gradient(120% 90% at 50% 0%, #2a2a2e, #0c0c0e);
    display: flex; align-items: flex-end; justify-content: center; overflow: hidden;
  }
  .result .preview img { max-height: 205px; max-width: 92%; }
  .fields { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .fields label { display: block; font-size: 11px; opacity: .6; margin-bottom: 3px; }
  .fields input, .fields textarea {
    width: 100%; background: #101012; border: 1px solid #3a3a3f; color: #eee;
    border-radius: 6px; padding: 7px 9px; font-size: 13px; font-family: inherit;
  }
  .fields input:focus, .fields textarea:focus { outline: none; border-color: #c8a06a; }
  .fields .full { grid-column: 1 / -1; }
  .ocr-note { font-size: 11px; opacity: .55; margin-top: 8px; line-height: 1.6; }

  /* ---------- 多酒櫃橫向翻頁（Carousel / Snap Scroll） ---------- */
  .viewbar {
    width: 960px; max-width: 96vw; margin: 0 auto 12px;
    display: flex; flex-direction: column; gap: 8px;
  }
  .pills { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .pill {
    border: 1px solid rgba(255,255,255,.15); background: rgba(255,255,255,.03); color: inherit;
    padding: 6px 8px; border-radius: 8px; font-size: 12px; cursor: pointer;
    letter-spacing: .5px; transition: .2s; font-family: inherit; text-align: center; white-space: nowrap;
  }
  .pill.on { background: #c8a06a; border-color: #c8a06a; color: #1d150d; font-weight: 700; }
  body.theme-wood .pill.on { background: #d9ac74; border-color: #d9ac74; color: #241708; }

  .ctl-row2 { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
  .midctl { display: flex; gap: 6px; }
  .midctl .pill { padding: 5px 11px; border-radius: 999px; font-size: 11.5px; }
  .seg { display: flex; background: rgba(0,0,0,.45); border: 1px solid rgba(255,255,255,.16); border-radius: 999px; padding: 2px; flex-shrink: 0; }
  .seg button {
    border: none; background: transparent; color: inherit; padding: 4px 11px; border-radius: 999px;
    font-size: 11.5px; cursor: pointer; letter-spacing: .5px; opacity: .55; font-family: inherit; transition: .2s;
  }
  .seg button.on { background: rgba(255,255,255,.16); opacity: 1; font-weight: 700; }

  /* ---- 日本 47 都道府縣制霸地圖 ---- */
  #prefPanel {
    width: 960px; max-width: 96vw; margin: 0 auto 14px;
    background: rgba(14,14,16,.82); border: 1px solid #2e2e33; border-radius: 12px;
    padding: 12px 16px 8px;
  }
  .pmap-head { display: flex; align-items: center; gap: 12px; margin-bottom: 4px; flex-wrap: wrap; }
  .pmap-title { font-size: 13.5px; letter-spacing: 2px; font-weight: 700; opacity: .85; }
  .pmap-badge {
    font-size: 12px; padding: 3px 10px; border-radius: 999px;
    background: rgba(217,172,116,.15); color: #e8c07a; border: 1px solid rgba(217,172,116,.45);
  }
  .pmap-info { font-size: 13.5px; font-weight: 700; letter-spacing: 1px; color: #f2cd87; }
  .pmap { overflow: hidden; }
  .pmap svg {
    display: block; width: 100%; max-width: 640px; margin: 0 auto;
    transition: transform .15s ease-out; touch-action: none; cursor: grab;
  }
  @media (max-width: 600px) {
    .pmap svg { max-width: 100%; }
    .bottle { height: 222px; }
    .car-nav { display: none; }
  }
  /* 和紙黃底（未飲）/ 朱紅（已收藏）*/
  .pref { fill: #E9C46A; stroke: #8C6D1F; stroke-width: 1.4; transition: fill .25s, filter .25s; }
  .pref.on { fill: #D62828; stroke: #8f1d1d; }
  .pref.on:hover { fill: #e63939; }
  .pref.sel { fill: #2A9D8F; stroke: #E0FBF7; stroke-width: 2.2; filter: drop-shadow(0 0 6px rgba(42,157,143,.95)); }

  /* ---- Sheet 迷你地圖 ---- */
  .sheet-map { position: absolute; top: 10px; right: 40px; width: 64px; pointer-events: none; opacity: .95; }
  .sheet-map svg .pref { fill: #26262b; stroke: #141416; stroke-width: 2; }
  .sheet-map svg .pref.on { fill: #D62828; stroke: #8f1d1d; }

  .carousel-wrap { position: relative; width: 960px; max-width: 96vw; margin: 0 auto; }
  .carousel {
    display: flex; gap: 20px;
    overflow-x: auto; scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }
  .carousel::-webkit-scrollbar { display: none; }
  .cabinet-page { flex: 0 0 100%; min-width: 0; scroll-snap-align: center; }
  .car-nav {
    position: absolute; top: 44%; transform: translateY(-50%); z-index: 20;
    width: 38px; height: 38px; border-radius: 50%; cursor: pointer;
    border: 1px solid rgba(255,255,255,.25); background: rgba(0,0,0,.55); color: #e8dfd0;
    font-size: 20px; line-height: 1; backdrop-filter: blur(4px);
  }
  .car-nav:hover { background: rgba(200,160,106,.85); color: #1d150d; }
  .car-nav.prev { left: -16px; }
  .car-nav.next { right: -16px; }
  @media (max-width: 1060px) { .car-nav.prev { left: 4px; } .car-nav.next { right: 4px; } }

  /* 分頁指示器（底部雙門上方） */
  .pager { display: flex; justify-content: center; align-items: center; gap: 14px; padding: 10px 0 4px; }
  .pager .dots { font-size: 13px; color: #9a8a70; letter-spacing: 4px; }
  .pager .dot { cursor: pointer; }
  .pager .dot.on { color: #e8c07a; }
  .pager .pcount { font-size: 11.5px; opacity: .55; letter-spacing: 1px; }

  /* 狀態圓點 / 空瓶位 / 入櫃閃爍 */
  .slot .st {
    position: absolute; bottom: 7px; left: 50%; margin-left: 24px;
    width: 9px; height: 9px; border-radius: 50%; z-index: 3;
  }
  .slot .st.cellaring { background: #8fbf75; box-shadow: 0 0 6px rgba(143,191,117,.9); }
  .slot .st.opened { background: #e0995c; box-shadow: 0 0 6px rgba(224,153,92,.9); }
  .slot.empty::after {
    content: ''; width: 52px; height: 168px; margin-bottom: 2px;
    border: 1.5px dashed rgba(255,255,255,.10); border-radius: 22px 22px 12px 12px;
  }
  .slot.empty .ground { opacity: .25; }
  .slot.flash img { animation: flashUp .55s ease 2; }
  @keyframes flashUp { 50% { transform: translateY(-12px) scale(1.05); } }

  /* Sheet 狀態切換掣 */
  .s-actions { display: flex; gap: 8px; margin: 10px 0 2px; }
  .s-act {
    border: 1px solid rgba(43,36,25,.4); background: transparent; color: var(--ink);
    opacity: .65; padding: 5px 12px; border-radius: 999px; font-size: 12px;
    cursor: pointer; letter-spacing: 1px; font-family: inherit; transition: .2s;
  }
  .s-act.on { background: #a8352c; border-color: #a8352c; color: #f7f1e3; opacity: 1; font-weight: 700; }

  /* ---------- 清單模式 ---------- */
  #listView { width: 720px; max-width: 94vw; margin: 0 auto; }
  .lsearch { margin-bottom: 12px; }
  .lsearch input {
    width: 100%; background: #17171a; border: 1px solid #3a3a3f; color: #eee;
    border-radius: 10px; padding: 11px 14px; font-size: 14px; font-family: inherit;
  }
  .lsearch input:focus { outline: none; border-color: #c8a06a; }
  .lrow {
    display: flex; align-items: center; gap: 14px; cursor: pointer;
    background: linear-gradient(180deg, #1e1e22, #161618);
    border: 1px solid #313136; border-radius: 12px;
    padding: 10px 16px 10px 10px; margin-bottom: 9px; transition: border-color .2s;
  }
  .lrow:hover { border-color: #8a6d3f; }
  .lrow img { height: 66px; width: auto; }
  .lmain { flex: 1; min-width: 0; }
  .lname { font-size: 15px; font-weight: 700; }
  .lname span { display: block; font-size: 11.5px; font-weight: 500; opacity: .6; margin-top: 2px; }
  .lmeta { font-size: 12px; opacity: .6; margin-top: 5px; }
  .ltag { font-size: 11px; padding: 4px 10px; border-radius: 999px; letter-spacing: 1px; flex-shrink: 0; }
  .ltag.cellaring { background: rgba(127,176,105,.18); color: #9fc98f; border: 1px solid rgba(127,176,105,.4); }
  .ltag.opened { background: rgba(217,138,75,.16); color: #e0a878; border: 1px solid rgba(217,138,75,.4); }
  .lempty { grid-column: 1 / -1; text-align: center; opacity: .5; padding: 30px 0; }

  /* ================= Phase 2：App 架構 ================= */
  .visit-bar {
    width: 960px; max-width: 96vw; margin: 0 auto 12px;
    display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap;
    background: rgba(168,53,44,.16); border: 1px solid rgba(168,53,44,.55); color: #f0d9a0;
    padding: 9px 16px; border-radius: 10px; font-size: 13px; letter-spacing: 1px;
  }
  .cab-sub { width: fit-content; margin: 0 auto 14px; }

  /* ---- 酒友探索：瀑布流 ---- */
  .tab-title { font-size: 17px; font-weight: 700; letter-spacing: 3px; margin-bottom: 14px; }
  #tab-explore, #tab-find, #tab-profile { width: 960px; max-width: 96vw; margin: 0 auto; padding: 0 16px; }
  .exp-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
  .exp-head .tab-title { margin-bottom: 0; }
  .exp-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
  .exp-tabs .pill { padding: 4px 11px; border-radius: 999px; font-size: 11.5px; }
  .feed { columns: 2; column-gap: 14px; text-align: left; padding: 4px 0 16px; }
  .feed .feed-empty { column-span: all; text-align: center; padding: 48px 16px; }
  @media (max-width: 560px) { .feed { columns: 1; } }
  .p-imgwrap { cursor: pointer; }
  .p-visit { border: 1px solid rgba(232,192,127,.45); background: rgba(200,160,106,.12); color: #e8c07a; border-radius: 999px; font-size: 11px; padding: 3px 9px; cursor: pointer; font-family: inherit; transition: .2s; }
  .p-visit:hover { background: rgba(200,160,106,.26); }
  .p-spec { font-size: 11px; opacity: .6; margin-top: 2px; }
  .post { break-inside: avoid; margin-bottom: 14px; background: linear-gradient(180deg,#1e1e22,#161618); border: 1px solid #313136; border-radius: 14px; overflow: hidden; }
  .p-head { display: flex; align-items: center; gap: 8px; padding: 10px 12px 6px; }
  .p-ava { width: 28px; height: 28px; border-radius: 50%; background: linear-gradient(135deg,#c8a06a,#8a6428); color: #1d150d; font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
  .p-name { flex: 1; font-size: 13px; font-weight: 600; }
  .p-follow { border: 1px solid #4a4a52; background: transparent; color: #ddd6c8; border-radius: 999px; font-size: 11px; padding: 3px 10px; cursor: pointer; font-family: inherit; }
  .p-follow.on { background: #a8352c; border-color: #a8352c; color: #f7f1e3; }
  .p-follow.pending { border-color: #8a5a52; background: rgba(168, 53, 44, 0.14); color: #e6a89e; }
  .p-follow.pending:hover { background: rgba(168, 53, 44, 0.28); border-color: #c86d63; color: #ffd4cd; }
  .p-imgwrap { position: relative; background: radial-gradient(120% 90% at 50% 0%, #26262a, #0e0e10); display: flex; justify-content: center; padding: 14px 0 6px; }
  .p-imgwrap img { height: 190px; }
  .p-pref { position: absolute; top: 8px; left: 10px; font-size: 10.5px; background: rgba(0,0,0,.55); border: 1px solid rgba(232,192,127,.4); color: #e8c07a; padding: 2px 8px; border-radius: 999px; }
  .p-body { padding: 8px 12px 12px; }
  .p-sake { font-size: 14px; font-weight: 700; }
  .p-stars { color: #e8c07a; font-size: 12px; margin: 3px 0; letter-spacing: 2px; }
  .p-note { font-size: 12.5px; opacity: .8; line-height: 1.6; margin-bottom: 8px; }
  .p-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
  .p-act { border: 1px solid #3a3a40; background: transparent; color: #ddd6c8; border-radius: 999px; font-size: 11.5px; padding: 4px 10px; cursor: pointer; font-family: inherit; }
  .p-act.on { background: #a8352c; border-color: #a8352c; color: #f7f1e3; }
  .p-time { margin-left: auto; font-size: 10.5px; opacity: .45; }

  /* ---- 哪裡買 ---- */
  .frow { display: flex; align-items: center; gap: 14px; background: linear-gradient(180deg,#1e1e22,#161618); border: 1px solid #313136; border-radius: 12px; padding: 12px 16px; margin-bottom: 9px; }
  .fmain { flex: 1; min-width: 0; }
  .fname { font-size: 14px; font-weight: 700; }
  .fshop { font-size: 12px; opacity: .6; margin-top: 3px; }
  .fright { text-align: right; flex-shrink: 0; }
  .fprice { font-size: 15px; font-weight: 700; color: #e8c07a; }
  .fstock { font-size: 11px; margin-top: 2px; }
  .fstock.in_stock { color: #9fc98f; }
  .fstock.low { color: #e0a878; }
  .fstock.out_of_stock { color: #b06565; }
  .fnote { text-align: center; font-size: 11.5px; opacity: .45; margin-top: 14px; }

  /* ---- 想喝清單 ---- */
  .whead { font-size: 15px; font-weight: 700; letter-spacing: 2px; margin-bottom: 12px; }
  .wish-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
  .wcard { background: linear-gradient(180deg,#1e1e22,#161618); border: 1px solid #313136; border-radius: 12px; padding: 12px; text-align: center; }
  .wcard img { height: 110px; }
  .wname { font-size: 12px; font-weight: 600; margin: 8px 0; min-height: 32px; }
  .wremove { border: 1px solid #4a4a52; background: transparent; color: #ddd6c8; border-radius: 999px; font-size: 11px; padding: 3px 12px; cursor: pointer; font-family: inherit; }

  /* ---- 個人主頁 ---- */
  #profileCard { width: 640px; max-width: 96vw; margin: 0 auto; }
  .pfguest { text-align: center; padding: 40px 0; }
  .pf-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
  .pf-ava-wrap { position: relative; width: 60px; height: 60px; flex-shrink: 0; cursor: pointer; }
  .pf-ava { width: 60px; height: 60px; border-radius: 50%; background: linear-gradient(135deg,#c8a06a,#8a6428); color: #1d150d; font-size: 22px; font-weight: 700; display: flex; align-items: center; justify-content: center; overflow: hidden; border: 2px solid rgba(232,192,122,.45); }
  .pf-ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
  .pf-ava-cam { position: absolute; right: -2px; bottom: -2px; width: 22px; height: 22px; border-radius: 50%; background: #232328; border: 1.5px solid #c8a06a; color: #f0d9a0; font-size: 11px; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 6px rgba(0,0,0,.6); }
  .p-ava { overflow: hidden; }
  .p-ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
  .pf-name { font-size: 17px; font-weight: 700; }
  .pf-mail { font-size: 12px; opacity: .55; margin-top: 2px; }
  .pf-stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin: 14px 0 18px; }
  @media (max-width: 480px) { .pf-stats { grid-template-columns: repeat(6, 1fr); } .pf-stats > button:nth-child(-n+3) { grid-column: span 2; } .pf-stats > button:nth-child(n+4) { grid-column: span 3; } }
  .pf-stats > button { background: #1b1b1f; border: 1px solid #2e2e33; border-radius: 10px; padding: 10px 4px; text-align: center; color: inherit; font-family: inherit; cursor: pointer; transition: border-color .2s, transform .15s, background .2s; }
  .pf-stats > button:hover { border-color: #c8a06a; background: #232329; transform: translateY(-2px); }
  .pf-stats > button:active { transform: scale(.97); }
  .pf-stats b { display: block; font-size: 16px; color: #e8c07a; }
  .pf-stats span { font-size: 11px; opacity: .65; letter-spacing: .5px; }

  /* ---- 藏酒家等級稱號徽章與進度卡 ---- */
  .pf-name-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
  .pf-rank-badge {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 3px 10px; border-radius: 999px;
    font-size: 11.5px; font-weight: 700; letter-spacing: .4px;
    color: #f6dfad;
    background: linear-gradient(135deg, rgba(200,160,106,.24), rgba(138,100,40,.18));
    border: 1px solid rgba(232,192,122,.52);
    box-shadow: 0 2px 8px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,244,214,.18);
    cursor: pointer; font-family: inherit;
    transition: transform .18s, border-color .18s, box-shadow .18s;
  }
  .pf-rank-badge:hover {
    transform: translateY(-1px);
    border-color: #f0d090;
    box-shadow: 0 4px 12px rgba(200,160,106,.28), inset 0 1px 0 rgba(255,244,214,.25);
  }
  .pf-rank-badge.tier-mid {
    color: #ffe7b3;
    background: linear-gradient(135deg, rgba(220,175,105,.32), rgba(156,110,42,.26));
    border-color: rgba(242,202,126,.68);
  }
  .pf-rank-badge.tier-high {
    color: #1f160a;
    background: linear-gradient(135deg, #f3d492, #c8984c);
    border-color: #ffe8b5;
    box-shadow: 0 3px 12px rgba(224,176,94,.38);
  }
  .pf-rank-lv {
    font-size: 10px; font-weight: 800; padding: 1px 5px; border-radius: 999px;
    background: rgba(0,0,0,.32); color: #f6dfad; letter-spacing: .3px;
  }
  .pf-rank-badge.tier-high .pf-rank-lv {
    background: rgba(31,22,10,.82); color: #f8dfa4;
  }
  .pf-rank-card {
    background: linear-gradient(145deg, rgba(32,30,27,.92), rgba(22,21,24,.96));
    border: 1px solid rgba(200,160,106,.28);
    border-radius: 12px; padding: 12px 14px; margin: 12px 0 16px;
    cursor: pointer; transition: border-color .2s, transform .15s;
  }
  .pf-rank-card:hover { border-color: rgba(232,192,122,.6); transform: translateY(-1px); }
  body.theme-wood .pf-rank-card {
    background: linear-gradient(145deg, rgba(54,38,24,.88), rgba(34,23,14,.94));
    border-color: rgba(224,182,118,.34);
  }
  .pf-rank-top {
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    margin-bottom: 5px;
  }
  .pf-rank-title-grp { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; }
  .pf-rank-cn { font-size: 14.5px; font-weight: 700; color: #f0d49a; letter-spacing: .5px; }
  .pf-rank-en { font-size: 11px; color: #c8a06a; opacity: .82; font-style: italic; }
  .pf-rank-all {
    font-size: 11px; color: #d8b87c; opacity: .8; white-space: nowrap;
    border: 1px solid rgba(200,160,106,.28); border-radius: 999px; padding: 2px 8px;
  }
  .pf-rank-desc { font-size: 12px; opacity: .76; line-height: 1.55; margin-bottom: 9px; }
  .pf-rank-bar {
    height: 6px; border-radius: 999px; background: rgba(255,255,255,.08);
    overflow: hidden; position: relative;
  }
  .pf-rank-fill {
    height: 100%; border-radius: 999px;
    background: linear-gradient(90deg, #b88946, #f0cf8e);
    transition: width .45s cubic-bezier(.22,.8,.32,1);
  }
  .pf-rank-foot {
    display: flex; justify-content: space-between; align-items: center; gap: 8px;
    margin-top: 6px; font-size: 11px; opacity: .68;
  }
  .pf-rank-foot b { color: #e8c07a; font-weight: 600; }

  /* ---- 10 級稱號圖鑑彈窗 ---- */
  #rankMask { z-index: 126; }
  .rank-modal { width: 460px; max-height: 84vh; display: flex; flex-direction: column; padding: 18px; }
  .rank-modal h2 { margin-bottom: 6px; }
  .rank-sub { font-size: 12px; opacity: .7; margin-bottom: 12px; line-height: 1.5; }
  .rank-list { overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding-right: 2px; }
  .rank-item {
    border: 1px solid #2c2c32; background: #19191d; border-radius: 10px;
    padding: 10px 12px; transition: .18s;
  }
  .rank-item.unlocked { border-color: rgba(200,160,106,.32); }
  .rank-item.current {
    border-color: #e8c07a;
    background: linear-gradient(135deg, rgba(200,160,106,.18), rgba(40,34,26,.9));
    box-shadow: 0 2px 10px rgba(200,160,106,.18);
  }
  .rank-item.locked { opacity: .56; }
  .rank-item-hd { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
  .rank-item-name { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
  .rank-lv-tag {
    font-size: 10.5px; font-weight: 700; padding: 1px 7px; border-radius: 999px;
    background: rgba(200,160,106,.18); color: #e8c07a; border: 1px solid rgba(200,160,106,.35);
  }
  .rank-item.current .rank-lv-tag { background: #e8c07a; color: #1b140b; }
  .rank-item-cn { font-size: 13.5px; font-weight: 700; color: #f2dfb6; }
  .rank-item-en { font-size: 11px; color: #bfa06a; }
  .rank-item-req { font-size: 11px; opacity: .72; white-space: nowrap; }
  .rank-item-desc { font-size: 11.5px; opacity: .75; line-height: 1.5; }


  /* ---- IG 風格追蹤 / 粉絲酒友列表彈窗 ---- */
  #followMask { z-index: 125; }
  .ig-modal { width: 420px; max-height: 82vh; display: flex; flex-direction: column; padding: 18px 18px 16px; }
  .ig-modal h2 { margin-bottom: 10px; }
  .ig-tabs { display: flex; gap: 6px; margin-bottom: 10px; border-bottom: 1px solid #28282e; padding-bottom: 8px; }
  .ig-tab { flex: 1; background: #18181c; border: 1px solid #2f2f36; color: #bbb; border-radius: 8px; padding: 6px 8px; font-size: 12.5px; font-weight: 600; cursor: pointer; font-family: inherit; transition: .18s; }
  .ig-tab.on { background: linear-gradient(160deg,#c8a06a,#8a6428); border-color: transparent; color: #1d150d; font-weight: 700; }
  .ig-search { width: 100%; background: #101012; border: 1px solid #3a3a3f; color: #eee; border-radius: 10px; padding: 9px 12px; font-size: 13px; font-family: inherit; margin-bottom: 10px; }
  .ig-search:focus { outline: none; border-color: #c8a06a; }
  .ig-list { overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 4px; }
  .ig-row { display: flex; align-items: center; gap: 11px; padding: 9px 6px; border-bottom: 1px solid rgba(255,255,255,.06); }
  .ig-row:last-child { border-bottom: none; }
  .ig-ava { width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg,#c8a06a,#8a6428); color: #1d150d; font-weight: 700; font-size: 16px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; overflow: hidden; cursor: pointer; }
  .ig-ava img { width: 100%; height: 100%; object-fit: cover; }
  .ig-info { flex: 1; min-width: 0; cursor: pointer; }
  .ig-uname { font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .ig-sub { font-size: 11.5px; opacity: .55; margin-top: 2px; }
  .ig-btns { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
  .ig-cab { border: 1px solid rgba(232,192,127,.45); background: rgba(200,160,106,.12); color: #e8c07a; border-radius: 8px; font-size: 11.5px; padding: 5px 9px; cursor: pointer; font-family: inherit; }
  .ig-fbtn { border: 1px solid #4a4a52; background: #26262c; color: #eee; border-radius: 8px; font-size: 11.5px; font-weight: 600; padding: 5px 11px; cursor: pointer; font-family: inherit; min-width: 66px; }
  .ig-fbtn.primary { background: linear-gradient(160deg,#c8a06a,#8a6428); border-color: transparent; color: #1d150d; }
  .pf-row { display: flex; justify-content: space-between; align-items: center; padding: 12px 4px; border-bottom: 1px solid #26262b; font-size: 13.5px; }
  .pf-follows { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 0; }
  .pf-tag { font-size: 12px; background: #232327; border: 1px solid #3a3a40; border-radius: 999px; padding: 4px 12px; }
  .pf-sec { margin-top: 18px; padding-top: 16px; border-top: 1px solid #26262b; }
  .pf-sec-title { font-size: 13.5px; font-weight: 700; letter-spacing: 1.5px; color: #f0d9a0; margin-bottom: 12px; display: flex; justify-content: space-between; align-items: center; }
  .pf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .pf-grid .full { grid-column: 1 / -1; }
  .pf-field label { display: block; font-size: 11px; opacity: .65; margin-bottom: 4px; }
  .pf-field input, .pf-field select, .pf-field textarea {
    width: 100%; background: #141417; border: 1px solid #3a3a3f; color: #eee;
    border-radius: 8px; padding: 8px 10px; font-size: 13px; font-family: inherit;
  }
  .pf-field input:focus, .pf-field select:focus, .pf-field textarea:focus { outline: none; border-color: #c8a06a; }
  .pf-field input[readonly] { opacity: .6; cursor: not-allowed; }
  .pf-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }
  .pwd-wrap { position: relative; display: flex; align-items: center; }
  .pwd-wrap input { padding-right: 36px !important; }
  .pwd-eye {
    position: absolute; right: 8px; background: none; border: none; color: #9a907e;
    cursor: pointer; font-size: 13px; padding: 2px 4px; opacity: .75; transition: .2s;
  }
  .pwd-eye:hover { opacity: 1; color: #f0d9a0; }
  .pwd-rules {
    margin-top: 8px; padding: 9px 11px; border-radius: 8px;
    background: rgba(16, 16, 18, .75); border: 1px solid #2c2c32;
    font-size: 11.5px; line-height: 1.75; text-align: left;
  }
  .pwd-meter { height: 4px; border-radius: 2px; background: #26262b; overflow: hidden; margin-bottom: 6px; }
  .pwd-meter i { display: block; height: 100%; width: 0%; transition: width .25s, background .25s; }
  .pwd-rule { display: flex; align-items: center; gap: 6px; color: #8c8578; transition: color .2s; }
  .pwd-rule.ok { color: #9fc98f; }
  .pwd-rule b { font-weight: 700; width: 12px; display: inline-block; }

  .switch { position: relative; width: 44px; height: 24px; display: inline-block; }
  .switch input { display: none; }
  .switch i { position: absolute; inset: 0; background: #3a3a40; border-radius: 999px; transition: .2s; }
  .switch i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; background: #ddd; border-radius: 50%; transition: .2s; }
  .switch input:checked + i { background: #8a6428; }
  .switch input:checked + i::after { left: 23px; background: #f2cd87; }

  /* ---- 底部導覽 ---- */
  .bottomnav {
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 80;
    display: flex; justify-content: space-around;
    background: rgba(14,14,16,.93); backdrop-filter: blur(10px);
    border-top: 1px solid #2c2c31;
    padding: 6px 4px calc(8px + env(safe-area-inset-bottom));
  }
  .bottomnav button {
    flex: 1; max-width: 120px; border: none; background: transparent; color: inherit; opacity: .55;
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    font-size: 10.5px; letter-spacing: 1px; cursor: pointer; font-family: inherit; padding: 4px 0;
  }
  .bottomnav button i {
    font-style: normal; width: 26px; height: 26px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 700; background: rgba(255,255,255,.08); transition: .2s;
  }
  .bottomnav button.on { opacity: 1; }
  .bottomnav button.on i { background: #b8a06a; color: #1d150d; }
  body.theme-wood .bottomnav button.on i { background: #d9ac74; color: #241708; }

  /* ---- 桌面：置中 412px 手機模擬視窗；手機全螢幕 ---- */
  @media (min-width: 540px) {
    .app .feed { columns: 1; }
    body { background: #08080a; }
    .app {
      width: 412px; margin: 0 auto; min-height: 100vh;
      background: radial-gradient(700px 500px at 50% -10%, #262019, #100d0a 72%);
      border-left: 1px solid #26262b; border-right: 1px solid #26262b;
    }
    .app .carousel-wrap, .app .viewbar, .app #prefPanel, .app .visit-bar,
    .app #tab-explore, .app #tab-find, .app #tab-profile, .app #listView, .app #profileCard {
      max-width: 100%;
    }
    .bottomnav { left: 50%; right: auto; transform: translateX(-50%); width: 412px; border: 1px solid #2c2c31; border-bottom: none; border-radius: 18px 18px 0 0; }
    .fab { right: calc(50% - 184px); }
    .sheet { width: 412px; }
    #toast { bottom: 110px; }
  }

  /* ---- Toast ---- */
  #toast {
    position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 20px);
    z-index: 130; background: rgba(20,20,24,.94); border: 1px solid #4a4436; color: #eee;
    padding: 10px 18px; border-radius: 999px; font-size: 13px; letter-spacing: 1px;
    opacity: 0; pointer-events: none; transition: .3s; backdrop-filter: blur(6px);
  }
  #toast.show { opacity: 1; transform: translate(-50%, 0); }

  /* ---- 登入視窗 ---- */
  .login-modal { width: 400px; text-align: center; }
  .lbrand { display: flex; justify-content: center; margin-bottom: 6px; }
  .lbrand img { height: 74px; width: auto; display: block; mix-blend-mode: lighten; }
  .login-modal h2 { justify-content: center; letter-spacing: 3px; font-size: 19px; margin-top: 14px; }
  .lsub { font-size: 13px; opacity: .6; margin: -6px 0 18px; }
  .lbtn { display: block; width: 100%; margin-bottom: 10px; padding: 12px; border-radius: 10px; border: 1px solid rgba(255,255,255,.18); background: #232327; color: #eee; font-size: 14px; letter-spacing: 1px; cursor: pointer; font-family: inherit; transition: .2s; }
  .lbtn:hover { filter: brightness(1.15); }
  .lbtn.apple { background: #000; color: #fff; border: none; font-weight: 600; }
  .lbtn.google {
    background: #fff; color: #1f1f1f; border: 1px solid #dadce0; font-weight: 600;
    display: flex; align-items: center; justify-content: center; gap: 10px;
  }
  .lbtn.google:hover { background: #f7f8f8; filter: none; }
  .lbtn.google svg { width: 18px; height: 18px; flex-shrink: 0; }
  .auth-divider {
    display: flex; align-items: center; gap: 10px; margin: 12px 0;
    font-size: 11.5px; color: #8c8578; letter-spacing: 1px;
  }
  .auth-divider::before, .auth-divider::after {
    content: ''; flex: 1; height: 1px; background: rgba(255,255,255,.12);
  }
  .lbtn.email { background: linear-gradient(160deg,#c8a06a,#8a6428); color: #1d150d; border: none; font-weight: 700; }
  .auth-tabs { display: flex; gap: 6px; margin-bottom: 14px; background: #141417; padding: 4px; border-radius: 10px; border: 1px solid #2e2e34; }
  .auth-tab { flex: 1; background: transparent; border: none; color: #9a907e; padding: 8px 0; border-radius: 7px; font-size: 13.5px; font-weight: 700; letter-spacing: 1px; cursor: pointer; font-family: inherit; transition: .2s; }
  .auth-tab.on { background: linear-gradient(160deg,#c8a06a,#8a6428); color: #1d150d; }
  .lrow { margin-top: 14px; font-size: 12.5px; opacity: .75; display: flex; justify-content: center; gap: 10px; align-items: center; }
  .linkbtn { background: none; border: none; color: inherit; text-decoration: underline; cursor: pointer; font-family: inherit; font-size: 12.5px; }

  /* ---- 星級評分 / 公開分享 / 地圖標籤 ---- */
  .rate-row { display: flex; align-items: center; gap: 12px; }
  .rlabel { font-size: 11px; opacity: .6; }
  .stars button { background: none; border: none; cursor: pointer; font-size: 27px; color: #3f3f46; transition: color .15s, transform .15s; padding: 0 2px; font-family: inherit; }
  .stars button.on { color: #e8c07a; text-shadow: 0 0 8px rgba(232,192,122,.5); }
  .stars button:hover { transform: scale(1.15); }
  .rhint { font-size: 12px; color: #e0a878; }
  .pub-row { margin-top: -2px; }
  .pub-row input { accent-color: #8a6428; width: 15px; height: 15px; }
  .s-stars { display: inline-flex; align-items: center; gap: 2px; }
  .s-stars button { background: none; border: none; padding: 0 2px; font-size: 18px; line-height: 1; color: rgba(43,36,25,.28); cursor: pointer; transition: transform .15s, color .15s; font-family: inherit; }
  .s-stars button.on { color: #d48817; text-shadow: 0 0 6px rgba(212,136,23,.35); }
  .s-stars button:hover { transform: scale(1.18); }
  .s-stars.ro button { cursor: default; pointer-events: none; }
  .s-stars .s-rhint { font-size: 11.5px; color: #8c6229; margin-left: 6px; font-weight: 600; }
  .v-like-btn { border: 1px solid rgba(232,192,127,.55); background: rgba(200,160,106,.14); color: #f0d9a0; border-radius: 999px; padding: 4px 11px; font-size: 12px; cursor: pointer; font-family: inherit; transition: .2s; display: inline-flex; align-items: center; gap: 5px; }
  .v-like-btn.on { background: #a8352c; border-color: #a8352c; color: #fff; font-weight: 700; }

  /* ---- Onboarding 問卷 ---- */
  .onboard { width: 420px; }
  .onboard h2 { letter-spacing: 2px; }
  .osub { font-size: 12.5px; opacity: .6; margin: -6px 0 16px; }
  .oq { margin-bottom: 14px; }
  .oq-t { font-size: 13.5px; font-weight: 700; letter-spacing: 1px; margin-bottom: 8px; color: #f0d9a0; }
  .oopts { display: flex; gap: 8px; flex-wrap: wrap; }
  .oopts button { flex: 1; min-width: 100px; border: 1px solid #4a4a52; background: #1c1c20; color: #ddd6c8; border-radius: 10px; padding: 10px 8px; font-size: 13px; cursor: pointer; font-family: inherit; transition: .2s; }
  .oopts button.on { background: linear-gradient(160deg,#c8a06a,#8a6428); border-color: transparent; color: #1d150d; font-weight: 700; }
  #obSubmit { width: 100%; margin-top: 6px; }
  #obSubmit:disabled { opacity: .4; cursor: not-allowed; }

  /* ---- 地圖縣名標籤（透明底：白字 + 深色柔邊，紅/黃縣份皆清晰） ---- */
  .pref-label {
    fill: #fff; font-weight: 700; text-anchor: middle; pointer-events: none;
    opacity: 0; transition: opacity .3s; paint-order: stroke;
    stroke: rgba(15,12,8,.55); stroke-width: 2px;
  }
  .pref-label.show { opacity: 1; }

  footer.site-footer {
    text-align: center; margin: 40px auto 24px; padding: 22px 18px 8px; max-width: 560px;
    font-size: 11.5px; line-height: 1.9; color: #a89e8a; letter-spacing: .5px;
    border-top: 1px solid rgba(255,255,255,.1);
  }
  .sf-legal { opacity: .85; margin-bottom: 10px; }
  .sf-links { display: flex; justify-content: center; gap: 18px; margin-bottom: 10px; }
  .sf-links button { background: none; border: none; color: #d9c9a0; font-size: 12px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; font-family: inherit; padding: 0; }
  .sf-copy { opacity: .55; font-size: 11px; }

  /* ---- 年齡確認（Age Gate） ---- */
  #ageMask { background: rgba(8,8,10,.82); backdrop-filter: blur(14px); }
  .age-modal { width: 400px; text-align: center; }
  .age-modal .aseal { font-size: 34px; margin-bottom: 6px; }
  .age-modal p { font-size: 13px; line-height: 1.9; opacity: .85; margin: 10px 0 18px; }
  #ageNoMsg { display: none; color: #e8a87c; font-size: 12.5px; margin: -6px 0 14px; }
  .age-btns { display: flex; flex-direction: column; gap: 10px; }
  .age-btns .btn { width: 100%; }

  /* ---- 頂部通知鈴鐺 & 搜尋酒友按鈕 ---- */
  header.navbar {
    justify-content: space-between;
  }
  .nav-actions {
    display: flex; align-items: center; gap: 8px;
  }
  .icon-btn {
    position: relative; width: 38px; height: 38px; border-radius: 50%;
    border: 1px solid rgba(255,255,255,.16); background: rgba(255,255,255,.05);
    color: #e6dfd1; font-size: 16px; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: .2s;
  }
  .icon-btn:hover { background: rgba(200,160,106,.22); border-color: #c8a06a; }
  .notif-badge {
    position: absolute; top: -3px; right: -3px;
    min-width: 17px; height: 17px; padding: 0 4px; border-radius: 999px;
    background: #d43a2f; color: #fff; font-size: 10px; font-weight: 700;
    display: none; align-items: center; justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,.6);
  }
  .notif-badge.show { display: flex; }

  /* ---- 酒友搜尋列 ---- */
  .user-search-box {
    display: flex; gap: 8px; margin-bottom: 14px;
  }
  .user-search-box input {
    flex: 1; background: #17171a; border: 1px solid #3a3a3f; color: #eee;
    border-radius: 10px; padding: 9px 13px; font-size: 13.5px; font-family: inherit;
  }
  .user-search-box input:focus { outline: none; border-color: #c8a06a; }
  .user-search-results {
    background: #18181c; border: 1px solid #313136; border-radius: 12px;
    padding: 8px 12px; margin-bottom: 14px; display: none;
  }
  .user-search-results.show { display: block; }
  .usr-row {
    display: flex; align-items: center; gap: 10px; padding: 8px 2px;
    border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .usr-row:last-child { border-bottom: none; }
  .usr-ava {
    width: 36px; height: 36px; border-radius: 50%;
    background: linear-gradient(135deg,#c8a06a,#8a6428); color: #1d150d;
    font-weight: 700; font-size: 14px; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  }
  .usr-info { flex: 1; min-width: 0; }
  .usr-name { font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .usr-sub { font-size: 11px; opacity: .6; }
  .usr-act-btn {
    border: 1px solid #c8a06a; background: rgba(200,160,106,.16); color: #f0d9a0;
    border-radius: 999px; font-size: 11.5px; font-weight: 600; padding: 5px 12px;
    cursor: pointer; font-family: inherit; transition: .2s; white-space: nowrap;
  }
  .usr-act-btn.primary { background: linear-gradient(160deg,#c8a06a,#8a6428); border-color: transparent; color: #1d150d; }
  .usr-act-btn.pending { border-color: #555; background: #26262b; color: #aaa; cursor: default; }
  .usr-act-btn.accepted { border-color: #4f7a42; background: rgba(127,176,105,.18); color: #9fc98f; }

  /* ---- 通知中心 Modal ---- */
  #notifMask { z-index: 128; }
  .notif-modal { width: 430px; max-height: 82vh; display: flex; flex-direction: column; padding: 18px; }
  .notif-head-actions { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 12px; }
  .notif-list { overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 8px; }
  .notif-item {
    background: #19191d; border: 1px solid #2e2e34; border-radius: 10px;
    padding: 11px 12px; transition: .2s;
  }
  .notif-item.unread {
    border-color: rgba(200,160,106,.55);
    background: linear-gradient(145deg, rgba(200,160,106,.12), #19191d);
  }
  .notif-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; margin-bottom: 4px; }
  .notif-title { font-size: 13px; font-weight: 700; color: #f0d9a0; }
  .notif-time { font-size: 10.5px; opacity: .5; white-space: nowrap; }
  .notif-body { font-size: 12.5px; opacity: .85; line-height: 1.55; }
  .notif-btns { display: flex; gap: 8px; margin-top: 9px; }
  .notif-btns button {
    flex: 1; padding: 6px 10px; border-radius: 8px; font-size: 12px; font-weight: 700;
    cursor: pointer; font-family: inherit; border: none;
  }
  .nbtn-accept { background: linear-gradient(160deg,#c8a06a,#8a6428); color: #1d150d; }
  .nbtn-reject { background: #28282e; color: #ccc; border: 1px solid #444 !important; }
  .notif-status-tag { display: inline-block; margin-top: 6px; font-size: 11px; padding: 2px 8px; border-radius: 999px; background: rgba(255,255,255,.07); opacity: .75; }


  /* ================= Pro 4大療癒與社交玩法樣式 ================= */
  .pro-pill-tag {
    display: inline-flex; align-items: center; gap: 3px;
    font-size: 10px; font-weight: 800; letter-spacing: .5px;
    padding: 1px 6px; border-radius: 999px;
    background: linear-gradient(135deg, #f3d492, #c8984c);
    color: #1f160a; margin-left: 4px; vertical-align: middle;
  }
  .pro-ribbon {
    display: flex; align-items: center; justify-content: flex-end; gap: 7px;
    margin-top: 2px;
  }
  .pro-ribbon-label { font-size: 11px; letter-spacing: 1px; color: #c8a06a; opacity: .85; margin-right: 1px; }
  .pro-icon-btn {
    width: 34px; height: 34px; border-radius: 50%; padding: 0;
    border: 1px solid rgba(232,192,127,.4);
    background: rgba(30,26,20,.72); font-size: 15px; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
    transition: .2s; font-family: inherit;
  }
  .pro-icon-btn:hover { background: rgba(200,160,106,.28); transform: translateY(-1px); }
  .pro-action-pill {
    border: 1px solid rgba(232,192,127,.42);
    background: linear-gradient(145deg, rgba(200,160,106,.16), rgba(30,26,20,.7));
    color: #f4dfb2; padding: 5px 10px; border-radius: 999px;
    font-size: 11.5px; font-weight: 600; cursor: pointer;
    letter-spacing: .5px; transition: .2s; font-family: inherit;
    display: inline-flex; align-items: center; gap: 4px;
  }
  .pro-action-pill:hover {
    background: linear-gradient(145deg, rgba(220,178,116,.3), rgba(52,42,28,.85));
    border-color: #f0d090; transform: translateY(-1px);
  }
  .pro-action-pill.on {
    background: linear-gradient(160deg, #c8a06a, #8a6428);
    color: #1d150d; border-color: transparent; font-weight: 700;
  }

  /* 1. 酒櫃精裝修與 3D 療癒小物 (Cabinet Deco & Props) */
  .slot.prop-slot {
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    padding: 0 2px;
  }
  .prop-3d {
    position: relative; z-index: 2;
    width: 66px; height: 92px;
    display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
    transform-origin: bottom center;
    transition: transform .32s cubic-bezier(.2,.75,.3,1.15), filter .3s;
    filter: drop-shadow(0 6px 6px rgba(0,0,0,.55));
    user-select: none;
  }
  .slot.prop-slot:hover .prop-3d {
    transform: translateY(-10px) scale(1.08);
    filter: drop-shadow(0 14px 12px rgba(0,0,0,.65));
  }
  .prop-3d svg {
    width: 62px; height: 74px; display: block; overflow: visible;
  }
  .prop-tag {
    font-size: 9.5px; letter-spacing: .5px; color: #f0d9a0;
    background: rgba(14,12,10,.72); border: 1px solid rgba(232,192,127,.35);
    padding: 1px 6px; border-radius: 999px; margin-top: -2px;
    opacity: 0; transition: opacity .2s; white-space: nowrap;
  }
  .slot.prop-slot:hover .prop-tag { opacity: 1; }
  .slot.empty.deco-ready::after {
    content: '＋擺飾';
    display: flex; align-items: center; justify-content: center;
    font-size: 10px; color: #e8c07a; letter-spacing: 1px;
    border-color: rgba(232,192,127,.55);
    background: rgba(200,160,106,.08);
    cursor: pointer;
  }
  .slot.empty.deco-ready:hover::after {
    background: rgba(200,160,106,.22);
    border-style: solid;
  }
  .deco-drawer {
    width: 960px; max-width: 96vw; margin: 0 auto 12px;
    background: linear-gradient(180deg, #221f1a, #161411);
    border: 1px solid rgba(232,192,127,.4); border-radius: 12px;
    padding: 12px 14px; display: none;
  }
  .deco-drawer.show { display: block; }
  .deco-drawer-hd {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 10px; gap: 8px; flex-wrap: wrap;
  }
  .deco-grid {
    display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px;
  }
  @media (max-width: 460px) { .deco-grid { grid-template-columns: repeat(3, 1fr); } }
  .deco-card {
    background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.12);
    border-radius: 10px; padding: 8px 4px; text-align: center; cursor: pointer;
    transition: .2s; color: #eee; font-family: inherit;
  }
  .deco-card:hover { border-color: #c8a06a; background: rgba(200,160,106,.14); }
  .deco-card.sel { border-color: #f0d090; background: rgba(200,160,106,.24); box-shadow: 0 0 12px rgba(232,192,127,.25); }
  .deco-card svg { width: 42px; height: 48px; margin: 0 auto 4px; display: block; }
  .deco-card span { display: block; font-size: 11px; font-weight: 600; }

  /* 2. 微醺回憶錄 (Tipsy Diary: 心情標籤 + 場景貼紙 + 聚餐相片) */
  .diary-box {
    margin-top: 8px; padding: 9px 11px; border-radius: 10px;
    background: rgba(43,36,25,.06); border: 1px dashed rgba(43,36,25,.25);
  }
  .diary-chips { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 6px; }
  .diary-chip {
    font-size: 11px; padding: 2px 8px; border-radius: 999px;
    background: rgba(168,53,44,.12); color: #8c271e; font-weight: 600;
    border: 1px solid rgba(168,53,44,.25);
  }
  .diary-sticker {
    font-size: 11px; padding: 2px 8px; border-radius: 999px;
    background: rgba(138,100,40,.14); color: #5c4014; font-weight: 600;
    border: 1px solid rgba(138,100,40,.28);
  }
  .diary-photo {
    width: 100%; max-height: 150px; object-fit: cover; border-radius: 8px;
    margin-top: 6px; border: 1px solid rgba(43,36,25,.2); display: block;
  }
  .tag-picker { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
  .tag-opt {
    border: 1px solid #4a4a52; background: #18181c; color: #ddd6c8;
    border-radius: 999px; padding: 4px 10px; font-size: 11.5px; cursor: pointer;
    font-family: inherit; transition: .18s;
  }
  .tag-opt.on {
    background: linear-gradient(160deg, #c8a06a, #8a6428);
    border-color: transparent; color: #1d150d; font-weight: 700;
  }
  .diary-photo-bar {
    display: flex; align-items: center; gap: 8px; margin-top: 6px; flex-wrap: wrap;
  }
  .diary-thumb {
    width: 48px; height: 48px; border-radius: 8px; object-fit: cover;
    border: 1px solid #c8a06a;
  }
  .pmap-story-bar {
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    flex-wrap: wrap; padding: 8px 10px; margin-top: 6px;
    border-top: 1px solid rgba(255,255,255,.08); font-size: 12px;
  }

  /* 3. 乾杯足跡、酒友緣分值 & Kampai! 動態特效 */
  .affinity-badge {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 11px; font-weight: 700; color: #f6dfad;
    background: linear-gradient(135deg, rgba(168,53,44,.28), rgba(200,160,106,.2));
    border: 1px solid rgba(232,192,127,.45);
    padding: 3px 10px; border-radius: 999px; margin-top: 4px;
  }
  .kampai-btn {
    border: 1px solid rgba(242,202,126,.65);
    background: linear-gradient(135deg, #f3d492, #c8984c);
    color: #1f160a; border-radius: 999px; padding: 4px 12px;
    font-size: 12px; font-weight: 800; cursor: pointer; font-family: inherit;
    display: inline-flex; align-items: center; gap: 4px;
    box-shadow: 0 2px 10px rgba(200,160,106,.3); transition: .2s;
  }
  .kampai-btn:hover { transform: scale(1.05); }
  .kampai-overlay {
    position: fixed; inset: 0; z-index: 220; pointer-events: none;
    display: none; align-items: center; justify-content: center; flex-direction: column;
    background: radial-gradient(circle at center, rgba(200,160,106,.24), rgba(0,0,0,.62));
    backdrop-filter: blur(2px);
  }
  .kampai-overlay.show { display: flex; animation: kampaiFade 2.5s ease forwards; }
  .kampai-cups {
    display: flex; align-items: center; justify-content: center; gap: 16px;
    font-size: 68px; filter: drop-shadow(0 8px 24px rgba(240,208,144,.65));
  }
  .kampai-cups .cup-l { animation: clinkL .75s cubic-bezier(.2,.9,.3,1.2) forwards; }
  .kampai-cups .cup-r { animation: clinkR .75s cubic-bezier(.2,.9,.3,1.2) forwards; }
  .kampai-spark {
    font-size: 30px; font-weight: 900; letter-spacing: 3px; color: #ffe7b3;
    text-shadow: 0 2px 14px rgba(232,192,127,.9); margin-top: 8px;
    animation: sparkPop .75s ease forwards;
  }
  .kampai-sub {
    font-size: 13.5px; color: #f7f1e3; background: rgba(20,18,15,.85);
    border: 1px solid rgba(232,192,127,.5); padding: 6px 16px; border-radius: 999px;
    margin-top: 10px;
  }
  @keyframes clinkL {
    0% { transform: translateX(-60px) rotate(-18deg) scale(.8); opacity: 0; }
    55% { transform: translateX(8px) rotate(14deg) scale(1.12); opacity: 1; }
    100% { transform: translateX(0) rotate(6deg) scale(1); opacity: 1; }
  }
  @keyframes clinkR {
    0% { transform: translateX(60px) rotate(18deg) scale(.8); opacity: 0; }
    55% { transform: translateX(-8px) rotate(-14deg) scale(1.12); opacity: 1; }
    100% { transform: translateX(0) rotate(-6deg) scale(1); opacity: 1; }
  }
  @keyframes sparkPop {
    0% { transform: scale(.4); opacity: 0; }
    60% { transform: scale(1.15); opacity: 1; }
    100% { transform: scale(1); opacity: 1; }
  }
  @keyframes kampaiFade {
    0%, 78% { opacity: 1; }
    100% { opacity: 0; }
  }
  .visitor-row {
    display: flex; align-items: center; gap: 10px; padding: 10px 6px;
    border-bottom: 1px solid rgba(255,255,255,.07);
  }
  .visitor-row:last-child { border-bottom: none; }

  /* 4. 「今日喝哪支？」3D 轉盤抽籤器 (Sake Roulette) */
  .slot.roulette-spot .bottle {
    transform: translateY(-18px) scale(1.1) !important;
    filter: drop-shadow(0 0 18px rgba(255,225,140,.98)) drop-shadow(0 16px 16px rgba(0,0,0,.75)) !important;
  }
  .slot.roulette-spot::before {
    content: ''; position: absolute; inset: -14px -8px -4px;
    background: radial-gradient(ellipse at center, rgba(255,232,165,.42) 0%, transparent 72%);
    border-radius: 50%; z-index: 1; pointer-events: none;
  }
  .roulette-modal { width: 420px; text-align: center; }
  .roulette-stage {
    position: relative; margin: 10px auto 14px; padding: 18px 14px;
    border-radius: 14px;
    background: radial-gradient(circle at 50% 25%, rgba(232,192,127,.22), #121110 76%);
    border: 1px solid rgba(232,192,127,.4);
  }
  .roulette-bottle-img {
    height: 176px; width: auto; margin: 0 auto 10px; display: block;
    filter: drop-shadow(0 12px 18px rgba(0,0,0,.7));
    transition: transform .25s ease;
  }
  .roulette-quote {
    font-size: 13px; line-height: 1.7; color: #f4dfb2;
    background: rgba(200,160,106,.12); border: 1px solid rgba(200,160,106,.3);
    border-radius: 10px; padding: 9px 12px; margin-top: 10px;
  }
  .story-preview-wrap {
    margin: 10px auto; text-align: center;
  }
  .story-preview-wrap img {
    max-width: 240px; width: 100%; border-radius: 14px;
    border: 1px solid rgba(232,192,127,.45);
    box-shadow: 0 12px 32px rgba(0,0,0,.75);
  }
