/* Faculty review pages. Denser than the learner interface on purpose: the
 * job here is scanning and comparing, not reading one message at a time.
 */

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

body[data-screen="review"] .screen { display: block; }

/* Just the breadcrumb now: the account controls and the Admin link moved to
 * the shared brand bar, which is where they belong once every page has one.
 * Kept as its own bar rather than folded into the page heading because it is
 * a trail, and it is the one piece of chrome specific to this section. */
.topbar {
  display: flex; align-items: center; gap: 1rem;
  font-size: .875rem; margin-bottom: 2rem;
  padding-bottom: .75rem; border-bottom: 1px solid var(--line);
}
/* A button that reads as a link: the sign-out has to be a POST from Django 5
   on, so it cannot be an <a>. */
.card button.linkish {
  background: none; border: 0; padding: 0;
  font: inherit; color: var(--accent);
  text-decoration: underline; cursor: pointer;
}

.breadcrumb ol {
  display: flex; align-items: center; gap: .5rem; flex-wrap: wrap;
  list-style: none; margin: 0; padding: 0;
}
.breadcrumb li { margin: 0; }
.breadcrumb a { color: var(--accent); }
.breadcrumb .sep { color: var(--ink-meta); }

h2.section {
  /* Was .78rem in --ink-faint: uppercase and tracked-out at that size is the
   * hardest text on the page to read, so it gets both more size and more
   * contrast. */
  font-family: var(--font-mono); font-weight: 500;
  font-size: .8rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-meta); margin: 2.5rem 0 .85rem;
  padding-bottom: .4rem; border-bottom: 1px solid var(--line);
}

/* Wide content scrolls inside its own box rather than the page. The box is
 * also the card: a table's own border-radius does nothing under
 * border-collapse, so the rounding lives on the wrapper and the table sits
 * flush inside it.
 *
 * position: relative keeps the table's sr-only text inside the box -- see
 * .sr-only in style.css; without it one "none" in the last column made the
 * list page 978px wide at 320px. The templates give each box a tab stop and
 * a name, because on a narrow window it scrolls and most of its tables hold
 * nothing focusable to scroll it with. */
.table-wrap {
  position: relative;
  overflow-x: auto; margin-bottom: 1rem;
  background: var(--card);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
}
.table-wrap:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

table.grid {
  width: 100%; border-collapse: collapse;
  font-size: .9rem; background: var(--card);
}
table.grid th {
  text-align: left;
  font-family: var(--font-mono); font-weight: 500;
  font-size: .7rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--ink-meta);
  padding: .8rem .9rem; border-bottom: 1px solid var(--line); white-space: nowrap;
}
table.grid thead th { background: var(--panel); }
table.grid th:first-child, table.grid td:first-child { padding-left: 1.4rem; }
table.grid th:last-child, table.grid td:last-child { padding-right: 1.4rem; }
/* Row headers are content, not column labels: they keep the body type. */
table.grid th[scope="row"] {
  font-family: var(--font-body); letter-spacing: normal;
  text-transform: none; font-size: inherit; color: inherit;
  font-weight: 600; white-space: normal; vertical-align: top;
}
table.grid td { padding: .8rem .9rem; border-bottom: 1px solid var(--line); vertical-align: top; }
table.grid tr:last-child td,
table.grid tr:last-child th[scope="row"] { border-bottom: 0; }
table.grid tbody tr:hover td,
table.grid tbody tr:hover th[scope="row"] { background: var(--panel); }
/* Dimming by opacity dragged this row's text under the contrast floor. Tint
 * the cell instead and keep the type at a colour that passes. */
table.grid tr.dim td,
table.grid tr.dim th[scope="row"] {
  background: color-mix(in srgb, var(--line) 35%, transparent);
}
table.grid tr.dim td,
table.grid tr.dim th[scope="row"],
table.grid tr.dim td .muted { color: var(--ink-soft); }
table.grid td.num { white-space: nowrap; }
table.grid a { color: var(--accent); font-weight: 600; }

.mono { font-family: var(--font-mono); font-size: .82em; }

