/* Share access by code. Scoped to the mount id so the shell's own p and li sizes do not win. */
/* On a phone the dialog is a sheet and its close sits in the corner, over the title's first line; the
   header keeps clear of it as the shared row header does. */
#akashic-health-records-patient-portal-root .share-access[data-close-button="true"] [data-slot="dialog-header"] {
  padding-right: 3rem;
}

#akashic-health-records-patient-portal-root .share-access-terms {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 18px;
  list-style: disc;
  color: var(--ink);
}

#akashic-health-records-patient-portal-root .share-access-showing {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

/* Big enough for a phone camera across a desk, never wider than a 390 screen allows. */
#akashic-health-records-patient-portal-root .share-access-qr {
  width: min(240px, 70vw);
  height: auto;
  border: 1px solid var(--line-soft);
}

#akashic-health-records-patient-portal-root .share-access-code {
  margin: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 28px;
  letter-spacing: 0.08em;
  color: var(--ink-strong);
}

#akashic-health-records-patient-portal-root .share-access-hint,
#akashic-health-records-patient-portal-root .share-access-note {
  margin: 0;
  color: var(--ink-muted);
  text-align: start;
}

#akashic-health-records-patient-portal-root .share-access-deciding {
  display: grid;
  gap: 10px;
}

#akashic-health-records-patient-portal-root .share-access-claimant {
  display: grid;
  gap: 2px;
  margin: 0;
}
#akashic-health-records-patient-portal-root .share-access-claimant dt {
  color: var(--ink-muted);
}
#akashic-health-records-patient-portal-root .share-access-claimant dd {
  margin: 0 0 6px;
  color: var(--ink-strong);
  overflow-wrap: anywhere;
}

#akashic-health-records-patient-portal-root .share-access-warning {
  margin: 0;
  color: var(--destructive);
}

#akashic-health-records-patient-portal-root .share-access-doc-toggle {
  justify-self: start;
}

#akashic-health-records-patient-portal-root .share-access-document {
  max-height: 40vh;
  overflow: auto;
  margin: 0;
  padding: 10px;
  white-space: pre-wrap;
  font-family: inherit;
  border: 1px solid var(--line-soft);
  background: var(--surface);
  color: var(--ink);
}

#akashic-health-records-patient-portal-root .share-access-agree {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  cursor: pointer;
}

#akashic-health-records-patient-portal-root .share-access-history {
  display: grid;
  gap: 6px;
  padding-top: 10px;
  border-top: 1px solid var(--line-soft);
}
#akashic-health-records-patient-portal-root .share-access-history-title {
  margin: 0;
  color: var(--ink-strong);
}
#akashic-health-records-patient-portal-root .share-access-history ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
#akashic-health-records-patient-portal-root .share-access-history li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 12px;
  color: var(--ink);
  overflow-wrap: anywhere;
}
#akashic-health-records-patient-portal-root .share-access-history-actions {
  display: flex;
  gap: 12px;
}
#akashic-health-records-patient-portal-root .share-access-history .share-access-document {
  flex-basis: 100%;
}
