/* ---------------------------------------------------------------------------
   AIDC — Agenda Management System
   G&K web design language, matching internal.g-k.co. Screen first, print last.

   Red is structural, never decorative: thin rules, small-caps labels, the
   active-tab marker, list markers. Never body text, never a large fill.
--------------------------------------------------------------------------- */

:root {
  --ink:        #14171F;
  --navy:       #141A2E;
  --crimson:    #C8102E;
  --crimson-dk: #9E0C24;
  --blue:       #1F4D78;
  --blue-500:   #2E74B5;
  --paper:      #FBFAF8;
  --paper-2:    #F4F1EA;
  --line:       #E2DDD2;
  --slate:      #4A4A4A;
  --slate-2:    #6B6B6B;

  --display: "Saira Condensed", "Arial Narrow", system-ui, sans-serif;
  --sans:    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono:    ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --radius:    12px;
  --radius-sm: 8px;
  --shadow:    0 1px 2px rgba(20, 23, 31, .04), 0 10px 30px -22px rgba(20, 26, 46, .45);
  --shadow-lg: 0 40px 80px -50px rgba(20, 26, 46, .5);
  --ease:      cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 500;
  line-height: 1.08;
  margin: 0 0 .5rem;
  letter-spacing: 0;
}
h1 { font-size: 2rem; }
h2 { font-size: 1.45rem; }
h3 { font-size: 1.16rem; font-weight: 600; }
p  { margin: 0 0 .9rem; }
a  { color: inherit; text-decoration: none; }
a:hover { color: var(--blue); }
img { max-width: 100%; }
code, .mono { font-family: var(--mono); font-size: .88em; }
code { background: var(--paper-2); padding: 2px 6px; border-radius: 4px; }
small, .small { font-size: .84rem; }

.muted   { color: var(--slate-2); }
.dim     { color: var(--slate); }
.nowrap  { white-space: nowrap; }
.right   { text-align: right; }
.center  { text-align: center; }
.stack > * + * { margin-top: .55rem; }
.mt   { margin-top: 1rem; }
.mt-2 { margin-top: 1.75rem; }
.mb   { margin-bottom: 1rem; }
.hidden { display: none !important; }

/* The G&K eyebrow: small caps, wide tracking, short crimson rule. */
.eyebrow {
  font-family: var(--sans);
  font-size: 12px; font-weight: 600; letter-spacing: .22em;
  text-transform: uppercase; color: var(--blue);
  display: inline-flex; align-items: center; gap: .8em;
  margin: 0 0 14px;
}
.eyebrow::before {
  content: ""; width: 26px; height: 1px;
  background: var(--crimson); opacity: .8;
}
.lede { font-size: 1.02rem; color: var(--slate); max-width: 62ch; }

/* --- Top bar -------------------------------------------------------------- */

.bar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251, 250, 248, .9);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.bar-in {
  max-width: 1180px; margin-inline: auto; padding: 0 24px;
  min-height: 70px; display: flex; align-items: center; gap: 22px;
}
/* Two targets, not one: the G&K mark goes up to the hub, the tool name goes to
   that tool's own home. The convention people already expect from a logo. */
.bar-brand { display: flex; align-items: center; gap: 11px; flex-shrink: 0; }
.bar-brand img { height: 30px; width: auto; display: block; }
.bar-home { display: flex; align-items: center; transition: opacity .2s; }
.bar-home:hover { opacity: .6; }
.bar-brand::after {
  content: ""; width: 1px; height: 20px; background: var(--line); flex: none;
  order: 1;
}
.bar-mod {
  font-family: var(--display); font-size: 15px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--crimson); font-weight: 600;
  order: 2; transition: color .2s;
}
.bar-mod:hover { color: var(--crimson-dk); }

/* The explicit way out, in the sticky bar so it is reachable from anywhere on
   a long page. The footer has one too, but the footer is not sticky. */
