/* Callboard - Phase 0 styles.
 *
 * The brand palette lives here as custom properties from the start, so that
 * when real pages arrive they ask for a token rather than pasting a hex code.
 *
 * Signal Red and Confirmed Green are defined but deliberately unused on this
 * page. Red means one thing in this app - something a worker needs to act on
 * now, like an expiring offer or a cancelled call - and it keeps that meaning
 * only by never being spent on decoration. */

:root {
  /* THE BRIEF: this has to read like the call board by the stage door.
   *
   * A call board is a dark framed case in a backstage corridor with the
   * day's call typed and posted on it. So the chrome is a warm near-black
   * deck and the content is paper posted on it.
   *
   * Three things carry it, and they are what to defend if anyone wants to
   * "clean this up":
   *   1. The black is WARM. Blue-black reads as tech and kills it.
   *   2. The paper is photocopy cream, never white.
   *   3. Times, codes and names read off a sheet are MONOSPACE.
   *
   * Signal Red means one thing in this app - something a worker must act on
   * now, like an expiring offer or a cancelled call - and it keeps that
   * meaning only by never being spent on decoration. */

  /* The board itself: stage deck, masking, road case. */
  --deck: #131110;
  --deck-raise: #1F1B18;
  --deck-rule: #332C27;

  /* Posted paper, and what is typed on it. */
  --paper: #F2EEE6;
  --sheet: #FBF8F2;
  --ink: #16130F;
  --slate: #5E5649;
  --rule: #D9D1C2;

  /* The bulb. Incandescent, and only ever marks what is lit or current. */
  --marquee-amber: #FFB340;
  --amber-dim: #8A5A12;
  --amber-glow: rgba(255, 179, 64, 0.22);

  /* Gels. */
  --signal-red: #CC3B2E;
  --confirmed-green: #3E7C59;

  --display: 'Oswald', -apple-system, BlinkMacSystemFont, 'Segoe UI',
             Helvetica, Arial, sans-serif;
  --font: 'Public Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI',
          Helvetica, Arial, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 2rem 1.25rem;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  /* Workers read this on a phone at 5am, so nothing is set small. */
  font-size: 1rem;
  line-height: 1.5;
}

.shell {
  max-width: 34rem;
  margin: 0 auto;
}

.wordmark {
  margin: 0;
  font-family: var(--display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 2rem;
  letter-spacing: -0.01em;
}

.tagline {
  margin: 0.25rem 0 2rem;
  color: var(--slate);
}

.panel {
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--sheet);
  padding: 1.25rem;
}

.panel h2 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--slate);
}

.note {
  margin: 0 0 1rem;
  color: var(--slate);
}

.status {
  margin: 0;
  padding: 0.75rem 0.9rem;
  border-radius: 4px;
  border-left: 3px solid var(--slate);
  background: var(--paper);
}

.status-waiting { border-left-color: var(--rule); color: var(--slate); }
.status-ok      { border-left-color: var(--confirmed-green); }

/* Amber, not red. A misconfigured deploy check is a thing to go and fix, not
 * an emergency a worker is looking at - and red is spoken for. */
.status-problem { border-left-color: var(--marquee-amber); }

/* ---------------------------------------------------------------------------
 * The worker profile
 *
 * Read on a phone, often outdoors, often early. So: nothing under 16px, real
 * spacing between anything tappable, and no colour carrying meaning on its
 * own - every badge says its status in words as well.
 * ------------------------------------------------------------------------ */

.topbar {
  border-bottom: 1px solid var(--rule);
  padding: 0.75rem 1.25rem;
  margin: -2rem -1.25rem 1.5rem;
  background: var(--sheet);
}

.wordmark-link { text-decoration: none; color: inherit; }
.wordmark-sm { font-family: var(--display); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.02em; }

h1 { font-size: 1.5rem; margin: 0 0 1.25rem; }

.panel + .panel { margin-top: 1.25rem; }

.panel h3 {
  margin: 1rem 0 0.25rem;
  font-size: 1.0625rem;
}

.hint {
  margin: 0.25rem 0 0;
  color: var(--slate);
  font-size: 0.9375rem;
}

/* Forms ------------------------------------------------------------------ */

.stack { display: flex; flex-direction: column; gap: 0.35rem; }
.stack label { font-weight: 600; font-size: 0.9375rem; margin-top: 0.6rem; }

