/* K&M Client Reviews — demo styles. Consistent DARK theme (owner direction, 2026-09-28):
   the two canon navies are the backgrounds; Warm White, Pure White, Blue-Grey and Gold are
   text and foreground. Brand canon: KM-Logo-Color-Chart-2027.png. Status colors below are
   functional light tints for dark surfaces and are always paired with words. */

@font-face {
  font-family: "Anton";
  src: url("/static/fonts/anton/Anton-Regular.ttf") format("truetype");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "TikTok Sans";
  src: url("/static/fonts/tiktok-sans/TikTokSans-Variable.ttf") format("truetype");
  font-weight: 300 900; font-stretch: 75% 150%; font-style: normal; font-display: swap;
}

:root {
  color-scheme: dark;
  /* Brand canon */
  --navy-dark: #09152E;
  --navy-mid: #101E3E;
  --blue-grey: #A1AAC8;
  --gold: #EBC14C;
  --warm-white: #F0EEEA;
  --white: #FFFFFF;

  /* Roles */
  --page: var(--navy-dark);          /* page background */
  --panel: var(--navy-mid);          /* cards and bars */
  --well: var(--navy-dark);          /* inputs, rows and wells inside panels */
  --text: var(--warm-white);         /* body text */
  --text-strong: var(--white);       /* headings, key figures */
  --text-soft: var(--blue-grey);     /* secondary text */
  --accent: var(--gold);             /* actions, highlights, focus */
  --line: rgba(161, 170, 200, .28);  /* Blue-Grey hairlines: the navies are only 1.10:1 apart */
  --line-strong: rgba(161, 170, 200, .55);

  /* Functional status tints for dark surfaces */
  --good: #86D9A6;   --good-bg: rgba(134, 217, 166, .13);
  --info: #9DC2FF;   --info-bg: rgba(157, 194, 255, .13);
  --warn: #F6B868;   --warn-bg: rgba(246, 184, 104, .14);
  --danger: #FF9C92; --danger-bg: rgba(255, 156, 146, .13);
  --good-solid: #1E6B43;

  --radius: 10px;
  --display: "Anton", "Arial Narrow", Impact, sans-serif;
  --body: "TikTok Sans", "DM Sans", Inter, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; color: var(--text); background-color: var(--page); font: 400 16px/1.55 var(--body); }
