/* 票域 Tickyo — 售票前端设计系统
   与后台「深空紫」完全分开：纸感浅底 + 墨黑 + 珊瑚橙点缀。
   只用一个强调色，圆角统一，阴影克制。 */

:root{
  /* 底色与层次 */
  --paper:#FAFAF8;          /* 页面底，带一点暖 */
  --surface:#FFFFFF;
  --surface-2:#F4F3F0;      /* 次级块、输入框底 */
  --line:#E7E5E0;
  --line-2:#D8D5CE;

  /* 文字三级 */
  --ink:#16171B;
  --ink-2:#5B5E66;
  --ink-3:#8B8E96;

  /* 强调色：珊瑚橙 */
  --brand:#F04E23;
  --brand-ink:#FFFFFF;
  --brand-dark:#C93C16;
  --brand-wash:#FDECE6;     /* 8% 底 */
  --brand-rgb:240,78,35;

  /* 语义色（不当强调色用） */
  --ok:#0E8F5E;
  --ok-wash:#E6F4EE;
  --warn:#B4690E;
  --warn-wash:#FBF0DF;
  --err:#C62B2B;
  --err-wash:#FBEAEA;

  --sans:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',
         'PingFang SC','Microsoft YaHei',sans-serif;
  --mono:'JetBrains Mono','SF Mono',ui-monospace,Consolas,monospace;

  --r:14px;                 /* 卡片圆角 */
  --r-sm:10px;
  --r-pill:999px;
  --ease:cubic-bezier(.2,.7,.2,1);
  --shadow:0 1px 2px rgba(20,22,26,.04),0 8px 24px rgba(20,22,26,.06);
  --shadow-lg:0 2px 6px rgba(20,22,26,.06),0 18px 48px rgba(20,22,26,.12);
  --head-h:64px;
}

*{box-sizing:border-box}
html,body{margin:0;padding:0}
body{
  background:var(--paper);color:var(--ink);font-family:var(--sans);
  font-size:15px;line-height:1.65;-webkit-font-smoothing:antialiased;
}
::selection{background:var(--brand);color:var(--brand-ink)}
img{display:block;max-width:100%}
a{color:inherit;text-decoration:none}
button,input,select,textarea{font:inherit;color:inherit}
.num{font-family:var(--mono);font-variant-numeric:tabular-nums}
:focus-visible{outline:2px solid var(--brand);outline-offset:2px;border-radius:6px}

/* ── 布局 ───────────────────────────── */
.wrap{max-width:1180px;margin:0 auto;padding-inline:20px}
.wrap-narrow{max-width:780px;margin:0 auto;padding-inline:20px}
.stack{display:flex;flex-direction:column}
.row{display:flex;align-items:center;gap:12px}
.spread{display:flex;align-items:center;justify-content:space-between;gap:16px}
.grow{flex:1;min-width:0}

/* ── 顶栏 ───────────────────────────── */
.head{
  position:sticky;top:0;z-index:50;height:var(--head-h);
  background:rgba(250,250,248,.82);backdrop-filter:blur(14px);
  -webkit-backdrop-filter:blur(14px);border-bottom:1px solid var(--line);
}
.head .wrap{height:100%;display:flex;align-items:center;gap:22px}
.logo{display:flex;align-items:center;gap:9px;font-weight:650;font-size:17px;
  letter-spacing:-.01em;flex:0 0 auto}
.logo .mk{width:28px;height:28px;flex:0 0 auto;color:var(--brand);display:block}
.logo:hover .mk{color:var(--brand-dark)}
/* the footer dims its text, but the wordmark should stay full strength */
.foot .logo{color:var(--ink)}
.nav{display:flex;gap:4px;margin-left:6px}
.nav a{padding:7px 12px;border-radius:var(--r-pill);color:var(--ink-2);
  font-size:14.5px;transition:background .18s var(--ease),color .18s var(--ease)}
.nav a:hover{background:var(--surface-2);color:var(--ink)}
.nav a.on{color:var(--brand);background:var(--brand-wash);font-weight:550}
.head .right{margin-left:auto;display:flex;align-items:center;gap:10px}
.burger{display:none;width:36px;height:36px;border-radius:var(--r-sm);
  border:1px solid var(--line);background:var(--surface);cursor:pointer}

