/* Diablo Master — negro de escenario, brasa y hueso.
   Titulares: Big Shoulders Display (condensada, de cartel). Texto: Archivo. */

@font-face { font-family: "Big Shoulders Display"; font-weight: 600; font-display: swap;
  src: url(/fonts/big-shoulders-display-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Big Shoulders Display"; font-weight: 800; font-display: swap;
  src: url(/fonts/big-shoulders-display-latin-800-normal.woff2) format("woff2"); }
@font-face { font-family: "Archivo"; font-weight: 100 900; font-display: swap;
  src: url(/fonts/archivo-latin-wght-normal.woff2) format("woff2"); }

:root {
  --bg: #0a0908;
  --bg-2: #0f0d0c;
  --surface: #151210;
  --surface-2: #1e1a17;
  --line: #2a231f;
  --line-2: #3a3029;
  --text: #f2ebe2;
  --muted: #a39486;
  --ember: #ff5a1f;
  --amber: #ffb347;
  --ink: #1a0d05;
  --ok: #7fd69c;
  --warn: #ffc65c;
  --err: #ff6b5e;
  --radius: 12px;
  --display: "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;
  --font: "Archivo", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --topbar-h: 68px;
  --side-w: 248px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.5 var(--font); min-height: 100vh;
  padding-bottom: env(safe-area-inset-bottom);
}
body.has-player { padding-bottom: calc(112px + env(safe-area-inset-bottom)); }

h1, h2, h3 { font-family: var(--display); font-weight: 800; letter-spacing: .01em; line-height: 1.05; margin: 0 0 .5rem; }
h1 { font-size: clamp(2.2rem, 4.5vw, 3.2rem); }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.35rem; }
p { margin: 0 0 .75rem; }
a { color: var(--amber); }
.muted { color: var(--muted); }
.small { font-size: .86rem; }
.hidden, [hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
svg.i { width: 1.15em; height: 1.15em; flex: none; vertical-align: -.2em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- barra superior ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40; height: var(--topbar-h);
  display: flex; align-items: center; gap: 1rem; padding: 0 1.25rem;
  padding-top: env(safe-area-inset-top);
  background: rgba(10, 9, 8, .94); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--text); min-width: 0; }
