/* Bureau shell ---------------------------------------------------------------
   Shared Campaign Archive framing for player-facing setup and utility rooms. */

.bureau-shell-screen {
  --bureau-shell-bg: #000;
  --bureau-shell-panel: #020606;
  --bureau-shell-cream: #e0d19c;
  --bureau-shell-muted: #8a8566;
  --bureau-shell-gold: #a37314;
  --bureau-shell-signal: #00dbc9;
  background-color: var(--bureau-shell-bg) !important;
}

.bureau-shell-brand,
.bureau-shell-title p {
  display: none;
}

@media (min-width: 901px) and (min-height: 621px) {
  .bureau-shell-screen {
    background:
      radial-gradient(circle at 50% 46%, rgba(0, 219, 201, 0.025), transparent 46%),
      linear-gradient(180deg, #030707, #020505) !important;
    background-color: #000 !important;
  }

  .bureau-shell-screen::before {
    background: none !important;
  }

  .bureau-shell-header {
    position: relative;
    z-index: 8;
    display: grid;
    grid-template-columns: 165px minmax(0, 1fr) 165px;
    align-items: stretch;
    min-height: 99px;
    margin: 0;
    padding: 0 16.5px;
    border: 0 !important;
    background: var(--bureau-shell-bg);
    box-shadow: none;
  }

  .bureau-shell-header::before {
    content: none !important;
  }

  .bureau-shell-header::after {
    content: "" !important;
    position: absolute;
    top: auto !important;
    right: 0 !important;
    bottom: 4px !important;
    left: 0 !important;
    display: block;
    width: auto;
    height: 1px;
    background: var(--bureau-shell-gold);
    pointer-events: none;
  }

  .bureau-shell-brand {
    position: absolute;
    top: 36.75px;
    left: 142.5px;
    display: grid;
    grid-template-columns: 25.5px auto;
    align-items: center;
    gap: 6.75px;
    color: var(--bureau-shell-signal);
    font: 700 7.5px/1.1 var(--font-ui);
    letter-spacing: 0.05em;
    pointer-events: none;
  }

  .bureau-shell-brand img {
    display: block;
    width: 25.5px;
    height: 25.5px;
    object-fit: contain;
    filter: saturate(0.78) brightness(0.94);
  }

  .bureau-shell-header .bureau-shell-back {
    position: absolute;
    top: 34.5px;
    bottom: auto;
    left: 16.5px;
    display: grid;
    grid-template-columns: 1fr;
    place-items: center;
    gap: 0;
    width: 112.5px;
    min-width: 112.5px;
    height: 30px;
    min-height: 30px;
    margin: 0;
    padding: 0;
    border: 1px solid #334740;
    border-radius: 0;
    color: #d6c999;
    background: var(--bureau-shell-panel);
    box-shadow: none;
    font: 400 9.75px/1 var(--font-menu);
    letter-spacing: 0.04em;
    text-align: center;
    cursor: pointer;
  }

  .bureau-shell-header .bureau-shell-back::before,
  .bureau-shell-header .bureau-shell-back > span[aria-hidden="true"] {
    content: "";
    position: absolute;
    top: 6px;
    bottom: 6px;
    left: 9px;
    display: block;
    width: 1.5px;
    height: auto;
    min-height: 0;
    border: 0;
    border-radius: 0;
    background: #d1bf85;
    box-shadow: none;
  }

  .bureau-shell-header .bureau-shell-back strong {
    color: inherit;
    font: inherit;
    letter-spacing: inherit;
  }

  .bureau-shell-header .bureau-shell-back:hover,
  .bureau-shell-header .bureau-shell-back:focus-visible {
    border-color: var(--bureau-shell-signal);
    color: #f1e3b3;
    background: rgba(0, 219, 201, 0.045);
    box-shadow: 0 0 0 1px rgba(0, 219, 201, 0.12);
    outline: 2px solid rgba(0, 219, 201, 0.32);
    outline-offset: 2px;
  }

  .bureau-shell-header .bureau-shell-back:hover::before,
  .bureau-shell-header .bureau-shell-back:focus-visible::before,
  .bureau-shell-header .bureau-shell-back:hover > span[aria-hidden="true"],
  .bureau-shell-header .bureau-shell-back:focus-visible > span[aria-hidden="true"] {
    background: var(--bureau-shell-signal);
  }

  .bureau-shell-header .bureau-shell-title {
    display: grid;
    grid-column: 2;
    place-content: center;
    justify-items: center;
    gap: 0;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
    text-align: center;
  }

  .bureau-shell-header .bureau-shell-title > span {
    display: none;
  }

  .bureau-shell-header .bureau-shell-title h1 {
    margin: 0;
    color: var(--bureau-shell-cream);
    font: 400 31.5px/1.16 var(--font-menu) !important;
    letter-spacing: 0.025em !important;
    text-align: center;
    text-shadow: none;
    -webkit-text-stroke: 0;
  }

  .bureau-shell-header .bureau-shell-title p {
    display: none;
  }

  .bureau-shell-header .bureau-shell-status {
    position: static;
    display: grid;
    grid-column: 3;
    align-self: center;
    justify-self: end;
    gap: 5.25px;
    width: auto;
    min-width: 0;
    min-height: 0;
    margin: 0 4.5px 0 0;
    padding: 0;
    border: 0;
    color: var(--bureau-shell-signal);
    background: transparent;
    box-shadow: none;
    font: 500 11.25px/1 var(--font-ui) !important;
    letter-spacing: 0 !important;
    text-align: right;
  }

  .bureau-shell-header .bureau-shell-status::before {
    content: attr(data-bureau-status-label);
    color: #00675f;
    font: 700 8.25px/1 var(--font-ui) !important;
    white-space: nowrap;
  }

  .bureau-shell-footer {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 18px !important;
    min-height: 36px !important;
    height: 36px !important;
    margin: 0 !important;
    padding: 0 37.5px !important;
    border: 0 !important;
    border-top: 1px solid #594a14 !important;
    color: #b4933d !important;
    background: #020505 !important;
    font: 700 7.5px/1 var(--font-ui) !important;
    letter-spacing: 0 !important;
  }

  .bureau-shell-footer > :last-child {
    color: #00a394;
    text-align: right;
  }

  #new-basecamp-screen.bureau-shell-screen {
    grid-template-rows: 99px minmax(0, 1fr) 36px !important;
  }

  #new-basecamp-screen.bureau-shell-screen .new-basecamp-header {
    grid-template-columns: 165px minmax(0, 1fr) 165px !important;
    width: 100%;
    min-height: 99px !important;
    padding: 0 16.5px !important;
  }

  #new-basecamp-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-back {
    display: grid;
    grid-template-columns: 1fr;
    place-items: center;
    gap: 0;
    width: 112.5px;
    min-width: 112.5px;
    height: 30px;
    min-height: 30px;
    padding: 0;
  }

  #new-basecamp-screen.bureau-shell-screen .new-basecamp-header__status {
    display: grid !important;
  }

  #new-basecamp-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-title h1 {
    font: 400 31.5px/1.16 var(--font-menu) !important;
    letter-spacing: 0.025em !important;
  }

  #new-basecamp-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-status {
    align-self: center;
    margin: 0 4.5px 0 0;
    font: 500 11.25px/1 var(--font-ui) !important;
    letter-spacing: 0 !important;
  }

  #new-basecamp-screen.bureau-shell-screen .new-basecamp-workspace {
    width: calc(100% - 48px) !important;
    height: 100% !important;
    margin: 0 24px !important;
  }

  #new-basecamp-screen.bureau-shell-screen .new-basecamp-wire {
    grid-row: 3;
  }

  .settings-screen.bureau-shell-screen {
    padding-bottom: 36px;
  }

  .settings-screen.bureau-shell-screen > .bureau-shell-header {
    position: absolute;
    width: 100%;
    height: 99px;
    min-height: 99px;
    padding: 0 16.5px;
  }

  .settings-screen.bureau-shell-screen .settings-workspace {
    top: 116px;
  }

  .settings-screen .settings-wire {
    position: absolute;
    z-index: 8;
    right: 0;
    bottom: 0;
    left: 0;
  }

  .statistics-screen.bureau-shell-screen > .bureau-shell-header {
    width: calc(100% / 0.75);
    height: 132px;
    min-height: 132px;
    padding: 0 22px;
    transform: scale(0.75);
    transform-origin: top left;
  }

  .statistics-screen.bureau-shell-screen .bureau-shell-brand {
    top: 49px;
    left: 190px;
    grid-template-columns: 34px auto;
    gap: 9px;
    font-size: 10px;
  }

  .statistics-screen.bureau-shell-screen .bureau-shell-brand img {
    width: 34px;
    height: 34px;
  }

  .statistics-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-back {
    top: 46px;
    bottom: auto;
    left: 22px;
    width: 150px;
    min-width: 150px;
    height: 40px;
    min-height: 40px;
    font-size: 13px;
  }

  .statistics-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-title {
    place-content: center;
    padding-top: 0;
  }

  .statistics-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-title h1 {
    font-size: 42px !important;
  }

  .statistics-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-status {
    align-self: center;
    gap: 7px;
    margin: 0 6px 0 0;
    font-size: 15px !important;
  }

  .statistics-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-status::before {
    font-size: 11px !important;
  }

  .statistics-screen.bureau-shell-screen .statistics-workspace {
    top: 99px;
    padding-top: 46px;
  }

  .statistics-screen.bureau-shell-screen .callsign-wire {
    position: absolute;
    z-index: 8;
    right: 0;
    bottom: 0;
    left: 0;
  }

  .relaxation-screen.bureau-shell-screen::before {
    background: none !important;
  }

  .relaxation-screen.bureau-shell-screen .relaxation-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 1600px;
    height: 132px;
    min-height: 132px;
    padding: 0 22px;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-brand {
    top: 49px;
    left: 190px;
    grid-template-columns: 34px auto;
    gap: 9px;
    font-size: 10px;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-brand img {
    width: 34px;
    height: 34px;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-back {
    position: absolute;
    top: 46px;
    bottom: auto;
    left: 0;
    width: 150px;
    min-width: 150px;
    height: 40px;
    min-height: 40px;
    margin: 0;
    padding: 0;
    font-size: 13px;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-title {
    width: auto;
    place-content: center;
    padding-top: 0;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-title h1 {
    font-size: 42px !important;
    line-height: 1.16;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-status {
    align-self: center;
    gap: 7px;
    width: auto;
    margin: 0 6px 0 0;
    color: var(--bureau-shell-signal);
    font-size: 15px !important;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-header .bureau-shell-status::before {
    font-size: 11px !important;
  }

  .relaxation-screen.bureau-shell-screen .relaxation-header::after {
    content: "" !important;
    top: auto;
    right: 0;
    bottom: 4px;
    left: 0;
  }

  .relaxation-screen.bureau-shell-screen .relaxation-program-tabs {
    top: 158px;
  }

  .relaxation-screen.bureau-shell-screen .relaxation-workspace {
    top: 158px;
  }

  .relaxation-screen.bureau-shell-screen .bureau-shell-footer {
    gap: 24px !important;
    min-height: 48px !important;
    height: 48px !important;
    padding: 0 50px !important;
    font-size: 10px !important;
  }

  .custom-game-screen.bureau-shell-screen {
    grid-template-columns: 350px minmax(0, 1fr);
    grid-template-rows: calc(99px * var(--game-scale)) minmax(0, 1fr) calc(36px * var(--game-scale));
  }

  .custom-game-screen.bureau-shell-screen .custom-game-backdrop {
    background: var(--bureau-shell-bg);
  }

  .custom-game-screen.bureau-shell-screen .custom-game-shell-header {
    grid-column: 1 / -1;
    grid-row: 1;
    width: var(--game-width);
    height: 99px;
    min-height: 99px;
    transform: scale(var(--game-scale));
    transform-origin: top left;
  }

  .custom-game-screen.bureau-shell-screen .custom-game-rail {
    grid-column: 1;
    grid-row: 2;
    padding-top: 24px;
    background: #020606;
  }

  .custom-game-screen.bureau-shell-screen .custom-game-rail__logo,
  .custom-game-screen.bureau-shell-screen .custom-game-rail__heading {
    display: none;
  }

  .custom-game-screen.bureau-shell-screen .custom-game-main {
    grid-column: 2;
    grid-row: 2;
    padding-top: 22px;
  }

  .custom-game-screen.bureau-shell-screen .custom-game-heading > div:first-child {
    display: none;
  }

  .custom-game-screen.bureau-shell-screen .custom-game-heading {
    justify-content: flex-end;
  }

  .custom-game-screen.bureau-shell-screen .custom-game-footer {
    grid-column: 1 / -1;
    grid-row: 3;
    width: var(--game-width);
    transform: scale(var(--game-scale));
    transform-origin: top left;
  }

  .multiplayer-screen.bureau-shell-screen {
    grid-template-rows: 99px minmax(0, 1fr) 36px;
  }

  .multiplayer-screen.bureau-shell-screen .multiplayer-command-header {
    padding: 0 16.5px;
  }

  .multiplayer-screen.bureau-shell-screen .multiplayer-stage {
    padding-top: 28px;
  }
}