/* The tier as a chip, so a column of them can be scanned by shape and weight
 * rather than read word by word. The three differ in lightness -- solid
 * accent, pale tint, outline -- not just in hue, and each still says its
 * tier in words. Measured: 12.36:1 on the tint, 8.41:1 for the outline's red
 * ink on --card (9.83:1 and 7.47:1 in dark mode). */
.tier {
  display: inline-block;
  padding: .2rem .7rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: .8rem; font-weight: 600; line-height: 1.5;
  white-space: nowrap;
}
.tier-high-performance { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.tier-developing-performance { background: #e8edf5; border-color: #c8d3e4; color: #00275c; }
.tier-needs-improvement { background: var(--card); border-color: #d9a69f; color: #8a2e25; }
/* No tier yet: the session is still in its views, or its evaluation. The
 * phase is printed as it is stored, dashed round to say "not a result". */
.tier-open {
  background: none; border: 1px dashed var(--line-control);
  color: var(--ink-soft); font-weight: 500;
  font-family: var(--font-mono); font-size: .75rem;
}
@media (prefers-color-scheme: dark) {
  .tier-developing-performance { background: #1e2a3d; border-color: #33445f; color: #c9d6ea; }
  .tier-needs-improvement { border-color: #6b3a33; color: #e2a094; }
}

/* The row's lens, with the same facts in words under it -- see the comment
 * in list.html. On the card's white, so its gaps are cut in card colour. */
.lens-cell { min-width: 9rem; }
/* Darker empty sides at this size, for the reason given at .lens-glyph in
 * style.css: pale blanks round one lit side read as a loading spinner. */
.lens-mini { width: 2.25rem; height: 2.25rem; margin-bottom: .35rem; }
.lens-mini polygon { stroke: var(--card); stroke-width: 8; }
.lens-mini polygon[data-state="upcoming"] { fill: #d6d1c4; }
@media (prefers-color-scheme: dark) {
  .lens-mini polygon[data-state="upcoming"] { fill: #3a414a; }
}
table.grid tbody tr:hover .lens-mini polygon { stroke: var(--panel); }
.lens-note { display: block; font-size: .78rem; line-height: 1.4; color: var(--ink-soft); }
.yes { color: #2f6b46; font-weight: 600; }
.no  { color: var(--danger); font-weight: 600; }
@media (prefers-color-scheme: dark) { .yes { color: #7fc79c; } }

.tag {
  display: inline-block; margin: 0 .25rem .2rem 0;
  padding: .1rem .4rem; border-radius: 5px;
  font-size: .72rem; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: var(--learner-bg); color: var(--ink-soft);
}
.tag.ok   { background: #dcece1; color: #2f6b46; }
.tag.warn { background: #f4ded9; color: #8d3227; }
@media (prefers-color-scheme: dark) {
  .tag.ok   { background: #23392d; color: #8fd0a8; }
  .tag.warn { background: #3d2723; color: #e2a094; }
}

/* What was withheld used to live in a title attribute -- invisible to touch,
 * to keyboards, and to most screen readers. It is plain text now. */
.withheld-text {
  display: block; font-size: .85rem; color: var(--ink-meta);
  max-width: 34ch; margin-bottom: .4rem;
}

.review-transcript { display: flex; flex-direction: column; gap: .85rem; }
.review-transcript .turn { max-width: none; }
.review-transcript p { max-width: 68ch; }
.review-transcript .turn.learner { align-self: stretch; }

ul.credits {
  list-style: none; margin: .7rem 0 0; padding: .7rem 0 0;
  border-top: 1px dashed var(--line); font-size: .85rem;
}
ul.credits li { margin-bottom: .3rem; }

.card.pre { white-space: pre-wrap; }

dl.answers { margin: 0; }
dl.answers dt {
  font-size: .8rem; letter-spacing: .01em;
  color: var(--ink-meta); font-weight: 600; margin-top: 1rem;
  max-width: var(--measure);
}
dl.answers dt:first-child { margin-top: 0; }
dl.answers dd { margin: .2rem 0 0; max-width: var(--measure); }

/* The review list's pager: previous and next around a page count. */
.pager {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin: 1rem 0 0;
  font-size: 0.95rem;
}
