/* INA Music — ธีม Spotify (มืด + เขียว) สำหรับมือถือ PWA */
:root {
  --bg: #121212;
  --surface: #1f1f1f;
  --surface-2: #2a2a2a;
  --line: #ffffff14;
  --text: #ffffff;
  --muted: #b3b3b3;
  --accent: #1db954;
  --accent-press: #1ed760;
  --bar-h: 62px;
  --nav-h: 58px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", "Noto Sans Thai UI", "Noto Sans Thai", Tahoma, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  min-height: 100vh;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior-y: none;
  user-select: none;
}
input, .track-list .t, .track-list .a, .bar-title, .bar-artist { user-select: text; }

button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
ul { list-style: none; margin: 0; padding: 0; }
img { display: block; }
.hidden { display: none !important; }

/* ---------- Views ---------- */
.view {
  padding: calc(14px + env(safe-area-inset-top)) 16px calc(var(--bar-h) + var(--nav-h) + 34px + env(safe-area-inset-bottom));
}
.view-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.view-head h1 { font-size: 24px; margin: 0; font-weight: 800; flex: 1; }
.wave { display: inline-block; }

.section { margin-bottom: 26px; }
.section h2 { font-size: 19px; margin: 0 0 12px; font-weight: 800; }
.see-all { color: var(--muted); font-size: 13.5px; margin-top: 10px; padding: 6px 0; }

/* ---------- Login / chip ---------- */
.login-btn {
  padding: 8px 16px; border-radius: 999px; background: var(--accent);
  color: #000; font-weight: 700; font-size: 14px; flex-shrink: 0;
}
.user-chip {
  padding: 7px 13px; border-radius: 999px; background: var(--surface-2);
  border: 1px solid var(--line); color: var(--text); font-size: 13px;
  max-width: 140px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex-shrink: 0;
}

/* ---------- Recent grid (หน้าแรก) ---------- */
.recent-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.recent-item {
  display: flex; align-items: center; gap: 10px; background: var(--surface);
  border-radius: 6px; overflow: hidden; cursor: pointer; text-align: left;
}
.recent-item:active { background: var(--surface-2); }
.recent-item img { width: 52px; height: 52px; object-fit: cover; background: var(--surface-2); }
.recent-item .t {
  font-size: 13.5px; font-weight: 600; padding: 8px 10px 8px 0; line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* ---------- Artist page ---------- */
.artist-name-link {
  color: inherit; font: inherit; text-align: left;
  max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.artist-name-link:active { text-decoration: underline; }
.np-artist-link {
  color: var(--muted); font: inherit; font-size: 14.5px; text-align: left;
  max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  cursor: pointer;
}
.np-artist-link:active { color: var(--text); text-decoration: underline; }

#viewArtist { padding-left: 0; padding-right: 0; }
#viewArtist .artist-topbar {
  position: sticky; top: 0; z-index: 5;
  padding: calc(6px + env(safe-area-inset-top)) 8px 6px 16px;
  background: linear-gradient(180deg, #0b0b0bd9, #0b0b0b00);
  display: flex; align-items: center;
}
#viewArtist.scrolled .artist-topbar { background: #0b0b0b; }
.artist-hero { position: relative; margin-top: -46px; }
.artist-hero img {
  width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--surface-2);
}
.artist-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, #00000026 40%, #121212e6 96%);
}
.artist-hero-text {
  position: absolute; left: 18px; right: 18px; bottom: 14px;
}
.artist-label { font-size: 12.5px; color: var(--text); }
.artist-hero-text h1 {
  margin: 4px 0 0; font-size: clamp(26px, 8vw, 40px); font-weight: 800; line-height: 1.1;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .5);
}
.artist-actions {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px 4px;
}
.artist-play {
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--accent); color: #000;
  display: grid; place-items: center;
  box-shadow: 0 6px 18px -6px rgba(29, 185, 84, .7);
}
.artist-play svg { width: 27px; height: 27px; }
.artist-play:active { transform: scale(.94); background: var(--accent-press); }
.artist-shuffle {
  width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center; color: var(--muted);
}
.artist-shuffle svg { width: 24px; height: 24px; }
.artist-shuffle.active { color: var(--accent); }
#viewArtist .track-list { padding: 8px 16px 0; }

