/* AME Desk. One design system for every screen: 16px text, 44px touch targets, one filled main button per view,
   status always a word plus a color. No inline styles anywhere (the Content Security Policy forbids them).
   Type (approved in the 12/01 design review, after Tebra's plain dashboard type): Arial, 16px body at 1.4, regular-weight
   labels, bold only for headings, pilot names and the main action; tabular numbers for counts and dates. */

:root {
  --font: Arial, "Helvetica Neue", Helvetica, sans-serif;
  --bg: #F1F3F6; --surface: #FFFFFF; --rail: #0E2A47; --rail-2: #16395E;
  --ink: #23272E; --ink-2: #4D5562; --ink-3: #5F6773;
  --line: #E3E6EB; --card: #D3D9E0; --input: #858F9C;
  --primary: #2D5E99; --primary-hover: #224A79; --sky: #8DBBE8;
  --late: #B42318; --late-bg: #FDF0EF; --late-line: #F2C4BF;
  --soon: #95580A; --soon-bg: #FFF6E6; --soon-line: #EDCF9C;
  --ok: #1E6B45; --ok-bg: #EAF5EE; --ok-line: #BFDFCB;
  --none: #4D5562; --none-bg: #EEF1F4;
  --new: #23466F; --new-bg: #E6EEF8;
  --radius: 8px; --shadow: 0 1px 2px rgba(20, 30, 45, .05);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { font: 16px/1.4 var(--font); color: var(--ink); background: var(--bg); font-variant-numeric: tabular-nums; letter-spacing: normal; }
h1, h2, h3, h4 { margin: 0; line-height: 1.25; }
h1 { font-size: 26px; font-weight: 700; }
h2 { font-size: 17px; font-weight: 700; }
h3 { font-size: 16px; font-weight: 700; }
b, strong { font-weight: 700; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
p { margin: 0; }
a { color: var(--primary); }
.muted { color: var(--ink-2); }
.small { font-size: 14px; }
@media (max-width: 760px) { .small { font-size: 15px; } }
.nowrap { white-space: nowrap; }
.hidden, [hidden] { display: none !important; }
:focus-visible { outline: none; box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--primary); border-radius: 6px; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 8px;
  border: 1px solid #B9C1CC; background: var(--surface); color: var(--ink); font: 400 16px/1.2 var(--font); cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { background: #F5F7F9; border-color: #98A3B0; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 700; }
.btn.primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn.danger { color: var(--late); border-color: #E3B4AE; }
.btn.danger.solid { background: var(--late); border-color: var(--late); color: #fff; }
.btn.compact { min-height: 38px; padding: 0 14px; font-size: 15px; }
.btn:disabled, .btn[aria-disabled="true"] { background: #EEF2F6; border-color: #EEF2F6; color: #8A99A8; cursor: not-allowed; }
.link { background: none; border: 0; padding: 6px 2px; color: var(--primary); font: 400 16px var(--font); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; min-height: 36px; }
.link.quiet { color: var(--ink-2); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* ---------- Status chips: a word plus a color ---------- */
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px; border-radius: 6px; font: 400 14px/1.4 var(--font); white-space: nowrap; border: 1px solid transparent; }
.chip.late { color: var(--late); background: var(--late-bg); border-color: var(--late-line); }
.chip.soon, .chip.nodate { color: var(--soon); background: var(--soon-bg); border-color: var(--soon-line); }
.chip.ok, .chip.in { color: var(--ok); background: var(--ok-bg); border-color: var(--ok-line); }
.chip.setup, .chip.none { color: var(--none); background: var(--none-bg); border-color: var(--card); }
.chip.new { color: var(--new); background: var(--new-bg); }
.tag { display: inline-block; padding: 1px 7px; border-radius: 5px; font: 400 13px/1.6 var(--font); background: #E9EDF2; color: #2E3A48; }

/* ---------- Sign-in ---------- */
.signin { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.signin .card { width: min(440px, 100%); background: var(--surface); border: 1px solid var(--card); border-radius: 16px; box-shadow: var(--shadow); padding: 36px 32px 28px; }
.signin .wordmark img { width: 210px; height: auto; display: block; }
.signin .tagline { color: var(--ink-2); margin: 10px 0 26px; font-size: 17px; }
.signin form { display: grid; gap: 14px; }
.signin .btn { width: 100%; min-height: 48px; font-size: 17px; }
.signin .help { margin-top: 22px; color: var(--ink-2); font-size: 15px; text-align: center; }
.signin .code { font-size: 28px; letter-spacing: .3em; text-align: center; }
.demo-sender-note { max-width: 540px; margin: 0 auto 14px; background: #FFF4D6; border: 1px solid #F3D19E; color: #6B4A00; border-radius: 8px; padding: 8px 12px; font-size: 14px; }
.local-flag { background: #FFF4D6; border: 1px solid #F3D19E; color: #6B4A00; border-radius: 8px; padding: 8px 12px; font-size: 14px; margin-bottom: 16px; }

/* ---------- Fields ---------- */
.field { display: grid; gap: 6px; align-content: start; }
.field > label, .field > .label { font: 400 15px/1.3 var(--font); color: var(--ink); }
.field .hint { font-size: 14px; color: var(--ink-2); }
input[type=text], input[type=email], input[type=date], input[type=number], input[type=tel], input:not([type]), select, textarea { min-width: 0;
  font: 16px/1.3 var(--font); color: var(--ink); background: #fff; border: 1px solid var(--input); border-radius: 8px; min-height: 44px; padding: 8px 12px; width: 100%; }
textarea { min-height: 140px; }
input[type=checkbox], input[type=radio] { width: 20px; height: 20px; accent-color: var(--primary); margin: 0; flex: none; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.choice { display: flex; gap: 12px; align-items: flex-start; border: 1px solid var(--card); border-radius: 8px; padding: 14px 16px; cursor: pointer; background: #fff; }
.choice:hover { border-color: #A9B8C8; }
.choice:has(input:checked) { border-color: var(--primary); box-shadow: 0 0 0 1px var(--primary); background: #F5F9FE; }
.choice b { display: block; }
.choice > span { display: grid; gap: 2px; }
.choices { display: grid; gap: 10px; }
.choices.row { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); align-items: stretch; }
.choices.row > .choice { align-self: stretch; margin: 0; }
.error { color: var(--late); background: var(--late-bg); border: 1px solid var(--late-line); border-radius: 8px; padding: 10px 14px; }
.okbox { color: var(--ok); background: var(--ok-bg); border: 1px solid var(--ok-line); border-radius: 8px; padding: 10px 14px; }

/* ---------- Shell ---------- */
.shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; }
.work { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; gap: 16px; min-height: 48px; padding: 0 32px; background: var(--surface); border-bottom: 1px solid var(--line); }
.topbar .practice { font-size: 15px; font-weight: 700; color: var(--ink); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-who { margin-left: auto; font-size: 14px; color: var(--ink-2); white-space: nowrap; }
.topbar-logo, .menu-btn { display: none; }
.rail { background: var(--rail); color: #fff; display: flex; flex-direction: column; padding: 22px 14px; gap: 22px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.rail .logo img { display: block; width: 170px; height: auto; margin: 0 8px; }
.nav { display: grid; gap: 4px; }
.nav a { display: flex; align-items: center; gap: 12px; min-height: 46px; padding: 0 14px; border-radius: 6px; color: #E9EEF4; text-decoration: none; font: 400 16px var(--font); border-left: 3px solid transparent; }
.nav a:hover { background: rgba(255, 255, 255, .08); }
.nav a[aria-current="page"] { background: rgba(255, 255, 255, .14); border-left-color: var(--sky); color: #fff; font-weight: 700; }
.nav .ico { width: 20px; height: 20px; flex: none; opacity: .9; }
.nav .lbl { flex: 1; }
.nav .count { background: #fff; color: var(--rail); border-radius: 999px; padding: 0 8px; font: 700 13px/22px var(--font); min-width: 24px; text-align: center; }
.nav .count.alert { background: #FECACA; color: #7F1D1D; }
.rail .me { margin-top: auto; border-top: 1px solid rgba(255, 255, 255, .15); padding: 16px 8px 0; display: grid; gap: 6px; font-size: 15px; }
.rail .me b { font-size: 16px; }
.rail .me span { color: #C9D6E4; }
.rail .me button { justify-self: start; background: none; border: 0; color: #fff; font: 400 15px var(--font); padding: 10px 0; min-height: 44px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.rail .me button:hover { text-decoration: underline; }
.rail .help { font-size: 14px; color: #C9D6E4; padding: 0 8px; }
.rail .help a { color: #fff; }
.main { padding: 26px 32px 80px; min-width: 0; max-width: 1280px; width: 100%; }

/* ---------- Page header ---------- */
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 24px; flex-wrap: wrap; }
.page-head .sub { color: var(--ink-2); margin-top: 4px; font-size: 16px; }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--primary); text-decoration: none; font: 400 16px var(--font); margin-bottom: 12px; min-height: 40px; }
.back:hover { text-decoration: underline; }
.summary-line { margin-top: 10px; font-size: 17px; font-weight: 700; }
.summary-line.late { color: var(--late); }
.meta { color: var(--ink-2); margin-top: 6px; display: flex; gap: 6px 14px; flex-wrap: wrap; align-items: center; font-size: 16px; }

/* ---------- Cards and sections ---------- */
.card { background: var(--surface); border: 1px solid var(--card); border-radius: 8px; box-shadow: var(--shadow); }
.section { margin-bottom: 26px; }
.section > h2, .section > .section-head { margin-bottom: 12px; }
.section-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.pad { padding: 20px 24px; }
.empty { padding: 26px 24px; color: var(--ink-2); }
.empty.big { text-align: center; padding: 48px 24px; }
.empty.big h3 { color: var(--ink); margin-bottom: 8px; }
.empty.big .actions { justify-content: center; margin-top: 18px; }
.oneline { padding: 14px 20px; color: var(--ink-2); }

/* ---------- Rows (lists of pilots, items, papers) ---------- */
.rows { list-style: none; margin: 0; padding: 0; }
.rows > li { border-top: 1px solid var(--line); }
.rows > li:first-child { border-top: 0; }
.row { display: grid; gap: 4px 16px; align-items: center; padding: 14px 20px; min-height: 64px; }
a.row, button.row { color: inherit; text-decoration: none; width: 100%; text-align: left; background: none; border: 0; font: inherit; cursor: pointer; }
a.row:hover, button.row:hover { background: #F7FAFD; }
.row .name { font-weight: 700; font-size: 16px; }
.row .what { color: var(--ink); }
.row .what.late { color: var(--late); font-weight: 700; }
.row .side { justify-self: end; display: flex; gap: 10px; align-items: center; }
.pilot-row { grid-template-columns: minmax(200px, 1.3fr) 150px minmax(200px, 1.6fr) minmax(180px, 1.3fr) 24px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.row .chip, .row .tag { justify-self: start; }
.typecell { display: grid; gap: 2px; justify-items: start; }
.pilot-row .chev { color: #8A99A8; font-size: 22px; justify-self: end; }
.rows-head { display: grid; padding: 9px 20px; font: 400 14px var(--font); color: var(--ink-2); background: #F7F8FA; border-bottom: 1px solid var(--line); border-radius: 8px 8px 0 0; }
.rows-head.pilot-row { min-height: 0; }
.group-title { display: flex; align-items: center; gap: 10px; margin: 24px 0 10px; font-size: 17px; }
.group-title .n { color: var(--ink-2); font-weight: 400; }
.item-row { grid-template-columns: minmax(160px, 2fr) minmax(110px, 1fr) minmax(110px, 1fr) minmax(150px, 1.4fr) 110px auto; }
.item-row .who { color: var(--ink-2); font-size: 15px; }
.item-detail { background: #F9FBFD; border-top: 1px dashed var(--line); padding: 14px 20px 18px 20px; display: grid; gap: 12px; }
.paper-row { grid-template-columns: minmax(240px, 2fr) minmax(180px, 1.2fr) auto; }
.today-row { grid-template-columns: minmax(180px, 1.2fr) 140px minmax(220px, 2.6fr) auto; }
.today-row a.name { color: var(--ink); text-decoration: none; }
.today-row a.name:hover { text-decoration: underline; }
/* Today: one summary strip, Needs attention beside Upcoming exams, Office setup below (12/01 design review). */
.today-head { align-items: center; margin-bottom: 18px; }
.strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: var(--surface); border: 1px solid var(--card); border-radius: 8px; margin-bottom: 20px; box-shadow: var(--shadow); }
.strip-cell { display: grid; gap: 2px; align-content: start; padding: 14px 18px; text-decoration: none; color: var(--ink); border-left: 1px solid var(--line); min-height: 44px; }
.strip-cell:first-child { border-left: 0; border-radius: 8px 0 0 8px; }
.strip-cell:last-child { border-radius: 0 8px 8px 0; }
.strip-cell:hover { background: #F6F8FA; }
.strip-cell .n { font-size: 25px; font-weight: 400; line-height: 1.15; font-variant-numeric: tabular-nums; }
.strip-cell .t { font-size: 15px; }
.strip-cell .s { font-size: 13px; color: var(--ink-2); }
.strip-cell.late .n { color: var(--late); } .strip-cell.soon .n { color: var(--soon); } .strip-cell.new .n { color: var(--primary); }
.strip-cell.zero .n, .strip-cell.zero .t { color: var(--ink-3); }
.today-grid { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: 20px; align-items: start; margin-bottom: 20px; }
.today-card .card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 13px 18px; border-bottom: 1px solid var(--line); }
.task-head, .task-row { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(130px, .9fr) minmax(150px, auto); gap: 6px 14px; }
.task-head { padding: 8px 18px; font-size: 13px; color: var(--ink-2); background: #F7F8FA; border-bottom: 1px solid var(--line); }
.tasks, .exam-list { list-style: none; margin: 0; padding: 0; }
.task-row { align-items: center; padding: 12px 18px; border-top: 1px solid var(--line); }
.task-row:first-child, .exam-item:first-child { border-top: 0; }
.task { display: grid; gap: 2px; min-width: 0; }
.pname { font-weight: 700; color: var(--ink); text-decoration: none; justify-self: start; }
a.pname:hover { text-decoration: underline; }
.task .what { color: var(--ink-2); font-size: 15px; }
.deadline { font-size: 15px; }
.deadline .dl { font-weight: 700; } .deadline .dl.late { color: var(--late); } .deadline .dl.soon { color: var(--soon); }
.deadline .date { color: var(--ink-2); display: block; font-size: 14px; }
.task-row .cell-label { display: none; }
.next { justify-self: start; }
.card-foot { padding: 8px 18px; border-top: 1px solid var(--line); }
.exam-item { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 4px 12px; padding: 12px 18px; border-top: 1px solid var(--line); }
.exam-item .when { font-size: 15px; }
.exam-item .who { display: grid; gap: 2px; min-width: 0; }
.exam-item .docs { font-size: 15px; } .exam-item .docs.ok { color: var(--ok); }
.exam-item .missing { font-size: 14px; color: var(--soon); }
.first-steps { padding: 18px; display: grid; gap: 14px; }
.getting-started .summary-title { font-weight: 700; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 26px; }
.stat { display: grid; gap: 2px; padding: 16px 18px; background: var(--surface); border: 1px solid var(--card); border-left: 4px solid var(--card); border-radius: 12px; text-decoration: none; color: var(--ink); box-shadow: var(--shadow); }
.stat:hover { border-color: #A9B8C8; }
.stat .n { font-size: 32px; font-weight: 700; line-height: 1.1; }
.stat .t { font-weight: 400; }
.stat .s { color: var(--ink-2); font-size: 14px; }
.stat.late { border-left-color: var(--late); } .stat.late .n { color: var(--late); }
.stat.soon { border-left-color: var(--soon); } .stat.soon .n { color: var(--soon); }
.stat.new { border-left-color: var(--primary); } .stat.new .n { color: var(--primary); }
.counts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.sortby { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; margin-left: auto; }
.sortby select { width: auto; }
.filters { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-bottom: 6px; }
.filters input { max-width: 340px; }
.seg { display: inline-flex; border: 1px solid #C3CFDB; border-radius: 8px; overflow: hidden; }
.seg button { min-height: 44px; padding: 0 16px; border: 0; background: #fff; font: 400 15px var(--font); color: var(--ink); cursor: pointer; border-left: 1px solid #C3CFDB; }
.seg button:first-child { border-left: 0; }
.seg button[aria-pressed="true"] { background: var(--rail); color: #fff; }

/* ---------- Visit and FAA box on the pilot page ---------- */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0; }
.fact { padding: 18px 22px; border-left: 1px solid var(--line); display: grid; gap: 8px; align-content: start; }
.fact:first-child { border-left: 0; }
.fact .label { font: 400 14px var(--font); color: var(--ink-2); }
.fact .value { font-size: 17px; font-weight: 700; }
.fact .value.late { color: var(--late); }
details.more { border-top: 1px solid var(--line); }
details.more summary { padding: 16px 22px; cursor: pointer; font-weight: 700; list-style: none; min-height: 44px; }
details.more summary::before { content: "\25B8"; display: inline-block; width: 18px; color: var(--ink-2); }
details.more[open] summary::before { content: "\25BE"; }
.kv { display: grid; grid-template-columns: 220px 1fr; gap: 10px 20px; padding: 4px 22px 20px 40px; }
.kv dt { color: var(--ink-2); }
.kv dd { margin: 0; }

/* ---------- Forms on their own page (add / edit a pilot, settings) ---------- */
.form-page { max-width: 980px; }
.step { margin-bottom: 22px; }
.step > .card { padding: 22px 24px; display: grid; gap: 18px; }
.step-title { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.step-title .num { width: 30px; height: 30px; border-radius: 50%; background: var(--rail); color: #fff; display: grid; place-items: center; font: 700 15px var(--font); }
.item-edit { display: grid; gap: 4px; padding: 16px; margin: 8px 0; border: 1px solid var(--primary); border-radius: 8px; background: #FAFBFD; }
.item-edit .due { display: grid; gap: 8px; }
.item-edit .inline { display: flex; gap: 8px; align-items: center; }
.item-edit .inline input { width: 80px; }
.item-edit .x, .item-sum .x { min-height: 44px; width: 44px; border: 1px solid transparent; background: none; color: var(--ink-2); font-size: 22px; border-radius: 8px; cursor: pointer; }
.item-edit .x:hover, .item-sum .x:hover { background: var(--late-bg); color: var(--late); }
.item-head { display: grid; grid-template-columns: minmax(200px, 1.6fr) minmax(205px, 1fr) minmax(250px, 1.5fr) minmax(150px, .9fr) 40px; gap: 10px; font: 400 14px var(--font); color: var(--ink-2); }
.form-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 8px; flex-wrap: wrap; }
.start-from { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.start-from select, #dest { max-width: 420px; }
.settings-grid { display: grid; gap: 22px; max-width: 900px; }
.staff-row { grid-template-columns: minmax(200px, 1.4fr) minmax(220px, 1.4fr) 110px auto; }

.imp { display: grid; grid-template-columns: 1fr 1fr 110px 100px 160px 1.3fr 160px 120px; gap: 10px; align-items: end; }
.imp label { display: block; min-width: 0; }
.imp-head { font: 400 14px var(--font); color: var(--ink-2); padding: 10px 20px 0; }
.imp-head-li { list-style: none; }
@media (max-width: 1100px) { .imp { grid-template-columns: 1fr 1fr; } .imp-head-li { display: none; } }

/* ---------- Files for the FAA ---------- */
.order { display: flex; gap: 6px; align-items: center; }
.order b { min-width: 24px; }
.arrow { width: 36px; height: 36px; border-radius: 8px; border: 1px solid #C3CFDB; background: #fff; cursor: pointer; font-size: 16px; }
.arrow:disabled { opacity: .35; cursor: default; }
.checklabel { display: flex; gap: 8px; align-items: center; font-size: 15px; min-height: 44px; }
.warn { color: var(--soon); font-size: 14px; font-weight: 700; }
.bad { color: var(--late); font-size: 14px; font-weight: 700; }

/* ---------- Dialogs ---------- */
dialog { border: 0; border-radius: 10px; padding: 0; width: min(600px, calc(100vw - 32px)); max-height: calc(100vh - 64px); box-shadow: 0 20px 60px rgba(11, 42, 74, .35); color: var(--ink); }
dialog.wide { width: min(980px, calc(100vw - 32px)); }
dialog.viewer { width: min(1100px, calc(100vw - 32px)); height: calc(100vh - 48px); }
dialog::backdrop { background: rgba(11, 42, 74, .5); }
dialog form, dialog .box { display: flex; flex-direction: column; max-height: inherit; height: 100%; }
dialog header { padding: 22px 24px 8px; }
dialog header p { color: var(--ink-2); margin-top: 6px; }
dialog .body { padding: 12px 24px 18px; overflow-y: auto; display: grid; gap: 18px; }
dialog footer { padding: 16px 24px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; align-items: center; background: #FBFCFD; }
dialog footer .left { margin-right: auto; }
dialog.viewer iframe { flex: 1; width: 100%; border: 0; background: #525659; }
dialog.viewer header { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.linkbox { display: flex; gap: 8px; }
.linkbox input { font-size: 15px; }

/* ---------- Toast with Undo ---------- */
#toast { position: fixed; right: 20px; top: 16px; max-width: min(520px, calc(100vw - 40px)); background: #0F2236; color: #fff; padding: 12px 14px 12px 20px; border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .25); display: flex; gap: 14px; align-items: center; font-size: 16px; z-index: 50; max-width: calc(100vw - 32px); }
#toast .btn { min-height: 36px; background: transparent; color: #fff; border-color: rgba(255, 255, 255, .5); }
.idle { position: fixed; right: 20px; bottom: 20px; background: #fff; border: 1px solid var(--soon-line); border-radius: 12px; box-shadow: var(--shadow); padding: 14px 16px; display: flex; gap: 12px; align-items: center; z-index: 60; }
.loading { padding: 60px; text-align: center; color: var(--ink-2); }

/* ---------- Getting started ---------- */
.getting-started { padding: 10px 18px; margin-bottom: 26px; }
.getting-started summary { cursor: pointer; display: flex; gap: 10px; align-items: center; min-height: 44px; }
.getting-started .checklist { margin: 10px 0 6px; }
.checklist { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 10px; }
.checklist li { display: flex; gap: 12px; align-items: center; min-height: 40px; }
.checklist .tick { width: 26px; height: 26px; border-radius: 50%; border: 2px solid #9FB3C8; display: grid; place-items: center; font-size: 15px; flex: none; color: transparent; }
.checklist .done .tick { background: var(--ok); border-color: var(--ok); color: #fff; }
.checklist .done span { color: var(--ink-2); text-decoration: line-through; }


/* ---------- Exams, renewals, HIMS board, inbox ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--card); margin-bottom: 18px; }
.tabs a { padding: 10px 16px; font: 400 16px var(--font); color: var(--ink-2); text-decoration: none; border-bottom: 3px solid transparent; margin-bottom: -1px; min-height: 44px; display: inline-flex; align-items: center; }
.tabs a[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--primary); font-weight: 700; }
.exam-row { grid-template-columns: minmax(150px, 1.2fr) 120px minmax(170px, 1.2fr) minmax(170px, 1.6fr) auto; }
.exam-row a.name, .inbox-row a.name, .board a.name { color: var(--ink); text-decoration: none; font-weight: 700; }
.exam-row a.name:hover, .inbox-row a.name:hover, .board a.name:hover { text-decoration: underline; }
.progress { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
progress { width: 90px; height: 10px; border: 0; border-radius: 999px; background: #E6ECF2; overflow: hidden; accent-color: var(--ok); }
progress::-webkit-progress-bar { background: #E6ECF2; border-radius: 999px; }
progress::-webkit-progress-value { background: var(--ok); border-radius: 999px; }
progress::-moz-progress-bar { background: var(--ok); border-radius: 999px; }
.legend { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.board-wrap { overflow-x: auto; }
.board { width: 100%; border-collapse: collapse; font-size: 15px; }
.board th, .board td { text-align: left; padding: 12px 14px; border-top: 1px solid var(--line); vertical-align: middle; }
.board thead th { background: #F7F8FA; font: 400 14px var(--font); color: var(--ink-2); border-top: 0; white-space: nowrap; }
.board tbody th { font-weight: 700; min-width: 170px; }
.board .cell { display: grid; gap: 2px; justify-items: start; text-decoration: none; color: inherit; padding: 4px 6px; margin: -4px -6px; border-radius: 8px; }
.board .cell:hover { background: #F2F6FB; }
.inbox-row { grid-template-columns: minmax(170px, 1fr) minmax(220px, 1.6fr) 160px auto; }
@media (max-width: 1100px) {
  .exam-row, .inbox-row { grid-template-columns: minmax(0, 1fr); }
  .board thead { display: none; }
  .board, .board tbody, .board tr, .board th, .board td { display: block; width: 100%; }
  .board tr { border-top: 1px solid var(--card); padding: 10px 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .board tbody th, .board td.visit { grid-column: 1 / -1; }
  .board .cell { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
  .board td, .board tbody th { border: 0; padding: 6px 16px; }
  .board td[data-label]::before { content: attr(data-label); display: block; font: 400 13px var(--font); color: var(--ink-2); }
}

/* ---------- Add-a-pilot steps and FAA steps ---------- */
.wizard { list-style: none; display: flex; gap: 8px; padding: 0; margin: 0 0 18px; counter-reset: w; flex-wrap: wrap; }
.wizard li { counter-increment: w; display: flex; align-items: center; gap: 8px; padding: 8px 14px 8px 8px; border-radius: 999px; background: #E9EDF2; color: var(--ink-2); font-size: 15px; }
.wizard li::before { content: counter(w); width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--ink-2); font-weight: 700; }
.wizard li.on { background: var(--rail); color: #fff; font-weight: 700; }
.wizard li.on::before { color: var(--rail); }
.wizard li.done { background: var(--ok-bg); color: var(--ok); }
.wizard li.done::before { content: "\2713"; background: var(--ok); color: #fff; }
.pick-row { grid-template-columns: 34px minmax(0, 1.6fr) minmax(0, 1fr); cursor: pointer; }
.pick-row.off { opacity: .6; }
.faa-row { grid-template-columns: 116px minmax(140px, 1.2fr) minmax(190px, 1.5fr) 156px 104px; }
.okbox-card { margin-top: 12px; border-color: var(--ok-line); background: var(--ok-bg); }

/* ---------- More than one FAA letter ---------- */
.letter-card { margin-bottom: 12px; padding: 22px 24px; display: grid; gap: 18px; }
@media (max-width: 760px) { .letter-card, .step > .card { padding: 18px 16px; } }
.letter-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 8px; }
.letter-top h3 { margin: 0; font-size: 17px; }
.add-letter { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 4px 0 14px; }
.add-letter .hint { margin: 0; }
.letter-items + .letter-items { margin-top: 22px; padding-top: 18px; border-top: 2px solid var(--line); }
.letter-head { margin: 0 0 10px; font-size: 17px; }
.letter-items .start-from { margin-bottom: 10px; }
.letter-group { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; padding: 12px 18px 8px; background: #F6F8FB; border-top: 1px solid var(--line); }
.section-head .head-links { display: flex; gap: 18px; flex-wrap: wrap; }

/* ---------- Round 3 (12/01): zoom, Save bar, File it, sets ---------- */
/* Labels that only show when the column headings are hidden (narrow window or 125 to 150 percent zoom). */
.cell-label { display: none; font: 400 14px var(--font); color: var(--ink-2); margin-bottom: 4px; }
/* Add and Edit: Back, Next and Save stay on screen. */
#pf > .form-foot { position: sticky; bottom: 0; z-index: 5; background: #fff; padding: 12px 16px; border: 1px solid var(--card); border-bottom: 0; border-radius: 8px 8px 0 0; box-shadow: 0 -6px 18px rgba(16, 24, 40, .10); margin-top: 16px; }
.foot-left { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.more-below { font-weight: 700; }
.form-end { height: 1px; }
/* File it: the paper beside the fields. */
dialog.fileit { width: min(1180px, calc(100vw - 32px)); }
.fileit-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, 1fr); gap: 20px; align-items: start; }
.fileit-pdf { width: 100%; height: min(62vh, 720px); border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.type-cell input { width: 100%; }
.set-row { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.dl-row + .dl-row { margin-top: 10px; }
.archive-line { margin-top: 14px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.head-links .link { white-space: nowrap; }

/* ---------- Start from the FAA's list ---------- */
dialog.faa-list { width: min(980px, calc(100vw - 32px)); }
.fl-body { display: grid; gap: 16px; }
.fl-letter { background: #F6F8FB; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.fl-block h3 { margin: 0 0 2px; font-size: 16px; }
.fl-lines { display: grid; gap: 6px; margin-top: 8px; }
.fl-line { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 8px; align-items: start; padding: 6px 8px; border-radius: 8px; cursor: pointer; }
.fl-line:hover { background: #F6F8FB; }
.fl-line input { margin-top: 3px; width: 18px; height: 18px; }
.fl-sub { margin-left: 30px; display: grid; gap: 4px; }
.faa-words { margin: 0 0 8px; color: var(--ink-2); }

/* ---------- Help ---------- */
.help-steps { margin: 8px 0 0; padding-left: 22px; display: grid; gap: 10px; }
.help-q { margin-bottom: 10px; }
.help-q summary { font-weight: 700; font-size: 16px; padding: 14px 18px; cursor: pointer; min-height: 44px; }
.help-a { padding: 0 18px 14px; color: var(--ink-2); }
.help-a p + p { margin-top: 8px; }

/* ---------- Narrow screens (tablet) ---------- */
@media (max-width: 1100px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .topbar { position: sticky; top: 0; z-index: 45; background: var(--rail); border-bottom: 0; min-height: 56px; padding: 0 12px 0 14px; gap: 12px; }
  .topbar-logo { display: block; width: 104px; height: auto; flex: none; }
  .topbar .practice { color: #fff; font-weight: 400; flex: 1; }
  .topbar-who { display: none; }
  .menu-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; min-width: 44px; padding: 0 14px; border: 1px solid rgba(255, 255, 255, .55); border-radius: 8px; background: transparent; color: #fff; font: 400 16px var(--font); cursor: pointer; flex: none; }
  .menu-btn .ico { width: 20px; height: 20px; }
  .rail { display: none; }
  .shell.menu-open .rail { display: flex; position: fixed; top: 56px; left: 0; right: 0; bottom: 0; z-index: 40; height: auto; overflow-y: auto; padding: 14px 16px 28px; gap: 16px; }
  .shell.menu-open .rail .logo { display: none; }
  .shell.menu-open .nav a { min-height: 48px; }
  .shell.menu-open .rail .me { margin-top: 0; }
  .cell-label { display: block; }
  .fileit-grid { grid-template-columns: 1fr; }
  .fileit-pdf { height: 46vh; }
  .set-row { grid-template-columns: minmax(0, 1fr); }
  .main { padding: 20px; }
  .today-grid { grid-template-columns: minmax(0, 1fr); }
  .strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .strip-cell:nth-child(3) { border-left: 0; }
  .strip-cell:nth-child(n+3) { border-top: 1px solid var(--line); }
  .strip-cell:first-child, .strip-cell:last-child { border-radius: 0; }
  .pilot-row { grid-template-columns: minmax(0, 1fr); }
  .rows-head.pilot-row { display: none; }
  .item-row, .paper-row, .today-row, .faa-row, .staff-row { grid-template-columns: minmax(0, 1fr); }
  .rows-head.item-row, .rows-head.faa-row, .rows-head.paper-row { display: none; }
  .item-row .chev, .pilot-row .chev { display: none; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .item-detail { padding-left: 20px; }
  .item-head { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .item-head { display: none; }
  .grid2, .grid3 { grid-template-columns: 1fr; }
  .kv { grid-template-columns: 1fr; padding-left: 22px; }
}

@media (max-width: 760px) {
  .main { padding: 16px 14px 60px; }
  .btn, .btn.compact { min-height: 44px; }
  .link { min-height: 44px; }
  .task-head { display: none; }
  .task-row { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .task-row .cell-label { display: none; }
  .next, .next .btn { width: 100%; }
  .exam-item { grid-template-columns: minmax(0, 1fr); }
  .page-head { margin-bottom: 16px; }
  .page-head .actions, .page-head .actions .btn { width: 100%; }
  .strip-cell { padding: 12px 14px; }
  .item-head { grid-template-columns: minmax(0, 1fr); }
  .filters input { max-width: none; }
  .sortby { margin-left: 0; }
  .seg { flex-wrap: wrap; }
  .facts { grid-template-columns: 1fr; } .fact { border-left: 0; border-top: 1px solid var(--line); } .fact:first-child { border-top: 0; }
  dialog { width: calc(100vw - 16px); max-height: calc(100dvh - 16px); }
  dialog .body { padding: 10px 16px 14px; } dialog header { padding: 16px 16px 6px; } dialog footer { padding: 12px 16px; flex-wrap: wrap; }
  .signin .card { padding: 26px 20px 20px; }
}
.signin .btn { white-space: normal; height: auto; padding: 10px 16px; }
dialog .body { min-height: 0; flex: 1 1 auto; }
.rows-head.item-row, .rows-head.pilot-row { min-height: 0; }

/* ---------- The sender's page (a pilot or provider on a phone) ---------- */
body.sender { padding: 24px 14px 40px; background: var(--bg); }
.send-card { margin: 0 auto; max-width: 560px; background: var(--surface); border: 1px solid var(--card); border-radius: 10px; box-shadow: var(--shadow); padding: 24px 20px; display: grid; gap: 16px; }
.send-card .eyebrow { font: 400 14px var(--font); color: var(--ink-2); }
.send-card h1 { font-size: 24px; }
.send-card .lead { color: var(--ink); font-size: 16px; }
.send-card .contact { font-size: 15px; color: var(--ink-2); }
.send-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
#body { display: grid; gap: 14px; }
#body > p { margin: 0; }
/* Each paper: its name, its status (or what went wrong and what to do) and its button. Side by side on a wide
   screen; stacked on a phone, the button full width (12/01 design review: "Counselor" split mid-word and the
   received label ran under the button at 390 px). */
.send-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "name action" "state action" "why why"; gap: 4px 14px; align-items: center; border: 1px solid var(--card); border-radius: 8px; padding: 14px 16px; min-height: 72px; cursor: pointer; background: #fff; }
.send-item:hover { border-color: var(--primary); }
.send-item .send-label { grid-area: name; font-weight: 700; font-size: 17px; }
.send-item .state { grid-area: state; font-size: 15px; }
.state.ok { color: var(--ok); } .state.soon { color: var(--soon); } .state.none { color: var(--ink-2); } .state.late { color: var(--late); font-weight: 700; }
.send-item .btn { grid-area: action; min-height: 48px; }
.send-item .why { grid-area: why; color: var(--late); font-size: 15px; }
@media (max-width: 560px) {
  .send-item { grid-template-columns: minmax(0, 1fr); grid-template-areas: "name" "state" "why" "action"; gap: 6px; }
  .send-item .btn { width: 100%; margin-top: 6px; white-space: normal; }
}
.banner { border-radius: 8px; padding: 12px 16px; font-weight: 700; overflow-wrap: break-word; }
.send-card > *, .send-item > * { min-width: 0; overflow-wrap: break-word; }
.banner.ok { color: var(--ok); background: var(--ok-bg); border: 1px solid var(--ok-line); }
.banner.info { color: var(--ink); background: #F3F6F9; border: 1px solid var(--card); font-weight: 400; }
.send-card details summary { cursor: pointer; color: var(--primary); min-height: 44px; display: flex; align-items: center; }
.send-card details p { margin-top: 8px; color: var(--ink-2); }
.send-card .foot { color: var(--ink-2); font-size: 15px; border-top: 1px solid var(--line); padding-top: 14px; display: grid; gap: 8px; }
.send-card .by { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-3); }
.send-card .by img { width: 20px; height: 20px; }
#inviteForm .btn { justify-self: start; }

/* Safari draws today's date, greyed, in an empty date box (12/01 dress rehearsal): show empty ones as empty. */
html.safari input[type="date"].empty:not(:focus) { color: transparent; }   /* WebKit colours the date digits from the input itself */

/* ---------- 12/01 design review, workflow pass ---------- */
.signin-title { font-size: 22px; margin: 22px 0 0; }
.good { color: var(--ok); font-size: 14px; font-weight: 700; }
[aria-invalid="true"] { border-color: var(--late) !important; box-shadow: 0 0 0 1px var(--late); }

/* Lists fold under their heading; on phones the calm part starts folded. */
details.fold > summary { list-style: none; cursor: pointer; min-height: 44px; display: flex; align-items: center; }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold > summary .group-title::before { content: ""; flex: none; width: 8px; height: 8px; border-right: 2px solid var(--ink-2); border-bottom: 2px solid var(--ink-2); transform: rotate(-45deg); transition: transform .15s; }
details.fold[open] > summary .group-title::before { transform: rotate(45deg); }
details.fold > summary:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; border-radius: 6px; }

/* Rows that open something say so. */
.row-act { color: var(--primary); font-size: 15px; justify-self: end; white-space: nowrap; }
.row-act::after { content: "\203A"; display: inline-block; margin-left: 6px; font-size: 18px; transition: transform .15s; }
.item-row[aria-expanded="true"] .row-act::after { transform: rotate(90deg); }
.board .cell .go { display: none; }

/* Pilot page: one main action, the rest in a labeled group; Archive on its own at the bottom. */
.head-actions { display: grid; gap: 12px; justify-items: end; }
.more-actions { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; justify-content: flex-end; }
.more-actions > .label { font-size: 14px; color: var(--ink-2); }
.archive-zone { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); }
.archive-zone h2 { font-size: 15px; font-weight: 400; color: var(--ink-2); margin: 0; }

/* Files for the FAA: where you are, the deadline, and short text with the long part behind a disclosure. */
.stepper { list-style: none; margin: 0 0 24px; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.stepper button { width: 100%; min-height: 44px; display: flex; align-items: center; gap: 8px; padding: 6px 10px; border: 1px solid var(--card); border-radius: 8px; background: #fff; font: 400 15px var(--font); color: var(--ink-2); text-align: left; cursor: pointer; }
.stepper .num { flex: none; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: #E9EDF2; color: var(--ink-2); font-weight: 700; font-size: 13px; }
.stepper li.done button { color: var(--ok); }
.stepper li.done .num { background: var(--ok); color: #fff; }
.stepper li.on button { border-color: var(--rail); background: var(--rail); color: #fff; font-weight: 700; }
.stepper li.on .num { background: #fff; color: var(--rail); }
.stepper-now { display: none; margin: 0 0 16px; font-weight: 700; }
.faa-step.current { border-left: 3px solid var(--rail); padding-left: 14px; }
.now-tag { font-size: 14px; color: var(--rail); border: 1px solid var(--rail); border-radius: 6px; padding: 2px 8px; }
.step-sub { color: var(--ink-2); margin: 0 0 10px; }
.step-sub > p { margin: 0; }
details.explain { margin: 6px 0; }
details.explain > summary { cursor: pointer; color: var(--primary); min-height: 44px; display: flex; align-items: center; width: fit-content; }
details.explain > p { margin: 2px 0 8px; color: var(--ink-2); }
.done-set h3 { margin: 0 0 4px; font-size: 17px; }
.done-set .actions { margin-top: 8px; }

/* Add pilot, step 3: one short line per item, one item open at a time. */
.item-list { display: grid; }
.item-sum { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.item-sum:first-child { border-top: 0; }
.item-sum-text { display: grid; gap: 2px; min-width: 0; overflow-wrap: break-word; }
.item-sum .need { color: var(--late); font-size: 15px; font-weight: 700; }
.item-sum.incomplete { box-shadow: inset 3px 0 0 var(--late); padding-left: 12px; }
.item-sum-actions { display: flex; gap: 6px; align-items: center; }
.item-edit-head { margin: 0 0 6px; font-size: 16px; }
.item-edit .due { align-content: start; }
.item-edit-foot { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; margin-top: 8px; }
.need-summary { color: var(--late); font-weight: 700; }

@media (max-width: 760px) {
  .row-act { justify-self: start; }
  .board .cell { position: relative; padding-right: 26px; }
  .board .cell .go { display: block; position: absolute; right: 6px; top: 50%; transform: translateY(-50%); color: var(--primary); font-size: 20px; }
  .head-actions { width: 100%; justify-items: stretch; }
  .more-actions { display: grid; justify-content: stretch; }
  .more-actions .actions { display: grid; grid-template-columns: minmax(0, 1fr); }
  .more-actions .btn { white-space: normal; }
  .stepper { grid-template-columns: repeat(5, 44px); gap: 8px; margin-bottom: 8px; }
  .stepper button { padding: 0; justify-content: center; }
  .stepper .name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .stepper-now { display: block; }
  .item-sum { grid-template-columns: minmax(0, 1fr); }
  .item-sum-actions { justify-content: space-between; }
}

/* Touch screens, any width (12/01 check: a 768 px tablet had 38 px compact buttons, and names, Back and HIMS cells were
   under 44 px on phones): every tap target at least 44 px tall. */
@media (pointer: coarse), (max-width: 760px) {
  .btn, .btn.compact, .link, .back { min-height: 44px; }
  .link:not(summary) { display: inline-flex; align-items: center; }
  .pname, .board a.name, .getting-started a, .first-steps a { display: inline-flex; align-items: center; min-height: 44px; }
  .board .cell { min-height: 44px; }
  .fl-line { min-height: 44px; padding-top: 10px; padding-bottom: 10px; }
}
/* Settings: the morning email preview wraps inside its card (12/01 review: it made the page 1860 px wide). */
.settings-grid pre { white-space: pre-wrap; overflow-wrap: break-word; max-width: 100%; font: 15px/1.45 var(--font); background: #F7F8FA; border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; }
.settings-grid { min-width: 0; }

/* 12/01 review fixes. The sticky top bar (<= 1100 px) never covers a heading something scrolls to. */
@media (max-width: 1100px) { html { scroll-padding-top: 64px; } }
/* Disclosures that lost their triangle to display: flex get one back. */
details.explain > summary::before, .send-card details summary::before { content: "\25B8"; display: inline-block; width: 16px; flex: none; }
details.explain[open] > summary::before, .send-card details[open] summary::before { content: "\25BE"; }
details.explain > summary::-webkit-details-marker, .send-card details summary::-webkit-details-marker { display: none; }
/* Sender page: the file picker is reachable by keyboard; the focused paper shows a ring. */
.send-item { position: relative; }
.send-item:has(input:focus-visible) { outline: 3px solid var(--primary); outline-offset: 2px; }
.item-edit .need { color: var(--late); font-weight: 700; margin: 0 0 6px; }

/* ---------- 12/01 scrolling pass (Ryan: "not obvious you can scroll. look at the entire app and fix any scrolling") ---------- */
/* Dialogs: the bottom fades while there's more below, with a More below button in the footer. */
dialog .body.shade-below { -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 36px), rgba(0, 0, 0, .2)); mask-image: linear-gradient(to bottom, #000 calc(100% - 36px), rgba(0, 0, 0, .2)); }
dialog footer .more-below { margin-right: auto; }
/* HIMS board on wider screens: tidy cells (chip over date, top-aligned), the pilot column stays put while the board
   scrolls sideways, and a shadow at the right edge while there's more to the right. */
@media (min-width: 761px) {
  .board th, .board td { vertical-align: top; padding: 12px 11px; }
  .board tbody th { min-width: 150px; }
  .board .cell .chip { min-width: 86px; justify-content: center; }
  .board .cell .small, .board td > .muted.small { white-space: nowrap; }
  .board tbody th { position: sticky; left: 0; z-index: 1; background: #fff; box-shadow: 1px 0 0 var(--line); }
  .board thead th:first-child { position: sticky; left: 0; z-index: 2; box-shadow: 1px 0 0 var(--line); }
  .board-wrap.more-right { box-shadow: var(--shadow), inset -18px 0 14px -14px rgba(16, 24, 40, .35); }
}
.board-hint { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin: 0 0 10px; color: var(--ink-2); }
/* The rail fits short screens without scrolling. */
@media (min-width: 1101px) and (max-height: 800px) {
  .rail { padding-top: 14px; padding-bottom: 14px; gap: 12px; }
  .nav a { min-height: 40px; }
  .rail .me { padding-top: 10px; gap: 2px; }
}
/* Phones: the office name in the top bar gets two lines instead of being cut off. */
@media (max-width: 1100px) {
  .topbar .practice { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.2; overflow: hidden; }
}

/* ---------- 12/01 workflow audit (round 5) ---------- */
.pending { display: block; color: var(--primary); font-weight: 700; font-size: 15px; }
.exam-item .pending, .exam-item .warn { display: block; }
.fileit-view { display: grid; gap: 6px; justify-items: start; }
.fileit-view .fileit-pdf, .fileit-view .pdf-fallback { width: 100%; }
.pdf-fallback { display: grid; gap: 10px; justify-items: start; padding: 20px; border: 1px dashed var(--card); border-radius: 10px; background: #F7F8FA; }
dialog.viewer .pdf-fallback { margin: 20px; }
.blocked h2 { margin: 0 0 4px; }
.blocked p { margin: 0 0 12px; color: var(--ink-2); }
.another-way .card p { margin: 0 0 12px; }
#vdSays p { margin: 0; }
#vdSays { display: grid; gap: 4px; }