input[type="text"], input[type="tel"], input[type="email"],
input[type="date"], select {
  font: inherit;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--rule);
  border-radius: 4px;
  background: var(--sheet);
  color: var(--ink);
  min-width: 0;
  width: 100%;
}

input:focus-visible, select:focus-visible, button:focus-visible {
  outline: 2px solid var(--marquee-amber);
  outline-offset: 1px;
}

/* A read-only field should look unavailable without looking broken. */
input[readonly] {
  background: var(--paper);
  color: var(--slate);
}

.row { display: flex; align-items: center; gap: 0.75rem; margin-top: 0.9rem; }
.row-wrap { flex-wrap: wrap; align-items: flex-end; }
.field { display: flex; flex-direction: column; gap: 0.35rem; flex: 1 1 8rem; }
.field label { font-weight: 600; font-size: 0.9375rem; }

.check { display: flex; align-items: center; gap: 0.5rem; font-weight: 400; }
.check input { width: auto; }

/* Buttons ---------------------------------------------------------------- */

.btn {
  font: inherit;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--rule);
  border-radius: 4px;
  background: var(--sheet);
  color: var(--ink);
  cursor: pointer;
  /* Big enough to hit with a thumb in the dark. */
  min-height: 2.75rem;
}

.btn:hover { border-color: var(--slate); }

.btn-primary {
  background: var(--marquee-amber);
  border-color: var(--marquee-amber);
  color: var(--ink);
  font-weight: 600;
}

.btn-quiet { padding: 0.4rem 0.6rem; min-height: 2.25rem; color: var(--slate); }
.btn:disabled { opacity: 0.4; cursor: default; }

/* Some buttons are links now that pages are real pages. They should not
   announce that by turning blue and underlining themselves. */
a.btn {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--ink);
}
a.btn-quiet { color: var(--slate); }

/* Records ---------------------------------------------------------------- */

.records { list-style: none; margin: 0.75rem 0 0; padding: 0; }

.record {
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 0.75rem 0.85rem;
  background: var(--paper);
}
.record + .record { margin-top: 0.6rem; }

.record-head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.record-title, .list-code { font-weight: 600; }
.list-code { letter-spacing: 0.02em; }
.record-line { margin: 0.35rem 0 0; }

.record-head .btn-quiet { margin-left: auto; }

.membership + .membership {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
}

/* Badges ----------------------------------------------------------------- */
/*
 * The word is the badge. Colour is a second signal, never the only one, so
 * these still read correctly in greyscale or to someone who cannot separate
 * amber from green.
 */

.badge {
  font-size: 0.8125rem;
  font-weight: 600;
  /* No text-transform. Statuses are already lowercase in the database, so it
   * bought nothing there, and it was mangling the badges that carry a real
   * name - "Lighting Board Operator" is not a status word. */
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  border: 1px solid var(--rule);
  background: var(--sheet);
  color: var(--slate);
}

