.safety-table-3-wrapper {
  width: 100%;
  padding-bottom: 2px;
  overflow-x: auto;
}

.safety-table-3 {
  --st3-purple: #3A134C0D;
  --st3-header-purple: #39134b;
  --st3-pink: #ff084d;
  --st3-text: rgba(0, 0, 0, 0.7);
  --st3-stripe: #f5f3f6;
  --st3-border: #b0c8d5;
  --st3-white: #ffffff;
  width: 100%;
  margin: 0 auto;
  table-layout: fixed;
  border-collapse: collapse;
  color: var(--st3-text);
  background: var(--st3-white);
  font-family: "Roboto", sans-serif;
}

/* Desktop Figma: 939 / 328 / 329 across the 1596px table. */
.safety-table-3 .description-column { width: 58.84%; }
.safety-table-3 .hibsago-column { width: 20.55%; }
.safety-table-3 .placebo-column { width: 20.61%; }
.safety-table-3 th,
.safety-table-3 td { box-sizing: border-box; }

.safety-table-3 thead th {
  height: 70px;
  padding: 9px 18px;
  vertical-align: middle;
}
.safety-table-3 .table-title {
  color: var(--st3-text);
  background: var(--st3-white);
  text-align: left;
  font-size: 16px !important;
  line-height: 44px;
  font-weight: 700;
  border: 0;
}
.safety-table-3 .treatment-heading {
  color: var(--st3-white);
  background: var(--st3-pink);
  text-align: center;
  font-size: 16px !important;
  line-height: 44px;
  font-weight: 700;
  border-right: 1px solid var(--st3-white);
}
.safety-table-3 .treatment-heading:last-child { border-right: 0; }
.safety-table-3 .treatment-heading .treatment-main {
  color: #ffffff !important;
  font-family: "Roboto", sans-serif !important;
  font-size: inherit !important;
  font-weight: inherit !important;
  line-height: inherit !important;
}

.safety-table-3 tbody th,
.safety-table-3 tbody td {
  height: 50px;
  padding: 10px 18px;
  vertical-align: middle;
  font-size: 16px;
  line-height: 24px;
  font-weight: 400;
  border-right: 1px solid var(--st3-border);
}
.safety-table-3 tbody th { text-align: left; }
.safety-table-3 tbody td { text-align: center; white-space: nowrap; }
.safety-table-3 tbody td:last-child { border-right: 0; }
.safety-table-3 tbody tr:nth-child(odd) th,
.safety-table-3 tbody tr:nth-child(odd) td {
  color: var(--st3-text);
  background: var(--st3-white);
}
.safety-table-3 tbody tr:nth-child(even) th,
.safety-table-3 tbody tr:nth-child(even) td {
  color: #000000;
  background: var(--st3-purple);
}

/* Desktop-only body text size. */
@media (min-width: 768px) {
  .safety-table-3 tbody th,
  .safety-table-3 tbody td {
    font-size: 14px !important;
  }
}

@media (min-width: 768px) and (max-width: 1439px) {
  .safety-table-3 .treatment-heading { font-size: 16px; }
  .safety-table-3 .treatment-main { white-space: nowrap; }
}

@media (max-width: 767px) {
  .safety-table-3-wrapper { overflow: visible; }
  .safety-table-3 {
    width: calc(100% + 40px);
    margin-left: -20px;
  }
  /* Mobile Figma: 190 / 90 / 80 across the 360px table. */
  .safety-table-3 .description-column { width: 52.7778%; }
  .safety-table-3 .hibsago-column { width: 25%; }
  .safety-table-3 .placebo-column { width: 22.2222%; }
  .safety-table-3 thead th {
    padding: 18px 4px !important;
  }
  .safety-table-3 .table-title {
    font-size: 12px !important;
    line-height: 14px !important;
    font-weight: 400;
  }
  .safety-table-3 .treatment-heading {
    background: var(--st3-header-purple);
    font-size: 12px !important;
    line-height: 16px !important;
    font-weight: 400;
  }
  .safety-table-3 .treatment-main { white-space: normal; }
  .safety-table-3 tbody th,
  .safety-table-3 tbody td {
    height: 58px;
    padding: 5px 10px;
    font-size: 12px !important;
    line-height: 14px !important;
    border-right: 1px solid var(--st3-white);
    border-bottom: 1px solid var(--st3-white);
  }
  .safety-table-3 tbody tr:first-child th,
  .safety-table-3 tbody tr:first-child td { height: 68px; }
  .safety-table-3 tbody th { overflow-wrap: break-word; }
  .safety-table-3 tbody td { padding-inline: 4px; white-space: nowrap; }
  /* Mobile Figma alternates brand pink and #F5F3F6. */
  .safety-table-3 tbody tr:nth-child(odd) th,
  .safety-table-3 tbody tr:nth-child(odd) td {
    color: var(--st3-text);
    background: var(--st3-pink);
  }
  .safety-table-3 tbody tr:nth-child(even) th,
  .safety-table-3 tbody tr:nth-child(even) td {
    color: var(--st3-text);
    background: var(--st3-stripe);
  }
  .safety-table-3 tbody tr:last-child th,
  .safety-table-3 tbody tr:last-child td { border-bottom: 0; }
}