a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--white); }
h1, h2, h3 { font-family: var(--display); font-weight: 400; color: var(--text-strong); line-height: 1.1; letter-spacing: .01em; }
h1 { font-size: 34px; margin: 6px 0 16px; }
h2 { font-size: 22px; margin: 0 0 10px; }
strong, b { font-weight: 650; color: var(--text-strong); }
code { font-size: .9em; }
.muted { color: var(--text-soft); }
.sub { color: var(--text-soft); font-size: 14px; }
.strong { font-weight: 650; }
.nowrap { white-space: nowrap; }
img { max-width: 100%; }
::placeholder { color: var(--text-soft); opacity: .75; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ---------- geometric page background: two broad planes, the two navies only ---------- */
body {
  background-image:
    linear-gradient(112deg, transparent 0 56%, var(--navy-mid) 56% 100%),
    linear-gradient(28deg, var(--navy-mid) 0 16%, transparent 16% 100%);
  background-attachment: fixed;
}

/* ---------- buttons & forms ---------- */
button, .btn {
  font: 600 15px/1.2 var(--body); cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; text-decoration: none;
  border: 1.5px solid var(--line-strong); background: transparent; color: var(--text);
  border-radius: 8px; padding: 9px 14px; min-height: 40px;
}
button:hover, .btn:hover { border-color: var(--warm-white); color: var(--white); background: rgba(240, 238, 234, .06); }
button.primary, .btn.primary { background: var(--gold); border-color: var(--gold); color: var(--navy-dark); }
button.primary:hover, .btn.primary:hover { background: #F2D06F; border-color: #F2D06F; color: var(--navy-dark); }
button.secondary, .btn.secondary { background: transparent; border-color: var(--warm-white); color: var(--warm-white); }
button.danger-outline { border-color: var(--danger); color: var(--danger); }
button.danger-outline:hover { background: var(--danger-bg); color: var(--danger); border-color: var(--danger); }
button.ghost { background: transparent; }
button.link { border: 0; background: none; padding: 0; min-height: 0; color: var(--accent); text-decoration: underline; font-weight: 500; }
button.small, .btn.small { padding: 5px 10px; min-height: 32px; font-size: 14px; }
button:disabled { opacity: .45; cursor: not-allowed; }
input, select, textarea {
  font: 400 16px/1.4 var(--body); color: var(--text); background: var(--well);
  border: 1.5px solid var(--line-strong); border-radius: 8px; padding: 9px 11px; width: 100%;
}
input:focus-visible, select:focus-visible, textarea:focus-visible { border-color: var(--accent); }
select option { background: var(--navy-mid); color: var(--text); }
textarea { resize: vertical; }
label { display: flex; flex-direction: column; gap: 4px; font-weight: 600; font-size: 15px; color: var(--text-strong); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
.span-2 { grid-column: 1 / -1; }
fieldset.checks { border: 0; padding: 0; margin: 0 0 12px; display: flex; flex-wrap: wrap; gap: 8px 18px; }
fieldset.checks legend { margin-bottom: 6px; padding: 0; }
fieldset.checks label { flex-direction: row; align-items: center; font-weight: 500; gap: 7px; color: var(--text); }
fieldset.checks input { width: 18px; height: 18px; accent-color: var(--gold); }
form.inline { display: inline; }
.row { display: flex; align-items: center; gap: 12px; margin-top: 10px; flex-wrap: wrap; }
.stack { display: grid; gap: 14px; margin: 14px 0; }
.center { text-align: center; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- staff chrome ---------- */
.topbar { display: flex; align-items: center; gap: 12px 28px; padding: 10px 24px; flex-wrap: wrap;
  background: rgba(9, 21, 46, .92); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; }
.topbar-logo { height: 72px; width: auto; display: block; }
.brand-title { font-family: var(--display); font-size: 22px; color: var(--white); letter-spacing: .02em; padding-left: 14px; border-left: 1px solid var(--line-strong); }
.nav { display: flex; gap: 2px; flex-wrap: wrap; flex: 1; }
.nav a { color: var(--blue-grey); text-decoration: none; padding: 8px 12px; border-radius: 6px; font-weight: 600; border-bottom: 3px solid transparent; }
.nav a:hover { color: var(--white); background: rgba(255,255,255,.06); }
.nav a.active { color: var(--white); border-bottom-color: var(--gold); border-radius: 6px 6px 0 0; }
.account { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; justify-content: flex-end; min-width: 0; }
.account-who { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; text-align: right; }
.account-email { font-size: 14px; font-weight: 600; color: var(--text-strong); overflow-wrap: anywhere; }
.account-role { font-size: 13px; color: var(--text-soft); }
.clock-readonly { margin: 0; flex: 1; }
.demo-banner { background: var(--gold); color: var(--navy-dark); font-size: 14px; padding: 7px 24px; text-align: center; }
.demo-banner strong { color: var(--navy-dark); }
.roster-banner { display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  background: var(--panel); border-bottom: 2px solid var(--warn); padding: 12px 24px; }
.roster-banner div { max-width: 900px; }
.clockbar { background: var(--panel); display: flex; align-items: center; gap: 14px 18px; padding: 12px 24px; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.clock-now { display: flex; flex-direction: column; min-width: 250px; }
.clock-label { text-transform: uppercase; letter-spacing: .1em; font-size: 12px; color: var(--blue-grey); font-weight: 700; }
.clock-now strong { font-size: 18px; }
.clock-next { font-size: 14px; color: var(--blue-grey); }
.clock-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; flex: 1; }
.clock-set { position: relative; }
.clock-set summary { cursor: pointer; font-weight: 600; padding: 9px 12px; border-radius: 8px; border: 1.5px solid var(--line-strong); list-style: none; }
.clock-set summary::-webkit-details-marker { display: none; }
.clock-set-body { position: absolute; z-index: 5; top: 115%; left: 0; background: var(--navy-mid); border: 1px solid var(--line-strong); padding: 14px; border-radius: 10px; box-shadow: 0 12px 32px rgba(0,0,0,.5); display: grid; gap: 8px; width: 250px; }
.clock-set-body small { color: var(--text-soft); }
.clock-set-body button { background: var(--gold); border-color: var(--gold); color: var(--navy-dark); }
.container { max-width: 1260px; margin: 0 auto; padding: 24px 24px 64px; }

/* ---------- cards, stats, tables ---------- */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; margin-bottom: 18px; box-shadow: 0 8px 24px rgba(0,0,0,.28); }
.card.empty { text-align: center; padding: 40px 20px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.card-head h2 { margin: 0; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; border-top: 4px solid var(--blue-grey); }
.stat.tone-good { border-top-color: var(--good); }
.stat.tone-info { border-top-color: var(--info); }
.stat.tone-warn { border-top-color: var(--gold); }
/* Queue tiles are filters: links with hover and a gold selected state. Plain .stat tiles elsewhere are summaries only. */
a.stat-link { display: block; text-decoration: none; color: inherit; cursor: pointer; position: relative; transition: border-color .12s, transform .12s; }
a.stat-link::after { content: "View ›"; position: absolute; right: 14px; top: 14px; font-size: 13px; font-weight: 600; color: var(--text-soft); }
a.stat-link:hover { border-color: var(--warm-white); transform: translateY(-1px); }
a.stat-link:hover::after { color: var(--gold); }
a.stat-link.selected { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold), 0 8px 24px rgba(0,0,0,.28); }
a.stat-link.selected::after { content: "Showing"; color: var(--gold); }
.stat-value { font-family: var(--display); font-size: 34px; color: var(--white); line-height: 1.05; }
.stat-label { font-weight: 650; font-size: 15px; color: var(--text-strong); }
.stat-note { color: var(--text-soft); font-size: 13px; }
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .07em; color: var(--text-soft); font-weight: 700; padding: 8px 10px; border-bottom: 1px solid var(--line-strong); }
.table td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td { background: rgba(161, 170, 200, .05); }
.who { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.mini { width: 28px; height: 33px; object-fit: cover; object-position: 50% 20%; border-radius: 5px; flex: none; box-shadow: 0 0 0 1px var(--line-strong); }
.seg { display: inline-flex; border: 1.5px solid var(--line-strong); border-radius: 8px; overflow: hidden; }
.seg a { padding: 6px 12px; text-decoration: none; color: var(--text); font-size: 14px; font-weight: 600; }
.seg a.active { background: var(--gold); color: var(--navy-dark); }
.range-seg { margin-bottom: 16px; }
.badge { display: inline-block; font-size: 13px; font-weight: 650; padding: 3px 9px; border-radius: 999px; white-space: nowrap; border: 1px solid transparent; }
.badge-good { background: var(--good-bg); color: var(--good); border-color: rgba(134, 217, 166, .35); }
.badge-info { background: var(--info-bg); color: var(--info); border-color: rgba(157, 194, 255, .35); }
.badge-warn { background: var(--warn-bg); color: var(--warn); border-color: rgba(246, 184, 104, .35); }
.badge-danger { background: var(--danger-bg); color: var(--danger); border-color: rgba(255, 156, 146, .35); }
.badge-active { background: rgba(240, 238, 234, .1); color: var(--warm-white); border-color: var(--line-strong); }
.badge-muted { background: transparent; color: var(--text-soft); border-color: var(--line); }
.chips { display: flex; flex-wrap: wrap; gap: 4px; }
.chip { font-size: 13px; border-radius: 6px; padding: 2px 7px; border: 1px solid var(--line); white-space: nowrap; font-weight: 600; }
.chip-good { color: var(--good); border-color: rgba(134, 217, 166, .4); background: var(--good-bg); }
.chip-danger { color: var(--danger); border-color: rgba(255, 156, 146, .4); background: var(--danger-bg); }
.chip-muted { color: var(--text-soft); }
.tag { font-family: var(--body); font-size: 11px; text-transform: uppercase; letter-spacing: .07em; font-weight: 700; color: var(--blue-grey); border: 1px solid var(--line-strong); border-radius: 4px; padding: 1px 5px; margin-left: 4px; vertical-align: middle; }
.tag-warn { color: var(--danger); border-color: rgba(255, 156, 146, .45); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid-2 > *, .grid-3 > * { min-width: 0; }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.page-head h1 { margin-bottom: 4px; }
.head-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0 0 12px; }
.dl dt { color: var(--text-soft); }
.dl dd { margin: 0; overflow-wrap: anywhere; }
ul.plain { list-style: none; padding: 0; margin: 0 0 10px; }
ul.plain li { padding: 6px 0; border-bottom: 1px solid var(--line); }
ul.plain li:last-child { border-bottom: 0; }
.callout { background: var(--warn-bg); border: 1px solid rgba(246, 184, 104, .4); border-radius: 10px; padding: 10px 14px; margin: 10px 0; color: var(--text); }
.callout.good { background: var(--good-bg); border-color: rgba(134, 217, 166, .4); }
blockquote { margin: 0 0 10px; padding: 10px 14px; background: var(--well); border-left: 4px solid var(--gold); border-radius: 6px; }
blockquote footer { color: var(--text-soft); font-size: 13px; margin-top: 4px; }
.flash { background: var(--good-bg); border: 1px solid rgba(134, 217, 166, .45); color: var(--good); font-weight: 600; padding: 10px 14px; border-radius: 10px; margin-bottom: 16px; }
.flash::before { content: "✓ "; }
.flash-error { background: var(--danger-bg); border-color: rgba(255, 156, 146, .45); color: var(--danger); }
.flash-error::before { content: "⚠ "; }

/* timeline */
.timeline { list-style: none; margin: 0; padding: 0; }
.step { display: grid; grid-template-columns: 18px 1fr; gap: 12px; padding-bottom: 14px; position: relative; }
.step:not(:last-child)::before { content: ""; position: absolute; left: 8px; top: 20px; bottom: 0; width: 2px; background: var(--line-strong); }
.step-dot { width: 18px; height: 18px; border-radius: 50%; border: 3px solid var(--warm-white); background: var(--navy-dark); margin-top: 2px; }
.step-consumed .step-dot { background: var(--gold); border-color: var(--gold); }
.step-skipped .step-dot { border-color: var(--line-strong); background: var(--navy-dark); }
.step-title { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.contacts { list-style: none; margin: 6px 0 0; padding: 0; font-size: 14px; }
.contacts li { padding: 2px 0; }
.chan { display: inline-block; min-width: 42px; font-weight: 650; color: var(--text-strong); }
.history details summary { cursor: pointer; color: var(--accent); font-size: 14px; }
.msg-preview { margin-top: 8px; background: var(--well); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; max-width: 560px; }
.msg-subject { font-weight: 650; margin-bottom: 6px; color: var(--text-strong); }
.msg-preview pre { white-space: pre-wrap; font: 14px/1.5 var(--body); margin: 0 0 6px; color: var(--text); }

/* reviews */
.explainer .badge { margin-right: 6px; }
.review-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(340px, 100%), 1fr)); gap: 14px; }
.review { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.review header { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.review-text { margin: 0; font-size: 17px; color: var(--text-strong); }
.review-meta { color: var(--text-soft); font-size: 14px; }
.review-match { border-top: 1px solid var(--line); padding-top: 8px; font-size: 15px; display: grid; gap: 6px; }
.stars { color: var(--gold); letter-spacing: 1px; font-size: 15px; }
.stars .off { color: rgba(161, 170, 200, .35); }
.rating-num { font-size: 14px; font-weight: 650; }
.platform { font-size: 13px; font-weight: 700; padding: 2px 9px; border-radius: 6px; color: var(--navy-dark); background: var(--blue-grey); }
.add-review summary { cursor: pointer; }
.add-review form { margin-top: 14px; }
.attorney-card { display: flex; gap: 18px; align-items: flex-start; }
.copy-field { font-size: 13px; color: var(--text-soft); }
.access-table td { vertical-align: middle; }
.access-email { overflow-wrap: anywhere; }
.access-role { display: flex; gap: 6px; align-items: center; }
.access-role select { width: auto; max-width: 100%; padding: 6px 8px; font-size: 14px; }
.access-buttons { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }

/* portraits: modest, face-preserving crop of ~300px sources */
.portrait { width: 96px; height: 113px; object-fit: cover; object-position: 50% 22%; border-radius: 8px; flex: none;
  border: 3px solid var(--navy-dark); box-shadow: 0 0 0 2px var(--gold), 0 6px 16px rgba(0,0,0,.35); }

/* ---------- client portal, intake, destination ---------- */
.demo-ribbon { background: var(--gold); color: var(--navy-dark); font-size: 14px; padding: 7px 16px; display: flex; justify-content: space-between; gap: 6px 16px; flex-wrap: wrap; }
.demo-ribbon strong { color: var(--navy-dark); }
.demo-ribbon a { color: var(--navy-dark); font-weight: 700; }
.ribbon-more { font-weight: 400; }
.masthead { display: flex; justify-content: center; padding: 30px 16px 26px; }
.masthead-inner { width: min(700px, 100%); display: flex; justify-content: center; }
.masthead-logo { width: 190px; height: auto; display: block; }
.portal { max-width: 720px; margin: 0 auto; padding: 0 16px 56px; }
.portal .card { padding: 24px 26px; }
.portal .welcome { border-top: 4px solid var(--gold); }
.portal .sub { font-size: 15px; }
.welcome h1 { font-size: 44px; margin: 22px 0 10px; }
.greeting { font-size: 18px; line-height: 1.65; margin: 0 0 10px; }
.signoff { color: var(--text-soft); margin: 0; font-style: italic; }
.attorney { display: flex; align-items: center; gap: 18px; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: 13px; color: var(--gold); font-weight: 700; }
.attorney-name { font-family: var(--display); font-size: 28px; color: var(--white); line-height: 1.1; letter-spacing: .01em; }
.num { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--gold); color: var(--navy-dark); font: 400 17px var(--display); margin-right: 8px; vertical-align: 3px; }
.destinations { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.destination { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 1.5px solid var(--line); border-left: 5px solid var(--gold); border-radius: 10px; text-decoration: none; color: var(--text-strong); background: var(--well); }
.destination strong { font-size: 17px; }
.destination:hover { border-color: var(--warm-white); border-left-color: var(--gold); color: var(--white); }
.destination span { color: var(--text-soft); font-size: 14px; }
.toggles { display: grid; gap: 8px; margin: 12px 0; }
.toggle-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--well); }
.toggle-row > div { min-width: 0; overflow-wrap: anywhere; }
.toggle-row.disabled { opacity: .75; }
.switch { position: relative; width: 78px; height: 34px; min-height: 34px; border-radius: 999px; background: var(--navy-mid); border: 1.5px solid var(--line-strong); padding: 0; justify-content: flex-end; flex: none; }
.switch .knob { position: absolute; left: 4px; top: 3px; width: 25px; height: 25px; border-radius: 50%; background: var(--blue-grey); box-shadow: 0 1px 3px rgba(0,0,0,.4); transition: left .15s; }
.switch .switch-text { font-size: 13px; font-weight: 700; color: var(--blue-grey); padding: 0 10px; }
.switch.on { background: var(--good-solid); border-color: var(--good); justify-content: flex-start; }
.switch.on .knob { left: 47px; background: var(--white); }
.switch.on .switch-text { color: var(--white); }
.switch:hover { border-color: var(--warm-white); background: var(--navy-mid); }
.switch.on:hover { background: #185A38; }
.snooze { border: 1.5px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 12px 0; background: var(--well); }
.snooze summary { cursor: pointer; }
.snooze form { margin-top: 12px; }
.end-actions { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.demo-warning { background: var(--warn-bg); border: 1px solid rgba(246, 184, 104, .4); border-radius: 10px; padding: 8px 12px; margin: 0 0 12px; font-size: 15px; }
.demo-example { display: inline-block; margin-top: 16px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--navy-dark); background: var(--gold); border-radius: 4px; padding: 2px 7px; }
.demo-example + h1 { margin-top: 8px; }
.auth { max-width: 520px; }
.auth .welcome h1 { font-size: 38px; margin: 4px 0 10px; }
.portal-foot { text-align: center; color: var(--blue-grey); font-size: 15px; margin-top: 28px; line-height: 1.7; }
.portal textarea + button, .portal form > button { margin-top: 10px; }

@media (max-width: 900px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .topbar, .clockbar, .demo-banner, .roster-banner { padding-left: 16px; padding-right: 16px; }
  .container { padding: 16px; }
  .topbar-logo { height: 60px; }
}
@media (max-width: 760px) {
  .topbar { gap: 8px 16px; }
  .nav { flex: 1 1 100%; order: 3; }
  .nav a { padding: 6px 9px; }
  .account { order: 2; }
  .clock-now { min-width: 0; flex: 1 1 100%; }
  .clock-actions { flex: 1 1 auto; }
  .clock-actions > button, .clock-set summary { padding: 7px 10px; min-height: 36px; }
}
@media (max-width: 760px) {
  /* Manage access: each account becomes a stacked card on phones. */
  .access-table, .access-table tbody { display: block; width: 100%; }
  .access-table thead { display: none; }
  .access-table tr { display: block; border-bottom: 1px solid var(--line-strong); padding: 8px 0; }
  .access-table tr:last-child { border-bottom: 0; }
  .access-table td { display: grid; grid-template-columns: 64px 1fr; gap: 10px; align-items: center; border: 0; padding: 6px 0; white-space: normal; }
  .access-table td::before { content: attr(data-label); font-size: 12px; text-transform: uppercase; letter-spacing: .07em; color: var(--text-soft); font-weight: 700; }
  .access-table td[colspan] { display: block; }
  .access-table td[colspan]::before { content: none; }
  .access-table .badge { white-space: normal; justify-self: start; }
  .access-role { flex-wrap: wrap; min-width: 0; }
  .access-role select { flex: 1 1 160px; min-width: 0; }
}
@media (max-width: 560px) {
  /* Anchor the date picker to the button row, not the wrapped button, so it stays on screen. */
  .clock-actions { position: relative; }
  .clock-set { position: static; }
  .clock-set-body { top: calc(100% + 6px); left: 0; width: min(250px, 100%); }
  h1 { font-size: 30px; }
  .form-grid { grid-template-columns: 1fr; }
  .masthead { padding: 22px 16px 20px; }
  .masthead-logo { width: 140px; }
  .portal { padding: 0 12px 44px; }
  .portal .card { padding: 20px 18px; }
  .welcome h1 { font-size: 36px; }
  .attorney-name { font-size: 24px; }
  .portrait { width: 80px; height: 94px; }
  .attorney-card { flex-direction: column; }
  .brand-title { font-size: 19px; }
  .account { width: 100%; justify-content: space-between; }
  .account-who { text-align: left; flex: 1 1 100%; }
  .auth .welcome h1 { font-size: 32px; }
  .ribbon-more { display: block; }
  /* Recompose the planes for tall, narrow screens */
  body {
    background-image:
      linear-gradient(135deg, transparent 0 62%, var(--navy-mid) 62% 100%),
      linear-gradient(20deg, var(--navy-mid) 0 12%, transparent 12% 100%);
  }
}
