/* Shared visual treatment; visibility, positioning and modal stacking stay owned by each module. */
body select:not([multiple]):not([size]),
body select[size="1"] {
  min-height: 42px;
  border: 1px solid #bac5ce;
  border-radius: 6px;
  padding: 9px 12px;
  font: inherit;
  font-size: 0.95rem;
  line-height: 1.4;
  color: #223239;
  background-color: #fff;
  box-shadow: 0 1px 2px rgb(20 35 40 / 4%);
  max-width: 100%;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}
body select[multiple], body select[size]:not([size="1"]) {
  border: 1px solid #bac5ce;
  border-radius: 6px;
  padding: 8px;
  color: #223239;
  background-color: #fff;
}
body select:focus-visible {
  outline: 2px solid #087c77;
  outline-offset: 2px;
  border-color: #087c77;
}
body select:disabled { opacity: 0.6; cursor: not-allowed; }
body select option, body select optgroup { color: #223239; background: #fff; }

body .tabs-cat > .tabs-cat__panel,
body[data-cf-role] .tabs-cat > .tabs-cat__panel {
  padding: 8px;
  gap: 3px;
  border: 1px solid #d4dcdf;
  border-radius: 8px !important;
  background: #fff;
  box-shadow: 0 12px 32px rgb(20 35 40 / 18%);
  overscroll-behavior: contain;
  scrollbar-width: thin;
}
body .tabs-cat__panel .tab,
body[data-cf-role] .tabs-cat__panel .tab {
  min-height: 42px;
  padding: 10px 12px;
  border-radius: 4px !important;
  font-size: 0.94rem;
  font-weight: 600;
  line-height: 1.4;
  white-space: normal;
  overflow-wrap: anywhere;
  transition: background-color 140ms ease;
}
body[data-cf-role] .tabs-cat__panel .tab:hover,
body[data-cf-role] .tabs-cat__panel .tab:focus-visible,
body[data-cf-role] .tabs-cat__panel .tab.active {
  background: #eaf4f2 !important;
  color: #17534f !important;
  border-left-color: #087c77 !important;
}
body .tabs-cat__panel .tab:focus-visible { outline: 2px solid #087c77; outline-offset: -2px; }

body :is(.modal__card, .modal, .library-ccc__modal-dialog,
  .surveys-app__modal-dialog, .public-voting-modal__dialog, .modal-dialog, dialog),
body[data-cf-role] :is(.modal__card, .modal, .library-ccc__modal-dialog,
  .surveys-app__modal-dialog, .public-voting-modal__dialog, .modal-dialog, dialog) {
  border-radius: 8px;
  border-color: #cbd5da;
  box-shadow: 0 20px 64px rgb(15 30 35 / 24%), 0 2px 8px rgb(15 30 35 / 8%);
  letter-spacing: 0;
  overflow-wrap: anywhere;
}
body :is(.modal__card, .library-ccc__modal-dialog, .surveys-app__modal-dialog) {
  background: #fff;
  color: #223239;
}
body :is(.modal__head, .library-ccc__modal-head, .surveys-app__modal-head, .public-voting-modal__head),
body[data-cf-role] :is(.modal__head, .library-ccc__modal-head, .surveys-app__modal-head, .public-voting-modal__head) {
  padding: 18px 22px;
  gap: 16px;
  border-bottom: 1px solid #dce3e5;
  align-items: center;
}
body :is(.modal__title, .library-ccc__modal-head h3, .surveys-app__modal-head h2),
body[data-cf-role] :is(.modal__title, .library-ccc__modal-head h3, .surveys-app__modal-head h2) {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.4;
  margin: 0;
  min-width: 0;
  border-bottom: 0;
  padding-bottom: 0;
}
body :is(.modal__body, .library-ccc__modal-body, .surveys-app__modal-body) {
  padding: 22px;
  line-height: 1.55;
}
body :is(.modal__head, .library-ccc__modal-head, .surveys-app__modal-head) > button {
  flex-shrink: 0;
  min-height: 36px;
  border-radius: 6px;
  color: #33454c !important;
  background: #f3f6f7 !important;
  border: 1px solid #cbd5da;
}
body :is(.modal__head, .library-ccc__modal-head, .surveys-app__modal-head) > button:focus-visible {
  outline: 2px solid #087c77;
  outline-offset: 2px;
}
body :is(.modal__card, .library-ccc__modal-dialog, .surveys-app__modal-dialog) {
  max-height: 90vh;
  max-height: 90dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}
body .library-ccc__modal-actions,
body .public-voting-modal__actions {
  padding: 16px 22px;
  gap: 10px;
  flex-wrap: wrap;
}
#regSuccessCard { padding: 24px; }
.parent-email-hint { margin: 12px 0 0; line-height: 1.55; }
@media (max-width: 600px) {
  body :is(.modal__head, .library-ccc__modal-head, .surveys-app__modal-head, .public-voting-modal__head),
  body[data-cf-role] :is(.modal__head, .library-ccc__modal-head, .surveys-app__modal-head, .public-voting-modal__head) {
    padding: 14px 16px; gap: 10px;
  }
  body :is(.modal__body, .library-ccc__modal-body, .surveys-app__modal-body) { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  body select, body .tabs-cat__panel .tab { transition: none; }
}
@media print {
  body :is(.modal__card, .modal, .library-ccc__modal-dialog, .surveys-app__modal-dialog, dialog) {
    box-shadow: none; max-height: none; overflow: visible;
  }
}
