/* Baustein „Regiepult zum Selbst-Drücken“ (regie_stage) – Entwurf B „Heute Abend führt ihr Regie“.
   Saal oben (Licht-Wash, Nebel, Spots, Leinwand, Tische, Gast-Handy), Pult darunter. Alles mit Präfix .erl-rg-. */

.erl-rg {
  --rg-gold: #d2b27a;
  --rg-gold-hi: #e6c993;
  --rg-mut: #b9ae9d;
  --rg-text: #e9e3d8;
  --rg-dim: #6e675e;
  --rg-panel: #1c1916;
  --rg-key: #26211d;
  --rg-key-on: #4a3d2e;
  --rg-edge: rgba(243, 240, 234, .1);
  margin-top: clamp(36px, 5vw, 56px);
  font-family: var(--sans);
  font-stretch: 100%;
  letter-spacing: 0;
  line-height: 1.4;
  color: var(--paper);
}
.erl-rg *, .erl-rg *::before, .erl-rg *::after { box-sizing: border-box; }
.erl-rg button { -webkit-tap-highlight-color: transparent; }
.erl-rg button:focus-visible, .erl-rg .erl-rg-input:focus-visible { outline: 2px solid var(--rg-gold); outline-offset: 2px; }

/* Zähler über dem Saal */
.erl-rg-meta { display: flex; justify-content: flex-end; gap: 28px; margin-bottom: 18px; font-size: 14px; color: var(--rg-mut); }
.erl-rg-meta > div { display: flex; flex-direction: column; }
.erl-rg-meta b { font-size: 40px; line-height: 1.1; font-weight: 800; font-stretch: 125%; color: var(--paper); font-variant-numeric: tabular-nums; }
.erl-rg-sec:not(.dark) .erl-rg-meta { color: var(--muted); }
.erl-rg-sec:not(.dark) .erl-rg-meta b { color: var(--ink); }

