/* Servicedesk wallboard — dark forest theme
   Palette source: D-Cloud brand tokens (colors.css) */
@import url("https://fonts.googleapis.com/css2?family=Instrument+Sans:ital,wght@0,400..700;1,400..700&display=swap");

:root {
  --wb-forest: #1F362D;
  --wb-forest-900: #122019;
  --wb-cyan: #24F2E0;
  --wb-copper: #C86B45;
  --wb-amber: #E5A93C;
  --wb-indigo: #6366F1;
  --wb-sand: #E6DFD3;
  --wb-red: #E5484D;
  --wb-rose: #E8578A;
  --wb-lime: #9ED166;
  --wb-honeydew: #7AC0B4;
}

html, body {
  height: 100%;
  margin: 0;
}

body.wallboard {
  background: var(--wb-forest);
  color: var(--wb-sand);
  font-family: "Instrument Sans", system-ui, sans-serif;
  overflow: hidden;
}

#wallboard {
  height: 100vh;
  width: 100vw;
  display: flex;
  flex-direction: column;
}

.wb-num {
  font-variant-numeric: tabular-nums;
}

/* ---------- header ---------- */
.wb-header {
  flex: none;
  display: flex;
  align-items: center;
  gap: 2vh;
  padding: 2vh 3vh;
  border-bottom: 1px solid rgba(230, 223, 211, .14);
}
.wb-header .wb-logo { height: 3.4vh; }
.wb-header .wb-title {
  font-size: 2.2vh;
  font-weight: 500;
  color: rgba(230, 223, 211, .55);
  padding-left: 1.6vh;
  border-left: 1px solid rgba(230, 223, 211, .2);
}
.wb-spacer { flex: 1; }
.wb-clock {
  font-size: 5.2vh;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: #fff;
}

/* ---------- alert bar ---------- */
.wb-alert {
  flex: none;
  display: none;
  align-items: center;
  gap: 1.6vh;
  padding: 1.4vh 3vh;
  background: var(--wb-copper);
  color: #fff;
}
.wb-alert.is-visible { display: flex; }
.wb-alert .wb-tag {
  font-size: 1.4vh;
  letter-spacing: .12em;
  text-transform: uppercase;
  background: rgba(0, 0, 0, .22);
  padding: .5vh 1.2vh;
  border-radius: 999px;
  white-space: nowrap;
}
.wb-alert .wb-msg { font-size: 2.4vh; font-weight: 500; }

/* ---------- main ---------- */
.wb-main {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 2vh;
  padding: 2vh 3vh;
}

