:root {
  color-scheme: dark;
  --bg: #000612;
  --nav: #111f73;
  --nav-2: #071039;
  --accent: #4f6bff;
  --accent-soft: #7f91ff;
  --panel: #071033;
  --panel-soft: rgba(7, 16, 51, .82);
  --line: rgba(255,255,255,.16);
  --text: #fffaf0;
  --muted: rgba(255,250,240,.66);
  --ok: #8bd9c6;
  --warn: #d7c37b;
  --hot: #d98698;
  --shadow: 0 24px 70px rgba(0,0,0,.38);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  overflow-x: clip;
  background:
    radial-gradient(circle at 50% 0, rgba(72, 59, 135, .26), transparent 34rem),
    linear-gradient(180deg, #02091f 0%, var(--bg) 62%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  letter-spacing: 0;
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .45; cursor: not-allowed; }

.app-splash {
  position: fixed;
  inset: 0;
  z-index: 999;
  padding: calc(20px + env(safe-area-inset-top)) 20px calc(20px + env(safe-area-inset-bottom));
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 12px;
  background:
    radial-gradient(circle at 50% 24%, rgba(79,107,255,.28), transparent 22rem),
    linear-gradient(180deg, #071039, #000612);
  color: var(--text);
  transition: opacity .36s ease, visibility .36s ease;
}

.app-splash.hide {
  opacity: 0;
  visibility: hidden;
}

.splash-mark {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  background: var(--text);
  color: var(--bg);
  font-size: 25px;
  font-weight: 1000;
}

.app-splash strong {
  margin-top: 10px;
  font-size: clamp(34px, 10vw, 54px);
  line-height: .9;
  text-transform: uppercase;
}

.app-splash span {
  color: var(--muted);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 1000;
}

.app-splash i {
  width: 140px;
  height: 3px;
  margin-top: 14px;
  overflow: hidden;
  background: rgba(255,255,255,.14);
}

.app-splash i::after {
  content: "";
  width: 46px;
  height: 100%;
  display: block;
  background: var(--accent-soft);
  animation: splashLoad 1s ease-in-out infinite;
}

@keyframes splashLoad {
  0% { transform: translateX(-46px); }
  100% { transform: translateX(140px); }
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 90;
  padding: calc(24px + env(safe-area-inset-top)) 24px calc(24px + env(safe-area-inset-bottom));
  display: grid;
  place-items: center;
  overflow: auto;
  background:
    radial-gradient(circle at 50% 10%, rgba(79,107,255,.24), transparent 28rem),
    linear-gradient(180deg, #071039, #000612);
}

.auth-card {
  width: min(860px, 100%);
  padding: 26px;
  display: grid;
  grid-template-columns: minmax(260px, .9fr) minmax(340px, 1fr);
  gap: 22px;
  align-items: stretch;
  border: 1px solid var(--line);
  background: rgba(7, 16, 51, .84);
  box-shadow: var(--shadow);
}

.auth-card h1,
.auth-card h2,
.auth-card p {
  margin: 0;
}

.auth-card h1 {
  margin-top: 16px;
  font-size: clamp(38px, 5vw, 58px);
  line-height: .9;
  text-transform: uppercase;
}

.auth-card > div > p:last-child {
  margin-top: 18px;
  color: var(--muted);
  line-height: 1.45;
}

.auth-panel {
  min-width: 0;
  display: grid;
}

.auth-form {
  min-width: 0;
  padding: 18px;
  display: grid;
  gap: 12px;
  align-content: start;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.14);
}

.auth-form[hidden] {
  display: none;
}

.auth-form h2 {
  text-transform: uppercase;
  font-size: 24px;
}

.auth-form label {
  display: grid;
  gap: 6px;
}

.auth-form label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.auth-form input {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: #000a2e;
  color: var(--text);
}

.auth-switch {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.auth-switch button {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent-soft);
  font: inherit;
  font-weight: 1000;
  text-transform: uppercase;
  cursor: pointer;
}

.auth-message {
  grid-column: 1 / -1;
  min-height: 20px;
  color: var(--hot);
  font-weight: 900;
}

.app-shell {
  min-height: 100vh;
  width: 100%;
  overflow-x: clip;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  transition: grid-template-columns .18s ease;
}

body.sidebar-collapsed .app-shell {
  grid-template-columns: 82px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 30;
  height: 100vh;
  padding: 22px 16px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  background: linear-gradient(180deg, var(--nav), var(--nav-2));
  border-right: 1px solid rgba(255,255,255,.18);
  transition: padding .18s ease;
}

.sidebar-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.menu-close {
  width: 42px;
  height: 42px;
  display: none;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  background: rgba(0,0,0,.18);
  color: var(--text);
  font-size: 28px;
  line-height: 1;
  font-weight: 800;
}

.brand {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0;
  background: transparent;
  border: 0;
  color: var(--text);
  text-align: left;
}

.brand::after,
.nav-item::after {
  content: attr(data-label);
  position: absolute;
  left: calc(100% + 12px);
  top: 50%;
  z-index: 60;
  min-width: max-content;
  padding: 9px 12px;
  transform: translateY(-50%) translateX(-6px);
  opacity: 0;
  pointer-events: none;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(7, 16, 51, .96);
  color: var(--text);
  box-shadow: var(--shadow);
  text-transform: none;
  font-size: 13px;
  font-weight: 900;
  transition: opacity .16s ease, transform .16s ease;
}

.brand-mark {
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  background: var(--text);
  color: var(--bg);
  border-radius: 4px;
  font-weight: 1000;
}

.brand strong {
  display: block;
  font-size: 30px;
  line-height: .9;
  font-weight: 1000;
  text-transform: uppercase;
}

.brand small {
  display: block;
  color: rgba(255,255,255,.72);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.nav {
  display: grid;
  gap: 6px;
}

.nav-item {
  position: relative;
  min-height: 44px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
  text-transform: uppercase;
  font-size: 13px;
  font-weight: 1000;
}

.nav-item span {
  width: 22px;
  text-align: center;
}

.nav-item b {
  font: inherit;
}

.nav-item:hover,
.nav-item.active {
  border-color: rgba(255,255,255,.26);
  background: rgba(0,0,0,.2);
}

.sidebar-toggle {
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  background: #000a2e;
  color: var(--text);
}

.sidebar-toggle svg {
  width: 22px;
  height: 22px;
}

body.sidebar-collapsed .sidebar {
  padding: 22px 12px;
  align-items: center;
}

body.sidebar-collapsed .brand {
  width: 54px;
  justify-content: center;
}

body.sidebar-collapsed .brand-copy,
body.sidebar-collapsed .menu-close,
body.sidebar-collapsed .nav-item b,
body.sidebar-collapsed .user-chip,
body.sidebar-collapsed .sidebar-actions {
  display: none;
}

body.sidebar-collapsed .nav-item {
  width: 54px;
  justify-content: center;
  padding: 10px;
}

body.sidebar-collapsed .brand:hover::after,
body.sidebar-collapsed .nav-item:hover::after {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

.sidebar-actions {
  margin-top: auto;
  display: grid;
  gap: 8px;
}

.user-chip {
  min-width: 0;
  padding: 10px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(0,0,0,.16);
}

.user-chip span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: var(--text);
  color: var(--bg);
  font-weight: 1000;
}

.user-chip strong,
.user-chip small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-chip strong {
  font-size: 14px;
}

.user-chip small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.install-button,
.tour-button,
.primary,
.ghost,
.danger,
.pill-button {
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 0;
  color: var(--text);
  background: transparent;
  text-transform: uppercase;
  font-weight: 1000;
  font-size: 13px;
}

.primary,
.install-button {
  background: var(--accent);
  border-color: var(--accent);
}

.install-button {
  width: 100%;
  text-align: center;
}

.tour-button {
  background: rgba(0,0,0,.18);
  border-color: rgba(255,255,255,.26);
}

.danger {
  background: rgba(217,134,152,.18);
  border-color: rgba(217,134,152,.45);
}

.settle-button {
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid #ff4964;
  border-radius: 0;
  background: #ff2d55;
  color: #fffaf0;
  text-transform: uppercase;
  font-weight: 1000;
  font-size: 13px;
  box-shadow: 0 0 0 1px rgba(255,255,255,.08) inset;
}

.settle-button:hover {
  background: #ff4964;
}

.small {
  min-height: 34px;
  padding: 7px 10px;
  font-size: 12px;
}

.icon-danger {
  width: 36px;
  min-width: 36px;
  padding: 0;
  display: inline-grid;
  place-items: center;
}

.icon-danger svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: square;
  stroke-linejoin: miter;
}

.main {
  min-width: 0;
  padding: 0 0 120px;
}

.topbar {
  min-height: 110px;
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.topbar h1 {
  margin: 0;
  max-width: min(900px, 58vw);
  font-size: clamp(32px, 4vw, 58px);
  line-height: .95;
  text-transform: uppercase;
  font-weight: 1000;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 1000;
}

small,
.muted {
  color: var(--muted);
}

.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;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.search,
.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #000a2e;
  color: var(--text);
  outline: none;
}

.search {
  width: min(32vw, 380px);
}

.mobile-song-search {
  display: none;
}

.icon-button,
.mobile-menu {
  width: 46px;
  height: 46px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #000a2e;
  color: var(--text);
}

.mobile-menu {
  display: none;
}

.view {
  display: grid;
  gap: 40px;
}

.today-stage {
  margin: 0 32px;
  min-height: 260px;
  padding: 24px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  background:
    linear-gradient(90deg, rgba(0,6,18,.08), rgba(0,6,18,.84)),
    radial-gradient(circle at 28% 35%, rgba(255,255,255,.14), transparent 16rem),
    repeating-linear-gradient(0deg, rgba(255,255,255,.035), rgba(255,255,255,.035) 1px, transparent 1px, transparent 6px),
    linear-gradient(118deg, #182759, #050b25 62%, #020411);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.today-stage h2 {
  max-width: 760px;
  margin: 8px 0 10px;
  font-size: clamp(32px, 4.5vw, 62px);
  line-height: .96;
  text-transform: uppercase;
  font-weight: 1000;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.today-stage p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.stage-kicker {
  color: var(--ok);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 1000;
}

.event-strip,
.queue-strip {
  display: grid;
  gap: 14px;
  padding: 0 32px;
}

.event-strip-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.event-strip-item {
  min-height: 116px;
  padding: 14px;
  display: grid;
  align-content: space-between;
  gap: 8px;
  background: rgba(7, 16, 51, .68);
  border: 1px solid var(--line);
}

.event-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.event-strip-item strong {
  font-size: 18px;
  text-transform: none;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
}

.view > .section-head {
  padding: 0 32px;
}

.view > .section-head.page-actions {
  justify-content: flex-end;
  margin-top: -14px;
}

.view > .section-head.page-actions > .primary,
.view > .section-head.page-actions > .ghost,
.view > .section-head.page-actions > .card-actions {
  margin-left: auto;
}

.section-head h2,
.panel h2,
.panel h3 {
  margin: 0;
  line-height: .95;
  text-transform: uppercase;
  font-weight: 1000;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.panel > .section-head {
  margin-bottom: 22px;
}

.panel > .section-head h2 {
  max-width: 14ch;
  font-size: clamp(24px, 2.7vw, 38px);
}

.panel > .section-head > :last-child {
  flex-shrink: 0;
  margin-top: 2px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
  padding: 0 32px;
}

.panel .grid {
  padding: 0;
}

.span-3 { grid-column: span 3; }
.span-4 { grid-column: span 4; }
.span-5 { grid-column: span 5; }
.span-6 { grid-column: span 6; }
.span-7 { grid-column: span 7; }
.span-8 { grid-column: span 8; }
.span-12 { grid-column: span 12; }

.panel,
.item-card,
.metric,
.table-wrap {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 0;
  box-shadow: var(--shadow);
}

.panel,
.metric {
  padding: 22px;
}

.metric {
  min-height: 132px;
  border-top: 5px solid var(--accent-soft);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.metric strong {
  display: block;
  margin-top: 14px;
  font-size: clamp(24px, 2.7vw, 34px);
  line-height: .95;
  font-weight: 1000;
  overflow-wrap: anywhere;
}

.metric strong.negative {
  color: #ff7f96;
}

.metric strong.positive {
  color: var(--text);
}

.metric:hover {
  border-color: rgba(255,250,240,.42);
}

.metric.green { border-top-color: var(--ok); }
.metric.pink { border-top-color: var(--hot); }
.metric.yellow { border-top-color: var(--warn); }
.metric.blue { border-top-color: var(--accent-soft); }

.list {
  display: grid;
  gap: 14px;
}

.item-card {
  padding: 18px;
  display: grid;
  gap: 12px;
}

.item-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.card-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

.track-actions {
  grid-column: 1 / -1;
  justify-content: flex-start;
}

.strip-actions {
  justify-content: flex-start;
  margin-top: 10px;
}

.table-actions {
  justify-content: flex-start;
  min-width: 0;
}

.finance-subhead {
  margin-bottom: 14px;
}

.member-balance-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.member-balance {
  min-width: 0;
  padding: 14px;
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  background: rgba(0,0,0,.18);
}

.member-balance > div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.member-balance strong,
.member-balance small {
  display: block;
}

.member-balance small {
  color: var(--muted);
  font-weight: 800;
}

.member-balance.gets {
  border-color: rgba(139,217,198,.34);
  background: linear-gradient(145deg, rgba(139,217,198,.12), rgba(0,0,0,.14));
}

.member-balance.owes {
  border-color: rgba(255,73,100,.34);
  background: linear-gradient(145deg, rgba(255,73,100,.1), rgba(0,0,0,.14));
}

.member-balance.even {
  border-color: rgba(255,255,255,.14);
}

.balance-total {
  color: var(--text);
  font-size: 24px;
  line-height: 1;
}

.member-balance.gets .balance-total {
  color: var(--ok);
}

.member-balance.owes .balance-total {
  color: #ff8398;
}

.member-balance dl {
  margin: 0;
  display: grid;
  gap: 6px;
}

.member-balance dl div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.member-balance dt,
.member-balance dd {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.finance-toolbar {
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid var(--line);
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-tabs button {
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.filter-tabs button.active {
  background: var(--text);
  border-color: var(--text);
  color: var(--bg);
}

.planning-toolbar {
  margin-bottom: 14px;
  padding: 14px 16px;
  display: grid;
  grid-template-columns: minmax(150px, 250px) minmax(280px, 420px);
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(18, 35, 89, .66), rgba(7, 16, 51, .38));
}

.planning-toolbar-head {
  display: grid;
  gap: 4px;
}

.planning-toolbar strong {
  font-size: 17px;
}

.planning-toolbar small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.planning-filter-row {
  display: none;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 9px 12px;
  align-items: center;
}

.planning-filter-row > span {
  color: var(--ok);
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 1000;
  letter-spacing: .04em;
}

.planning-toolbar .filter-tabs {
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: thin;
  padding-bottom: 2px;
}

.planning-toolbar .filter-tabs button {
  min-height: 34px;
  white-space: nowrap;
  background: rgba(255,255,255,.025);
}

.planning-toolbar .filter-tabs button.active {
  box-shadow: 0 0 0 1px rgba(255,250,240,.18);
}

.planning-filter-selects {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.planning-filter-selects label {
  display: grid;
  gap: 6px;
}

.planning-filter-selects span {
  color: var(--ok);
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 1000;
  letter-spacing: .04em;
}

.planning-filter-selects select {
  width: 100%;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  background: #000a2e;
  color: var(--text);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 1000;
}

.planning-list {
  gap: 10px;
}

.planning-pagination {
  margin-top: 14px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.planning-pagination > div {
  display: flex;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.planning-pagination button {
  min-height: 34px;
  padding: 6px 11px;
  border: 1px solid var(--line);
  background: rgba(7, 16, 51, .7);
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.planning-pagination button.active {
  background: var(--text);
  border-color: var(--text);
  color: var(--bg);
}

.planning-pagination button:disabled {
  opacity: .35;
  cursor: not-allowed;
}

.segmented-control {
  display: inline-flex;
  border: 1px solid var(--line);
  background: rgba(0,0,0,.16);
}

.segmented-control button {
  min-height: 38px;
  padding: 8px 14px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.segmented-control button:last-child {
  border-right: 0;
}

.segmented-control button.active {
  background: var(--text);
  color: var(--bg);
}

.settlement-list {
  gap: 10px;
}

.settlement-card {
  padding: 14px;
  display: grid;
  gap: 8px;
  border: 1px solid rgba(255,73,100,.3);
  background: rgba(255,73,100,.08);
}

.settlement-card strong {
  font-size: 16px;
}

.settlement-card span {
  color: #ffb3c0;
  font-size: 20px;
  font-weight: 1000;
}

.event-main {
  min-width: 0;
  display: grid;
  gap: 12px;
}

.event-card {
  padding: 16px 18px;
}

.event-card > .item-row {
  align-items: flex-start;
}

.event-card .card-actions {
  min-width: 270px;
  align-items: flex-start;
}

.event-card .status {
  min-height: 30px;
}

.event-card .ghost.small,
.event-card .icon-danger {
  min-height: 38px;
}

.deadline-chip {
  min-height: 30px;
  padding: 5px 9px;
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border: 1px solid rgba(127,145,255,.22);
  background: rgba(127,145,255,.1);
  color: var(--muted);
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 1000;
}

.calendar-head {
  margin-bottom: 18px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-end;
}

.calendar-head h2 {
  margin: 4px 0 0;
  font-size: clamp(24px, 2.6vw, 36px);
  line-height: 1;
  text-transform: uppercase;
}

.calendar-head small {
  color: var(--muted);
  font-weight: 900;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.calendar-weekday,
.calendar-cell {
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.calendar-weekday {
  min-height: 34px;
  display: grid;
  place-items: center;
  color: var(--muted);
  background: rgba(0,0,0,.16);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.calendar-cell {
  min-height: 116px;
  padding: 9px;
  display: grid;
  align-content: start;
  gap: 8px;
  background: rgba(255,255,255,.018);
}

.calendar-cell.empty-cell {
  background: rgba(0,0,0,.12);
}

.calendar-cell > strong {
  color: rgba(255,250,240,.86);
  font-size: 13px;
}

.calendar-cell > div {
  display: grid;
  gap: 5px;
}

.calendar-event {
  min-height: 25px;
  padding: 5px 7px;
  border: 0;
  color: #00140f;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: left;
  font-size: 11px;
  font-weight: 1000;
}

.calendar-event.live { background: var(--ok); }
.calendar-event.recording { background: var(--hot); color: #18080c; }
.calendar-event.rehearsing { background: var(--warn); color: #161200; }
.calendar-event.meeting { background: rgba(255,255,255,.18); color: var(--text); }
.calendar-event.deadline { background: var(--accent-soft); color: #090a24; }

.calendar-mobile-list {
  display: none;
}

.calendar-mobile-item {
  width: 100%;
  padding: 12px;
  display: grid;
  gap: 6px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(7, 16, 51, .68);
  color: var(--text);
  text-align: left;
}

.calendar-mobile-item strong {
  font-size: 16px;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.calendar-mobile-item small {
  line-height: 1.35;
}

.event-title-line {
  display: grid;
  gap: 5px;
}

.event-title-line strong {
  font-size: 18px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.event-title-line small {
  line-height: 1.35;
}

.event-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.attendance-pill {
  min-height: 30px;
  padding: 4px 9px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  background: rgba(139,217,198,.075);
  border: 1px solid rgba(139,217,198,.2);
  color: var(--text);
  font-size: 11px;
  font-weight: 900;
  font-family: inherit;
  cursor: pointer;
}

.attendance-pill:hover,
.attendance-pill:focus-visible {
  border-color: rgba(139,217,198,.55);
  background: rgba(139,217,198,.14);
}

.attendance-icon {
  position: relative;
  width: 14px;
  height: 14px;
  border: 2px solid var(--ok);
  border-radius: 999px;
}

.attendance-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -6px;
  width: 17px;
  height: 9px;
  transform: translateX(-50%);
  border: 2px solid var(--ok);
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
}

.attendance-pill strong {
  font-size: 13px;
}

.attendance-pill small {
  color: var(--muted);
  white-space: nowrap;
}

.attendance-card {
  padding: 14px;
  display: grid;
  gap: 12px;
  border: 1px solid rgba(139,217,198,.24);
  background: linear-gradient(145deg, rgba(139,217,198,.1), rgba(0,0,0,.14));
}

.attendance-card strong,
.attendance-card small {
  display: block;
}

.attendance-overview {
  display: grid;
  gap: 16px;
}

.attendance-overview-head {
  display: grid;
  gap: 4px;
}

.attendance-overview-head strong {
  font-size: 22px;
  color: var(--text);
}

.attendance-overview-head small {
  color: var(--muted);
}

.attendance-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.attendance-group {
  border: 1px solid var(--line);
  background: rgba(4,13,42,.62);
  padding: 14px;
  display: grid;
  gap: 12px;
}

.attendance-group h3 {
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 15px;
  color: var(--text);
}

.attendance-group h3 span {
  min-width: 28px;
  min-height: 28px;
  display: inline-grid;
  place-items: center;
  background: rgba(255,255,255,.08);
  color: var(--text);
}

.attendance-group > div {
  display: grid;
  gap: 8px;
}

.attendance-group article {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.attendance-group article > span {
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,.08);
  color: var(--text);
  font-weight: 1000;
  text-transform: uppercase;
}

.attendance-group article strong,
.attendance-group article small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.attendance-group article strong {
  color: var(--text);
}

.attendance-group article small,
.attendance-group p {
  margin: 0;
  color: var(--muted);
}

.attendance-group.yes h3 span {
  background: rgba(139,217,198,.18);
  color: var(--ok);
}

.attendance-group.maybe h3 span {
  background: rgba(222,203,115,.2);
  color: var(--yellow);
}

.attendance-group.no h3 span {
  background: rgba(217,134,152,.18);
  color: var(--pink);
}

.print-preview-modal {
  width: min(980px, 100%);
}

.print-preview-doc {
  background:
    linear-gradient(90deg, rgba(139,217,198,.08), transparent 44%),
    var(--panel);
  color: var(--text);
  max-height: min(68vh, 760px);
  overflow: auto;
}

.print-preview-doc .print-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 42px;
  border: 1px solid var(--line);
  background:
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(135deg, rgba(139,217,198,.1), rgba(82,108,255,.04) 45%, transparent),
    #0a1230;
  background-size: 26px 26px, 26px 26px, auto, auto;
  color: var(--text);
}

.print-preview-doc .print-page header {
  border-bottom: 2px solid rgba(255,255,255,.18);
  margin-bottom: 30px;
  padding-bottom: 22px;
}

.print-preview-doc .print-page p {
  margin: 0 0 10px;
}

.print-preview-doc .print-page header p {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.print-preview-doc .print-page h1 {
  margin: 0;
  font-size: 58px;
  line-height: .92;
  text-transform: uppercase;
}

.print-preview-doc .print-page header span {
  display: block;
  margin-top: 14px;
  color: var(--muted);
  font-size: 18px;
}

.print-preview-doc .lyrics-lines {
  font-size: 22px;
  line-height: 1.5;
}

.print-preview-doc .lyrics-lines h3 {
  margin: 28px 0 8px;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--ok);
}

.print-preview-doc .lyrics-lines p {
  white-space: pre-wrap;
}

.print-preview-doc .setlist-print ol {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 16px;
}

.print-preview-doc .setlist-print li {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  border-bottom: 1px solid #cfc7ba;
  padding: 0 0 12px;
  font-size: 34px;
  font-weight: 900;
}

.print-preview-doc .setlist-print li span {
  color: #777;
  font-size: 18px;
}

.print-preview-doc .setlist-print footer {
  margin-top: 34px;
  font-size: 20px;
}

.attendance-card strong {
  font-size: 17px;
  line-height: 1.15;
}

.attendance-card small {
  margin-top: 5px;
  color: var(--muted);
}

.attendance-choice {
  display: grid;
  grid-template-columns: 1fr 1.45fr 1fr;
  gap: 6px;
}

.attendance-choice.compact {
  width: min(100%, 260px);
}

.attendance-choice button {
  min-height: 34px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  background: rgba(0,0,0,.18);
  color: var(--text);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.attendance-choice button.active,
.attendance-choice button:hover {
  background: var(--ok);
  border-color: var(--ok);
  color: #00140f;
}

.my-attendance {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 10px;
}

.my-attendance > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.availability-button {
  width: fit-content;
  min-height: 30px;
  padding: 4px 9px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(255,255,255,.13);
  background: rgba(255,255,255,.035);
  color: var(--muted);
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 1000;
}

.availability-button span {
  color: var(--muted);
}

.availability-button strong {
  color: var(--ok);
  font-size: 11px;
}

.attendance-modal {
  display: grid;
  gap: 12px;
}

.attendance-modal strong,
.attendance-modal small {
  display: block;
}

.attendance-modal small {
  color: var(--muted);
}

.modal-choice {
  margin-top: 6px;
}

.inbox-fab {
  position: fixed;
  right: 22px;
  bottom: 92px;
  z-index: 22;
  width: 48px;
  height: 48px;
  min-height: 0;
  padding: 0;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  border: 1px solid rgba(255,255,255,.2);
  background: rgba(0,10,46,.82);
  color: var(--text);
  box-shadow: 0 16px 46px rgba(0,0,0,.34);
  backdrop-filter: blur(16px);
}

.inbox-fab span {
  font-size: 18px;
  line-height: 1;
}

.inbox-fab:focus-visible {
  outline: 2px solid var(--ok);
  outline-offset: 3px;
}

.inbox-fab strong {
  position: absolute;
  top: -9px;
  right: -9px;
  min-width: 24px;
  height: 24px;
  padding: 0 6px;
  display: inline-grid;
  place-items: center;
  background: var(--ok);
  border: 2px solid var(--bg);
  color: #00140f;
  font-size: 12px;
  font-weight: 1000;
}

.update-banner {
  position: fixed;
  left: 50%;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 92;
  width: min(520px, calc(100vw - 32px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(139,217,198,.42);
  background:
    linear-gradient(90deg, rgba(139,217,198,.16), rgba(78,107,255,.12)),
    rgba(6, 14, 43, .96);
  box-shadow: 0 24px 80px rgba(0,0,0,.55);
}

.update-banner strong {
  display: block;
  color: var(--text);
  font-size: 17px;
  line-height: 1.1;
}

.update-banner small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-weight: 800;
  line-height: 1.35;
}

.update-banner button:disabled {
  opacity: .72;
  cursor: wait;
}

.install-help {
  display: grid;
  gap: 14px;
}

.install-help > strong {
  color: var(--text);
  font-size: 22px;
  line-height: 1.1;
}

.install-help ol {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  list-style: none;
  counter-reset: install-steps;
}

.install-help li {
  counter-increment: install-steps;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: var(--text);
  font-weight: 850;
  line-height: 1.35;
}

.install-help li::before {
  content: counter(install-steps);
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  background: rgba(139,217,198,.16);
  border: 1px solid rgba(139,217,198,.38);
  color: var(--ok);
  font-size: 13px;
  font-weight: 1000;
}

.install-help p {
  margin: 0;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(0,0,0,.16);
  color: var(--muted);
  font-weight: 750;
  line-height: 1.45;
}

.panel > .item-row:first-child {
  align-items: flex-start;
  margin-bottom: 8px;
}

.panel > .item-row:first-child h2 {
  font-size: clamp(26px, 2.9vw, 40px);
  line-height: .98;
  overflow-wrap: anywhere;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.chip,
.status {
  min-height: 26px;
  padding: 4px 8px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255,255,255,.09);
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.status.live { color: #00140f; background: var(--ok); }
.status.recording { color: #18080c; background: var(--hot); }
.status.rehearsing { color: #161200; background: var(--warn); }
.status.writing { color: #090a24; background: var(--accent-soft); }
.status.meeting { color: var(--text); background: rgba(255,255,255,.14); }
.status.deadline { color: #090a24; background: var(--accent-soft); }

.event-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.event-tile {
  min-height: 300px;
  display: grid;
  align-content: end;
  gap: 10px;
}

.event-art {
  min-height: 180px;
  background:
    linear-gradient(140deg, rgba(79,107,255,.25), rgba(139,217,198,.12)),
    repeating-linear-gradient(90deg, rgba(255,255,255,.08), rgba(255,255,255,.08) 1px, transparent 1px, transparent 9px),
    #18214d;
}

.event-tile h3 {
  margin: 0;
  font-size: clamp(20px, 1.7vw, 26px);
  line-height: 1.04;
  text-transform: uppercase;
  font-weight: 1000;
  overflow-wrap: anywhere;
}

.setlist-grid {
  padding: 0 32px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 18px;
}

.setlist-card {
  min-height: 280px;
  padding: 22px;
  display: grid;
  align-content: start;
  gap: 18px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.setlist-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.setlist-card h2 {
  margin: 0;
  max-width: 18ch;
  font-size: clamp(26px, 2.8vw, 42px);
  line-height: 1;
  text-transform: uppercase;
  font-weight: 1000;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.setlist-songs {
  margin: 0;
  padding-left: 24px;
  color: rgba(255,250,240,.92);
  font-size: 16px;
  line-height: 1.45;
}

.setlist-card p {
  margin: 0;
  font-size: 16px;
  line-height: 1.4;
}

.song-layout {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  padding: 0 32px;
}

.song-list {
  display: grid;
  gap: 18px;
  align-self: start;
  height: fit-content;
}

.song-queue-panel {
  grid-column: 1 / -1;
}

.song-list-items {
  display: grid;
  gap: 10px;
}

.song-pagination {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 42px;
  gap: 8px;
  align-items: center;
}

.song-pagination > div {
  display: flex;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.song-pagination button {
  min-width: 34px;
  min-height: 34px;
  padding: 6px 9px;
  border: 1px solid var(--line);
  background: rgba(7, 16, 51, .7);
  color: var(--muted);
  font-size: 13px;
  font-weight: 1000;
}

.song-pagination button.active {
  background: var(--text);
  border-color: var(--text);
  color: var(--bg);
}

.song-detail-panel {
  padding: 28px;
  min-width: 0;
}

.song-detail-panel > .item-row,
.song-detail-head {
  gap: 16px;
  align-items: flex-start;
}

.song-detail-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.song-detail-panel > .item-row h2,
.song-detail-head h2 {
  margin: 0;
  max-width: 18ch;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.song-button {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 0;
  background: rgba(7, 16, 51, .62);
  color: var(--text);
  text-align: left;
}

.song-button.active {
  border-color: rgba(255,250,240,.82);
  background:
    linear-gradient(90deg, rgba(139,217,198,.1), transparent 56%),
    #000a2e;
}

.song-button strong,
.queue-card strong {
  font-size: 18px;
  overflow-wrap: anywhere;
}

.queue-panel {
  padding: 14px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.035);
}

.queue-panel .section-head {
  margin: 0 0 10px;
  padding: 0;
  display: flex;
  align-items: center;
}

.queue-panel .section-head h2 {
  font-size: 18px;
}

.song-tab-surface {
  min-width: 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.1);
}

.song-module-nav {
  margin: 24px 0 0;
  padding: 6px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.14);
}

.song-module-tab {
  min-height: 44px;
  padding: 10px 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.song-module-tab:hover {
  border-color: rgba(255,255,255,.16);
  color: var(--text);
}

.song-module-tab.active {
  background: var(--text);
  border-color: var(--text);
  color: var(--bg);
}

.song-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.song-overview-card,
.song-overview-wide {
  min-width: 0;
  padding: 18px;
  background: rgba(0,0,0,.12);
}

.song-overview-card {
  display: grid;
  align-content: start;
  gap: 14px;
}

.song-overview-card h3 {
  margin: 0;
  font-size: clamp(19px, 1.8vw, 26px);
  line-height: 1.06;
}

.song-overview-card p {
  max-width: 34ch;
  margin: 0;
  font-size: clamp(15px, 1.35vw, 19px);
  line-height: 1.4;
}

.song-overview-wide {
  grid-column: 1 / -1;
}

.multitrack-session {
  margin-top: 8px;
  display: grid;
  gap: 14px;
  overflow: visible;
}

.multitrack-unavailable {
  min-height: 260px;
  padding: 28px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  text-align: center;
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(79,107,255,.13), transparent 52%),
    rgba(7, 16, 51, .74);
}

.multitrack-unavailable span {
  width: 58px;
  height: 58px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.05);
  color: var(--accent-soft);
  font-size: 28px;
}

.multitrack-unavailable h3 {
  margin: 0;
  max-width: 13ch;
  font-size: clamp(28px, 7vw, 44px);
  line-height: .95;
  text-transform: uppercase;
}

.multitrack-unavailable p {
  max-width: 46ch;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.45;
}

.session-transport {
  padding: 12px;
  display: grid;
  grid-template-columns: 42px 42px 42px 54px minmax(160px, 1fr) 54px minmax(190px, 240px);
  gap: 10px;
  align-items: center;
  background: rgba(0,0,0,.18);
}

.master-volume {
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(90px, 1fr) 42px;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 1000;
}

.master-volume input {
  width: 100%;
  accent-color: var(--accent-soft);
}

.master-volume strong {
  color: var(--text);
  text-align: right;
}

.mix-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mix-tools .disabled-tool {
  opacity: .45;
}

.transport-play,
.transport-pause,
.transport-stop {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.2);
  background: rgba(79,107,255,.24);
  color: var(--text);
  font-size: 17px;
}

.transport-pause {
  background: rgba(255,255,255,.08);
}

.transport-stop {
  background: rgba(255,255,255,.04);
}

.session-progress {
  height: 8px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.12);
  cursor: pointer;
}

.session-progress span {
  width: 0%;
  height: 100%;
  display: block;
  background: var(--accent-soft);
}

.session-tabs {
  margin: 4px 0;
  display: flex;
  gap: 10px;
}

.session-tabs button {
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--muted);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 1000;
}

.session-tabs button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--text);
}

.session-track-list {
  display: grid;
  gap: 12px;
}

.session-track {
  padding: 16px;
  display: grid;
  grid-template-columns: minmax(150px, 210px) minmax(0, 1fr);
  gap: 14px 18px;
  align-items: center;
  background: rgba(7, 16, 51, .62);
}

.session-track-head {
  min-width: 0;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.drag-dots {
  color: var(--muted);
  font-size: 20px;
  letter-spacing: -4px;
}

.session-track-name {
  min-width: 0;
}

.session-track-name small {
  display: block;
}

.track-inline-name,
.track-inline-meta select {
  width: 100%;
  min-height: 34px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.16);
  color: var(--text);
  font-weight: 900;
}

.track-inline-name {
  padding: 6px 8px;
  font-size: clamp(17px, 1.6vw, 23px);
}

.track-inline-meta {
  margin-top: 8px;
  display: grid;
  grid-template-columns: minmax(78px, 100px) minmax(0, 1fr);
  gap: 7px;
  align-items: center;
}

.track-inline-meta select {
  padding: 5px 7px;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
}

.session-track-name small {
  color: var(--muted);
  line-height: 1.25;
}

.track-offset {
  display: inline-block;
  padding: 3px 6px;
  border: 1px solid rgba(255,255,255,.14);
  color: var(--ok);
  font-size: 11px;
  font-weight: 900;
}

.waveform {
  --playhead: 0%;
  position: relative;
  min-height: 72px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  gap: 2px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(255,73,100,.78) 2px, transparent 2px),
    rgba(255,255,255,.035);
  cursor: pointer;
}

.waveform::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--playhead);
  background: linear-gradient(90deg, rgba(139,217,198,.28), rgba(79,107,255,.18));
  pointer-events: none;
}

.waveform::after {
  content: "";
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: var(--playhead);
  width: 2px;
  background: rgba(139,217,198,.95);
  box-shadow: 0 0 16px rgba(139,217,198,.45);
  pointer-events: none;
}

.waveform span {
  position: relative;
  z-index: 1;
  width: 3px;
  min-width: 3px;
  display: block;
  background: rgba(255,255,255,.32);
}

.waveform span.gap {
  margin-left: 14px;
}

.waveform.loaded {
  background: linear-gradient(90deg, rgba(255,73,100,.75) 2px, transparent 2px), rgba(139,217,198,.045);
}

.waveform.unavailable {
  opacity: .45;
  cursor: not-allowed;
}

.track-mix-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.session-track-controls {
  min-width: 0;
  grid-column: 2;
  display: grid;
  grid-template-columns: 68px 84px minmax(120px, 1fr) 74px 38px;
  gap: 10px;
  align-items: center;
}

.track-order-controls {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

.track-order-controls button {
  min-height: 32px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.05);
  color: var(--text);
  font-size: 14px;
  font-weight: 1000;
}

.track-order-controls button:disabled {
  opacity: .28;
}

.mix-button {
  width: 38px;
  height: 38px;
  border: 0;
  background: rgba(255,255,255,.11);
  color: var(--text);
  font-weight: 1000;
}

.mix-button.active.mute {
  background: var(--hot);
  color: #18080c;
}

.mix-button.active.solo {
  background: var(--ok);
  color: #00140f;
}

.volume-slider {
  width: 100%;
}

.nudge-controls {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

.nudge-controls button {
  min-height: 32px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--text);
  font-size: 11px;
  font-weight: 1000;
}

@media (max-width: 1380px) {
  .song-layout {
    grid-template-columns: minmax(230px, 300px) minmax(0, 1fr);
  }

  .session-track {
    grid-template-columns: minmax(145px, 190px) minmax(0, 1fr);
  }

  .session-track-controls {
    grid-column: 2;
    grid-template-columns: 64px 82px minmax(100px, 1fr) 72px 38px;
  }
}

.mixer-console {
  min-height: 560px;
  padding: 12px;
  display: flex;
  gap: 12px;
  overflow-x: auto;
  border: 1px solid rgba(255,255,255,.1);
  background:
    linear-gradient(180deg, rgba(255,255,255,.045), transparent 34%),
    rgba(0,0,0,.16);
  scroll-snap-type: x proximity;
}

.mixer-channel {
  flex: 0 0 164px;
  min-height: 520px;
  padding: 14px;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  justify-items: stretch;
  gap: 14px;
  border: 1px solid rgba(255,255,255,.12);
  background: linear-gradient(180deg, rgba(7,16,51,.8), rgba(0,0,0,.18));
  text-align: center;
  scroll-snap-align: start;
}

.mixer-channel header {
  min-height: 70px;
  display: grid;
  gap: 5px;
  align-content: start;
}

.mixer-channel header strong,
.mixer-channel small {
  display: block;
}

.mixer-channel header strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 17px;
}

.mixer-channel small,
.mixer-readout small {
  color: var(--muted);
  font-weight: 800;
}

.mixer-strip {
  min-height: 270px;
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 14px;
  justify-items: center;
  align-items: stretch;
}

.level-meter {
  --meter: 0%;
  --peak: 0%;
  position: relative;
  width: 26px;
  min-height: 270px;
  padding: 3px;
  display: flex;
  align-items: flex-end;
  border: 1px solid rgba(255,255,255,.14);
  background:
    linear-gradient(180deg, rgba(217,134,152,.35), rgba(215,195,123,.28) 28%, rgba(139,217,198,.22) 64%, rgba(255,255,255,.08));
}

.level-meter::after {
  content: "";
  position: absolute;
  left: 4px;
  right: 4px;
  bottom: var(--peak);
  height: 2px;
  background: var(--text);
  opacity: .8;
  box-shadow: 0 0 10px rgba(255,250,240,.34);
}

.level-meter span {
  width: 100%;
  height: var(--meter);
  min-height: 2px;
  display: block;
  background: linear-gradient(180deg, #ff8398, var(--warn) 34%, var(--ok));
  box-shadow: 0 0 14px rgba(139,217,198,.32);
}

.mixer-fader {
  width: 48px;
  height: 270px;
  writing-mode: vertical-lr;
  direction: rtl;
  accent-color: var(--accent-soft);
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  cursor: pointer;
}

.mixer-fader::-webkit-slider-runnable-track {
  width: 48px;
  height: 270px;
  border: 1px solid rgba(255,255,255,.14);
  background:
    linear-gradient(90deg, transparent 0 21px, rgba(255,250,240,.28) 21px 23px, transparent 23px),
    repeating-linear-gradient(180deg, rgba(255,250,240,.16) 0 1px, transparent 1px 32px),
    linear-gradient(180deg, rgba(79,107,255,.18), rgba(0,0,0,.2));
}

.mixer-fader::-webkit-slider-thumb {
  width: 44px;
  height: 22px;
  margin-left: 1px;
  border: 1px solid rgba(255,250,240,.58);
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(255,250,240,.22), transparent 48%),
    linear-gradient(90deg, #6178ff, var(--accent-soft));
  box-shadow: 0 10px 24px rgba(0,0,0,.42), 0 0 18px rgba(79,107,255,.24);
  -webkit-appearance: none;
}

.mixer-fader::-moz-range-track {
  width: 48px;
  height: 270px;
  border: 1px solid rgba(255,255,255,.14);
  background:
    linear-gradient(90deg, transparent 0 21px, rgba(255,250,240,.28) 21px 23px, transparent 23px),
    repeating-linear-gradient(180deg, rgba(255,250,240,.16) 0 1px, transparent 1px 32px),
    linear-gradient(180deg, rgba(79,107,255,.18), rgba(0,0,0,.2));
}

.mixer-fader::-moz-range-thumb {
  width: 44px;
  height: 22px;
  border: 1px solid rgba(255,250,240,.58);
  border-radius: 0;
  background: linear-gradient(90deg, #6178ff, var(--accent-soft));
  box-shadow: 0 10px 24px rgba(0,0,0,.42), 0 0 18px rgba(79,107,255,.24);
}

.mixer-readout {
  display: grid;
  gap: 3px;
}

.mixer-readout strong {
  font-size: 20px;
  line-height: 1;
}

.mixer-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.mixer-buttons .mix-button {
  width: 100%;
}

.session-add {
  padding-top: 18px;
  text-align: center;
}

.panel .span-6 {
  min-width: 0;
}

audio {
  width: 100%;
}

.spotify-panel {
  padding: 14px;
  display: grid;
  gap: 10px;
  border: 1px solid var(--line);
  background: rgba(0,0,0,.22);
}

.queue-strip-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}

.queue-card {
  min-height: 92px;
  padding: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  background:
    linear-gradient(90deg, rgba(139,217,198,.08), transparent 42%),
    rgba(7, 16, 51, .7);
  border: 1px solid rgba(255,255,255,.13);
}

.queue-info {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.queue-info small {
  color: var(--ok);
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 1000;
}

.queue-info strong {
  font-size: 18px;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.queue-info span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.queue-actions {
  display: grid;
  grid-template-columns: 72px 36px;
  gap: 8px;
  align-items: center;
}

.queue-play,
.queue-remove {
  min-height: 36px;
  border: 1px solid var(--line);
  color: var(--text);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.queue-play {
  background: var(--accent);
  border-color: var(--accent);
}

.queue-remove {
  padding: 0;
  background: rgba(255,255,255,.04);
  color: var(--muted);
  font-size: 18px;
}

.queue-remove:hover {
  border-color: rgba(217,134,152,.7);
  color: var(--text);
}

.notes-toolbar {
  padding: 0 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.note-tabs {
  display: inline-flex;
  padding: 4px;
  border: 1px solid var(--line);
  background: rgba(7, 16, 51, .72);
  box-shadow: var(--shadow);
}

.note-tabs button {
  min-height: 40px;
  padding: 8px 14px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 0;
  background: transparent;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.note-tabs button.active {
  background: var(--text);
  color: var(--bg);
}

.note-tabs span {
  min-width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  background: rgba(255,255,255,.11);
  color: inherit;
  font-size: 11px;
}

.notes-grid {
  padding: 0 32px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
}

.note-card {
  min-height: 250px;
  padding: 20px;
  display: grid;
  align-content: start;
  gap: 16px;
  background: rgba(7, 16, 51, .76);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.note-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.note-card h2 {
  margin: 0;
  font-size: clamp(21px, 2vw, 30px);
  line-height: 1.06;
  text-transform: none;
  font-weight: 900;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.note-card p {
  max-width: 62ch;
  margin: 0;
  color: rgba(255,250,240,.9);
  font-size: 16px;
  line-height: 1.45;
}

.checklist,
.pick-list {
  display: grid;
  gap: 8px;
}

.check-row,
.pick-row {
  padding: 10px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  background: rgba(0,0,0,.16);
}

.pick-row {
  grid-template-columns: auto 1fr;
}

.check-row.done {
  opacity: .68;
}

.check-row.done strong {
  text-decoration: line-through;
}

.pick-row strong,
.pick-row small {
  display: block;
}

.lyrics-sheet {
  padding: 26px;
  border: 1px solid rgba(255,255,255,.18);
  background:
    linear-gradient(90deg, rgba(255,250,240,.035) 1px, transparent 1px),
    linear-gradient(180deg, rgba(139,217,198,.08), rgba(0,0,0,.08));
  background-size: 28px 28px, auto;
}

.lyrics-sheet header {
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255,255,255,.18);
}

.lyrics-sheet header span {
  color: var(--ok);
  font-size: 12px;
  font-weight: 1000;
  text-transform: uppercase;
}

.lyrics-sheet h2 {
  margin: 8px 0 4px;
  font-size: clamp(32px, 4vw, 58px);
  line-height: .94;
  text-transform: uppercase;
}

.lyrics-sheet header p {
  margin: 0;
  color: var(--muted);
}

.lyrics-lines {
  max-width: 72ch;
}

.lyrics-lines h3 {
  margin: 26px 0 8px;
  color: var(--ok);
  font-size: 13px;
  font-weight: 1000;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.lyrics-lines p {
  margin: 0 0 7px;
  color: rgba(255,250,240,.92);
  font-size: 17px;
  line-height: 1.45;
  white-space: pre-wrap;
}

.lyrics-editor textarea {
  min-height: 260px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  line-height: 1.5;
}

.lyrics-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lyrics-tools button {
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--text);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.lyrics-tools button:hover {
  background: var(--text);
  border-color: var(--text);
  color: var(--bg);
}

.drive-shell {
  margin: 0 32px;
  min-height: 650px;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  padding: 0;
  border: 1px solid var(--line);
  background: var(--panel-soft);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.drive-sidebar {
  padding: 18px;
  display: grid;
  align-content: start;
  gap: 8px;
  border-right: 1px solid var(--line);
  background: rgba(0,0,0,.16);
}

.drive-location {
  width: 100%;
  min-height: 52px;
  padding: 10px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 8px 10px;
  align-items: center;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.drive-location span {
  grid-row: span 2;
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  color: var(--ok);
  font-size: 18px;
}

.drive-location strong,
.drive-location small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.drive-location strong {
  font-size: 14px;
}

.drive-location small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.drive-location.active,
.drive-location:hover {
  border-color: rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
}

.drive-browser {
  min-width: 0;
  padding: 22px;
  display: grid;
  align-content: start;
  gap: 20px;
}

.drive-browser-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
}

.drive-breadcrumb {
  margin-bottom: 10px;
  display: flex;
  gap: 8px;
  align-items: center;
  color: var(--muted);
}

.drive-breadcrumb button {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.drive-breadcrumb button.active {
  color: var(--text);
}

.drive-browser-head h2 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: .98;
  text-transform: uppercase;
}

.drive-browser-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

.drive-view-actions {
  display: flex;
  gap: 8px;
}

.drive-view-actions button {
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.04);
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
}

.drive-view-actions button.active {
  background: var(--text);
  border-color: var(--text);
  color: var(--bg);
}

.drive-quick-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.drive-quick-row article {
  padding: 14px;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(0,0,0,.14);
}

.drive-quick-row span {
  color: var(--ok);
}

.drive-quick-row strong {
  font-size: 24px;
  line-height: 1;
}

.drive-quick-row small {
  color: var(--muted);
  font-weight: 800;
}

.drive-folder-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.drive-card {
  min-height: 126px;
  padding: 14px;
  display: grid;
  align-content: start;
  justify-items: start;
  gap: 8px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.13);
  color: var(--text);
  text-align: left;
}

.drive-card.active,
.drive-card:hover {
  border-color: rgba(139,217,198,.58);
  background: rgba(139,217,198,.1);
}

.drive-card-icon {
  color: var(--ok);
  font-size: 26px;
  line-height: 1;
}

.drive-card.file .drive-card-icon {
  color: var(--hot);
}

.drive-card strong {
  font-size: 15px;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.drive-card small {
  color: var(--muted);
}

.drive-list {
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(0,0,0,.11);
}

.drive-list-head,
.drive-file-row {
  display: grid;
  gap: 12px;
  align-items: center;
}

.drive-list-head {
  grid-template-columns: minmax(220px, 1fr) minmax(120px, 170px) minmax(80px, 110px) minmax(78px, auto);
  padding: 10px 14px 10px 60px;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 1000;
  border-bottom: 1px solid var(--line);
}

.drive-file-row {
  grid-template-columns: 34px minmax(220px, 1fr) minmax(120px, 170px) minmax(80px, 110px) minmax(78px, auto);
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.drive-file-row:last-child {
  border-bottom: 0;
}

.drive-file-icon {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  background: rgba(139,217,198,.12);
  color: var(--ok);
  font-weight: 1000;
}

.drive-file-row strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.drive-file-row small {
  color: var(--muted);
}

.drive-recent {
  display: grid;
  gap: 10px;
}

.drive-recent h3 {
  margin: 0;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 12px;
}

.drive-recent > div {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.drive-recent button {
  min-height: 72px;
  padding: 12px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 2px 10px;
  align-items: center;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.035);
  color: var(--text);
  text-align: left;
}

.drive-recent button span {
  grid-row: span 2;
  color: var(--ok);
}

.drive-recent button strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.drive-recent button small {
  color: var(--muted);
}

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

.transaction-row {
  background: rgba(255,255,255,.015);
  cursor: pointer;
  transition: background .18s ease, box-shadow .18s ease;
}

.transaction-row:hover {
  background: rgba(255,255,255,.045);
}

.transaction-row:focus-visible {
  outline: 2px solid var(--ok);
  outline-offset: -2px;
}

.transaction-row.income {
  background: linear-gradient(90deg, rgba(139,217,198,.08), transparent 34%);
}

.transaction-row.expense {
  background: linear-gradient(90deg, rgba(255,73,100,.07), transparent 34%);
}

th,
td {
  padding: 15px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.amount {
  display: inline-block;
  font-weight: 1000;
  white-space: nowrap;
}

.transaction-date {
  display: inline-block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.amount.income {
  color: var(--ok);
}

.amount.expense {
  color: #ff8398;
}

.money-status {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.1);
  color: var(--muted);
  font-size: 12px;
  font-weight: 1000;
  text-transform: uppercase;
}

.money-status.open {
  background: rgba(255,73,100,.16);
  color: #ffb3c0;
}

.money-status.settled {
  background: rgba(139,217,198,.14);
  color: var(--ok);
}

.payment-request-modal {
  display: grid;
  gap: 14px;
}

.payment-request-modal > strong {
  color: var(--text);
  font-size: 24px;
  line-height: 1.1;
}

.payment-request-modal p,
.payment-request-modal small {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
  line-height: 1.45;
}

.payment-request-modal small {
  padding: 10px;
  border: 1px solid rgba(255,255,255,.14);
  overflow-wrap: anywhere;
}

.payment-request-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.finance-member-checks > div {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.finance-member-checks label {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 10px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.025);
}

.finance-member-checks input {
  width: 17px;
  height: 17px;
  accent-color: var(--ok);
}

.finance-detail {
  display: grid;
  gap: 18px;
}

.finance-detail-hero {
  padding: 18px;
  border: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(139,217,198,.08), rgba(255,255,255,.015));
}

.finance-detail-hero strong {
  display: block;
  margin-top: 6px;
  font-size: clamp(30px, 6vw, 56px);
  line-height: .95;
}

.finance-detail-hero.income strong {
  color: var(--ok);
}

.finance-detail-hero.expense strong {
  color: #ff8398;
}

.finance-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.finance-detail-grid div,
.finance-detail-members {
  padding: 12px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.025);
}

.finance-detail-grid span,
.finance-detail-members span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.finance-detail-grid b,
.finance-detail-members b {
  display: block;
  margin-top: 4px;
  color: var(--text);
}

.finance-detail-members ul {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.finance-detail-members li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.finance-detail-members li:last-child {
  border-bottom: 0;
}

.finance-detail-members em {
  color: var(--muted);
  font-style: normal;
  font-weight: 900;
  text-transform: uppercase;
}

.finance-detail-members li.paid em {
  color: var(--ok);
}

.finance-detail-members li.open em {
  color: #ffb3c0;
}

.field {
  display: grid;
  gap: 6px;
}

.field label,
.field span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.upload-field input[type="file"] {
  min-height: 58px;
  padding: 14px;
  display: block;
  border: 1px dashed rgba(139,217,198,.34);
  background:
    linear-gradient(90deg, rgba(139,217,198,.08), transparent 48%),
    rgba(0,0,0,.16);
  color: var(--muted);
}

.upload-field input[type="file"]::file-selector-button {
  min-height: 34px;
  margin-right: 12px;
  padding: 7px 12px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--text);
  text-transform: uppercase;
  font-weight: 1000;
}

.upload-field small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.full {
  grid-column: 1 / -1;
}

.player-dock {
  position: fixed;
  left: 50%;
  bottom: 18px;
  z-index: 20;
  width: min(680px, calc(100vw - 28px));
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  transform: translateX(-50%);
  background: rgba(0,10,46,.94);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.player-dock small {
  display: block;
}

.modal-backdrop,
.tour-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(0,0,0,.62);
}

.tour-overlay {
  z-index: 80;
}

.modal,
.tour-card {
  width: min(680px, 100%);
  max-height: min(760px, 92vh);
  overflow: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.tour-card {
  width: min(520px, 100%);
  padding: 22px;
  display: grid;
  gap: 14px;
}

.modal header,
.modal footer {
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

.modal footer,
.tour-card footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border-top: 1px solid var(--line);
  border-bottom: 0;
}

.modal h2,
.tour-card h2 {
  margin: 0;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.tour-card h2 {
  font-size: clamp(26px, 4vw, 42px);
  line-height: .96;
}

.tour-card p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.45;
}

.tour-step-count {
  color: var(--ok);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 1000;
}

.modal-body {
  padding: 16px;
}

.modal-error {
  grid-column: 1 / -1;
  margin: 4px 0 0;
  padding: 10px 12px;
  border: 1px solid rgba(217,134,152,.42);
  background: rgba(217,134,152,.14);
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.info-modal {
  display: grid;
  gap: 12px;
}

.info-modal p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.45;
}

.info-modal strong {
  color: var(--text);
}

.empty {
  min-height: 180px;
  padding: 24px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
}

.offline-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
}

.offline-card {
  max-width: 440px;
  padding: 24px;
  background: var(--panel);
  border: 1px solid var(--line);
}

@media (max-width: 1180px) {
  .app-shell {
    grid-template-columns: 240px minmax(0, 1fr);
  }

  body.sidebar-collapsed .app-shell {
    grid-template-columns: 78px minmax(0, 1fr);
  }

  .drive-shell {
    grid-template-columns: 220px minmax(0, 1fr);
  }

  .drive-list-head {
    display: none;
  }

  .drive-file-row {
    grid-template-columns: 34px minmax(0, 1fr) minmax(70px, auto);
  }

  .drive-file-row > small:first-of-type {
    display: none;
  }
}

@media (max-width: 980px) {
  html,
  body {
    min-height: 100dvh;
    overflow-x: hidden;
  }

  .app-shell {
    display: block;
    min-height: 100dvh;
    overflow-x: hidden;
  }

  .auth-card {
    grid-template-columns: 1fr;
  }

  body.sidebar-collapsed .app-shell {
    display: block;
  }

  .sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 40;
    width: min(78vw, 304px);
    max-width: calc(100vw - 28px);
    height: 100dvh;
    padding: calc(18px + env(safe-area-inset-top)) 14px calc(18px + env(safe-area-inset-bottom));
    overflow: auto;
    overscroll-behavior: contain;
    transform: translateX(-105%);
    transition: transform .2s ease;
  }

  .sidebar-head {
    align-items: flex-start;
  }

  body.menu-open::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 35;
    background: rgba(0,0,0,.42);
    backdrop-filter: blur(2px);
  }

  body.menu-open .sidebar {
    transform: translateX(0);
  }

  .menu-close {
    display: inline-grid;
  }

  .sidebar-toggle {
    display: none;
  }

  .mobile-menu {
    display: inline-grid;
  }

  .topbar {
    position: sticky;
    top: 0;
    z-index: 24;
    min-height: auto;
    padding: calc(18px + env(safe-area-inset-top)) 16px 16px;
    align-items: flex-start;
    background: rgba(0, 6, 18, .92);
    border-bottom: 1px solid rgba(255,255,255,.1);
    backdrop-filter: blur(16px);
  }

  .topbar > div {
    min-width: 0;
  }

  .topbar h1 {
    max-width: 100%;
  }

  .topbar-actions {
    display: none;
  }

  .main {
    padding-bottom: calc(120px + env(safe-area-inset-bottom));
    overflow-x: hidden;
  }

  .view {
    padding-top: 14px;
    overflow-x: hidden;
  }

  .today-stage {
    margin: 0 14px;
    min-height: 260px;
    padding: 18px;
    display: grid;
    align-items: end;
  }

  .event-strip,
  .drive-shell,
  .grid,
  .song-layout,
  .queue-strip,
  .notes-toolbar,
  .notes-grid,
  .setlist-grid,
  .view > .section-head {
    padding: 0 14px;
  }

  .drive-shell {
    margin: 0 14px;
    padding: 0;
    grid-template-columns: 1fr;
  }

  .drive-sidebar {
    display: flex;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .drive-location {
    min-width: 180px;
  }

  .drive-browser {
    padding: 16px;
  }

  .drive-browser-head h2 {
    font-size: 30px;
  }

  .drive-browser-head,
  .drive-view-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .event-card .card-actions {
    min-width: 0;
    justify-content: flex-start;
  }

  .planning-toolbar,
  .planning-pagination {
    grid-template-columns: 1fr;
  }

  .planning-toolbar {
    margin-bottom: 12px;
    padding: 12px;
    gap: 12px;
  }

  .planning-toolbar-head {
    grid-template-columns: 1fr auto;
    align-items: end;
  }

  .planning-toolbar-head small {
    display: none;
  }

  .planning-filter-selects {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .event-card {
    padding: 14px;
  }

  .event-card > .item-row {
    display: grid;
    gap: 12px;
  }

  .event-title-line strong {
    font-size: 22px;
  }

  .event-title-line small {
    max-width: 24ch;
    line-height: 1.3;
  }

  .event-meta-row {
    align-items: stretch;
    gap: 7px;
  }

  .attendance-pill,
  .availability-button {
    min-height: 38px;
  }

  .attendance-pill {
    flex: 0 0 auto;
    min-width: 0;
    padding: 5px 8px;
    gap: 6px;
  }

  .attendance-pill small {
    display: none;
  }

  .attendance-pill strong {
    font-size: 15px;
  }

  .attendance-icon {
    width: 13px;
    height: 13px;
  }

  .attendance-icon::after {
    width: 16px;
    height: 8px;
  }

  .availability-button {
    flex: 0 1 auto;
    justify-content: center;
  }

  .event-card .card-actions {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 8px;
    width: 100%;
  }

  .event-card .status {
    grid-column: 1 / -1;
    justify-self: start;
    order: -1;
    min-height: 28px;
  }

  .event-card .ghost.small {
    min-height: 40px;
    padding: 8px 10px;
    font-size: 11px;
  }

  .event-card .icon-danger {
    width: 42px;
    min-height: 40px;
    padding: 0;
  }

  .planning-pagination > div {
    justify-content: flex-start;
  }

  .calendar-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .calendar-grid {
    min-width: 760px;
  }

  .calendar-panel {
    overflow-x: auto;
  }

  .panel .grid {
    padding: 0;
  }

  .event-strip-list,
  .event-grid,
  .drive-grid,
  .member-balance-grid,
  .setlist-grid,
  .song-overview-grid,
  .song-layout {
    grid-template-columns: 1fr;
  }

  .song-detail-head {
    display: grid;
  }

  .song-list {
    gap: 12px;
  }

  .song-queue-panel {
    margin-top: 4px;
  }

  .song-module-nav {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    overflow: visible;
    scroll-snap-type: none;
  }

  .song-module-tab {
    min-width: 0;
    scroll-snap-align: none;
  }

  .primary,
  .ghost,
  .danger,
  .pill-button,
  .small,
  .nav-item,
  .icon-button,
  .mobile-menu,
  .settle-button {
    min-height: 44px;
  }

  input,
  select,
  textarea {
    font-size: 16px;
  }

  .span-3,
  .span-4,
  .span-5,
  .span-6,
  .span-7,
  .span-8 {
    grid-column: span 12;
  }

  .session-transport,
  .session-track {
    grid-template-columns: 1fr;
  }

  .master-volume {
    grid-template-columns: auto minmax(120px, 1fr) 42px;
  }

  .waveform,
  .volume-slider {
    width: 100%;
  }

  .track-mix-buttons,
  .nudge-controls {
    width: 100%;
  }

  .session-track-controls {
    grid-column: auto;
    grid-template-columns: 68px 88px minmax(120px, 1fr) 86px 42px;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .drive-shell {
    margin: 0 14px;
  }

  .drive-toolbar,
  .drive-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .modal-backdrop {
    padding: 10px;
    place-items: center;
  }

  .modal {
    width: min(100%, 680px);
    max-height: min(86dvh, 760px);
  }

  .modal header,
  .modal footer {
    position: sticky;
    z-index: 1;
    background: var(--panel);
  }

  .modal header {
    top: 0;
  }

  .modal footer {
    bottom: 0;
  }
}

@media (max-width: 560px) {
  .view {
    gap: 28px;
    padding-top: 18px;
    padding-bottom: 110px;
  }

  .sidebar {
    width: min(84vw, 292px);
    max-width: calc(100vw - 24px);
    padding-left: 12px;
    padding-right: 12px;
  }

  .brand strong {
    font-size: 25px;
  }

  .brand small {
    font-size: 10px;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .menu-close {
    width: 40px;
    height: 40px;
  }

  .auth-gate {
    padding: 12px;
  }

  .auth-card {
    padding: 16px;
  }

  .view > .section-head {
    align-items: flex-start;
    gap: 12px;
  }

  .view > .section-head.page-actions {
    justify-content: flex-start;
    margin-top: 0;
    padding-top: 12px;
  }

  .view > .section-head.page-actions > .primary,
  .view > .section-head.page-actions > .ghost,
  .view > .section-head.page-actions > .card-actions {
    margin-left: 0;
  }

  .view > .section-head .card-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .song-actions {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: stretch;
    width: 100%;
  }

  .song-actions .primary {
    white-space: nowrap;
  }

  .mobile-song-search {
    display: block;
    min-width: 0;
  }

  .mobile-song-search input {
    width: 100%;
    min-height: 44px;
    padding: 9px 11px;
    border: 1px solid var(--line);
    background: #000a2e;
    color: var(--text);
    font-size: 16px;
    font-weight: 800;
    outline: none;
  }

  .topbar h1 {
    font-size: 32px;
  }

  .topbar {
    padding-left: 14px;
    padding-right: 14px;
    padding-bottom: 18px;
  }

  .today-stage {
    min-height: 220px;
  }

  .today-stage h2 {
    font-size: 34px;
  }

  .today-stage .primary {
    width: 100%;
  }

  .grid {
    gap: 12px;
  }

  .event-strip-list {
    grid-template-columns: 1fr;
  }

  .event-grid {
    gap: 14px;
  }

  .calendar-panel {
    overflow: visible;
  }

  .calendar-head {
    margin-bottom: 14px;
    display: grid;
    gap: 8px;
  }

  .calendar-head h2 {
    font-size: 28px;
  }

  .calendar-head small {
    font-size: 13px;
  }

  .calendar-grid {
    display: grid;
    min-width: 0;
    width: 100%;
    border-color: rgba(255,255,255,.12);
  }

  .calendar-weekday {
    min-height: 26px;
    font-size: 9px;
  }

  .calendar-cell {
    min-height: 48px;
    padding: 5px;
    gap: 4px;
  }

  .calendar-cell > strong {
    font-size: 11px;
  }

  .calendar-cell > div {
    display: flex;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 3px;
  }

  .calendar-event {
    width: 8px;
    min-width: 8px;
    height: 8px;
    min-height: 8px;
    padding: 0;
    overflow: hidden;
    border-radius: 0;
    color: transparent !important;
    font-size: 0;
  }

  .calendar-mobile-list {
    margin-top: 16px;
    display: grid;
    gap: 8px;
  }

  .calendar-mobile-item {
    position: relative;
    padding: 13px 13px 13px 46px;
    min-height: 76px;
    align-content: center;
    border-color: rgba(255,255,255,.14);
    background:
      linear-gradient(90deg, rgba(139,217,198,.08), transparent 42%),
      rgba(7, 16, 51, .72);
  }

  .calendar-mobile-item::before {
    content: "";
    position: absolute;
    left: 14px;
    top: 18px;
    width: 16px;
    height: 16px;
    border: 2px solid var(--ok);
    background: rgba(139,217,198,.08);
  }

  .calendar-mobile-item .status {
    width: fit-content;
    min-height: 22px;
    padding: 3px 7px;
    font-size: 10px;
  }

  .calendar-mobile-item strong {
    font-size: 17px;
  }

  .calendar-mobile-item small {
    color: var(--muted);
    font-size: 13px;
  }

  th,
  td {
    padding: 10px;
  }

  .finance-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .table-actions {
    gap: 6px;
  }

  .payment-request-actions {
    grid-template-columns: 1fr;
  }

  .table-wrap {
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .table-wrap table,
  .table-wrap thead,
  .table-wrap tbody,
  .table-wrap tr,
  .table-wrap th,
  .table-wrap td {
    display: block;
  }

  .table-wrap thead {
    display: none;
  }

  .finance-table .transaction-row {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "title amount"
      "date status"
      "split split"
      "actions actions";
    gap: 6px 14px;
    margin-bottom: 12px;
    padding: 16px;
    border: 1px solid var(--line);
    background:
      linear-gradient(90deg, rgba(255,255,255,.035), transparent 62%),
      var(--panel-soft);
  }

  .finance-table .transaction-row.income {
    background:
      linear-gradient(90deg, rgba(139,217,198,.1), transparent 56%),
      var(--panel-soft);
  }

  .finance-table .transaction-row.expense {
    background:
      linear-gradient(90deg, rgba(255,73,100,.08), transparent 56%),
      var(--panel-soft);
  }

  .finance-table .transaction-row td {
    min-width: 0;
    padding: 0;
    border-bottom: 0;
  }

  .finance-table .transaction-row td::before {
    display: none;
  }

  .finance-table .transaction-row td[data-label="Datum"] {
    grid-area: date;
  }

  .finance-table .transaction-row td[data-label="Titel"] {
    grid-area: title;
  }

  .finance-table .transaction-row td[data-label="Bedrag"] {
    grid-area: amount;
    align-self: start;
    text-align: right;
  }

  .finance-table .transaction-row td[data-label="Betaald door"] {
    display: none;
  }

  .finance-table .transaction-row td[data-label="Verdeling"] {
    grid-area: split;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
  }

  .finance-table .transaction-row td[data-label="Status"] {
    grid-area: status;
  }

  .finance-table .transaction-row td[data-label="Acties"] {
    grid-area: actions;
    padding-top: 8px;
  }

  .finance-table .transaction-row td[data-label="Titel"] strong {
    display: block;
    max-width: 100%;
    color: var(--text);
    font-size: 20px;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .finance-table .transaction-row td[data-label="Titel"] small {
    display: block;
    margin-top: 5px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.3;
  }

  .finance-table .transaction-date {
    color: var(--muted);
    font-size: 13px;
    text-transform: none;
  }

  .finance-table .amount {
    font-size: 20px;
  }

  .finance-table .money-status {
    min-height: 24px;
    padding: 4px 8px;
    font-size: 10px;
  }

  .finance-table .table-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
  }

  .finance-table .table-actions .small {
    min-height: 40px;
    padding: 9px 11px;
    font-size: 12px;
  }

  .finance-table .table-actions .icon-danger {
    width: 42px;
    min-width: 42px;
    padding: 0;
  }

  .song-detail-panel {
    padding: 18px;
  }

  .song-detail-panel > .item-row h2,
  .song-detail-head h2 {
    font-size: 30px;
  }

  .song-module-nav {
    margin-top: 18px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 5px;
    gap: 5px;
  }

  .song-module-tab {
    min-height: 38px;
    padding: 8px 6px;
    font-size: 10px;
  }

  .song-button .item-row {
    display: grid;
    gap: 8px;
  }

  .song-button .status {
    width: fit-content;
  }

  .song-detail-head .card-actions {
    justify-content: flex-start;
  }

  .song-overview-card .chips {
    display: grid;
    grid-template-columns: 1fr;
  }

  .song-overview-card p {
    font-size: 15px;
  }

  .session-track {
    padding: 14px;
  }

  .session-transport {
    gap: 8px;
    grid-template-columns: 44px 44px 44px minmax(0, 1fr);
  }

  .session-transport > strong:last-of-type,
  .master-volume {
    grid-column: 1 / -1;
  }

  .master-volume {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .mix-tools {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .mix-tools .disabled-tool {
    grid-column: 1 / -1;
  }

  .session-track-controls {
    grid-template-columns: 1fr 1fr;
  }

  .track-inline-meta {
    grid-template-columns: 1fr;
  }

  .mixer-console {
    min-height: 500px;
    padding: 10px;
    scroll-snap-type: x mandatory;
  }

  .mixer-channel {
    flex-basis: min(78vw, 220px);
    min-height: 470px;
  }

  .mixer-fader,
  .mixer-fader::-webkit-slider-runnable-track,
  .mixer-fader::-moz-range-track {
    height: 230px;
  }

  .level-meter {
    min-height: 230px;
  }

  .track-order-controls,
  .track-mix-buttons,
  .volume-slider,
  .nudge-controls {
    grid-column: auto;
  }

  .queue-card {
    grid-template-columns: 1fr;
  }

  .queue-actions {
    grid-template-columns: 1fr 40px;
  }

  .drive-quick-row,
  .drive-folder-row {
    grid-template-columns: 1fr;
  }

  .drive-file-row {
    align-items: start;
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .drive-file-row > small,
  .drive-file-row .card-actions {
    grid-column: 2;
  }

  .drive-recent > div {
    grid-template-columns: 1fr;
  }

  .volume-slider,
  .nudge-controls {
    grid-column: 1 / -1;
  }

  .player-dock {
    left: 12px;
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom));
    width: auto;
    transform: none;
    align-items: stretch;
    display: grid;
    grid-template-columns: 1fr 72px 72px;
  }

  .player-dock .primary,
  .player-dock .ghost {
    padding: 10px 8px;
  }

  .inbox-fab {
    right: 12px;
    bottom: 82px;
  }

  .update-banner {
    bottom: calc(12px + env(safe-area-inset-bottom));
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .player-dock:not([hidden]) ~ .update-banner {
    bottom: calc(92px + env(safe-area-inset-bottom));
  }

  .attendance-overview-grid {
    grid-template-columns: 1fr;
  }

  .print-preview-doc {
    max-height: 62vh;
  }

  .print-preview-doc .print-page {
    padding: 24px;
  }

  .print-preview-doc .print-page h1 {
    font-size: 38px;
  }

  .print-preview-doc .lyrics-lines {
    font-size: 18px;
  }
}

@media print {
  body.printing-document {
    background: #fff;
  }

  body.printing-document > *:not(.print-preview-backdrop) {
    display: none !important;
  }

  body.printing-document .print-preview-backdrop {
    position: static;
    inset: auto;
    display: block;
    padding: 0;
    background: #fff;
  }

  body.printing-document .print-preview-modal {
    width: 100%;
    max-height: none;
    overflow: visible;
    border: 0;
    box-shadow: none;
    background: #fff;
  }

  body.printing-document .print-preview-modal > header,
  body.printing-document .print-preview-modal > footer {
    display: none !important;
  }

  body.printing-document .modal-body {
    padding: 0;
  }

  body.printing-document .print-preview-doc {
    max-height: none;
    overflow: visible;
    background: #fff;
  }

  body.printing-document .print-preview-doc .print-page {
    padding: 24px;
    background: #fff;
    border: 0;
    color: #101014;
  }

  body.printing-document .print-preview-doc .print-page header {
    border-bottom-color: #101014;
  }

  body.printing-document .print-preview-doc .print-page header span,
  body.printing-document .print-preview-doc .lyrics-lines h3 {
    color: #101014;
  }
}
