
.status-ribbon {
  position: fixed;
  top: 0;
  left: var(--sidebar);
  right: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 1.75rem;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  background: linear-gradient(90deg, rgba(61,186,160,0.12), rgba(16,28,34,0.92) 40%, rgba(108,180,217,0.1));
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}
.pulse {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 var(--accent-glow);
  animation: pulse 1.8s ease-out infinite;
}
@keyframes pulse {
  70% { box-shadow: 0 0 0 10px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.ribbon-sep { opacity: 0.45; }
.ribbon-ok { color: var(--accent); }
.main { padding-top: 3.1rem; }
@media (max-width: 960px) {
  .status-ribbon { left: 0; }
}

.activity-panel { margin-top: 1rem; }
.activity {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.activity-item {
  display: grid;
  grid-template-columns: 3.2rem 1fr;
  gap: 0.85rem;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.02);
  font-size: 0.9rem;
}
.activity-item time {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.activity-item.tone-ok { border-left: 3px solid var(--accent); }
.activity-item.tone-warn { border-left: 3px solid var(--warn); }
.activity-item.tone-danger { border-left: 3px solid var(--danger); }
.activity-item.tone-info { border-left: 3px solid var(--info); }

.kpi { animation: rise 520ms ease both; }
.kpi:nth-child(2) { animation-delay: 60ms; }
.kpi:nth-child(3) { animation-delay: 120ms; }
.kpi:nth-child(4) { animation-delay: 180ms; }
.bed { transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease, background 160ms ease; }
.bed[data-status="free"]::after {
  content: "";
  display: block;
  margin-top: 0.45rem;
  height: 3px;
  border-radius: 99px;
  background: var(--accent);
  opacity: 0.55;
  animation: shimmer 2.4s ease-in-out infinite;
}
@keyframes shimmer {
  0%, 100% { opacity: 0.25; transform: scaleX(0.7); }
  50% { opacity: 0.85; transform: scaleX(1); }
}
.nav-item.is-active {
  transition: box-shadow 200ms ease, background 200ms ease;
}

.bed-popover {
  position: fixed;
  z-index: 50;
  min-width: 180px;
  max-width: 240px;
  padding: 0.75rem 0.85rem;
  border-radius: 12px;
  background: #143039;
  border: 1px solid rgba(61, 186, 160, 0.35);
  box-shadow: var(--shadow);
  pointer-events: none;
  animation: rise 180ms ease both;
}
.bed-popover strong { display: block; margin-bottom: 0.2rem; }

.or-meters {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.or-meter {
  padding: 0.85rem 0.9rem;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(22, 38, 46, 0.72);
}
.or-meter-top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.55rem;
  font-size: 0.9rem;
}
@media (max-width: 900px) {
  .or-meters { grid-template-columns: 1fr 1fr; }
}

.demo-banner {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1rem;
  padding: 0.7rem 0.95rem;
  border-radius: 12px;
  border: 1px solid rgba(108, 180, 217, 0.28);
  background: linear-gradient(90deg, rgba(108,180,217,0.14), rgba(61,186,160,0.08));
  animation: rise 420ms ease both;
}
.demo-banner strong {
  color: var(--info);
  white-space: nowrap;
}
.demo-banner span { color: var(--muted); font-size: 0.9rem; }
.banner-dismiss {
  margin-left: auto;
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 1.2rem;
  cursor: pointer;
  line-height: 1;
}

body.is-compact .kpi-value { font-size: 1.45rem; }
body.is-compact .panel { padding: 0.75rem 0.85rem; }
body.is-compact .bed { padding: 0.55rem 0.5rem; }
body.is-compact .topbar h1 { font-size: 1.45rem; }
body.is-compact .activity-item,
body.is-compact .queue li { padding: 0.5rem 0.65rem; }

.shortcut-hint {
  margin: 0.55rem 0 0;
  opacity: 0.8;
  letter-spacing: 0.02em;
}

.app-footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.75rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.8rem;
  color: var(--muted);
}
.app-bg::after {
  content: "";
  position: absolute;
  inset: auto -10% -20% 40%;
  height: 55%;
  background: radial-gradient(closest-side, rgba(61,186,160,0.08), transparent 70%);
  pointer-events: none;
  animation: drift 14s ease-in-out infinite alternate;
}
@keyframes drift {
  from { transform: translate3d(0,0,0); }
  to { transform: translate3d(-4%, -3%, 0); }
}
