* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: #000;
  color: #f2f2f2;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.35;
}

body:not(.page-output) {
  min-height: 100vh;
  min-height: 100dvh;
  background:
    radial-gradient(900px 420px at 0% -8%, rgba(255, 255, 255, 0.09), transparent 55%),
    radial-gradient(720px 380px at 100% 0%, rgba(255, 255, 255, 0.05), transparent 48%),
    linear-gradient(180deg, #2c2c2c 0%, #171717 46%, #0c0c0c 100%);
}

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }

[hidden] { display: none !important; }

:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025));
}

.brand, .label-input {
  margin: 0;
  background: transparent;
  border: 1px solid transparent;
  color: #fff;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.label-input { width: min(280px, 46vw); padding: 8px; }
.label-input:focus { border-color: #fff; outline: none; }

.top-actions, .row-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.btn, .mini {
  background: linear-gradient(180deg, #3a3a3a, #242424);
  color: #f4f4f4;
  border: 1px solid rgba(255, 255, 255, 0.55);
  text-decoration: none;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 12px 14px;
  font-size: 13px;
  line-height: 1;
}

.mini { padding: 7px 8px; font-size: 11px; letter-spacing: 0.08em; }
.btn:hover, .btn:focus-visible, .mini:hover, .mini:focus-visible { background: #f3f3f3; color: #141414; }
.mini.is-on { background: #f3f3f3; color: #141414; }
.btn:disabled, .mini:disabled { opacity: 0.4; cursor: default; }
.btn:disabled:hover, .mini:disabled:hover { background: linear-gradient(180deg, #3a3a3a, #242424); color: #f4f4f4; }

.linktext {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border: 1px solid #fff;
  padding: 6px 8px;
}

.onair {
  border: 1px solid #fff;
  padding: 8px 12px;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  max-width: min(520px, 48vw);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.onair.is-live { background: #fff; color: #000; }

.home {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 880px;
  margin: 0 auto;
  padding: 48px 20px 64px;
}

.home h1 {
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.22em;
}

.lede, .hint, .hosts, .field span, .msg {
  color: #cfcfcf;
}

.lede { max-width: 38em; margin: 14px 0 0; }
.kicker {
  margin: 32px 0 8px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #cfcfcf;
}

.spots, .stack { display: grid; gap: 8px; }
.spots { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.stack { grid-template-columns: 1fr 1fr; margin-top: 8px; }

.spots a, .stack a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 92px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025));
  text-decoration: none;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  padding: 12px;
}

.spots a b, .stack a b { font-size: 28px; font-weight: 500; letter-spacing: 0; }
.stack a b { font-size: 18px; letter-spacing: 0.12em; }
.spots a:hover, .stack a:hover, .spots a:focus-visible, .stack a:focus-visible { background: #f3f3f3; color: #141414; }
.spots a small, .stack a small { color: #bdbdbd; letter-spacing: 0.08em; font-size: 11px; }
.spots a:hover small, .stack a:hover small, .spots a:focus-visible small, .stack a:focus-visible small { color: inherit; }
.spot-red { box-shadow: inset 0 3px 0 #ff5d5d; }
.spot-blue { box-shadow: inset 0 3px 0 #6aa4ff; }
.spot-gold { box-shadow: inset 0 3px 0 #e2c16a; }
.spot-silver { box-shadow: inset 0 3px 0 #d5d8de; }
.spot-green { box-shadow: inset 0 3px 0 #5dce86; }
.spot-red b, .col.spot-red .col-head, body[data-spotter="red"] .label-input { color: #ff5d5d; }
.spot-blue b, .col.spot-blue .col-head, body[data-spotter="blue"] .label-input { color: #6aa4ff; }
.spot-gold b, .col.spot-gold .col-head, body[data-spotter="gold"] .label-input { color: #e2c16a; }
.spot-silver b, .col.spot-silver .col-head, body[data-spotter="silver"] .label-input { color: #d5d8de; }
.spot-green b, .col.spot-green .col-head, body[data-spotter="green"] .label-input { color: #5dce86; }
.spots a:hover b, .spots a:focus-visible b { color: #141414; }
body[data-spotter="red"] { box-shadow: inset 0 3px 0 #ff5d5d; }
body[data-spotter="blue"] { box-shadow: inset 0 3px 0 #6aa4ff; }
body[data-spotter="gold"] { box-shadow: inset 0 3px 0 #e2c16a; }
body[data-spotter="silver"] { box-shadow: inset 0 3px 0 #d5d8de; }
body[data-spotter="green"] { box-shadow: inset 0 3px 0 #5dce86; }
.wide { grid-column: 1 / -1; }
.hosts { margin-top: 28px; font-size: 14px; }

.spotter {
  max-width: 860px;
  margin: 0 auto;
  padding: 28px 20px 48px;
}

.field { display: block; }
.field span, .lineup-head h2, .col-head .sub {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

input[type="search"] {
  -webkit-appearance: none;
  appearance: none;
}

input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-results-button,
input[type="search"]::-webkit-search-cancel-button {
  -webkit-appearance: none;
  appearance: none;
  display: none;
}

input, textarea, select {
  width: 100%;
  background: rgba(0, 0, 0, 0.35);
  color: #f4f4f4;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 0;
  padding: 14px 16px;
  font-size: 16px;
}

textarea { resize: vertical; min-height: 76px; }
input::placeholder, textarea::placeholder { color: #8a8a8a; }

.spotter-search { font-size: 28px; padding: 16px 18px; }

.search-wrap { position: relative; }

.results {
  position: absolute;
  z-index: 20;
  left: 0;
  right: 0;
  top: 100%;
  background: linear-gradient(180deg, #2a2a2a, #161616);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-top: 0;
  max-height: 380px;
  overflow: auto;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.45);
}

.result, .person, .pick {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  color: #f4f4f4;
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px 14px;
}

.result:hover, .person:hover, .pick:hover { background: rgba(255, 255, 255, 0.06); }

.result.is-active, .person.is-selected {
  background: #f4f4f4;
  color: #141414;
}

.result .who, .person .who, .pick .who, .row .who {
  display: block;
  font-weight: 700;
}

.result .meta, .person .meta, .pick .meta, .row .meta {
  display: block;
  margin-top: 3px;
  color: #bdbdbd;
  font-size: 13px;
}

.result.is-active .meta, .person.is-selected .meta { color: #333; }

.result { display: grid; grid-template-columns: 1fr auto; column-gap: 12px; }
.result .who { grid-column: 1; }
.result .tag { grid-column: 2; grid-row: 1; align-self: start; }
.result .meta { grid-column: 1 / -1; }
.pick { display: grid; grid-template-columns: 1fr auto; column-gap: 12px; }
.pick .num { grid-column: 2; grid-row: 1; }
.pick .who { grid-column: 1; grid-row: 1; }
.pick .meta, .pick .ctx { grid-column: 1 / -1; }
.result .tag, .pick .num {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9a9a9a;
}

.result.is-active .tag { color: #444; }
.airbug, .pick.is-live .num {
  display: inline-block;
  width: fit-content;
  background: #fff;
  color: #111;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1;
  padding: 4px 6px;
}
.airbug { margin-bottom: 6px; }

.lineup { margin-top: 36px; }
.lineup-head, .form-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.lineup-head h2, .form-head h2 { margin: 0 0 8px; font-size: 12px; font-weight: 500; }

.rows { list-style: none; margin: 8px 0 0; padding: 0; }
.row {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.row .num { font-size: 13px; letter-spacing: 0.08em; color: #9a9a9a; }
.row.flash { outline: 1px solid #fff; outline-offset: -1px; }
.row.is-offer, .pick.is-offer { box-shadow: inset 3px 0 0 #fff; }
.row.is-offer .num, .pick.is-offer:not(.is-live) .num { color: #fff; text-transform: uppercase; letter-spacing: 0.12em; }
.empty { color: #bdbdbd; margin: 16px 0; }

.control {
  height: 100vh;
  display: grid;
  grid-template-rows: auto auto auto auto auto minmax(0, 1fr);
}

.preview-wrap { padding: 10px 12px 0; }
.preview-wrap .l3 {
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.4);
  min-height: 128px;
}
.preview-label {
  margin: 0 0 6px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #cfcfcf;
}

.l3 {
  background: #000;
  color: #fff;
  border-top: 4px solid #fff;
  text-align: left;
}

.l3-copy { min-width: 0; }
.l3:has(.l3-face) {
  display: flex;
  align-items: center;
  gap: 18px;
}
.l3-face, .face {
  object-fit: cover;
  object-position: center 15%;
  background: #111;
  flex: none;
}
.l3-face { width: 84px; height: 84px; }
.page-output .l3-face { width: min(168px, 22vh); height: min(168px, 22vh); }
.face { width: 44px; height: 44px; display: block; }

.result:has(.face), .pick:has(.face), .person:has(.face) {
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
}
.result:has(.face) .face, .pick:has(.face) .face, .person:has(.face) .face {
  grid-column: 1;
  grid-row: 1 / span 3;
}
.result:has(.face) .who, .pick:has(.face) .who, .person:has(.face) .who { grid-column: 2; }
.result:has(.face) .tag, .pick:has(.face) .num { grid-column: 3; grid-row: 1; }
.result:has(.face) .meta, .pick:has(.face) .meta, .pick:has(.face) .ctx, .person:has(.face) .meta { grid-column: 2 / span 2; }
.row:has(.face) { grid-template-columns: 28px 44px minmax(0, 1fr) auto; }
.l3-name {
  font-weight: 700;
  letter-spacing: 0.045em;
  text-transform: uppercase;
  line-height: 1.05;
}
.l3-title { font-weight: 500; line-height: 1.2; }
.l3-context { font-weight: 400; line-height: 1.35; }

.page-output { overflow: hidden; }
.page-output .l3 {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  min-height: 26vh;
  padding: 28px 96px 56px;
  transform: translate3d(0, 110%, 0);
  transition: transform 150ms cubic-bezier(0.4, 0, 1, 1);
}
.page-output .l3.is-on {
  transform: translate3d(0, 0, 0);
  transition-duration: 180ms;
  transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
}
@media (prefers-reduced-motion: reduce) {
  .page-output .l3 { transition: none; }
}
.page-output .l3-name { font-size: clamp(36px, 4.2vw, 68px); }
.page-output .l3-title { margin-top: 10px; font-size: clamp(20px, 2.2vw, 34px); }
.page-output .l3-context { margin-top: 12px; max-width: 46em; font-size: clamp(18px, 1.7vw, 28px); }

.l3.compact { border-top-width: 3px; padding: 14px 18px 16px; }
.l3.compact .l3-name { font-size: 28px; }
.l3.compact .l3-title { margin-top: 4px; font-size: 16px; }
.l3.compact .l3-context { margin-top: 4px; font-size: 14px; max-width: none; }

.desk-switch {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 8px 12px 0;
}

.desk-link {
  display: block;
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025));
  text-align: center;
  text-decoration: none;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 12px;
}

a.desk-link.spot-red { color: #ff5d5d; }
a.desk-link.spot-blue { color: #6aa4ff; }
a.desk-link.spot-gold { color: #e2c16a; }
a.desk-link.spot-silver { color: #d5d8de; }
a.desk-link.spot-green { color: #5dce86; }
.desk-link:hover, .desk-link:focus-visible, .desk-link[aria-current="page"] {
  background: #f4f4f4;
  color: #141414;
}

a.col-head { display: block; text-decoration: none; }
a.col-head:hover, a.col-head:focus-visible { background: rgba(255, 255, 255, 0.1); }

.search-row { padding: 12px 12px 0; position: relative; z-index: 5; }
.search-line { display: flex; align-items: stretch; gap: 8px; }
.search-line .search-wrap { flex: 1; min-width: 0; }
.search-line .btn {
  flex: 0 0 auto;
  padding: 0 28px;
  font-size: 16px;
}
.board-hint { margin: 10px 12px 0; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: #bdbdbd; }

.board {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 8px;
}

.col {
  min-height: 0;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
}

.col-head {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.04);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.col-list { overflow: auto; min-height: 0; flex: 1; }
.pick .who { margin-top: 6px; font-size: 16px; }
.pick .ctx {
  display: block;
  margin-top: 4px;
  color: #cfcfcf;
  font-size: 12px;
  line-height: 1.35;
}
.pick.is-live .ctx { color: #d7d7d7; }
.col .empty { padding: 14px 12px; }

.people {
  display: grid;
  grid-template-columns: minmax(280px, 420px) minmax(0, 1fr);
  gap: 28px;
  padding: 20px;
  align-items: start;
}

.form-grid { display: grid; gap: 14px; }
.portrait-preview {
  width: 72px;
  height: 72px;
  object-fit: cover;
  object-position: center 15%;
  background: #111;
}
input[type="file"] { color: #f4f4f4; font-size: 14px; max-width: 100%; }
.msg { min-height: 1.2em; margin: 0; }
.count { color: #bdbdbd; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; }
.group-label {
  margin: 18px 0 6px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #cfcfcf;
}

.cat-royalfamily { box-shadow: inset 3px 0 0 #fff; }
.cat-household { box-shadow: inset 3px 0 0 #c8c8c8; }
.cat-church { box-shadow: inset 3px 0 0 #d9d0c2; }
.cat-parliament { box-shadow: inset 3px 0 0 #b7c0c9; }
.cat-government { box-shadow: inset 3px 0 0 #dedede; }
.cat-politics { box-shadow: inset 3px 0 0 #c9c3b6; }
.cat-military { box-shadow: inset 3px 0 0 #aeb6bf; }
.cat-international { box-shadow: inset 3px 0 0 #b7c3ce; }
.cat-guest { box-shadow: inset 3px 0 0 #8d8d8d; }

@media (max-width: 1100px) {
  .board { grid-template-columns: 1fr 1fr; }
  .page-output .l3 { padding: 22px 28px 32px; }
}

@media (max-width: 800px) {
  .spots { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .spots a:last-child { grid-column: 1 / -1; }
  .stack, .people, .board { grid-template-columns: 1fr; }
  .top { align-items: flex-start; flex-wrap: wrap; }
  .onair { max-width: none; }
}