.brand img { display: block; width: 52px; height: 52px; mix-blend-mode: lighten; flex: none; }
.brand-name { font-family: var(--display); font-weight: 800; font-size: 1.65rem; letter-spacing: .02em; line-height: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: .5rem; }
.bell, .me-chip {
  position: relative; display: inline-flex; align-items: center; gap: .55rem; min-height: 44px; min-width: 44px; justify-content: center;
  background: transparent; border: 1px solid transparent; border-radius: 999px; color: var(--text); cursor: pointer; text-decoration: none; font: inherit; padding: 0 .6rem;
}
.bell:hover, .me-chip:hover { background: var(--surface-2); }
.bell .badge-n {
  position: absolute; top: 3px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--ember); color: var(--ink); font-size: .72rem; font-weight: 700; line-height: 18px; text-align: center;
}
.avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; background: var(--surface-2); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; color: var(--amber); flex: none; }
.avatar.lg { width: 96px; height: 96px; font-size: 2rem; }
.me-name { font-size: .92rem; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- estructura ---------- */
.shell { display: flex; align-items: flex-start; min-height: calc(100vh - var(--topbar-h)); }
.side {
  position: sticky; top: var(--topbar-h); width: var(--side-w); flex: none; height: calc(100vh - var(--topbar-h)); overflow-y: auto;
  background: var(--bg-2); border-right: 1px solid var(--line); padding: 1.1rem .8rem 2rem;
}
.app { flex: 1; min-width: 0; padding: 2rem clamp(1rem, 3vw, 2.75rem) 4rem; max-width: 1180px; }
body.public .topbar, body.public .side { display: none; }
body.public .shell { display: block; }
body.public .app { max-width: none; padding: 0; }

.side-title { font-family: var(--display); font-weight: 600; font-size: 1.05rem; color: var(--muted); padding: .4rem .7rem; margin: 0; letter-spacing: .03em; }
.side a.nav-link {
  display: flex; align-items: center; gap: .65rem; padding: .55rem .7rem; border-radius: 9px;
  color: var(--text); text-decoration: none; font-size: .96rem; min-height: 40px;
}
.side a.nav-link:hover { background: var(--surface-2); }
.side a.nav-link.active { background: var(--surface-2); box-shadow: inset 3px 0 0 var(--ember); }
.side .band-link { font-weight: 600; }
.side .band-link .avatar { width: 28px; height: 28px; border-radius: 8px; font-size: .8rem; }
.side-tools { margin: .1rem 0 .6rem 1.35rem; padding-left: .5rem; border-left: 1px solid var(--line); }
.side-sep { height: 1px; background: var(--line); margin: .9rem .5rem; }

/* ---------- componentes ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.15rem 1.25rem; margin-bottom: 1rem; }
.card > :last-child { margin-bottom: 0; }
.row { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.grow { flex: 1 1 auto; min-width: 0; }
.stack > * + * { margin-top: .85rem; }
.page-head { display: flex; align-items: flex-end; gap: 1.1rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.page-head .lead { margin: 0; color: var(--muted); max-width: 60ch; }
.band-photo { position: relative; width: 84px; height: 84px; border-radius: 16px; overflow: hidden; background: var(--surface-2); flex: none; border: 1px solid var(--line-2); }
.band-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.band-photo .ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 800; font-size: 2.2rem; color: var(--amber); }
.band-photo button { position: absolute; inset: auto 4px 4px auto; width: 30px; height: 30px; border-radius: 50%; border: 0; background: rgba(0,0,0,.72); color: var(--text); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.band-photo button:hover { background: var(--ember); color: var(--ink); }

label { display: block; font-size: .9rem; color: var(--muted); margin-bottom: .3rem; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=time], select, textarea {
  width: 100%; padding: .7rem .8rem; border-radius: 10px; border: 1px solid var(--line-2);
  background: var(--bg); color: var(--text); font: inherit; min-height: 44px;
}
textarea { min-height: 84px; resize: vertical; }
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible, summary:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--amber); outline-offset: 2px;
}
.field { margin-bottom: .9rem; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: .75rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 44px; padding: .55rem 1.1rem;
  border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--text);
  font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap;
}
.btn:hover { border-color: var(--muted); }
.btn.primary { background: linear-gradient(135deg, var(--amber), var(--ember)); color: var(--ink); border-color: transparent; }
.btn.primary:hover { filter: brightness(1.08); }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--err); }
.btn.small { min-height: 36px; padding: .3rem .8rem; font-size: .88rem; }
.btn.big { min-height: 54px; padding: .8rem 1.6rem; font-size: 1.05rem; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.icon-btn { background: none; border: 0; color: var(--muted); font-size: 1rem; cursor: pointer; min-width: 40px; min-height: 40px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; }
.icon-btn:hover { color: var(--text); background: var(--surface-2); }

.seg { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .55rem; }
.seg label { display: block; margin: 0; padding: .75rem .9rem; border: 1px solid var(--line-2); border-radius: 10px; color: var(--text); cursor: pointer; background: var(--bg); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) { border-color: var(--ember); background: rgba(255, 90, 31, .09); }
.seg label:has(input:focus-visible) { outline: 2px solid var(--amber); outline-offset: 2px; }
.seg .hint { display: block; color: var(--muted); font-size: .82rem; margin-top: .15rem; }

.badge { display: inline-block; padding: .08rem .55rem; border-radius: 999px; font-size: .76rem; font-weight: 600; background: var(--surface-2); border: 1px solid var(--line-2); color: var(--muted); }
.badge.master { background: rgba(255, 90, 31, .14); border-color: var(--ember); color: var(--amber); }
.badge.mix { color: var(--text); }

.progress, .meter { height: 8px; border-radius: 999px; background: var(--bg); overflow: hidden; border: 1px solid var(--line-2); }
.progress { height: 10px; }
.progress > i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--amber), var(--ember)); transition: width .2s; }
.meter > i { display: block; height: 100%; background: var(--ok); }
.meter.warn > i { background: var(--warn); } .meter.full > i { background: var(--err); }

.callout { padding: .8rem 1rem; border-radius: 10px; background: rgba(255, 179, 71, .07); border: 1px solid rgba(255, 179, 71, .3); font-size: .92rem; }
.empty { text-align: center; padding: 2.2rem 1rem; color: var(--muted); }
.empty svg.i { width: 2.4rem; height: 2.4rem; display: block; margin: 0 auto .6rem; color: var(--line-2); stroke-width: 1.4; }
.copybox { display: flex; gap: .5rem; align-items: center; padding: .6rem .7rem; border-radius: 10px; background: var(--bg); border: 1px solid var(--line-2); word-break: break-all; font-family: ui-monospace, Menlo, monospace; font-size: .85rem; }
.table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.table th, .table td { text-align: left; padding: .5rem .4rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { color: var(--muted); font-weight: 600; font-size: .85rem; }
.table input { min-height: 38px; padding: .4rem .6rem; }
details > summary { cursor: pointer; color: var(--amber); }

/* ---------- inicio público ---------- */
.hero {
  position: relative; min-height: 100vh; display: flex; flex-direction: column; justify-content: flex-end;
  padding: 2rem clamp(1.25rem, 6vw, 5rem) clamp(2.5rem, 8vh, 5rem);
  background: linear-gradient(90deg, rgba(10,9,8,.92) 0%, rgba(10,9,8,.55) 55%, rgba(10,9,8,.2) 100%),
              linear-gradient(0deg, var(--bg) 0%, rgba(10,9,8,0) 40%), url(/fondo-login.jpg) center / cover no-repeat;
}
.hero-top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; justify-content: space-between; padding: 1.25rem clamp(1.25rem, 6vw, 5rem); }
.hero-top .brand img { width: 64px; height: 64px; }
.hero h1 { font-size: clamp(3.8rem, 13vw, 10.5rem); line-height: .86; margin: 0 0 1.2rem; letter-spacing: .005em; }
.hero p.lead { font-size: clamp(1.1rem, 2.2vw, 1.5rem); max-width: 30ch; color: var(--text); margin-bottom: 1.8rem; }
.hero .cta { display: flex; gap: .8rem; flex-wrap: wrap; align-items: center; }
.hero .cta .muted { font-size: .92rem; max-width: 30ch; }
.tools { padding: clamp(2.5rem, 7vw, 5rem) clamp(1.25rem, 6vw, 5rem); max-width: 1100px; margin: 0 auto; }
.tool-row { display: grid; grid-template-columns: minmax(180px, 1fr) 2fr minmax(220px, 1.3fr); gap: 1.5rem; padding: 1.6rem 0; border-top: 1px solid var(--line-2); align-items: center; }
.tool-row img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 12px; display: block; border: 1px solid var(--line-2); }
.tool-row:last-child { border-bottom: 1px solid var(--line-2); }
.tool-row h2 { font-size: clamp(2rem, 4vw, 3rem); margin: 0; }
.tool-row p { margin: 0; color: var(--muted); font-size: 1.08rem; max-width: 52ch; }
.foot { padding: 2rem clamp(1.25rem, 6vw, 5rem) 3rem; display: flex; gap: 1rem; justify-content: space-between; flex-wrap: wrap; align-items: center; color: var(--muted); max-width: 1100px; margin: 0 auto; }

