:root {
  --bg: #f4f3ef; --surface: #ffffff; --surface-2: #f8f7f4; --ink: #1c1c1e; --ink-2: #5f5f66; --ink-3: #707077;
  --line: #e6e4de; --accent: #2b6e53; --accent-ink: #ffffff; --accent-soft: #e3f0ea; --danger: #b42318;
  --shadow: 0 1px 2px rgba(20, 20, 20, .04), 0 4px 16px rgba(20, 20, 20, .05);
  --radius: 14px; --radius-sm: 9px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121214; --surface: #1c1c1f; --surface-2: #232327; --ink: #f2f2f3; --ink-2: #b4b4bb; --ink-3: #85858d;
    --line: #2e2e33; --accent: #5cc595; --accent-ink: #0e2a1e; --accent-soft: #1d3a2d; --danger: #ff8a7a;
    --shadow: none;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink);
       font: 15px/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
.muted { color: var(--ink-2); }
.small { font-size: 13px; }

/* top bar */
.topbar { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 88%, transparent);
          backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.topbar-inner { max-width: 1180px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; gap: 12px; }
.logo { width: 30px; height: 30px; border-radius: 8px; background: var(--accent); color: var(--accent-ink);
        display: grid; place-items: center; }
.brand { min-width: 0; margin-right: auto; display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.brand b { display: block; font-size: 16px; letter-spacing: -.01em; }
.brand .tagline { display: block; font-size: 12.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 640px) { .brand .tagline { display: none; } .topbar-inner { padding: 10px 14px; } }

/* layout */
.layout { max-width: 1180px; margin: 0 auto; padding: 20px; display: grid; gap: 20px;
          grid-template-columns: 300px minmax(0, 1fr); align-items: start; }
.library { position: sticky; top: 76px; }
@media (max-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1fr); padding: 14px; gap: 14px; }
  .library { position: static; order: 2; }
}
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
        scroll-margin-top: 76px; /* keep titles clear of the sticky top bar when scrolled to */ }
