.exam-laterality {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 12px;
  padding: 10px 12px;
  border: 1px solid #d8cbea;
  border-radius: 11px;
  background: #faf7ff;
}

.exam-laterality[hidden] { display: none; }
.exam-laterality > strong { color: #51377a; font-size: 12px; }
.exam-laterality > div { display: flex; flex-wrap: wrap; gap: 6px; }

.exam-laterality button {
  border: 1px solid #cbbce1;
  border-radius: 999px;
  background: #fff;
  color: #62458b;
  padding: 7px 10px;
  font: inherit;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.exam-laterality button.active {
  border-color: #7045ad;
  background: #7045ad;
  color: #fff;
  box-shadow: 0 0 0 2px rgba(112, 69, 173, .12);
}

@media (max-width: 560px) {
  .exam-laterality { align-items: flex-start; flex-direction: column; }
  .exam-laterality > div { width: 100%; }
  .exam-laterality button { flex: 1; }
}

.procedure-state-option {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 6px 7px 6px 11px;
  border: 1px solid #cad8d4;
  border-radius: 10px;
  background: #fff;
  color: #49635d;
  font-size: 12px;
}

.procedure-state-option > div { display: flex; gap: 4px; }
.procedure-state-option button {
  border: 1px solid #d2ddda;
  border-radius: 999px;
  background: #f7faf9;
  color: #607771;
  padding: 6px 8px;
  font: inherit;
  font-size: 10px;
  font-weight: 900;
  cursor: pointer;
}

.procedure-state-option button.present.active { border-color: #197a65; background: #197a65; color: #fff; }
.procedure-state-option button.absent.active { border-color: #a64b42; background: #a64b42; color: #fff; }
.procedure-state-option:has(.present.active) { border-color: #65aa98; background: #eff9f6; }
.procedure-state-option:has(.absent.active) { border-color: #d19a91; background: #fff4f1; }

@media (max-width: 620px) {
  .procedure-state-option { grid-template-columns: 1fr; }
  .procedure-state-option > div button { flex: 1; }
}

.blank-document-disclosure {
  margin: 0 0 20px;
  border: 1px solid #d6e3df;
  border-radius: 16px;
  background: #f8fbfa;
  overflow: hidden;
}

.blank-document-disclosure > summary {
  padding: 14px 18px;
  color: #244a42;
  font-size: 14px;
  font-weight: 850;
  cursor: pointer;
  list-style-position: inside;
}

.blank-document-disclosure .blank-document-grid { padding: 0 14px 14px; }

.pdf-segmented {
  position: absolute;
  z-index: 5;
  display: grid;
  grid-template-columns: repeat(var(--segments), minmax(0, 1fr));
  align-items: stretch;
  gap: 0;
}

.pdf-segmented.date {
  grid-template-columns: repeat(2, minmax(0, 1fr)) calc(5px * var(--zoom)) repeat(2, minmax(0, 1fr)) calc(5px * var(--zoom)) repeat(4, minmax(0, 1fr));
}

.pdf-segmented.date input:nth-child(1) { grid-column: 1; }
.pdf-segmented.date input:nth-child(2) { grid-column: 2; }
.pdf-segmented.date input:nth-child(3) { grid-column: 4; }
.pdf-segmented.date input:nth-child(4) { grid-column: 5; }
.pdf-segmented.date input:nth-child(5) { grid-column: 7; }
.pdf-segmented.date input:nth-child(6) { grid-column: 8; }
.pdf-segmented.date input:nth-child(7) { grid-column: 9; }
.pdf-segmented.date input:nth-child(8) { grid-column: 10; }

.pdf-segmented input {
  width: 100%;
  min-width: 0;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 1px;
  outline: 0;
  background: transparent;
  color: #000;
  font: 800 calc(7.6px * var(--zoom))/1 Arial, sans-serif;
  text-align: center;
}

.pdf-segmented input:hover { border-color: rgba(177,129,20,.38); background: rgba(255,245,155,.3); }
.pdf-segmented input:focus { border-color: #d39a27; background: rgba(255,252,220,.78); box-shadow: 0 0 0 1px rgba(211,154,39,.18); }
.pdf-page.show-guides .pdf-segmented input { border-color: rgba(20,125,112,.48); background: rgba(71,174,158,.1); }
.pdf-page[data-document="aih"] .pdf-segmented input { font-size: calc(8px * var(--zoom)); }

@media print {
  .pdf-segmented input { border-color: transparent !important; background: transparent !important; }
}

.respiratory-negative-detail {
  display: grid;
  gap: 9px;
  margin: -4px 0 10px 18px;
  padding: 12px;
  border: 1px solid #e0cbc6;
  border-left: 3px solid #b86658;
  border-radius: 0 11px 11px 11px;
  background: #fff8f6;
}

.respiratory-negative-detail > strong { color: #7d3e35; font-size: 11px; }
.respiratory-negative-detail > div { display: grid; grid-template-columns: minmax(145px, .55fr) 1fr; align-items: center; gap: 9px; }
.respiratory-negative-detail span { color: #6f544f; font-size: 11px; font-weight: 750; }
.respiratory-negative-detail > div > div { display: flex; flex-wrap: wrap; gap: 5px; }

.respiratory-negative-detail button {
  border: 1px solid #d8c3be;
  border-radius: 999px;
  background: #fff;
  color: #72544e;
  padding: 6px 9px;
  font: inherit;
  font-size: 10px;
  font-weight: 850;
}

.respiratory-negative-detail button.active { border-color: #a24e42; background: #a24e42; color: #fff; }

@media (max-width: 620px) {
  .respiratory-negative-detail { margin-left: 0; }
  .respiratory-negative-detail > div { grid-template-columns: 1fr; }
}