/* Preserve the adjacent Figma Content Block surface. */
.lab-abnormalities-details {
  margin-top: 0;
  margin-bottom: 0;
  background-color: #ffffff !important;
  color: #39134b;
}
ul.lab-abnormalities-details > li,
ul.lab-abnormalities-details > li > p,
#lab-abnormalities-details,
#lab-abnormalities-details > div,
#lab-abnormalities-details .lab-abnormalities-details {
  background-color: #ffffff !important;
}

/* Lock desktop Figma theming against global rich-text/table overrides. */
@media (min-width: 768px) {
  .safety-table-3 .table-title { color: rgba(0, 0, 0, 0.7) !important; background-color: #ffffff !important; }
  .safety-table-3 .treatment-heading { color: #ffffff !important; background-color: #ff084d !important; }
  .safety-table-3 tbody tr:nth-child(odd) th,
  .safety-table-3 tbody tr:nth-child(odd) td { color: rgba(0, 0, 0, 0.7) !important; background-color: #ffffff !important; }
  .safety-table-3 tbody tr:nth-child(even) th,
  .safety-table-3 tbody tr:nth-child(even) td { color: #000000B2 !important; background-color: #3A134C0D !important; }
}

/* Mobile Figma dark theme with accessible foreground text. */
@media (max-width: 767px) {
  .safety-table-3 .table-title { color: rgba(0, 0, 0, 0.7) !important; background-color: #ffffff !important; }
  .safety-table-3 .treatment-heading { color: #ffffff !important; background-color: #39134b !important; }
  .safety-table-3 tbody tr:nth-child(odd) th,
  .safety-table-3 tbody tr:nth-child(odd) td { color: #ffffff !important; background-color: #39134b !important; }
  .safety-table-3 tbody tr:nth-child(even) th,
  .safety-table-3 tbody tr:nth-child(even) td { color: rgba(0, 0, 0, 0.7) !important; background-color: #f5f3f6 !important; }
}

/* Final mobile Figma row theme and header weight. */
@media (max-width: 767px) {
  .safety-table-3 .table-title {
    font-weight: 700 !important;
  }
  .safety-table-3 tbody tr:nth-child(odd) th,
  .safety-table-3 tbody tr:nth-child(odd) td {
    color: #000000B2 !important;
    background-color: #ffffff !important;
  }
  .safety-table-3 tbody tr:nth-child(even) th,
  .safety-table-3 tbody tr:nth-child(even) td {
    color: #000000B2 !important;
    background-color: #3A134C0D !important;
  }
}

/* Figma: all table-header cells use 700 weight on desktop and mobile. */
.safety-table-3 thead th,
.safety-table-3 thead th * {
  font-weight: 700 !important;
}


/* Mobile first-row typography, colors and vertical padding. */
@media (max-width: 767px) {
  .safety-table-3 thead > tr:first-child > th {
    font-family: "Roboto", sans-serif !important;
    font-size: 12px !important;
    line-height: 16px !important;
    padding-top: 12px !important;
    padding-bottom: 12px !important;
  }
  .safety-table-3 thead > tr:first-child > th span {
    font-family: "Roboto", sans-serif !important;
    font-size: 12px !important;
    line-height: 16px !important;
  }
  .safety-table-3 thead > tr:first-child > th.table-title {
    color: rgba(0, 0, 0, 0.7) !important;
    background-color: #ffffff !important;
  }
  .safety-table-3 thead > tr:first-child > th.treatment-heading,
  .safety-table-3 thead > tr:first-child > th.treatment-heading span {
    color: #ffffff !important;
  }
  .safety-table-3 thead > tr:first-child > th.treatment-heading {
    background-color: #39134b !important;
  }
}


/* Mobile header geometry and unbroken parenthetical phrases. */
@media (max-width: 767px) {
  .safety-table-3 .description-column { width: 52.77777778%; }
  .safety-table-3 .hibsago-column { width: 25%; }
  .safety-table-3 .placebo-column { width: 22.22222222%; }
  .safety-table-3 thead > tr:first-child > th {
    height: 82px !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
    word-break: normal !important;
    overflow-wrap: normal !important;
    hyphens: none !important;
  }
  .safety-table-3 thead > tr:first-child > th .mobile-header-parenthetical {
    white-space: nowrap !important;
    word-break: normal !important;
    overflow-wrap: normal !important;
  }
  .safety-table-3 thead > tr:first-child > th .mobile-header-wrap {
    display: inline !important;
  }
}

/* Rounded outer corners, matching the study-design table. */
.safety-table-3 {
  border-collapse: separate;
  border-spacing: 0;
}
.safety-table-3 thead > tr:first-child > .treatment-heading:nth-child(2) {
  border-top-left-radius: 24px;
}
.safety-table-3 thead > tr:first-child > .treatment-heading:last-child {
  border-top-right-radius: 24px;
}
.safety-table-3 tbody > tr:last-child > :first-child {
  border-bottom-left-radius: 24px;
}
.safety-table-3 tbody > tr:last-child > :last-child {
  border-bottom-right-radius: 24px;
}