.badge-ok   { border-color: var(--confirmed-green); color: var(--confirmed-green); }
.badge-warn { border-color: var(--marquee-amber); color: #8A5A12; }
.badge-note { border-color: var(--slate); color: var(--slate); }

/* Banners and feedback --------------------------------------------------- */

.banner {
  border: 1px solid var(--rule);
  border-left-width: 3px;
  border-radius: 4px;
  padding: 0.75rem 0.85rem;
  margin-bottom: 1rem;
  background: var(--sheet);
}

.banner p { margin: 0; }
.banner label { display: block; margin-top: 0.6rem; font-weight: 600; font-size: 0.9375rem; }
.banner input { margin-top: 0.25rem; }
.banner .btn { margin-top: 0.5rem; }

/* Amber, not red. A missing Access configuration is something to go and fix,
 * and red in this app means an offer is about to expire or a confirmed call
 * has been cancelled. Spending it here would blunt it there. */
.banner-warn { border-left-color: var(--marquee-amber); }
.banner-note { border-left-color: var(--slate); }

.said { font-size: 0.9375rem; color: var(--slate); }
.said-ok { color: var(--confirmed-green); }
.said-problem { color: #8A5A12; font-weight: 600; }

@media (max-width: 30rem) {
  .row { flex-wrap: wrap; }
  .record-head .btn-quiet { margin-left: 0; }
}

/* ---------------------------------------------------------------------------
 * The dispatcher's back office
 *
 * Read at a desk rather than on a phone, and denser than the worker side: a
 * dispatcher is scanning a list of names against the clock. Wider shell, but
 * the same components, so the two sides of the app do not drift apart.
 * ------------------------------------------------------------------------ */

.shell-wide { max-width: 52rem; }

.topbar { display: flex; align-items: center; gap: 1.25rem; }

.topnav { display: flex; gap: 1rem; margin-left: auto; }
.topnav a {
  color: var(--slate);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 600;
}
.topnav a:hover { color: var(--ink); }

/* The page you are on, marked without relying on colour alone. */
.topnav a[aria-current="page"] {
  color: var(--ink);
  border-bottom: 2px solid var(--marquee-amber);
}

/* Inline controls inside a record - a status dropdown and its reason box -
 * should not each stretch to the full width the way stacked form fields do. */
.record .row select,
.record .row input[type="text"] { width: auto; flex: 1 1 10rem; }
.record .row select { flex: 0 1 12rem; }

.membership h3 { margin: 0; }

/* The venue's slot lines: several short fields on one row rather than a stack,
 * because a call is read across - how many, of what, when. */
.qty { width: 5rem; flex: 0 0 auto; }
.record .row input[type="number"],
.record .row input[type="datetime-local"] { width: auto; flex: 0 1 auto; }

.crew { list-style: none; margin: 0.5rem 0 0; padding: 0; }
.crew li {
  padding: 0.3rem 0;
  border-top: 1px solid var(--rule);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* The landing page's three doors. */
.doors { list-style: none; margin: 0; padding: 0; }
.doors li + li { margin-top: 0.9rem; padding-top: 0.9rem; border-top: 1px solid var(--rule); }
.doors a { display: block; font-weight: 600; color: var(--ink); }
.doors .hint { display: block; margin-top: 0.15rem; }

/* Why a slot could not be filled. Dense on purpose: a dispatcher reads the
 * whole list, and summarising it would hide the one name they need. */
.reasons { margin: 0.4rem 0 0; padding-left: 1.1rem; }
.reasons li { color: var(--slate); font-size: 0.9375rem; }

/* ---------------------------------------------------------------------------
 * The call board
 *
 * The one screen somebody reads at five in the morning, half awake, outdoors,
 * deciding whether to get in the van. The offer is the largest thing on the
 * page and the two answers are far apart, because a mis-tap here costs
 * somebody a day's work or gets them a no-show.
 * ------------------------------------------------------------------------ */

.offer {
  border: 1px solid var(--rule);
  border-left: 4px solid var(--marquee-amber);
  border-radius: 6px;
  background: var(--sheet);
  padding: 1rem 1.1rem;
  margin-bottom: 1rem;
}

.offer-lapsed { border-left-color: var(--rule); opacity: 0.65; }

/* THE ONE PLACE RED IS SPENT.
 *
 * The brand reserves Signal Red for things a worker must act on now. An offer
 * about to run out is exactly that, and it earns its weight by appearing
 * nowhere else - not on errors, not on destructive buttons, not on validation.
 * Under five minutes it turns red; before that it is ordinary text. */
.countdown {
  font-size: 1.125rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  margin: 0 0 0.35rem;
  color: var(--slate);
}

.countdown-urgent { color: var(--signal-red); }
.countdown-gone { color: var(--slate); font-weight: 400; }

.offer-event { font-size: 1.375rem; margin: 0 0 0.15rem; line-height: 1.2; }
.offer-where { margin: 0; font-weight: 600; color: var(--slate); }

.facts {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.3rem 0.9rem;
  margin: 0.9rem 0 0;
}
.facts dt { color: var(--slate); font-size: 0.9375rem; }
.facts dd { margin: 0; font-weight: 600; }

.offer-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1rem;
}

/* Both full-size and equally weighted. Declining is not a lesser action and
 * should not be a lesser button - but they are far enough apart that a thumb
 * does not find the wrong one. */
.offer-actions .btn { flex: 1; min-height: 3.25rem; font-size: 1.0625rem; font-weight: 600; }

.btn-accept {
  background: var(--confirmed-green);
  border-color: var(--confirmed-green);
  color: #FFF;
}

/* Not red. Declining is a normal, legitimate answer, and colouring it as a
 * danger would both misuse red and imply the worker is doing something wrong. */
.btn-decline { background: var(--sheet); border-color: var(--slate); color: var(--ink); }

#work h3 { margin: 1.1rem 0 0; font-size: 1rem; }
#work h3:first-child { margin-top: 0; }

/* The words a dispatcher reads out. Set apart so it is obviously a script to
 * be spoken rather than another label on the screen. */
.script {
  margin: 0.75rem 0;
  padding: 0.6rem 0.9rem;
  border-left: 3px solid var(--marquee-amber);
  background: var(--paper);
  font-size: 1.0625rem;
}

/* ---------------------------------------------------------------------------
 * Orientation
 *
 * The dispatch screen was forty thousand pixels of stacked panels. Everything
 * on it was equally weighted, so "somebody is waiting on you" sat at the same
 * level as thresholds that get set once a year. These are the pieces that put
 * the work first and let the rest be found rather than scrolled past.
 * ------------------------------------------------------------------------ */

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* The development warning. It has to be visible - it means anyone can claim to
 * be anyone - but it is a fact about the environment, not the dispatcher's
 * work, and as a full panel it was taking a third of the first screen. */
.devbar {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  padding: 0.45rem 0.7rem;
  margin: -0.5rem 0 1.25rem;
  border: 1px solid var(--marquee-amber);
  border-radius: 4px;
  background: #FDF6EC;
  font-size: 0.875rem;
  color: var(--ink);
}

.devbar-flag {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.75rem;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  background: var(--marquee-amber);
}

/* Being signed out is ordinary, not a breach. Amber is for the environment
   where anyone can claim to be anyone; this one is just nobody yet, and
   dressing it the same way cries wolf. */
.devbar-signedout {
  border-color: var(--rule);
  background: var(--paper);
  color: var(--slate);
}

.devbar-signedout .devbar-flag { background: var(--rule); color: var(--slate); }

.devbar input { width: auto; flex: 1 1 14rem; padding: 0.3rem 0.45rem; font-size: 0.875rem; }
.devbar .btn { min-height: 2rem; padding: 0.25rem 0.6rem; font-size: 0.875rem; }

.pagehead { margin-bottom: 1rem; }
.pagehead h1 { margin: 0; }
.pagehead-sub { margin: 0.15rem 0 0; color: var(--slate); font-size: 0.9375rem; }

/* The three questions a dispatcher opens this screen with. Each tile goes to
 * the thing rather than describing it - a number you cannot act on is
 * decoration. */
.summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
  gap: 0.6rem;
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0;
}

.tile { margin: 0; }

.tile-button {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--rule);
  border-left: 3px solid var(--rule);
  border-radius: 4px;
  background: var(--sheet);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.tile-button:hover { border-color: var(--slate); }
.tile-count { font-size: 1.5rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.tile-label { font-size: 0.875rem; color: var(--slate); line-height: 1.2; }

/* Amber where something is outstanding, plain where it is not. Not red: red is
 * an offer about to run out, and a queue of two verifications is not that. */
.tile-attention .tile-button { border-left-color: var(--marquee-amber); }
.tile-quiet .tile-button { border-left-color: var(--slate); }
.tile:not(.tile-attention):not(.tile-quiet) .tile-count { color: var(--slate); font-weight: 400; }

/* Sections of the job, one at a time. */
.tabs {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--rule);
}

.tab {
  font: inherit;
  font-weight: 600;
  padding: 0.55rem 0.9rem;
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  color: var(--slate);
  cursor: pointer;
  min-height: 2.75rem;
}

.tab:hover { color: var(--ink); }

.tab[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--marquee-amber);
}

