/* Hall plan with bookable tables + "ticket / table" switch (site, mini app) */

/* ---------- "add a table" switch ---------- */
.addon { display: grid; gap: 14px; padding: 6px; border-radius: 20px; background: rgba(10, 6, 34, 0.55); border: 1px solid var(--line); transition: border-color 0.4s, box-shadow 0.4s; }
.addon.on { border-color: rgba(255, 211, 110, 0.55); box-shadow: 0 0 40px -18px rgba(255, 211, 110, 0.8); }
.addon.off { opacity: 0.5; }
.addon-toggle {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; padding: 10px 10px 10px 12px;
  border: 0; border-radius: 14px; background: none; color: var(--text); font: inherit; text-align: left; cursor: pointer;
}
.addon-toggle:disabled { cursor: not-allowed; }
.addon-ico { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; font-size: 1.3rem; background: linear-gradient(135deg, rgba(255, 211, 110, 0.25), rgba(255, 79, 216, 0.25)); border: 1px solid rgba(255, 211, 110, 0.4); }
.addon-t { display: grid; gap: 2px; min-width: 0; }
.addon-t b { font-size: 0.98rem; }
.addon-t small { color: var(--muted); font-size: 0.78rem; }
.switch { position: relative; width: 50px; height: 30px; border-radius: 999px; background: rgba(255, 255, 255, 0.12); border: 1px solid var(--line); transition: background 0.4s, border-color 0.4s; }
.switch i { position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4); transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1); }
.addon.on .switch { background: linear-gradient(120deg, #ffb347, #ff4fd8); border-color: transparent; }
.addon.on .switch i { transform: translateX(20px); }
.addon-body { display: grid; gap: 12px; padding: 0 4px 6px; animation: pane-in 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes pane-in { from { opacity: 0; transform: translateY(10px); } }

.tf-sum { display: grid; gap: 6px; padding: 12px 14px; border-radius: 14px; background: rgba(139, 92, 246, 0.1); border: 1px solid var(--line); font-size: 0.86rem; }
.tf-sum div { display: flex; justify-content: space-between; gap: 12px; }
.tf-sum span { color: #ddd5ff; min-width: 0; }
.tf-sum b { white-space: nowrap; }

/* ---------- plan ---------- */
.fl { display: grid; gap: 12px; }
.fl-svg {
  display: block; width: 100%; height: auto; border-radius: 22px; overflow: hidden;
  background: radial-gradient(90% 60% at 50% 0%, rgba(139, 92, 246, 0.22), transparent 70%), #0a0624;
  box-shadow: inset 0 0 0 1px rgba(200, 170, 255, 0.18), 0 30px 80px -40px rgba(139, 92, 246, 0.9);
  -webkit-tap-highlight-color: transparent; user-select: none;
}
.fl-svg text { font-family: var(--font-display); text-anchor: middle; dominant-baseline: central; pointer-events: none; }

.fl-wall { fill: none; stroke: rgba(200, 180, 255, 0.55); stroke-width: 8; stroke-linecap: square; }
.fl-door path { fill: none; stroke: rgba(200, 180, 255, 0.4); stroke-width: 3; stroke-dasharray: 8 8; }
.fl-door text { fill: rgba(200, 180, 255, 0.75); font-size: 24px; font-weight: 700; letter-spacing: 4px; }
.fl-sofa rect { fill: rgba(139, 92, 246, 0.12); stroke: rgba(200, 180, 255, 0.3); stroke-width: 3; }

.fl-dance rect { fill: rgba(139, 92, 246, 0.05); stroke: rgba(200, 170, 255, 0.16); stroke-width: 3; stroke-dasharray: 14 12; }
.fl-dance text { fill: rgba(255, 255, 255, 0.08); font-size: 46px; font-weight: 800; letter-spacing: 10px; }

/* DJ booth */
.fl-screen { animation: fl-led 3.2s ease-in-out infinite; }
@keyframes fl-led { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }
.fl-console { fill: #150c3a; stroke: #ff4fd8; stroke-width: 4; }
.fl-spk { fill: #0a0624; stroke: rgba(255, 255, 255, 0.85); stroke-width: 4; }
.fl-spk-in { fill: #ff4fd8; }
.fl-ring { fill: none; stroke: #ff4fd8; stroke-width: 3; transform-box: fill-box; transform-origin: center; animation: fl-ring 1s ease-out infinite; }
@keyframes fl-ring { from { opacity: 0.9; transform: scale(1); } to { opacity: 0; transform: scale(2.1); } }
.fl-faders line { stroke: rgba(255, 255, 255, 0.4); stroke-width: 3; }
.fl-knob { fill: #59e1ff; animation: fl-knob 0.9s ease-in-out infinite alternate; animation-delay: calc(var(--k) * -0.27s); }
@keyframes fl-knob { from { transform: translateY(-12px); } to { transform: translateY(12px); } }
.fl-djt { fill: #fff; font-size: 26px; font-weight: 800; letter-spacing: 10px; opacity: 0.85; }
.fl-beam { opacity: 0.42; animation: fl-sweep 6s ease-in-out infinite alternate; }
.fl-beam.b2 { animation-delay: -3s; animation-direction: alternate-reverse; }
@keyframes fl-sweep { from { transform: rotate(-12deg); } to { transform: rotate(12deg); } }

/* tables */
.fl-t { --tc: #59e1ff; cursor: pointer; outline: none; transform-box: fill-box; transform-origin: center; transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1); transition-delay: calc(var(--i) * 70ms); }
.fl:not(.in) .fl-t { opacity: 0; transform: scale(0.7); }
.fl-t.tier-1 { --tc: #b794ff; }
.fl-t.tier-2 { --tc: #ffd36e; }
.fl-hit { fill: transparent; }
.fl-halo { fill: var(--tc); opacity: 0; transition: opacity 0.4s; }
.fl-ch rect { fill: rgba(10, 6, 36, 0.9); stroke: var(--tc); stroke-width: 3; transition: fill 0.4s; }
.fl-top { fill: rgba(20, 12, 58, 0.95); stroke: var(--tc); stroke-width: 4; transition: fill 0.4s, stroke-width 0.3s; }
.fl-num { fill: #fff; font-size: 42px; font-weight: 800; transition: fill 0.4s; }
.fl-cap { fill: var(--tc); font-size: 19px; font-weight: 600; letter-spacing: 1px; }

.fl-t.free:hover .fl-halo, .fl-t.free:focus-visible .fl-halo { opacity: 0.16; }
.fl-t.free:hover .fl-top, .fl-t.free:focus-visible .fl-top { stroke-width: 6; }
.fl-t.sel .fl-halo { opacity: 0.55; animation: fl-glow 1.6s ease-in-out infinite; }
@keyframes fl-glow { 50% { opacity: 0.3; } }
.fl-t.sel .fl-top { fill: var(--tc); stroke: #fff; }
.fl-t.sel .fl-ch rect { fill: var(--tc); stroke: #fff; }
.fl-t.sel .fl-num, .fl-t.sel .fl-cap { fill: #12082f; }

.fl-t.busy { cursor: not-allowed; }
.fl-t.busy .fl-top { fill: #1a1534; stroke: rgba(255, 255, 255, 0.18); }
.fl-t.busy .fl-ch rect { stroke: rgba(255, 255, 255, 0.14); }
.fl-t.busy .fl-num { fill: rgba(255, 255, 255, 0.3); }
.fl-t.busy .fl-cap { fill: rgba(255, 120, 150, 0.7); }
.fl-t.nope { animation: fl-nope 0.5s; }
@keyframes fl-nope { 20%, 60% { transform: translateX(-10px); } 40%, 80% { transform: translateX(10px); } }

/* small plans: just big numbers, details go to the legend / picked card */
.fl-compact .fl-cap { display: none; }
.fl-compact .fl-num { font-size: 50px; transform: translateY(9px); }
@media (max-width: 520px) {
  .fl-cap { display: none; }
  .fl-num { font-size: 50px; transform: translateY(9px); }
}

/* legend */
.fl-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 14px; font-size: 0.74rem; color: var(--muted); }
.fl-legend .lg { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.fl-legend i { width: 14px; height: 10px; border-radius: 3px; border: 2px solid var(--tc, #59e1ff); background: rgba(20, 12, 58, 0.95); }
.fl-legend .tier-1 { --tc: #b794ff; }
.fl-legend .tier-2 { --tc: #ffd36e; }
.fl-legend .lg-busy i { border-color: rgba(255, 255, 255, 0.2); background: repeating-linear-gradient(45deg, #1a1534 0 3px, #2a2450 3px 6px); }

/* picked table */
.tb-hint { margin: 0; padding: 14px; border-radius: 16px; text-align: center; font-size: 0.88rem; color: #ddd5ff; background: rgba(139, 92, 246, 0.1); border: 1px dashed rgba(200, 170, 255, 0.35); }
.tb-hint.warn { color: #ffb3c4; border-color: rgba(255, 79, 120, 0.5); background: rgba(255, 79, 120, 0.08); }
.tb-card {
  --tc: #59e1ff; min-width: 0; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; padding: 12px 16px 12px 12px; border-radius: 18px;
  background: linear-gradient(120deg, color-mix(in srgb, var(--tc) 22%, transparent), rgba(20, 12, 58, 0.8));
  border: 1px solid var(--tc); box-shadow: 0 0 30px -10px var(--tc); animation: pane-in 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.tb-card.tier-1 { --tc: #b794ff; }
.tb-card.tier-2 { --tc: #ffd36e; }
.tb-num { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: var(--tc); color: #12082f; font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; }
.tbc-info { display: grid; gap: 2px; min-width: 0; }
.tbc-info b { font-size: 1rem; }
.tbc-info small { color: var(--muted); font-size: 0.78rem; }
.tbc-price { font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
  .fl-beam, .fl-ring, .fl-knob, .fl-screen, .fl-t.sel .fl-halo { animation: none; }
  .fl:not(.in) .fl-t { opacity: 1; transform: none; }
}

/* loops stop while the plan is off screen */
.fl.off *, .fl.off { animation-play-state: paused !important; }
