/* Tạo Bài Hát — дизайн-система «Đà Nẵng về đêm»: нефрит, свет фонарей Хойана, мост Дракона. */
:root {
  --jade-950: #041a14;
  --jade-900: #06241c;
  --jade-850: #082d23;
  --jade-800: #0a3529;
  --jade-700: #0f4a3a;
  --jade-600: #156049;
  --jade-500: #1f8a68;
  --jade-300: #5fd3a5;
  --jade-200: #9ee8c8;
  --lantern: #ff7a2f;
  --lantern-2: #ffb347;
  --gold: #ffd27a;
  --lacquer: #e8432e;
  --cream: #fff6e6;
  --cream-2: #fbe9cc;
  --ink: #0b1f1a;
  --ink-2: #3c5a50;
  --text: #f4efe3;
  --muted: #a9c3b8;
  --line: rgba(255, 246, 230, .12);
  --card: rgba(10, 53, 41, .72);
  --radius: 22px;
  --radius-sm: 14px;
  --shadow: 0 18px 50px rgba(0, 0, 0, .35);
  --glow: 0 0 28px rgba(255, 122, 47, .45);
  --font: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--jade-950);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
input, textarea, select { font: inherit; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ── фон: ночное небо с мягкими огнями ─────────────────────────────── */
.night {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(60vw 40vh at 85% -5%, rgba(255, 122, 47, .22), transparent 70%),
    radial-gradient(50vw 40vh at 0% 30%, rgba(95, 211, 165, .14), transparent 70%),
    radial-gradient(80vw 60vh at 50% 110%, rgba(31, 138, 104, .35), transparent 70%),
    linear-gradient(180deg, var(--jade-950), var(--jade-900) 40%, var(--jade-950));
}
.bokeh { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.bokeh i {
  position: absolute; border-radius: 50%; filter: blur(2px); opacity: .55;
  background: radial-gradient(circle, rgba(255, 179, 71, .9), rgba(255, 122, 47, 0) 70%);
  animation: float 14s ease-in-out infinite;
}
@keyframes float { 0%, 100% { transform: translateY(0) } 50% { transform: translateY(-24px) } }

/* ── шапка ─────────────────────────────────────────────────────────── */
.top {
  position: sticky; top: 0; z-index: 30;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  background: linear-gradient(180deg, rgba(4, 26, 20, .92), rgba(4, 26, 20, .7));
  border-bottom: 1px solid var(--line);
}
.top .wrap { display: flex; align-items: center; gap: 12px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; letter-spacing: -.01em; }
.brand svg { width: 38px; height: 38px; flex: none; }
.brand b { font-size: 1.12rem; }
.brand b span { color: var(--lantern-2); }
.top nav { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.top nav a {
  text-decoration: none; padding: 8px 12px; border-radius: 999px; font-weight: 600; font-size: .92rem; color: var(--muted);
}
.top nav a:hover, .top nav a.on { color: var(--text); background: rgba(255, 246, 230, .08); }
.brand b, .top nav a { white-space: nowrap; }
@media (max-width: 720px) { .top nav .hide-m { display: none; } }
@media (max-width: 480px) {
  .top nav a { padding: 8px 10px; font-size: .86rem; }
  .top.has-bar nav { display: none; }
  .brand svg { width: 32px; height: 32px; }
}

/* выбор языка: жёлтая «планета» справа в шапке */
.globe { position: relative; flex: none; margin-left: 4px; }
.globe-btn {
  display: inline-flex; align-items: center; gap: 4px; height: 42px; padding: 0 10px 0 7px; border-radius: 999px; cursor: pointer;
  border: 0; color: #2a1203; font-weight: 900; font-size: .78rem; letter-spacing: .04em;
  background: radial-gradient(circle at 35% 30%, #fff3b0, var(--gold) 45%, var(--lantern-2));
  box-shadow: 0 0 0 2px rgba(255, 210, 122, .35), 0 0 18px rgba(255, 179, 71, .55);
}
.globe-btn svg { width: 26px; height: 26px; }
.globe-btn:hover { filter: brightness(1.06); }
.globe-menu {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 80; min-width: 190px; padding: 6px; border-radius: 16px;
  background: var(--jade-850); border: 1px solid rgba(255, 210, 122, .35); box-shadow: var(--shadow); display: grid; gap: 2px;
}
.globe-menu button {
  display: flex; align-items: center; gap: 10px; padding: 11px 12px; border: 0; border-radius: 12px; background: none;
  color: var(--text); font-weight: 700; cursor: pointer; text-align: left;
}
.globe-menu button b { width: 30px; color: var(--gold); font-size: .8rem; }
.globe-menu button:hover { background: rgba(255, 246, 230, .08); }
.globe-menu button[aria-checked="true"] { background: rgba(255, 179, 71, .16); color: var(--gold); }
@media (max-width: 480px) { .top.has-bar .globe { margin-left: auto; } }
/* узкий телефон: логотип + «Bài hát của tôi» + планета должны влезть без горизонтальной прокрутки */
@media (max-width: 400px) {
  .top .wrap { gap: 8px; }
  .top nav { min-width: 0; }
  .top nav a { padding: 8px 6px; overflow: hidden; text-overflow: ellipsis; }
  .brand { gap: 8px; }
  .brand b { font-size: 1.02rem; }
  .globe { margin-left: 0; }
}

/* выбор способа оплаты */
.pay-tabs { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; padding: 5px; border-radius: 18px; background: rgba(255, 246, 230, .06); margin-bottom: 14px; }
.pay-tabs button { border: 0; border-radius: 14px; padding: 12px 8px; font-weight: 800; background: none; color: var(--muted); cursor: pointer; line-height: 1.2; }
.pay-tabs button.on { background: linear-gradient(180deg, var(--lantern-2), var(--lantern)); color: #2a1203; box-shadow: var(--glow); }
.have-songs { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }

.bar-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 8px; border-radius: 999px;
  background: rgba(95, 211, 165, .14); border: 1px solid rgba(95, 211, 165, .35); color: var(--jade-200);
  font-weight: 700; font-size: .85rem; white-space: nowrap; max-width: 52vw; overflow: hidden; text-overflow: ellipsis;
}
.bar-chip .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--jade-300); box-shadow: 0 0 10px var(--jade-300); flex: none; }

/* ── кнопки ────────────────────────────────────────────────────────── */
.btn {
  --b: var(--lantern);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 26px; border: 0; border-radius: 999px; cursor: pointer;
  font-weight: 800; font-size: 1.02rem; letter-spacing: .01em; text-decoration: none;
  color: #2a1203; background: linear-gradient(180deg, var(--lantern-2), var(--lantern));
  box-shadow: 0 10px 28px rgba(255, 122, 47, .35), inset 0 1px 0 rgba(255, 255, 255, .45);
  transition: transform .15s ease, box-shadow .2s ease, filter .2s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 14px 34px rgba(255, 122, 47, .5), inset 0 1px 0 rgba(255, 255, 255, .45); }
.btn:active { transform: translateY(1px); }
.btn:disabled { filter: grayscale(.7) brightness(.8); cursor: not-allowed; transform: none; }
.btn.big { min-height: 62px; font-size: 1.12rem; padding: 0 34px; }
.btn.block { width: 100%; }
.btn.ghost {
  color: var(--text); background: rgba(255, 246, 230, .06); border: 1px solid rgba(255, 246, 230, .22); box-shadow: none;
}
.btn.ghost:hover { background: rgba(255, 246, 230, .12); }
.btn.jade { color: #032018; background: linear-gradient(180deg, var(--jade-200), var(--jade-300)); box-shadow: 0 10px 28px rgba(95, 211, 165, .3); }
.btn.small { min-height: 40px; padding: 0 16px; font-size: .9rem; }
.btn svg { width: 22px; height: 22px; flex: none; }
.link { background: none; border: 0; color: var(--jade-200); text-decoration: underline; cursor: pointer; padding: 0; font-weight: 600; }

/* ── заголовки ─────────────────────────────────────────────────────── */
h1, h2, h3 { line-height: 1.12; letter-spacing: -.02em; margin: 0; }
h1 { font-size: clamp(2.1rem, 6.4vw, 4.2rem); font-weight: 900; }
h2 { font-size: clamp(1.7rem, 4.4vw, 2.7rem); font-weight: 900; }
h3 { font-size: 1.15rem; font-weight: 800; }
.glow-text {
  background: linear-gradient(90deg, var(--gold), var(--lantern-2) 40%, var(--lantern));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: .78rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--lantern-2);
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: currentColor; border-radius: 2px; }
.lead { font-size: clamp(1.02rem, 2.2vw, 1.2rem); color: var(--muted); max-width: 60ch; }
.sec { padding: clamp(56px, 9vw, 110px) 0; position: relative; }
.sec-h { display: grid; gap: 12px; margin-bottom: 34px; max-width: 760px; }
.sec-h.center { margin-inline: auto; text-align: center; justify-items: center; }

/* ── герой ─────────────────────────────────────────────────────────── */
.hero { position: relative; padding: 28px 0 0; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.02fr 1fr; gap: 40px; align-items: center; }
.hero h1 { margin: 14px 0 18px; }
.hero .cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0 16px; }
.hero .facts { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: .92rem; font-weight: 600; }
.hero .facts span { display: inline-flex; gap: 7px; align-items: center; }
.hero .facts svg { width: 18px; height: 18px; color: var(--jade-300); }
.hero-art {
  position: relative; border-radius: 30px; overflow: hidden; aspect-ratio: 16 / 11;
  box-shadow: var(--shadow), 0 0 0 1px rgba(255, 210, 122, .25);
  transform: rotate(1.2deg);
}
.hero-art img { width: 100%; height: 100%; object-fit: cover; }
.hero-art::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(4, 26, 20, .65));
}
.hero-art .now {
  position: absolute; left: 16px; right: 16px; bottom: 14px; z-index: 2;
  display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 16px;
  background: rgba(4, 26, 20, .88); border: 1px solid rgba(255, 246, 230, .16); color: var(--text);
  font-size: .9rem; line-height: 1.35;
}
.hero-art .now b { color: var(--gold); }
.eq { display: inline-flex; gap: 3px; align-items: flex-end; height: 18px; }
.eq i { width: 4px; background: var(--lantern-2); border-radius: 2px; animation: eq 1s ease-in-out infinite; }
.eq i:nth-child(2) { animation-delay: .2s } .eq i:nth-child(3) { animation-delay: .4s } .eq i:nth-child(4) { animation-delay: .1s }
@keyframes eq { 0%, 100% { height: 4px } 50% { height: 18px } }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 26px; }
  .hero-art { transform: none; aspect-ratio: 4 / 3; }
}
@media (max-width: 600px) {
  .hero-art { aspect-ratio: 4 / 5; }
  .hero-art img { object-position: center 30%; }
}