/* ---------------------------------------------------------------------------
 * The front door
 * ------------------------------------------------------------------------ */

.landing { padding-top: 2.5rem; }
.landing .wordmark { font-size: 2.5rem; }
.landing .tagline { margin-bottom: 2.5rem; }

.doors { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.85rem; }

.door {
  border: 1px solid var(--rule);
  border-left: 3px solid var(--marquee-amber);
  border-radius: 6px;
  background: var(--sheet);
}

.door-main {
  display: block;
  padding: 1.1rem 1.2rem;
  text-decoration: none;
  color: inherit;
}

.door-main:hover { background: var(--paper); }
.door-title { display: block; font-size: 1.25rem; font-weight: 700; }
.door-sub { display: block; margin-top: 0.15rem; color: var(--slate); }

.door-aside {
  display: block;
  padding: 0.6rem 1.2rem;
  border-top: 1px solid var(--rule);
  font-size: 0.9375rem;
  color: var(--slate);
}
.door-aside:hover { color: var(--ink); }

/* Quiet when healthy, loud when not. */
.deploycheck {
  max-width: 34rem;
  margin: 3rem auto 2rem;
  padding: 0 1.25rem;
}

.deploycheck-line { margin: 0; font-size: 0.8125rem; color: var(--slate); }
.deploycheck-ok::before { content: '· '; }
.deploycheck-ok { opacity: 0.6; }

