/* Interactive controls across the branded application shells. */
.brand-site {
  --brand-control-border: #658479;
  --brand-focus: #12496d;
  --brand-error: #b42318;
  --field-border: var(--brand-control-border);
}

.brand-site :where(main, .report-issue-modal) .btn:not(.primary, .danger, .ghost) {
  border-color: var(--brand-control-border);
  color: var(--green);
}

.brand-site :where(main, .report-issue-modal) .btn:not(.primary, .danger, .ghost, :disabled, [aria-disabled="true"]):hover {
  background: var(--mint);
}

.brand-site .btn.primary:not(:disabled, [aria-disabled="true"]):active {
  background: #054e38;
}

.brand-site :where(main, .report-issue-modal) .btn:not(.primary, .danger, .ghost, :disabled, [aria-disabled="true"]):active {
  background: #cfeee1;
}

.brand-site .btn:is(:disabled, [aria-disabled="true"]),
.brand-site .btn.primary:is(:disabled, [aria-disabled="true"]) {
  background: #edf1ef;
  border-color: #adbcb6;
  color: #43564e;
  cursor: not-allowed;
}

.brand-site .btn:disabled:not(.primary, .danger, .ghost),
.brand-site .btn[aria-disabled="true"]:not(.primary, .danger, .ghost) {
  color: #43564e;
}

.brand-site :is(
  input:not([type="checkbox"], [type="radio"], [type="hidden"], [type="submit"], [type="button"], [type="file"]),
  select, textarea
) {
  border-radius: 11px;
}

.brand-site :is(input, select, textarea)::placeholder { color: var(--muted); }
.brand-site :is(input, select, textarea)[aria-invalid="true"] { border-color: var(--brand-error); }
.brand-site :is(input, select, textarea):disabled { background: #edf1ef; color: #43564e; }

.brand-site :is(
  input:not([type="checkbox"], [type="radio"], [type="hidden"], [type="submit"], [type="button"], [type="file"]),
  select, textarea, .outline-lesson-link, .report-issue-close, .report-issue-fab
):focus-visible {
  outline: 3px solid var(--brand-focus);
  outline-offset: 3px;
}

.brand-site .report-issue-modal { border-radius: 18px; }
.brand-site .report-issue-close { min-width: 44px; min-height: 44px; }
.brand-site .report-issue-fab { box-shadow: 0 4px 14px rgb(15 27 61 / .18); }
.brand-site .report-issue-fab:is(:hover, :focus) { background: #066346; }
.brand-site .report-issue-message.success { color: var(--green); }
.brand-site .report-issue-message.error { color: var(--brand-error); }
.brand-site .report-upload-box { border-color: var(--brand-control-border); }
.brand-site .form-row:has(input[type="file"]:focus-visible) .report-upload-box {
  outline: 3px solid var(--brand-focus);
  outline-offset: 3px;
}

.brand-site dialog {
  border-color: var(--line);
  color: var(--ink);
}
.brand-site dialog::backdrop { background: rgb(15 27 61 / .52); }
.brand-site .lesson-body :where(table, pre, figure) { max-inline-size: 100%; }
.brand-site .lesson-body :where(pre, .table-wrap) { overflow-x: auto; }
