/* Bold squared clock type, served locally with its SIL Open Font License. */
@font-face {
  font-family: "BB Clock";
  src: url("../fonts/orbitron-clock-context-800.ttf") format("truetype");
  font-style: normal;
  font-weight: 800;
  font-display: swap;
}
.bb-top-header.bb-clock-host { grid-template-columns: auto minmax(0, 1fr) auto; }
#bb-site-clock {
  display: inline-flex !important;
  align-items: center;
  justify-self: end;
  gap: 5px;
  min-width: 0;
  color: #fff;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  line-height: 1;
  letter-spacing: 0;
  white-space: nowrap;
  -webkit-font-smoothing: antialiased;
}
#bb-site-clock .bb-clock-face { all: unset; display: flex; align-items: center; gap: 10px; cursor: pointer; border-radius: 3px; }
#bb-site-clock .bb-clock-time { display: inline-flex; align-items: center; gap: 7px; }
#bb-site-clock [hidden] { display: none !important; }
#bb-site-clock .bb-clock-face:focus-visible { outline: 1px solid #e5e5e5; outline-offset: 4px; }
#bb-site-clock[data-mode="game"] .bb-clock-date::after { content: "·"; margin-left: 10px; color: #777; }
#bb-site-clock time,
#bb-site-clock .bb-clock-date,
#bb-site-clock [data-period] {
  color: inherit;
  font-family: "BB Clock", "Arial Black", ui-monospace, monospace;
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: .015em;
  text-shadow: 0 0 9px rgba(255,255,255,.20);
}
#bb-site-clock [data-period] { flex-shrink: 0; }
#bb-site-clock .bb-clock-digit { display: inline-block; width: .834em; text-align: center; }
#bb-site-clock .bb-clock-colon { display: inline-block; width: .26em; text-align: center; }
#bb-site-clock .bb-clock-zone {
  display: grid;
  gap: 3px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .08em;
  color: #b8b8b8;
  min-width: 3ch;
}
#bb-site-clock[data-sync="device"] .bb-clock-zone,
#bb-site-clock[data-sync="holdover"] .bb-clock-zone { color: #949494; }
#bb-site-clock .bb-clock-toggle {
  all: unset;
  box-sizing: border-box;
  display: grid;
  place-items: center;
  width: 28px;
  height: 32px;
  flex: 0 0 28px;
  border-radius: 5px;
  color: #949494;
  cursor: pointer;
  touch-action: manipulation;
}
#bb-site-clock .bb-clock-toggle svg { width: 12px; height: 12px; pointer-events: none; }
#bb-site-clock .bb-clock-toggle:hover { color: #fff; background: rgba(255,255,255,.04); }
#bb-site-clock .bb-clock-toggle:focus-visible { outline: 1px solid #e5e5e5; outline-offset: 1px; }
#bb-site-clock[data-collapsed="true"] .bb-clock-toggle svg { transform: rotate(180deg); }
.topbar.bb-clock-admin {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 8px 16px;
}
.topbar.bb-clock-admin > #bb-site-clock { grid-column: 2; grid-row: 1; }
.topbar.bb-clock-admin > div:first-child { min-width: 0; overflow-wrap: anywhere; }
.topbar.bb-clock-admin > .topbar-actions { grid-column: 1 / -1; grid-row: 2; }
@media (max-width: 1100px) {
  #bb-site-clock[data-mode="game"] .bb-clock-face { display: grid; justify-items: end; gap: 4px; }
  #bb-site-clock[data-mode="game"] .bb-clock-date::after { content: none; }
}
@media (max-width: 760px) {
  .bb-top-header.bb-clock-host {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: 32px 32px;
    gap: 2px 8px;
    height: auto !important;
    min-height: 74px !important;
    padding-top: 4px !important;
    padding-bottom: 4px !important;
  }
  .bb-top-header.bb-clock-host > .bb-top-brand { grid-row: 1; grid-column: 1; justify-self: start; }
  .bb-top-header.bb-clock-host > #bb-site-clock { grid-row: 1; grid-column: 2; }
  .bb-top-header.bb-clock-host > .bb-top-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-self: center;
    max-width: 100%;
  }
  .bb-top-header.bb-clock-host.bb-clock-collapsed {
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-rows: 1fr;
    min-height: 54px !important;
  }
  .bb-top-header.bb-clock-collapsed > .bb-top-nav { grid-column: 2; grid-row: 1; }
  .bb-top-header.bb-clock-collapsed > #bb-site-clock { grid-column: 3; }
  .bb-top-header.bb-clock-game-mode { grid-template-rows: 54px 32px; min-height: 96px !important; }
  .topbar.bb-clock-admin { gap: 8px; }
}