/* ── 按钮 ───────────────────────────── */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  padding:10px 18px;border-radius:var(--r-pill);border:1px solid transparent;
  background:var(--surface-2);color:var(--ink);font-size:14.5px;font-weight:550;
  cursor:pointer;white-space:nowrap;
  transition:background .18s var(--ease),border-color .18s var(--ease),
             transform .12s var(--ease),box-shadow .18s var(--ease);
}
.btn:hover{background:var(--line)}
.btn:active{transform:translateY(1px)}
.btn-primary{background:var(--brand);color:var(--brand-ink);
  box-shadow:0 4px 14px rgba(var(--brand-rgb),.28)}
.btn-primary:hover{background:var(--brand-dark);box-shadow:0 6px 20px rgba(var(--brand-rgb),.34)}
.btn-ghost{background:transparent;border-color:var(--line-2);color:var(--ink)}
.btn-ghost:hover{background:var(--surface-2)}
.btn-lg{padding:14px 26px;font-size:16px}
.btn-block{width:100%}
.btn:disabled{opacity:.45;cursor:not-allowed;transform:none}

/* ── 卡片 ───────────────────────────── */
.card{background:var(--surface);border:1px solid var(--line);
  border-radius:var(--r);box-shadow:var(--shadow)}
.card-pad{padding:22px}

/* ── 标签 ───────────────────────────── */
.tag{display:inline-flex;align-items:center;gap:5px;padding:3px 10px;
  border-radius:var(--r-pill);background:var(--surface-2);color:var(--ink-2);
  font-size:12px;font-weight:500;white-space:nowrap}
.tag-brand{background:var(--brand-wash);color:var(--brand-dark)}
.tag-ok{background:var(--ok-wash);color:var(--ok)}
.tag-warn{background:var(--warn-wash);color:var(--warn)}
.tag-err{background:var(--err-wash);color:var(--err)}

/* ── 区块标题 ───────────────────────── */
.sec{display:flex;align-items:flex-end;gap:14px;margin:44px 0 18px}
.sec h2{margin:0;font-size:21px;font-weight:650;letter-spacing:-.015em}
.sec p{margin:0;color:var(--ink-3);font-size:13.5px}
.sec .more{margin-left:auto;color:var(--brand);font-size:14px;font-weight:550}
.sec .more:hover{text-decoration:underline}

/* ── 演出卡片 ───────────────────────── */
.grid{display:grid;gap:20px;grid-template-columns:repeat(auto-fill,minmax(216px,1fr))}
.ev{display:flex;flex-direction:column;border-radius:var(--r);overflow:hidden;
  background:var(--surface);border:1px solid var(--line);
  transition:transform .2s var(--ease),box-shadow .2s var(--ease),
             border-color .2s var(--ease)}
.ev:hover{transform:translateY(-3px);box-shadow:var(--shadow-lg);border-color:var(--line-2)}
.ev .ph{position:relative;aspect-ratio:3/4;background:var(--surface-2);overflow:hidden}
.ev .ph img{width:100%;height:100%;object-fit:cover;
  transition:transform .4s var(--ease)}
.ev:hover .ph img{transform:scale(1.04)}
.ev .badge{position:absolute;top:10px;left:10px;padding:4px 10px;
  border-radius:var(--r-pill);font-size:11.5px;font-weight:600;
  background:rgba(255,255,255,.94);backdrop-filter:blur(6px);color:var(--ink)}
