@font-face {
  font-family: Montserrat;
  src: url("/brand/montserrat-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
:root {
  color-scheme: light;
  --ink: #1b2026;
  --muted: #515a65;
  --line: #dce0e6;
  --blue: #214eab;
  --error: #a02921;
  --serif: "Palatino Linotype", Palatino, Georgia, serif;
  --amber-ink: #7a4d00; --amber-bg: #fff1cf; --ok: #1d6b3a; --soft: #f7f8fa;
  font: 15px/1.55 Montserrat, system-ui, sans-serif;
  color: var(--ink);
  background: white;
}
* { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
button, select, input, textarea { font: inherit; color: inherit; }
button, select, summary { cursor: pointer; }
button:focus-visible, select:focus-visible, summary:focus-visible,
textarea:focus-visible, input:focus-visible, .dropzone:focus-within {
  outline: 3px solid #345db7;
  outline-offset: 3px;
}
p, h1, h2, dl, ul { margin: 0; }
.masthead { border-top: 3px solid var(--ink); border-bottom: 1px solid var(--line); }
.bar, main { width: min(100% - 72px, 1056px); margin: 0 auto; }
.bar { min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.identity { display: flex; align-items: center; gap: 20px; }
.identity img { display: block; width: 104px; height: auto; }
.partner { border-left: 1px solid #c9cdd2; padding-left: 20px; font-size: 15px; font-weight: 600; }
.account { display: flex; align-items: center; gap: 18px; font-size: 13px; flex-wrap: wrap; }
.account a { color: var(--blue); font-weight: 600; text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.account a:hover { text-decoration: underline; text-underline-offset: 3px; }
.who { color: var(--muted); overflow-wrap: anywhere; }
.text-button { border: 0; background: none; padding: 4px 0; font-size: 13px; font-weight: 600; color: var(--blue); min-height: 44px; }
.text-button:hover { text-decoration: underline; text-underline-offset: 3px; }
main { padding: 44px 0 64px; }
.intro { padding-bottom: 24px; border-bottom: 1px solid var(--line); }
h1 { font: 400 clamp(36px, 4.1vw, 52px)/1.12 var(--serif); letter-spacing: -.035em; }
h1:focus { outline: none; }
.intro > p:last-child, .lead { margin-top: 10px; color: var(--muted); max-width: 680px; }
.status { color: var(--muted); font-size: 13px; padding: 16px 0 6px; }
.status:empty { display: none; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-size: 13px; font-weight: 600; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--ink); }
td { padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
td.name { font-weight: 600; }
td.num { white-space: nowrap; font-variant-numeric: tabular-nums; }
td.mk { color: var(--muted); }
td.act { text-align: right; width: 1%; white-space: nowrap; }
.left { display: inline-block; padding: 3px 9px; border-radius: 4px; background: #eef2f8; font-weight: 600; font-size: 14px; }
.left.soon { background: var(--amber-bg); color: var(--amber-ink); }
.refund { min-height: 40px; padding: 7px 18px; border-radius: 5px; border: 1px solid var(--ink); background: white; font-weight: 600; font-size: 14px; }
.refund:hover { background: var(--soft); }
.sent { color: var(--ok); font-weight: 600; font-size: 14px; }
.warn { color: var(--error); font-weight: 600; font-size: 14px; }
.back { display: inline-flex; margin-bottom: 14px; }
.layout { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(260px, 1fr); gap: clamp(36px, 7vw, 92px); align-items: start; padding-top: 30px; }
.field { margin-bottom: 21px; }
label { display: block; font-weight: 650; font-size: 14px; margin-bottom: 7px; }
select, textarea, input[type=email], input[type=text], input[type=search] { width: 100%; min-height: 44px; padding: 9px 12px; border: 1px solid #88919c; background: white; border-radius: 5px; line-height: 1.5; }
textarea { resize: vertical; }
.hint, .before-input, .guide > p, details p { color: var(--muted); font-size: 13px; line-height: 1.6; }
.hint { margin-top: 6px; }
.before-input { margin: -2px 0 9px; }
.dropzone { display: flex; align-items: center; justify-content: center; gap: 14px; position: relative; padding: 22px 14px; border: 1px dashed #8593aa; border-radius: 6px; background: #fafbfd; }
.dropzone:hover, .dropzone.over { border-color: var(--blue); background: #f1f5fc; }
.file-glyph { display: grid; place-items: center; flex: 0 0 30px; height: 34px; border: 1px solid #b1bccc; border-radius: 3px; font: 22px/1 system-ui; color: #455978; background: white; }
.browse { color: var(--blue); display: inline; margin: 0; font-size: 14px; }
.drag-hint { font-size: 13px; color: var(--muted); }
#file-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
#attachments { list-style: none; padding: 0; margin-top: 8px; }
#attachments li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 14px; border-bottom: 1px solid var(--line); font-size: 13px; }
#attachments span { overflow-wrap: anywhere; }
#attachments .size { color: var(--muted); white-space: nowrap; }
.submit-row { border-top: 1px solid var(--line); padding-top: 19px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.submit-row .hint { margin: 0; }
.primary { display: inline-flex; justify-content: center; align-items: center; gap: 14px; min-height: 46px; border-radius: 5px; padding: 11px 18px; background: var(--ink); color: white; border: 1px solid var(--ink); font-size: 14px; font-weight: 600; }
.primary:hover { background: #354150; }
.primary:disabled { opacity: .6; cursor: progress; }
.primary span { font-size: 18px; line-height: 1; }
.guide { background: var(--soft); border-radius: 7px; padding: 23px 24px 12px; }
.guide h2 { font: 400 27px/1.2 var(--serif); letter-spacing: -.025em; }
.guide > p { margin: 5px 0 16px; }
details { border-top: 1px solid var(--line); }
summary { display: flex; align-items: center; justify-content: space-between; gap: 8px; list-style: none; min-height: 43px; font-weight: 550; font-size: 13px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: #52647b; font: 19px/1 system-ui; }
details[open] summary::after { content: "−"; }
details p { padding: 0 10px 13px 0; }
.error { color: var(--error); font-size: 13px; font-weight: 550; margin-top: 6px; }
[aria-invalid="true"], .dropzone:has([aria-invalid="true"]) { border-color: var(--error); }
.single { max-width: 600px; }
.done { color: var(--ok); font-weight: 650; font-size: 13px; margin-bottom: 10px; }
.single .lead { margin-bottom: 26px; }
.single .primary { margin-top: 22px; }
dl { border-block: 1px solid var(--line); padding: 6px 0; }
dl > div { display: grid; grid-template-columns: 140px 1fr; gap: 12px; padding: 9px 0; }
dt { color: var(--muted); font-size: 13px; }
dd { margin: 0; font-weight: 550; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.r0-only { display: inline-block; font-size: 12px; font-weight: 650; color: var(--blue); background: #edf2fb; border-radius: 4px; padding: 2px 8px; margin-bottom: 10px; }
h2.section { font: 400 26px/1.2 var(--serif); letter-spacing: -.02em; margin: 34px 0 6px; }
.count { font: 600 13px/1 Montserrat, sans-serif; color: var(--muted); margin-left: 6px; vertical-align: middle; }
.sub { display: block; color: var(--muted); font-size: 13px; }
.note { font-style: italic; }
.doc a { color: var(--blue); font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.visually-hidden { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; white-space: nowrap; }
@media (max-width: 760px) {
  .bar, main { width: calc(100% - 40px); }
  main { padding: 28px 0 40px; }
  .layout { grid-template-columns: 1fr; gap: 28px; padding-top: 22px; }
  .identity { gap: 12px; } .identity img { width: 82px; }
  .partner { padding-left: 12px; font-size: 14px; }
  .bar { min-height: 60px; gap: 4px 8px; padding: 6px 0; }
  .account { gap: 14px; }
  select, textarea, input { font-size: 16px; }
  #cases thead, .stack thead { display: none; }
  #cases tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
  #cases td { border: 0; padding: 0; }
  #cases td.name { grid-column: 1; font-size: 16px; }
  #cases td.num { grid-column: 1; font-size: 13px; color: var(--muted); }
  #cases td.mk { grid-column: 1; font-size: 13px; }
  #cases td.mk:empty { display: none; }
  #cases td.mk::before { content: attr(data-l) " "; }
  #cases td.num::before { content: attr(data-l) " "; }
  #cases td.num .left { margin-left: 4px; font-size: 13px; }
  #cases td.act { grid-column: 2; grid-row: 1 / span 4; align-self: center; }
  .stack tr { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .stack td { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 10px; border: 0; padding: 4px 0; white-space: normal; }
  .stack td::before { content: attr(data-l); color: var(--muted); font-size: 13px; }
}
@media (max-width: 390px) {
  .bar, main { width: calc(100% - 32px); }
  .submit-row { align-items: flex-start; flex-direction: column; gap: 7px; }
  dl > div { grid-template-columns: 1fr; gap: 2px; }
}

/* Sign-in */
.signin { max-width: 460px; }
.signin form { margin-top: 18px; }
.signin .lead { margin: 0 0 20px; }
.signin .submit-row { gap: 18px; }
input.code { font-size: 22px; letter-spacing: .3em; font-variant-numeric: tabular-nums; max-width: 220px; }

/* Find a client: a combobox over the open cases */
.finder { position: relative; max-width: 420px; padding: 20px 0 4px; }
.finder label { display: block; font-weight: 600; margin-bottom: 7px; }
.finder input { padding-left: 36px; background: white url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%23515a65' stroke-width='2'%3E%3Ccircle cx='7' cy='7' r='5'/%3E%3Cpath d='m11 11 4 4'/%3E%3C/svg%3E") no-repeat 12px center; }
.suggestions { position: absolute; z-index: 5; left: 0; right: 0; margin: 4px 0 0; padding: 4px 0; list-style: none; background: white; border: 1px solid #88919c; border-radius: 5px; box-shadow: 0 8px 24px rgb(27 32 38 / .12); max-height: 300px; overflow-y: auto; }
.suggestions li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 12px; min-height: 44px; align-items: center; cursor: pointer; }
.suggestions li[aria-selected="true"], .suggestions li:hover { background: #eef2f8; }
.suggestions mark { background: none; color: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.suggestions .meta { color: var(--muted); font-size: 13px; white-space: nowrap; }
.suggestions .none { color: var(--muted); cursor: default; }

/* The document the chosen reason needs, asked for before the upload */
.before-input.ask { background: #eef2f8; border-left: 3px solid var(--blue); padding: 10px 12px; color: var(--ink); border-radius: 0 5px 5px 0; margin-bottom: 8px; }

/* Other reason: the warning Vinay asked for (from the preview) */
#other-reason-dialog { width: min(520px, calc(100% - 32px)); max-height: calc(100% - 32px); border: 1px solid var(--line); border-top: 5px solid #99701d; border-radius: 8px; padding: clamp(20px, 4vw, 32px); background: white; color: var(--ink); }
#other-reason-dialog::backdrop { background: rgb(16 24 36 / 58%); }
#other-reason-title { font: 400 clamp(26px, 4vw, 32px)/1.15 var(--serif); letter-spacing: -.02em; }
#other-reason-guidance { margin: 14px 0 24px; }
.dialog-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.dialog-actions .secondary { background: white; border: 1px solid #88919c; border-radius: 5px; min-height: 46px; padding: 10px 16px; font-size: 14px; font-weight: 600; }
@media (max-width: 500px) { .dialog-actions button { width: 100%; } }

/* r0's view-as switch and the banner that says whose view this is */
.viewas { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); }
.viewas select { width: auto; min-height: 36px; padding: 4px 10px; font-size: 13px; font-weight: 600; color: var(--ink); }
.as-banner { margin: 0 0 22px; padding: 10px 14px; border-radius: 5px; background: var(--amber-bg); color: var(--amber-ink); font-size: 14px; font-weight: 550; }
