/* 中票在线 · dark theme: near-black canvas, grey surfaces, bold white type.
   Four accent colours, one job each: blue = tappable / selected, teal = good news (on sale, paid, valid) and
   info icons, orange = needs attention (discount, unpaid, not refundable, few left), red = something went wrong.
   Greys come in fixed steps: bg → card → card-2 → line → faint → muted → text-2 → text. */
[hidden] { display: none !important; }
:root {
  color-scheme: dark;
  --bg: #121212; --card: #1e1e1e; --card-2: #2a2a2a; --line: #3a3a3a; --faint: #5c5c5c; --muted: #8e8e8e;
  --text-2: #c8c8c8; --text: #ffffff;
  --brand: #3d6bff; --brand-weak: rgba(61,107,255,.18);
  --teal: #5fe3d0; --teal-weak: rgba(95,227,208,.14); --teal-ink: #0b2b27;
  --orange: #ff8a3d; --orange-weak: rgba(255,138,61,.15); --orange-text: #ffc7a3; --orange-ink: #2e1405;
  --red: #ff5c5c; --red-weak: rgba(255,92,92,.15); --red-text: #ffb3b3;
  --radius: 2px; --safe-bottom: env(safe-area-inset-bottom, 0px);
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { background: #000; }
body { margin: 0; font: 15px/1.5 var(--sans); color: var(--text); background: #000; }
a { color: inherit; text-decoration: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 700; }
button, input, select, textarea { font: inherit; color: inherit; }
.icon { flex: none; vertical-align: -0.15em; }

.app { max-width: 480px; min-height: 100vh; margin: 0 auto; background: var(--bg); position: relative; }
.app.has-bar { padding-bottom: calc(76px + var(--safe-bottom)); }
main { padding: 14px 16px; display: flex; flex-direction: column; gap: 14px; }

/* top bar */
.navbar { position: sticky; top: 0; z-index: 5; height: 50px; display: flex; align-items: center; justify-content: center;
  background: var(--bg); }
.navbar h1 { font-size: 17px; max-width: calc(100% - 112px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-back { position: absolute; left: 4px; top: 0; width: 48px; height: 48px; display: grid; place-items: center; }

/* bottom tab bar and action bar */
.tabbar, .action-bar { position: fixed; bottom: 0; left: 0; right: 0; margin: 0 auto; max-width: 480px;
  z-index: 5; background: var(--card); padding-bottom: var(--safe-bottom); }
.tabbar { display: flex; }
.tabbar a { flex: 1; height: 62px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; font-size: 11px; color: var(--muted); }
.tabbar a[aria-current] { color: var(--text); font-weight: 600; }
.tabbar a[aria-current] .icon { color: var(--brand); stroke-width: 2.4; }
.action-bar { display: flex; align-items: center; gap: 10px; padding: 10px 16px calc(10px + var(--safe-bottom)); }
.action-bar form { display: contents; }
.action-bar .btn { flex: 1; }
.action-bar .btn.ghost { flex: 0 0 auto; padding: 0 16px; }
.bar-price { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.bar-price output { font-size: 22px; font-weight: 800; }
.bar-price small { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-price + .btn { flex: 0 0 150px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; height: 48px; padding: 0 22px; border: 0;
  border-radius: 24px; background: var(--brand); color: #fff; font-size: 16px; font-weight: 700; cursor: pointer; }
.btn:disabled { background: var(--line); color: var(--muted); cursor: not-allowed; }
.btn.busy, .btn.busy:disabled { background: var(--brand); color: #fff; opacity: .7; cursor: progress; }
.btn.ghost { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.btn.danger { background: transparent; color: var(--red); box-shadow: inset 0 0 0 1px var(--red); }
.btn.block { width: 100%; }
form .btn.block { margin-top: 8px; }
.btn .icon { margin-right: 4px; }
.btn.mini { height: 30px; padding: 0 14px; font-size: 13px; font-weight: 500; border-radius: 15px; }
.mini-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 10px; }
.mini-actions form { padding: 0; }
.btn.big { height: 54px; font-size: 18px; }
.btn.small-btn { height: 40px; padding: 0 16px; font-size: 15px; flex: none; }
.stack { display: flex; flex-direction: column; gap: 10px; }

/* toast */
.toast { margin: 14px 16px 0; padding: 10px 14px; border-radius: 8px; background: var(--red-weak); color: var(--red-text); font-size: 14px; }
.toast.ok { background: var(--teal-weak); color: var(--teal); }
/* A done notice (已保存 / 已开始售票 …) folds away after a few seconds (checkout.js); errors stay. */
.toast.ok.fading { overflow: hidden; opacity: 0; margin-top: 0; margin-bottom: 0; padding-top: 0; padding-bottom: 0;
  max-height: 0; transition: opacity .4s, max-height .4s .1s, margin .4s .1s, padding .4s .1s; }

/* text helpers */
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; }
.meta { color: var(--text-2); font-size: 13px; display: flex; gap: 4px; align-items: center; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.empty { padding: 56px 16px; text-align: center; color: var(--muted); display: flex; flex-direction: column; gap: 16px;
  align-items: center; }
.empty a:not(.btn) { color: var(--brand); }
.link { color: var(--brand); }

/* chips */
.chip { display: inline-block; padding: 0 8px; border-radius: 4px; font-size: 12px; line-height: 20px; font-weight: 600; }
.chip.selling { background: var(--teal-weak); color: var(--teal); }
.chip.upcoming { background: var(--orange-weak); color: var(--orange); }
.chip.soldout, .chip.closed { background: var(--card-2); color: var(--muted); }
.chip.danger, .chip.void { background: var(--red-weak); color: var(--red); }
.status { font-size: 13px; }
.status.selling { color: var(--teal); }
.status.upcoming { color: var(--orange); }
.status.closed { color: var(--muted); }
.status.void { color: var(--red-text); font-weight: 600; }

/* ---- home: location, search pill, featured strip, ranked list ---- */
.loc { display: flex; align-items: center; gap: 8px; padding: 10px 0 2px; font-size: 18px; }
.loc .icon:first-child { color: var(--teal); }
.loc .icon:last-child { color: var(--muted); }
.search-pill { display: flex; align-items: center; gap: 12px; height: 60px; padding: 6px 18px 6px 6px; border-radius: 30px;
  background: var(--card-2); margin-top: 8px; }
.search-pill:focus-within { box-shadow: inset 0 0 0 1px var(--line); }
.search-pill button { flex: none; width: 48px; height: 48px; border: 0; border-radius: 50%; background: var(--brand); color: #fff;
  display: grid; place-items: center; cursor: pointer; }
.search-pill input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; font-size: 18px; }
.search-pill input::placeholder { color: var(--muted); }
.search-pill input::-webkit-search-cancel-button { -webkit-appearance: none; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; margin-top: 12px; }
.section-head h2 { font-size: 21px; }
.section-head a { font-size: 14px; color: var(--text-2); }
.feature-strip { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
  margin: 0 -16px; padding: 0 16px; }
.feature-strip::-webkit-scrollbar { display: none; }
.feature { flex: 0 0 82%; scroll-snap-align: start; background: var(--card); border-radius: 2px; overflow: hidden;
  display: flex; flex-direction: column; }
/* Posters keep their own shape (square stays square, portrait stays portrait): fixed width, natural height,
   capped at 2:3 so an unusually tall image cannot stretch a list. Placeholders use 3:4. */
.feature-art { position: relative; height: 220px; overflow: hidden; display: grid; place-items: center; background: var(--card-2); }
.feature-art-bg { position: absolute; inset: -20px; background-size: cover; background-position: center;
  filter: blur(20px) brightness(.5); }
.feature-img { position: relative; display: block; max-width: 92%; max-height: 196px; width: auto; height: auto;
  border-radius: 4px; box-shadow: 0 6px 18px rgba(0,0,0,.45); }
.feature-img.poster-empty { height: 196px; aspect-ratio: 3 / 4; }
.feature h3 { font-size: 20px; line-height: 1.35; padding: 12px 14px 4px; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden; }
.feature-meta { display: flex; align-items: center; gap: 14px; padding: 4px 14px 14px; min-width: 0; }
.feature-meta > div:last-child { min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: 14px; color: var(--text-2); }
.feature-meta .place { display: flex; align-items: center; gap: 4px; color: var(--text); font-weight: 600; min-width: 0; }
.feature-meta .place .icon { color: var(--teal); }
.feature-meta .place { align-items: flex-start; }
.feature-meta .place .icon { margin-top: 2px; flex: none; }
.feature-meta .place span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.date-badge { flex: none; display: flex; flex-direction: column; align-items: center; line-height: 1.1; padding-bottom: 4px;
  border-bottom: 3px solid var(--brand); }
.date-badge small { font-size: 12px; font-weight: 600; }
.date-badge b { font-size: 28px; font-weight: 800; }
.rank-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.rank-row { display: flex; align-items: center; gap: 6px; }
.rank-card { flex: 1; min-width: 0; display: flex; align-items: center; background: var(--card); overflow: hidden; }
.rank-card > a:not(.heart) { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; }
.rank-img { flex: none; width: 76px; height: auto; max-height: 114px; object-fit: cover; object-position: center top;
  display: block; background: var(--card-2); }
.rank-img.poster-empty { aspect-ratio: 3 / 4; }
.rank-info { min-width: 0; display: flex; flex-direction: column; gap: 3px; padding: 8px 0; }
.rank-info h3 { font-size: 16px; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; }
.rank-cat { align-self: flex-start; font-size: 12px; line-height: 1.5; color: var(--text-2); background: var(--card-2); padding: 1px 7px; border-radius: 2px; margin: 1px 0 2px; }
.rank-info p { font-size: 13px; color: var(--text-2); display: flex; align-items: center; gap: 4px; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; }
.rank-price b { color: var(--text); font-size: 16px; }
.rank-price .chip { margin-left: 6px; }
.heart-form { display: contents; }
.heart { flex: none; width: 52px; height: 52px; display: grid; place-items: center; border: 0; background: transparent;
  color: var(--text); cursor: pointer; }
.heart.on { color: var(--brand); }
.heart.on .icon { fill: currentColor; }
.city-list { list-style: none; margin: 0; padding: 0; }
.city-list li + li { border-top: 2px solid var(--bg); }
.city-list a { display: flex; align-items: center; gap: 10px; padding: 14px; }
.city-list a .icon { color: var(--teal); }
.city-list b { flex: 1; }
.city-list a[aria-current] b { color: var(--brand); }

/* legacy home pieces still used elsewhere */
.hero { padding: 10px 0 12px; }
.hero h2 { font-size: 28px; }
.brand { color: var(--muted); font-size: 12px; letter-spacing: .2em; }
.section-title { font-size: 20px; }
.show-list, .order-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.show-card { display: flex; gap: 12px; padding: 12px; background: var(--card); border-radius: var(--radius); }
.show-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.show-info h3 { font-size: 16px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; }
.price { font-size: 12px; color: var(--text-2); }
.price b { font-size: 20px; color: var(--text); }
.poster, .poster-lg, .poster-sm { flex: none; align-self: flex-start; height: auto; object-fit: cover; object-position: center top;
  border-radius: 4px; background: var(--card-2); }
.poster { width: 96px; max-height: 144px; }
.poster-lg { width: 112px; max-height: 168px; }
.poster-sm { width: 60px; max-height: 90px; }
.poster-empty { aspect-ratio: 3 / 4; }
.poster-empty { display: grid; place-items: center; color: #fff; font-weight: 800; padding: 6px; text-align: center;
  background: var(--card-2); color: var(--text-2); font-size: 15px; }
.poster-sm.poster-empty { font-size: 12px; }

/* cards */
.card { background: var(--card); border-radius: var(--radius); padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.card h3 { font-size: 17px; }
.kv { display: flex; gap: 12px; font-size: 14px; line-height: 1.6; }
/* Labels sit on one line: at least 72px so values line up, wider only when a label is long. */
.kv > span { flex: none; min-width: 72px; max-width: 45%; color: var(--muted); }
.kv p { flex: 1; min-width: 0; overflow-wrap: anywhere; color: var(--text-2); }
/* Long values (the programme, a long cast list) take the full width under their label. */
.kv.stack { flex-direction: column; gap: 4px; }
.kv.stack > span { max-width: none; }
.kv .line { display: block; }
.kv .line + .line { margin-top: 4px; }
.lines { display: flex; flex-direction: column; gap: 6px; font-size: 14px; line-height: 1.6; color: var(--text-2);
  overflow-wrap: anywhere; }
/* Safari ignores flex gap on <details>, so collapsible cards space their rows with margins instead. */
details.card { display: block; }
details.card > * + * { margin-top: 10px; }
.intro-images img { display: block; width: 100%; height: auto; }
.intro-images + .intro-images { margin-top: 8px; }
.prose + .intro-images, .intro-images + .prose { margin-top: 12px; }
.intro-thumbs { display: flex; flex-wrap: wrap; gap: 8px; }
.intro-thumb { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 13px; color: var(--text-2); }
.intro-thumb img { width: 72px; height: 96px; object-fit: cover; object-position: top; border-radius: 4px;
  background: transparent; }
.prose { white-space: pre-line; font-size: 14px; line-height: 1.75; color: var(--text-2); }
details > summary { cursor: pointer; list-style: none; font-weight: 700; display: flex; justify-content: space-between;
  align-items: center; }
details > summary::-webkit-details-marker { display: none; }
details > summary::after { content: "展开"; font-weight: 400; color: var(--muted); font-size: 13px; }
details[open] > summary::after { content: "收起"; }
details.more > summary { font-weight: 400; font-size: 14px; color: var(--text-2); }
/* Inside forms, optional sections are big tappable rows (easy to hit with a thumb), not small grey text. */
form details.more > summary { min-height: 48px; padding: 0 14px; border-radius: 8px; background: var(--card-2);
  box-shadow: inset 0 0 0 1px var(--line); color: var(--text); font-size: 15px; font-weight: 600; }
form details.more > summary::after { content: "展开 ▾"; color: var(--brand); font-size: 14px; font-weight: 600; }
form details.more[open] > summary::after { content: "收起 ▴"; }
form details.more[open] > summary { margin-bottom: 8px; }
details.card[open] { gap: 10px; }
.rules p { font-size: 13px; color: var(--text-2); }

/* detail header (admin review) */
.detail-head { display: flex; gap: 14px; padding: 4px 0 6px; }
.detail-head > div { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.detail-head h2 { font-size: 21px; }
.detail-head .chip { align-self: flex-start; }

/* option chips */
.options { display: flex; flex-wrap: wrap; gap: 8px; }
.option { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: calc(50% - 4px); flex: 1 1 calc(50% - 4px); padding: 9px 8px; border-radius: 8px; background: var(--card-2);
  font-size: 14px; text-align: center; cursor: pointer; }
.option small { font-size: 11px; color: var(--muted); }
.option[aria-current], .option:has(input:checked) { box-shadow: inset 0 0 0 2px var(--brand); }
.option.disabled { color: var(--faint); cursor: not-allowed; }
.option input { position: absolute; opacity: 0; pointer-events: none; }

/* forms */
.field { display: flex; flex-direction: column; gap: 6px; padding: 6px 0; }
.field span { font-size: 13px; color: var(--muted); }
.field input, .field select, .field textarea { border: 0; outline: 0; padding: 12px; font-size: 16px; background: var(--card-2);
  border-radius: 4px; width: 100%; font-family: inherit; color: inherit; min-height: 46px; }
.field input[type=file] { background: transparent; padding: 4px 0; min-height: 0; }
.field input:focus, .field select:focus, .field textarea:focus { box-shadow: inset 0 0 0 1px var(--brand); }
.field select option { background: var(--card); }
.field textarea { resize: vertical; line-height: 1.6; }
.field input[type=file] { font-size: 14px; }
.field small { font-size: 12px; color: var(--muted); }
.field:focus-within span { color: var(--brand); }
.field.grow { flex: 1; }
.check { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--text-2); }
.check.switch { justify-content: space-between; padding: 6px 0; font-size: 15px; color: var(--text); }
.check.switch input { appearance: none; -webkit-appearance: none; flex: none; width: 46px; height: 28px; margin: 0;
  border-radius: 14px; background: var(--line); position: relative; cursor: pointer; transition: background .2s; }
.check.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px;
  border-radius: 50%; background: #fff; transition: transform .2s; }
.check.switch input:checked { background: var(--brand); }
.check.switch input:checked::after { transform: translateX(18px); }
.check input { width: 18px; height: 18px; accent-color: var(--brand); }
.attendee { border: 0; margin: 0; padding: 0 0 6px; min-width: 0; }
.attendee + .attendee { margin: 10px 0 0; padding: 6px 0; }
.attendee legend { font-size: 15px; font-weight: 700; padding: 0 0 4px; }
.summary { flex-direction: row; gap: 12px; }
.summary > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.stepper { display: flex; align-items: center; border-radius: 18px; overflow: hidden; background: var(--card-2); }
.stepper button { width: 38px; height: 36px; border: 0; background: transparent; font-size: 18px; cursor: pointer; }
.stepper input { width: 44px; height: 36px; border: 0; background: transparent; text-align: center; font-size: 17px;
  font-weight: 700; -moz-appearance: textfield; }
.stepper input::-webkit-inner-spin-button, .stepper input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.two { display: flex; gap: 12px; }
.two > * { flex: 1; min-width: 0; }
.two form { display: flex; }
.two form .btn { flex: 1; }
form details.more { padding: 8px 0; }
form > details.more:first-child { border-top: 0; padding-top: 0; }
details.card > form, details.more > form { margin-top: 4px; }

/* segmented tabs */
.segmented { display: flex; gap: 4px; background: var(--card); border-radius: 22px; padding: 4px; }
.segmented a { flex: 1; text-align: center; padding: 7px 0; border-radius: 18px; font-size: 14px; color: var(--muted); }
.segmented a[aria-current] { background: var(--brand); color: #fff; font-weight: 700; }
.order-card { display: flex; flex-direction: column; gap: 10px; padding: 14px; background: var(--card); border-radius: var(--radius); }
.order-main { display: flex; flex-direction: row; gap: 12px; }
.order-main > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.order-main h3 { font-size: 16px; }
.order-main .chip { align-self: flex-start; }
li.card .order-main h3 { font-size: 16px; }

/* order detail */
.banner { padding: 18px 16px; border-radius: var(--radius); background: var(--card); display: flex; flex-direction: column; gap: 4px; }
.banner h2 { font-size: 22px; }
.banner p { font-size: 14px; }
.banner.selling { background: var(--teal); color: var(--teal-ink); }
.banner.upcoming { background: var(--orange); color: var(--orange-ink); }
.banner.closed { color: var(--muted); }
.banner.void { background: var(--red); color: #fff; }
p.banner { font-size: 14px; padding: 12px 14px; }
.tickets { display: flex; flex-direction: column; gap: 12px; }
.ticket { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 14px 14px 16px;
  border-radius: 8px; background: var(--card-2); }
.ticket-head { align-self: stretch; display: flex; justify-content: space-between; font-size: 14px; color: var(--text-2); }
.ticket .status { color: var(--teal); font-weight: 700; }
.qr-box { width: 200px; max-width: 70%; background: #fff; border-radius: 8px; padding: 4px; }
.qr-box:empty { display: none; }
.qr { display: block; width: 100%; height: auto; }
.ticket code { font: 700 18px/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; }
.ticket.used .qr-box { opacity: .25; }
.ticket.used code, .ticket.void code, .ticket.used .status { color: var(--muted); }
.ticket.void .status { color: var(--red-text); }

/* ticket wallet */
.pass-left { align-self: flex-start; margin-top: 4px; font-size: 12px; font-weight: 700; color: var(--teal-ink);
  background: var(--teal); padding: 2px 8px; border-radius: 2px; }
.past-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px;
  background: var(--card); border-radius: 2px; color: var(--muted); }
.past-row > div { min-width: 0; }
.past-row h3 { font-size: 15px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.past-row > span { flex: none; font-size: 13px; }
.order-list:has(.past-row) { gap: 2px; }

/* door check: a scanned ticket */
.card.scanned { box-shadow: inset 0 0 0 2px var(--teal); }
.card.scanned h3 { font-size: 20px; }

/* me */
.profile { display: flex; gap: 14px; align-items: center; padding: 12px 0 6px; }
.profile h2 { font-size: 20px; }
.avatar { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; font-size: 24px; font-weight: 800;
  color: #fff; background: var(--brand); }
.stats { display: flex; flex-direction: row; }
.stats a, .stats > div { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 0; }
.stats b { font-size: 22px; font-weight: 800; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.stats span { font-size: 12px; color: var(--muted); white-space: nowrap; }
.card .stats { padding: 6px 0; }
.cell { display: flex; justify-content: space-between; align-items: center; font-size: 15px; padding: 6px 0; }
.cell + .cell { padding-top: 10px; }
.cell span { display: flex; align-items: center; gap: 6px; }

/* auth */
.auth { display: flex; flex-direction: column; gap: 14px; padding: 20px 0; }
.auth h2 { font-size: 28px; margin-bottom: 4px; }
.auth form { padding: 0; }
.auth a { color: var(--brand); }

/* ---- partner / admin ---- */
.notice-box { display: flex; gap: 8px; padding: 10px 12px; border-radius: 8px; background: var(--orange-weak); color: var(--orange-text);
  font-size: 14px; }
a.notice-box { align-items: center; }
.notice-box.column { flex-direction: column; gap: 4px; }
/* Adding a show: "1/2 填写演出资料 · 下一步：添加场次" with one bar per step. */
.flow-steps { display: flex; flex-direction: column; gap: 8px; padding: 2px 2px 0; }
.flow-head { display: flex; align-items: baseline; gap: 8px; }
.flow-head b { color: var(--teal); font-size: 15px; font-variant-numeric: tabular-nums; }
.flow-head span { font-size: 16px; font-weight: 700; }
.flow-head em { margin-left: auto; font-style: normal; font-size: 13px; color: var(--muted); }
.flow-bar { display: flex; gap: 6px; }
.flow-bar i { flex: 1; height: 4px; border-radius: 2px; background: var(--line); }
.flow-bar i.on { background: var(--teal); }
.flow-done { display: flex; flex-direction: column; gap: 12px; }
.flow-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.flow-actions .btn { text-align: center; }
.rules-list { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 2px; }
.progress { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--brand); border-radius: 3px; }
.grid-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding-top: 4px; }
.grid-actions.three { grid-template-columns: repeat(3, 1fr); }
.grid-actions a { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px 0; font-size: 12px;
  color: var(--text-2); border-radius: 8px; }
.grid-actions a:active { background: var(--card-2); }
.grid-actions .icon { color: var(--teal); }
.grid-actions a[aria-current] { background: var(--teal-weak); color: var(--teal); font-weight: 700; }
.ops-nav { padding: 8px; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px; }
.chips::-webkit-scrollbar { display: none; }
.chips a { flex: none; padding: 5px 14px; border-radius: 16px; background: var(--card); font-size: 14px; color: var(--text-2); }
.chips a[aria-current] { background: var(--brand); color: #fff; }
.search { display: flex; gap: 8px; align-items: center; }
.search input { flex: 1; min-width: 0; height: 42px; border: 0; border-radius: 21px; background: var(--card-2); padding: 0 16px;
  font-size: 15px; outline: 0; }
.result { padding: 18px 16px; border-radius: var(--radius); color: #fff; display: flex; flex-direction: column; gap: 4px; }
.result b { font-size: 22px; }
.result.ok { background: var(--teal); color: var(--teal-ink); }
.result.bad { background: var(--red); color: #fff; }
.result.warn { background: var(--orange); color: var(--orange-ink); }
.card.scanned .result { margin: 4px 0 8px; }
.result code { font: 600 20px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; background: rgba(0,0,0,.14);
  padding: 2px 8px; border-radius: 6px; user-select: all; }
.tier-box { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 8px; background: var(--card-2); }
.tier-box details.more { padding-top: 4px; }
.tier-box details.more[open] { display: flex; flex-direction: column; gap: 6px; }
s.muted { font-size: 12px; }
.log { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.log p { font-size: 14px; }
.big-number { font-size: 40px; font-weight: 800; line-height: 1.1; }
.order-detail > summary { display: flex; flex-direction: column; align-items: stretch; gap: 4px; font-weight: 400; }
.order-detail > summary::after { display: none; }
.order-detail > summary .chip { align-self: flex-start; }
.order-detail[open] > summary { padding-bottom: 8px; }

/* ---- show page ---- */
.show-hero { position: relative; overflow: hidden; margin: -14px -16px 0; padding: 20px 16px 18px; display: flex; gap: 14px; }
.show-hero-bg { position: absolute; inset: -30px; background-size: cover; background-position: center;
  filter: blur(28px) brightness(.45) saturate(1.2); transform: scale(1.1); }
.show-hero > * { position: relative; }
.show-hero .poster-lg { box-shadow: 0 8px 24px rgba(0,0,0,.5); }
.show-hero-info { flex: 1; display: flex; flex-direction: column; gap: 6px; min-width: 0; padding-right: 30px; }
.show-hero-info h2 { font-size: 20px; line-height: 1.3; }
.show-hero-info .meta { color: rgba(255,255,255,.85); }
.show-hero-info .chip { align-self: flex-start; margin-top: auto; }
.show-hero .heart { position: absolute; top: 10px; right: 0; }
.show-hero .heart-form { display: block; }
.hero-price { font-size: 13px; color: var(--text-2); }
.hero-price b { font-size: 24px; color: #fff; font-weight: 800; }
.card-title { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.card-title .muted { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.date-strip { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
  margin: 0 -14px; padding: 2px 14px 4px; }
.date-strip::-webkit-scrollbar { display: none; }
.date-card { flex: 0 0 78px; scroll-snap-align: start; display: flex; flex-direction: column; align-items: center; gap: 1px;
  padding: 8px 4px; border-radius: 8px; background: var(--card-2); line-height: 1.3; }
.date-card b { font-size: 19px; font-weight: 800; }
.date-card span { font-size: 12px; color: var(--text-2); }
.date-card small { font-size: 11px; color: var(--teal); }
.date-card.off small { color: var(--muted); }
.date-card.off b, .date-card.off span { color: var(--faint); }
.date-card[aria-current] { background: var(--brand); }
.date-card[aria-current] b, .date-card[aria-current] span, .date-card[aria-current] small { color: #fff; }
.tier-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tier-card { position: relative; display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; min-width: 0;
  border-radius: 8px; background: var(--card-2); cursor: pointer; }
.tier-card input { position: absolute; opacity: 0; pointer-events: none; }
.tier-card .name { font-size: 13px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 34px; }
.tier-card .price b { font-size: 19px; font-weight: 800; }
.tier-card .price s { font-size: 12px; color: var(--muted); margin-left: 6px; }
.tier-card .tag { position: absolute; top: 0; right: 0; padding: 0 6px; border-radius: 0 8px 0 8px; font-size: 11px;
  line-height: 18px; font-weight: 700; background: var(--orange); color: var(--bg); }
.tier-card .tag.gray { background: var(--line); color: var(--muted); }
.tier-card .left { font-size: 11px; color: var(--orange); }
.tier-card:has(input:checked) { box-shadow: inset 0 0 0 2px var(--brand); background: var(--brand-weak); }
.tier-card:has(input:focus-visible) { outline: 2px solid var(--brand); outline-offset: 2px; }
.tier-card.disabled { cursor: not-allowed; }
.tier-card.disabled .name, .tier-card.disabled .price b { color: var(--faint); }

/* ---- compact lists for many sessions / tiers ---- */
.card.flush { padding: 0; gap: 0; overflow: hidden; }
.card.flush > .pad, .card .pad { padding: 14px 14px 8px; }
.session-list, .tier-list { list-style: none; margin: 0; padding: 0; }
.session-list li + li, .tier-list li + li { border-top: 2px solid var(--bg); }
.session-row { display: flex; align-items: center; gap: 12px; padding: 12px 10px 12px 14px; }
.session-row:active { background: var(--card-2); }
.session-row > .icon { color: var(--muted); }
.date-block { flex: 0 0 62px; display: flex; flex-direction: column; align-items: center; padding: 6px 0; border-radius: 8px;
  background: var(--card-2); line-height: 1.3; }
.date-block b { font-size: 17px; font-weight: 800; }
.date-block span { font-size: 11px; color: var(--muted); white-space: nowrap; }
.session-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.tier-row > summary { display: flex; flex-direction: column; align-items: stretch; gap: 5px; padding: 12px 14px; font-weight: 400; }
.tier-row > summary::after { display: none; }
.tier-row[open] > summary { background: var(--card-2); }
.tier-row .tier-name { font-weight: 700; display: flex; align-items: center; gap: 6px; min-width: 0; }
.tier-row .tier-price { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.tier-row .price-now { font-size: 17px; font-weight: 800; }
.tier-row .edit-hint { color: var(--brand); white-space: nowrap; }
.tier-row[open] .edit-hint { color: var(--muted); }
.tier-row > .notice-box, .tier-row > p { margin: 0 14px 8px; }
.tier-row .tool { margin: 0 14px 12px; padding: 10px 12px; border-radius: 8px; background: var(--card-2);
  display: flex; flex-direction: column; gap: 4px; }
.tier-row .tool .field { border-bottom: 0; }

/* ---- flat pieces: welcome, sign-in empty states, settings-style menus ---- */
.welcome { text-align: center; padding: 36px 0 6px; }
.welcome p { font-size: 17px; color: var(--text-2); }
.welcome h1 { font-size: 34px; font-weight: 800; font-style: italic; letter-spacing: -.01em; }
.btn.wide { width: 100%; gap: 8px; height: 52px; font-size: 18px; }
.btn.wide .icon { margin: 0; }
.group { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.group h2 { font-size: 14px; font-weight: 600; color: var(--text-2); padding: 0 4px; }
.menu { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 1px;
  border-radius: var(--radius); overflow: hidden; }
.menu a { display: flex; align-items: center; gap: 14px; padding: 0 16px; height: 52px; background: var(--card); font-size: 15px; }
.menu a span { flex: 1; }
.menu a .icon:last-child { color: var(--text-2); }
.menu a:active { background: var(--card-2); }
.intro { text-align: center; padding: 18px 0 0; }
.intro h1 { font-size: 24px; font-weight: 800; letter-spacing: .04em; }
.intro p { color: var(--text-2); margin-top: 4px; }
.intro-mark { display: flex; flex-direction: column; align-items: center; gap: 18px; padding: 30px 0 10px; color: var(--brand); }
.intro-mark::after { content: ""; width: 72px; height: 3px; background: var(--brand); }
.points { list-style: none; margin: 0; padding: 10px 20px 20px; display: flex; flex-direction: column; gap: 24px; }
.points li { display: flex; gap: 18px; align-items: flex-start; }
.points .icon { color: var(--brand); margin-top: 2px; }
.points b { font-size: 17px; }
.points p { color: var(--text-2); font-size: 15px; margin-top: 2px; }
.profile { padding-top: 18px; }
.tier-row .tool { background: var(--bg); }
.order-card, .card { box-shadow: none; }

/* ---- no page names in the top bar: back arrow only, big title in the content ---- */
.page-title { font-size: 28px; font-weight: 800; line-height: 1.2; padding: 2px 0 4px; }
.navbar:not(:has(h1)) { justify-content: flex-start; }
.navbar.float { margin-bottom: -50px; background: transparent; pointer-events: none;
  transition: background-color .2s; }
.navbar.float .nav-title { opacity: 0; transform: translateY(6px); transition: opacity .2s, transform .2s; }
.navbar.float.solid { background: var(--bg); pointer-events: auto; }
.navbar.float.solid .nav-title { opacity: 1; transform: none; }
.navbar.float .nav-back { pointer-events: auto; color: #fff; }
.navbar.float + main .show-hero, .navbar.float ~ main .show-hero { padding-top: 56px; }
.show-hero .heart { top: 1px; right: 0; width: 48px; height: 48px; }

/* show page: share + save in the hero, notice tags */
.hero-tools { position: absolute; top: 1px; right: 0; display: flex; }
.hero-tools .heart, .show-hero .hero-tools .heart { position: static; width: 44px; height: 48px; }
.hero-tools .heart-form { display: block; }
.share { width: 44px; height: 48px; display: grid; place-items: center; border: 0; background: transparent; color: #fff;
  cursor: pointer; }
.show-hero-info { padding-right: 0; }
.show-hero-info h2 { padding-right: 70px; }
.toast.float { position: fixed; left: 50%; bottom: calc(96px + var(--safe-bottom)); transform: translateX(-50%); z-index: 20;
  width: auto; white-space: nowrap; }

/* home with only a few shows: one list of large cards */
.feature-list { display: flex; flex-direction: column; gap: 14px; }
.feature-list .feature { flex: none; }

/* saved attendees on checkout */
.saved-people { display: flex; flex-wrap: wrap; gap: 8px; }
.saved-people:empty { display: none; }
.person { display: inline-flex; align-items: center; background: var(--card-2); border-radius: 2px; font-size: 14px; }
.person button { border: 0; background: transparent; color: inherit; font: inherit; cursor: pointer; }
.person .pick { padding: 7px 4px 7px 12px; }
.person .pick small { color: var(--muted); margin-left: 4px; }
.person .drop { padding: 7px 10px 7px 6px; color: var(--muted); display: grid; place-items: center; }
.person.used { box-shadow: inset 0 0 0 1px var(--brand); }
.feature-item { position: relative; }
.feature-item .heart { position: absolute; top: 8px; right: 8px; width: 40px; height: 40px; border-radius: 50%;
  background: rgba(0,0,0,.55); color: #fff; }
.feature-item .heart.on { color: var(--brand); }

/* checkout: refund rules always visible */
.refund-rules ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 14px;
  color: var(--text-2); }
.refund-rules.none { background: var(--orange-weak); }
.refund-rules.none li { color: var(--orange); font-weight: 600; list-style: none; margin-left: -18px; }

/* WeChat scan-to-pay (computers) and the "open in browser" hint inside WeChat */
.wxpay { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.wxpay .price { font-size: 28px; font-weight: 700; }
.wxpay .qr-box { width: 220px; }
.open-browser { display: flex; gap: 12px; align-items: flex-start; border: 1px solid var(--orange); }
.open-browser > svg { color: var(--orange); flex: none; margin-top: 2px; }
.open-browser h3 { color: var(--orange-text); margin-bottom: 4px; }

/* door check: real-name ticket, compare the ID card */
.id-check { margin: 12px 0; padding: 12px; border-radius: 8px; border: 1px solid var(--orange); background: var(--orange-weak);
  display: flex; flex-direction: column; gap: 6px; }
.id-check > b { color: var(--orange-text); }
.id-check .id-name { font-size: 20px; color: var(--text); }
.id-ok { color: var(--teal); font-weight: 600; }
.id-bad { color: var(--red-text); font-weight: 600; }

/* Date-time boxes (calendar): iPhone gives them a fixed inner width, so let them fill their row and align left. */
.field input[type=datetime-local], .field input[type=date] { -webkit-appearance: none; appearance: none; display: block;
  width: 100%; min-width: 0; min-height: 46px; text-align: left; }
.field input::-webkit-date-and-time-value { text-align: left; }
/* File fields: one labelled button instead of the browser's own "choose file" control, which looks different on
   every phone and reads like a second button. Tapping anywhere on the field opens the picker. */
.file-pick { position: relative; cursor: pointer; }
.file-pick input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.file-pick .btn { align-self: flex-start; }
.file-pick input:focus-visible ~ .btn { box-shadow: inset 0 0 0 2px var(--brand); }
.file-pick [data-file-names] { color: var(--text-2); }

/* Session page: a clear button to open a tier's quota and discount tools. */
.tier-row .edit-btn { flex: none; display: inline-flex; align-items: center; min-height: 32px; padding: 0 12px;
  border-radius: 999px; box-shadow: inset 0 0 0 1px var(--brand); color: var(--brand); font-size: 14px; font-weight: 600;
  white-space: nowrap; }
.tier-row .edit-btn::before { content: attr(data-closed) " ▾"; }
.tier-row[open] .edit-btn::before { content: attr(data-open) " ▴"; }
.tier-row[open] .edit-btn { box-shadow: inset 0 0 0 1px var(--line); color: var(--text-2); }

/* Add-session form: tiers are filled in one box at a time; "再添加一个票档" opens the next box. */
.new-tier { margin: 0 0 10px; padding: 12px; min-width: 0; border-radius: 8px; background: var(--card-2); }
.new-tier > .row-between { min-height: 32px; font-size: 15px; }
.new-tier .field input, .new-tier .field select { background: var(--card); }
.new-tier .link-btn { min-height: 32px; padding: 0 4px 0 12px; border: 0;
  background: transparent; color: var(--red-text); font-size: 14px; cursor: pointer; }

/* Show page with a wide banner: the image fills the top, the name sits over its lower edge. */
.show-hero.has-banner { display: block; padding: 0; }
.show-hero.has-banner .banner { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.show-hero.has-banner::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,.45) 0, transparent 22%, transparent 40%, rgba(18,18,18,.92) 82%, var(--bg) 100%); }
.show-hero.has-banner .show-hero-info { position: relative; z-index: 1; margin-top: -88px; padding: 0 16px 14px; }
.show-hero.has-banner .hero-tools { z-index: 2; top: 1px; }
.navbar.float ~ main .show-hero.has-banner { padding-top: 0; }
.show-hero.has-banner .show-hero-info h2 { font-size: 22px; text-shadow: 0 1px 8px rgba(0,0,0,.6); padding-right: 0; }

/* Section tabs on the show page (jump links; they stay under the top bar while scrolling). */
.show-tabs { position: sticky; top: 50px; z-index: 4; display: flex; margin: 0 -16px; padding: 0 8px;
  background: var(--bg); border-bottom: 1px solid var(--line); }
.show-tabs a { flex: 1; text-align: center; padding: 12px 0 10px; font-size: 15px; color: var(--text-2);
  border-bottom: 2px solid transparent; }
.show-tabs a:active, .show-tabs a:focus-visible { color: #fff; border-bottom-color: var(--brand); }
main [id] { scroll-margin-top: 104px; }

/* Buyer session rows and ticket listings. */
.session-row.buyer .session-main b { font-size: 17px; }
.session-row.off .session-main b, .session-row.off .date-block b { color: var(--faint); }
.session-price { text-align: right; white-space: nowrap; }
.session-price b { font-size: 18px; font-weight: 800; }
.session-price small { font-size: 12px; color: var(--muted); margin-left: 2px; }
.chips.qty-chips { flex-wrap: wrap; margin: 0; padding: 0; overflow: visible; }
.qty-chips a { min-width: 60px; text-align: center; padding: 9px 12px; background: var(--card-2); font-size: 15px; }
.qty-chips a[aria-current] { background: var(--brand); color: #fff; font-weight: 700; }
.qty-more { display: flex; gap: 8px; align-items: center; }
.qty-more select, .qty-select { appearance: none; -webkit-appearance: none; border: 0; outline: 0; padding: 10px 34px 10px 12px;
  border-radius: 8px; background: var(--card-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238e8e8e' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat right 12px center; color: var(--text); font-size: 16px; }
.qty-more select { flex: 1; }
.listing-list { list-style: none; margin: 0; padding: 0; }
.listing-list li + li { border-top: 2px solid var(--bg); }
.listing { display: flex; align-items: center; gap: 10px; padding: 14px 10px 14px 14px; }
.listing:active { background: var(--card-2); }
.listing > div:first-child { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.listing > div:first-child b { font-size: 16px; }
.listing .left { font-size: 12px; color: var(--orange); }
.listing-price { display: flex; flex-direction: column; align-items: flex-end; white-space: nowrap; }
.listing-price b { font-size: 20px; font-weight: 800; }
.listing-price b + small { font-size: 12px; color: var(--muted); }
.listing-price > small { font-size: 12px; }
.listing > .icon { color: var(--muted); }
.qty-select { min-width: 110px; font-size: 17px; font-weight: 700; }
#details .show-intro { margin-top: 6px; }

/* Comments. */
.comment { padding: 12px 0; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; }
.comment p { margin: 0; line-height: 1.7; white-space: pre-line; color: var(--text-2); }
.comment.hidden-comment p { color: var(--faint); }
.comment form { align-self: flex-start; }

/* Selling rule choices (big tappable rows) and the banner preview in the admin form. */
fieldset.choices { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
fieldset.choices legend { font-size: 14px; color: var(--text-2); margin-bottom: 8px; padding: 0; }
.choice { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 8px; background: var(--card-2); }
/* Our own radio: a thin grey ring when not chosen (the phone's default is a solid black dot), blue dot when chosen. */
.choice input { appearance: none; -webkit-appearance: none; width: 20px; height: 20px; flex: none; margin: 0;
  border-radius: 50%; border: 1.5px solid var(--text-2); background: transparent; opacity: .55; }
.choice input:checked { opacity: 1; border: 6px solid var(--brand); background: #fff; }
.choice input:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.choice span { display: flex; flex-direction: column; gap: 2px; }
.choice:has(input:checked) { box-shadow: inset 0 0 0 2px var(--brand); background: var(--brand-weak); }
.banner-thumb { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; }

/* ======================================================================================================
   Show page and ticket page: light layout (white panels on light grey, big picture on top, underlined tabs,
   date boxes, round blue arrows). The rest of the site stays dark; these two pages set `.app.tm`.
   ====================================================================================================== */
html:has(.app.tm), html:has(.app.tm) body { background: #e9e9e9; }
.app.tm { --bg: #f2f2f2; --card: #ffffff; --card-2: #f1f1f1; --line: #e2e2e2; --faint: #b5b5b5; --muted: #6f6f6f;
  --text-2: #3b3b3b; --text: #1f1f1f; --teal: #0b8a78; --teal-weak: rgba(11,138,120,.1); --orange: #c25a12;
  --orange-weak: rgba(194,90,18,.1); --orange-text: #9a4510; --red: #d23a3a; --red-text: #b02a2a;
  --teal-ink: #fff; --orange-ink: #fff; --tm-blue: #1f4fe0; color: var(--text); }
.app.tm main { padding: 0 0 24px; gap: 0; }
.app.tm .tabbar { background: #fff; box-shadow: 0 -1px 0 var(--line); }
.app.tm .tabbar a[aria-current] .icon { color: var(--tm-blue); }

/* top: picture with the name over its lower edge */
.tm-hero { position: relative; overflow: hidden; aspect-ratio: 3 / 2; background: #111; }
.tm-hero .hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tm-hero .hero-blur { position: absolute; inset: -30px; background: #222 center / cover; filter: blur(22px) brightness(.55); }
.tm-hero .hero-poster { position: absolute; top: 14px; bottom: 14px; left: 50%; transform: translateX(-50%); height: calc(100% - 28px);
  width: auto; max-width: 70%; object-fit: contain; box-shadow: 0 10px 30px rgba(0,0,0,.5); }
.tm-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,.35) 0, transparent 26%, transparent 55%, rgba(0,0,0,.72) 100%); }
.tm-name { position: absolute; z-index: 1; left: 16px; right: 16px; bottom: 18px; margin: 0; color: #fff;
  font-size: 30px; line-height: 1.2; font-weight: 800; letter-spacing: .01em; }
.tm-name span { background: linear-gradient(transparent 62%, var(--tm-blue) 62%, var(--tm-blue) 92%, transparent 92%);
  -webkit-box-decoration-break: clone; box-decoration-break: clone; padding: 0 4px; margin-left: -4px; }
.app.tm .hero-tools { position: absolute; z-index: 2; top: 3px; right: 10px; display: flex; gap: 10px; }
.app.tm .hero-tools .heart, .app.tm .share { width: 40px; height: 40px; border-radius: 50%; background: rgba(0,0,0,.55);
  color: #fff; display: grid; place-items: center; }
.app.tm .hero-tools .heart.on { color: #fff; }
.app.tm .navbar.float .nav-back { left: 10px; top: 3px; width: 40px; height: 40px; border-radius: 50%;
  background: rgba(0,0,0,.55); color: #fff; }
.app.tm .navbar.float.solid { background: #1a1a1a; }
.app.tm .navbar.float.solid .nav-title { color: #fff; }
.app.tm .navbar.float.solid .nav-back { background: transparent; }
.app.tm .navbar.float ~ main .tm-hero { margin-top: 0; }

/* tabs: dark text, the current one underlined */
.tm-tabs { position: sticky; top: 50px; z-index: 4; display: flex; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.08); }
.tm-tabs a { flex: 1; text-align: center; padding: 15px 0 13px; font-size: 16px; letter-spacing: .2em; color: #6f6f6f;
  border-bottom: 3px solid transparent; }
.tm-tabs a[aria-current] { color: #111; font-weight: 700; border-bottom-color: #111; }
.app.tm main [id] { scroll-margin-top: 104px; }

/* section heading: short bar over a big title, then a white panel */
.tm-head { padding: 26px 16px 14px; }
.tm-head h3 { position: relative; font-size: 22px; font-weight: 800; letter-spacing: .04em; padding-top: 10px; }
.tm-head h3::before { content: ""; position: absolute; top: 0; left: 0; width: 26px; height: 4px; background: #111; }
.tm-dot { margin: 0 10px; font-weight: 400; }
.tm-count { font-weight: 500; }
.tm-panel { background: #fff; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.tm-panel.flush { padding: 0; }
.tm-empty { padding: 28px 16px; text-align: center; color: var(--muted); }
.tm-sub { color: var(--muted); font-size: 14px; }
.app.tm .kv > span { color: var(--muted); }
.app.tm .kv p { color: var(--text); }
.app.tm .prose { color: var(--text-2); }
.app.tm .comment { border-top-color: var(--line); }
.app.tm .comment p { color: var(--text); }

/* rows: date box · lines of text · round blue arrow */
.tm-list { list-style: none; margin: 0; padding: 0; }
.tm-list li + li .tm-row { border-top: 1px solid var(--line); }
.tm-list li { padding: 0 16px; }
.tm-row { display: flex; align-items: center; gap: 14px; padding: 16px 0; }
.tm-date { flex: 0 0 60px; min-height: 60px; padding: 6px 0; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: #f1f1f1; border-radius: 4px; line-height: 1.1; }
.tm-date small { font-size: 13px; color: #333; }
.tm-date b { font-size: 24px; font-weight: 500; }
.tm-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tm-main b { font-size: 16px; font-weight: 700; color: #1f1f1f; }
.tm-main .tm-price { color: #1f1f1f; }
.tm-go { flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--tm-blue); color: #fff; display: grid; place-items: center; }
.tm-row.off .tm-go { background: #d6d6d6; }
.tm-row.off .tm-date b, .tm-row.off .tm-main b { color: #8a8a8a; }
.tm-row:active { background: #fafafa; }

/* ticket page */
.tm-bar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 6px; min-height: 60px;
  padding: 8px 16px 8px 52px; background: #1a1a1a; color: #fff; }
.tm-bar .nav-back { top: 6px; color: #fff; }
.tm-bar div { min-width: 0; }
.tm-bar h1 { font-size: 17px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tm-bar { padding-top: 10px; padding-bottom: 10px; }
.tm-bar p { font-size: 14px; line-height: 1.45; color: #e2e2e2; }  /* time, then venue on its own line; wraps rather than being cut off */
.tm-bar h1 + p { margin-top: 3px; }
.tm-qty { background: #fff; padding: 12px 0 14px; }
.tm-qty h4 { margin: 0; padding: 0 16px 8px; line-height: 1.3; font-size: 13px; font-weight: 600; color: var(--muted); }
.tm-qty + .tm-sheet { margin-top: 8px; border-radius: 0; }
.tm-pills { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 0 16px; }
.tm-pills::-webkit-scrollbar { display: none; }
.tm-pills a, .tm-pills select { flex: none; height: 36px; padding: 0 16px; border-radius: 18px; display: inline-flex; align-items: center;
  background: #f1f1f1; color: #1f1f1f; font-size: 15px; font-weight: 600; white-space: nowrap; }
.tm-pills a[aria-current] { background: var(--brand); color: #fff; }
.tm-pills form { display: contents; }
.tm-pills select { appearance: none; -webkit-appearance: none; border: 0; outline: 0; padding-right: 34px;
  background: #f1f1f1 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23333' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat right 14px center; }
.tm-sheet { background: #fff; border-radius: 16px 16px 0 0; margin-top: 4px; padding: 18px 0 8px; display: flex; flex-direction: column; gap: 10px; }
.tm-sheet + .tm-sheet { border-radius: 0; margin-top: 10px; padding: 18px 16px; }
.tm-sheet-head { display: flex; justify-content: space-between; align-items: center; padding: 0 16px; }
.tm-sheet + .tm-sheet .tm-sheet-head { padding: 0; }
.tm-sheet-head b { font-size: 20px; font-weight: 800; }
.tm-sort { display: inline-flex; align-items: center; gap: 4px; color: var(--tm-blue); font-size: 15px; font-weight: 600; }
.tm-note { margin: 0; padding: 10px 16px; background: #eef2fb; font-size: 13px; color: #333; }
/* Ticket page filters: one row of dropdowns in the site's grey pill (like the old 更多 ▾), blue once set. */
.tm-sheet[data-ticket-list] { padding-top: 6px; }
.tm-stick { position: sticky; top: var(--bar-h, 0px); z-index: 3; background: #fff; display: flex; flex-direction: column;
  gap: 10px; padding-top: 12px; border-radius: 16px 16px 0 0; }
.tm-stick .tm-filter { margin: 0 16px 10px; }
.tm-filters { display: flex; align-items: center; gap: 8px; padding: 0 16px; }
.tm-filters form { display: contents; }
.tm-filters select { flex: none; height: 36px; padding: 0 34px 0 16px; border-radius: 18px; border: 0; outline: 0;
  appearance: none; -webkit-appearance: none; font: inherit; font-size: 15px; font-weight: 600; color: #1f1f1f;
  background: #f1f1f1 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23333' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat right 14px center; }
.tm-filters select.set { background-color: var(--brand); color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23fff' stroke-width='1.6'/%3E%3C/svg%3E"); }
.tm-filters .tm-sort { margin-left: auto; white-space: nowrap; font-size: 14px; }
.tm-meta { flex-wrap: wrap; gap: 4px 12px; padding-bottom: 12px; border-bottom: 1px solid #eee; }
.tm-meta b { font-size: 16px; }
.tm-facts { display: flex; flex-wrap: wrap; gap: 4px 10px; }
.tm-facts i { font-style: normal; display: inline-flex; align-items: center; gap: 3px; font-size: 12.5px; color: #4a4f57; }
.tm-facts .icon { color: var(--tm-blue); }
.tm-facts .warn, .tm-facts .warn .icon { color: var(--orange); }
.tm-sheet .tm-empty { padding: 20px 16px; }
.tm-seat { flex: 0 0 60px; height: 60px; border-radius: 50%; background: #f1f1f1; color: #8a8a8a; display: grid; place-items: center; }
.tm-seat.map { border-radius: 12px; background: #f6f7f9; padding: 4px; }
.sm-mini { width: 100%; height: 100%; display: block; }
.sm-mini-pick { fill: var(--brand, #3d6bff); stroke: #fff; stroke-width: 1; vector-effect: non-scaling-stroke; }
.sm-mini-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.tm-amount { flex: none; display: flex; flex-direction: column; align-items: flex-end; }
.tm-amount b { font-size: 19px; font-weight: 700; color: var(--tm-blue); }
.tm-amount small { font-size: 12px; color: var(--muted); }
.tm-main em { font-style: normal; color: var(--orange); }

/* Checkout, order and payment pages: same light colours as the show page, normal card layout. */
.app.tm-plain main { padding: 14px 16px 24px; gap: 14px; }
.app.tm-plain .navbar { background: #1a1a1a; color: #fff; }
.app.tm-plain .action-bar { background: #fff; box-shadow: 0 -1px 0 var(--line), 0 -4px 12px rgba(0,0,0,.05); }
.app.tm-plain .card { box-shadow: 0 1px 2px rgba(0,0,0,.05); }

/* Checkout: dark bar, step title, seat-map area, then white cards. */
.app.tm-checkout main { padding: 0 0 24px; gap: 0; }
.tm-map { position: relative; margin: 0; background: #e4e4e4; padding: 14px 16px 10px; text-align: center; }
.tm-map svg { width: 100%; max-width: 340px; height: auto; display: block; margin: 0 auto; }
.tm-map figcaption { font-size: 12px; color: #6f6f6f; margin-top: 4px; }
.tm-map.tm-nomap { background: #fff; }
.tm-co-body { display: flex; flex-direction: column; gap: 12px; padding: 12px 16px 0; }
.app.tm-checkout .action-bar { background: #fff; box-shadow: 0 -1px 0 var(--line), 0 -4px 12px rgba(0,0,0,.05); }
.app.tm-checkout .card { box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.tm-place h3 { display: flex; align-items: center; gap: 6px; }
.tm-where { font-size: 18px; font-weight: 700; margin: 6px 0 4px; }
.tm-where-sub { display: block; font-size: 14px; font-weight: 400; color: #6f6f6f; margin-top: 2px; }
.co-where { display: flex; align-items: center; gap: 8px; margin: 2px 0 0; }
.co-where .icon { color: var(--tm-blue); flex: none; }
.co-price { font-size: 22px !important; font-weight: 800; }
.co-price small { font-size: 13px; font-weight: 400; color: var(--muted); }
/* 张数: the plain box without scripts; with them, − n + around it. */
.co-qty { display: flex; align-items: center; gap: 10px; flex: none; }
.co-qty button { display: none; }
.co-qty.live button { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px;
  border-radius: 50%; border: 0; font-size: 22px; line-height: 1; color: #fff; background: var(--brand); cursor: pointer; }
.co-qty.live button[data-dir="-1"] { background: #fff; color: var(--brand); box-shadow: inset 0 0 0 1.5px #c9ccd2; }
.co-qty.live button:disabled, .co-qty.live button[data-dir="-1"]:disabled { background: #fff; color: #b5b8be; box-shadow: inset 0 0 0 1.5px #d3d6db; cursor: default; }
.co-qty.live .qty-select { min-width: 0; width: auto; padding: 0 2px; background: none; text-align: center;
  text-align-last: center; font-size: 18px; }
/* Contact on one line once it is known; 修改 opens the name box. */
.co-contact > summary { list-style: none; display: flex; align-items: center; gap: 12px; cursor: pointer; }
.co-contact > summary::-webkit-details-marker { display: none; }
.co-contact > summary::after { display: none; }
.co-contact > summary .icon { color: var(--tm-blue); flex: none; }
.co-contact > summary b { flex: 1; min-width: 0; font-size: 15px; }
.co-phone { margin: 2px 0 0 32px; font-size: 13px; color: var(--text-2); }
.co-contact-card .co-contact .field { margin-left: 32px; }
.co-more { font-size: 14px; color: var(--tm-blue); font-weight: 600; white-space: nowrap; }
.co-more::before { content: attr(data-closed); }
.co-more::after { content: "›"; display: inline-block; margin-left: 4px; transition: transform .15s; }
.co-contact[open] .co-more::before { content: attr(data-open); }
.co-contact[open] .co-more::after { transform: rotate(-90deg); }
.co-contact[open] > summary { margin-bottom: 2px; }
.co-contact[open] + .co-phone { margin-top: 10px; }

/* What is being paid: tickets, service fee, total. */
.co-total { margin: 0 4px; font-size: 14px; color: var(--text-2); }
.co-total > div { display: flex; justify-content: space-between; padding: 4px 0; }
.co-total .all { border-top: 1px solid #dfe2e6; margin-top: 6px; padding-top: 10px; color: var(--text); }
.co-total .all b { font-size: 18px; }
.tm-order-head { display: flex; align-items: center; gap: 12px; margin: 0; }
.tm-order-head .tm-seat { flex-basis: 56px; height: 56px; }
.tm-buy { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; padding-top: 14px;
  border-top: 1px solid var(--line); }
.tm-buy b { font-size: 16px; }
.tm-buy p { color: var(--text-2); }

/* Unpaid order: countdown strip, ticket card, one pay button. */
.tm-timer { display: flex; align-items: center; gap: 8px; background: #fff; padding: 12px 16px; border-bottom: 1px solid var(--line);
  color: var(--orange-text); font-size: 14px; }
.tm-timer b { color: var(--orange); }
.tm-total { font-size: 20px; }
.app.tm-checkout .link-btn { align-self: center; background: none; border: 0; color: var(--muted); font-size: 14px;
  text-decoration: underline; padding: 8px; }
.app.tm-checkout form:has(> .link-btn) { display: flex; justify-content: center; }
.tm-paid { display: flex; flex-direction: column; align-items: flex-end; }
.tm-paid small { font-size: 12px; color: var(--muted); }

/* Checkout: what kind of ticket, how to get in */
.entry-how { display: flex; flex-direction: column; gap: 12px; }
.entry-step { display: flex; gap: 12px; align-items: flex-start; }
.entry-step .icon { margin-top: 2px; color: var(--tm-blue, var(--brand)); }
.entry-step b { font-size: 15px; }
.entry-step p { font-size: 14px; color: var(--text-2); }

/* Phone sign-in and the verified phone at checkout */
.field.verified p { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 14px; border-radius: 8px;
  background: var(--card-2); font-size: 17px; }
.field.verified em { display: inline-flex; align-items: center; gap: 3px; font-style: normal; font-size: 13px; color: var(--teal); }
.tm-bar + .toast { margin: 12px 16px 0; }
/* Audience sign-in: the original centred layout, in the light colours of the buying flow. */
.app.tm-login main { padding: 14px 16px 24px; gap: 14px; }
.app.tm-login .navbar { background: transparent; }
.app.tm-login .field input { background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.app.tm-login .field input:focus { box-shadow: inset 0 0 0 1px var(--tm-blue); }
.app.tm-login .auth a { color: var(--tm-blue); }
.phone-big { font-style: normal !important; letter-spacing: .02em; }
.app.tm-login .link-btn { align-self: center; background: none; border: 0; color: var(--muted); font-size: 14px;
  text-decoration: underline; padding: 6px; }
.app.tm-login form:has(> .link-btn) { display: flex; justify-content: center; }
.app.tm-login .auth .muted-link { color: var(--muted); text-decoration: underline; }
.app.tm-login .staff-entry { margin-top: 96px; padding-top: 16px; border-top: 1px solid var(--line); text-align: center;
  font-size: 13px; color: var(--muted); }
.app.tm-login .staff-entry a { color: var(--text-2); text-decoration: underline; margin-left: 4px; }
.app.tm-login .link-btn:disabled { text-decoration: none; color: var(--faint); cursor: default; }
.date-card em { font-style: normal; font-size: 11px; color: var(--muted); line-height: 1; }
.date-card[aria-current] em { color: rgba(255,255,255,.8); }
.date-block em { font-style: normal; font-size: 11px; color: var(--muted); line-height: 1.1; }
.tm-amount small.tm-face { color: var(--muted); }
/* 我的: 退出登录 is a quiet last action, not louder than the menu above it. */
form[action="/logout"] .btn.ghost { font-size: 15px; font-weight: 500; color: var(--text-2); min-height: 46px; }
/* 资金管理 */
.funds-hero { gap: 12px; }
.funds-amount { font-size: 32px; font-weight: 800; line-height: 1.1; }
.funds-link { flex-direction: row; justify-content: space-between; align-items: center; padding: 14px 16px; }
.funds-link span { display: flex; align-items: center; gap: 8px; }
.funds-link .icon:first-child { color: var(--teal); }
.settle-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.settle-row { display: flex; flex-direction: column; gap: 4px; padding: 10px 0; border-top: 1px solid var(--line); }
.settle-row:first-child { border-top: 0; padding-top: 0; }
.settle-row .chip { align-self: flex-start; }
.funds-hero .stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 8px; padding: 4px 0; }
.funds-hero .stats > div { align-items: flex-start; }
.funds-hero .stats b { font-size: 18px; }
.menu-value { font-style: normal; font-size: 14px; color: var(--text-2); white-space: nowrap; }
.group:first-of-type { margin-top: 14px; }
/* 验票: pick a show — chevron on the right, the next-session chip under the dates */
.checkin-pick { align-items: center; }
.checkin-pick > div { flex: 1; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.checkin-pick > .icon { color: var(--text-2); flex: none; }
/* Whose numbers a session's 已售 / 待付款 / 剩余 are. */
.figures-caption { margin: 12px 0 -4px; font-size: 13px; color: var(--muted); }
/* "还有 N 个场次没卖票 · 去售票 ›" under a partner's own sessions. */
.card.more-row { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 12px;
  text-align: left; font-size: 15px; }
.card.more-row .link { display: inline-flex; align-items: center; gap: 2px; font-size: 14px; }

.form-page { display: flex; flex-direction: column; gap: 14px; }

/* ---- partner / admin on a computer ----
   Staff pages (.app.staff) keep the phone layout on phones. From 1000px wide the bottom tab bar becomes a
   left-hand menu, the content gets a desktop width, lists of cards sit side by side and forms keep a
   comfortable reading width. Buyer pages are untouched. */
.tabbar .side-brand { display: none; }
.tabbar.desk-only { display: none; }
@media (min-width: 1000px) {
  body:has(.app.staff) { background: var(--bg); }
  .app.staff { max-width: none; padding: 0 0 0 232px; }
  .app.staff.has-bar { padding-bottom: 0; }
  .app.staff .tabbar, .app.staff .tabbar.desk-only { display: flex; flex-direction: column; gap: 2px; top: 0; bottom: 0;
    left: 0; right: auto; width: 232px; max-width: none; margin: 0; padding: 20px 14px; background: var(--card);
    box-shadow: 1px 0 0 var(--line); }
  .app.staff .tabbar a { flex: none; height: 44px; flex-direction: row; justify-content: flex-start; gap: 12px;
    padding: 0 14px; border-radius: 10px; font-size: 15px; }
  .app.staff .tabbar a:hover { background: var(--card-2); color: var(--text); }
  .app.staff .tabbar a[aria-current] { background: var(--card-2); }
  .app.staff .tabbar .side-brand { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; height: auto;
    padding: 4px 14px 22px; font-size: 20px; font-weight: 800; color: var(--text); background: none; }
  .app.staff .tabbar .side-brand small { font-size: 12px; font-weight: 500; color: var(--muted); }
  .app.staff .navbar { height: 60px; max-width: 1040px; margin: 0 auto; }
  /* The back arrow sits level with the title and lines up with the content's left edge. */
  .app.staff .nav-back { top: 6px; left: 19px; }
  .app.staff .navbar h1 { font-size: 19px; }
  .app.staff > .toast { max-width: 1040px; margin: 16px auto 0; }
  .app.staff main { max-width: 1040px; margin: 0 auto; padding: 20px 32px 48px; gap: 16px; }
  .app.staff .action-bar { left: 232px; max-width: none; padding-left: 32px; padding-right: 32px; justify-content: flex-end; }
  .app.staff .action-bar .btn { flex: 0 0 auto; min-width: 200px; }
  /* Show and order cards: as many columns as fit. */
  .app.staff .show-list, .app.staff .order-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(420px, 1fr));
    align-items: start; }
  .app.staff .order-list:has(.past-row) { display: flex; }
  /* Forms stay at a readable width inside wide cards. */
  .app.staff .card > form, .app.staff details.card > form, .app.staff main > form:not(.card) { max-width: 680px; }
  .app.staff .flow-actions { display: flex; }
  .app.staff .flow-actions .btn { flex: none; height: 40px; padding: 0 24px; font-size: 15px; }
  .app.staff .flow-actions .flow-home { display: none; }
  .app.staff .form-page { max-width: 720px; gap: 16px; }  /* a page that is just a form: steps, hint and card together */
  .app.staff main > a.btn.block { align-self: flex-start; width: auto; padding: 0 36px; }
  .app.staff .menu, .app.staff main > form:has(> .btn.block) { max-width: 680px; }
}

.tm-row.off { cursor: default; }
.tm-row.off:active { background: none; }

/* Seat maps: our own drawing of the hall. Areas with tickets in the brand colour, the rest grey. */
.sm-map { position: relative; margin: 0; background: #f4f5f7; padding: 10px 10px 8px; }
.sm-view { overflow: auto; max-height: 72vh; border-radius: 8px; overscroll-behavior: contain; }
.sm-canvas { position: relative; width: 100%; }
.sm-canvas .sm-svg { display: block; width: 100%; height: auto; }
.sm-map figcaption { font-size: 12px; color: #7a7a7a; text-align: center; margin-top: 6px; }
.sm-zoom { position: absolute; right: 14px; top: 14px; z-index: 2; display: flex; flex-direction: column;
  background: #26282c; border-radius: 4px; overflow: hidden; }
.sm-zoom button { width: 34px; height: 34px; border: 0; border-radius: 0; background: transparent; color: #fff; padding: 0;
  display: grid; place-items: center; cursor: pointer; }
.sm-zoom button + button { border-top: 1px solid rgba(255,255,255,.16); }
.sm-zoom button:active { background: #3d4046; }
.sm-reset { position: absolute; left: 14px; top: 14px; z-index: 2; display: inline-flex; align-items: center; gap: 4px;
  height: 34px; padding: 0 12px 0 8px; border-radius: 4px; background: #26282c; color: #fff; font-size: 13px; font-weight: 600; }
.sm-reset[hidden] { display: none; }
.sm-reset svg, .tm-map .sm-reset svg { flex: none; width: 18px; height: 18px; margin: 0; display: block; }
.sm-reset { white-space: nowrap; text-align: left; }
.sm-map.zoomed .sm-view { cursor: grab; }
.sm-shape { stroke: #fff; stroke-width: 1.5; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.sm-shape.sale.on { fill: var(--brand, #3d6bff); }
.sm-shape.sale.off { fill: #d9dce2; }
.sm-shape.stage { fill: #2b2b30; }
.sm-shape.other { fill: #e6e8ec; }
.sm-shape[data-zone] { cursor: pointer; }
.sm-shape[data-zone]:not(.out):hover, .sm-shape[data-zone]:not(.out):focus { fill: #2d55d8; outline: none; }
.sm-map.has-pick .sm-shape.sale.on:not(.picked) { fill-opacity: .4; }
.sm-shape.sale.on.picked { fill: #1d3db0; }
.sm-label, .sm-price, .sm-note { text-anchor: middle; dominant-baseline: central; pointer-events: none;
  font-family: -apple-system, "PingFang SC", "Helvetica Neue", sans-serif; }
.sm-label { font-weight: 600; }
.sm-price { font-weight: 500; }
.sm-label.light, .sm-price.light { fill: #fff; }
.sm-label.dark, .sm-price.dark { fill: #4a4a4a; }
.sm-note { fill: #555; font-weight: 600; }
.tm-filter { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 4px 0 8px;
  padding: 8px 12px; background: #eef2ff; border-radius: 8px; font-size: 14px; }
.tm-filter button { border: 0; background: none; color: var(--brand, #3d6bff); font-size: 14px; cursor: pointer; padding: 0; }
.tm-list > li[hidden] { display: none; }

/* Staff editor: the picture under semi-transparent areas. */
.sm-list li a { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; }
.sm-list li + li { border-top: 1px solid var(--line); }
.sm-list li div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.sm-list li a.sm-special { padding: 10px 16px 10px 32px; border-top: 1px dashed var(--line); }
.sm-add-special { padding: 4px 16px 12px 32px; }
.sm-add-special summary { font-size: 13px; padding: 6px 0; cursor: pointer; }
.sm-add-special form { display: flex; flex-direction: column; gap: 10px; padding: 6px 0 0; }
.sm-editor { display: flex; flex-direction: column; gap: 10px; }
.sm-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.sm-check { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.sm-status { font-size: 14px; font-weight: 600; margin: 0; }
.sm-hint { font-size: 13px; color: var(--muted); margin: 0; }
.sm-draw-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13px; color: #c2410c; }
.sm-draw-bar[hidden], .sm-panel[hidden], .sm-panel [hidden] { display: none; }
.sm-map.editing { padding: 0; background: #fff; border: 1px solid var(--line); border-radius: 8px; }
.sm-map.editing .sm-picture { display: block; width: 100%; height: auto; user-select: none; -webkit-user-drag: none; }
.sm-map.editing .sm-canvas .sm-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.sm-map.editing .sm-shape { fill-opacity: .55; cursor: pointer; }
.sm-map.editing .sm-shape.unnamed { stroke: #e5484d; stroke-width: 2.5; }
.sm-map.editing .sm-shape.selected, .sm-map.editing .sm-note.selected { stroke: #f59e0b; stroke-width: 3.5; }
.sm-map.editing .sm-note { pointer-events: auto; cursor: pointer; }
.sm-map.editing.no-picture .sm-picture, .sm-map.editing.preview .sm-picture { visibility: hidden; }
.sm-map.editing.preview { background: #f4f5f7; }
.sm-map.editing.preview .sm-shape { fill-opacity: 1; stroke: #fff; stroke-width: 1.5; }
.sm-map.drawing .sm-svg { cursor: crosshair; }
.sm-map.drawing .sm-shape, .sm-map.drawing .sm-note { pointer-events: none; }
.sm-draft { fill: none; stroke: #ff5a36; stroke-width: 2; vector-effect: non-scaling-stroke; }
.sm-dot { fill: #ff5a36; }
.sm-dot.first { fill: #fff; stroke: #ff5a36; stroke-width: 2; vector-effect: non-scaling-stroke; }
.sm-panel { position: sticky; bottom: 0; z-index: 3; background: var(--card); border: 1px solid var(--line); border-radius: 12px;
  padding: 12px; box-shadow: 0 -4px 16px rgba(0,0,0,.25); display: flex; flex-direction: column; gap: 8px; }
.sm-panel .field { margin: 0; }

/* Ticket page price bands: tap one or several. */
.tm-price-filter { margin: 4px 0 10px; padding: 0 16px; display: flex; align-items: flex-start; gap: 10px; }
.tm-price-filter[hidden], .tm-empty[hidden] { display: none; }
.tm-price-filter > b { flex: none; font-size: 14px; line-height: 34px; }
.tm-price-pills { padding: 0; flex: 1; min-width: 0; flex-wrap: wrap; overflow: visible; }
.tm-price-pills button { flex: none; height: 34px; padding: 0 14px; border-radius: 17px; border: 0; display: inline-flex;
  align-items: center; gap: 4px; background: #f1f1f1; color: #1f1f1f; font: inherit; font-size: 14px; font-weight: 600;
  white-space: nowrap; cursor: pointer; }
.tm-price-pills button small { font-size: 12px; font-weight: 400; color: #8a8a8a; }
.tm-price-pills button[aria-pressed="true"] { background: var(--brand, #3d6bff); color: #fff; }
.tm-price-pills button[aria-pressed="true"] small { color: rgba(255,255,255,.8); }
.sm-shape.sale.on.out { fill: #d9dce2; cursor: default; }
.sm-label.light.dim { fill: #4a4a4a; }

/* Checkout boxes, one line each: name on the left, typed on the right, thin lines between (like phone settings). */
.co-rows .field { flex-direction: row; align-items: center; gap: 12px; min-height: 50px; padding: 0;
  border-bottom: 1px solid #eee; }
.co-rows .field > span { flex: none; width: 4.6em; font-size: 15px; color: var(--text); }
.co-rows .field textarea { flex: 1; min-width: 0; background: transparent; border-radius: 0; padding: 13px 0; min-height: 50px;
  font-size: 15px; line-height: 1.6; resize: none; overflow: hidden; field-sizing: content; }
.co-rows .field textarea:focus { box-shadow: none; }
.co-rows .field textarea::placeholder { color: var(--faint); }
.co-rows .field:has(textarea) > span { align-self: flex-start; padding-top: 13px; line-height: 1.6; }
.co-rows .field input { flex: 1; min-width: 0; background: transparent; border-radius: 0; padding: 13px 0; min-height: 50px; font-size: 15px; }
.co-rows .field input:focus { box-shadow: none; }
.co-rows .field input::placeholder { color: var(--faint); }
.co-rows .field input[readonly] { color: var(--muted); }
.co-rows .field > small { display: none; }
.co-rows .field.verified p { flex: 1; min-height: 50px; padding: 0; background: none; justify-content: space-between; }
.co-rows .check.switch { min-height: 50px; padding: 0; border-bottom: 1px solid #eee; }
.co-rows [data-ship-other][hidden] { display: none; }
.co-rows h3 + .field, .co-rows h3 + .check { margin-top: -6px; }
.co-rows > .field:last-child, .co-rows > div:last-child > .field:last-child,
.co-rows .attendee:last-child .field:last-child { border-bottom: 0; }
.co-rows .attendee legend { padding-top: 6px; }


/* ---- mini program sign-in: WeChat one-tap first, texting a code folded away under it ---- */
.mp-sms { margin-top: 4px; }
.app.tm-login .mp-sms > summary { justify-content: center; font-weight: 400; font-size: 14px; color: var(--muted); padding: 6px 0;
  text-decoration: underline; }
.app.tm-login .mp-sms > summary::after { display: none; }
.mp-sms > summary::-webkit-details-marker { display: none; }
.mp-sms[open] > summary { margin-bottom: 10px; }
.app.tm-login .auth a.btn { color: #fff; text-decoration: none; }

/* 《用户协议》《隐私政策》 (legal.py): a light, plain document — title block, one block per section,
   numbered clauses with bold labels. Also the links on the sign-in page and the footer of 首页 / 我的. */
html:has(.app.doc), html:has(.app.doc) body { background: #e9e9e9; }
.app.doc { --bg: #f4f4f4; --card: #fff; --line: #e4e4e4; --muted: #767676; --text-2: #3b3b3b; --text: #1f1f1f;
  color: var(--text); }
.app.doc .navbar { background: #fff; color: var(--text); box-shadow: 0 1px 0 var(--line); }
.app.doc main { padding: 0 0 32px; gap: 0; }
.doc-head { background: #fff; padding: 28px 20px 22px; border-bottom: 1px solid var(--line); }
.doc-head h1 { margin: 0 0 12px; font-size: 26px; font-weight: 800; letter-spacing: 1px; }
.doc-head p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.doc-sec { background: #fff; margin-top: 10px; padding: 20px 20px 12px; }
.doc-sec h2 { margin: 0 0 14px; padding-left: 10px; border-left: 3px solid #1f4fe0; font-size: 17px; font-weight: 700;
  line-height: 1.3; }
.doc-sec ol { margin: 0; padding: 0; list-style: none; counter-reset: item; }
.doc-sec li { position: relative; counter-increment: item; padding: 0 0 12px 24px; font-size: 15px; line-height: 1.75;
  color: var(--text-2); }
.doc-sec li::before { content: counter(item) "."; position: absolute; left: 0; top: 0; color: var(--muted);
  font-variant-numeric: tabular-nums; }
.doc-sec li b { display: block; color: var(--text); font-weight: 600; }
.doc-end { margin: 24px 20px 0; text-align: center; font-size: 13px; line-height: 2; color: var(--muted); }
.doc-end a { color: #1f4fe0; }
.agree, .site-foot { margin: 14px 0 0; text-align: center; font-size: 12px; color: var(--muted); }
.agree a, .site-foot a { color: var(--text-2); text-decoration: underline; }
.site-foot { margin: 28px 0 8px; line-height: 1.9; }
.site-foot p { margin: 0; }
.site-foot a[href^="https://beian"] { color: var(--muted); text-decoration: none; }

/* On the way to WeChat Pay / Alipay (buyer.leaving_for_payment): a calm white screen, no top bar. */
.leaving { margin: 22vh auto 0; max-width: 320px; text-align: center; }
.leaving .spinner { display: inline-block; width: 34px; height: 34px; border-radius: 50%; border: 3px solid #dfe5ff;
  border-top-color: #1f4fe0; animation: leaving-spin .8s linear infinite; }
@keyframes leaving-spin { to { transform: rotate(360deg); } }
.leaving h1 { margin: 18px 0 6px; font-size: 19px; font-weight: 700; color: var(--text); }
.leaving p { margin: 0 0 22px; font-size: 13px; color: var(--muted); }
.leaving .link-plain { display: inline-block; margin-top: 16px; font-size: 14px; color: var(--muted); text-decoration: underline; }

/* Order page: the dark bar scrolls away; the call-customer-service row at the bottom. */
.tm-bar.still { position: static; }
.card.service-call { flex-direction: row; align-items: center; text-align: left; gap: 10px; margin-bottom: 16px; color: inherit; text-decoration: none; }
.service-call span { flex: 1; font-weight: 600; }
.service-call b { font-weight: 500; color: var(--muted, #666); }
.tm-sub:empty { display: none; }  /* 随机座位 has no second line */
/* 演出简介 on the show forms: text and pictures in one framed box. */
fieldset.intro-block { border: 1px solid var(--line, #e2e2e2); border-radius: 10px; margin: 0; padding: 12px;
  display: flex; flex-direction: column; gap: 10px; min-width: 0; }
fieldset.intro-block legend { padding: 0 6px; font-size: 15px; font-weight: 600; color: var(--text); }
.intro-item { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.intro-item .small-btn { padding: 4px 8px; font-size: 12px; min-height: 0; }
.intro-thumb b { font-size: 13px; color: var(--text); }
[data-intro-new]:empty { display: none; }

/* ======================================================================================================
   Audience pages on a computer (from 1000px wide). Phones are untouched: everything below is inside the
   media query, and the site bar is hidden outside it. A dark bar across the top replaces the bottom tabs;
   lists spread into columns; the show page puts the details beside the sessions; the ticket page puts the
   seat map beside the tickets; checkout, order and sign-in pages stay a comfortable reading width.
   ====================================================================================================== */
.site-top { display: none; }
@media (min-width: 1000px) {
  .app:not(.staff) { max-width: none; background: var(--bg); }
  .app:not(.staff).has-bar:not(:has(.action-bar)) { padding-bottom: 0; }
  .app:not(.staff) .tabbar { display: none; }
  .site-top { display: block; position: sticky; top: 0; z-index: 20; background: #121212; color: #fff;
    box-shadow: 0 1px 0 rgba(255,255,255,.06); }
  .site-top > div { max-width: 1200px; margin: 0 auto; padding: 0 32px; height: 64px; display: flex; align-items: center;
    justify-content: space-between; }
  .site-brand { display: flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 800; letter-spacing: .02em; }
  .site-brand img { border-radius: 7px; }
  .site-top nav { display: flex; gap: 4px; }
  .site-top nav a { padding: 8px 16px; border-radius: 8px; font-size: 15px; color: #bdbdbd; }
  .site-top nav a:hover { color: #fff; background: rgba(255,255,255,.08); }
  .site-top nav a[aria-current] { color: #fff; font-weight: 700; box-shadow: inset 0 -3px 0 var(--brand, #3d6bff); border-radius: 8px 8px 0 0; }

  /* Default width: lists and forms (收藏, 票夹, 我的, 选择城市, 修改密码…). */
  .app:not(.staff) > main { max-width: 960px; margin: 0 auto; padding: 28px 32px 56px; }
  .app:not(.staff) > .navbar:not(.float) { max-width: 960px; margin: 0 auto; }
  .app:not(.staff) > .toast { max-width: 896px; margin: 16px auto 0; }
  .app:not(.staff) .order-list, .app:not(.staff) .show-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px; align-items: start; }
  .app:not(.staff) .order-list:has(.past-row) { display: flex; }

  /* Home: wide, recommendations four to a row instead of a sideways strip, the hot list in two columns. */
  .app.home > main { max-width: 1200px; padding-top: 24px; }
  .app.home .search-pill { max-width: 640px; }
  .app.home .feature-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0;
    overflow: visible; }
  .app.home .feature { border-radius: 8px; transition: transform .15s; }
  .app.home .feature:hover { transform: translateY(-3px); }
  .app.home .feature-art { height: 260px; }
  .app.home .feature-img { max-height: 232px; }
  .app.home .feature-img.poster-empty { height: 232px; }
  .app.home .feature h3 { font-size: 17px; }
  .app.home .rank-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .app.home .rank-card { border-radius: 8px; }
  .app.home .rank-card:hover { background: var(--card-2); }

  /* Light pages (show, tickets, checkout, order, sign-in): the page column on the light grey. */
  .app.tm:not(.staff) > main { max-width: 1200px; padding: 0 32px 56px; }

  /* Show page: a wide banner, then the sessions (and comments) on the left with the details beside them. */
  .app.tm:not(.tm-tickets):not(.tm-checkout):not(.tm-login):not(.tm-plain):has(.tm-hero) > main {
    display: grid; grid-template-columns: minmax(0, 1fr) 380px; column-gap: 28px; align-items: start; padding-top: 24px; }
  .app.tm .navbar.float { display: none; }  /* the site bar is there; the back arrow over the picture isn't needed */
  .app.tm > main > .tm-hero { grid-column: 1 / -1; aspect-ratio: auto; height: 420px; border-radius: 12px; }
  /* poster on the left, the name beside it */
  .app.tm > main > .tm-hero .hero-poster { left: 40px; transform: none; top: 28px; bottom: 28px; height: calc(100% - 56px);
    max-width: 300px; border-radius: 6px; }
  .app.tm > main > .tm-hero .tm-name { left: 372px; right: 48px; bottom: 40px; font-size: 38px; }
  .app.tm > main > .tm-hero .hero-tools { top: 16px; right: 16px; }
  .app.tm > main > .tm-tabs { display: none; }
  .app.tm > main > .show-details { grid-column: 2; grid-row: 2 / span 20; position: sticky; top: 80px; }
  .app.tm > main > .tm-panel, .app.tm > main > .show-details .tm-panel { border-radius: 10px; }
  .app.tm .tm-row { border-radius: 6px; }
  .app.tm a.tm-row:hover { background: #fafafa; }
  .app.tm .tm-row:hover .tm-go { filter: brightness(1.1); }

  /* Ticket page: dark show bar across, the seat map on the left (stays in view), tickets and notes on the right. */
  .app.tm-tickets:not(.staff) > main { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); column-gap: 24px;
    align-items: start; padding-top: 24px; }
  .app.tm-tickets > main > .tm-bar, .app.tm-tickets > main > .toast { grid-column: 1 / -1; }
  .app.tm-tickets > main > .tm-bar { position: relative; border-radius: 10px 10px 0 0; }
  .app.tm > main > .tm-bar .nav-back { left: 4px; }
  .app.tm-tickets > main > .tm-map { grid-column: 1; grid-row: 2 / span 20; position: sticky; top: 80px; border-radius: 0 0 0 10px; }
  .app.tm-tickets > main > .tm-map .sm-view { max-height: calc(100vh - 200px); }
  .app.tm-tickets > main > .tm-sheet { grid-column: 2; margin-top: 0; border-radius: 0 0 10px 0; }
  .app.tm-tickets > main > .tm-sheet + .tm-sheet { border-radius: 10px; }
  .app.tm-tickets > main > .tm-sheet + .tm-sheet { margin-top: 16px; }
  .app.tm-tickets .tm-stick { top: 64px; }
  .app.tm-tickets a.tm-row:hover { background: #fafafa; }

  /* Checkout, order, payment, sign-in: one column of reading width, the action bar under it. */
  .app.tm-checkout:not(.staff) > main, .app.tm-plain:not(.staff) > main { max-width: 824px; padding-top: 24px; }
  .app.tm-checkout .tm-co-body, .app.tm-plain .tm-co-body { padding-left: 0; padding-right: 0; }
  .app.tm-checkout > main > .tm-map, .app.tm-checkout > main > form > .tm-map { border-radius: 0 0 10px 10px; }
  .app.tm-checkout .card { border-radius: 10px; }
  .app.tm-checkout > main > .tm-bar, .app.tm-plain > main > .tm-bar { position: relative; border-radius: 10px; }
  .app.tm-checkout .action-bar, .app.tm-plain .action-bar { max-width: 760px; border-radius: 12px 12px 0 0;
    box-shadow: 0 -2px 12px rgba(0,0,0,.08); }
  .app.tm-login:not(.staff) > main { max-width: 480px; padding-top: 48px; }
  .app.doc > main { max-width: 820px; }
}