.deploycheck-problem {
  padding: 0.6rem 0.8rem;
  border-left: 3px solid var(--marquee-amber);
  background: #FDF6EC;
  color: var(--ink);
  font-size: 0.9375rem;
}

/* ---------------------------------------------------------------------------
 * The application shell
 *
 * A menu down the side, a bar across the top, and one page per thing. This
 * replaced a single dispatch page with tabs, which hid the length without
 * giving anything an address - a hall needs "open the roster" to be a place
 * you can link to, not a state a page happens to be in.
 * ------------------------------------------------------------------------ */

body.has-shell { padding: 0; background: var(--paper); }

.app { min-height: 100vh; display: flex; flex-direction: column; }

.appbar {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.6rem 1rem;
  background: var(--ink);
  color: #FFF;
  position: sticky;
  top: 0;
  z-index: 20;
}

.appbar-brand { color: var(--paper); text-decoration: none;
  font-family: var(--display); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.03em; }

/* Pushed right, and allowed to truncate rather than wrap the bar onto two
 * lines - the name matters less than the bar staying one line. */
.appbar-identity {
  margin-left: auto;
  font-size: 0.875rem;
  color: #C9CCD2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.appbar-toggle {
  display: none;
  font: inherit;
  font-size: 0.875rem;
  padding: 0.3rem 0.6rem;
  border: 1px solid #4A5160;
  border-radius: 4px;
  background: none;
  color: #FFF;
  cursor: pointer;
}

.app-body { display: flex; flex: 1; align-items: flex-start; }

.sidebar {
  flex: 0 0 15rem;
  padding: 1.25rem 0.75rem 2rem;
  border-right: 1px solid var(--rule);
  background: var(--sheet);
  position: sticky;
  top: 2.9rem;
  max-height: calc(100vh - 2.9rem);
  overflow-y: auto;
}

.sidebar-heading {
  margin: 1.1rem 0 0.35rem;
  padding: 0 0.6rem;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--slate);
}
.sidebar-heading:first-child { margin-top: 0; }

.sidebar-list { list-style: none; margin: 0; padding: 0; }

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.6rem;
  border-radius: 4px;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.9375rem;
  /* Tall enough to hit without aiming. */
  min-height: 2.5rem;
}

.sidebar-link:hover { background: var(--paper); }

/* Where you are, marked by weight and a rule rather than colour alone. */
.sidebar-link[aria-current="page"] {
  background: var(--paper);
  font-weight: 700;
  box-shadow: inset 3px 0 0 var(--marquee-amber);
}

/* Only rendered when there is something to count. A badge reading zero draws
 * the eye to nothing. */
.sidebar-badge {
  margin-left: auto;
  min-width: 1.4rem;
  padding: 0.05rem 0.35rem;
  border-radius: 999px;
  background: var(--marquee-amber);
  color: var(--ink);
  font-size: 0.75rem;
  font-weight: 700;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.content {
  flex: 1;
  min-width: 0;
  max-width: 56rem;
  padding: 1.5rem 1.5rem 4rem;
}

.has-shell .devbar { margin-top: 0; }

/* Narrow screens: the menu becomes a drawer rather than a column. */
@media (max-width: 48rem) {
  .appbar-toggle { display: block; }

  .sidebar {
    display: none;
    position: static;
    max-height: none;
    flex-basis: auto;
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--rule);
  }

  .app-body { flex-direction: column; }
  body.menu-open .sidebar { display: block; }
  .content { padding: 1rem 1rem 3rem; max-width: none; }
}

/* Tiles are links now, not buttons, so a whole tile is a target and the
 * address is visible in the status bar. That means undoing the browser's
 * default link treatment, which was rendering the count blue and underlined. */
a.tile-button { color: inherit; text-decoration: none; }
a.tile-button:hover { background: var(--paper); }
a.tile-button .tile-count { color: var(--ink); }