/* Saal */
.erl-rg-hall { position: relative; }
.erl-rg-stage { position: relative; height: 460px; border-radius: 24px; overflow: hidden; background: #15110f; isolation: isolate; }
.erl-rg-layer { position: absolute; inset: 0; pointer-events: none; }
.erl-rg-wash { opacity: 0; transition: opacity 1.2s ease; }
.erl-rg-wash.is-on { opacity: 1; }
.erl-rg-haze { opacity: 0; transition: opacity 1.2s ease; background: radial-gradient(ellipse at 50% 70%, rgba(230, 226, 220, .32), rgba(230, 226, 220, 0) 70%); }
.erl-rg-haze.is-on { opacity: 1; animation: erl-rg-drift 9s ease-in-out infinite alternate; }
@keyframes erl-rg-drift { 0% { transform: translateX(-3%) scale(1); } 100% { transform: translateX(3%) scale(1.06); } }
.erl-rg-beam {
  position: absolute; top: -10px; width: 260px; height: 520px; margin-left: -130px; transform-origin: 50% 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 240, 214, .55), rgba(255, 240, 214, 0) 85%);
  clip-path: polygon(46% 0, 54% 0, 100% 100%, 0 100%); opacity: 0; transition: opacity 1s ease;
}
.erl-rg-beam.is-on { opacity: 1; }
.erl-rg-sway1 { animation: erl-rg-sway 5s ease-in-out infinite alternate; }
.erl-rg-sway2 { animation: erl-rg-sway2 6s ease-in-out infinite alternate; }
@keyframes erl-rg-sway { 0% { transform: rotate(-16deg); } 100% { transform: rotate(10deg); } }
@keyframes erl-rg-sway2 { 0% { transform: rotate(14deg); } 100% { transform: rotate(-10deg); } }
.erl-rg-floor { position: absolute; left: 0; right: 0; bottom: 0; height: 150px; background: linear-gradient(180deg, #1d1814, #0c0a09); }

/* Leinwand */
.erl-rg-scname { position: absolute; left: 50%; top: 18px; width: 180px; margin-left: -90px; text-align: center; font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--rg-dim); }
.erl-rg-screen {
  position: absolute; left: 30%; top: 44px; width: 40%; aspect-ratio: 16 / 9; border-radius: 6px; background: #0b0a09; border: 6px solid #050404;
  overflow: hidden; transition: box-shadow 1s ease; container-type: inline-size; color: var(--paper);
}
.erl-rg-screen.is-glow { box-shadow: 0 0 80px rgba(210, 178, 122, .18); }
.erl-rg-sc { position: absolute; inset: 0; display: none; background: #161412; }
.erl-rg-sc.is-on { display: flex; }
.erl-rg-serif { font-family: var(--serif); font-style: italic; font-weight: 400; }
.erl-rg-kicker {
  font-size: 10px; font-size: clamp(8px, 2.1cqw, 11px); font-weight: 600; font-stretch: 125%; letter-spacing: .16em; text-transform: uppercase; color: var(--rg-gold);
}
.erl-rg-sub { font-size: 13px; font-size: clamp(9px, 2.75cqw, 14px); color: var(--rg-mut); }
.erl-rg-big { font-size: 42px; font-size: clamp(20px, 8.8cqw, 46px); line-height: 1.05; font-weight: 800; font-stretch: 125%; }

.erl-rg-sc-ablauf { flex-direction: column; justify-content: center; padding: 0 9%; gap: 6%; }
.erl-rg-sc-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 26px; font-size: clamp(14px, 5.4cqw, 28px); }
.erl-rg-sc-clock { font-weight: 300; font-variant-numeric: tabular-nums; }
.erl-rg-sc-rows { display: flex; flex-direction: column; gap: 6px; gap: 1.6cqw; }
.erl-rg-sc-row { display: flex; gap: 14px; font-size: 14px; font-size: clamp(9px, 2.9cqw, 15px); color: var(--rg-mut); }
.erl-rg-sc-row span:first-child { width: 3.2em; flex: none; font-variant-numeric: tabular-nums; }
.erl-rg-sc-row.is-now { color: var(--rg-gold); }

.erl-rg-sc-buffet, .erl-rg-sc-heim, .erl-rg-sc-say { flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 4px; padding: 0 8%; }
.erl-rg-bf-open, .erl-rg-bf-call { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.erl-rg-bf-open[hidden], .erl-rg-bf-call[hidden] { display: none; }
.erl-rg-home { font-size: 30px; font-size: clamp(16px, 6.3cqw, 32px); line-height: 1.1; }
.erl-rg-sc-heim { gap: 6px; }
.erl-rg-sc-say { background: var(--bronze); color: #fff; gap: 6px; }
.erl-rg-sc-say .erl-rg-kicker { color: #fff; }
.erl-rg-say-text { font-size: 26px; font-size: clamp(14px, 5.4cqw, 28px); line-height: 1.1; overflow-wrap: anywhere; }

.erl-rg-sc-quiz { flex-direction: column; justify-content: center; gap: 4%; padding: 6% 7%; }
.erl-rg-q { font-size: 17px; font-size: clamp(11px, 3.6cqw, 19px); line-height: 1.15; }
.erl-rg-bar { position: relative; flex: 0 0 auto; height: 18%; min-height: 16px; border-radius: 4px; background: rgba(243, 240, 234, .1); overflow: hidden; }
.erl-rg-barfill { position: absolute; top: 0; left: 0; height: 100%; background: var(--bronze); transition: width 1.2s cubic-bezier(.2, .8, .2, 1), background .4s ease; }
.erl-rg-barfill.is-right { background: var(--rg-gold); }
.erl-rg-bartext { position: relative; height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 8px; font-size: 10px; font-size: clamp(8px, 2.2cqw, 12px); white-space: nowrap; }
.erl-rg-bartext span:first-child { overflow: hidden; text-overflow: ellipsis; }

.erl-rg-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1s ease; }
.erl-rg-photo.is-on { opacity: 1; }
.erl-rg-dia-cap { position: absolute; left: 10px; bottom: 8px; font-size: 10px; font-size: clamp(8px, 2.1cqw, 11px); letter-spacing: .14em; text-transform: uppercase; color: var(--paper); text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }

/* Tische mit Stühlen (Punkte) */
.erl-rg-table {
  position: absolute; bottom: 34px; height: 44px; border-radius: 50%; background: #2a231d; border: 1px solid rgba(243, 240, 234, .12);
  display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: var(--rg-mut);
  transition: background .6s ease, box-shadow .6s ease, color .6s ease;
}
.erl-rg-table i { position: absolute; top: -14px; width: 10px; height: 10px; border-radius: 50%; background: #4a3f35; }
.erl-rg-table i:nth-child(2) { top: -16px; }
.erl-rg-table.is-on { background: var(--bronze); color: #fff; box-shadow: 0 0 40px rgba(210, 178, 122, .7); }
.erl-rg-table.is-on i { background: var(--paper); animation: erl-rg-blink 1s ease-in-out infinite; }
@keyframes erl-rg-blink { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }

.erl-rg-fx { opacity: 0; background: radial-gradient(ellipse at 50% 100%, rgba(255, 250, 240, .55), rgba(255, 250, 240, 0) 60%); }
.erl-rg-fx.is-on { animation: erl-rg-fx 1.6s ease-out; }
@keyframes erl-rg-fx { 0% { opacity: 0; } 20% { opacity: 1; } 100% { opacity: 0; } }

.erl-rg-pills { position: absolute; left: 20px; top: 18px; display: flex; gap: 8px; flex-wrap: wrap; max-width: 26%; }
.erl-rg-pills > span { padding: 6px 12px; border-radius: 99px; background: rgba(14, 12, 11, .7); font-size: 12px; white-space: nowrap; }

/* Gast-Handy oben rechts */
.erl-rg-phone { position: absolute; right: 22px; top: 18px; width: 128px; height: 236px; border-radius: 22px; background: #050404; padding: 6px; z-index: 2; }
.erl-rg-phone-in {
  width: 100%; height: 100%; border-radius: 17px; background: var(--paper); color: var(--ink); padding: 22px 10px 10px;
  display: flex; flex-direction: column; gap: 6px; font-size: 10px; line-height: 1.3; overflow: hidden;
}
.erl-rg-phone-name { font-weight: 700; font-size: 11px; }
.erl-rg-phone-note, .erl-rg-phone-sub { color: var(--muted); }
.erl-rg-phone-msg { margin-top: 6px; padding: 8px; border-radius: 10px; background: var(--stone); color: var(--ink); font-size: 12px; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; transition: background .4s ease, color .4s ease; }
.erl-rg-phone-msg.is-hit { background: var(--bronze); color: #fff; }
.erl-rg-phone-msg.is-say { background: var(--ink); color: var(--paper); }
.erl-rg-phone-sub { margin-top: auto; }

.erl-rg-pop { animation: erl-rg-pop .5s cubic-bezier(.2, 1.4, .4, 1); }
@keyframes erl-rg-pop { 0% { transform: scale(.7); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }

/* Pult */
.erl-rg-desk { display: flex; flex-wrap: wrap; gap: 20px; margin-top: 24px; }
.erl-rg-panel { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 14px; padding: 22px; border-radius: 24px; background: var(--rg-panel); border: 1px solid var(--rg-edge); }
.erl-rg-label { font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--rg-mut); }
.erl-rg-label-log { margin-top: 4px; }
.erl-rg-grid { display: grid; gap: 8px; }
.erl-rg-grid-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.erl-rg-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.erl-rg-grid-t { grid-template-columns: repeat(auto-fit, minmax(44px, 1fr)); }

.erl-rg-key {
  min-height: 52px; padding: 0 14px; border-radius: 14px; border: 1px solid rgba(243, 240, 234, .14); background: var(--rg-key); color: var(--paper);
  font: 600 13px/1.2 var(--sans); font-stretch: 100%; letter-spacing: 0; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: background .2s ease, border-color .2s ease, transform .1s ease;
}
.erl-rg-key:hover { border-color: var(--rg-gold); }
.erl-rg-key:active { transform: scale(.97); }
.erl-rg-key.is-on { background: var(--rg-key-on); border-color: var(--rg-gold); color: #fff; }
.erl-rg-tkey { padding: 0; }
.erl-rg-tkey.is-done { color: var(--rg-mut); }

.erl-rg-sw { width: 100%; min-width: 0; height: 52px; padding: 0 2px; border-radius: 14px; border: 2px solid transparent; cursor: pointer; font: 600 12px/1.1 var(--sans); font-stretch: 100%; color: var(--ink); overflow: hidden; text-overflow: ellipsis; transition: border-color .2s ease, transform .1s ease; }
.erl-rg-sw:active { transform: scale(.97); }
.erl-rg-sw.is-on { border-color: var(--paper); }
.erl-rg-sw-blau { color: #fff; }
.erl-rg-sw-party { background: linear-gradient(90deg, #c86bd6, #4f6fd8, #e8a25a); color: #fff; }

.erl-rg-plan { display: flex; flex-direction: column; gap: 4px; }
.erl-rg-plan-row {
  display: flex; gap: 12px; align-items: center; width: 100%; min-height: 44px; padding: 8px 10px; border: 0; border-radius: 10px; background: transparent;
  color: var(--rg-mut); font: 400 14px/1.3 var(--sans); font-stretch: 100%; text-align: left; cursor: pointer; transition: background .2s ease, color .2s ease, opacity .2s ease;
}
.erl-rg-plan-row:hover { background: rgba(243, 240, 234, .05); }
.erl-rg-plan-row.is-now { background: var(--rg-key); color: #fff; }
.erl-rg-plan-row.is-past { opacity: .45; }
.erl-rg-plan-time { width: 46px; flex: none; font-variant-numeric: tabular-nums; }
.erl-rg-plan-title { flex: 1; min-width: 0; }
.erl-rg-plan-mark { font-size: 12px; color: var(--rg-gold); }

.erl-rg-next {
  width: 100%; min-height: 72px; margin-top: auto; padding: 0 22px; border: 0; border-radius: 18px; background: var(--rg-gold); color: var(--ink);
  font: 700 16px/1.2 var(--sans); font-stretch: 125%; letter-spacing: .08em; text-transform: uppercase; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; text-align: left; transition: background .2s ease, transform .1s ease;
}
.erl-rg-next:hover { background: var(--rg-gold-hi); }
.erl-rg-next:active { transform: scale(.985); }

.erl-rg-say { display: flex; gap: 8px; margin: 0; }
.erl-rg-say .erl-rg-key { flex: none; }
.erl-rg-input {
  flex: 1; min-width: 0; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid rgba(243, 240, 234, .2); background: #0e0c0b; color: var(--paper);
  font: 500 15px var(--sans); font-stretch: 100%; letter-spacing: 0;
}
.erl-rg-input::placeholder { color: var(--rg-dim); }

.erl-rg-log { max-height: 150px; overflow-y: auto; overscroll-behavior: contain; }
.erl-rg-log-list { list-style: none; margin: 0; padding: 0; }
.erl-rg-log-list li { display: flex; gap: 12px; padding: 6px 0; border-bottom: 1px solid rgba(243, 240, 234, .08); font-size: 13px; color: var(--rg-text); }
.erl-rg-log-list time { width: 44px; flex: none; color: var(--rg-gold); font-variant-numeric: tabular-nums; }
.erl-rg-log-empty { font-size: 13px; color: var(--rg-dim); }
.erl-rg-log-empty[hidden] { display: none; }

/* Mittlere Breite: Leinwand etwas breiter, Handy schmaler */
@media (max-width: 1000px) {
  .erl-rg-screen { left: 26%; width: 48%; }
  .erl-rg-phone { right: 14px; width: 112px; height: 210px; }
  .erl-rg-pills { left: 14px; max-width: 22%; }
  .erl-rg-pills > span { white-space: normal; }
}

/* Handy: Saal flacher, Leinwand breit, Gast-Handy unter dem Saal */
@media (max-width: 760px) {
  .erl-rg-meta { justify-content: flex-start; gap: 24px; }
  .erl-rg-meta b { font-size: 32px; }
  .erl-rg-stage { height: 300px; border-radius: 18px; }
  .erl-rg-scname { display: none; }
  .erl-rg-screen { left: 9%; width: 82%; top: 50px; border-width: 4px; }
  .erl-rg-pills { left: 12px; top: 12px; max-width: none; right: 12px; }
  .erl-rg-pills > span { padding: 4px 10px; font-size: 11px; white-space: nowrap; }
  .erl-rg-beam { width: 160px; height: 340px; margin-left: -80px; }
  .erl-rg-floor { height: 90px; }
  .erl-rg-table { bottom: 14px; height: 26px; font-size: 11px; }
  .erl-rg-table i { width: 7px; height: 7px; top: -10px; }
  .erl-rg-table i:nth-child(2) { top: -11px; }
  .erl-rg-phone { position: relative; right: auto; top: auto; width: auto; height: auto; margin-top: 12px; border-radius: 22px; }
  .erl-rg-phone-in { padding: 14px 14px 12px; font-size: 12px; display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; }
  .erl-rg-phone-name { font-size: 13px; }
  .erl-rg-phone-note { text-align: right; }
  .erl-rg-phone-msg { grid-column: 1 / -1; margin-top: 4px; font-size: 15px; padding: 10px 12px; }
  .erl-rg-phone-sub { grid-column: 1 / -1; margin-top: 0; }
  .erl-rg-desk { gap: 14px; margin-top: 16px; }
  .erl-rg-panel { padding: 18px; border-radius: 20px; }
  .erl-rg-next { min-height: 64px; font-size: 14px; padding: 0 18px; }
  .erl-rg-input { font-size: 16px; }
  .erl-rg-sw { font-size: 11px; }
}

/* Weniger Bewegung: keine Schwenks, kein Aufploppen, kein Nebeltreiben */
@media (prefers-reduced-motion: reduce) {
  .erl-rg-sway1, .erl-rg-sway2, .erl-rg-haze.is-on, .erl-rg-table.is-on i, .erl-rg-pop { animation: none; }
  .erl-rg-sway1 { transform: rotate(-6deg); }
  .erl-rg-sway2 { transform: rotate(6deg); }
  .erl-rg-fx.is-on { animation-duration: .8s; }
  .erl-rg-barfill { transition-duration: .2s; }
}
