:root {
  --bg: #F4F3F8; --surface: #fff; --ink: #17161F; --muted: #64627A; --faint: #9896AA; --line: #E6E4EF;
  --accent: #4F46E5; --accent-2: #EEF0FF; --good: #1F9D55; --good-bg: #E8F7EE; --warn: #B45309; --warn-bg: #FFF4E0;
  --bad: #C92A2A; --bad-bg: #FDECEC; --shadow: 0 1px 2px rgba(23,22,31,.05), 0 6px 24px rgba(23,22,31,.06); --r: 16px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 15px/1.5 Inter, -apple-system, "Segoe UI", sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--accent); }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -.01em; }
.top { display: flex; align-items: center; gap: 14px; padding: 14px 20px; max-width: 980px; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; color: inherit; text-decoration: none; }
.logo { width: 30px; height: 30px; border-radius: 9px; background: linear-gradient(135deg, #6D5DF5, #4338CA); display: grid; place-items: center; box-shadow: 0 2px 8px rgba(79,70,229,.35); }
.logo svg { width: 18px; height: 18px; }
.nav { margin-left: auto; display: flex; gap: 4px; }
.nav a { text-decoration: none; color: var(--muted); font-weight: 500; padding: 7px 12px; border-radius: 9px; font-size: 14.5px; }
.nav a.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
main { max-width: 980px; margin: 0 auto; padding: 4px 20px 60px; }
.card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: 22px; margin-bottom: 16px; }
.card h2 { font-size: 18px; margin-bottom: 4px; }
.sub { color: var(--muted); margin: 0 0 16px; font-size: 14px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid3 { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 12px; }
@media (max-width: 640px) { .grid2, .grid3 { grid-template-columns: 1fr; } .nav a { padding: 7px 9px; } .card { padding: 18px; } }
.field { display: block; margin-bottom: 12px; }
.field > span { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 5px; }
.field em { font-style: normal; font-weight: 400; color: var(--faint); }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], select, textarea {
  width: 100%; border: 1.5px solid var(--line); background: #fff; border-radius: 11px; padding: 10px 12px; outline: none; transition: border-color .15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); }
textarea { resize: vertical; min-height: 150px; line-height: 1.6; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.chip { border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 3px 10px; font-size: 12.5px; cursor: pointer; color: var(--muted); }
.chip:hover { border-color: var(--accent); color: var(--accent); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 11px; padding: 10px 16px; font-weight: 600; cursor: pointer; background: var(--accent-2); color: var(--accent); text-decoration: none; font-size: 14.5px; }
.btn.primary { background: var(--accent); color: #fff; box-shadow: 0 2px 10px rgba(79,70,229,.3); }
.btn.big { padding: 13px 20px; font-size: 15.5px; }
.btn.ghost { background: transparent; color: var(--muted); }
.btn.danger { background: var(--bad-bg); color: var(--bad); }
.btn:disabled { opacity: .55; cursor: default; }
.btn.small { padding: 6px 11px; font-size: 13px; border-radius: 9px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }
.muted { color: var(--muted); }
.faint { color: var(--faint); font-size: 13px; }
.hidden { display: none !important; }
.banner { border-radius: 12px; padding: 12px 14px; font-size: 14px; margin-bottom: 14px; }
.banner.good { background: var(--good-bg); color: #15693A; }
.banner.warn { background: var(--warn-bg); color: #8A4106; }
.banner.bad { background: var(--bad-bg); color: var(--bad); }
.banner.info { background: var(--accent-2); color: #3730A3; }
.banner b { font-weight: 600; }
.banner ul { margin: 6px 0 0; padding-left: 18px; }

/* set results */
.plan { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.plan .when { font-size: 20px; font-weight: 700; }
.song { border: 1.5px solid var(--line); border-radius: 14px; padding: 14px 16px; margin-bottom: 10px; background: #fff; }
.song.ok { border-color: #BFE8CF; }
.song.warn { border-color: #F6D9A8; }
.song.bad { border-color: #F3C0C0; }
.song.skip { opacity: .55; }
.song-head { display: flex; gap: 12px; align-items: flex-start; }
.num { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; margin-top: 1px; }
.ok .num { background: var(--good-bg); color: var(--good); }
.warn .num { background: var(--warn-bg); color: var(--warn); }
.bad .num { background: var(--bad-bg); color: var(--bad); }
.song-title { font-weight: 650; font-size: 16px; }
.song-meta { color: var(--muted); font-size: 13px; }
.typed { color: var(--faint); font-size: 12.5px; }
.song-body { margin: 10px 0 0 38px; }
.pickers { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.pickers select { width: auto; min-width: 140px; padding: 6px 10px; font-size: 13.5px; border-radius: 9px; }
.files { display: flex; gap: 6px; flex-wrap: wrap; }
.f { font-size: 12.5px; padding: 3px 9px; border-radius: 99px; font-weight: 500; }
.f.have { background: var(--good-bg); color: #15693A; }
.f.miss { background: var(--bad-bg); color: var(--bad); }
.f.extra { background: #F1F0F6; color: var(--muted); }
.links { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 8px; font-size: 13px; }
.links a, .links button { color: var(--accent); text-decoration: none; background: none; border: 0; padding: 0; cursor: pointer; font-size: 13px; font-weight: 500; }
.choices { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 8px; }
.choices button { border: 1.5px solid var(--line); background: #fff; border-radius: 10px; padding: 6px 10px; cursor: pointer; font-size: 13.5px; text-align: left; }
.choices button:hover { border-color: var(--accent); }
.choices small { color: var(--faint); display: block; font-size: 11.5px; }
.actions { position: sticky; bottom: 0; background: linear-gradient(transparent, var(--bg) 30%); padding: 18px 0 8px; display: flex; gap: 10px; flex-wrap: wrap; }
.toggle { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); cursor: pointer; }

/* lyrics preview */
.dialog { position: fixed; inset: 0; background: rgba(23,22,31,.45); display: grid; place-items: center; padding: 16px; z-index: 20; }
.dialog-card { background: var(--surface); border-radius: 18px; max-width: 760px; width: 100%; max-height: 88vh; overflow: auto; padding: 22px; }
.slides { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin-top: 12px; }
.slide { background: #000; color: #fff; aspect-ratio: 16/9; border-radius: 8px; display: grid; place-items: center; text-align: center; font-weight: 700; font-size: 12px; line-height: 1.3; padding: 10px; position: relative; white-space: pre-line; }
.slide i { position: absolute; left: 0; bottom: 0; right: 0; font-style: normal; font-size: 10px; font-weight: 600; padding: 2px 6px; text-align: left; border-radius: 0 0 8px 8px; }

/* lists */
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.list a.item { text-decoration: none; color: inherit; flex: 1; min-width: 0; }
.pill { font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 99px; background: #F1F0F6; color: var(--muted); }
.pill.sent { background: var(--good-bg); color: var(--good); }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; }
.steps > li { counter-increment: s; position: relative; padding: 0 0 14px 38px; }
.steps > li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 99px; background: var(--accent-2); color: var(--accent); font-weight: 700; display: grid; place-items: center; font-size: 13px; }
.steps > li.done::before { content: "✓"; background: var(--good-bg); color: var(--good); }
.campus-row { display: grid; grid-template-columns: 1fr 1.4fr auto; gap: 8px; margin-bottom: 8px; }
@media (max-width: 640px) { .campus-row { grid-template-columns: 1fr; } }
.code { font-family: ui-monospace, Menlo, monospace; background: #F1F0F6; padding: 2px 7px; border-radius: 6px; font-size: 13px; word-break: break-all; }
.check { display: flex; gap: 8px; align-items: center; margin: 6px 0; font-size: 14.5px; }
.check input { width: 17px; height: 17px; accent-color: var(--accent); }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 12px; font-size: 14px; z-index: 30; box-shadow: 0 8px 30px rgba(0,0,0,.25); max-width: 90vw; }
.spin { width: 16px; height: 16px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 99px; animation: spin .7s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.foot { text-align: center; color: var(--faint); font-size: 13px; padding: 10px 0 30px; }
.foot a { color: var(--muted); }
.nav a { white-space: nowrap; }
@media (max-width: 520px) {
  .top { padding: 12px 14px; gap: 8px; }
  .brand { font-size: 0; gap: 0; }
  .brand .logo { font-size: 15px; }
  .nav { gap: 2px; }
  .nav a { padding: 6px 8px; font-size: 13.5px; }
  main { padding: 4px 12px 40px; }
  .actions { gap: 8px; }
  .actions .btn.big { padding: 10px 13px; font-size: 14px; }
  .song-body { margin-left: 0; }
}
.slot-row { display: grid; grid-template-columns: 1fr 1fr 1.2fr auto; gap: 8px; margin-bottom: 8px; }
@media (max-width: 640px) { .slot-row { grid-template-columns: 1fr 1fr; padding-bottom: 8px; border-bottom: 1px solid var(--line); } }
