/* The Executive Report print sheet.
 *
 * A facsimile of the firm's own weekly export ("FIRMWIDE Totals.pdf"), which is
 * an Excel print of a 17x11in landscape page. The four fills below are sampled
 * from that PDF, not chosen: black scope bands, #FFFF66 on the two human-entered
 * rows, #BFBFBF on the column headers, #CCFFFF banding on the money rows. The
 * house muted-earth palette deliberately does not apply here — the whole point
 * of the page is that leadership cannot tell it from the sheet they have been
 * reading for years.
 *
 * Loaded ONLY by the exec_print layout; nothing else on the site links it.
 */

:root {
  color-scheme: light;
}

/* print-color-adjust is inherited, so setting it once at the root carries the
 * fills into the printed page. Without it Chrome drops every background and the
 * sheet prints as a bare grid — the single highest-impact rule in this file. */
html {
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}

html,
body.exec-print {
  margin: 0;
  padding: 0;
  background: #f4f4f2;
  color: #111;
  font-family: Calibri, Carlito, "Segoe UI", Arial, Helvetica, sans-serif;
}

/* ── Screen chrome (never printed) ──────────────────────────────────────────── */

/* A custom element has no default display, so an unstyled turbo-frame is inline
   and the toolbar and sheet inside it lose their block layout. */
turbo-frame {
  display: block;
}

.exec-print-toolbar {
  position: sticky;
  top: 0;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.5rem;
  background: #fff;
  border-bottom: 1px solid #dcdad4;
  font-size: 0.875rem;
}