/* ── мост Дракона ──────────────────────────────────────────────────── */
.dragon-bridge { width: 100%; height: auto; display: block; }
.dragon-bridge .body-glow { filter: url(#db-glow); }
.dragon-bridge .runner { stroke-dasharray: 60 940; animation: run 6s linear infinite; }
@keyframes run { to { stroke-dashoffset: -1000; } }
.dragon-bridge .fire { transform-origin: center; animation: fire 1.4s ease-in-out infinite; }
@keyframes fire { 0%, 100% { opacity: .75; transform: scale(.94) } 50% { opacity: 1; transform: scale(1.08) } }
.dragon-bridge .ripple { animation: ripple 5s ease-in-out infinite; }
@keyframes ripple { 0%, 100% { transform: translateX(0) } 50% { transform: translateX(-12px) } }
.river-band { position: relative; margin-top: -10px; }

/* ── фонари ────────────────────────────────────────────────────────── */
.lanterns { position: absolute; top: 0; left: 0; right: 0; height: 140px; pointer-events: none; z-index: 1; }
.lanterns svg { width: 100%; height: 100%; }
.lanterns .lt { transform-box: fill-box; transform-origin: 50% 0; animation: swing 4.5s ease-in-out infinite; }
.lanterns .lt:nth-child(2n) { animation-duration: 5.4s; animation-delay: -1s; }
.lanterns .lt:nth-child(3n) { animation-duration: 6.1s; animation-delay: -2.2s; }
@keyframes swing { 0%, 100% { transform: rotate(-4deg) } 50% { transform: rotate(4deg) } }

/* ── звёзды: мерцающее небо и đèn ông sao ─────────────────────────── */
.sky { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.sky i { position: absolute; display: block; animation: twinkle 4s ease-in-out infinite; }
.sky i.dot { border-radius: 50%; background: #fff3d0; box-shadow: 0 0 6px #ffd27a; }
.sky i.spark {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-10 -10 20 20'%3E%3Cpath d='M0-10C1-2 2-1 10 0 2 1 1 2 0 10-1 2-2 1-10 0-2-1-1-2 0-10z'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-10 -10 20 20'%3E%3Cpath d='M0-10C1-2 2-1 10 0 2 1 1 2 0 10-1 2-2 1-10 0-2-1-1-2 0-10z'/%3E%3C/svg%3E") center/contain no-repeat;
  background: #ffe9b0; filter: drop-shadow(0 0 6px #ffd27a);
}
@keyframes twinkle { 0%, 100% { opacity: .15; transform: scale(.6) } 50% { opacity: 1; transform: scale(1) } }
.star-lantern { width: 100%; height: auto; overflow: visible; }
.star-hang { position: absolute; pointer-events: none; transform-origin: 50% 0; animation: swing 5s ease-in-out infinite; }
.star-hang:nth-of-type(2n) { animation-duration: 6.3s; animation-delay: -1.7s; }
.star-hang .star-lantern polygon { animation: glowpulse 3.2s ease-in-out infinite; }
@keyframes glowpulse { 0%, 100% { filter: brightness(1) } 50% { filter: brightness(1.25) } }

/* ── карточки ──────────────────────────────────────────────────────── */
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px;
  box-shadow: var(--shadow); backdrop-filter: blur(6px);
}
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.step { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--jade-850); border: 1px solid var(--line); }
.step img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.step .tx { padding: 18px 20px 22px; }
.step .num {
  position: absolute; top: 14px; left: 14px; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center;
  font-weight: 900; color: #2a1203; background: linear-gradient(180deg, var(--lantern-2), var(--lantern)); box-shadow: var(--glow);
}
.step p { color: var(--muted); margin: 6px 0 0; }
@media (max-width: 820px) { .steps { grid-template-columns: 1fr; } .step { display: grid; grid-template-columns: 120px 1fr; align-items: center; } .step img { height: 100%; } .step .num { width: 34px; height: 34px; top: 8px; left: 8px; } }

/* светлая секция (кремовая, как бумага фонаря) */
.paper { background: linear-gradient(180deg, var(--cream), var(--cream-2)); color: var(--ink); }
.paper .lead, .paper p { color: var(--ink-2); }
.paper .eyebrow { color: var(--lacquer); }
.wave-top, .wave-bot { display: block; width: 100%; height: 48px; }

.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.tile {
  position: relative; border-radius: 20px; overflow: hidden; cursor: pointer; border: 0; padding: 0; text-align: left;
  background: var(--jade-800); aspect-ratio: 1; box-shadow: 0 10px 26px rgba(4, 26, 20, .25);
  transition: transform .18s ease, box-shadow .2s ease;
}
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.tile:hover img { transform: scale(1.05); }
.tile:hover { transform: translateY(-2px); }
.tile .lb {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 12px 10px; color: #fff; font-weight: 800; font-size: .98rem;
  background: linear-gradient(180deg, transparent, rgba(4, 26, 20, .85));
}
.tile .lb small { display: block; font-weight: 600; font-size: .78rem; color: var(--cream-2); opacity: .9; }
.tile.on { box-shadow: 0 0 0 3px var(--lantern-2), 0 12px 30px rgba(255, 122, 47, .4); }
.tile.on::after {
  content: ""; position: absolute; top: 10px; right: 10px; width: 28px; height: 28px; border-radius: 50%;
  background: var(--lantern-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232a1203' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/16px no-repeat;
}

/* примеры песен */
.players { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.player {
  display: flex; gap: 14px; align-items: center; padding: 14px; border-radius: 18px; background: #fff; color: var(--ink);
  box-shadow: 0 8px 24px rgba(11, 31, 26, .08); border: 1px solid rgba(11, 31, 26, .06);
}
.player img { width: 64px; height: 64px; border-radius: 14px; object-fit: cover; flex: none; }
.player .meta { flex: 1; min-width: 0; }
.player b { display: block; font-size: .98rem; }
.player small { color: var(--ink-2); }
.play-btn {
  width: 48px; height: 48px; border-radius: 50%; border: 0; cursor: pointer; flex: none; display: grid; place-items: center;
  background: linear-gradient(180deg, var(--lantern-2), var(--lantern)); color: #2a1203; box-shadow: 0 6px 18px rgba(255, 122, 47, .35);
}
.play-btn svg { width: 20px; height: 20px; }
.prog { height: 5px; border-radius: 3px; background: rgba(11, 31, 26, .1); margin-top: 8px; overflow: hidden; }
.prog i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--jade-500), var(--lantern)); }

/* тарифы */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.plan { position: relative; padding: 26px 22px; border-radius: var(--radius); background: var(--jade-850); border: 1px solid var(--line); display: grid; gap: 10px; align-content: start; }
.plan.hot { background: linear-gradient(180deg, rgba(255, 122, 47, .16), var(--jade-850) 60%); border-color: rgba(255, 179, 71, .55); box-shadow: var(--glow); }
.plan .badge { position: absolute; top: -12px; left: 22px; padding: 4px 12px; border-radius: 999px; font-size: .75rem; font-weight: 800; color: #2a1203; background: var(--gold); }
.plan .price { font-size: 2rem; font-weight: 900; }
.plan .price small { font-size: .9rem; color: var(--muted); font-weight: 600; }
.plan ul { margin: 6px 0 12px; padding: 0; list-style: none; display: grid; gap: 8px; color: var(--muted); }
.plan li { display: flex; gap: 8px; align-items: flex-start; }
.plan li::before { content: ""; flex: none; width: 18px; height: 18px; margin-top: 3px; border-radius: 50%; background: rgba(95, 211, 165, .2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235fd3a5' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-9'/%3E%3C/svg%3E") center/12px no-repeat; }
@media (max-width: 860px) { .plans { grid-template-columns: 1fr; } }

/* вопросы */
.faq { display: grid; gap: 10px; max-width: 820px; }
.faq details { border-radius: 16px; background: #fff; border: 1px solid rgba(11, 31, 26, .08); padding: 0 18px; }
.faq summary { cursor: pointer; padding: 16px 0; font-weight: 800; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.4rem; line-height: 1; color: var(--lacquer); }
.faq details[open] summary::after { content: "–"; }
.faq p { margin: 0 0 16px; }

/* бары рядом */
.bars-list { display: grid; gap: 10px; }
.bar-row {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 18px; background: var(--card); border: 1px solid var(--line);
}
.bar-row .ic { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: rgba(255, 122, 47, .16); color: var(--lantern-2); flex: none; }
.bar-row .ic svg { width: 24px; height: 24px; }
.bar-row .meta { flex: 1; min-width: 0; }
.bar-row .meta b { display: block; }
.bar-row .meta small { color: var(--muted); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .76rem; font-weight: 800; }
.pill.live { color: #032018; background: var(--jade-300); }
.pill.off { color: var(--muted); background: rgba(255, 246, 230, .08); }
#map { height: 320px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); margin-bottom: 14px; background: var(--jade-850); }

/* подвал */
.foot { padding: 40px 0 120px; color: var(--muted); font-size: .9rem; border-top: 1px solid var(--line); }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 14px 28px; justify-content: space-between; }
.foot a { color: var(--muted); }

/* ── мастер создания песни (полноэкранный лист) ─────────────────────── */
.sheet {
  position: fixed; inset: 0; z-index: 60; display: none; flex-direction: column;
  background:
    radial-gradient(70vw 40vh at 100% 0%, rgba(255, 122, 47, .18), transparent 70%),
    linear-gradient(180deg, var(--jade-900), var(--jade-950));
}
.sheet.open { display: flex; animation: up .28s ease; }
@keyframes up { from { transform: translateY(24px); opacity: 0 } }
.sheet-top { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.sheet-top .x {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: rgba(255, 246, 230, .05); cursor: pointer;
  display: grid; place-items: center; flex: none;
}
.sheet-top .x svg { width: 20px; height: 20px; }
.sheet-top .ttl { font-weight: 800; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dots { display: flex; gap: 6px; flex: none; }
.dots i { width: 22px; height: 6px; border-radius: 3px; background: rgba(255, 246, 230, .15); }
@media (max-width: 420px) { .dots { gap: 3px; } .dots i { width: 8px; } }
/* планета в шапке мастера — компактная, только значок */
#wzGlobe { flex: none; }
.sheet-top .globe-btn { width: 42px; height: 42px; padding: 0; justify-content: center; }
.sheet-top .globe-code { display: none; }
@media (max-width: 420px) { .sheet-top { gap: 8px; padding: 10px 12px; } }
.dots i.on { background: var(--lantern-2); box-shadow: 0 0 10px rgba(255, 179, 71, .6); }
.sheet-body { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 22px 16px 120px; }
.sheet-body > .in { width: min(760px, 100%); margin-inline: auto; }
.sheet-foot {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 16px calc(14px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(4, 26, 20, 0), rgba(4, 26, 20, .96) 30%);
}
.sheet-foot .in { width: min(760px, 100%); margin-inline: auto; display: flex; gap: 10px; }
.q { font-size: clamp(1.5rem, 5vw, 2.1rem); font-weight: 900; margin: 0 0 6px; }
.q-sub { color: var(--muted); margin: 0 0 20px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 10px 16px; border-radius: 999px; border: 1px solid rgba(255, 246, 230, .2); background: rgba(255, 246, 230, .04);
  cursor: pointer; font-weight: 700;
}
.chip.on { background: rgba(255, 179, 71, .18); border-color: var(--lantern-2); color: var(--gold); }
.field { display: grid; gap: 8px; margin-bottom: 18px; }
.field label { font-weight: 800; font-size: .95rem; }
.field small { color: var(--muted); }
.inp {
  width: 100%; padding: 15px 16px; border-radius: 16px; border: 1px solid rgba(255, 246, 230, .2);
  background: rgba(4, 26, 20, .6); color: var(--text); font-size: 1.05rem; outline: none;
}
.inp:focus { border-color: var(--lantern-2); box-shadow: 0 0 0 4px rgba(255, 179, 71, .18); }
textarea.inp { min-height: 110px; resize: vertical; line-height: 1.6; }
.lyrics-box {
  white-space: pre-wrap; font-size: 1.06rem; line-height: 1.85; padding: 20px; border-radius: 20px;
  background: var(--cream); color: var(--ink); border: 1px solid rgba(255, 210, 122, .6);
  box-shadow: inset 0 0 0 6px rgba(255, 210, 122, .18);
}
.lyrics-box .tag { color: var(--lacquer); font-weight: 800; font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { .two { grid-template-columns: 1fr; } }
.err { color: #ffb4a6; font-weight: 700; min-height: 1.2em; margin: 10px 0 0; }
.note { color: var(--muted); font-size: .9rem; }

/* ожидание генерации */
.wait { text-align: center; padding: 10px 0 20px; }
.wait .lamp { width: 170px; margin: 0 auto 10px; }
.wait .lamp .lt { transform-box: fill-box; transform-origin: 50% 0; animation: swing 3s ease-in-out infinite; }
.bar-prog { height: 10px; border-radius: 6px; background: rgba(255, 246, 230, .1); overflow: hidden; margin: 18px auto 10px; max-width: 420px; }
.bar-prog i { display: block; height: 100%; width: 3%; border-radius: 6px; background: linear-gradient(90deg, var(--jade-300), var(--lantern-2), var(--lantern)); transition: width .8s ease; }
.fact { margin: 18px auto 0; max-width: 460px; padding: 14px 18px; border-radius: 16px; background: rgba(255, 246, 230, .06); border: 1px dashed rgba(255, 210, 122, .35); color: var(--cream-2); font-size: .95rem; }

/* большой плеер */
.bigplayer { display: grid; gap: 14px; padding: 18px; border-radius: 24px; background: linear-gradient(160deg, var(--jade-700), var(--jade-850)); border: 1px solid rgba(255, 210, 122, .25); }
.bigplayer .row { display: flex; align-items: center; gap: 14px; }
.bigplayer .cover { width: 78px; height: 78px; border-radius: 18px; overflow: hidden; flex: none; box-shadow: var(--glow); }
.bigplayer .cover img { width: 100%; height: 100%; object-fit: cover; }
.bigplayer .play-btn { width: 60px; height: 60px; }
.seek { height: 8px; border-radius: 5px; background: rgba(255, 246, 230, .14); cursor: pointer; overflow: hidden; }
.seek i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--jade-300), var(--lantern-2)); }
.times { display: flex; justify-content: space-between; color: var(--muted); font-size: .82rem; font-variant-numeric: tabular-nums; }

.pay-opts { display: grid; gap: 10px; }
.pay-opt { display: flex; gap: 14px; align-items: center; padding: 16px; border-radius: 18px; border: 1px solid var(--line); background: rgba(255, 246, 230, .04); cursor: pointer; text-align: left; width: 100%; }
.pay-opt.on { border-color: var(--lantern-2); background: rgba(255, 179, 71, .1); }
.pay-opt .meta { flex: 1; }
.pay-opt b { display: block; }
.pay-opt small { color: var(--muted); }
.pay-opt .pr { font-weight: 900; font-size: 1.1rem; white-space: nowrap; }

/* оплата: промокод у официанта и карта */
.pay-block { padding: 16px; border-radius: 20px; border: 1px solid var(--line); background: rgba(255, 246, 230, .04); margin-bottom: 14px; }
.pay-block > b { display: block; margin-bottom: 10px; font-size: 1.02rem; }
.promo-block { border-color: rgba(255, 210, 122, .45); background: linear-gradient(160deg, rgba(255, 179, 71, .12), rgba(10, 53, 41, .5)); }
.promo-form { display: flex; gap: 8px; }
.promo-form .inp { text-transform: uppercase; letter-spacing: .08em; font-weight: 800; min-width: 0; }
.promo-form .inp::placeholder { text-transform: none; letter-spacing: 0; font-weight: 500; }
.promo-form .btn { flex: none; }
.pay-logos { display: flex; flex-wrap: wrap; gap: 6px; margin: -2px 0 12px; }
.pay-logos span { padding: 4px 10px; border-radius: 8px; font-size: .78rem; font-weight: 800; background: var(--cream); color: var(--ink); }
.tokens-line { margin: 0; padding: 10px 14px; border-radius: 14px; background: rgba(95, 211, 165, .14); border: 1px solid rgba(95, 211, 165, .35); color: var(--jade-200); font-weight: 700; }
.tokens-line b { color: var(--gold); }
.promo-price { margin-top: -6px; font-weight: 700; color: var(--jade-200); font-size: .92rem; }
.promo-price b { color: var(--gold); }
.partner-cta { position: relative; overflow: hidden; }
.partner-cta .star-hang { right: 4%; top: -4px; width: clamp(60px, 12vw, 110px); }
@media (max-width: 560px) { .partner-cta .star-hang { opacity: .45; } }

.song-list { display: grid; gap: 10px; }
.song-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); }
.song-item .meta { flex: 1; min-width: 0; }
.song-item .meta b { display: block; }
.song-item .meta small { color: var(--muted); }
.song-item .acts { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 520px) {
  .song-item { flex-wrap: wrap; }
  .song-item .acts { width: 100%; flex-wrap: nowrap; }
  .song-item .acts .btn:first-child:not(:last-child) { flex: 1; }
}

/* статус в очереди */
.queue-card { text-align: center; padding: 26px 20px; border-radius: 26px; background: linear-gradient(180deg, rgba(95, 211, 165, .14), rgba(10, 53, 41, .7)); border: 1px solid rgba(95, 211, 165, .35); }
.queue-card .pos { font-size: 4.6rem; font-weight: 900; line-height: 1; color: var(--gold); text-shadow: var(--glow); }
.queue-card.live { background: linear-gradient(180deg, rgba(255, 122, 47, .22), rgba(10, 53, 41, .7)); border-color: rgba(255, 179, 71, .55); }

/* плавающая кнопка на телефоне */
.dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(4, 26, 20, 0), rgba(4, 26, 20, .95) 35%); display: none;
}
.dock .in { width: min(560px, 100%); margin-inline: auto; }
@media (max-width: 900px) { .dock { display: block; } }

.toast {
  position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%) translateY(20px); z-index: 90; opacity: 0; pointer-events: none;
  padding: 12px 18px; border-radius: 14px; background: var(--cream); color: var(--ink); font-weight: 700; box-shadow: var(--shadow);
  transition: all .25s ease; max-width: calc(100% - 32px);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.fade { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.fade.in { opacity: 1; transform: none; }

/* ── мастер как у Melody Market: карточки-варианты, вопросы по одному, сводка ── */
.opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.opts.one { grid-template-columns: 1fr; }
.opt {
  min-height: 74px; padding: 14px 16px; border-radius: 18px; border: 1px solid var(--line); cursor: pointer; text-align: left;
  color: var(--text); background: linear-gradient(160deg, rgba(255, 246, 230, .07), rgba(255, 246, 230, .02)); display: grid; gap: 4px; align-content: center;
}
.opt b { font-size: 1.05rem; }
.opt small { color: var(--muted); font-size: .85rem; }
.opt.on, .opt:active { border-color: var(--lantern-2); background: rgba(255, 179, 71, .14); box-shadow: 0 0 0 2px rgba(255, 179, 71, .35); }
.opt.mood-vui { --c: #ffd27a; } .opt.mood-lang-man { --c: #ff8fb1; } .opt.mood-xuc-dong { --c: #7cc4ff; } .opt.mood-hao-hung { --c: #ff7a2f; }
.opt.mood-chill { --c: #8fe3c6; } .opt.mood-buon { --c: #9aa7ff; } .opt.mood-hai-huoc { --c: #c8f545; } .opt.mood-truyen-cam-hung { --c: #ffb347; }
.opt[class*="mood-"] { border-left: 4px solid var(--c); }
.qhead { display: flex; justify-content: space-between; align-items: center; gap: 10px; color: var(--muted); font-size: .88rem; margin-bottom: 10px; }
.qbar { height: 6px; border-radius: 4px; background: rgba(255, 246, 230, .1); overflow: hidden; margin-bottom: 18px; }
.qbar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--lantern)); transition: width .3s ease; }
.sum { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.sum li { display: grid; grid-template-columns: minmax(96px, 34%) 1fr; gap: 10px; padding: 10px 14px; border-radius: 14px; background: rgba(255, 246, 230, .05); }
.sum li span { color: var(--muted); font-size: .88rem; }
.sum li b { font-weight: 600; overflow-wrap: anywhere; }
.typing::after { content: "▍"; color: var(--lantern-2); animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.link-btn { background: none; border: 0; color: var(--gold); text-decoration: underline; cursor: pointer; font: inherit; padding: 6px 0; }

/* ── ожидание: кольцо с процентами (как у Ральфа) ── */
.rk { position: relative; display: inline-block; flex: none; line-height: 0; }
.rk svg { display: block; width: 100%; height: 100%; transform: rotate(-90deg); }
.rk .rk-t { fill: none; stroke: rgba(255, 246, 230, .12); }
.rk .rk-a { fill: none; stroke: url(#tbhRingGrad); stroke-linecap: round; transition: stroke-dashoffset .5s ease; }
.rk .rk-n { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-weight: 900; color: var(--text); font-variant-numeric: tabular-nums; line-height: 1; }
.rk .rk-ok { position: absolute; inset: 0; display: none; transform: none; }
.rk.done > svg:first-child, .rk.done .rk-n { display: none; }
.rk.done .rk-ok { display: block; animation: rk-pop .35s ease-out; }
.rk.wait .rk-a { stroke-dasharray: 18 82 !important; stroke-dashoffset: 0 !important; animation: rk-spin 1.6s linear infinite; transform-origin: 50% 50%; }
@keyframes rk-spin { to { transform: rotate(360deg); } }
@keyframes rk-pop { 0% { transform: scale(.6); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.ring-box { display: grid; justify-items: center; gap: 12px; text-align: center; padding: 8px 0 4px; }
.ring-box .lead-msg { min-height: 1.5em; color: var(--cream-2); }

/* ── игры, пока ждём ── */
.games-wrap { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.games-head { display: grid; gap: 2px; margin-bottom: 12px; }
.games-head small { color: var(--muted); }
.games { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.game-tile {
  display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 16px; cursor: pointer; text-align: left; color: var(--text);
  border: 1px solid rgba(255, 210, 122, .25); background: linear-gradient(160deg, rgba(255, 122, 47, .16), rgba(255, 246, 230, .03));
}
.game-tile svg { width: 40px; height: 40px; flex: none; color: var(--lantern-2); }
.game-tile span { display: grid; gap: 2px; min-width: 0; }
.game-tile b { font-size: .95rem; }
.game-tile small { color: var(--muted); font-size: .78rem; }
.game-ov { position: fixed; inset: 0; z-index: 200; display: flex; flex-direction: column; background: #0C0B10; }
.game-ov[hidden] { display: none; }
.game-top { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px solid var(--line); background: var(--jade-950); }
.game-top .x { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: rgba(255, 246, 230, .05); color: var(--text); display: grid; place-items: center; cursor: pointer; flex: none; }
.game-top .x svg { width: 20px; height: 20px; }
.game-ttl { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.game-ready { animation: rk-pop .35s ease-out; }
.game-frame { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; }
.game-frame canvas { display: block; }
body.game-open { overflow: hidden; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .fade { opacity: 1; transform: none; }
}