/* queue cards */
.wb-queues {
  flex: 1.55;
  min-height: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2vh;
}
.wb-queue-card {
  border: 1px solid rgba(230, 223, 211, .16);
  background: rgba(255, 255, 255, .04);
  border-radius: 1.4vh;
  padding: 2vh 2.4vh;
  display: flex;
  flex-direction: column;
  gap: 1vh;
  transition: background .3s, border-color .3s;
}
.wb-queue-card.wb-level-warn {
  border-color: var(--wb-amber);
  background: rgba(229, 169, 60, .14);
}
.wb-queue-card.wb-level-crit {
  border-color: var(--wb-copper);
  background: rgba(200, 107, 69, .18);
  animation: wb-puls 2.4s ease-out infinite;
}
.wb-queue-card .wb-qlabel {
  font-size: 2.6vh;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.wb-queue-card .wb-qbody {
  display: flex;
  align-items: baseline;
  gap: 3vh;
  flex: 1;
  min-height: 0;
}
.wb-queue-card .wb-qnum {
  font-size: 12.4vh;
  font-weight: 800;
  line-height: 1.1;
  color: #fff;
}
.wb-queue-card .wb-qfoot {
  display: flex;
  flex-wrap: wrap;
  gap: 3vh;
  font-size: 2vh;
  opacity: .85;
}
.wb-queue-card .wb-qwait-warn {
  color: var(--wb-amber);
  font-weight: 600;
  opacity: 1;
}
.wb-queue-card .wb-qwait-crit {
  color: var(--wb-copper);
  font-weight: 600;
  opacity: 1;
}

/* stat rows */
.wb-statrow {
  flex: .9;
  display: flex;
  gap: 2.4vh;
}
.wb-statgroup { display: flex; flex-direction: column; gap: .8vh; min-height: 0; }
.wb-statgroup.wb-g3 { flex: 3; }
.wb-statgroup.wb-g4 { flex: 4; }
.wb-statgroup.wb-g5 { flex: 5; }
.wb-statgroup > .wb-glabel {
  font-size: 1.7vh;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(230, 223, 211, .45);
}
.wb-tiles {
  flex: 1;
  min-height: 0;
  display: grid;
  gap: 1.4vh;
}
.wb-tiles.wb-cols-3 { grid-template-columns: repeat(3, 1fr); }
.wb-tiles.wb-cols-4 { grid-template-columns: repeat(4, 1fr); }
.wb-tiles.wb-cols-5 { grid-template-columns: repeat(5, 1fr); }
.wb-tile {
  border: 1px solid rgba(230, 223, 211, .16);
  border-radius: 1.4vh;
  padding: 1.2vh 1.6vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: .3vh;
}
.wb-tile.wb-tile-warn { border-color: var(--wb-copper); background: rgba(200, 107, 69, .12); }
.wb-tile .wb-tlabel { font-size: 1.7vh; color: rgba(230, 223, 211, .6); }
.wb-tile.wb-tile-warn .wb-tlabel { color: #f2b79c; }
.wb-tile .wb-tval { font-size: 4vh; font-weight: 800; line-height: 1.15; }
.wb-tile.wb-tile-warn .wb-tval { color: var(--wb-copper); }

/* agent panel */
.wb-agents-group {
  flex: 1.4;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: .8vh;
}
.wb-agents-group > .wb-glabel {
  font-size: 1.7vh;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(230, 223, 211, .45);
}
.wb-agents {
  flex: 1;
  min-height: 0;
  border: 1px solid rgba(230, 223, 211, .16);
  border-radius: 1.4vh;
  padding: 1.6vh 2vh;
  display: flex;
  flex-direction: column;
}
.wb-agents-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: .5vh;
  padding-top: .8vh;
}
.wb-agent-row {
  display: flex;
  align-items: center;
  gap: 1.4vh;
  flex: none;
}
.wb-agent-row .wb-dot {
  width: 1.2vh;
  height: 1.2vh;
  border-radius: 999px;
  flex: none;
  background: rgba(230, 223, 211, .4);
}
.wb-agent-row .wb-name {
  font-size: 2.1vh;
  font-weight: 500;
  color: #fff;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.wb-agent-row .wb-schedule {
  font-size: 1.8vh;
  color: #fff;
  width: 16vh;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.wb-agent-row .wb-schedule.wb-schedule-none {
  font-style: italic;
  color: rgba(230, 223, 211, .35);
}
.wb-agent-row .wb-logintime {
  font-size: 1.8vh;
  color: #fff;
  width: 10vh;
  flex: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-variant-numeric: tabular-nums;
}
.wb-agent-row .wb-channel {
  width: 7vh;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.wb-agent-row .wb-channel-dot {
  width: 1.2vh;
  height: 1.2vh;
  border-radius: 999px;
  background: rgba(230, 223, 211, .25);
}
.wb-agent-row .wb-status {
  font-size: 1.8vh;
  color: #fff;
  width: 16vh;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.wb-agent-row .wb-calls {
  font-size: 2vh;
  text-align: right;
  width: 14vh;
  flex: none;
  white-space: nowrap;
  color: #fff;
}
.wb-agent-header {
  flex: none;
  padding-left: 2.6vh;
  padding-bottom: .8vh;
  margin-bottom: .4vh;
  border-bottom: 1px solid rgba(230, 223, 211, .14);
}
.wb-agent-header .wb-name,
.wb-agent-header .wb-schedule,
.wb-agent-header .wb-logintime,
.wb-agent-header .wb-channel,
.wb-agent-header .wb-status,
.wb-agent-header .wb-calls {
  font-size: 1.5vh;
  font-weight: 500;
  font-style: normal;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(230, 223, 211, .45);
  overflow: hidden;
  text-overflow: ellipsis;
}
.wb-empty {
  font-size: 2vh;
  color: rgba(230, 223, 211, .5);
  padding: 1vh 0;
}

@keyframes wb-puls {
  0%, 100% { box-shadow: 0 0 0 0 rgba(200, 107, 69, .55); }
  50% { box-shadow: 0 0 0 1.6vh rgba(200, 107, 69, 0); }
}