/* ---------- Playlist grid ---------- */
.pl-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
}
.pl-card { text-align: left; }
.pl-cover {
  width: 100%; aspect-ratio: 1; border-radius: 8px; overflow: hidden;
  background: var(--surface-2); position: relative;
  display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr;
  box-shadow: 0 6px 20px -8px rgba(0, 0, 0, .6);
}
.pl-cover img { width: 100%; height: 100%; object-fit: cover; }
.pl-cover.single img { grid-column: 1 / -1; grid-row: 1 / -1; }
.pl-cover.empty {
  display: grid; place-items: center; color: var(--muted); font-size: 34px;
}
.pl-card .pl-name {
  margin-top: 8px; font-weight: 600; font-size: 14px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pl-card .pl-count { color: var(--muted); font-size: 12px; }
.pl-card:active .pl-cover { opacity: .85; }

.pl-hero-cover {
  width: 100%; aspect-ratio: 1; position: relative;
  display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr;
  background: var(--surface-2);
}
.pl-hero-cover img { width: 100%; height: 100%; object-fit: cover; }
.pl-hero-cover.single img { grid-column: 1 / -1; grid-row: 1 / -1; }
.pl-hero-cover.empty { display: grid; place-items: center; color: var(--muted); font-size: 60px; }

.new-pl { background: transparent; border: 1px dashed #ffffff45; color: var(--text); }

/* ---------- Track menu (⋮) ---------- */
.menu-modal { padding-bottom: 18px; }
.menu-song { display: flex; align-items: center; gap: 12px; margin: 8px 0 14px; }
.menu-song img { width: 48px; height: 48px; border-radius: 4px; object-fit: cover; background: var(--surface-2); }
.menu-song-meta { min-width: 0; }
.menu-song .t { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.menu-song .a { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.menu-actions { display: flex; flex-direction: column; }
.menu-actions button {
  text-align: left; padding: 13px 6px; font-size: 15px; font-weight: 500;
  border-bottom: 1px solid var(--line); color: var(--text);
}
.menu-actions button:last-child { border-bottom: 0; }
.menu-actions button:active { opacity: .6; }
#menuPlPanel { margin-top: 4px; }
#menuPlPanel h4 {
  margin: 14px 0 6px; font-size: 12.5px; color: var(--muted); letter-spacing: 1px; text-transform: uppercase;
}
.pl-quick-create { display: flex; gap: 8px; margin: 10px 0 8px; }
.pl-quick-create input {
  flex: 1; padding: 11px 13px; border-radius: 6px; background: #3e3e3e;
  border: 0; color: var(--text); font-size: 14px; outline: none;
}
.pl-quick-create button {
  padding: 0 16px; border-radius: 6px; background: var(--accent); color: #000; font-weight: 700;
}
.menu-pl-list { max-height: 220px; overflow-y: auto; }
.menu-pl-list button {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 9px 4px; font-size: 14.5px; color: var(--text);
}
.menu-pl-list button:active { opacity: .6; }
.menu-pl-list .pl-thumb {
  width: 40px; height: 40px; border-radius: 4px; background: var(--surface-2);
  display: grid; place-items: center; font-size: 16px; overflow: hidden; flex-shrink: 0;
}
.menu-pl-list .pl-thumb img { width: 100%; height: 100%; object-fit: cover; }
.menu-pl-list .meta { flex: 1; min-width: 0; }
.menu-pl-list .meta .t { font-weight: 600; }
.menu-pl-list .meta .a { color: var(--muted); font-size: 12px; }
.topbar-actions { margin-left: auto; display: flex; gap: 2px; }

/* ---------- Chips (คลังเพลง) ---------- */
.chips { display: flex; gap: 8px; margin-bottom: 14px; }
.chip {
  padding: 7px 14px; border-radius: 999px; background: var(--surface);
  color: var(--text); font-size: 13.5px; font-weight: 600;
}
.chip.active { background: var(--accent); color: #000; }

/* ---------- Search ---------- */
.search-head { padding-bottom: 2px; }
.search-form {
  display: flex; align-items: center; gap: 9px; width: 100%;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 8px; padding: 11px 14px;
}
.search-form svg { width: 19px; height: 19px; color: var(--muted); flex-shrink: 0; }
.search-form input {
  flex: 1; min-width: 0; background: none; border: 0; outline: 0;
  color: var(--text); font-size: 15.5px; -webkit-appearance: none; appearance: none;
}
.search-form input::placeholder { color: var(--muted); }
.search-form input::-webkit-search-cancel-button { -webkit-appearance: none; }
.search-hint { color: var(--muted); text-align: center; padding: 40px 20px; font-size: 14.5px; }

/* ---------- Track list ---------- */
.track-list li {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 6px; border-radius: 8px; cursor: pointer;
}
.track-list li:active { background: var(--surface); }
.track-list .art {
  width: 50px; height: 50px; border-radius: 4px; object-fit: cover;
  background: var(--surface-2); flex-shrink: 0;
}
.track-list .meta { flex: 1; min-width: 0; }
.track-list .t { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track-list .a { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track-list .d { color: var(--muted); font-size: 12.5px; flex-shrink: 0; }
.track-list li.current .t { color: var(--accent); }
.track-list li.playing .t::after { content: " ♪"; }
.track-list .add-btn, .track-list .rm-btn {
  width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center; color: var(--muted);
}
.track-list .add-btn svg { width: 20px; height: 20px; }
.track-list .rm-btn { font-size: 15px; }
.track-list .heart-mini { width: 30px; height: 30px; display: grid; place-items: center; color: var(--muted); flex-shrink: 0; }
.track-list .heart-mini.liked { color: var(--accent); }
.track-list .more-btn {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center; color: var(--muted); font-size: 17px; font-weight: 700;
}
.track-list .more-btn:active { background: var(--surface-2); }
.loading { color: var(--muted); padding: 14px 6px; text-align: center; }

/* ---------- Drag & drop จัดลำดับเพลงในเพลย์ลิสต์ ---------- */
.track-list li { position: relative; transition: transform .18s ease; -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
.drag-handle {
  position: absolute; left: -7px; top: 0; bottom: 0; width: 24px;
  display: grid; place-items: center; color: #ffffff40;
  touch-action: none; cursor: grab; z-index: 2;
}
.drag-handle svg { width: 17px; height: 17px; }
.drag-handle:active { color: #ffffff85; }
.track-list li.dragging {
  z-index: 6; background: var(--surface-2);
  box-shadow: 0 12px 30px -8px rgba(0, 0, 0, .9);
  transition: none; cursor: grabbing;
}
body.dragging-row { user-select: none; cursor: grabbing; }
body.dragging-row * { cursor: grabbing !important; }

/* ---------- Bottom nav ---------- */
.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 35;
  height: calc(var(--nav-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  display: flex; background: linear-gradient(180deg, #00000000, #000 40%);
}
.bottom-nav button {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; color: var(--muted); font-size: 10.5px; padding-top: 8px;
}
.bottom-nav button svg { width: 23px; height: 23px; }
.bottom-nav button.active { color: var(--text); }

/* ---------- Mini player ---------- */
.player-bar {
  position: fixed; left: 8px; right: 8px;
  bottom: calc(var(--nav-h) + 6px + env(safe-area-inset-bottom));
  z-index: 40; height: var(--bar-h);
  display: none; align-items: center; gap: 8px; padding: 0 6px 0 8px;
  background: var(--surface-2); border-radius: 10px;
  box-shadow: 0 8px 28px -6px rgba(0, 0, 0, .8);
  cursor: pointer; overflow: hidden;
}
.player-bar.visible { display: flex; }
.player-bar::before {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2.5px;
  width: var(--prog, 0%); background: var(--text); opacity: .85;
  transition: width .3s linear;
}
.player-bar img { width: 44px; height: 44px; border-radius: 6px; object-fit: cover; background: var(--surface); }
.bar-meta { flex: 1; min-width: 0; }
.bar-title { font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-artist { color: var(--muted); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.heart-btn { width: 36px; height: 36px; display: grid; place-items: center; color: var(--muted); flex-shrink: 0; }
.heart-btn svg { width: 21px; height: 21px; }
.heart-btn.liked { color: var(--accent); }
.heart-btn.liked svg { fill: var(--accent); }
.heart-btn.big { width: 42px; height: 42px; }
.heart-btn.big svg { width: 26px; height: 26px; }

.ctrl-btn {
  width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center; color: var(--text); flex-shrink: 0; position: relative;
}
.ctrl-btn svg { width: 22px; height: 22px; }
.ctrl-btn.big { width: 58px; height: 58px; background: #fff; color: #000; border-radius: 50%; }
.ctrl-btn.big svg { width: 28px; height: 28px; }
.ctrl-btn.big:active { transform: scale(.94); }
.ctrl-btn.small { color: var(--muted); }
.ctrl-btn.small.active { color: var(--accent); }
.ctrl-btn.small.active::after {
  content: ""; position: absolute; bottom: 5px; left: 50%; transform: translateX(-50%);
  width: 4px; height: 4px; border-radius: 50%; background: var(--accent);
}
.icon-btn { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: var(--text); }
.icon-btn svg { width: 22px; height: 22px; }

/* ---------- Now Playing (เต็มจอ) ---------- */
.backdrop { position: fixed; inset: 0; z-index: 45; background: rgba(0, 0, 0, .55); }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  height: 100vh; height: 100dvh;
  background: var(--bg); border-radius: 14px 14px 0 0;
  transform: translateY(105%); transition: transform .34s cubic-bezier(.32, .72, .24, 1);
  overflow: hidden;
}
.sheet.open { transform: translateY(0); }
.sheet-bg { position: absolute; inset: 0; z-index: 0; }
.sheet-bg img { width: 100%; height: 55%; object-fit: cover; filter: blur(48px) saturate(1.3) brightness(.55); transform: scale(1.3); }
.sheet-bg-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, #24242466 0%, var(--bg) 62%); }
.sheet-inner { position: relative; z-index: 1; height: 100%; display: flex; flex-direction: column; }
.sheet-grab { display: flex; justify-content: center; padding: 8px 0 2px; cursor: grab; }
.grab-bar { width: 38px; height: 4px; border-radius: 2px; background: #ffffff59; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 2px 10px; }
.sheet-context { color: var(--muted); font-size: 11.5px; letter-spacing: 1.5px; font-weight: 600; }
.sheet-scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; }

.np-main { padding: 4vh 22px calc(20px + env(safe-area-inset-bottom)); max-width: 520px; margin: 0 auto; }
#npArt {
  width: min(86vw, 340px); aspect-ratio: 1; object-fit: cover; border-radius: 8px;
  background: var(--surface-2); margin: 0 auto 22px;
  box-shadow: 0 20px 60px -18px rgba(0, 0, 0, .9);
}
.np-row { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.np-info { flex: 1; min-width: 0; }
.np-title { font-size: 21px; font-weight: 800; line-height: 1.25; }
.np-artist { color: var(--muted); font-size: 14.5px; margin-top: 2px; }

/* ---------- Range (seek + volume) ---------- */
.range {
  width: 100%; height: 26px; margin: 0;
  -webkit-appearance: none; appearance: none; background: none; display: block;
}
.range::-webkit-slider-runnable-track {
  height: 4px; border-radius: 2px;
  background: linear-gradient(to right, var(--fill-color, #fff) var(--fill, 0%), #ffffff38 var(--fill, 0%));
}
.range::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 13px; height: 13px; border-radius: 50%; margin-top: -4.5px;
  background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .6);
  opacity: 0; transition: opacity .15s;
}
.range:hover::-webkit-slider-thumb, .range:active::-webkit-slider-thumb { opacity: 1; }
.range::-moz-range-track { height: 4px; border-radius: 2px; background: #ffffff38; }
.range::-moz-range-progress { height: 4px; border-radius: 2px; background: var(--fill-color, #fff); }
.range::-moz-range-thumb { width: 13px; height: 13px; border: 0; border-radius: 50%; background: #fff; }
.range:disabled { opacity: .35; }
#seek { --fill-color: #fff; }
#seek:active::-webkit-slider-runnable-track { --fill-color: var(--accent); }

.times { display: flex; justify-content: space-between; color: var(--muted); font-size: 11.5px; margin-top: -4px; }

/* ---------- Controls ---------- */
.controls {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 0 8px;
}
.controls .ctrl-btn.big { margin: 0 auto; }
.repeat-one { position: absolute; font-size: 9px; font-weight: 800; transform: translate(14px, -12px); color: var(--accent); }

/* ---------- แถวล่างของหน้าเล่น: devices / volume / queue ---------- */
.np-foot { display: flex; align-items: center; gap: 6px; margin-top: 8px; }
.vol-wrap { flex: 1; display: flex; align-items: center; gap: 2px; padding: 0 4px; }
.vol-wrap .range { height: 22px; }
.vol-wrap .range::-webkit-slider-thumb { width: 11px; height: 11px; margin-top: -3.5px; opacity: 1; background: var(--text); }
.vol-wrap .range::-webkit-slider-runnable-track { --fill-color: var(--text); height: 3px; }

/* ---------- Lyrics panel ---------- */
.sheet-head-actions { display: flex; }
.lyrics-panel { padding: 4px 22px calc(20px + env(safe-area-inset-bottom)); max-width: 520px; margin: 0 auto; }
.lyrics-head { display: flex; align-items: baseline; gap: 10px; margin: 10px 0 4px; }
.lyrics-head h3 { margin: 0; font-size: 16px; font-weight: 800; }
.lyrics-status { color: var(--muted); font-size: 12px; }
.lyrics-box { padding: 30px 0 45vh; scroll-behavior: smooth; }
.lyrics-line {
  padding: 9px 4px; font-size: 21px; font-weight: 700; line-height: 1.35;
  color: #ffffff40; border-radius: 8px; cursor: pointer;
  transition: color .25s, transform .25s;
  transform-origin: left center;
}
.lyrics-line:active { background: #ffffff10; }
.lyrics-line.current { color: #fff; transform: scale(1.03); }
.lyrics-line.past { color: #ffffff2e; }
.lyrics-plain { white-space: pre-wrap; color: #d8d8d8; font-size: 16.5px; line-height: 1.9; padding: 10px 2px 40vh; }
.lyrics-empty { color: var(--muted); padding: 30px 0; text-align: center; }
.lyrics-hint { color: var(--muted); padding: 30px 0; text-align: center; }

/* ---------- Queue panel ---------- */
.queue-panel { padding: 4px 22px calc(20px + env(safe-area-inset-bottom)); max-width: 520px; margin: 0 auto; }
.queue-head { display: flex; align-items: center; justify-content: space-between; margin: 10px 0 4px; }
.queue-head h3 { margin: 0; font-size: 16px; font-weight: 800; }
.queue-head span { color: var(--muted); font-weight: 400; }
.text-btn { color: var(--muted); font-size: 13.5px; padding: 6px 4px; }
.queue-label { color: var(--muted); font-size: 12px; letter-spacing: 1px; margin: 12px 0 2px; font-weight: 700; }

/* ---------- Modal (บัญชี) ---------- */
.modal {
  position: fixed; z-index: 50; left: 50%; bottom: 0;
  width: min(100%, 430px); transform: translate(-50%, 105%);
  background: #282828; border-radius: 14px 14px 0 0;
  padding: 18px 20px calc(24px + env(safe-area-inset-bottom));
  transition: transform .3s cubic-bezier(.32, .72, .24, 1);
}
.modal.open { transform: translate(-50%, 0); }
.modal-close { position: absolute; top: 10px; right: 10px; }
.modal h2 { margin: 4px 0 14px; font-size: 19px; }
.tabs { display: flex; gap: 6px; background: #1f1f1f; padding: 4px; border-radius: 999px; margin-bottom: 16px; }
.tab { flex: 1; padding: 9px 0; border-radius: 999px; color: var(--muted); font-weight: 600; font-size: 14px; }
.tab.active { background: #fff; color: #000; }
.modal label { display: block; font-size: 13px; color: var(--muted); margin: 12px 0 5px; }
.modal input {
  width: 100%; padding: 12px 14px; border-radius: 6px;
  background: #3e3e3e; border: 1px solid transparent; color: var(--text);
  font-size: 15px; outline: none;
}
.modal input:focus { border-color: #fff; }
.form-error { color: #f87171; font-size: 13px; margin: 10px 0 0; }
.submit-btn {
  width: 100%; margin-top: 18px; padding: 13px 0; border-radius: 999px;
  background: var(--accent); color: #000; font-weight: 800; font-size: 15px;
}
.auth-note { color: var(--muted); font-size: 12.5px; margin: 14px 0 0; text-align: center; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; z-index: 60; left: 50%; bottom: calc(var(--bar-h) + var(--nav-h) + 22px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  background: var(--accent); color: #000;
  padding: 10px 18px; border-radius: 999px; font-size: 14px; font-weight: 600;
  box-shadow: 0 8px 30px rgba(0, 0, 0, .5);
  max-width: 88vw; text-align: center;
}

/* ---------- Desktop ---------- */
@media (min-width: 760px) {
  .view { max-width: 820px; margin: 0 auto; }
  .player-bar { left: 50%; right: auto; width: min(560px, 92vw); transform: translateX(-50%); }
  .sheet, .modal { left: 50%; right: auto; width: min(100%, 480px); transform: translate(-50%, 105%); }
  .sheet.open, .modal.open { transform: translate(-50%, 0); }
}
