/* Live floor: interactive floor plan with table states, nudges feed, KPI strip and camera views. */
.fl-head { max-width: 760px; margin: 0 auto clamp(48px, 6vw, 80px); display: grid; justify-items: center; gap: 18px; }
.fl-eyebrow { color: var(--mist); }
.fl-sub { max-width: 560px; }

.fl-app { position: relative; border-radius: 10px; overflow: hidden; background: linear-gradient(180deg, #141414, #0e0e0e); border: 1px solid var(--line); box-shadow: 0 40px 120px -40px rgba(61, 111, 245, 0.18), 0 0 0 1px rgba(255, 255, 255, 0.02) inset; }
.fl-app::before { content: ""; position: absolute; inset: 0 0 auto; height: 1px; background: linear-gradient(90deg, transparent, rgba(110, 147, 247, 0.5), transparent); opacity: .6; pointer-events: none; }

/* top bar */
.fl-top { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; min-height: 56px; padding: 10px 20px; border-bottom: 1px solid var(--line); }
.fl-venue { display: flex; align-items: center; gap: 10px; min-width: 0; }
.fl-venue img { width: 20px; height: auto; }
.fl-venue__name { font-size: 14px; color: var(--fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fl-venue__name span { color: var(--mist); }
.fl-live { display: inline-flex; align-items: center; gap: 7px; padding: 4px 9px; border: 1px solid rgba(248, 113, 113, 0.35); border-radius: 999px; color: #fca5a5; font: 500 10.5px/1 var(--f-mono); letter-spacing: 0.1em; text-transform: uppercase; }
.fl-live i { width: 6px; height: 6px; border-radius: 50%; background: #ef4444; box-shadow: 0 0 8px rgba(239, 68, 68, 0.9); animation: flRec 1.6s steps(1) infinite; }
@keyframes flRec { 50% { opacity: .25; } }
.fl-seg { display: inline-flex; padding: 3px; border-radius: 6px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); }
.fl-seg button { border: 0; background: transparent; padding: 7px 14px; border-radius: 4px; color: var(--mist); font: 500 11px/1 var(--f-mono); letter-spacing: 0.1em; text-transform: uppercase; cursor: pointer; transition: background .2s var(--ease), color .2s var(--ease); }
.fl-seg button:hover { color: #fff; }
.fl-seg button[aria-selected="true"] { background: rgba(255, 255, 255, 0.12); color: #fff; }
.fl-meta { display: flex; align-items: center; justify-content: flex-end; gap: 14px; }
.fl-clock { color: var(--fg-2); font-size: 12.5px; }

/* KPI strip */
.fl-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
.fl-kpi { position: relative; display: grid; gap: 8px; padding: 18px 20px 16px; border-right: 1px solid var(--line); min-width: 0; }
.fl-kpi:last-child { border-right: 0; }
.fl-kpi b { font: 500 28px/1 var(--f-body); letter-spacing: -0.02em; color: #fff; transition: color .4s var(--ease); }
.fl-kpi b small { font-size: 14px; color: var(--mist); font-weight: 400; letter-spacing: 0; }
.fl-kpi b.is-tick { color: var(--blue-2); }
.fl-kpi__note { color: var(--mist-2); font-size: 12px; }
.fl-kpi__bar { position: relative; display: block; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.fl-kpi__bar i { position: absolute; inset: 0 auto 0 0; width: 70%; background: linear-gradient(90deg, var(--blue), var(--blue-2)); border-radius: 2px; transition: width .8s var(--ease-out); }

/* body: plan + feed */
.fl-body { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 340px; min-height: 560px; }
.fl-plan { position: relative; padding: 18px 20px 16px; border-right: 1px solid var(--line); min-width: 0; }
.fl-svg { width: 100%; height: auto; overflow: visible; user-select: none; -webkit-user-select: none; }
.fl-legend { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 10px; color: var(--mist); font: 500 10.5px/1 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; }
.fl-legend span { display: inline-flex; align-items: center; gap: 7px; }
.fl-legend i { width: 9px; height: 9px; border-radius: 2px; border: 1.5px solid var(--c); background: var(--cf); }
.fl-cov[hidden], .fl-legend[hidden] { display: none; }
.fl-cov { display: flex; align-items: center; gap: 14px; margin-top: 10px; flex-wrap: wrap; }
.fl-cov__ramp { width: 160px; height: 6px; border-radius: 3px; background: linear-gradient(90deg, rgba(61, 111, 245, 0.25), rgba(251, 191, 36, 0.55), rgba(248, 113, 113, 0.8)); }
.fl-cov__ticks { display: inline-flex; gap: 46px; color: var(--mist-2); font-size: 10.5px; }

/* state palette (used by the legend, the SVG tables and chips) */
.s-free { --c: rgba(255, 255, 255, 0.28); --cf: rgba(255, 255, 255, 0.03); }
.s-seated { --c: #6E93F7; --cf: rgba(110, 147, 247, 0.18); }
.s-served { --c: #E9E1D2; --cf: rgba(233, 225, 210, 0.12); }
.s-finished { --c: #FBBF24; --cf: rgba(251, 191, 36, 0.18); }
.s-paying { --c: #2DD4BF; --cf: rgba(45, 212, 191, 0.14); }
.s-clear { --c: #F87171; --cf: rgba(248, 113, 113, 0.2); }
.s-reset { --c: #34D399; --cf: rgba(52, 211, 153, 0.12); }

/* SVG */
.fl-wall { fill: rgba(255, 255, 255, 0.012); stroke: rgba(255, 255, 255, 0.16); stroke-width: 1.5; }
.fl-room { fill: rgba(255, 255, 255, 0.025); stroke: rgba(255, 255, 255, 0.1); stroke-width: 1; }
.fl-grid { stroke: rgba(255, 255, 255, 0.035); stroke-width: 1; }
.fl-lbl { fill: rgba(255, 255, 255, 0.32); font: 500 11px var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; }
.fl-lbl--dim { fill: rgba(255, 255, 255, 0.2); }
.fl-pass { fill: rgba(255, 255, 255, 0.08); stroke: rgba(255, 255, 255, 0.14); transition: fill .4s var(--ease), stroke .4s var(--ease); }
.fl-pass.is-wait { fill: rgba(251, 191, 36, 0.22); stroke: #FBBF24; }
.fl-plate { fill: none; stroke: #FBBF24; stroke-width: 2; opacity: 0; transition: opacity .3s var(--ease); }
.fl-pass.is-wait + .fl-plate, .fl-plate.on { opacity: 1; }
.fl-station { fill: rgba(255, 255, 255, 0.035); stroke: rgba(255, 255, 255, 0.09); stroke-width: 1; }
.fl-counter { fill: rgba(255, 255, 255, 0.06); stroke: rgba(255, 255, 255, 0.12); }
.fl-stool { fill: rgba(255, 255, 255, 0.07); }
.fl-stool.on { fill: rgba(110, 147, 247, 0.4); }
.fl-door { stroke: var(--bg); stroke-width: 4; }
.fl-doorarc { fill: none; stroke: rgba(255, 255, 255, 0.18); stroke-width: 1; stroke-dasharray: 3 4; }
.fl-q { fill: rgba(255, 255, 255, 0.5); transition: opacity .5s var(--ease), transform .8s var(--ease-out); }
.fl-q.off { opacity: 0; }
.fl-zone { fill: var(--zf, rgba(61, 111, 245, 0.18)); stroke: none; opacity: 0; transition: opacity .6s var(--ease); }
.fl-app.is-coverage .fl-zone { opacity: 1; }
.fl-zone-lbl { fill: #fff; font: 500 12px var(--f-body); opacity: 0; transition: opacity .5s var(--ease); }
.fl-zone-sub { fill: rgba(255, 255, 255, 0.6); font: 500 10px var(--f-mono); letter-spacing: 0.06em; opacity: 0; transition: opacity .5s var(--ease); }
.fl-app.is-coverage .fl-zone-lbl, .fl-app.is-coverage .fl-zone-sub { opacity: 1; }
.fl-app.is-coverage .fl-t__shape { fill: rgba(255, 255, 255, 0.04); stroke: rgba(255, 255, 255, 0.3); }
.fl-app.is-coverage .fl-t__timer, .fl-app.is-coverage .fl-t__badge { opacity: 0; }

.fl-t { cursor: pointer; outline: none; }
.fl-t__hit { fill: transparent; }
.fl-t__shape { fill: var(--cf); stroke: var(--c); stroke-width: 1.6; transition: fill .7s var(--ease), stroke .7s var(--ease), stroke-width .2s var(--ease); }
.fl-t.s-reset .fl-t__shape { stroke-dasharray: 5 4; animation: flDash 1.2s linear infinite; }
@keyframes flDash { to { stroke-dashoffset: -18; } }
.fl-t__seat { fill: rgba(255, 255, 255, 0.07); transition: fill .6s var(--ease); }
.fl-t__seat.on { fill: var(--c); fill-opacity: .7; }
.fl-t__num { fill: #fff; font: 600 15px var(--f-body); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.fl-t__timer { fill: rgba(255, 255, 255, 0.62); font: 500 10.5px var(--f-mono); text-anchor: middle; pointer-events: none; transition: opacity .3s var(--ease); }
.fl-t__ring { fill: none; stroke: var(--c); stroke-width: 1.5; opacity: 0; transform-box: fill-box; transform-origin: center; pointer-events: none; }
.fl-t.is-alert .fl-t__ring { animation: flRing 1.8s var(--ease-out) infinite; }
@keyframes flRing { 0% { opacity: .85; transform: scale(1); } 100% { opacity: 0; transform: scale(1.7); } }
.fl-t__badge { pointer-events: none; transition: opacity .3s var(--ease), transform .4s var(--ease-out); transform-box: fill-box; transform-origin: center; }
.fl-t__badge circle { fill: #ef4444; stroke: #0e0e0e; stroke-width: 2; }
.fl-t__badge path { fill: none; stroke: #fff; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.fl-t__badge.is-ok circle { fill: #10b981; }
.fl-t__badge.off { opacity: 0; transform: scale(.4); }
.fl-t:hover .fl-t__shape, .fl-t:focus-visible .fl-t__shape { stroke-width: 2.6; }
.fl-t.is-sel .fl-t__shape { stroke: #fff; stroke-width: 2.6; }
.fl-t.is-hint .fl-t__ring { animation: flRing 1.8s var(--ease-out) infinite; stroke: #fff; }
.fl-hint { fill: rgba(255, 255, 255, 0.85); font: 500 11px var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; pointer-events: none; transition: opacity .4s var(--ease); }
.fl-hintline { stroke: rgba(255, 255, 255, 0.4); stroke-width: 1; stroke-dasharray: 2 3; transition: opacity .4s var(--ease); }
.fl-svg.is-touched .fl-hint, .fl-svg.is-touched .fl-hintline { opacity: 0; }

/* tooltip */
.fl-tip { position: absolute; z-index: 3; min-width: 190px; padding: 10px 12px; border-radius: 6px; background: rgba(20, 20, 20, 0.96); border: 1px solid var(--line-2); box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5); pointer-events: none; opacity: 0; transform: translateY(4px); transition: opacity .15s var(--ease), transform .2s var(--ease-out); }
.fl-tip.on { opacity: 1; transform: none; }
.fl-tip b { display: block; font: 500 13.5px/1.3 var(--f-body); color: #fff; }
.fl-tip span { display: block; margin-top: 4px; color: var(--mist); font-size: 12px; line-height: 1.45; }
.fl-tip em { font-style: normal; color: var(--c, #fff); }

/* feed */
.fl-feed { display: flex; flex-direction: column; padding: 18px 18px 14px; min-width: 0; }
.fl-feed__head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; }
.fl-feed__count { color: var(--mist-2); font-size: 11px; }
.fl-feed__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; align-content: start; flex: 1; overflow: hidden; }
.fl-n { position: relative; }
.fl-n button { width: 100%; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 10px; align-items: start; text-align: left; padding: 11px 12px 11px 10px; border: 1px solid var(--line); border-radius: 7px; background: rgba(255, 255, 255, 0.025); cursor: pointer; transition: background .2s var(--ease), border-color .2s var(--ease); }
.fl-n button:hover { background: rgba(255, 255, 255, 0.055); border-color: var(--line-2); }
.fl-n__ic { width: 28px; height: 28px; border-radius: 6px; display: grid; place-items: center; background: var(--cf); color: var(--c); }
.fl-n__ic svg { width: 15px; height: 15px; }
.fl-n__t { display: block; color: #fff; font-size: 13.5px; line-height: 1.3; }
.fl-n__d { display: block; margin-top: 3px; color: var(--mist); font-size: 12px; line-height: 1.4; }
.fl-n__m { color: var(--mist-2); font: 500 10.5px/1.3 var(--f-mono); white-space: nowrap; }
.fl-n.is-new button { animation: flIn .7s var(--ease-out) both; }
@keyframes flIn { from { opacity: 0; transform: translateY(-10px) scale(.98); } }
.fl-n.is-new button::after { content: ""; position: absolute; inset: 0; border-radius: 7px; box-shadow: 0 0 0 1px var(--c) inset; opacity: .7; animation: flFlash 1.6s var(--ease) forwards; pointer-events: none; }
@keyframes flFlash { to { opacity: 0; } }
.fl-feed__foot { margin-top: 12px; color: var(--mist-2); font-size: 12px; }

/* camera card */
.fl-cam { position: absolute; inset: 0; z-index: 5; display: grid; place-items: center; padding: 20px; background: rgba(10, 10, 10, 0.7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); animation: flFade .3s var(--ease) both; }
.fl-cam[hidden] { display: none !important; }
@keyframes flFade { from { opacity: 0; } }
.fl-cam__card { width: min(980px, 100%); max-height: 100%; overflow: auto; display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); border-radius: 10px; border: 1px solid var(--line-2); background: #121212; box-shadow: 0 40px 100px rgba(0, 0, 0, 0.6); animation: flPop .45s var(--ease-out) both; }
@keyframes flPop { from { opacity: 0; transform: translateY(10px) scale(.98); } }
.fl-cam__left { display: grid; grid-template-rows: auto minmax(88px, 1fr) auto; min-width: 0; background: #0d0d0d; border-right: 1px solid var(--line); }
.fl-cam__log { position: relative; min-height: 0; overflow: hidden; border-bottom: 1px solid var(--line); }
.fl-cam__log .label { position: absolute; left: 14px; top: 12px; color: var(--mist-2); font-size: 10px; }
.fl-cam__log ol { position: absolute; left: 14px; right: 14px; top: 32px; bottom: 8px; list-style: none; margin: 0; padding: 0; overflow: hidden; display: grid; align-content: start; gap: 6px; }
.fl-cam__log li { display: grid; grid-template-columns: 64px 10px minmax(0, 1fr); align-items: center; gap: 8px; color: var(--fg-2); font-size: 12.5px; white-space: nowrap; }
.fl-cam__log li span { color: var(--mist-2); font: 500 11px/1 var(--f-mono); font-variant-numeric: tabular-nums; }
.fl-cam__log li i { width: 6px; height: 6px; border-radius: 1px; background: var(--c, #6E93F7); }
.fl-cam__log li b { font-weight: 400; overflow: hidden; text-overflow: ellipsis; }
.fl-cam__cap { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; padding: 12px 14px; color: var(--mist); font: 500 10px/1.2 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; }
.fl-cam__key { display: inline-flex; align-items: center; gap: 7px; }
.fl-cam__key i { width: 10px; height: 10px; border: 1.5px solid; border-radius: 1px; }
.fl-cam__key .k-guest { border-color: #6E93F7; }
.fl-cam__key .k-staff { border-color: #34D399; }
.fl-cam__key .k-alert { border-color: #FBBF24; }
.fl-cam__cap em { margin-left: auto; font-style: normal; color: var(--mist-2); }
.fl-cam__media { position: relative; aspect-ratio: 16 / 9; background: #050505 center / cover no-repeat; overflow: hidden; }
.fl-cam__video, .fl-cam__fx { position: absolute; inset: 0; width: 100%; height: 100%; }
.fl-cam__video { object-fit: cover; filter: saturate(.92) contrast(1.03); }
.fl-cam__tag { position: absolute; left: 12px; top: 12px; display: inline-flex; align-items: center; gap: 8px; padding: 6px 9px; border-radius: 4px; background: rgba(0, 0, 0, 0.55); color: #fff; font: 500 10.5px/1 var(--f-mono); letter-spacing: 0.1em; text-transform: uppercase; }
.fl-cam__tag i { width: 6px; height: 6px; border-radius: 50%; background: #ef4444; animation: flRec 1.6s steps(1) infinite; }
.fl-cam__time { position: absolute; right: 12px; bottom: 10px; color: rgba(255, 255, 255, 0.8); font-size: 11px; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6); }
.fl-cam__info { padding: 20px 22px 22px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.fl-cam__row { display: flex; justify-content: space-between; align-items: center; }
.fl-chip { display: inline-flex; align-items: center; gap: 7px; padding: 5px 10px; border-radius: 999px; background: var(--cf); color: var(--c); border: 1px solid var(--c); font: 500 10.5px/1 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; }
.fl-chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--c); }
.fl-cam__close { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 6px; border: 1px solid var(--line-2); background: transparent; color: #fff; cursor: pointer; transition: background .2s var(--ease); }
.fl-cam__close:hover { background: rgba(255, 255, 255, 0.08); }
.fl-cam__close svg { width: 14px; height: 14px; }
.fl-cam__head { font: 400 22px/1.2 var(--f-serif); letter-spacing: -0.01em; font-variation-settings: "opsz" 48; }
.fl-cam__what { color: var(--fg-2); font-size: 14px; line-height: 1.5; }
.fl-cam__facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 2px 0 0; }
.fl-cam__facts div { padding: 10px 12px; border-radius: 6px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--line); }
.fl-cam__facts dt { color: var(--mist); font: 500 10px/1.3 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; }
.fl-cam__facts dd { margin: 5px 0 0; color: #fff; font-size: 15px; font-variant-numeric: tabular-nums; }
.fl-cam__timeline { list-style: none; margin: 4px 0 0; padding: 0 0 0 14px; border-left: 1px solid var(--line-2); display: grid; gap: 9px; }
.fl-cam__timeline li { position: relative; display: flex; justify-content: space-between; gap: 10px; color: var(--mist); font-size: 12.5px; }
.fl-cam__timeline li::before { content: ""; position: absolute; left: -18px; top: 6px; width: 7px; height: 7px; border-radius: 50%; background: var(--c, #555); box-shadow: 0 0 0 3px #121212; }
.fl-cam__timeline li b { color: #fff; font-weight: 400; }
.fl-cam__timeline li span { font: 500 11px/1.4 var(--f-mono); color: var(--mist-2); }
.fl-cam__timeline li.is-now b { color: var(--c); }

/* responsive */
@media (max-width: 1100px) {
  .fl-body { grid-template-columns: minmax(0, 1fr) 290px; }
}
@media (max-width: 900px) {
  .fl-top { grid-template-columns: minmax(0, 1fr) auto; }
  .fl-meta { grid-column: 1 / -1; justify-content: space-between; order: 3; }
  .fl-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fl-kpi:nth-child(2) { border-right: 0; }
  .fl-kpi:nth-child(-n + 2) { border-bottom: 1px solid var(--line); }
  .fl-body { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .fl-plan { border-right: 0; border-bottom: 1px solid var(--line); padding: 12px 12px 14px; }
  .fl-feed__list { max-height: 360px; }
  .fl-cam { align-items: start; padding: 10px; }
  .fl-cam__card { grid-template-columns: minmax(0, 1fr); }
  .fl-cam__left { border-right: 0; border-bottom: 1px solid var(--line); }
  .fl-cam__cap { padding: 10px 12px; gap: 6px 12px; }
  .fl-cam__log { display: none; }
  .fl-cam__cap em { margin-left: 0; width: 100%; }
  .fl-t__timer { font-size: 13px; }
  .fl-t__num { font-size: 19px; }
  .fl-lbl { font-size: 14px; }
  .fl-hint { font-size: 15px; }
  .fl-zone-sub { font-size: 13px; }
}
@media (max-width: 640px) {
  .fl-t__num { font-size: 21px; }
  .fl-t__timer { font-size: 15px; }
  .fl-t__seat { rx: 4; }
  .fl-lbl { font-size: 14.5px; }
  .fl-hint { font-size: 17px; }
  .fl-zone-sub { font-size: 14px; }
  .fl-plan { padding: 10px 8px 14px; }
}
@media (max-width: 560px) {
  .fl-top { grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 12px 14px; }
  .fl-venue { grid-column: 1; }
  .fl-seg { justify-self: stretch; display: grid; grid-template-columns: 1fr 1fr; }
  .fl-meta { grid-column: 1; order: 0; }
  .fl-sample { font-size: 9.5px; }
  .fl-kpi { padding: 14px 14px 12px; }
  .fl-kpi b { font-size: 23px; }
  .fl-seg button { padding: 7px 10px; font-size: 10px; }
  .fl-cam__info { padding: 16px; }
  .fl-cam__facts dd { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .fl-t.is-alert .fl-t__ring, .fl-t.is-hint .fl-t__ring, .fl-t.s-reset .fl-t__shape { animation: none; }
}