.exec-print-zone {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.exec-print-zone.is-centre {
  justify-content: center;
}

.exec-print-zone.is-end {
  justify-content: flex-end;
}

.exec-print-zone select {
  padding: 0.35rem 0.5rem;
  border: 1px solid #dcdad4;
  border-radius: 6px;
  background: #fff;
  color: #1c1c1a;
  font: inherit;
  font-weight: 600;
}

.exec-print-button {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  border: 1px solid transparent;
  border-radius: 6px;
  background: #2f2f2c;
  color: #fff;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.exec-print-button:hover {
  background: #46463f;
}

/* Secondary weight for Close: one filled button per toolbar, so the action that
   reads as primary is the one you came here to take. */
.exec-print-button.is-quiet {
  border-color: #dcdad4;
  background: #fff;
  color: #57564f;
}

.exec-print-button.is-quiet:hover {
  background: #f4f2ed;
  color: #1c1c1a;
}

/* The sheet does not load Tailwind, so the glyph has no size utility to take. */
.exec-print-glyph {
  width: 1rem;
  height: 1rem;
}

/* ── The sheet ──────────────────────────────────────────────────────────────── */

.exec-sheet {
  padding: 1.5rem;
  overflow-x: auto;
}

.exec-sheet table {
  width: 100%;
  min-width: 1180px;
  background: #fff;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 9px;
}

/* The label column carries the longest string on the page ("PLACEMAKING +
 * MIXED USE"); the workbook gives it a sixth of the width and the twelve months
 * split what is left evenly, which table-layout: fixed does for us. */
.exec-sheet col.col-key {
  width: 15.5%;
}

.exec-sheet col.col-total {
  width: 6.9%;
}

.exec-sheet th,
.exec-sheet td {
  padding: 3px 4px;
  border: 1px solid #000;
  overflow: hidden;
  font-weight: 400;
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

.exec-sheet .key,
.exec-sheet .total {
  font-weight: 700;
}

/* Row labels wrap rather than clip. On the 17x11in page they never need to; on
 * Letter "FTE Capacity" is wider than the Total Fee column it sits in (the
 * workbook prints the baseline labels there, not in the label column) and a
 * clipped "FTE Capacit" is the one thing a reader would notice. */
.exec-sheet td.key {
  white-space: normal;
}

.exec-sheet tr.is-head th {
  background: #bfbfbf;
  font-weight: 700;
}

.exec-sheet tr.is-head td.corner {
  background: #fff;
}

.exec-sheet tr.is-baseline td {
  background: #ffff66;
  font-weight: 700;
}

/* The scope band runs THROUGH the baseline rows (it is one black cell spanning
 * them), so it has to out-specify the row's own fill — a td.scope selector alone
 * loses to tr.is-baseline td and the band prints yellow with invisible white
 * text on it. */
.exec-sheet tr.is-baseline td.scope {
  background: #000;
}

.exec-sheet tr.is-band td {
  background: #ccffff;
}

.exec-sheet td.scope {
  position: relative;
  background: #000;
  color: #fff;
  font-size: 1.2em;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  /* The one cell allowed to wrap. On the 17x11in page the longest studio name
   * fits on a line; on Letter it does not, and a wrapped name beats a clipped
   * one. Every other cell stays nowrap so the grid keeps its rhythm. */
  overflow: visible;
  white-space: normal;
}

/* Out of flow so it cannot widen the label column, and pinned to the corner the
 * workbook prints it in. */
.exec-sheet td.scope .count {
  position: absolute;
  top: 1px;
  right: 4px;
  font-size: 0.62em;
  font-weight: 700;
  letter-spacing: 0;
}

/* ── Print ──────────────────────────────────────────────────────────────────── */

/* Tabloid landscape — the source workbook's own page. Letter landscape also
 * works (the grid is proportional); it just prints denser. */
@page {
  size: 17in 11in;
  margin: 0.75in 0.7in;
}

@media print {
  html,
  body.exec-print {
    background: #fff;
  }

  .exec-print-toolbar {
    display: none;
  }

  .exec-sheet {
    padding: 0;
    overflow: visible;
  }

  /* 8pt with the 3px cell padding puts a row at ~0.22in, which is the source
   * workbook's own row pitch — 44 rows then fill the 17x11in page the way the
   * firm's export does instead of ending two inches short. */
  .exec-sheet table {
    min-width: 0;
    font-size: 8pt;
  }

  /* A scope block is the unit a reader carries in their head, so it never
   * straddles a page. tbody is the block; the row rule is belt-and-braces for
   * engines that ignore break-inside on row groups. */
  .exec-sheet tbody,
  .exec-sheet tr {
    break-inside: avoid;
    page-break-inside: avoid;
  }
}

/* ── The weekly email's PDF (.is-pdf) ───────────────────────────────────────── */

/* Joanna's own FIRMWIDE Totals.pdf, measured off her 2026-09-11 export: Excel
 * shrinks the sheet to fit one 17x11in page, so these are her printed sizes, in
 * points — a 16pt row pitch, a 29pt header band, Arial Bold labels over Calibri
 * figures. The attachment matches her PDF exactly (Dalton, 2026-10-02); the
 * screen sheet keeps the rules above.
 *
 * ⚠ ONE PAGE HAS ABOUT 6PT TO SPARE with all seven studios, so the row height
 * is load-bearing. */

.exec-sheet.is-pdf {
  padding: 0;
}

.exec-sheet.is-pdf table {
  min-width: 0;
  font-family: Calibri, Carlito, "Segoe UI", Arial, Helvetica, sans-serif;
  font-size: 5.95pt;
}

.exec-sheet.is-pdf col.col-key {
  width: 15.4%;
}

.exec-sheet.is-pdf col.col-total {
  width: 6.43%;
}

/* Her rules are 0.3pt hairlines and her outline 0.5pt. ⚠ THEY ARE PAINTED AS
 * INSET SHADOWS, NOT BORDERS: Chrome rounds a border up to a whole pixel
 * (0.75pt), and a shadow it paints at the size given. Each cell draws its own
 * right and bottom rule; the outline cells add their left or top. */
.exec-sheet.is-pdf th,
.exec-sheet.is-pdf td {
  --rule-right: 0.3pt;
  --rule-bottom: 0.3pt;
  --rule-left: 0pt;
  --rule-top: 0pt;
  height: 15.95pt;
  padding: 0 1.5pt;
  border: none;
  box-shadow:
    inset calc(-1 * var(--rule-right)) 0 0 #000,
    inset 0 calc(-1 * var(--rule-bottom)) 0 #000,
    inset var(--rule-left) 0 0 #000,
    inset 0 var(--rule-top) 0 #000;
  line-height: 1;
}

/* A baseline row under a rowspanned scope cell starts at the Total Fee column. */
.exec-sheet.is-pdf tr:not(.is-baseline) > :first-child,
.exec-sheet.is-pdf td.scope {
  --rule-left: 0.5pt;
}

.exec-sheet.is-pdf tr > :last-child {
  --rule-right: 0.5pt;
}

.exec-sheet.is-pdf tbody[data-block="Firmwide"] tr.is-head > * {
  --rule-top: 0.5pt;
}

.exec-sheet.is-pdf tbody:last-child tr:last-child > * {
  --rule-bottom: 0.5pt;
}

.exec-sheet.is-pdf th,
.exec-sheet.is-pdf td.key,
.exec-sheet.is-pdf td.scope {
  font-family: Arial, "Liberation Sans", Arimo, Helvetica, sans-serif;
  font-weight: 700;
}

.exec-sheet.is-pdf th,
.exec-sheet.is-pdf tr.is-baseline td.key {
  font-size: 6.1pt;
}

.exec-sheet.is-pdf td.key {
  font-size: 7.9pt;
}

.exec-sheet.is-pdf td.scope {
  font-size: 9.25pt;
  letter-spacing: 0;
}

/* Her headcount sits mid-row at the right of the black cell, in the figures' face. */
.exec-sheet.is-pdf td.scope .count {
  top: 50%;
  right: 1.5pt;
  transform: translateY(-50%);
  font-family: Calibri, Carlito, "Segoe UI", Arial, Helvetica, sans-serif;
  font-size: 5.95pt;
}

/* Bold where she is bold: every Total Fee, the Signed rows, and the firm's two
 * rulers. A studio's FTE Capacity, Potential and the combined rows are regular. */
.exec-sheet.is-pdf tr.is-baseline td {
  font-weight: 400;
}

.exec-sheet.is-pdf tbody[data-block="Firmwide"] tr.is-baseline td,
.exec-sheet.is-pdf tr.is-baseline td.key,
.exec-sheet.is-pdf tr[data-row="Total Signed"] td,
.exec-sheet.is-pdf tr[data-row="Signed"] td,
.exec-sheet.is-pdf td.total {
  font-weight: 700;
}

/* The header: Total Fee on white beside the gray months, and the firm's header a
 * tall band. */
.exec-sheet.is-pdf tr.is-head th.total {
  background: #fff;
}

.exec-sheet.is-pdf tbody[data-block="Firmwide"] tr.is-head > * {
  height: 29pt;
}

.exec-sheet.is-pdf tr.is-count td {
  height: 10pt;
  box-shadow: none;
  background: none;
  vertical-align: bottom;
  font-weight: 700;
}

.exec-sheet.is-pdf td.count-billable {
  text-align: right;
}

.exec-sheet.is-pdf td.count-billable,
.exec-sheet.is-pdf td.count-total {
  color: #f00;
}
