:root {
  --bg: #f3eeed;
  --bg2: #ebe4e2;
  --card: #ffffff;
  --line: #ece4e2;
  --ink: #1f1a1b;
  --muted: #7d7274;
  --faint: #b3a8a9;
  --accent: #b5838a;
  --accent-deep: #9c6870;
  --accent-ink: #ffffff;
  --accent-soft: #f4e9ea;
  --glass: rgba(255, 255, 255, .62);
  --glass-ink: #1f1a1b;
  --good: #6f9a74;
  --warn: #c39a4a;
  --bad: #c0645f;
  --shadow: 0 18px 40px -18px rgba(90, 55, 60, .35);
  --shadow-sm: 0 8px 20px -10px rgba(90, 55, 60, .35);
  --r-xl: 30px;
  --r-lg: 22px;
  --r: 16px;
  --font: "Urbanist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --tabh: 76px;
  --mini: 0px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171314; --bg2: #1f1a1b; --card: #262021; --line: #352d2e;
    --ink: #f6eeee; --muted: #b0a3a5; --faint: #786c6e;
    --accent: #d1a0a7; --accent-deep: #e2b6bc; --accent-ink: #231b1c; --accent-soft: #3a2c2e;
    --glass: rgba(30, 24, 25, .55); --glass-ink: #fff;
    --shadow: 0 18px 40px -18px rgba(0, 0, 0, .7); --shadow-sm: 0 8px 20px -10px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 500 15px/1.45 var(--font); -webkit-font-smoothing: antialiased; }
