/* GHH Music portal */
:root {
  --ink: #0f1728; --ink-2: #2a3449; --muted: #5b6679; --line: #e3e7ef; --soft: #f4f6fa;
  --paper: #fff; --brand: #5146e5; --brand-deep: #3f35c4; --brand-soft: #eff0fe;
  --blue: #1d6fe0; --blue-soft: #eef4ff; --warn: #b7791f; --warn-soft: #fdf5e6;
  --err: #c9302c; --err-soft: #fdeceb; --radius: 14px;
  --shadow: 0 1px 2px rgba(15,23,40,.06), 0 8px 24px rgba(15,23,40,.07);
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--soft);
  font-size: 15.5px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.7rem; margin: 0 0 4px; letter-spacing: -.02em; }
h2 { font-size: 1.15rem; margin: 0 0 12px; letter-spacing: -.01em; }
h3 { font-size: 1rem; margin: 0 0 8px; }
p { margin: 0 0 .8em; }
.muted { color: var(--muted); } .small { font-size: .86rem; } .mono { font-family: ui-monospace, Menlo, monospace; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 18px; }

/* top bar */
.top { background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.top .wrap { display: flex; align-items: center; gap: 18px; height: 62px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; color: var(--ink); text-decoration: none !important; }
.brand-mark { width: 32px; height: 32px; border-radius: 9px; background: var(--brand); color: #fff;
  display: grid; place-items: center; }
.brand small { color: var(--muted); font-weight: 600; }
.nav { display: flex; gap: 4px; flex: 1; overflow-x: auto; scrollbar-width: none; }
.nav a { color: var(--ink-2); font-weight: 600; padding: 8px 12px; border-radius: 999px; white-space: nowrap; text-decoration: none; }
.nav a:hover { background: var(--soft); }
.nav a.on { background: var(--brand-soft); color: var(--brand-deep); }
.who { display: flex; align-items: center; gap: 10px; font-size: .88rem; }
.venue-pill { background: var(--soft); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; font-weight: 600; white-space: nowrap; }
@media (max-width: 860px) {
  .top .wrap { flex-wrap: wrap; height: auto; padding-top: 10px; gap: 8px; }
  .nav { order: 3; flex-basis: 100%; padding-bottom: 8px; }
  .who .hide-sm { display: none; }
}

main { padding: 26px 0 60px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }

/* cards */
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card + .card { margin-top: 18px; }
.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

/* buttons & forms */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: inherit; font-weight: 700;
  font-size: .9rem; line-height: 1; padding: 10px 16px; border-radius: 999px; border: 1.5px solid var(--line);
  background: var(--paper); color: var(--ink); cursor: pointer; text-decoration: none !important; white-space: nowrap; }