.bar-tools {
  font-size: 13px; color: var(--slate-2); white-space: nowrap;
  display: inline-flex; align-items: center; gap: .35em; transition: color .2s;
}
.bar-tools:hover { color: var(--blue); }
.bar-tabs { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.bar-tabs a {
  font-size: 14.5px; font-weight: 500; padding: 9px 14px;
  border-radius: 100px; position: relative; color: var(--ink);
  transition: color .2s, background .2s;
}
.bar-tabs a:hover { color: var(--blue); background: var(--paper-2); }
.bar-tabs a.on { color: var(--blue); }
.bar-tabs a.on::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 2px;
  height: 2px; background: var(--crimson); border-radius: 2px;
}
.bar-me { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.who { font-size: 13px; color: var(--slate-2); white-space: nowrap; }
.who-pic { width: 26px; height: 26px; border-radius: 50%; display: block; }

/* Second row: the event currently in scope. */
.bar-sub { border-top: 1px solid var(--line); background: rgba(244, 241, 234, .55); }
.bar-sub .bar-in { min-height: 50px; }
.bar-sub .scope {
  font-family: var(--display); font-size: 14px; letter-spacing: .1em;
  text-transform: uppercase; color: var(--slate); flex-shrink: 0;
  max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

@media (max-width: 820px) {
  .bar-in { min-height: auto; flex-wrap: wrap; padding: 10px 16px; gap: 8px; }
  .bar-brand { order: 1; }
  .bar-me { order: 2; margin-left: auto; }
  /* nowrap, not wrap: the tabs become one row that scrolls sideways. Allowed
     to wrap they stack two or three deep and the header eats the screen
     before any content appears. */
  .bar-tabs {
    order: 3; flex: 0 0 100%; width: 100%; gap: 2px;
    flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .bar-tabs::-webkit-scrollbar { display: none; }
  .bar-tabs a { white-space: nowrap; padding: 8px 12px; font-size: 14px; flex: none; }
  .who { display: none; }
  .bar-brand img { height: 24px; }
  .bar-mod { font-size: 13px; }
  .bar-sub .scope { max-width: 100%; font-size: 12.5px; }
}

/* --- Layout --------------------------------------------------------------- */

.wrap { max-width: 1180px; margin-inline: auto; padding: 40px 24px 80px; }
.wrap-narrow { max-width: 760px; }

.page-head { display: flex; align-items: flex-start; gap: 1rem; flex-wrap: wrap; margin-bottom: 28px; }
.page-head .grow { flex: 1 1 320px; min-width: 0; }
.page-head h1 { margin-bottom: .2rem; font-size: clamp(1.8rem, 3vw, 2.4rem); }
.crumb { font-size: 12.5px; color: var(--slate-2); margin-bottom: 8px; }
.crumb a:hover { color: var(--blue); }

.event-logo { height: 44px; width: auto; border-radius: 4px; flex: none; }
.event-logo-lg { height: 72px; }

/* --- Cards & tables ------------------------------------------------------- */

.card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow);
}
.card + .card { margin-top: 1.1rem; }
.card-head {
  padding: 16px 22px; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: .75rem; flex-wrap: wrap;
}
.card-head h2, .card-head h3 { margin: 0; }
.card-head .grow { flex: 1; }
.card-body { padding: 22px; }
.card-body.tight { padding: 14px 22px; }

.grid { display: grid; gap: 1.1rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

/* Main column plus a sidebar. Named classes rather than inline styles so the
   breakpoint below can reach them — an inline grid-template-columns cannot be
   overridden by a media query, which left every one of these two-up on a
   phone, squeezing the main column to a few characters wide. */
.grid-side      { grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr); align-items: start; }
.grid-side-wide { grid-template-columns: minmax(0, 3fr) minmax(300px, 2fr); align-items: start; }
.grid-side-even { grid-template-columns: minmax(0, 1fr) minmax(320px, 1fr); align-items: start; }
.grid-halves    { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);     align-items: start; }

@media (max-width: 900px) {
  .grid-side, .grid-side-wide, .grid-side-even, .grid-halves {
    grid-template-columns: minmax(0, 1fr);
  }
}

table { width: 100%; border-collapse: collapse; }
th, td { padding: 11px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
th {
  font-family: var(--sans); font-size: 11px; text-transform: uppercase;
  letter-spacing: .12em; color: var(--slate-2); font-weight: 700;
  background: var(--paper-2);
}
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: rgba(244, 241, 234, .5); }
td.actions { white-space: nowrap; text-align: right; }

.empty { padding: 56px 24px; text-align: center; color: var(--slate-2); }
.empty strong {
  display: block; font-family: var(--display); font-size: 1.3rem;
  font-weight: 600; color: var(--ink); margin-bottom: .35rem;
}

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

