/* Patient Summary: the editor on the left, a US Letter preview on the right. */

.summary-layout { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 24px; align-items: start; }
.summary-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.summary-changed { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.summary-changed > span:first-child { color: oklch(0.5 0.11 70); }
.summary-changed-text { flex: 1; }
.summary-changed-text b { font-weight: 600; }
.summary-changed form { margin: 0; }
.summary-form { display: flex; flex-direction: column; gap: 16px; margin: 0; }
.summary-editor textarea {
  display: block;
  width: 100%;
  min-height: 280px;
  padding: 18px 20px;
  border: 0;
  border-radius: var(--radius-card);
  background: transparent;
  font-size: var(--text-md);
  line-height: 1.6;
  resize: vertical;
}
.summary-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.summary-prints h2 { margin: 0 0 6px; font-size: var(--text-md); font-weight: 600; }
.summary-prints ul { margin: 0; padding-left: 18px; font-size: var(--text-base); color: var(--text-secondary); }

.summary-preview { display: flex; justify-content: center; padding: 24px; border-radius: var(--radius-card); background: #e9e8e3; }
.summary-paper {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  max-width: 360px;
  aspect-ratio: 8.5 / 11;
  padding: 28px 26px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.12);
  font-size: 10px;
  line-height: 1.55;
}
.summary-paper-head { display: flex; justify-content: space-between; padding-bottom: 8px; border-bottom: 1px solid var(--border-divider); }
.summary-paper-head b { font-size: var(--text-xs); }
.summary-paper-head span, .summary-paper-for { color: var(--text-tertiary); }
.summary-paper .summary-text { white-space: pre-wrap; overflow-wrap: anywhere; }

@media (max-width: 60rem) {
  .summary-layout { grid-template-columns: minmax(0, 1fr); }
}

/* The Patient Summary printed as plain text on paper. */
.summary-print { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.5; }
.print-page main { max-width: 42rem; margin: 0 auto; padding: 1.5rem 1rem; }
.print-controls { display: flex; align-items: center; gap: 0.5rem; }
@media print {
  .print-controls { display: none; }
  .print-page { background: #fff; color: #000; }
  .print-page main { max-width: none; padding: 0; }
  .summary-print { font-size: 12pt; }
}