.btn:hover { border-color: #c9d0dd; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-deep); border-color: var(--brand-deep); }
.btn-danger { color: var(--err); }
.btn-sm { padding: 7px 12px; font-size: .82rem; }
.btn-icon { width: 44px; height: 44px; padding: 0; font-size: 1.1rem; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
form.inline { display: inline; }
label { display: block; font-weight: 600; font-size: .86rem; margin: 0 0 5px; }
input[type=text], input[type=email], input[type=password], input[type=time], input[type=number], select, textarea {
  width: 100%; font: inherit; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
input[type=range] { width: 100%; accent-color: var(--brand); }
.field { margin-bottom: 14px; }
.fields { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); align-items: end; }
.days { display: flex; gap: 4px; flex-wrap: wrap; }
.days label { margin: 0; }
.days input { position: absolute; opacity: 0; pointer-events: none; }
.days span { display: inline-block; padding: 7px 10px; border: 1.5px solid var(--line); border-radius: 8px; font-size: .82rem; cursor: pointer; user-select: none; }
.days input:checked + span { background: var(--brand); border-color: var(--brand); color: #fff; }
.days input:focus-visible + span { box-shadow: 0 0 0 3px var(--brand-soft); }

/* flashes, badges */
.flash { padding: 11px 14px; border-radius: 10px; margin-bottom: 10px; font-weight: 500; }
.flash.ok { background: var(--blue-soft); color: #1558b8; }
.flash.error { background: var(--err-soft); color: #9d1f1b; }
.flash.info { background: var(--brand-soft); color: var(--brand-deep); }
.banner { background: var(--warn-soft); color: #7a5214; border-bottom: 1px solid #f1dfb8; padding: 10px 0; font-weight: 600; font-size: .9rem; }
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: .74rem; font-weight: 700; padding: 3px 9px; border-radius: 999px;
  background: var(--soft); color: var(--muted); letter-spacing: .02em; }
.badge.on { background: var(--blue-soft); color: #1558b8; }
.badge.off { background: var(--err-soft); color: #9d1f1b; }
.badge.brand { background: var(--brand-soft); color: var(--brand-deep); }
.badge.warn { background: var(--warn-soft); color: #7a5214; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #b5bdcc; display: inline-block; }
.dot.on { background: var(--blue); box-shadow: 0 0 0 3px rgba(29,111,224,.18); }
.dot.off { background: var(--err); }

/* zone cards */
.zone-card { display: flex; flex-direction: column; gap: 14px; }
.zone-card .head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.zone-card h2 { margin: 0; }
.now { display: flex; gap: 14px; align-items: center; background: var(--soft); border-radius: 12px; padding: 12px; min-height: 72px; }
.art { width: 48px; height: 48px; border-radius: 10px; flex: none; display: grid; place-items: center; color: #fff; background: var(--brand); }
.art.idle { background: #c3c9d4; }
.now .t { font-weight: 700; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.now .a { color: var(--muted); font-size: .88rem; }
.eq { display: inline-flex; gap: 2px; align-items: flex-end; height: 18px; }
.eq i { width: 3px; background: #fff; border-radius: 1px; animation: eq 1s ease-in-out infinite; }
.eq i:nth-child(2) { animation-delay: -.3s; } .eq i:nth-child(3) { animation-delay: -.6s; } .eq i:nth-child(4) { animation-delay: -.15s; }
@keyframes eq { 0%,100% { height: 4px; } 50% { height: 18px; } }
@media (prefers-reduced-motion: reduce) { .eq i { animation: none; height: 10px; } }
.meta-row { display: flex; gap: 14px; flex-wrap: wrap; font-size: .85rem; color: var(--muted); }
.meta-row strong { color: var(--ink); }

/* tables & lists */
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th { text-align: left; font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; padding: 8px 10px; border-bottom: 1px solid var(--line); }
td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
.table-wrap { overflow-x: auto; margin: 0 -20px; padding: 0 20px; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.grow { flex: 1; min-width: 0; }
.ellip { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.swatch { width: 12px; height: 12px; border-radius: 4px; display: inline-block; flex: none; }
.block { display: flex; gap: 12px; align-items: center; padding: 12px; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 8px; }
.block .when { font-weight: 700; min-width: 140px; }
.block.now-on { border-color: var(--brand); background: var(--brand-soft); }
.station-card { display: flex; flex-direction: column; gap: 8px; color: var(--ink); text-decoration: none !important; border-top: 5px solid var(--brand); }
.station-card:hover { box-shadow: 0 2px 4px rgba(15,23,40,.06), 0 16px 40px rgba(15,23,40,.12); }
audio { width: 100%; height: 36px; }
details summary { cursor: pointer; font-weight: 600; }
.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty h2 { color: var(--ink); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: .88rem; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; font-weight: 600; word-break: break-word; }
.code { font-family: ui-monospace, Menlo, monospace; font-weight: 700; background: var(--brand-soft); color: var(--brand-deep); padding: 3px 8px; border-radius: 6px; letter-spacing: .04em; }
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.login-card { width: 100%; max-width: 400px; }
footer.foot { text-align: center; color: var(--muted); font-size: .8rem; padding: 20px 0 30px; }