.btn {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--sans); font-weight: 600; font-size: 14.5px;
  padding: 9px 18px; border-radius: 100px; cursor: pointer;
  border: 1px solid var(--line); background: #fff; color: var(--ink);
  transition: background .2s var(--ease), border-color .2s, color .2s;
  white-space: nowrap;
}
.btn:hover { background: var(--paper-2); border-color: #d6d0c2; color: var(--ink); }
.btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.btn-primary { background: var(--navy); border-color: var(--navy); color: #fff; }
.btn-primary:hover { background: #1d2540; border-color: #1d2540; color: #fff; }
.btn-danger { color: var(--crimson); border-color: #eccdd2; }
.btn-danger:hover { background: #fdf3f4; border-color: #e0b3ba; color: var(--crimson-dk); }
.btn-sm { padding: 5px 12px; font-size: 13px; }
.btn-block { width: 100%; justify-content: center; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-row { display: flex; gap: .55rem; flex-wrap: wrap; align-items: center; }

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

.field { margin-bottom: 16px; }
.field > label {
  display: block; font-size: 12.5px; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--slate); margin-bottom: 6px;
}
/* Deliberately not scoped to .field: hints also sit inside checkbox labels,
   where there is no .field wrapper. Scoped, they rendered inline and ran
   straight on from the label — "Active Inactive resources keep their history". */
.hint {
  display: block;
  font-size: 12.5px; color: var(--slate-2); margin-top: 5px;
  text-transform: none; letter-spacing: 0; font-weight: 400; line-height: 1.45;
}
.field .req { color: var(--crimson); }

input[type=text], input[type=email], input[type=password], input[type=url],
input[type=date], input[type=time], input[type=datetime-local], input[type=number],
input[type=tel], input[type=search], input[type=file], select, textarea {
  width: 100%; padding: 11px 13px; font-family: var(--sans); font-size: 15px;
  color: var(--ink); background: #fff;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .2s, box-shadow .2s;
}
textarea { min-height: 96px; resize: vertical; line-height: 1.55; }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--blue-500);
  box-shadow: 0 0 0 3px rgba(46, 116, 181, .12);
}
input[type=color] {
  width: 52px; height: 40px; padding: 3px; border: 1px solid var(--line);
  border-radius: var(--radius-sm); background: #fff; cursor: pointer;
}
input[type=file] { padding: 9px 12px; font-size: 14px; }
.field-row { display: flex; gap: 16px; flex-wrap: wrap; }
.field-row > .field { flex: 1 1 180px; }
.check { display: flex; align-items: flex-start; gap: .55rem; font-size: 14.5px; }
.check input { width: auto; margin-top: .3rem; }
.check > span { font-weight: 500; }

/* --- Chips, badges, alerts ------------------------------------------------ */

.chip {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: 3px 11px; border-radius: 100px;
  font-size: 11.5px; font-weight: 700; letter-spacing: .04em;
  background: var(--paper-2); color: var(--slate); white-space: nowrap;
}
.badge {
  display: inline-block; padding: 2px 7px; border-radius: 4px;
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .09em;
  background: var(--paper-2); color: var(--slate);
}
.badge-mod  { background: #fdf3f4; color: var(--crimson-dk); }
.badge-role { background: #eef3f8; color: var(--blue); }

.alert {
  padding: 12px 16px; border-radius: 0 6px 6px 0;
  border-left: 3px solid; font-size: 14.5px; margin: 0 0 20px;
}
.alert-success { background: #f1f7f2; border-color: #2e7d4f; color: #22603c; }
.alert-error   { background: #fdf3f4; border-color: var(--crimson); color: #7c1020; }
.alert-warn    { background: #fdf8ec; border-color: #b8860b; color: #7a5a12; }
.alert-info    { background: #f2f6fa; border-color: var(--blue); color: #1b3f61; }
/* Bare .alert / .ok match the internal.g-k.co sign-in card. */
.alert:not([class*=" alert-"]) { background: #fdf3f4; border-color: var(--crimson); color: #7c1020; }
.ok { background: #f1f7f2; border-left: 3px solid #2e7d4f; color: #22603c; padding: 12px 16px; border-radius: 0 6px 6px 0; font-size: 14.5px; margin: 0 0 20px; }

/* --- Sign in -------------------------------------------------------------- */

body.signin {
  display: flex; align-items: center; justify-content: center;
  min-height: 100vh; padding: 24px;
  background: radial-gradient(120% 90% at 85% 0%, #fff, var(--paper) 62%);
}
.signin-card {
  max-width: 470px; width: 100%; background: #fff;
  border: 1px solid var(--line); border-radius: 14px;
  padding: 44px 40px; box-shadow: var(--shadow-lg); text-align: left;
}
.signin-logo { height: 46px; width: auto; margin-bottom: 28px; display: block; }
.signin-card h1 { font-size: 2rem; margin-bottom: 12px; }
.signin-card .lede { font-size: .97rem; margin: 0 0 26px; }
.signin-card .g_id_signin { margin: 6px 0 22px; }
.fineprint { font-size: 12.5px; color: var(--slate-2); margin: 8px 0 0; }
.fineprint strong { color: var(--slate); }

/* --- Landing hub ---------------------------------------------------------- */

.hero {
  background: var(--navy); color: #fff;
  padding: 76px 24px 68px; text-align: center;
  border-bottom: 3px solid var(--crimson);
}
.hero .hero-logo { height: 46px; width: auto; margin: 0 auto 26px; display: block; }
.hero h1 {
  font-size: clamp(2.1rem, 4.6vw, 3.2rem); margin-bottom: .6rem; color: #fff;
}
.hero p { max-width: 620px; margin: 0 auto; color: rgba(255, 255, 255, .72); font-size: 1.02rem; }
.hero .eyebrow { color: rgba(255, 255, 255, .78); justify-content: center; }
.hero .eyebrow::before { background: var(--crimson); opacity: 1; }

.tiles { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.tile {
  display: flex; flex-direction: column; gap: 10px;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 30px; color: inherit;
  box-shadow: var(--shadow);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s;
}
a.tile:hover {
  transform: translateY(-3px); box-shadow: var(--shadow-lg);
  border-color: #d6d0c2; color: inherit;
}
.tile-icon {
  width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center;
  background: var(--paper-2); color: var(--blue); font-size: 1.2rem; margin-bottom: 4px;
}
.tile h3 { margin: 0; font-size: 1.3rem; font-weight: 600; }
.tile p { margin: 0; font-size: 14.5px; color: var(--slate-2); flex: 1; }
.tile .go { font-size: 14px; font-weight: 600; color: var(--blue); }
.tile.soon { opacity: .6; border-style: dashed; box-shadow: none; }
.tile.soon .tile-icon { color: var(--slate-2); }

.section-label {
  font-family: var(--sans); text-transform: uppercase; letter-spacing: .22em;
  font-size: 12px; font-weight: 600; color: var(--blue);
  margin: 48px 0 18px; display: inline-flex; align-items: center; gap: .8em;
}
.section-label::before { content: ""; width: 26px; height: 1px; background: var(--crimson); opacity: .8; }
.section-label:first-of-type { margin-top: 0; }

.site-foot {
  border-top: 1px solid var(--line); margin-top: 56px; padding: 28px 24px;
  text-align: center; font-size: 12.5px; color: var(--slate-2);
}

/* --- Agenda: running order ------------------------------------------------ */

.day-head {
  display: flex; align-items: baseline; gap: .8rem; flex-wrap: wrap;
  margin: 40px 0 14px; padding-bottom: 8px;
  border-bottom: 1px solid var(--line); position: relative;
}
.day-head::after {
  content: ""; position: absolute; left: 0; bottom: -1px;
  width: 48px; height: 2px; background: var(--crimson);
}
.day-head h2 { margin: 0; }
.day-head .day-meta { font-size: 13px; color: var(--slate-2); }

.slot {
  display: grid; grid-template-columns: 118px 1fr; gap: 22px;
  padding: 18px 0; border-bottom: 1px solid var(--line);
}
.slot:last-child { border-bottom: 0; }
.slot-time {
  font-variant-numeric: tabular-nums; font-weight: 600; font-size: 14.5px;
  color: var(--ink); padding-top: 2px;
}
.slot-time .dur { display: block; font-weight: 400; font-size: 12.5px; color: var(--slate-2); }
.slot-title { font-family: var(--display); font-size: 1.25rem; font-weight: 600; margin: 0 0 4px; }
/* Session titles carry long unbroken tokens — model names, hyphenated phrases,
   the occasional URL in an abstract. Without this they push past the card edge
   at any width narrow enough, rather than wrapping. */
.slot-title, .slot-abstract, .slot-meta, .person { overflow-wrap: anywhere; }
.slot-meta { font-size: 13px; color: var(--slate-2); display: flex; gap: .55rem; flex-wrap: wrap; align-items: center; }
.slot-abstract { font-size: 14.5px; color: var(--slate); margin: 8px 0 0; max-width: 68ch; }
.slot.is-break .slot-title { font-weight: 400; color: var(--slate-2); font-style: italic; }

.people { margin: 10px 0 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.person { display: flex; align-items: baseline; gap: .45rem; font-size: 14.5px; flex-wrap: wrap; }
/* Photographs in a running order: small enough that a line-up stays a list
   rather than becoming a gallery. */
.people.with-photos .person { align-items: center; gap: .55rem; }
.person-photo {
  width: 30px; height: 30px; border-radius: 50%; object-fit: cover;
  background: var(--paper-2); flex: none;
}
.person-photo.avatar-placeholder { border-radius: 4px; object-fit: contain; background: #EDEDED; }

.person .pname { font-weight: 600; }
.person .paff { color: var(--slate-2); }
/* An unfilled seat reads as pending rather than as a name. */
.person.is-unfilled .pname { font-weight: 500; font-style: italic; color: var(--slate-2); }

.avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; background: var(--paper-2); flex: none; }
.avatar-lg { width: 92px; height: 92px; border-radius: 10px; }
.avatar-fallback {
  display: grid; place-items: center; font-size: 12.5px; font-weight: 700;
  color: var(--slate-2); background: var(--paper-2);
}

/* Placeholder seats are passport-shaped (3:4) with the identifying flag band
   along the bottom edge. A circular crop would cut off precisely that band, so
   they render as a contained rounded rectangle instead — which also reads at a
   glance as "seat, not person". */
.avatar-placeholder {
  border-radius: 5px;
  object-fit: contain;
  background: #EDEDED;
}
.avatar-lg.avatar-placeholder { border-radius: 8px; }

/* --- Agenda: venue grid --------------------------------------------------- */

.grid-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
table.venue-grid { min-width: 760px; }
table.venue-grid th.time-col, table.venue-grid td.time-col {
  width: 96px; font-variant-numeric: tabular-nums; font-size: 13px;
  color: var(--slate-2); background: var(--paper-2); white-space: nowrap;
}
table.venue-grid td { border-right: 1px solid var(--line); }
table.venue-grid td:last-child { border-right: 0; }
.grid-item {
  border-left: 3px solid var(--navy); background: var(--paper);
  border-radius: 0 6px 6px 0; padding: 8px 11px; font-size: 13.5px;
}
.grid-item + .grid-item { margin-top: 6px; }
.grid-item strong { display: block; font-weight: 600; line-height: 1.35; }
.grid-item .gm { color: var(--slate-2); font-size: 12.5px; }
/* Faces in a grid cell: small, in a row, names still beneath. */
.grid-faces { display: flex; gap: 3px; flex-wrap: wrap; margin: 4px 0 3px; }
.grid-face { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; background: var(--paper-2); }
.grid-face.avatar-placeholder { border-radius: 3px; object-fit: contain; background: #EDEDED; }
@media print {
  .grid-face { width: 18pt; height: 18pt; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

.clash-list { margin: 0; padding-left: 1.1rem; font-size: 14px; }
.clash-list li { margin-bottom: 4px; }
.clash-list li::marker { color: var(--crimson); }

/* --- Moderator toolkit ---------------------------------------------------- */

.qlist { list-style: none; margin: 0; padding: 0; counter-reset: q; }
.qlist li { counter-increment: q; padding: 12px 0 12px 38px; position: relative; border-bottom: 1px solid var(--line); }
.qlist li:last-child { border-bottom: 0; }
.qlist li::before {
  content: counter(q); position: absolute; left: 0; top: 12px;
  width: 26px; height: 26px; border-radius: 50%; background: var(--paper-2);
  color: var(--crimson); font-size: 12px; font-weight: 700;
  display: grid; place-items: center;
}
.qlist .qpurpose { font-size: 13px; color: var(--slate-2); margin-top: 2px; }

.internal-note {
  border-left: 3px solid var(--crimson); background: #fdf3f4;
  padding: 8px 13px; border-radius: 0 6px 6px 0; font-size: 13.5px;
}
.filelist { list-style: none; margin: 0; padding: 0; }
.filelist li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.filelist li:last-child { border-bottom: 0; }

/* --- Narrow screens -------------------------------------------------------
   Tables carry more columns than a phone is wide. Rather than hiding columns
   — which loses information silently — each table scrolls inside its card, so
   the page itself never moves sideways. */

@media (max-width: 820px) {
  /* Both positions a table appears in: straight inside a card, and nested in
     a card body alongside other content. */
  .card > table,
  .card-body > table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
  }
  /* A long event name in a button ("Add selected to …") was pushing the whole
     document wider than the screen. Buttons may wrap here. */
  .btn { white-space: normal; }
  .card-head { align-items: flex-start; }
  .page-head .btn-row { width: 100%; }
}

/* --- Slot picker ----------------------------------------------------------
   A day laid out left to right, one lane per hall. Booked time is blocked
   out; free slots of the chosen length are the only things clickable, so the
   programme lines up across halls instead of drifting by a few minutes. */

.slotpick { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 16px; }
/* In its own full-width card the picker needs no divider, and the day has
   room for hourly labels that do not collide. */
.slotpick-wide { margin-top: 0; border-top: 0; padding-top: 0; }
.slotpick-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.slotpick-title {
  font-size: 12.5px; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--slate);
}
.slotpick-lens { display: flex; gap: 4px; margin-left: auto; }
.slotpick-len {
  font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer;
  padding: 4px 10px; border-radius: 100px;
  border: 1px solid var(--line); background: #fff; color: var(--slate);
  transition: background .15s, border-color .15s, color .15s;
}
.slotpick-len:hover { border-color: #d6d0c2; color: var(--ink); }
.slotpick-len.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.slotpick-len .buf { opacity: .6; margin-left: 3px; font-weight: 500; }

.slotpick-days { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 12px; }
.slotpick-day {
  font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer;
  padding: 4px 10px; border-radius: 6px;
  border: 1px solid var(--line); background: #fff; color: var(--slate);
}
.slotpick-day:hover { border-color: #d6d0c2; }
.slotpick-day.on { background: var(--paper-2); border-color: var(--slate-2); color: var(--ink); }

.slotpick-ruler { position: relative; height: 16px; margin-left: 96px; }
.slotpick-tick {
  position: absolute; top: 0; transform: translateX(-50%);
  font-size: 10.5px; color: var(--slate-2); font-variant-numeric: tabular-nums;
}

.slotpick-row { display: flex; align-items: stretch; gap: 8px; margin-bottom: 5px; transition: opacity .2s; }
/* Halls other than the chosen one stay visible but recede — you can still see
   a clash forming next door without them competing for attention. */
.slotpick-row.dim { opacity: .4; }
.slotpick-row.dim:hover { opacity: .85; }

.slotpick-hall {
  flex: 0 0 88px; font-size: 12px; font-weight: 600; color: var(--ink);
  display: flex; align-items: center; gap: 5px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.slotpick-hall span {
  font-weight: 500; color: var(--slate-2); font-size: 10.5px;
  background: var(--paper-2); border-radius: 3px; padding: 0 4px;
}

.slotpick-lane {
  position: relative; flex: 1; height: 30px;
  background: repeating-linear-gradient(90deg, var(--paper-2) 0 1px, transparent 1px 100%);
  background-size: 8.3333% 100%;      /* a light hourly grid */
  border: 1px solid var(--line); border-radius: 5px; overflow: hidden;
}
.slotpick-busy {
  position: absolute; top: 0; bottom: 0;
  background: repeating-linear-gradient(45deg, #E8E2D6 0 5px, #DED7C8 5px 10px);
  color: var(--slate); font-size: 10.5px; line-height: 30px;
  padding: 0 5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  border-right: 1px solid #cfc7b6;
}
/* Blocked time is solid and crimson-tinted: unlike a session, nothing can be
   negotiated into it without going back to the Venues page. */
.slotpick-blocked {
  position: absolute; top: 0; bottom: 0;
  background: repeating-linear-gradient(45deg, #F0D9DD 0 5px, #E6C9CE 5px 10px);
  color: var(--crimson-dk); font-size: 10.5px; line-height: 30px; font-weight: 600;
  padding: 0 5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  border-right: 1px solid var(--crimson); border-left: 2px solid var(--crimson);
}

.slotpick-key {
  display: flex; gap: 16px; flex-wrap: wrap; margin-top: 12px;
  font-size: 12px; color: var(--slate-2);
}
.slotpick-key span { display: inline-flex; align-items: center; gap: 6px; }
.slotpick-key i { width: 18px; height: 12px; border-radius: 3px; display: inline-block; }
.slotpick-key .k-busy  { background: repeating-linear-gradient(45deg, #E8E2D6 0 4px, #DED7C8 4px 8px); }
.slotpick-key .k-block { background: repeating-linear-gradient(45deg, #F0D9DD 0 4px, #E6C9CE 4px 8px); border-left: 2px solid var(--crimson); }
.slotpick-key .k-free  { background: rgba(46, 116, 181, .18); border: 1px dashed var(--blue-500); }

.slotpick-free {
  position: absolute; top: 3px; bottom: 3px; padding: 0;
  border: 1px dashed var(--blue-500); border-radius: 4px;
  background: rgba(46, 116, 181, .10); cursor: pointer;
  transition: background .12s, border-color .12s;
}
.slotpick-free:hover { background: rgba(46, 116, 181, .26); border-style: solid; }
.slotpick-free.on {
  background: var(--crimson); border: 1px solid var(--crimson-dk);
}

@media (max-width: 820px) {
  .slotpick-hall { flex-basis: 62px; font-size: 11px; }
  .slotpick-ruler { margin-left: 70px; }
}

/* On a phone a whole day squeezed into 300px leaves 20-minute slots about ten
   pixels wide — visible but not tappable. Give the timeline a floor and let it
   scroll sideways instead, so every slot stays a real target. */
/* Below about 360px a 118px time column leaves the session itself under 150px.
   Put the time on its own line instead and give the content the full width. */
@media (max-width: 400px) {
  .slot { grid-template-columns: 1fr; gap: 2px; padding: 14px 0; }
  .slot-time { display: flex; align-items: baseline; gap: .5rem; padding-top: 0; }
  .slot-time .dur { display: inline; font-size: 12px; }
}

@media (max-width: 700px) {
  .slotpick-body {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
  }
  .slotpick-ruler,
  .slotpick-row { min-width: 620px; }
  .slotpick-body .slotpick-ruler { margin-left: 70px; }
}

/* --- Repeating sub-forms -------------------------------------------------- */

.rows { display: grid; gap: 12px; }
.row-item {
  display: grid; gap: 12px; align-items: start;
  padding: 16px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--paper);
}
.row-item .row-grid { display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end; }
.row-item .row-grid > * { flex: 1 1 170px; }
.row-item .row-grid > .shrink { flex: 0 0 auto; }
.row-item .field { margin-bottom: 0; }

/* ===========================================================================
   Project management
   Same language as everything above: crimson stays structural, status is
   carried by muted tints rather than saturated fills, and the letter badges
   are the one place a small block of colour is allowed to do the work.
=========================================================================== */

.wrap-wide { max-width: 1480px; }

/* --- RASCI letters -------------------------------------------------------- */

.rasci {
  display: inline-grid; place-items: center;
  width: 20px; height: 20px; border-radius: 4px;
  font-family: var(--sans); font-size: 11px; font-weight: 700;
  letter-spacing: 0; line-height: 1; cursor: default;
  vertical-align: -3px;
}
.rasci-A { background: #C8102E; color: #fff; }          /* the one that owns it */
.rasci-R { background: #1F4D78; color: #fff; }
.rasci-S { background: #cfe0ef; color: #14395c; }
.rasci-C { background: var(--paper-2); color: var(--slate); box-shadow: inset 0 0 0 1px var(--line); }
.rasci-I { background: transparent; color: var(--slate-2); box-shadow: inset 0 0 0 1px var(--line); }

.rasci-key {
  display: grid; gap: 6px; font-size: 13px; color: var(--slate);
  padding: 14px 16px; background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
.rasci-key strong { color: var(--ink); }

.load-cell { display: inline-flex; align-items: center; gap: 3px; margin-right: 10px; }
.load-cell .load-n { font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }

/* --- Status ---------------------------------------------------------------- */

.chip-not_started { background: var(--paper-2); color: var(--slate-2); }
.chip-in_progress { background: #eef3f8; color: var(--blue); }
.chip-blocked     { background: #fdf8ec; color: #7a5a12; }
.chip-done        { background: #f1f7f2; color: #22603c; }
.chip-overdue     { background: #fdf3f4; color: var(--crimson-dk); }

.badge-high     { background: #fdf8ec; color: #7a5a12; }
.badge-critical { background: #fdf3f4; color: var(--crimson-dk); }
.badge-low      { background: var(--paper-2); color: var(--slate-2); }

.overdue-text  { color: var(--crimson); font-weight: 600; }
.blocked-note  { color: #7a5a12; margin-top: .2rem; }
.field-bad     { border-color: var(--crimson) !important; background: #fdf3f4; }

.count-dot {
  display: inline-grid; place-items: center; min-width: 17px; height: 17px;
  padding: 0 4px; margin-left: 4px; border-radius: 100px;
  background: var(--crimson); color: #fff; font-size: 10.5px; font-weight: 700;
  vertical-align: 1px;
}

/* --- Progress bar --------------------------------------------------------- */

.pbar {
  display: block; height: 6px; border-radius: 100px;
  background: var(--paper-2); overflow: hidden; margin: 2px 0 3px;
}
.pbar > span { display: block; height: 100%; background: var(--blue); border-radius: 100px; }

/* --- Statistics row ------------------------------------------------------- */

.stat-row { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.stat {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 20px; box-shadow: var(--shadow);
}
.stat-n { font-family: var(--display); font-size: 2rem; font-weight: 600; line-height: 1; }
.stat-l {
  font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--slate-2); margin-top: 6px;
}
.stat-alert { border-color: #eccdd2; }
.stat-alert .stat-n { color: var(--crimson); }

.deflist { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; font-size: 14px; }
.deflist dt {
  font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--slate-2); align-self: center;
}
.deflist dd { margin: 0; }

/* --- Toolbar and segmented control ---------------------------------------- */

.toolbar { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.toolbar .grow { flex: 1; }
.seg {
  display: inline-flex; border: 1px solid var(--line); border-radius: 100px;
  background: #fff; padding: 3px; gap: 2px;
}
.seg a {
  padding: 6px 15px; border-radius: 100px; font-size: 13.5px; font-weight: 600;
  color: var(--slate); transition: background .2s, color .2s;
}
.seg a:hover { background: var(--paper-2); color: var(--ink); }
.seg a.on { background: var(--navy); color: #fff; }

/* --- RASCI matrix --------------------------------------------------------- */

table.matrix { min-width: 640px; }
table.matrix th, table.matrix td { padding: 8px 6px; }
.matrix-task { width: 300px; min-width: 240px; text-align: left; padding-left: 16px !important; }
.matrix-cell { text-align: center; width: 46px; border-left: 1px solid var(--line); }
.matrix-person {
  width: 46px; vertical-align: bottom; padding-bottom: 12px !important;
  border-left: 1px solid var(--line);
}
/* Vertical column heads: names stay readable however many people there are. */
.matrix-person span {
  writing-mode: vertical-rl; transform: rotate(180deg);
  white-space: nowrap; max-height: 190px; overflow: hidden;
  font-size: 11.5px; letter-spacing: .04em; text-transform: none; font-weight: 600;
  color: var(--ink);
}
tr.matrix-flag td.matrix-task { box-shadow: inset 3px 0 0 var(--crimson); }
table.matrix tfoot td { background: var(--paper-2); font-size: 13px; border-top: 1px solid var(--line); }

/* --- Gantt ---------------------------------------------------------------- */

.gantt-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.gantt { display: flex; min-width: 820px; }

.gantt-labels { flex: 0 0 260px; border-right: 1px solid var(--line); background: var(--paper); }
.gantt-corner {
  height: 34px; padding: 0 14px; display: flex; align-items: center;
  font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--slate-2); background: var(--paper-2); border-bottom: 1px solid var(--line);
}
.gantt-label {
  height: var(--row-h); padding: 0 14px; display: flex; flex-direction: column;
  justify-content: center; border-bottom: 1px solid var(--line); overflow: hidden;
}
.gantt-label a { font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gantt-who {
  font-size: 11px; color: var(--slate-2); white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; gap: 3px;
}
.gantt-who .rasci { width: 15px; height: 15px; font-size: 9px; vertical-align: 0; }

.gantt-chart { flex: 1; min-width: 480px; }
.gantt-axis {
  position: relative; height: 34px; background: var(--paper-2);
  border-bottom: 1px solid var(--line);
}
.gantt-tick {
  position: absolute; top: 0; height: 34px; display: flex; align-items: center;
  padding-left: 6px; font-size: 11px; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--slate-2); white-space: nowrap;
  border-left: 1px solid var(--line);
}
.gantt-body { position: relative; height: calc(var(--rows) * var(--row-h)); }
.gantt-grid { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--line); }
.gantt-today {
  position: absolute; top: 0; bottom: 0; width: 2px; background: var(--crimson);
  opacity: .75; z-index: 3;
}
.gantt-arrows { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; }
.gantt-arrows path { stroke-width: 1.2px; }
.dep-met   { stroke: #b9b2a4; }
.dep-unmet { stroke: var(--crimson); stroke-dasharray: 4 3; }

.gantt-row {
  position: absolute; left: 0; right: 0; height: var(--row-h);
  border-bottom: 1px solid var(--line); z-index: 2;
}
.gbar {
  position: absolute; top: 50%; transform: translateY(-50%);
  height: 18px; border-radius: 4px; display: block; overflow: hidden;
  background: #cfd6e2; box-shadow: inset 0 0 0 1px rgba(20, 26, 46, .18);
  transition: filter .15s;
}
.gbar:hover { filter: brightness(.94); }
.gbar-in_progress { background: #9db8d4; }
.gbar-done        { background: #bcd9c6; }
.gbar-blocked     { background: #eedcb4; }
.gbar-overdue     { background: #f0c3c9; box-shadow: inset 0 0 0 1px var(--crimson); }
.gbar-blocked.gbar-not_started { background: #eedcb4; }
/* A single-dated task is a diamond marker, not a bar — it has no duration. */
.gbar-point {
  height: 13px; border-radius: 2px; transform: translateY(-50%) rotate(45deg);
  min-width: 13px;
}
/* Progress darkens the bar's own colour rather than introducing a second one.
   A saturated fill reads as a different bar sitting on top of this one. */
.gbar-fill {
  display: block; height: 100%;
  background: rgba(20, 26, 46, .26);
  border-right: 1px solid rgba(20, 26, 46, .45);
}

.gantt-key { display: flex; gap: 18px; flex-wrap: wrap; font-size: 12.5px; color: var(--slate-2); }
.gantt-key span { display: inline-flex; align-items: center; gap: 6px; }
.gk-swatch { width: 16px; height: 10px; border-radius: 2px; display: inline-block; }
.gk-not_started { background: #cfd6e2; }
.gk-in_progress { background: #9db8d4; }
.gk-done        { background: #bcd9c6; }
.gk-overdue     { background: #f0c3c9; box-shadow: inset 0 0 0 1px var(--crimson); }
.gk-blockedkey  { background: #eedcb4; }
.gk-line { width: 16px; height: 0; border-top: 2px solid; display: inline-block; }
.gk-line-unmet { border-top-style: dashed; color: var(--crimson); }
.gk-line-today { color: var(--crimson); }

/* --- Month calendar ------------------------------------------------------- */

.cal-title { display: flex; align-items: baseline; gap: .8rem; margin-bottom: 12px; }
.cal-title h2 { margin: 0; }

table.cal { min-width: 860px; table-layout: fixed; }
table.cal th { text-align: center; }
td.cal-day {
  height: 116px; vertical-align: top; border-left: 1px solid var(--line);
  padding: 6px 7px;
}
td.cal-day:first-child { border-left: 0; }
.cal-out { background: var(--paper); }
.cal-out .cal-n { color: #c9c2b4; }
.cal-weekend { background: rgba(244, 241, 234, .5); }
.cal-today { box-shadow: inset 0 2px 0 var(--crimson); }
.cal-today .cal-n { color: var(--crimson); font-weight: 700; }
.cal-n { font-size: 12px; font-weight: 600; color: var(--slate-2); margin-bottom: 4px; }

.cal-item {
  display: block; border-left: 3px solid var(--blue); background: var(--paper-2);
  border-radius: 0 4px 4px 0; padding: 3px 6px; margin-bottom: 3px;
  font-size: 11.5px; line-height: 1.35;
}
.cal-item strong { display: block; font-weight: 600; }
.cal-item .cal-who { color: var(--slate-2); }
.cal-item:hover { background: #eef3f8; color: inherit; }
.cal-done { opacity: .55; border-left-color: #2e7d4f; }
.cal-blocked { border-left-color: #b8860b; }
.cal-overdue { border-left-color: var(--crimson); background: #fdf3f4; }

/* --- Waiting for the server ----------------------------------------------- */

/* Applied by app.js the moment something is going to navigate. */
body.is-busy,
body.is-busy a,
body.is-busy button { cursor: progress; }

/* The thing that was actually pressed recedes and stops accepting further
   clicks, which is what prevents the double submission. */
.is-busy.btn,
.is-busy.tile { opacity: .6; pointer-events: none; }
a.is-busy:not(.btn):not(.tile) { opacity: .55; }

.btn.is-busy::after {
  content: "";
  width: 12px; height: 12px; flex: none;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: gk-spin .6s linear infinite;
}

@keyframes gk-spin { to { transform: rotate(360deg); } }

/* A spinner is a nicety; motion sensitivity is not. Keep the dimming, which
   is what actually carries the message, and drop the rotation. */
@media (prefers-reduced-motion: reduce) {
  .btn.is-busy::after { animation: none; border-top-color: currentColor; opacity: .4; }
}

/* --- Escalations ---------------------------------------------------------- */

.esc-open .card-head { box-shadow: inset 3px 0 0 var(--crimson); }
.esc-acknowledged .card-head { box-shadow: inset 3px 0 0 #b8860b; }
.esc-resolved { opacity: .72; }

/* --- Phones --------------------------------------------------------------- */

@media (max-width: 760px) {
  .wrap { padding: 22px 14px 60px; }

  /* Two rows of tabs plus the project name is a quarter of a phone screen.
     Sticky, that quarter is gone on every scroll; static, it scrolls away and
     comes back with a flick to the top. */
  .bar { position: static; }

  /* A data table cannot be made narrow without becoming unreadable, so let it
     keep its width and scroll inside its own card. Squeezing it instead turns
     every cell into a column of single words. */
  .card { overflow-x: auto; }
  .card > table { min-width: 620px; }
  .card > .card-head,
  .card > .card-body { position: sticky; left: 0; }

  /* The lists people actually work from become one block per record instead
     of a table to be dragged sideways. The column head moves into each cell
     as a small label, so a stacked row still says which name is Responsible
     and which is Accountable. */
  .card > table.stacked { min-width: 0; }
  table.stacked thead { display: none; }
  table.stacked tbody,
  table.stacked tr,
  table.stacked td { display: block; width: auto; }
  table.stacked tr { padding: 14px 16px; border-bottom: 1px solid var(--line); }
  table.stacked tr:last-child { border-bottom: 0; }
  table.stacked tbody tr:hover { background: none; }
  table.stacked td { border: 0; padding: 3px 0; text-align: left; }
  table.stacked td:empty { display: none; }
  table.stacked td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: 10px; font-weight: 700; letter-spacing: .11em;
    text-transform: uppercase; color: var(--slate-2);
  }
  table.stacked td.actions { padding-top: 10px; white-space: normal; }
  table.stacked td.actions .btn { margin-right: .35rem; }

  th, td { padding: 9px 12px; }

  h1 { font-size: 1.6rem; }
  .page-head { margin-bottom: 20px; gap: .6rem; }
  .page-head .btn-row { width: 100%; }

  /* Full-width controls beat a row of half-tapped buttons. */
  .btn { padding: 10px 16px; }
  .page-head .btn-row .btn { flex: 1 1 auto; justify-content: center; }

  .stat-row { grid-template-columns: repeat(auto-fit, minmax(104px, 1fr)); gap: 10px; }
  .stat { padding: 14px; }
  .stat-n { font-size: 1.5rem; }

  .field-row { gap: 10px; }
  .row-item { padding: 12px; }

  .toolbar { gap: .5rem; }
  .seg { width: 100%; }
  .seg a { flex: 1; text-align: center; }

  .deflist { grid-template-columns: 1fr; gap: 2px 0; }
  .deflist dd { margin-bottom: 8px; }

  /* The wide views already scroll; just stop them fighting the page. */
  .gantt-labels { flex-basis: 150px; }
  .matrix-task { min-width: 170px; }
  /* Rotated column heads are 190px tall by default, which on a phone is a
     screenful of nothing above the first row. */
  .matrix-person span { max-height: 110px; font-size: 10.5px; }
  td.cal-day { height: 84px; }
  .cal-item { font-size: 10.5px; }
}

/* --- Print ---------------------------------------------------------------- */

@media print {
  body { background: #fff; font-size: 10.5pt; color: #14171F; }
  .bar, .site-foot, .no-print, .btn, form.inline-form, .hero { display: none !important; }
  .wrap { max-width: none; padding: 0; }
  .card { border: 0; box-shadow: none; }
  .card-head { border-bottom: 1px solid #ccc; padding: 0 0 6pt; }
  .card-body { padding: 0; }
  a { color: inherit; text-decoration: none; }

  .print-head { display: block !important; margin-bottom: 16pt; }
  .print-head .event-logo { height: 46px; margin-bottom: 8pt; }

  .day-head { break-after: avoid; page-break-after: avoid; }
  .slot, .card, .person { break-inside: avoid; page-break-inside: avoid; }
  .page-break { break-before: page; page-break-before: always; }

  /* Track colours must survive the printer driver. */
  .chip, .grid-item { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .chip { border: 1px solid #bbb; }

  /* Photographs are <img> content, so they print even when "background
     graphics" is off — but they must not be split across a page break, and a
     line-up should not be orphaned from its session. */
  .person-photo {
    -webkit-print-color-adjust: exact; print-color-adjust: exact;
    width: 26pt; height: 26pt;
  }
  .people, .person { break-inside: avoid; page-break-inside: avoid; }

  /* --- Project management ------------------------------------------------ */

  .stat-row, .toolbar, .seg, .rasci-key { display: none !important; }

  /* The matrix and the Gantt are landscape deliverables, and both are meant
     to come off the printer on one page. */
  .grid-scroll, .gantt-scroll { overflow: visible !important; border: 0; }
  table.matrix, table.cal, .gantt { min-width: 0 !important; width: 100% !important; }

  .rasci, .pbar > span, .gbar, .gk-swatch, .cal-item {
    -webkit-print-color-adjust: exact; print-color-adjust: exact;
  }
  .rasci { border: 1px solid #999; }

  table.matrix { font-size: 8.5pt; }
  table.matrix th, table.matrix td { padding: 4pt 3pt; }
  .matrix-task { width: auto; min-width: 0; }
  .matrix-person span { max-height: 130px; font-size: 8pt; }

  .gantt-label a { font-size: 8.5pt; }
  .gantt-who { font-size: 7.5pt; }
  .gantt-labels { flex-basis: 190px; }

  td.cal-day { height: 84px; }
  .cal-item { font-size: 7.5pt; }

  .card, .gantt-row, .esc { break-inside: avoid; page-break-inside: avoid; }
}


.print-head { display: none; }

@page { margin: 16mm 14mm; }
