:root {
  --accent: #b02020;
  --panel-opacity: 0.92;
  --bg: #0b0c0e;
  --fg: #e8e9ec;
  --muted: #9aa0a8;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--fg);
  font-family: -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
a { color: var(--accent); }
#scene { position: fixed; inset: 0; touch-action: none; }
.topbar { position: fixed; top: 0; left: 0; right: 0; display: flex; gap: 8px; align-items: center;
  padding: 10px 12px; background: rgba(15,16,19,var(--panel-opacity)); backdrop-filter: blur(8px);
  border-bottom: 1px solid #23252a; z-index: 10; flex-wrap: wrap; }
.topbar .title { font-weight: 700; margin-right: auto; font-size: 15px; }
.topbar .title small { color: var(--muted); font-weight: 400; }
button, .btn { background: #1c1e23; color: var(--fg); border: 1px solid #2e3138; border-radius: 10px;
  padding: 8px 12px; font-size: 14px; cursor: pointer; text-decoration: none; }
button.active, .btn.active { border-color: var(--accent); color: #fff; background: color-mix(in srgb, var(--accent) 35%, #1c1e23); }
.explodebar { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 10;
  background: rgba(15,16,19,var(--panel-opacity)); border: 1px solid #23252a; border-radius: 14px;
  padding: 10px 14px; backdrop-filter: blur(8px); }
.explodebar label { font-size: 13px; color: var(--muted); display: flex; justify-content: space-between; }
input[type=range] { width: 100%; accent-color: var(--accent); height: 34px; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(320px, 88vw); z-index: 20;
  background: rgba(15,16,19,0.98); border-left: 1px solid #23252a; transform: translateX(100%);
  transition: transform .2s ease; display: flex; flex-direction: column; }
.drawer.open { transform: none; }
.drawer header { display: flex; justify-content: space-between; align-items: center; padding: 12px; border-bottom: 1px solid #23252a; }
.drawer .list { overflow-y: auto; padding: 8px 12px 24px; }
.drawer h3 { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; margin: 14px 0 6px; }
.partrow { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; margin: 2px 0; padding: 9px 10px; }
.partrow .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); flex: none; }
.partrow.solo { opacity: .95; }
.infosheet { position: fixed; left: 12px; right: 12px; bottom: 86px; z-index: 15;
  background: rgba(15,16,19,0.97); border: 1px solid #2e3138; border-radius: 14px; padding: 14px;
  display: none; }
.infosheet.open { display: block; }
.infosheet h2 { margin: 0 0 4px; font-size: 17px; }
.infosheet .grp { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.infosheet p { margin: 8px 0 12px; font-size: 14px; line-height: 1.45; color: #cfd3d9; }
.infosheet .row { display: flex; gap: 8px; }
.page { max-width: 640px; margin: 0 auto; padding: 18px 16px 60px; }
.page h1 { font-size: 22px; } .page h2 { font-size: 16px; margin-top: 26px; }
.page p, .page li { color: #cfd3d9; line-height: 1.55; font-size: 15px; }
.card { background: #14161a; border: 1px solid #23252a; border-radius: 14px; padding: 16px; margin: 14px 0; }
.field { margin: 14px 0; }
.field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
input[type=color] { width: 64px; height: 40px; border: none; background: none; padding: 0; }
select { background: #1c1e23; color: var(--fg); border: 1px solid #2e3138; border-radius: 10px; padding: 8px 10px; font-size: 14px; }
.hint { color: var(--muted); font-size: 13px; }
.loginwrap { min-height: 100%; display: grid; place-items: center; padding: 20px; }
.logincard { width: min(380px, 100%); }
.logincard input[type=password] { width: 100%; background: #1c1e23; color: var(--fg);
  border: 1px solid #2e3138; border-radius: 10px; padding: 12px; font-size: 16px; margin: 8px 0 12px; }
.err { color: #ff7a7a; font-size: 14px; }
@media (min-width: 720px) {
  .infosheet { left: auto; width: 360px; right: 16px; }
  .explodebar { left: 16px; right: auto; width: 360px; bottom: 16px; }
}
