:root {
  --teal: #00bec2;
  --teal-dark: #008b92;
  --orange: #ee9106;
  --ink: #10292d;
  --muted: #6f7e80;
  --room-bg: #eee4da;
  --room-ink: #38221d;
  --room-muted: #82736c;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { color: var(--ink); background: #081315; font-family: Inter, "Segoe UI", Arial, sans-serif; }
button { font: inherit; }
.demo-toolbar { position: sticky; z-index: 20; top: 0; display: grid; grid-template-columns: auto 1fr auto; gap: 24px; align-items: center; min-height: 72px; padding: 10px 22px; border-bottom: 1px solid rgba(255,255,255,.1); color: #fff; background: rgba(6,17,19,.92); backdrop-filter: blur(16px); }
.demo-brand { display: inline-flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.demo-brand img { width: 38px; height: 38px; }
.demo-brand span { display: flex; flex-direction: column; line-height: 1.15; }
.demo-brand strong { font-size: 17px; }
.demo-brand small { color: #8fa2a4; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.demo-mode { display: flex; justify-self: center; gap: 5px; padding: 5px; border: 1px solid rgba(255,255,255,.12); border-radius: 999px; background: rgba(255,255,255,.05); }
.demo-mode button, .demo-action { border: 0; border-radius: 999px; color: #bed0d2; background: transparent; font-size: 13px; font-weight: 800; cursor: pointer; }
.demo-mode button { min-height: 40px; padding: 0 16px; }
.demo-mode button.is-active { color: #fff; background: var(--teal-dark); }
.demo-actions { display: flex; align-items: center; gap: 8px; }
.lang-switcher-demo { display: flex; flex-wrap: wrap; gap: 5px; }
.lang-switcher-item { display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding: 0 5px; border: 1px solid rgba(255,255,255,.16); border-radius: 999px; color: #d8e3e4; background: rgba(255,255,255,.04); }
.lang-switcher-item span { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; color: #10292d; background: #fff; font-size: 8px; font-weight: 900; }
.lang-switcher-item b { display: none; }
.lang-switcher-item.is-active, .lang-switcher-item[aria-current="page"] { color: #fff; border-color: var(--teal); background: rgba(0,190,194,.2); }
.demo-action { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 14px; border: 1px solid rgba(255,255,255,.14); }
.demo-action:hover { color: #fff; border-color: var(--teal); }
.demo-action-call { color: #fff; border-color: transparent; background: var(--orange); }
.demo-action svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.demo-shell { display: grid; place-items: center; min-height: calc(100vh - 122px); padding: 24px; }
.demo-stage { width: min(100%, 1600px); }
.demo-stage[hidden] { display: none; }
.hall-board { position: relative; overflow: hidden; display: grid; grid-template-rows: auto repeat(4, 1fr) auto; width: 100%; aspect-ratio: 16/9; border-radius: 20px; color: #121212; background: #f2f2f2; box-shadow: 0 30px 100px rgba(0,0,0,.4); }
.hall-head, .hall-row { display: grid; grid-template-columns: 14% 37% 19% 30%; align-items: stretch; }
.hall-head { color: #fff; background: var(--teal); font-size: clamp(13px, 1.4vw, 25px); font-weight: 850; text-align: center; }
.hall-head > div { display: grid; place-items: center; padding: .55em; border-right: 1px solid rgba(255,255,255,.3); }
.hall-head > div:last-child { border-right: 0; background: #575858; }
.hall-row { min-height: 0; border-bottom: 1px solid #d6d6d6; background: #f7f7f7; }
.hall-row:nth-child(odd) { background: #eceeee; }
.hall-row > div { border-right: 1px solid #d7d7d7; }
.hall-row > div:last-child { border-right: 0; }
.hall-room { display: grid; place-items: center; color: var(--teal-dark); font-size: clamp(36px, 5vw, 82px); font-weight: 950; }
.hall-doctor { display: flex; align-items: center; gap: clamp(10px, 1.4vw, 24px); padding: clamp(8px, 1vw, 16px); }
.hall-doctor img, .hall-avatar { width: clamp(54px, 6vw, 104px); height: clamp(62px, 7vw, 118px); flex: none; border-radius: 17px; object-fit: cover; }
.hall-avatar { display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--teal), var(--teal-dark)); font-size: clamp(18px, 2vw, 34px); font-weight: 900; }
.hall-avatar-alt { background: linear-gradient(135deg, #6785a8, #2c4a70); }
.hall-doctor strong, .hall-doctor small { display: block; }
.hall-doctor strong { font-size: clamp(18px, 2.2vw, 38px); line-height: 1.05; }
.hall-doctor small { margin-top: 8px; color: #5d6667; font-size: clamp(11px, 1.15vw, 20px); }
.hall-current { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.hall-current strong { color: var(--orange); font-size: clamp(40px, 5vw, 86px); line-height: .9; }
.hall-current time, .hall-wait time { margin-top: 6px; color: #858585; font-size: clamp(10px, 1.05vw, 18px); }
.hall-wait { display: flex; align-items: center; justify-content: space-around; gap: 10px; padding: 8px; }
.hall-wait span { display: flex; flex-direction: column; align-items: center; }
.hall-wait strong { font-size: clamp(24px, 3.2vw, 56px); line-height: .9; }
.hall-footer { display: flex; align-items: center; justify-content: space-between; padding: .45em 1.1em; color: #fff; background: var(--teal); font-size: clamp(14px, 1.55vw, 28px); font-weight: 850; }
.hall-footer > span:last-child { display: flex; align-items: baseline; gap: 16px; }
.hall-footer small { opacity: .85; }
.hall-call-banner { position: absolute; z-index: 4; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #fff; background: rgba(238,145,6,.97); opacity: 0; visibility: hidden; transform: scale(.97); transition: opacity .25s ease, visibility .25s ease, transform .25s ease; }
.hall-call-banner.is-active { opacity: 1; visibility: visible; transform: scale(1); }
.hall-call-banner small { font-size: clamp(24px, 4vw, 64px); font-weight: 850; text-transform: uppercase; letter-spacing: .12em; }
.hall-call-banner strong { font-size: clamp(130px, 24vw, 380px); line-height: .86; letter-spacing: -.08em; }
.hall-call-banner span { font-size: clamp(26px, 4vw, 70px); font-weight: 850; }
.room-board { position: relative; overflow: hidden; width: 100%; aspect-ratio: 16/9; border-radius: 20px; color: var(--room-ink); background: var(--room-bg); box-shadow: 0 30px 100px rgba(0,0,0,.4); }
.room-logo { height: 15%; padding: 1.4% 3%; }
.room-logo img { width: auto; height: 100%; }
.room-main { display: grid; grid-template-columns: 32% 68%; gap: 3%; height: 65%; padding: 1% 5% 2%; align-items: center; }
.room-photo { width: 100%; height: 100%; border: 7px solid #aa9989; border-radius: 30px; object-fit: cover; }
.room-info { min-width: 0; }
.room-lastname { display: block; font-size: clamp(45px, 7vw, 116px); font-weight: 950; line-height: .9; letter-spacing: -.05em; }
.room-info > strong { display: block; margin-top: 14px; font-size: clamp(24px, 3vw, 52px); }
.room-info > small { display: block; margin: 8px 0 22px; color: var(--room-muted); font-size: clamp(16px, 1.9vw, 32px); font-weight: 750; }
.room-list { overflow: hidden; border: 2px solid rgba(56,34,29,.22); border-radius: 18px; background: rgba(255,255,255,.42); }
.room-list > div { display: grid; grid-template-columns: 1fr auto auto; gap: 20px; align-items: center; min-height: clamp(54px, 5vw, 88px); padding: 0 22px; border-bottom: 1px solid rgba(56,34,29,.18); font-size: clamp(16px, 1.7vw, 29px); font-weight: 700; }
.room-list > div:last-child { border-bottom: 0; }
.room-list strong { font-size: 1.35em; }
.room-list time { color: var(--room-muted); }
.room-list .is-current { color: var(--room-bg); background: var(--room-ink); }
.room-footer { display: flex; align-items: center; justify-content: center; gap: 4%; height: 20%; color: var(--room-bg); background: var(--room-ink); }
.room-footer span { font-size: clamp(30px, 5vw, 80px); font-weight: 850; text-transform: uppercase; letter-spacing: .12em; }
.room-footer strong { font-size: clamp(100px, 15vw, 245px); line-height: .78; }
.room-call { position: absolute; z-index: 4; inset: 15% 0 20%; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--room-ink); background: var(--room-bg); opacity: 0; visibility: hidden; transform: scale(.97); transition: opacity .25s ease, visibility .25s ease, transform .25s ease; }
.room-call.is-active { opacity: 1; visibility: visible; transform: scale(1); }
.room-call span { font-size: clamp(34px, 5vw, 86px); font-weight: 900; text-transform: uppercase; letter-spacing: .1em; }
.room-call strong { font-size: clamp(150px, 25vw, 420px); line-height: .82; letter-spacing: -.08em; }
.room-call small { color: var(--room-muted); font-size: clamp(18px, 2.4vw, 42px); font-weight: 750; }
.demo-note { padding: 14px 24px 22px; color: #829597; background: #081315; text-align: center; font-size: 12px; }
.demo-note p { margin: 0; }
.demo-note a { color: #77eeeb; font-weight: 800; }
body.is-fullscreen .demo-toolbar, body.is-fullscreen .demo-note { display: none; }
body.is-fullscreen .demo-shell { min-height: 100vh; padding: 0; }
body.is-fullscreen .demo-stage, body.is-fullscreen .hall-board, body.is-fullscreen .room-board { width: 100vw; height: 100vh; max-width: none; border-radius: 0; }
body.is-fullscreen .hall-board, body.is-fullscreen .room-board { aspect-ratio: auto; }
@media (max-width: 850px) {
  .demo-toolbar { grid-template-columns: 1fr auto; gap: 10px; }
  .demo-mode { grid-row: 2; grid-column: 1 / -1; width: 100%; }
  .demo-mode button { flex: 1; }
  .demo-actions .demo-action:not(.demo-action-call) { display: none; }
  .demo-action-call { font-size: 0; }
  .demo-action-call::after { content: attr(data-call-label); font-size: 13px; }
  .lang-switcher-demo { width: 100%; }
  .demo-shell { min-height: auto; padding: 14px; }
  .hall-row:nth-of-type(5) { display: none; }
  .hall-board { grid-template-rows: auto repeat(3, 1fr) auto; }
  .hall-wait span:nth-child(3) { display: none; }
  .room-main { grid-template-columns: 30% 70%; gap: 2%; padding-inline: 3%; }
}
@media (max-width: 520px) {
  .demo-brand small { display: none; }
  .hall-head, .hall-row { grid-template-columns: 17% 40% 20% 23%; }
  .hall-doctor img, .hall-avatar { width: 30px; height: 35px; border-radius: 6px; }
  .hall-doctor { gap: 4px; padding: 3px; }
  .hall-doctor small { display: none; }
  .hall-wait span:nth-child(n+2) { display: none; }
  .hall-footer small { display: none; }
  .room-photo { border-width: 3px; border-radius: 10px; }
  .room-info > small { margin: 2px 0 4px; }
  .room-list > div { min-height: 24px; padding: 0 6px; gap: 5px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; } }