.card-pad { padding: 18px; }
@media (max-width: 600px) { .card-pad { padding: 14px; } }
h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); margin: 0 0 10px; font-weight: 600; }
#main { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; min-width: 0; }
@media (max-width: 900px) { #main { gap: 14px; } }

/* buttons */
.btn { border: 0; border-radius: var(--radius-sm); padding: 10px 16px; font-weight: 600; display: inline-flex;
       align-items: center; justify-content: center; gap: 8px; text-decoration: none; white-space: nowrap; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-secondary { background: var(--surface-2); color: var(--ink); border: 1px solid var(--line); }
.btn:disabled { opacity: .5; cursor: default; }
.btn svg { width: 17px; height: 17px; }

/* create card */
.tabs { display: inline-flex; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 3px; margin-bottom: 14px; }
.tabs button { border: 0; background: transparent; padding: 6px 14px; border-radius: 7px; font-weight: 600; color: var(--ink-2); font-size: 14px; }
.tabs button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.source-row { display: flex; gap: 10px; }
.field { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line);
         border-radius: var(--radius-sm); padding: 0 12px; background: var(--surface-2); }
.field:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.field svg { width: 17px; height: 17px; color: var(--ink-3); flex: none; }
.field input { border: 0; outline: 0; background: transparent; padding: 11px 0; width: 100%; }
.drop { flex: 1; min-width: 0; border: 1.5px dashed var(--line); border-radius: var(--radius-sm); padding: 14px;
        display: flex; align-items: center; gap: 12px; cursor: pointer; background: var(--surface-2); }
.drop.over { border-color: var(--accent); background: var(--accent-soft); }
.drop svg { width: 22px; height: 22px; color: var(--ink-3); flex: none; }
.drop b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drop span { font-size: 13px; color: var(--ink-3); }
@media (max-width: 600px) { .source-row { flex-direction: column; } }
.form-error { color: var(--danger); font-size: 14px; margin-top: 10px; min-height: 0; }

/* options */
.options { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; }
.options > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 14px; }
.options > summary::-webkit-details-marker { display: none; }
.options > summary .chev { transition: transform .15s; color: var(--ink-3); }
.options[open] > summary .chev { transform: rotate(90deg); }
.options > summary .sum { font-weight: 400; color: var(--ink-3); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.groups { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
@media (max-width: 1050px) { .groups { grid-template-columns: 1fr; } }
.group { background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: grid; gap: 12px; align-content: start; }
.group h3 { margin: 0; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); }
.opt { display: grid; gap: 6px; }
.opt-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.opt label, .opt .label { font-size: 13.5px; color: var(--ink-2); }
.seg { display: flex; background: var(--surface); border: 1px solid var(--line); border-radius: 9px; padding: 2px; }
.seg button { flex: 1; border: 0; background: transparent; padding: 5px 6px; border-radius: 7px; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.seg button.on { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); }
.stepper button { border: 0; background: transparent; width: 30px; height: 30px; font-size: 17px; color: var(--ink-2); }
.stepper output { min-width: 26px; text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; }
input[type=range] { width: 100%; accent-color: var(--accent); }
.bpm-input { width: 90px; border: 1px solid var(--line); border-radius: 8px; padding: 5px 8px; background: var(--surface); }
.switch { position: relative; width: 40px; height: 24px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch span { position: absolute; inset: 0; background: var(--line); border-radius: 99px; transition: .15s; }
.switch span::after { content: ""; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px; border-radius: 50%; background: #fff; transition: .15s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.switch input:checked + span { background: var(--accent); }
.switch input:checked + span::after { transform: translateX(16px); }
.hint { font-size: 12px; color: var(--ink-3); }
.create-actions { display: flex; justify-content: flex-end; margin-top: 14px; }

/* job */
.job-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.job-title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.progress { height: 6px; background: var(--surface-2); border-radius: 99px; overflow: hidden; margin: 12px 0; }
.progress div { height: 100%; background: var(--accent); width: 0; transition: width .4s; }
.steps { list-style: none; padding: 0; margin: 4px 0 0; display: grid; gap: 2px; }
.steps li { display: grid; grid-template-columns: 22px 1fr auto; align-items: center; gap: 8px; padding: 6px 8px;
            border-radius: 8px; font-size: 14px; color: var(--ink-3); }
.steps li .ic { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center;
                font-size: 11px; line-height: 1; }
.steps li .tm { font-size: 12.5px; font-variant-numeric: tabular-nums; color: var(--ink-3); }
.steps li.done { color: var(--ink); }
.steps li.done .ic { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.steps li.cached { color: var(--ink-2); }
.steps li.cached .ic { border-color: var(--accent); color: var(--accent); }
.steps li.active { background: var(--accent-soft); color: var(--ink); font-weight: 600; }
.steps li.active .ic { border-color: var(--accent); border-top-color: transparent; animation: spin .9s linear infinite; }
.steps li.active .tm { color: var(--accent); font-weight: 600; }
.steps li.failed { color: var(--danger); }
.steps li.failed .ic { background: var(--danger); border-color: var(--danger); color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }
.job-error { color: var(--danger); white-space: pre-wrap; font-size: 13px; margin-top: 10px; }

/* confidence rating */
.rating { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: start; margin-top: 14px;
          padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.score { width: 74px; height: 74px; border-radius: 50%; display: grid; place-items: center; text-align: center;
         border: 4px solid var(--line); font-weight: 750; font-size: 22px; line-height: 1; }
.score small { display: block; font-size: 11px; font-weight: 600; margin-top: 3px; }
.score.good { border-color: var(--accent); color: var(--accent); }
.score.fair { border-color: #c98a1b; color: #c98a1b; }
.score.risky { border-color: var(--danger); color: var(--danger); }
.subs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 16px; font-size: 13px; }
.sub { display: grid; gap: 3px; }
.sub .row { display: flex; justify-content: space-between; color: var(--ink-2); }
.sub .meter { height: 5px; border-radius: 99px; background: var(--line); overflow: hidden; }
.sub .meter div { height: 100%; background: var(--accent); }
.notes { grid-column: 1 / -1; margin: 0; padding-left: 18px; font-size: 13px; color: var(--ink-2); display: grid; gap: 3px; }
.rating-actions { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.conf { display: inline-flex; gap: 6px; align-items: center; margin-top: 8px; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.conf b.good { color: var(--accent); } .conf b.fair { color: #c98a1b; } .conf b.risky { color: var(--danger); }
.lib-item .m b.good { color: var(--accent); font-weight: 600; } .lib-item .m b.fair { color: #c98a1b; font-weight: 600; }
.lib-item .m b.risky { color: var(--danger); font-weight: 600; }
.check-first { display: flex; align-items: center; gap: 10px; margin-top: 12px; font-size: 13.5px; color: var(--ink-2); }

/* song */
.empty { text-align: center; padding: 48px 20px; color: var(--ink-3); }
.empty svg { width: 40px; height: 40px; margin-bottom: 8px; color: var(--line); }
.song-head { display: flex; gap: 16px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
.song-head h1 { font-size: 24px; line-height: 1.2; letter-spacing: -.02em; margin: 0; }
.song-head .sub { color: var(--ink-2); margin-top: 4px; }
.song-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 18px; }
@media (max-width: 600px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stat { background: var(--surface-2); border-radius: 11px; padding: 10px 12px; }
.stat .k { font-size: 12px; color: var(--ink-3); }
.stat .v { font-size: 17px; font-weight: 650; letter-spacing: -.01em; }
.stat .d { font-size: 12px; color: var(--ink-3); }
.frets { margin-top: 16px; }
.frets .label { font-size: 13px; color: var(--ink-2); margin-bottom: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: baseline; gap: 6px; padding: 5px 10px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line); font-size: 14px; }
.chip i { font-style: normal; font-size: 11px; color: var(--ink-3); font-weight: 600; }
.chip b { font-weight: 650; }

/* player */
.player { margin-top: 18px; display: flex; align-items: center; gap: 12px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.play { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; flex: none; }
.play svg { width: 18px; height: 18px; }
.time { font-size: 12.5px; color: var(--ink-2); font-variant-numeric: tabular-nums; flex: none; min-width: 82px; text-align: right; }
.vox { display: flex; align-items: center; gap: 8px; flex: none; font-size: 13px; color: var(--ink-2); cursor: pointer;
       padding-left: 12px; border-left: 1px solid var(--line); }
.vox.disabled { opacity: .45; cursor: default; }
@media (max-width: 600px) { .player { flex-wrap: wrap; } .player input[type=range] { order: 5; flex-basis: 100%; }
                            .vox { margin-left: auto; } }

/* chart */
.chart-head { display: flex; justify-content: space-between; align-items: baseline; margin-top: 22px; margin-bottom: 8px; gap: 10px; }
.chart-head h3 { margin: 0; font-size: 15px; }
.chart-tools { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-bottom: 8px; }
.chart-tools .small { margin-right: auto; }
.chip-btn { border: 1px solid var(--line); background: var(--surface); border-radius: 99px; padding: 4px 11px; font-size: 13px; color: var(--ink-2); }
.chip-btn:hover { border-color: var(--ink-3); color: var(--ink); }
.chart { max-height: 480px; overflow-y: auto; border: 1px solid var(--line); border-radius: 12px; padding: 8px; background: var(--surface-2); }
.bars { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.bar { position: relative; border: 1px solid var(--line); background: var(--surface); border-radius: 9px; padding: 20px 8px 8px;
       min-height: 64px; text-align: left; display: flex; flex-direction: column; gap: 3px; cursor: pointer; }
.bar:hover { border-color: var(--ink-3); }
.bar .t { position: absolute; top: 4px; left: 8px; font-size: 10.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.bar .chords { display: flex; gap: 4px; }
.bar .c { flex: 1; min-width: 0; font-weight: 650; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar .c + .c { border-left: 1px solid var(--line); padding-left: 6px; }
.bar .c sup { font-size: 10px; color: var(--ink-3); font-weight: 600; margin-left: 2px; }
.bar .c.none { color: var(--ink-3); font-weight: 400; }
.bar .ly { font-size: 12.5px; line-height: 1.3; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bar.cue { box-shadow: inset 3px 0 0 var(--accent); }
.bar .cue-label { color: var(--accent); font-weight: 650; }
.mic { position: absolute; top: 3px; right: 4px; width: 24px; height: 22px; border: 0; border-radius: 6px; background: transparent;
       color: var(--ink-3); display: grid; place-items: center; padding: 0; }
.mic:hover { background: var(--surface-2); color: var(--ink); }
.mic svg { width: 14px; height: 14px; }
.bar.muted { background: repeating-linear-gradient(-45deg, var(--surface), var(--surface) 6px, var(--surface-2) 6px, var(--surface-2) 12px); }
.bar.muted .ly { text-decoration: line-through; color: var(--ink-3); }
.bar.muted .mic { color: var(--danger); }
.bar.now { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent) inset; }
.bar.now:not(.muted) { background: var(--accent-soft); }
@media (max-width: 600px) { .bar .c { font-size: 14px; } .bars { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.play.loading { opacity: .6; }

/* library */
.lib-list { display: grid; gap: 2px; }
.lib-item { border: 0; background: transparent; text-align: left; border-radius: 10px; padding: 9px 10px; display: grid; gap: 1px; width: 100%; }
.lib-item:hover { background: var(--surface-2); }
.lib-item.on { background: var(--accent-soft); }
.lib-item .t { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-item .s { font-size: 12.5px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-item .m { font-size: 12px; color: var(--ink-2); }
.lib-empty { font-size: 14px; color: var(--ink-3); padding: 6px 2px; }

/* ---------- MuzikCaffe additions ---------- */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--accent); color: var(--accent-ink);
        padding: 8px 14px; border-radius: 8px; font-weight: 600; text-decoration: none; }
.skip:focus { top: 10px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.btn-sm { padding: 7px 12px; font-size: 14px; }
.btn-ghost { background: transparent; color: var(--ink-2); border: 1px solid transparent; }
.btn-ghost:hover { color: var(--ink); background: var(--surface-2); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger-ghost { background: transparent; color: var(--danger); border: 1px solid var(--line); }
.btn-danger-ghost:hover { border-color: var(--danger); }
@media (prefers-color-scheme: dark) { .btn-danger { color: #2a0b07; } }
.icon-btn { border: 0; background: transparent; width: 34px; height: 34px; border-radius: 8px; display: inline-grid;
            place-items: center; color: var(--ink-3); flex: none; padding: 0; }
.icon-btn:hover { background: var(--surface-2); color: var(--ink); }
.icon-btn svg { width: 17px; height: 17px; }

/* account area in the top bar */
.account { display: flex; align-items: center; gap: 8px; min-width: 0; }
.who { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 13.5px; color: var(--ink-2); }
.who .email { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 240px; }
.avatar { width: 30px; height: 30px; border-radius: 50%; flex: none; background: var(--accent-soft); color: var(--accent);
          display: grid; place-items: center; font-weight: 700; font-size: 13px; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 640px) { .who .email { display: none; } .account .btn-label { display: none; } }

/* boot */
.boot { min-height: 60vh; display: grid; place-items: center; color: var(--ink-3); font-size: 14px; }
.spinner { width: 26px; height: 26px; border-radius: 50%; border: 2.5px solid var(--line); border-top-color: var(--accent);
           animation: spin .9s linear infinite; margin: 0 auto 10px; }

/* landing */
.landing { max-width: 1040px; margin: 0 auto; padding: 56px 20px 40px; }
.hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 40px; align-items: center; }
.hero h1 { font-size: clamp(32px, 5vw, 50px); line-height: 1.05; letter-spacing: -.035em; margin: 0 0 14px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lede { font-size: 17px; color: var(--ink-2); margin: 0 0 26px; max-width: 34em; }
.signin { display: grid; gap: 10px; justify-items: start; }
.signin .gsi { min-height: 44px; min-width: 220px; }
.signin .note { font-size: 13px; color: var(--ink-3); }
.signin .err { color: var(--danger); font-size: 14px; }
.mock-gsi { display: inline-flex; align-items: center; gap: 10px; border: 1px solid var(--line); background: var(--surface);
            border-radius: 99px; padding: 9px 18px 9px 12px; font-weight: 600; font-size: 14.5px; }
.mock-gsi svg { width: 18px; height: 18px; }
.mock-note { font-size: 12px; color: var(--ink-3); margin-top: 6px; }
.preview { padding: 16px; display: grid; gap: 10px; transform: rotate(-1deg); }
.preview .pv-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.preview .pv-head b { font-size: 16px; }
.preview .bars { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.preview .bar { cursor: default; min-height: 58px; }
@media (max-width: 600px) {
  .preview .bars { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .song-actions { width: 100%; }
  .song-actions .btn { flex: 1 1 auto; }
}
.features { list-style: none; padding: 0; margin: 56px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.features li { padding: 18px; }
.features .fi { width: 36px; height: 36px; border-radius: 10px; background: var(--accent-soft); color: var(--accent);
                display: grid; place-items: center; margin-bottom: 10px; }
.features .fi svg { width: 19px; height: 19px; }
.features b { display: block; margin-bottom: 4px; }
.features p { margin: 0; color: var(--ink-2); font-size: 14px; }
.site-foot { text-align: center; color: var(--ink-3); font-size: 12.5px; padding: 28px 20px 36px; line-height: 1.8; }
.site-foot a { color: var(--ink-2); }
.site-foot a:hover { color: var(--accent); }

/* privacy / terms */
.doc { max-width: 720px; margin: 0 auto; padding: 32px 16px 0; }
.doc article { padding: 28px 32px; }
.doc h1 { font-size: 28px; letter-spacing: -.02em; margin: 0 0 4px; }
.doc h2 { font-size: 16px; text-transform: none; letter-spacing: -.01em; color: var(--ink); margin: 24px 0 6px; }
.doc p, .doc li { color: var(--ink-2); }
.doc p { margin: 0 0 10px; }
.doc ul { padding-left: 20px; margin: 0 0 10px; display: grid; gap: 6px; }
.doc b { color: var(--ink); font-weight: 600; }
.doc a { color: var(--accent); }
.doc .updated { font-size: 13px; color: var(--ink-3); }
@media (max-width: 600px) { .doc { padding-top: 16px; } .doc article { padding: 20px 18px; } }
@media (max-width: 860px) {
  .landing { padding: 28px 16px 24px; }
  .hero { grid-template-columns: 1fr; gap: 28px; }
  .preview { transform: none; }
  .features { grid-template-columns: 1fr; margin-top: 28px; gap: 10px; }
}

/* not on the guest list / notices */
.notice { max-width: 520px; margin: 56px auto; padding: 0 16px; }
.notice .card { padding: 28px; text-align: center; }
.notice .big-ic { width: 52px; height: 52px; border-radius: 50%; background: var(--accent-soft); color: var(--accent);
                  display: grid; place-items: center; margin: 0 auto 14px; }
.notice .big-ic svg { width: 26px; height: 26px; }
.notice h1 { font-size: 22px; letter-spacing: -.02em; margin: 0 0 8px; }
.notice p { color: var(--ink-2); margin: 0 0 10px; }
.notice .signed-as { display: inline-flex; align-items: center; gap: 8px; background: var(--surface-2); border: 1px solid var(--line);
                     border-radius: 99px; padding: 5px 12px 5px 5px; font-size: 14px; margin: 6px 0 18px; max-width: 100%; }
.notice .signed-as span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.notice .signed-as .avatar { width: 24px; height: 24px; font-size: 11px; }
.notice .actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }

/* song title: inline edit */
.title-row { display: flex; align-items: center; gap: 4px; min-width: 0; }
.title-row h1 { min-width: 0; overflow-wrap: anywhere; }
.edit-form { display: grid; gap: 8px; max-width: 520px; }
.edit-form .row { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 8px; align-items: center; }
.edit-form label { font-size: 13px; color: var(--ink-2); }
.text-input { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; background: var(--surface-2); width: 100%; outline: 0; }
.text-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.edit-form .btns { display: flex; gap: 8px; }
.edit-form .err { color: var(--danger); font-size: 13px; }
.song-head > div:first-child { flex: 1 1 320px; }
.frets .label { display: flex; flex-wrap: wrap; gap: 4px 12px; justify-content: space-between; }
.frets .label b { color: var(--ink); font-weight: 600; }
.song-foot { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); display: flex; justify-content: space-between;
             align-items: center; gap: 10px; flex-wrap: wrap; }
.bar:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }

/* dialogs */
dialog { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink);
         padding: 0; width: min(560px, calc(100vw - 24px)); max-height: calc(100dvh - 48px); box-shadow: 0 20px 60px rgba(0,0,0,.25); }
dialog::backdrop { background: rgba(10, 10, 12, .45); backdrop-filter: blur(2px); }
.dlg-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 18px 6px; }
.dlg-head h2 { margin: 0; font-size: 18px; text-transform: none; letter-spacing: -.01em; color: var(--ink); }
.dlg-body { padding: 6px 18px 18px; }
.invite-form { display: flex; gap: 8px; margin: 12px 0 4px; }
.invite-form .text-input { flex: 1; min-width: 0; }
.invite-list { list-style: none; margin: 12px 0 0; padding: 0; border: 1px solid var(--line); border-radius: 12px;
               max-height: min(52vh, 420px); overflow-y: auto; }
.invite-list li { display: flex; align-items: center; gap: 10px; padding: 10px 8px 10px 14px; }
.invite-list li + li { border-top: 1px solid var(--line); }
.invite-list .who-col { flex: 1; min-width: 0; }
.invite-list .em { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.invite-list .meta { font-size: 12.5px; color: var(--ink-3); overflow-wrap: anywhere; }
.invite-list .empty-row { color: var(--ink-3); font-size: 14px; justify-content: center; padding: 18px; }
.tag { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--accent);
       background: var(--accent-soft); border-radius: 99px; padding: 2px 8px; }
.confirm-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
@media (max-width: 600px) { dialog { margin: auto auto 12px; } .invite-form { flex-direction: column; } }

/* toast */
.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translateX(-50%) translateY(20px);
         background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 10px; font-size: 14px; z-index: 60;
         opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; max-width: calc(100vw - 32px); }
.toast.show { opacity: 1; transform: translateX(-50%); }
.toast.error { background: var(--danger); color: #fff; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