/* A filter row above a list, rather than controls buried inside it. */
.filters { margin-bottom: 1rem; align-items: flex-end; }
.filters .field { flex: 0 1 12rem; }
.filters .field-wide { flex: 0 1 30rem; }


/* ------------------------------------------------------------------------
 * Typed, not set.
 *
 * Call times, list codes, counts and seniority dates are things a dispatcher
 * reads off a sheet, and a call sheet is typed. Monospace here is what makes
 * the roster read as a posted call rather than as a table in a dashboard -
 * and it aligns the digits for free, which is why the figures line up when
 * you scan a column of start times.
 * --------------------------------------------------------------------- */

.tile-count,
.sidebar-badge,
.when,
.slot-time,
time,
td.num,
.mono {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}

/* The sidebar section labels are the typed header on a posted notice. */
.sidebar-heading {
  font-family: var(--display);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* ------------------------------------------------------------------------
 * The sign-in page.
 *
 * The one page a stranger can reach, so it is the board itself rather than
 * a screen inside the app: dark deck, one sheet posted on it, nothing else.
 * --------------------------------------------------------------------- */

body.signin-page {
  background: var(--deck);
  color: var(--paper);
  padding: 0;
  min-height: 100vh;
}

.bulbs {
  height: 10px;
  background-image: radial-gradient(circle at 7px 5px,
    var(--marquee-amber) 0 2.5px, var(--amber-glow) 2.5px 5px, transparent 5px);
  background-size: 14px 10px;
  background-repeat: repeat-x;
  border-bottom: 1px solid var(--deck-rule);
}

.signin {
  max-width: 24rem;
  margin: 0 auto;
  padding: 3rem 1rem 4rem;
}

.signin .wordmark {
  font-size: 1.375rem;
  text-align: center;
  margin-bottom: 1.5rem;
  color: var(--paper);
}

.signin-card {
  background: var(--sheet);
  color: var(--ink);
  border: 1px solid var(--rule);
  border-radius: 2px;
  padding: 1.5rem;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.4);
}

.signin-card h1 {
  font-family: var(--display);
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
}

.signin-lede {
  margin: 0 0 1.25rem;
  color: var(--slate);
  font-size: 0.9375rem;
}

.signin .field {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.375rem;
}

.signin input {
  width: 100%;
  /* 16px minimum, or iOS zooms the page when the field takes focus. */
  font-size: 1rem;
  font-family: inherit;
  padding: 0.6875rem 0.75rem;
  border: 1px solid var(--rule);
  border-radius: 3px;
  background: #fff;
  color: var(--ink);
  margin-bottom: 1rem;
}

.signin input:focus-visible {
  outline: 2px solid var(--marquee-amber);
  outline-offset: 1px;
  border-color: var(--amber-dim);
}

/* The code is read off a message and typed in. Monospace, spaced out, big -
   this is the one field where getting a digit wrong costs a whole round trip. */
.code-input {
  font-family: var(--mono);
  font-size: 1.5rem !important;
  letter-spacing: 0.3em;
  text-align: center;
}

.signin .btn {
  width: 100%;
  display: block;
  text-align: center;
  border: 1px solid transparent;
  border-radius: 3px;
  padding: 0.75rem 1rem;
  font-family: var(--display);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}

.signin .btn-primary {
  background: var(--ink);
  color: var(--sheet);
}

.signin .btn-primary:disabled {
  background: var(--slate);
  cursor: progress;
}

.signin .btn-quiet {
  background: transparent;
  color: var(--slate);
  margin-top: 0.5rem;
  text-transform: none;
  letter-spacing: 0;
  font-family: var(--font);
}

.signin .btn-quiet:hover {
  color: var(--ink);
  text-decoration: underline;
}

.signin-say {
  margin: 1rem 0 0;
  font-size: 0.9375rem;
  padding: 0.625rem 0.75rem;
  border-radius: 3px;
  border-left: 3px solid var(--rule);
  background: var(--paper);
}

/* Amber, not red. A mistyped code is not an emergency, and Signal Red means
   a worker must act now - spending it here is how it stops meaning that. */
.signin-say-warn {
  border-left-color: var(--marquee-amber);
}

.signin-say-ok {
  border-left-color: var(--confirmed-green);
}

.signin-foot {
  margin: 1.5rem 0 0;
  text-align: center;
  font-size: 0.875rem;
  color: #a1968a;
}
