/* Telecast brand settings. Change these colors to match your logo. */
:root {
  --dusk: #10263b;        /* page background */
  --dusk-raised: #1a3650; /* tile background */
  --steel: #a9bac5;       /* secondary text */
  --steel-dark: #47627a;  /* outlines */
  --paper: #eef3f5;       /* main text and buttons */
  --beacon: #ef3e36;      /* live light and selected camera */
  --gutter: clamp(16px, 4vw, 48px);
  color-scheme: dark;
}

@font-face { font-family: "Barlow Condensed"; src: url("fonts/barlow-condensed-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("fonts/barlow-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("fonts/barlow-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--dusk); color: var(--paper); font: 400 1.0625rem/1.5 "Barlow", system-ui, sans-serif; }
[hidden] { display: none !important; }
a { color: inherit; }
h1, h2, p { margin: 0; }
:focus-visible { outline: 3px solid var(--paper); outline-offset: 3px; }

.masthead { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px var(--gutter); }
.brand { display: flex; align-items: center; min-height: 44px; text-decoration: none; }
.brand-logo { display: block; height: 44px; width: auto; max-width: 56vw; }
.brand-text { display: none; font: 600 1.5rem/1.1 "Barlow Condensed", sans-serif; }
.brand.no-logo .brand-logo { display: none; }
.brand.no-logo .brand-text { display: block; }
.masthead-links { display: flex; align-items: center; gap: 20px; font-weight: 600; white-space: nowrap; }
.masthead-links a:not(.button) { text-underline-offset: 3px; }

.button { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border: 2px solid var(--paper); border-radius: 3px; background: var(--paper); color: var(--dusk); font: 600 1rem/1 "Barlow", sans-serif; text-decoration: none; cursor: pointer; }
.button-quiet { background: transparent; color: var(--paper); }
.button-quiet[aria-pressed="true"] { background: var(--paper); color: var(--dusk); }

main { padding: 0 var(--gutter); max-width: 1500px; margin: 0 auto; }
.intro { padding: clamp(20px, 4vw, 44px) 0 clamp(18px, 3vw, 30px); }
h1 { font: 600 clamp(3rem, 7vw, 6rem)/0.92 "Barlow Condensed", sans-serif; letter-spacing: -0.005em; }
#page-tagline { margin-top: 14px; color: var(--steel); max-width: 62ch; font-size: 1.125rem; }

.screen { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--dusk-raised); }
.screen video, .screen .still { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.screen:fullscreen { aspect-ratio: auto; width: 100vw; height: 100vh; background: #000; }
.screen:fullscreen video { object-fit: contain; }
.mark { position: absolute; right: 2.5%; bottom: 4%; width: clamp(64px, 16%, 200px); height: auto; opacity: .88; pointer-events: none; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .75)); }
.mark-text { width: auto; font: 600 clamp(.85rem, 1.7vw, 1.4rem)/1 "Barlow Condensed", sans-serif; text-shadow: 0 1px 4px #000; }

.live-tag { position: absolute; left: 2.5%; bottom: 4%; display: flex; align-items: center; gap: 7px; padding: 4px 9px 4px 7px; border-radius: 2px; background: rgba(16, 38, 59, .78); font-size: .875rem; font-weight: 600; line-height: 1.3; }
.beacon { width: 11px; height: 11px; border-radius: 50%; background: var(--beacon); box-shadow: 0 0 9px 2px var(--beacon); animation: beacon 2s steps(1) infinite; }
/* The same slow on-and-off rhythm as a tower's obstruction light. */
@keyframes beacon { 0%, 55% { opacity: 1; } 56%, 100% { opacity: .18; } }

.notice { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 16px; background: rgba(16, 38, 59, .82); text-align: center; }
.fullscreen { position: absolute; right: 2%; top: 3.5%; min-width: 44px; min-height: 44px; padding: 0 12px; border: 0; border-radius: 2px; background: rgba(16, 38, 59, .78); color: var(--paper); font: 600 .875rem/1 "Barlow", sans-serif; cursor: pointer; }

.feature-caption { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 16px; padding: 14px 0 0; }
.feature-caption h2 { font: 600 clamp(2rem, 4.5vw, 3.5rem)/1 "Barlow Condensed", sans-serif; }
.feature-caption p { color: var(--steel); font-size: 1.125rem; }

.wall-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: clamp(32px, 5vw, 60px) 0 16px; }
.wall-heading h2 { font: 600 2rem/1 "Barlow Condensed", sans-serif; }
.wall { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 22px 16px; }
.wall.is-live { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }

.tile { display: block; width: 100%; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.tile .screen { outline: 3px solid transparent; outline-offset: 2px; }
.tile:hover .screen { outline-color: var(--steel-dark); }
.wall:not(.is-live) .tile[aria-current="true"] .screen { outline-color: var(--beacon); }
.tile-name { display: block; margin-top: 9px; font: 600 1.45rem/1.1 "Barlow Condensed", sans-serif; }
.tile-area { display: block; color: var(--steel); font-size: .9375rem; }
.tile-state { position: absolute; left: 0; right: 0; top: 0; padding: 7px 10px; background: rgba(16, 38, 59, .88); font-size: .875rem; }
.tile-empty { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 12px; color: var(--steel); text-align: center; font-size: .9375rem; }

.load-error { padding: 20px 0; }
.footer { display: flex; flex-wrap: wrap; gap: 4px 28px; margin-top: 64px; padding: 24px var(--gutter) 36px; border-top: 1px solid var(--steel-dark); color: var(--steel); font-size: .9375rem; }

@media (max-width: 560px) {
  .masthead-links a:not(.button) { display: none; }
  .brand-logo { height: 36px; }
  .button { padding: 0 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .beacon { animation: none; }
}