body { min-height: 100dvh; overscroll-behavior-y: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
input { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-weight: 700; letter-spacing: -.01em; margin: 0; }
svg.i { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ---------- shell */
.shell { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 100dvh; }
.main { min-width: 0; padding: calc(14px + env(safe-area-inset-top)) 16px calc(var(--tabh) + var(--mini) + 30px + env(safe-area-inset-bottom)); max-width: 1180px; width: 100%; margin: 0 auto; }
.top { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; margin: 2px 0 18px; }
.top h1 { font-size: 19px; text-align: center; display: flex; align-items: center; justify-content: center; gap: 8px; }
.top h1 .dots { display: inline-grid; grid-template-columns: 6px 6px; gap: 2px; }
.top h1 .dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.top h1 .dots i:first-child { grid-column: span 2; justify-self: center; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand .word { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.avatar { width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-deep)); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 16px; box-shadow: var(--shadow-sm); }
.menu { position: relative; }

.tabs { position: fixed; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 30; height: 64px; border-radius: 26px;
  display: grid; grid-template-columns: repeat(4, 1fr); background: var(--card); box-shadow: var(--shadow); }
.tabs a { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--faint); }
.tabs a span { display: none; }
.tabs a.on { color: var(--accent); }
.tabs a.on::after { content: ""; position: absolute; bottom: 10px; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }
.tabs .rail-brand { display: none; }

@media (min-width: 900px) {
  :root { --tabh: 0px; }
  .shell { grid-template-columns: 232px minmax(0, 1fr); }
  .tabs { position: sticky; top: 0; left: auto; right: auto; bottom: auto; height: 100dvh; border-radius: 0; box-shadow: none; display: flex; flex-direction: column; align-items: stretch; gap: 6px; padding: 26px 16px; background: var(--card); border-right: 1px solid var(--line); }
  .tabs a { flex-direction: row; justify-content: flex-start; gap: 14px; padding: 12px 16px; border-radius: 14px; color: var(--muted); font-weight: 600; }
  .tabs a span { display: inline; }
  .tabs a:hover { background: var(--bg); color: var(--ink); }
  .tabs a.on { background: var(--accent-soft); color: var(--accent-deep); }
  .tabs a.on::after { display: none; }
  .tabs .rail-brand { display: flex; margin: 0 8px 26px; }
  .main { padding: 28px 40px calc(var(--mini) + 40px); }
}

/* ---------- covers + cards */
.section { margin: 8px 0 30px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.section-head h2 { font-size: 20px; }
.section-head a, .link { color: var(--accent-deep); font-size: 14px; font-weight: 700; }
.row { display: grid; grid-auto-flow: column; grid-auto-columns: 128px; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 16px; padding: 2px 16px 16px; margin: 0 -16px; scrollbar-width: none; }
.row::-webkit-scrollbar { display: none; }
.row > * { scroll-snap-align: start; }
@media (min-width: 900px) { .row { grid-auto-columns: 156px; margin: 0; padding-left: 0; padding-right: 0; } }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 22px 16px; }
@media (min-width: 900px) { .grid { grid-template-columns: repeat(auto-fill, minmax(164px, 1fr)); gap: 28px 22px; } }

.book { display: block; min-width: 0; text-align: left; }
.cover { position: relative; aspect-ratio: 1; border-radius: var(--r); overflow: hidden; background: var(--bg2); box-shadow: var(--shadow-sm); }
.cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cover .ph { position: absolute; inset: 0; display: grid; place-items: center; padding: 14px; text-align: center; font-weight: 700; font-size: 15px; color: var(--accent-deep);
  background: linear-gradient(150deg, var(--accent-soft), var(--bg2)); }
.cover .bar { position: absolute; left: 10px; right: 10px; bottom: 10px; height: 5px; border-radius: 5px; background: rgba(255,255,255,.55); overflow: hidden; backdrop-filter: blur(6px); }
.cover .bar i { display: block; height: 100%; background: var(--accent); }
.cover .done { position: absolute; top: 8px; right: 8px; width: 26px; height: 26px; border-radius: 50%; background: var(--glass); backdrop-filter: blur(10px); display: grid; place-items: center; color: var(--accent-deep); }
.cover .done svg { width: 15px; height: 15px; stroke-width: 2.6; }
.book .t { margin-top: 10px; font-weight: 700; font-size: 14.5px; line-height: 1.25; display: flex; align-items: center; gap: 4px; }
.book .t span { display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.book .t svg { width: 15px; height: 15px; color: var(--faint); }
.book .a { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }

/* ---------- featured carousel */
.carousel { display: grid; grid-auto-flow: column; grid-auto-columns: min(78%, 330px); gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 6px calc(50% - min(39%, 165px)) 24px; margin: 0 -16px 10px; scrollbar-width: none; }
.carousel::-webkit-scrollbar { display: none; }
@media (min-width: 900px) { .carousel { margin: 0 0 10px; padding: 6px 0 24px; grid-auto-columns: 300px; } }
.feature { position: relative; scroll-snap-align: center; aspect-ratio: 3 / 4; border-radius: var(--r-xl); overflow: hidden; box-shadow: var(--shadow); background: var(--bg2); color: #fff; display: block; }
.feature > img, .feature > .ph { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.feature > .ph { display: grid; place-items: center; padding: 30px; text-align: center; font-size: 22px; font-weight: 800; color: var(--accent-deep); background: linear-gradient(150deg, var(--accent-soft), var(--bg2)); }
.feature .shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20,12,14,.05) 0%, rgba(20,12,14,.15) 30%, rgba(20,12,14,.78) 100%); }
.feature .badge { position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 46px; height: 40px; border-radius: 0 0 16px 16px; background: var(--card); display: grid; place-items: center; color: var(--accent); }
.feature .badge::before, .feature .badge::after { content: ""; position: absolute; top: 0; width: 14px; height: 14px; background: radial-gradient(circle at 0 100%, transparent 13px, var(--card) 14px); }
.feature .badge::before { left: -14px; transform: scaleX(-1); }
.feature .badge::after { right: -14px; }
.feature .badge svg { width: 20px; height: 20px; }
.feature .body { position: absolute; left: 0; right: 0; bottom: 0; padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.feature .k { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; opacity: .85; }
.feature h3 { font-size: 22px; line-height: 1.15; text-shadow: 0 2px 12px rgba(0,0,0,.3); }
.feature .blurb { font-size: 13px; line-height: 1.4; opacity: .92; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.glass { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; border-radius: 11px; background: rgba(255,255,255,.22); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); font-size: 12.5px; font-weight: 700; color: #fff; border: 1px solid rgba(255,255,255,.25); }
.glass svg { width: 15px; height: 15px; }
.chiprow { display: flex; gap: 8px; flex-wrap: wrap; }
.feature .go { align-self: center; display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 22px; border-radius: 16px; background: rgba(255,255,255,.88); color: #1f1a1b; font-weight: 700; box-shadow: 0 10px 24px -10px rgba(0,0,0,.5); }
.feature .go svg { width: 18px; height: 18px; }
.feature .go[disabled] { opacity: .7; }

/* ---------- buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 22px; border-radius: 16px; background: var(--accent); color: var(--accent-ink); font-weight: 700; white-space: nowrap; box-shadow: 0 10px 22px -12px var(--accent-deep); }
.btn:hover { background: var(--accent-deep); }
.btn.ghost { background: var(--card); color: var(--ink); box-shadow: var(--shadow-sm); }
.btn.small { height: 36px; padding: 0 14px; border-radius: 12px; font-size: 13.5px; }
.btn.wide { width: 100%; }
.btn[disabled] { opacity: .6; cursor: default; }
.btn svg.i { width: 18px; height: 18px; }
.iconbtn { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; }
.iconbtn:hover { background: var(--bg2); }

/* ---------- toolbar */
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.search { flex: 1 1 260px; display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 16px; border-radius: 18px; background: var(--card); box-shadow: var(--shadow-sm); }
.search input { flex: 1; border: 0; background: none; outline: none; min-width: 0; font-weight: 500; }
.search svg { color: var(--faint); }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.chip { height: 36px; padding: 0 15px; border-radius: 12px; background: var(--card); color: var(--muted); font-size: 13.5px; font-weight: 600; white-space: nowrap; }
.chip.on { background: var(--accent); color: var(--accent-ink); }
.count { color: var(--faint); font-size: 13px; margin: -6px 0 14px; }

/* ---------- book detail */
.detail { display: grid; gap: 20px; margin: calc(-14px - env(safe-area-inset-top)) -16px 0; }
.detail .art { position: relative; }
.detail .art .cover { border-radius: 0 0 var(--r-xl) var(--r-xl); aspect-ratio: 1; box-shadow: var(--shadow); }
.detail .art .backbtn { position: absolute; top: calc(16px + env(safe-area-inset-top)); left: 16px; width: 46px; height: 46px; border-radius: 15px; background: rgba(255,255,255,.3); backdrop-filter: blur(14px); color: #fff; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.35); }
.detail .info { padding: 0 20px; }
.detail h1 { font-size: 27px; line-height: 1.15; }
.detail .by { color: var(--accent); font-weight: 600; font-size: 16px; margin-top: 6px; }
.detail .actions { display: flex; gap: 10px; margin: 22px 0 8px; }
.detail .actions .btn:first-child { flex: 1; }
.facts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.fact { display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border-radius: 11px; background: var(--card); color: var(--muted); font-size: 13px; font-weight: 600; box-shadow: var(--shadow-sm); }
.fact svg { width: 16px; height: 16px; color: var(--accent); }
.desc { color: var(--muted); max-width: 70ch; margin-top: 18px; line-height: 1.55; }
.desc b { color: var(--ink); font-weight: 700; }
.desc.clip { display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.chapters { background: var(--card); border-radius: var(--r-lg); padding: 4px 16px; box-shadow: var(--shadow-sm); }
.chapters button { display: flex; width: 100%; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); text-align: left; }
.chapters button:last-child { border-bottom: 0; }
.chapters .n { color: var(--faint); width: 26px; font-variant-numeric: tabular-nums; }
.chapters .ct { flex: 1; }
.chapters .d { color: var(--faint); font-variant-numeric: tabular-nums; }
@media (min-width: 900px) {
  .detail { grid-template-columns: 340px 1fr; gap: 44px; align-items: start; margin: 0; }
  .detail .art .cover { border-radius: var(--r-xl); }
  .detail .art .backbtn { top: 14px; left: 14px; }
  .detail .info { padding: 10px 0 0; }
  .detail h1 { font-size: 38px; }
}

/* ---------- discover */
.result { display: grid; grid-template-columns: 84px 1fr; gap: 14px; padding: 12px; border-radius: var(--r-lg); background: var(--card); box-shadow: var(--shadow-sm); margin-bottom: 12px; }
.result .cover { box-shadow: none; border-radius: 12px; }
.result .t { font-weight: 700; line-height: 1.25; }
.result .a { color: var(--muted); font-size: 13.5px; margin-top: 2px; }
.result .why { color: var(--accent-deep); font-size: 13px; margin-top: 6px; font-weight: 600; }
.result .foot { display: flex; align-items: center; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.result .len { color: var(--faint); font-size: 13px; }
@media (min-width: 900px) { .results { display: grid; grid-template-columns: 1fr 1fr; column-gap: 16px; } }

.pill { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; border-radius: 10px; font-size: 12.5px; font-weight: 700; background: var(--bg2); color: var(--muted); }
.pill.good { color: var(--good); background: color-mix(in srgb, var(--good) 14%, transparent); }
.pill.warn { color: var(--warn); background: color-mix(in srgb, var(--warn) 15%, transparent); }
.pill.bad { color: var(--bad); background: color-mix(in srgb, var(--bad) 13%, transparent); }
.pill.accent { color: var(--accent-deep); background: var(--accent-soft); }
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pill .dot.pulse { animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }

.panelcard { background: var(--card); border-radius: var(--r-lg); padding: 18px; box-shadow: var(--shadow-sm); margin-bottom: 22px; display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.panelcard .ic { width: 46px; height: 46px; border-radius: 14px; background: var(--accent-soft); color: var(--accent-deep); display: grid; place-items: center; flex: none; }
.panelcard .tx { flex: 1 1 200px; }
.panelcard .tx b { display: block; font-size: 16px; }
.panelcard .tx span { color: var(--muted); font-size: 13.5px; }
.steps { color: var(--muted); font-size: 13.5px; margin: 6px 0 0; padding-left: 18px; }

/* ---------- requests */
.req { display: grid; grid-template-columns: 70px 1fr auto; gap: 14px; align-items: center; padding: 12px; border-radius: var(--r-lg); background: var(--card); box-shadow: var(--shadow-sm); margin-bottom: 12px; }
.req .cover { box-shadow: none; border-radius: 12px; }
.req .t { font-weight: 700; line-height: 1.25; }
.req .a { color: var(--muted); font-size: 13.5px; }
.req .prog { height: 5px; border-radius: 5px; background: var(--bg2); margin-top: 9px; overflow: hidden; }
.req .prog i { display: block; height: 100%; background: var(--accent); transition: width .6s; }
.req .when { color: var(--faint); font-size: 12.5px; margin-top: 6px; }
.req .side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.empty { text-align: center; padding: 46px 20px; color: var(--muted); }
.empty h3 { color: var(--ink); font-size: 20px; margin-bottom: 6px; }
.empty .btn { margin-top: 14px; }

/* ---------- mini player */
.mini { position: fixed; z-index: 29; left: 12px; right: 12px; bottom: calc(var(--tabh) + env(safe-area-inset-bottom) + 6px); display: grid; grid-template-columns: 48px 1fr auto auto; gap: 12px; align-items: center;
  padding: 8px; border-radius: 20px; background: var(--card); box-shadow: var(--shadow); overflow: hidden; }
.mini .cover { border-radius: 12px; box-shadow: none; }
.mini .t { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini .a { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini .line { position: absolute; left: 0; bottom: 0; height: 3px; background: var(--accent); }
.mini .open { min-width: 0; text-align: left; }
.mini [data-a=toggle] { background: var(--accent); color: #fff; }
.mini [data-a=toggle] svg { fill: currentColor; stroke: none; }
@media (min-width: 900px) { .mini { left: 252px; right: 20px; bottom: 16px; max-width: 720px; margin: 0 auto; } }

/* ---------- full player: tinted from the cover */
.player { --p-bg: #2a2224; --p-bg2: #342b2d; --p-line: #4a3d40; --p-acc: #e2b6bc; --p-acc-ink: #231b1c; --p-text: #f7eff0; --p-muted: #c4b2b5;
  position: fixed; inset: 0; z-index: 50; background: var(--p-bg); color: var(--p-text); display: flex; flex-direction: column;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom); transform: translateY(100%); transition: transform .34s cubic-bezier(.2,.8,.2,1), background .6s; }
.player.open { transform: none; }
.player .phead { display: grid; grid-template-columns: 48px 1fr 48px; align-items: center; gap: 6px; padding: 12px 12px 10px; background: color-mix(in srgb, var(--p-bg2) 70%, transparent); }
.player .phead .iconbtn { color: var(--p-text); }
.player .phead .iconbtn:hover { background: var(--p-line); }
.player .ptitle { min-width: 0; }
.player .ptitle b { display: block; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player .ptitle span { display: block; font-size: 13px; color: var(--p-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player.listing [data-a=view] { color: var(--p-acc); }
.player .pstage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 18px 24px; overflow: hidden; }
.player .pcover { width: min(100%, 52dvh, 420px); }
.player .pcover .cover { border-radius: 22px; box-shadow: 0 30px 60px -24px rgba(0,0,0,.7); transition: transform .4s; }
.player.paused .pcover .cover { transform: scale(.94); }
.player .pchapters { align-self: stretch; width: 100%; max-width: 560px; margin: 0 auto; overflow-y: auto; background: color-mix(in srgb, var(--p-bg2) 80%, transparent); border-radius: 18px; padding: 4px 0; }
.player .pchapters button { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; text-align: left; padding: 13px 18px; border-bottom: 1px solid var(--p-line); }
.player .pchapters button:last-child { border-bottom: 0; }
.player .pchapters b { display: block; font-weight: 600; }
.player .pchapters span { font-size: 12.5px; color: var(--p-muted); font-variant-numeric: tabular-nums; }
.player .pchapters .now b { color: var(--p-acc); }
.player .pp { width: 28px; height: 28px; border-radius: 50%; background: var(--p-acc); color: var(--p-acc-ink); display: grid; place-items: center; flex: none; }
.player .pp svg { width: 13px; height: 13px; fill: currentColor; stroke: none; margin-left: 2px; }
.eq { display: flex; align-items: flex-end; gap: 3px; height: 18px; width: 28px; justify-content: center; }
.eq s { width: 3px; background: var(--p-acc); border-radius: 2px; animation: eq 1s ease-in-out infinite; height: 40%; }
.eq s:nth-child(2) { animation-delay: -.4s; } .eq s:nth-child(3) { animation-delay: -.7s; }
.player.paused .eq s { animation-play-state: paused; }
@keyframes eq { 50% { height: 100%; } }
.player .pdock { padding: 10px 22px 18px; background: color-mix(in srgb, var(--p-bg2) 70%, transparent); }
.player .pdock > * { max-width: 560px; margin-left: auto; margin-right: auto; }
.scrub input { -webkit-appearance: none; appearance: none; width: 100%; height: 22px; background: transparent; margin: 4px 0 2px; }
.scrub input::-webkit-slider-runnable-track { height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--p-acc) var(--fill, 0%), var(--p-line) var(--fill, 0%)); }
.scrub input::-moz-range-track { height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--p-acc) var(--fill, 0%), var(--p-line) var(--fill, 0%)); }
.scrub input::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: #fff4d6; margin-top: -6px; box-shadow: 0 2px 6px rgba(0,0,0,.4); }
.scrub input::-moz-range-thumb { width: 16px; height: 16px; border: 0; border-radius: 50%; background: #fff4d6; }
.times { display: flex; justify-content: space-between; color: var(--p-muted); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.controls { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; }
.controls .side { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 11.5px; color: var(--p-muted); width: 52px; }
.controls .side b { font-size: 17px; color: var(--p-acc); height: 22px; line-height: 22px; }
.controls .side svg { color: var(--p-acc); }
.controls .side.on span { color: var(--p-acc); }
.controls .ctl { width: 40px; height: 44px; display: grid; place-items: center; color: var(--p-text); position: relative; }
.controls .ctl svg { width: 22px; height: 22px; }
.controls .ctl.skip svg { width: 30px; height: 30px; stroke-width: 1.5; }
.controls .ctl.skip em { position: absolute; font-style: normal; font-size: 9.5px; font-weight: 800; top: 17px; }
.controls .ctl [d] { }
.controls .play { width: 66px; height: 66px; border-radius: 50%; background: var(--p-acc); color: var(--p-acc-ink); display: grid; place-items: center; box-shadow: 0 12px 26px -12px rgba(0,0,0,.6); flex: none; }
.controls .play svg.i { width: 28px; height: 28px; fill: currentColor; stroke: none; }
.player .pleft { text-align: center; color: var(--p-muted); font-size: 12px; margin-top: 8px; }
@media (max-width: 370px) { .controls .ctl:not(.skip) { display: none; } }
@media (min-width: 900px) { .player .pstage { padding: 30px; } }

.sheet { position: fixed; inset: 0; z-index: 60; background: rgba(30,20,22,.35); display: flex; align-items: flex-end; justify-content: center; backdrop-filter: blur(3px); }
.sheet .panel { width: 100%; max-width: 520px; max-height: 75dvh; overflow-y: auto; background: var(--card); border-radius: var(--r-xl) var(--r-xl) 0 0; padding: 22px 20px calc(20px + env(safe-area-inset-bottom)); }
.sheet h3 { font-size: 19px; margin-bottom: 8px; }
.opts button { display: block; width: 100%; text-align: left; padding: 14px 4px; border-bottom: 1px solid var(--line); }
.opts button.on { color: var(--accent-deep); font-weight: 700; }

/* ---------- welcome / sign in */
.signin { min-height: 100dvh; display: grid; place-items: center; padding: 16px; }
.welcome { position: relative; width: 100%; max-width: 420px; min-height: min(92dvh, 820px); border-radius: 36px; overflow: hidden; box-shadow: var(--shadow); color: #fff; display: flex; flex-direction: column; justify-content: flex-end;
  background:
    radial-gradient(120% 70% at 85% 10%, rgba(255, 220, 200, .55), transparent 60%),
    radial-gradient(90% 60% at 0% 40%, rgba(150, 95, 85, .65), transparent 70%),
    linear-gradient(170deg, #d8c3b6 0%, #a9827a 42%, #5d3f3d 100%); }
.welcome .art { position: absolute; inset: 0; display: grid; place-items: start center; padding-top: 9%; opacity: .95; }
.welcome .art svg { width: 78%; max-width: 330px; filter: drop-shadow(0 30px 40px rgba(40,20,20,.45)); }
.welcome .copy { position: relative; padding: 0 28px; text-align: center; }
.welcome h1 { font-size: 34px; line-height: 1.1; text-shadow: 0 2px 20px rgba(0,0,0,.25); }
.welcome .copy p { margin: 10px 0 0; opacity: .9; }
.welcome form { position: relative; margin: 22px 18px 18px; padding: 18px; border-radius: 26px; background: rgba(255,255,255,.18); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); border: 1px solid rgba(255,255,255,.28); }
.welcome .field { display: block; margin-bottom: 10px; }
.welcome .field input { width: 100%; height: 50px; padding: 0 16px; border-radius: 16px; border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.88); color: #1f1a1b; outline: none; font-weight: 600; }
.welcome .field input::placeholder { color: #8b7f80; font-weight: 500; }
.welcome .field input:focus { border-color: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,.35); }
.welcome .btn { width: 100%; height: 54px; margin-top: 4px; font-size: 16px; background: #b5838a; color: #fff; box-shadow: 0 14px 26px -12px rgba(60, 25, 30, .9); }
.welcome .err { color: #ffe1dc; font-size: 14px; min-height: 20px; margin: 2px 0 6px; text-align: center; font-weight: 700; }
.welcome .hint { text-align: center; color: rgba(255,255,255,.8); font-size: 12.5px; margin: 12px 0 0; }
.welcome .brand { position: absolute; top: 22px; left: 24px; color: #fff; }
.welcome .brand .word { font-size: 20px; }

.toast { position: fixed; z-index: 80; left: 50%; bottom: calc(var(--tabh) + var(--mini) + 26px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 14px; font-size: 14px; font-weight: 600; box-shadow: var(--shadow); max-width: calc(100vw - 32px); }
.skeleton { background: linear-gradient(90deg, var(--card), var(--bg2), var(--card)); background-size: 200% 100%; animation: sk 1.3s linear infinite; }
@keyframes sk { to { background-position: -200% 0; } }
.menu .pop { position: absolute; left: 0; top: 50px; z-index: 40; background: var(--card); border-radius: 16px; padding: 6px; min-width: 200px; box-shadow: var(--shadow); }
.menu .pop .who { padding: 9px 10px; color: var(--muted); font-size: 13px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.menu .pop button { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; padding: 10px; border-radius: 10px; }
.menu .pop button:hover { background: var(--bg); }

/* ---------- request sheet */
.sheet .want .wanthead { display: grid; grid-template-columns: 110px 1fr; gap: 16px; align-items: center; }
.sheet .want h3 { font-size: 20px; line-height: 1.2; margin: 0; }
.sheet .want .by { color: var(--accent); font-weight: 600; margin-top: 4px; }
.sheet .want .facts { margin-top: 10px; }
.sheet .want .why { display: flex; gap: 8px; align-items: flex-start; background: var(--accent-soft); color: var(--accent-deep); padding: 12px 14px; border-radius: 14px; font-weight: 600; font-size: 14px; margin: 16px 0 0; }
.sheet .want .why svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.sheet .want .len { color: var(--faint); font-size: 13px; margin: 12px 0 0; }
.sheet .want .desc { margin-top: 12px; font-size: 14px; }
.sheet .want .foot { display: flex; gap: 10px; align-items: center; margin-top: 18px; }
.sheet .want .foot .btn { flex: 1; height: 50px; font-size: 15px; }
button.book { padding: 0; }
.result[data-want] { cursor: pointer; }
.feature .body[data-want] { cursor: pointer; }
.feature.skeleton { background: linear-gradient(90deg, var(--card), var(--bg2), var(--card)); background-size: 200% 100%; }

/* ---------- welcome tweaks */
.welcome.photo { background-size: cover; background-position: center; }
.welcome .cta { position: relative; padding: 26px 24px 26px; }
.welcome .cta .btn { height: 58px; border-radius: 20px; }
.welcome.form .art { opacity: .35; transition: opacity .3s; }
.welcome.form .copy p { display: none; }
