:root {
  --bg: #15111E;
  --surface: #201A2D;
  --surface-2: #2B2440;
  --line: #3A3150;
  --text: #F7F3EC;
  --muted: #BDB4CC;
  --soft: #E3DCEC;
  --violet: #8F7CFF;
  --peach: #FFB38A;
  --lime: #D6F36B;
  --danger: #FF8A8A;
  --radius: 20px;
  --head: 'Bricolage Grotesque', 'DM Sans', system-ui, sans-serif;
  --body: 'DM Sans', Inter, system-ui, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.45 var(--body); -webkit-font-smoothing: antialiased; }
body { min-height: 100vh; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
img { display: block; }
:focus-visible { outline: 3px solid var(--lime); outline-offset: 2px; border-radius: 10px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.boot { display: grid; place-items: center; min-height: 100vh; color: var(--muted); }
h1, h2, h3 { font-family: var(--head); font-weight: 800; margin: 0; letter-spacing: -0.01em; }
.muted { color: var(--muted); }

/* ---------- buttons and chips */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 2px solid transparent; font-weight: 700; font-size: 15px; background: var(--surface-2); color: var(--text); white-space: nowrap; transition: transform .12s ease, background .12s ease; }
.btn:hover { background: var(--line); }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--lime); color: var(--bg); }
.btn.primary:hover { background: #E3FA8F; }
.btn.violet { background: var(--violet); color: var(--bg); }
.btn.ghost { background: transparent; border-color: var(--line); }
.btn.small { min-height: 36px; padding: 0 14px; font-size: 14px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }
.icon-btn { width: 44px; height: 44px; flex: none; display: inline-grid; place-items: center; border-radius: 50%; border: 0; background: var(--surface-2); color: var(--text); }
.icon-btn:hover { background: var(--line); }
.icon-btn.lime { background: var(--lime); color: var(--bg); }
.icon-btn svg { width: 20px; height: 20px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { min-height: 40px; padding: 0 16px; border-radius: 999px; border: 2px solid var(--line); background: transparent; color: var(--soft); font-weight: 600; font-size: 14px; }
.chip[aria-pressed="true"] { background: var(--lime); border-color: var(--lime); color: var(--bg); }
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; border-radius: 999px; padding: 4px 10px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.badge.have { background: rgba(214, 243, 107, .14); color: var(--lime); }
.badge.new { background: var(--peach); color: var(--bg); }

/* ---------- top bar */
.topbar { position: sticky; top: 0; z-index: 20; background: rgba(21, 17, 30, .86); backdrop-filter: blur(14px); border-bottom: 1px solid var(--surface-2); }
.topbar-in { max-width: 1280px; margin: 0 auto; padding: 10px 20px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.brand { font-family: var(--head); font-weight: 800; font-size: 20px; display: flex; align-items: center; gap: 10px; }
.brand-dots { display: flex; }
.brand-dots span { width: 18px; height: 18px; border-radius: 50%; margin-left: -7px; }
.brand-dots span:first-child { margin-left: 0; }
.nav { display: flex; gap: 4px; }
.nav a, .nav span { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border-radius: 999px; font-weight: 600; color: var(--soft); font-size: 15px; }
.nav a[aria-current="page"] { background: var(--surface); color: var(--text); }
.nav span { color: #7E7592; cursor: default; }
.searchbox { flex: 1 1 280px; position: relative; min-width: 0; }
.searchbox input { width: 100%; min-height: 44px; border-radius: 999px; border: 2px solid var(--line); background: var(--surface); padding: 0 18px 0 44px; font-size: 15px; }
.searchbox input:focus { border-color: var(--violet); outline: none; }
.searchbox svg { position: absolute; left: 15px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: var(--muted); }
.me { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--violet); color: var(--bg); display: grid; place-items: center; font: 800 16px var(--head); }
.link-btn { background: none; border: 0; color: var(--soft); font-weight: 600; min-height: 44px; padding: 0 8px; }

/* ---------- page */
.page { max-width: 1280px; margin: 0 auto; padding: 24px 20px 140px; display: flex; flex-direction: column; gap: 32px; }
.hero-hi { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.hero-hi h1 { font-size: clamp(32px, 5vw, 52px); line-height: 1.02; }
.hero-hi p { margin: 8px 0 0; color: var(--muted); max-width: 560px; }

/* ---------- rows and cards */
.section { display: flex; flex-direction: column; gap: 14px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.section-head h2 { font-size: 24px; }
.row-arrows { display: flex; gap: 6px; }
.row { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 180px); gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 10px; scrollbar-width: none; }
.row::-webkit-scrollbar { display: none; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 18px; }
.card { position: relative; scroll-snap-align: start; display: flex; flex-direction: column; gap: 8px; padding: 10px; border-radius: var(--radius); transition: background .15s ease; min-width: 0; }
.card:hover { background: var(--surface); }
.card .art { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: var(--surface-2); box-shadow: 0 10px 30px rgba(0, 0, 0, .35); }
.card.round .art { border-radius: 50%; }
.card .art img { width: 100%; height: 100%; object-fit: cover; }
.card .t { font-weight: 700; font-size: 15px; line-height: 1.25; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.card .s { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card.round .t, .card.round .s { text-align: center; }
.card .actions { position: absolute; right: 18px; top: calc(10px + (100% - 80px) - 60px); display: flex; gap: 6px; opacity: 0; transform: translateY(6px); transition: .15s ease; }
.card .art-actions { position: absolute; right: 8px; bottom: 8px; display: flex; gap: 6px; opacity: 0; transform: translateY(6px); transition: .15s ease; }
.card:hover .art-actions, .card:focus-within .art-actions { opacity: 1; transform: none; }
@media (hover: none) { .card .art-actions { opacity: 1; transform: none; } }
.card .corner { position: absolute; left: 8px; top: 8px; }
.card .pick { position: absolute; left: 8px; top: 8px; width: 26px; height: 26px; accent-color: var(--lime); }
.ph { width: 100%; height: 100%; display: grid; place-items: center; font: 800 40px var(--head); color: var(--violet); background: linear-gradient(135deg, var(--surface-2), var(--surface)); }
.skel { background: linear-gradient(90deg, var(--surface) 0%, var(--surface-2) 50%, var(--surface) 100%); background-size: 200% 100%; animation: shimmer 1.3s infinite linear; border-radius: 14px; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- track list */
.tracks { display: flex; flex-direction: column; }
.track { display: grid; grid-template-columns: 32px 44px 1fr auto auto; align-items: center; gap: 12px; padding: 6px 10px; border-radius: 14px; min-height: 60px; }
.track:hover { background: var(--surface); }
.track .num { color: var(--muted); font-size: 14px; text-align: right; font-variant-numeric: tabular-nums; }
.track .thumb { width: 44px; height: 44px; border-radius: 8px; overflow: hidden; background: var(--surface-2); }
.track .thumb img { width: 100%; height: 100%; object-fit: cover; }
.track .meta { min-width: 0; }
.track .name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track .by { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track .dur { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.track .ctl { display: flex; gap: 6px; align-items: center; }
.track input[type=checkbox] { width: 20px; height: 20px; accent-color: var(--lime); }
.track.playing .name { color: var(--lime); }
@media (max-width: 640px) { .track { grid-template-columns: 24px 44px 1fr auto; } .track .dur { display: none; } }

/* ---------- detail headers */
.detail { position: relative; border-radius: 32px; overflow: hidden; background: var(--surface); }
.detail .backdrop { position: absolute; inset: -40px; background-size: cover; background-position: center; filter: blur(50px) saturate(1.3); opacity: .45; }
.detail .inner { position: relative; display: flex; flex-wrap: wrap; gap: 28px; align-items: flex-end; padding: 28px; background: linear-gradient(180deg, rgba(21, 17, 30, 0) 0%, rgba(21, 17, 30, .65) 100%); }
.detail .cover { width: min(240px, 60vw); aspect-ratio: 1; border-radius: 20px; overflow: hidden; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); flex: none; background: var(--surface-2); }
.detail.round .cover { border-radius: 50%; }
.detail .cover img { width: 100%; height: 100%; object-fit: cover; }
.detail .info { flex: 1 1 300px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.detail .kicker { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--soft); }
.detail h1 { font-size: clamp(30px, 5vw, 58px); line-height: 1; overflow-wrap: anywhere; }
.detail .sub { color: var(--soft); }
.detail .sub a { font-weight: 700; color: var(--text); }
.detail .sub a:hover { text-decoration: underline; }
.detail .cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; align-items: center; }

/* ---------- panels and forms */
.panel { background: var(--surface); border-radius: 28px; padding: 22px; display: flex; flex-direction: column; gap: 14px; }
.panel h2 { font-size: 20px; }
.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; align-items: start; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 14px; color: var(--muted); }
.input { min-height: 46px; border-radius: 14px; border: 2px solid var(--line); background: var(--bg); padding: 0 14px; width: 100%; }
.input:focus { border-color: var(--violet); outline: none; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 44px; cursor: pointer; }
.switch input { width: 22px; height: 22px; accent-color: var(--lime); flex: none; }
.switch small { display: block; color: var(--muted); font-size: 13px; }
.summary { border: 2px solid var(--lime); border-radius: 24px; padding: 18px; display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between; }
.summary p { margin: 0; flex: 1 1 260px; }

/* ---------- requests */
.reqs { display: flex; flex-direction: column; gap: 10px; }
.req { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center; background: var(--surface); border-radius: 22px; padding: 12px 16px 12px 12px; }
.req .thumb { width: 64px; height: 64px; border-radius: 12px; overflow: hidden; background: var(--surface-2); }
.req .thumb img { width: 100%; height: 100%; object-fit: cover; }
.req .t { font-weight: 700; }
.req .m { font-size: 13px; color: var(--muted); }
.req .note { font-size: 13px; color: var(--soft); margin-top: 2px; }
.req .bar { height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; margin-top: 8px; max-width: 420px; }
.req .bar i { display: block; height: 100%; background: var(--violet); border-radius: 999px; transition: width .4s ease; }
.req .side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.pill { font-size: 13px; font-weight: 700; border-radius: 999px; padding: 7px 13px; white-space: nowrap; }
.pill.ready { background: var(--lime); color: var(--bg); }
.pill.work { background: var(--violet); color: var(--bg); }
.pill.wait { background: var(--surface-2); color: var(--soft); }
.pill.warn { background: var(--peach); color: var(--bg); }
.pill.bad { background: rgba(255, 138, 138, .18); color: var(--danger); }
@media (max-width: 560px) { .req { grid-template-columns: 52px 1fr; } .req .thumb { width: 52px; height: 52px; } .req .side { grid-column: 1 / -1; flex-direction: row; justify-content: space-between; align-items: center; } }

/* ---------- verify banner */
.verify { background: var(--peach); color: var(--bg); }
.verify-in { max-width: 1280px; margin: 0 auto; padding: 12px 20px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; font-weight: 600; }
.verify .btn { background: var(--bg); color: var(--text); }
.verify .paste { display: flex; gap: 8px; flex: 1 1 100%; }
.verify .paste input { flex: 1; min-height: 40px; border-radius: 999px; border: 0; padding: 0 14px; background: rgba(21, 17, 30, .12); color: var(--bg); }

/* ---------- mini player and toasts */
.player { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 30; width: min(560px, calc(100% - 24px)); background: rgba(43, 36, 64, .96); backdrop-filter: blur(14px); border-radius: 22px; padding: 10px 12px; display: grid; grid-template-columns: 48px 1fr auto; gap: 12px; align-items: center; box-shadow: 0 16px 50px rgba(0, 0, 0, .5); }
.player .thumb { width: 48px; height: 48px; border-radius: 10px; overflow: hidden; background: var(--surface); }
.player .thumb img { width: 100%; height: 100%; object-fit: cover; }
.player .name { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player .by { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player .prog { height: 4px; border-radius: 999px; background: var(--surface); margin-top: 6px; overflow: hidden; }
.player .prog i { display: block; height: 100%; width: 0; background: var(--lime); }
.player .ctl { display: flex; gap: 6px; }
.toasts { position: fixed; top: 76px; right: 16px; z-index: 40; display: flex; flex-direction: column; gap: 8px; width: min(380px, calc(100% - 32px)); }
.toast { background: var(--surface-2); border-left: 4px solid var(--lime); border-radius: 14px; padding: 12px 14px; box-shadow: 0 10px 30px rgba(0, 0, 0, .4); animation: pop .2s ease; }
.toast.err { border-left-color: var(--danger); }
@keyframes pop { from { opacity: 0; transform: translateY(-6px); } }

/* ---------- login */
.login { min-height: 100vh; display: grid; place-items: center; padding: 48px 20px; }
.login-card { width: 100%; max-width: 440px; display: flex; flex-direction: column; gap: 22px; }
.login-card h1 { font-size: 40px; line-height: 1.05; }
.login-card form { background: var(--surface); border-radius: 28px; padding: 26px; display: flex; flex-direction: column; gap: 16px; }
.login-dots { display: flex; }
.login-dots span { width: 44px; height: 44px; border-radius: 50%; margin-left: -18px; }
.login-dots span:first-child { margin-left: 0; }
.err-msg { color: var(--danger); font-size: 14px; min-height: 20px; margin: 0; }
.empty { color: var(--muted); padding: 24px; text-align: center; background: var(--surface); border-radius: 22px; }

@media (max-width: 720px) {
  .topbar-in { padding: 8px 14px; gap: 8px; }
  .brand { order: 1; }
  .me { order: 2; }
  .nav { order: 3; flex-basis: 100%; }
  .searchbox { order: 4; flex-basis: 100%; }
  .page { padding: 18px 16px 140px; gap: 26px; }
  .row { grid-auto-columns: minmax(130px, 150px); gap: 10px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; }
  .detail .inner { padding: 20px; }
  .row-arrows { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* ---------- v2 additions */
.card .art-actions.has-status { opacity: 1; transform: none; }
.card .art-actions .pill { box-shadow: 0 6px 18px rgba(0, 0, 0, .45); }
.track .ctl .pill { font-size: 12px; padding: 6px 10px; }
.cta-status:empty { display: none; }
.pastebox { display: flex; gap: 10px; max-width: 760px; }
.pastebox .input { border-radius: 999px; padding: 0 18px; background: var(--surface); }
.track.flash { background: rgba(214, 243, 107, .12); box-shadow: inset 3px 0 0 var(--lime); }
.topbar { padding-top: env(safe-area-inset-top); }
.player { bottom: calc(16px + env(safe-area-inset-bottom)); }

/* ---------- v3: Discover hero, Made for you, browse */
.disc-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 340px); gap: 24px; align-items: center; }
.disc-hi { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.disc-hi h1 { font-size: clamp(32px, 5vw, 52px); line-height: 1.02; }
.disc-hi p { margin: 0; color: var(--muted); max-width: 560px; }
.disc-body { display: flex; flex-direction: column; gap: 34px; transition: opacity .2s ease; }
.disc-body.loading { opacity: .45; pointer-events: none; }
.fy-card { position: relative; display: flex; flex-direction: column; gap: 14px; padding: 20px; border-radius: 28px; overflow: hidden;
  background: radial-gradient(120% 140% at 0% 0%, #8F7CFF 0%, #5B4BC4 45%, #2B2440 100%); color: var(--text); box-shadow: 0 18px 50px rgba(143, 124, 255, .25); transition: transform .15s ease; }
.fy-card:hover { transform: translateY(-2px); }
.fy-card::after { content: ''; position: absolute; right: -40px; bottom: -40px; width: 160px; height: 160px; border-radius: 50%; background: var(--peach); opacity: .35; filter: blur(10px); }
.fy-stack { display: flex; }
.fy-stack span { width: 64px; height: 64px; border-radius: 14px; overflow: hidden; margin-left: -18px; box-shadow: 0 8px 20px rgba(0, 0, 0, .35); background: var(--surface); }
.fy-stack span:first-child { margin-left: 0; }
.fy-stack img { width: 100%; height: 100%; object-fit: cover; }
.fy-stack .fy-dot { border-radius: 50%; }
.fy-dot.a { background: var(--violet); border: 3px solid rgba(255, 255, 255, .25); }
.fy-dot.b { background: var(--peach); }
.fy-dot.c { background: var(--lime); }
.fy-kicker { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; opacity: .85; }
.fy-title { font: 800 24px/1.1 var(--head); margin-top: 4px; }
.fy-sub { font-size: 14px; opacity: .85; margin-top: 4px; }
.link { color: inherit; }
.link:hover { text-decoration: underline; color: var(--lime); }
a.t.link, a.m.link { display: block; }
.detail .cta .chips { flex-basis: 100%; }
@media (max-width: 860px) { .disc-hero { grid-template-columns: 1fr; } }
.sec-orig { display: inline-block; margin-left: 12px; font: 600 14px var(--body); color: var(--muted); letter-spacing: 0; vertical-align: middle; }

/* ---------- v6: account menu and settings */
.me { position: relative; }
.me-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 4px 12px 4px 4px; border-radius: 999px; border: 0; background: transparent; color: var(--text); font-weight: 600; }
.me-btn:hover, .me-btn[aria-expanded="true"] { background: var(--surface); }
.me-btn .caret { color: var(--muted); font-size: 12px; }
.menu { position: absolute; right: 0; top: calc(100% + 8px); z-index: 50; min-width: 220px; background: var(--surface-2); border-radius: 18px; padding: 8px; box-shadow: 0 18px 50px rgba(0, 0, 0, .5); display: flex; flex-direction: column; }
.menu[hidden] { display: none; }
.menu a, .menu button { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: 12px; border: 0; background: none; text-align: left; font-weight: 600; color: var(--text); }
.menu a:hover, .menu button:hover, .menu a:focus-visible, .menu button:focus-visible { background: var(--line); }
.menu-who { display: flex; flex-direction: column; padding: 8px 12px 10px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.menu-who span { font-size: 13px; color: var(--muted); }
.set-group { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.set-group legend { font-weight: 700; margin-bottom: 8px; padding: 0; }
.chip.radio { display: inline-flex; align-items: center; cursor: pointer; }
.chip.radio input { position: absolute; opacity: 0; pointer-events: none; }
.chip.radio:has(input:checked) { background: var(--lime); border-color: var(--lime); color: var(--bg); }
.chip.radio:has(input:focus-visible) { outline: 3px solid var(--lime); outline-offset: 2px; }
.set-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 4px 24px; }
.note-warn { margin: 0; padding: 12px 14px; border-radius: 14px; background: rgba(255, 179, 138, .14); color: var(--peach); }
select.input { appearance: auto; }
@media (max-width: 720px) { .me-name { display: none; } }
.switch small { font-weight: 400; }
.set-list .switch small { display: block; color: var(--muted); font-size: 12px; }

/* ---------- v8: settings tiles and sections */
.panel h2 .badge { vertical-align: middle; margin-left: 6px; }
.set-group { border-top: 1px solid var(--surface-2); padding-top: 18px; display: flex; flex-direction: column; gap: 16px; }
.set-group:first-of-type { border-top: 0; padding-top: 0; }
.set-group h3 { font-size: 17px; font-family: var(--head); color: var(--soft); letter-spacing: .01em; }
.set-sub { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.set-label { font-weight: 700; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.set-label small { font-weight: 400; font-size: 13px; color: var(--muted); }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.tile { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 56px; padding: 10px 14px; border: 2px solid var(--line); border-radius: 16px; background: var(--bg); cursor: pointer; transition: border-color .15s ease, background .15s ease; }
.tile:hover { border-color: #4B4166; }
.tile:has(input:checked) { border-color: var(--lime); background: rgba(214, 243, 107, .07); }
.tile:has(input:focus-visible) { outline: 3px solid var(--lime); outline-offset: 2px; }
.tile-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tile-name { font-weight: 600; }
.tile small { font-size: 12px; color: var(--muted); line-height: 1.35; }
.tile input { width: 22px; height: 22px; flex: none; accent-color: var(--lime); margin: 0; }
.grid-fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; align-items: start; }
.grid-fields .field small { font-size: 12px; }
.inline-form { display: flex; gap: 8px; max-width: 560px; }
.inline-form .input { flex: 1; min-width: 0; }
.save-bar { position: sticky; bottom: 12px; z-index: 5; display: flex; justify-content: flex-end; padding: 10px; margin: 0 -10px -10px; border-radius: 22px; background: rgba(32, 26, 45, .9); backdrop-filter: blur(8px); }
.hero-hi nav.chips a.chip { display: inline-flex; align-items: center; }
#set-you, #set-stats, #set-server { scroll-margin-top: 90px; }

/* cover size (personal setting) */
html[data-cards="compact"] .row { grid-auto-columns: minmax(118px, 138px); gap: 10px; }
html[data-cards="compact"] .grid { grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); gap: 10px; }
html[data-cards="compact"] .card .t { font-size: 14px; }
html[data-cards="large"] .row { grid-auto-columns: minmax(200px, 240px); gap: 20px; }
html[data-cards="large"] .grid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 22px; }
html.no-previews [aria-label^="Preview "] { display: none; }

/* ---------- v11: request feedback and squiggle progress */
.spinner { width: 18px; height: 18px; border-radius: 50%; border: 3px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
.icon-btn.busy { cursor: progress; opacity: .9; }
@keyframes spin { to { transform: rotate(360deg); } }
.wave { position: relative; display: flex; align-items: center; gap: 5px; height: 12px; width: 100%; color: var(--violet); }
.wave-on { flex: none; height: 12px; background: currentColor; border-radius: 6px;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 12'%3E%3Cpath d='M0 6 Q6 0 12 6 T24 6' fill='none' stroke='black' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") left center / 24px 12px repeat-x; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 12'%3E%3Cpath d='M0 6 Q6 0 12 6 T24 6' fill='none' stroke='black' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") left center / 24px 12px repeat-x;
  animation: wave-move 1.1s linear infinite; transition: width .5s ease; }
.wave-off { flex: 1; height: 4px; border-radius: 4px; background: var(--surface-2); min-width: 0; }
.wave.ind .wave-on { position: absolute; left: 0; width: 34%; animation: wave-move 1.1s linear infinite, wave-slide 1.6s ease-in-out infinite alternate; }
.wave.small { height: 8px; gap: 4px; }
.wave.small .wave-on { height: 8px; -webkit-mask-size: 16px 8px; mask-size: 16px 8px; animation-name: wave-move-s; }
.wave.small.ind .wave-on { animation: wave-move-s 1.1s linear infinite, wave-slide 1.6s ease-in-out infinite alternate; }
.wave.small .wave-off { height: 3px; background: rgba(255, 255, 255, .22); }
@keyframes wave-move { to { -webkit-mask-position: 24px center; mask-position: 24px center; } }
@keyframes wave-move-s { to { -webkit-mask-position: 16px center; mask-position: 16px center; } }
@keyframes wave-slide { from { left: 0; } to { left: 66%; } }

/* on album covers: slim strip along the bottom instead of a big pill */
.card .art-actions.has-status { left: 8px; right: 8px; bottom: 8px; justify-content: stretch; }
.cover-status { flex: 1; display: flex; flex-direction: column; gap: 5px; padding: 7px 9px 8px; border-radius: 12px; background: rgba(21, 17, 30, .78); backdrop-filter: blur(8px); color: var(--text); font-size: 11px; font-weight: 700; letter-spacing: .01em; }
.cover-status .wave { color: var(--lime); }
.cover-done, .cover-flag { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; padding: 4px 9px 4px 6px; border-radius: 999px; font-size: 11px; font-weight: 800; background: var(--lime); color: var(--bg); box-shadow: 0 4px 12px rgba(0, 0, 0, .35); }
.cover-done svg { width: 14px; height: 14px; }
.cover-flag { padding: 4px 9px; }
.cover-flag.warn { background: var(--peach); }
.cover-flag.bad { background: #FF8A8A; }
.mini-wave { width: 72px; }
.pill.mini { font-size: 12px; padding: 5px 10px; }

/* Requests page: the whole journey */
.journey { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; max-width: 560px; }
.journey-bar { display: flex; align-items: center; gap: 10px; }
.journey-bar .wave { flex: 1; }
.journey-pct { font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--soft); min-width: 38px; text-align: right; }
.steps { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 12px; color: var(--muted); }
.steps li { display: inline-flex; align-items: center; gap: 6px; }
.steps .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--surface-2); }
.steps li.done { color: var(--soft); }
.steps li.done .dot { background: var(--lime); }
.steps li.now { color: var(--text); font-weight: 700; }
.steps li.now .dot { background: var(--violet); box-shadow: 0 0 0 4px rgba(143, 124, 255, .25); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(143, 124, 255, .08); } }
@media (prefers-reduced-motion: reduce) { .wave-on, .spinner, .steps li.now .dot { animation: none !important; } }

/* ---------- v12: failed requests */
.req.req-bad { box-shadow: inset 3px 0 0 #FF8A8A; }
.err-box { margin-top: 8px; padding: 12px 14px; border-radius: 14px; background: rgba(255, 138, 138, .1); border: 1px solid rgba(255, 138, 138, .3); display: flex; flex-direction: column; gap: 6px; max-width: 640px; }
.err-why { font-size: 14px; color: #FFD0D0; line-height: 1.45; }
.err-why strong { color: #FF8A8A; }
.err-tracks, .err-meta { font-size: 12px; color: var(--muted); }
.err-meta:empty { display: none; }
.err-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2px; }
.err-actions .btn .spinner { width: 14px; height: 14px; border-width: 2px; }
.chip.chip-bad[aria-pressed="false"] { border-color: rgba(255, 138, 138, .55); color: #FFB0B0; }

/* ---------- v13: Made for you sits beside the greeting and the paste box, softer shadow */
.disc-hero { grid-template-columns: minmax(0, 1fr) minmax(260px, 320px); grid-template-areas: "hi card" "paste card"; column-gap: 48px; row-gap: 22px; align-items: center; }
.disc-hero .disc-hi { grid-area: hi; }
.disc-hero .pastebox { grid-area: paste; }
.disc-hero .fy-card { grid-area: card; align-self: stretch; justify-content: center; margin: 6px clamp(0px, 4vw, 56px) 6px 0; box-shadow: 0 6px 18px rgba(0, 0, 0, .22); }
.disc-hero .fy-card:hover { box-shadow: 0 10px 26px rgba(0, 0, 0, .28); }
@media (max-width: 860px) {
  .disc-hero { grid-template-columns: 1fr; grid-template-areas: "hi" "paste" "card"; }
  .disc-hero .fy-card { margin: 0; }
}

/* ---------- v14: done part is a straight line, the part still to do squiggles */
.wave { gap: 0; }
.wave .wave-on { height: 4px; border-radius: 4px; background: currentColor; -webkit-mask: none; mask: none; animation: none; transition: width .5s ease; }
.wave .wave-off { flex: 1; min-width: 0; height: 12px; margin-left: 4px; border-radius: 0; color: rgba(255, 255, 255, .26); background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 12'%3E%3Cpath d='M0 6 Q6 0 12 6 T24 6' fill='none' stroke='black' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") left center / 24px 12px repeat-x; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 12'%3E%3Cpath d='M0 6 Q6 0 12 6 T24 6' fill='none' stroke='black' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") left center / 24px 12px repeat-x; animation: wave-move 1.1s linear infinite; }
.wave.full .wave-off { display: none; }
.wave.ind .wave-on { display: none; }
.wave.ind .wave-off { margin-left: 0; color: inherit; }
.wave.small .wave-on { height: 3px; }
.wave.small .wave-off { height: 8px; margin-left: 3px; -webkit-mask-size: 16px 8px; mask-size: 16px 8px; animation-name: wave-move-s; color: rgba(255, 255, 255, .32); }
.wave.small.ind .wave-off { color: inherit; }