.ev .badge.hot{background:var(--brand);color:var(--brand-ink)}
.ev .bd{padding:13px 14px 15px;display:flex;flex-direction:column;gap:5px;flex:1}
.ev .ti{font-size:14.5px;font-weight:600;line-height:1.4;letter-spacing:-.005em;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.ev .meta{font-size:12.5px;color:var(--ink-3)}
.ev .price{margin-top:auto;padding-top:9px;font-size:14px;font-weight:650;
  color:var(--brand);font-family:var(--mono);font-variant-numeric:tabular-nums}
.ev .price small{font-family:var(--sans);font-weight:500;color:var(--ink-3);
  font-size:12px;margin-right:2px}
/* 首单折扣：卡片上也要看得见。原价压暗划掉，折后价保持品牌色 —— 只显示
   折后价的话客户不知道便宜了多少，那就白折了。 */
.ev .price .was{color:var(--ink-3);font-weight:500;font-size:.86em;
  margin-right:5px;text-decoration:line-through}
.ev .price .now{color:var(--brand)}
/* 票面价那一行。大字是客人自己的货币（换算的），这一行是票面上真正的数字和
   币种 —— 他拿到的票、我们收款的凭据都是它。压暗、缩小，但不能不显示。
   换算不出来时这一行根本不会生成，所以不用管它空着的样子。
   注意要盖过上面 .ev .price small 的 margin-right，那是给 "from" 用的。 */
.ev .price .face{display:block;margin:1px 0 0;font-family:var(--sans);
  font-weight:500;font-size:11.5px;color:var(--ink-3)}

/* ── 表单 ───────────────────────────── */
.field{display:flex;flex-direction:column;gap:7px;margin-bottom:16px}
.field label{font-size:13.5px;font-weight:550;color:var(--ink-2)}
.field .hint{font-size:12.5px;color:var(--ink-3)}
.input{
  width:100%;padding:12px 14px;border-radius:var(--r-sm);
  border:1px solid var(--line-2);background:var(--surface);font-size:15px;
  transition:border-color .18s var(--ease),box-shadow .18s var(--ease);
}
.input::placeholder{color:var(--ink-3)}
.input:focus{outline:none;border-color:var(--brand);
  box-shadow:0 0 0 3px rgba(var(--brand-rgb),.13)}
.input.bad{border-color:var(--err);box-shadow:0 0 0 3px rgba(198,43,43,.1)}
.err-msg{color:var(--err);font-size:12.5px;min-height:1em}
.grid-2{display:grid;grid-template-columns:1fr 1fr;gap:0 14px}

/* ── 分段控件 ───────────────────────── */
.seg{display:inline-flex;padding:4px;gap:4px;border-radius:var(--r-pill);
  background:var(--surface-2);border:1px solid var(--line)}
.seg button{padding:8px 18px;border-radius:var(--r-pill);border:0;
  background:transparent;color:var(--ink-2);font-size:14px;font-weight:550;
  cursor:pointer;transition:background .18s var(--ease),color .18s var(--ease)}
.seg button.on{background:var(--surface);color:var(--ink);box-shadow:var(--shadow)}

/* ── 提示条 ─────────────────────────── */
.note{display:flex;gap:11px;padding:13px 16px;border-radius:var(--r-sm);
  font-size:13.5px;line-height:1.6}
.note-warn{background:var(--warn-wash);color:#7A4708;
  border:1px solid rgba(180,105,14,.22)}
.note-info{background:var(--surface-2);color:var(--ink-2);border:1px solid var(--line)}
/* 预售提示。比 info 醒目一档：这块字是客户掏钱前唯一会读的说明，
   沉到灰底里就没人看了。正文仍用 --ink，只有底色带品牌色。 */
.note-brand{background:var(--brand-wash);color:var(--ink);
  border:1px solid rgba(var(--brand-rgb),.22)}
.note b{font-weight:650}

/* 开票提醒按钮。长在 .note-brand 里面，所以**不能**用实心主色 —— 那块底色
   本来就是品牌色，再放一个实心按钮两片颜色会糊在一起，按钮反而看不见。
   设过之后换成灰描边：已经答应的事不需要再喊。 */
.remind{margin-top:13px;padding:8px 14px;font-size:13px;line-height:1.3;
  border-radius:9px;border:1px solid rgba(var(--brand-rgb),.45);
  background:transparent;color:var(--brand-dark);font-weight:600;
  cursor:pointer;display:inline-flex;align-items:center;gap:7px;
  font-family:inherit;transition:background .15s,border-color .15s,color .15s}
.remind:hover{background:rgba(var(--brand-rgb),.09)}
.remind.on{border-color:var(--line-2);color:var(--ink-2);background:var(--surface)}
.remind:disabled{opacity:.5;cursor:default}

/* ── 页脚 ───────────────────────────── */
.foot{margin-top:72px;border-top:1px solid var(--line);background:var(--surface);
  padding:40px 0 48px;color:var(--ink-3);font-size:13.5px}
.foot .cols{display:grid;grid-template-columns:2fr 1fr 1fr 1fr;gap:32px}
.foot h4{margin:0 0 12px;font-size:13px;color:var(--ink);font-weight:650}
.foot a{display:block;padding:4px 0;color:var(--ink-3)}
.foot a:hover{color:var(--brand)}
/* 保障行：抢不到全额退款 + 安全支付 + 卡组织标志。欧美客人付款前最看这两样 */
.foot .trust{margin-top:32px;padding-top:20px;border-top:1px solid var(--line);
  display:flex;align-items:center;justify-content:space-between;gap:16px 28px;flex-wrap:wrap}
.foot .trust-msg{display:flex;gap:10px 24px;flex-wrap:wrap}
.foot .trust-item{display:inline-flex;align-items:center;gap:8px;color:var(--ink-2,var(--ink));font-weight:550}
.foot .trust-item svg{width:18px;height:18px;flex:none;color:#1a8a4a}
.foot .pay-marks{display:flex;gap:6px;flex-wrap:wrap}
.foot .pay-marks img{display:block;width:38px;height:24px}
.foot .trust + .bottom{margin-top:20px}
.foot .bottom{margin-top:32px;padding-top:20px;border-top:1px solid var(--line);
  display:flex;gap:16px;flex-wrap:wrap;font-size:12.5px}

/* ── 文档页（隐私 / 退款）───────────── */
.doc h1{font-size:30px;font-weight:680;letter-spacing:-.02em;margin:0 0 6px}
.doc .updated{color:var(--ink-3);font-size:13.5px;margin-bottom:30px}
.doc h2{font-size:18px;font-weight:650;margin:34px 0 10px;letter-spacing:-.01em}
.doc h3{font-size:15.5px;font-weight:600;margin:22px 0 8px}
.doc p,.doc li{color:var(--ink-2);font-size:15px;line-height:1.8}
.doc ul{padding-left:20px}
.doc li{margin-bottom:6px}
.doc table{width:100%;border-collapse:collapse;margin:16px 0;font-size:14px}
.doc th{text-align:left;font-weight:600;background:var(--surface-2);
  padding:11px 14px;border:1px solid var(--line)}
.doc td{padding:11px 14px;border:1px solid var(--line);color:var(--ink-2)}
.toc{background:var(--surface);border:1px solid var(--line);
  border-radius:var(--r);padding:18px 22px;margin-bottom:8px}
.toc a{display:block;padding:5px 0;font-size:14px;color:var(--ink-2)}
.toc a:hover{color:var(--brand)}

/* ── 空状态 ─────────────────────────── */
.empty{padding:56px 20px;text-align:center;color:var(--ink-3)}
.empty .big{font-size:34px;margin-bottom:10px}
.empty p{margin:6px 0 18px;font-size:14px}

/* ── 响应式 ─────────────────────────── */
@media(max-width:900px){
  .foot .cols{grid-template-columns:1fr 1fr;gap:26px}
}
/* the menu copy of Sign up exists only for the collapsed header */
.nav [data-nav="signup"]{display:none}

@media(max-width:720px){
  .nav.open [data-nav="signup"]{display:block}
  .nav{display:none}
  .nav.open{display:flex;position:absolute;top:var(--head-h);left:0;right:0;
    flex-direction:column;background:var(--surface);border-bottom:1px solid var(--line);
    padding:10px 14px;gap:2px;box-shadow:var(--shadow)}
  .burger{display:block}
  .grid{grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:14px}
  .grid-2{grid-template-columns:1fr}
  /* title and its hint stack rather than fighting for one line */
  .sec{margin:32px 0 14px;flex-direction:column;align-items:flex-start;gap:3px}
  .sec h2{font-size:18px}
  .sec .hint,.sec .more{margin-left:0;text-align:left}
  /* leave room for the chat launcher so it never covers the last row */
  body{padding-bottom:64px}
}

/* Policy tables are wider than a phone. Let them scroll inside their own
   box instead of dragging the whole page sideways. */
.tscroll{overflow-x:auto;-webkit-overflow-scrolling:touch;margin:16px 0}
.tscroll table{margin:0}
@media(max-width:720px){
  .tscroll table{min-width:560px}
  .doc table{font-size:13.5px}
  .doc th,.doc td{padding:9px 11px}
}

/* 430–560 这一档原来没人管，于是页眉挤不下会折行：宽度还没到 430，「註冊」
   按钮没被收起来，六样东西（logo、下拉、登入、註冊、汉堡）加上 22px 的间隙
   一共要 530 多。
   算一下 460px：40 + logo 100 + 间隙 88 + 下拉 140 + 登入 64 + 註冊 64 +
   汉堡 36 = 532px。所以这一档先把间隙收掉、註冊挪进汉堡菜单（app.js 本来就
   往菜单里放了一份），再把下拉收窄。重算 380px，宽松。 */
@media(max-width:560px){
  .head .wrap{gap:10px}
  .head .right{gap:8px}
  .head .right .btn-primary{display:none}
  .combo-pick select{max-width:110px}
}

/* Below ~430px the logo, both auth buttons and the burger stop fitting.
   Sign up moves into the menu; Sign in stays.

   页眉现在有**两个**下拉（语言 + 货币）。算一下 430px 的屏：
   padding 28 + logo 100 + 间隙 36 + 语言 104 + 货币 78 + 按钮 80 + 汉堡 34
   = 460px，比屏幕还宽。结果整页能横向滚，内容看着像被切掉一块 ——
   结账页那种字多的页面尤其明显。加货币下拉之前是 382px，刚好塞得下。

   所以这一档把 logo 收成只剩图标（font-size:0 把文字吃掉，图标自己有尺寸），
   两个下拉再收窄，间隙也收一点。重算：24+32+72+66+80+34+28 = 336px，
   360 的屏也装得下。 */
@media(max-width:430px){
  .head .wrap{gap:8px;padding:0 14px}
  .wrap,.wrap-narrow{padding-inline:14px}
  /* 合并成一个下拉之后省出了地方，logo 的字可以留着 —— 只剩一个橙方块，
     人会以为图裂了。缩小就够。
     重算 360px：28 + logo 85 + 间隙 24 + 下拉 100 + 登入 56 + 汉堡 34 = 327px。 */
  .logo{font-size:14px;gap:6px}
  .logo .mk{width:24px;height:24px}
  .lang-pick,.cur-pick{margin-right:0;min-width:0}
  .lang-pick select{max-width:72px;padding:6px 18px 6px 6px;font-size:12px}
  .cur-pick select{max-width:66px;padding:6px 18px 6px 6px;font-size:12px}
  /* 合起来的只有一个，省下来的地方给它 —— 「繁體中文 · HK$」要放得下。
     重算：28 + 图标 26 + 间隙 24 + 这个 124 + 按钮 80 + 汉堡 34 = 316px。 */
  /* 窄屏上语言名走短写（EN / 繁中），所以 100px 够放下「· HK$」那半截。 */
  .combo-pick select{max-width:104px;padding:6px 17px 6px 7px;font-size:12px}
  .head .right{gap:8px;min-width:0}
  .head .right .btn{padding:8px 11px;font-size:13px}
  .head .right .btn-primary{display:none}
  .burger{width:34px;height:34px;flex:0 0 auto}
  h1{overflow-wrap:anywhere}
}
/* 320px（老 iPhone SE、部分安卓机）还差最后十几个像素。logo 只留图标
   ——到这个宽度谁都知道左上角那个方块是回首页，文字是奢侈品；下拉再收一点，
   短写「繁中 · ¥」放得下。重算 306px。 */
@media(max-width:340px){
  .head .wrap{gap:7px;padding:0 12px}
  .wrap,.wrap-narrow{padding-inline:12px}
  .logo{font-size:0;gap:0}
  .logo .mk{width:24px;height:24px}
  .combo-pick select{max-width:88px;padding:6px 16px 6px 6px}
  .head .right .btn{padding:7px 10px;font-size:12.5px}
}

@media(prefers-reduced-motion:reduce){
  *,*::before,*::after{animation:none!important;transition:none!important}
}

/* ── live chat ──────────────────────── */
/* Icon only. A labelled pill took up a stripe of the screen on a phone and
   covered the content behind it; the icon is the convention anyway. */
.chat-btn{
  position:fixed;right:20px;bottom:20px;z-index:70;
  width:52px;height:52px;display:grid;place-items:center;
  border:0;border-radius:50%;cursor:pointer;
  background:var(--brand);color:var(--brand-ink);
  box-shadow:0 6px 20px rgba(var(--brand-rgb),.34);
  transition:transform .18s var(--ease),box-shadow .18s var(--ease)}
.chat-btn:hover{transform:translateY(-2px);box-shadow:0 10px 26px rgba(var(--brand-rgb),.44)}
.chat-btn:active{transform:translateY(0)}
.chat-btn svg{width:23px;height:23px}
/* presence badge, pinned to the rim rather than sitting inline */
.chat-btn .dot{position:absolute;top:3px;right:3px;width:11px;height:11px;
  border-radius:50%;background:#34C77B;border:2.5px solid var(--paper)}
.chat-btn[hidden]{display:none}

.chat-panel{
  position:fixed;right:20px;bottom:20px;z-index:71;width:344px;max-width:calc(100vw - 32px);
  background:var(--surface);border:1px solid var(--line);border-radius:var(--r);
  box-shadow:var(--shadow-lg);overflow:hidden;
  display:flex;flex-direction:column;
  animation:chatIn .2s var(--ease) both}
@keyframes chatIn{from{opacity:0;transform:translateY(12px) scale(.98)}to{opacity:1;transform:none}}
.chat-panel[hidden]{display:none}
.chat-head{display:flex;align-items:center;gap:10px;padding:15px 17px;
  background:var(--brand);color:var(--brand-ink)}
.chat-head .t{font-weight:650;font-size:15px;line-height:1.25}
.chat-head .s{font-size:12px;opacity:.88;display:flex;align-items:center;gap:6px}
.chat-head .s i{width:6px;height:6px;border-radius:50%;background:#7CE7B0;display:block}
.chat-head button{margin-left:auto;width:28px;height:28px;border:0;border-radius:8px;
  background:rgba(255,255,255,.18);color:var(--brand-ink);cursor:pointer;font-size:16px;
  line-height:1}
.chat-head button:hover{background:rgba(255,255,255,.3)}
.chat-body{padding:17px;display:flex;flex-direction:column;gap:12px;
  max-height:min(50vh,340px);overflow-y:auto}
.chat-msg{background:var(--surface-2);border-radius:14px 14px 14px 4px;
  padding:11px 14px;font-size:13.5px;line-height:1.6;color:var(--ink-2);max-width:92%}
.chat-msg.me{align-self:flex-end;background:var(--brand-wash);color:var(--brand-dark);
  border-radius:14px 14px 4px 14px}
.chat-quick{display:flex;flex-wrap:wrap;gap:7px}
.chat-quick a{padding:6px 12px;border-radius:var(--r-pill);border:1px solid var(--line-2);
  font-size:12.5px;color:var(--ink-2);background:var(--surface)}
.chat-quick a:hover{border-color:var(--brand);color:var(--brand)}
.chat-foot{display:flex;gap:8px;padding:12px 14px;border-top:1px solid var(--line)}
.chat-foot input{flex:1;min-width:0;padding:10px 14px;border-radius:var(--r-pill);
  border:1px solid var(--line-2);background:var(--surface);font-size:14px}
.chat-foot input:focus{outline:none;border-color:var(--brand);
  box-shadow:0 0 0 3px rgba(var(--brand-rgb),.12)}
.chat-foot button{flex:0 0 auto;width:40px;height:40px;border-radius:50%;border:0;
  background:var(--brand);color:var(--brand-ink);cursor:pointer;font-size:15px}
.chat-foot button:hover{background:var(--brand-dark)}
@media(max-width:480px){
  .chat-btn{right:14px;bottom:14px;width:48px;height:48px}
  .chat-panel{right:14px;left:14px;bottom:14px;width:auto}
}

/* ── generated cover, for events whose source publishes no artwork ───
   LCSD's open data carries none at all, so ~15% of the catalogue would
   otherwise be missing from the shop. Muted on purpose: this has to read as
   a designed card sitting behind the real posters, not as one that failed to
   load. --h is set inline from a hash of the event id. */
.gencover{position:relative;width:100%;height:100%;overflow:hidden;
  display:flex;align-items:center;justify-content:center;
  padding:20px;text-align:center;border-radius:inherit;
  background:
    radial-gradient(130% 80% at 50% -10%,
      hsl(var(--h) 34% 40%) 0%, hsl(var(--h) 30% 30%) 45%, transparent 100%),
    linear-gradient(158deg,
      hsl(var(--h) 28% 28%) 0%, hsl(calc(var(--h) + 34) 32% 18%) 100%)}
/* the site's ticket mark, watermarked -- structure, so the card does not
   look like an empty rectangle */
.gencover::after{content:'';position:absolute;right:-16%;bottom:-18%;
  width:74%;height:74%;background:#fff;opacity:.06;pointer-events:none;
  -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpath d='M7 6h11.2a3.2 3.2 0 0 0 6.4 0H25a4 4 0 0 1 4 4v12a4 4 0 0 1-4 4h-.4a3.2 3.2 0 0 0-6.4 0H7a4 4 0 0 1-4-4V10a4 4 0 0 1 4-4z' fill='%23fff'/%3E%3C/svg%3E") no-repeat center/contain;
          mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpath d='M7 6h11.2a3.2 3.2 0 0 0 6.4 0H25a4 4 0 0 1 4 4v12a4 4 0 0 1-4 4h-.4a3.2 3.2 0 0 0-6.4 0H7a4 4 0 0 1-4-4V10a4 4 0 0 1 4-4z' fill='%23fff'/%3E%3C/svg%3E") no-repeat center/contain}
.gencover span{position:relative;z-index:1;
  font-size:15px;font-weight:600;line-height:1.38;letter-spacing:-.005em;
  color:rgba(255,255,255,.94);text-shadow:0 1px 10px rgba(0,0,0,.3);
  display:-webkit-box;-webkit-line-clamp:5;-webkit-box-orient:vertical;
  overflow:hidden}
.gencover.sm{padding:7px}
.gencover.sm::after{right:-22%;bottom:-24%;width:82%;height:82%;opacity:.08}
.gencover.sm span{font-size:9.5px;line-height:1.24;-webkit-line-clamp:4;
  text-shadow:0 1px 4px rgba(0,0,0,.35)}
.poster .gencover{aspect-ratio:3/4}

/* ── live chat: unread count, pending / failed sends ── */
/* Red count on the launcher once support has replied and the panel is closed.
   The green dot stays as the presence mark; this sits on the opposite corner. */
.chat-btn .cnt{position:absolute;top:-4px;left:-4px;min-width:20px;height:20px;padding:0 6px;
  border-radius:999px;background:var(--err);color:#fff;font:700 11px/20px var(--mono);
  text-align:center;border:2px solid var(--paper)}
.chat-btn .cnt[hidden]{display:none}
.chat-msg{white-space:pre-wrap;word-break:break-word}
.chat-msg.pending{opacity:.55}
.chat-msg.err{align-self:center;background:var(--err-wash);color:var(--err);
  border-radius:10px;font-size:12.5px;padding:8px 12px}

/* ── checkout: sign-in gate ── */
/* Shown in place of the payment form when nobody is signed in. The selection
   is kept, so coming back from login lands straight on the form. */
.gate .ic{width:52px;height:52px;border-radius:50%;background:var(--brand-wash);color:var(--brand);
  display:grid;place-items:center;font-size:22px;margin-bottom:16px}
.gate h1{margin:0 0 8px}
.gate p{color:var(--ink-2);margin:0 0 20px;max-width:34em}
.gate .row{display:flex;gap:10px;flex-wrap:wrap}
.gate .fine{font-size:12.5px;color:var(--ink-3);margin:18px 0 0}

/* ── live chat: photos ── */
/* Padding drops to 4px around a photo; 210px tall at most, click to zoom. */
.chat-msg.img{padding:4px;max-width:78%}
.chat-msg.img img{display:block;max-height:210px;max-width:100%;width:auto;height:auto;
  border-radius:9px;cursor:zoom-in;background:var(--surface-2)}
.chat-msg.img .cap{padding:6px 10px 3px;font-size:13px}
.chat-foot .attach{flex:0 0 auto;width:40px;height:40px;border-radius:50%;
  border:1px solid var(--line-2);background:var(--surface);color:var(--ink-2);
  cursor:pointer;display:grid;place-items:center}
.chat-foot .attach svg{width:18px;height:18px}
.chat-foot .attach:hover{border-color:var(--brand);color:var(--brand)}
.chat-zoom{position:fixed;inset:0;z-index:99;background:rgba(0,0,0,.82);
  display:grid;place-items:center;padding:20px;cursor:zoom-out}
.chat-zoom img{max-width:100%;max-height:100%;border-radius:8px;
  box-shadow:0 20px 60px rgba(0,0,0,.5)}

/* "Agent is typing": three dots where the next bubble will land, the header
   line switched over, and — while the panel is closed — a ring on the
   launcher, so a reply being written is visible without opening anything. */
.chat-typing{align-self:flex-start;width:max-content;
  background:var(--surface-2);border-radius:14px 14px 14px 4px;
  padding:13px 16px;display:flex;align-items:center;gap:4px}
.chat-typing i{display:block;width:6px;height:6px;border-radius:50%;
  background:var(--ink-3);animation:chatDot 1.25s infinite ease-in-out}
.chat-typing i:nth-child(2){animation-delay:.16s}
.chat-typing i:nth-child(3){animation-delay:.32s}
@keyframes chatDot{0%,60%,100%{opacity:.3;transform:translateY(0)}
  30%{opacity:1;transform:translateY(-3px)}}
.chat-head .s.typing i{background:#FFD479;animation:chatPulse 1.1s infinite ease-in-out}
@keyframes chatPulse{0%,100%{opacity:1}50%{opacity:.3}}
.chat-btn.live::after{content:"";position:absolute;inset:-4px;border-radius:50%;
  border:2px solid rgba(var(--brand-rgb),.5);animation:chatRing 1.6s infinite;
  pointer-events:none}
@keyframes chatRing{from{transform:scale(.9);opacity:.9}to{transform:scale(1.2);opacity:0}}
@media (prefers-reduced-motion:reduce){
  .chat-typing i,.chat-head .s.typing i,.chat-btn.live::after{animation:none}
}

/* Promo badges. "Only N% left" sits top-left in red; "On sale soon" moves to
   the top-right so a card can carry both. "Sold out" keeps the default look. */
.ev .badge.left{background:var(--err);color:#fff}
.ev .badge.hot{left:auto;right:10px}

/* 首单折扣弹窗。只在首页、只弹一次，关掉之后写进 localStorage 不再出现 ——
   每次进站都糊一脸只会教会人闭着眼点叉，连带把以后真要紧的提示一起点掉。
   延迟 1.2 秒出现（见 app.js 的 promoPopup），让人先看清页面是什么。 */
.promo-pop{position:fixed;inset:0;z-index:60;display:flex;align-items:center;
  justify-content:center;padding:20px;background:rgba(12,10,18,.62);
  backdrop-filter:blur(3px);animation:promoIn .18s ease-out}
@keyframes promoIn{from{opacity:0}to{opacity:1}}
.promo-card{position:relative;width:100%;max-width:380px;padding:30px 26px 26px;
  text-align:center;background:var(--surface);border:1px solid var(--line);
  border-radius:var(--r-lg);box-shadow:0 22px 60px rgba(0,0,0,.28)}
.promo-card .promo-pct{font-family:var(--mono);font-size:52px;line-height:1;
  font-weight:800;color:var(--brand)}
.promo-card h3{margin:6px 0 10px;font-size:19px}
.promo-card p{margin:0 0 20px;font-size:13.5px;line-height:1.65;color:var(--ink-2)}
.promo-x{position:absolute;top:10px;right:12px;width:30px;height:30px;
  border:0;background:none;cursor:pointer;font-size:22px;line-height:1;
  color:var(--ink-3)}
.promo-x:hover{color:var(--ink)}
@media (max-width:480px){.promo-card{padding:26px 20px 22px}
  .promo-card .promo-pct{font-size:44px}}

/* 语言切换器。放在页眉右上、登录按钮左边 —— 看不懂页面的人第一件事就是
   找它，藏在页脚等于没有。做成原生 select：各平台自带的下拉在手机上比
   自己画的浮层好用，键盘和读屏也不用额外适配。 */
/* 语言和货币两个下拉。**必须是两个** —— 英语国家的货币各不相同
   （澳洲 AUD、加拿大 CAD、新加坡 SGD、新西兰 NZD、英国 GBP），
   跟着语言走一个都猜不对。长得一样，所以样式并到一起。 */
.lang-pick,.cur-pick{display:inline-flex;align-items:center;margin-right:8px;
  min-width:0;flex:0 1 auto}
.lang-pick select,.cur-pick select{appearance:none;-webkit-appearance:none;
  padding:7px 26px 7px 11px;border:1px solid var(--line);border-radius:var(--r);
  background:var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23888' stroke-width='1.5' fill='none'/%3E%3C/svg%3E") no-repeat right 9px center;
  color:var(--ink);font:inherit;font-size:13.5px;cursor:pointer;line-height:1.2}
.lang-pick select:hover,.cur-pick select:hover{border-color:var(--line-2)}
.lang-pick select:focus-visible,.cur-pick select:focus-visible{outline:2px solid var(--brand);outline-offset:1px}
/* 合起来的那个要写下「繁體中文 · HK$」，比单独的语言或货币都长。
   但它是**唯一**一个下拉（合并之前是两个并排），总宽反而比原来窄。 */
.combo-pick select{max-width:none}
@media(max-width:520px){
  /* 窄屏收窄，别把登录按钮挤下去。货币那个更窄 —— 它的内容本来就短，
     而且两个下拉并排比语言一个更占地方。 */
  .lang-pick select{padding:6px 22px 6px 8px;font-size:12.5px;max-width:104px}
  .cur-pick select{padding:6px 20px 6px 7px;font-size:12.5px;max-width:78px}
}