/* ---------- login ---------- */
.auth-wrap {
  min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr;
}
.auth-art {
  position: relative; background: linear-gradient(0deg, rgba(10,9,8,.8), rgba(10,9,8,.15)), url(/img/hero-escenario.jpg) center / cover no-repeat;
  display: flex; align-items: flex-end; padding: 2.5rem;
}
.auth-art h2 { font-size: clamp(2.2rem, 4vw, 3.4rem); max-width: 12ch; margin: 0; }
.auth-form { display: flex; align-items: center; justify-content: center; padding: 2rem 1.25rem; }
.auth-form form { width: min(400px, 100%); }
.auth-form .brand { margin-bottom: 1.6rem; }
.auth-form .brand img { width: 72px; height: 72px; }

/* ---------- inicio de la app: bandas ---------- */
.band-grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.band-tile { display: block; color: inherit; text-decoration: none; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; transition: border-color .15s; }
.band-tile:hover { border-color: var(--ember); }
.band-tile .pic { aspect-ratio: 1.4; background: var(--surface-2); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.band-tile .pic img { width: 100%; height: 100%; object-fit: cover; }
.band-tile .pic span { font-family: var(--display); font-weight: 800; font-size: 4rem; color: var(--amber); }
.band-tile .meta { padding: .9rem 1rem 1rem; }
.band-tile h3 { margin: 0 0 .15rem; }
.upcoming { list-style: none; margin: 0; padding: 0; }
.upcoming li { display: flex; gap: .9rem; align-items: center; padding: .65rem 0; border-bottom: 1px solid var(--line); }
.upcoming li:last-child { border-bottom: 0; }
.date-chip { flex: none; width: 52px; text-align: center; border: 1px solid var(--line-2); border-radius: 10px; padding: .25rem 0; line-height: 1.1; }
.date-chip b { display: block; font-family: var(--display); font-size: 1.5rem; }
.date-chip span { font-size: .75rem; color: var(--muted); }

/* ---------- grabador ---------- */
.recorder { display: grid; grid-template-columns: auto 1fr; gap: 1.4rem; align-items: center; }
.rec-btn {
  width: 96px; height: 96px; border-radius: 50%; border: 3px solid var(--line-2); background: var(--bg); cursor: pointer; position: relative; flex: none;
  display: flex; align-items: center; justify-content: center; color: var(--text);
}
.rec-btn::after { content: ""; width: 44px; height: 44px; border-radius: 50%; background: var(--err); transition: all .15s; }
.rec-btn:hover { border-color: var(--err); }
.rec-btn.on { border-color: var(--err); }
.rec-btn.on::after { width: 30px; height: 30px; border-radius: 7px; }
.rec-time { font-family: var(--display); font-weight: 800; font-size: 3rem; line-height: 1; font-variant-numeric: tabular-nums; }
.rec-meter { display: flex; align-items: flex-end; gap: 3px; height: 38px; margin: .55rem 0; }
.rec-meter i { flex: 1; min-width: 3px; background: var(--line-2); border-radius: 2px; height: 8%; transition: height .06s linear; }
.rec-meter i.on { background: linear-gradient(0deg, var(--ember), var(--amber)); }
.rec-meter i.hot { background: var(--err); }
.rec-review audio { width: 100%; margin: .6rem 0; }

.drop { border: 2px dashed var(--line-2); border-radius: var(--radius); padding: 1.3rem 1rem; text-align: center; color: var(--muted); cursor: pointer; transition: border-color .15s, background .15s; }
.drop.over, .drop:hover { border-color: var(--ember); background: rgba(255, 90, 31, .05); color: var(--text); }
.drop strong { color: var(--text); }

/* ---------- temas ---------- */
.track-head { display: flex; align-items: flex-start; gap: .75rem; }
.track-head h3 { margin: 0; overflow-wrap: anywhere; font-size: 1.5rem; }
.versions { list-style: none; margin: .9rem 0 0; padding: 0; border-top: 1px solid var(--line); }
.ver { padding: .8rem 0; border-bottom: 1px solid var(--line); }
.ver:last-child { border-bottom: 0; padding-bottom: 0; }
.ver-top { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.ver.is-master { background: linear-gradient(90deg, rgba(255,90,31,.08), transparent 70%); margin: 0 -1.25rem; padding-left: 1.25rem; padding-right: 1.25rem; }
.ver-actions { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .6rem; align-items: center; }
.dl-label { color: var(--muted); font-size: .85rem; margin-left: .25rem; }
.status { font-size: .88rem; }
.status.processing { color: var(--warn); }
.status.error { color: var(--err); }
.spinner { display: inline-block; width: 14px; height: 14px; border-radius: 50%; vertical-align: -2px; margin-right: .35rem; border: 2px solid var(--line-2); border-top-color: var(--warn); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.track-foot { margin-top: 1rem; display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }
.oneclick { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.oneclick select { width: auto; min-width: 150px; }
.mini-sel { width: auto; min-height: 36px; padding: .25rem .6rem; font-size: .88rem; }

/* ---------- asistente ---------- */
.assistant { margin-top: 1rem; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--bg); padding: 1rem 1.1rem; }
.assistant h4 { font-family: var(--display); font-weight: 800; font-size: 1.3rem; margin: 0 0 .4rem; }
.verdict { padding: .65rem .9rem; border-radius: 10px; margin-bottom: .8rem; font-weight: 600; border: 1px solid; }
.verdict.listo { background: rgba(127,214,156,.08); border-color: rgba(127,214,156,.4); color: var(--ok); }
.verdict.casi { background: rgba(255,198,92,.08); border-color: rgba(255,198,92,.4); color: var(--warn); }
.verdict.revisar { background: rgba(255,107,94,.08); border-color: rgba(255,107,94,.45); color: var(--err); }
.tips { list-style: none; margin: 0; padding: 0; }
.tips li { display: grid; grid-template-columns: 26px 1fr; gap: .6rem; padding: .55rem 0; border-top: 1px solid var(--line); }
.tips li:first-child { border-top: 0; }
.tips .mark { width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 800; margin-top: 2px; }
.tips .ok .mark { background: rgba(127,214,156,.16); color: var(--ok); }
.tips .warn .mark { background: rgba(255,198,92,.16); color: var(--warn); }
.tips .bad .mark { background: rgba(255,107,94,.16); color: var(--err); }
.tips b { display: block; }
.tips span { color: var(--muted); font-size: .92rem; }
.ai-note { white-space: pre-wrap; margin-top: .8rem; padding: .8rem 1rem; border-left: 3px solid var(--ember); background: var(--surface); border-radius: 0 10px 10px 0; }

/* ---------- master (pasos) ---------- */
.steps { counter-reset: step; }
.step { position: relative; padding-left: 3.1rem; margin-bottom: 1.4rem; }
.step::before { counter-increment: step; content: counter(step); position: absolute; left: 0; top: -.1rem; width: 2.1rem; height: 2.1rem; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 800; font-size: 1.2rem; background: var(--surface-2); border: 1px solid var(--line-2); color: var(--amber); }
.step h3 { margin: 0 0 .5rem; font-size: 1.35rem; }

/* ---------- albumes ---------- */
.album { display: grid; grid-template-columns: 180px 1fr; gap: 1.4rem; }
.cover { position: relative; width: 180px; height: 180px; border-radius: 12px; overflow: hidden; background: var(--surface-2); border: 1px solid var(--line-2); }
.cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cover .ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--line-2); }
.cover .ph svg { width: 3.4rem; height: 3.4rem; }
.cover button { position: absolute; right: 8px; bottom: 8px; width: 34px; height: 34px; border-radius: 50%; border: 0; background: rgba(0,0,0,.75); color: var(--text); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.cover button:hover { background: var(--ember); color: var(--ink); }
.tracklist { list-style: none; margin: .8rem 0 0; padding: 0; }
.tracklist li { display: flex; align-items: center; gap: .6rem; padding: .45rem 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.tracklist .n { font-family: var(--display); font-weight: 800; font-size: 1.2rem; color: var(--muted); width: 1.8rem; text-align: right; }

/* ---------- calendario ---------- */
.cal-head { display: flex; align-items: center; gap: .5rem; margin-bottom: .8rem; }
.cal-head h2 { margin: 0 .5rem 0 0; text-transform: none; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.cal .dow { padding: .4rem .5rem; font-size: .8rem; color: var(--muted); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--bg-2); }
.cal .day { min-height: 92px; padding: .35rem .45rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); cursor: pointer; font-size: .85rem; text-align: left; color: var(--text); border-top: 0; border-left: 0; font-family: inherit; display: block; }
.cal .day:hover { background: var(--surface-2); }
.cal .day.out { background: var(--bg); color: var(--muted); }
.cal .day.today .dn { background: var(--ember); color: var(--ink); border-radius: 50%; }
.cal .dn { display: inline-flex; width: 24px; height: 24px; align-items: center; justify-content: center; font-weight: 700; }
.cal .ev { display: block; margin-top: 3px; padding: 1px 6px; border-radius: 5px; background: rgba(255,90,31,.2); color: var(--amber); font-size: .76rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- campana de avisos ---------- */
.notif {
  position: fixed; top: calc(var(--topbar-h) + 6px); right: 1rem; z-index: 55; width: min(400px, calc(100vw - 2rem)); max-height: min(560px, 75vh); overflow-y: auto;
  background: var(--surface); border: 1px solid var(--line-2); border-radius: 14px; box-shadow: 0 20px 60px rgba(0,0,0,.65); padding: .9rem 1rem;
}
.notif h4 { font-family: var(--display); font-weight: 800; font-size: 1.15rem; margin: .2rem 0 .4rem; }
.notif a.item { display: block; padding: .55rem .4rem; border-radius: 8px; color: var(--text); text-decoration: none; font-size: .93rem; border-bottom: 1px solid var(--line); }
.notif a.item:hover { background: var(--surface-2); }
.notif a.item.unread { box-shadow: inset 3px 0 0 var(--ember); padding-left: .7rem; }
.notif .when { display: block; color: var(--muted); font-size: .8rem; }

/* ---------- reproductor, modal, avisos ---------- */
.player { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; padding: .6rem 1rem calc(.6rem + env(safe-area-inset-bottom)); background: rgba(21, 18, 16, .97); backdrop-filter: blur(8px); border-top: 1px solid var(--line-2); }
.player-info { display: flex; align-items: center; justify-content: space-between; gap: .5rem; max-width: 880px; margin: 0 auto; }
.player-title { font-weight: 600; font-size: .92rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player audio { display: block; width: 100%; max-width: 880px; margin: 0 auto; height: 40px; }
.modal { width: min(540px, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); overflow: auto; background: var(--surface); color: var(--text); border: 1px solid var(--line-2); border-radius: 14px; padding: 1.4rem; }
.modal::backdrop { background: rgba(0, 0, 0, .7); }
.toasts { position: fixed; top: calc(.8rem + env(safe-area-inset-top)); left: 0; right: 0; z-index: 70; display: flex; flex-direction: column; align-items: center; gap: .5rem; pointer-events: none; padding: 0 1rem; }
.toast { pointer-events: auto; max-width: 480px; padding: .7rem 1rem; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line-2); box-shadow: 0 8px 30px rgba(0, 0, 0, .5); }
.toast.err { border-color: var(--err); }
.toast.ok { border-color: var(--ok); }

/* ---------- celular ---------- */
@media (max-width: 860px) {
  :root { --topbar-h: 60px; }
  .topbar { padding: 0 .75rem; gap: .5rem; }
  .brand img { width: 36px; height: 36px; }
  .brand-name { font-size: 1.02rem; }
  .me-name { display: none; }
  .shell { display: block; }
  .menu-btn { display: inline-flex; }
  .side {
    position: fixed; top: var(--topbar-h); bottom: 0; left: 0; z-index: 60; width: min(300px, 86vw); height: auto;
    transform: translateX(-102%); transition: transform .2s ease; background: var(--bg-2); border-right: 1px solid var(--line-2);
    padding-bottom: calc(5rem + env(safe-area-inset-bottom));
  }
  body.drawer-open .side { transform: none; }
  body.drawer-open .scrim { display: block; }
  .tabbar { display: flex; }
  body.has-tabbar { padding-bottom: calc(68px + env(safe-area-inset-bottom)); }
  body.has-tabbar .player { bottom: calc(62px + env(safe-area-inset-bottom)); padding-bottom: .6rem; }
  body.has-tabbar.has-player { padding-bottom: calc(180px + env(safe-area-inset-bottom)); }
  .app { padding: 1.25rem 1rem 3rem; }
  .recorder { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .album { grid-template-columns: 1fr; }
  .cover { width: 100%; max-width: 260px; height: auto; aspect-ratio: 1; }
  .tool-row { grid-template-columns: 1fr; gap: .6rem; }
  .tool-row img { order: -1; }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-art { display: none; }
  .auth-form { min-height: 100vh; background: linear-gradient(rgba(10,9,8,.8), rgba(10,9,8,.95)), url(/img/hero-escenario.jpg) center / cover; }
  .cal .day { min-height: 64px; padding: .2rem .25rem; }
  .cal .ev { font-size: .68rem; padding: 0 3px; }
  .ver.is-master { margin: 0 -1rem; padding-left: 1rem; padding-right: 1rem; }
  .hero h1 { font-size: clamp(3.4rem, 19vw, 6rem); }
}
/* ---------- menú inferior, panel de inicio, admin ---------- */
.menu-btn { margin-right: -.2rem; }
@media (min-width: 861px) { .menu-btn, .scrim, .tabbar { display: none !important; } }
@media (max-width: 860px) { .scrim { display: none; } .tabbar { display: flex; } .menu-btn { display: inline-flex; } }
.scrim { position: fixed; inset: var(--topbar-h) 0 0 0; z-index: 55; background: rgba(0, 0, 0, .6); }
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; background: rgba(15, 13, 12, .97); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line-2); padding: .3rem .25rem calc(.3rem + env(safe-area-inset-bottom));
}
.tabbar[hidden] { display: none !important; }
.tabbar a {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem; min-height: 54px; border-radius: 12px;
  color: var(--muted); text-decoration: none; font-size: .68rem; font-weight: 600; letter-spacing: .01em;
}
.tabbar a .i { width: 24px; height: 24px; }
.tabbar a.on { color: var(--ember); background: rgba(255, 90, 31, .1); }
.band-card .rec-cta { margin-left: auto; }
.tool-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-top: 1.1rem; }
.tool-tile {
  display: flex; flex-direction: column; gap: .2rem; padding: .95rem; border: 1px solid var(--line-2); border-radius: 12px; background: var(--surface-2);
  color: var(--text); text-decoration: none;
}
.tool-tile:hover { border-color: var(--ember); }
.tool-tile .i { width: 26px; height: 26px; color: var(--ember); margin-bottom: .25rem; }
.tool-tile strong { font-family: var(--display); font-weight: 800; font-size: 1.25rem; }
.tool-tile span { color: var(--muted); font-size: .85rem; line-height: 1.3; }
.install .ico-lg { width: 52px; height: 52px; border-radius: 14px; background: var(--surface-2); display: inline-flex; align-items: center; justify-content: center; color: var(--ember); flex: none; }
.install .ico-lg .i { width: 28px; height: 28px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1rem; }
.stat b { display: block; font-family: var(--display); font-weight: 800; font-size: 1.9rem; line-height: 1.05; }
.stat span { color: var(--muted); font-size: .85rem; }
.admin-band { padding: 1rem 0; border-top: 1px solid var(--line); }
.admin-band:first-of-type { border-top: 0; padding-top: .2rem; }
.table-wrap { overflow-x: auto; }
tr.inactive { opacity: .55; }
@media (max-width: 860px) { .band-card .rec-cta { width: 100%; justify-content: center; margin-left: 0; } .tool-grid { grid-template-columns: repeat(2, 1fr); } }
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
