/* MEDIPHARM 1.14.2 — Layout recovery layer.
   Kept separate from the historical compiled cascade; do not mutate module data or routes. */
body.syh-v1142-home #syh-app.syh-home-v1142 {
  --syh142-max: 1260px;
  --syh142-edge: 24px;
  --syh142-line: #d5e3ec;
  --syh142-ink: #15354d;
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 *,
body.syh-v1142-home #syh-app.syh-home-v1142 *::before,
body.syh-v1142-home #syh-app.syh-home-v1142 *::after { box-sizing: border-box; }
/* The historical homepage uses a three-track grid (gutter/content/gutter).
   Footer lives outside that grid, causing sections to be narrower than footer. */
body.syh-v1142-home #syh-app.syh-home-v1142 > main {
  display:block !important;
  min-width:0 !important;
}
/* Reset historical per-section widths before applying the shared shell width. */
body.syh-v1142-home #syh-app.syh-home-v1142 > main > section {
  width:100% !important;
  min-width:0 !important;
  max-width:100% !important;
  margin-left:0 !important;
  margin-right:0 !important;
  padding-left:0 !important;
  padding-right:0 !important;
  box-sizing:border-box !important;
}
/* ONE canvas across hero, shortcuts, library, clinical, language, QA and footer. */
body.syh-v1142-home #syh-app.syh-home-v1142 > main > section > .syh-shell,
body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer > .syh-shell {
  width: min(var(--syh142-max), calc(100% - var(--syh142-edge) * 2)) !important;
  min-width: 0 !important;
  max-width: var(--syh142-max) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  box-sizing: border-box !important;
}
body.syh-v1142-home :is(.syh-home-inspiration,.mpi-section) > .mpi-shell,
body.syh-v1142-home :is(.syh-home-inspiration,.mpi-section) > .syh-shell {
  width: min(1260px, calc(100% - 48px)) !important;
  max-width: 1260px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  box-sizing: border-box !important;
}
/* Provider blocks already nested inside the homepage use their parent's content width. */
body.syh-v1142-home #syh-app.syh-home-v1142 :is(.syh-home-inspiration,.mpi-section) > :is(.mpi-shell,.syh-shell) {
  width:100% !important;
  max-width:100% !important;
  min-width:0 !important;
  margin-left:0 !important;
  margin-right:0 !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 > main > section > .syh-shell > *,
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-catalog,
body.syh-v1142-home #syh-app.syh-home-v1142 :is(.syh-parent-category-grid,.syh-library-grid,.syh-tool-grid,.syh-learning-feature-grid) {
  min-width: 0 !important;
  max-width: 100% !important;
}
/* CATEGORY DECK: preserve exactly the available 1, 2, or 3 covers in a stacked fan. */
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-grid {
  display: grid !important;
  grid-template-columns: repeat(4,minmax(0,1fr)) !important;
  gap: 14px !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card {
  min-width: 0 !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
  border-radius: 18px !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-media {
  position: relative !important;
  display: block !important;
  flex: 0 0 auto !important;
  width: 100% !important;
  height: 184px !important;
  aspect-ratio: auto !important;
  min-height: 0 !important;
  overflow: hidden !important;
  background: linear-gradient(180deg,#fcfeff,#eef7fa) !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-media > span.syh-category-deck {
  position: absolute !important;
  inset: 0 !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: visible !important;
  background: transparent !important;
  grid-template-columns: none !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-media img.syh-category-deck-ghost {display:none!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-media .syh-category-deck > img.syh-category-deck-cover {
  position: absolute !important;
  inset: auto auto 8px 50% !important;
  display: block !important;
  width: 44% !important;
  max-width: 124px !important;
  min-width: 0 !important;
  height: 82% !important;
  min-height: 0 !important;
  max-height: none !important;
  border-radius: 9px !important;
  border: 1px solid rgba(180,204,218,.7) !important;
  background: #fff !important;
  object-fit: cover !important;
  object-position: center 18% !important;
  box-shadow: 0 12px 22px rgba(20,50,75,.16) !important;
  filter: none !important;
  transform-origin: 50% 95% !important;
  transition: transform .22s ease !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-category-deck--count-3 > img.syh-category-deck-cover--1 {transform:translateX(-99%) rotate(-12deg)!important;z-index:1!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-category-deck--count-3 > img.syh-category-deck-cover--2 {transform:translateX(-50%) rotate(-1deg)!important;z-index:3!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-category-deck--count-3 > img.syh-category-deck-cover--3 {transform:translateX(0%) rotate(11deg)!important;z-index:2!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-category-deck--count-2 > img.syh-category-deck-cover--1 {transform:translateX(-80%) rotate(-9deg)!important;z-index:1!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-category-deck--count-2 > img.syh-category-deck-cover--2 {transform:translateX(-18%) rotate(8deg)!important;z-index:2!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-category-deck--count-1 > img.syh-category-deck-cover {transform:translateX(-50%) rotate(-1deg)!important;z-index:2!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-footer {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 8px !important;
  min-width: 0 !important;
  width: 100% !important;
  min-height: 60px !important;
  padding: 10px 12px !important;
}
/* RANKED BOOKS: remove left/right clipped portrait. Each jacket fully visible. */
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-filters {
  display: flex !important;
  flex-wrap: nowrap !important;
  overflow-x: auto !important;
  max-width: 100% !important;
  gap: 8px !important;
  scrollbar-width: none !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-filters button {flex:0 0 auto!important;white-space:nowrap!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-grid {
  display: grid !important;
  grid-template-columns: repeat(4,minmax(0,1fr)) !important;
  gap: 14px !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-grid > .syh-library-card:not([hidden]) {
  display: flex !important;
  flex-direction: column !important;
  min-width: 0 !important;
  height: auto !important;
  min-height: 0 !important;
  border-radius: 18px !important;
  overflow: hidden !important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card[hidden] {display:none!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card a.syh-book-cover {
  position:relative!important;
  display:flex!important;
  flex:0 0 auto!important;
  align-items:center!important;
  justify-content:center!important;
  width:100%!important;
  height: clamp(230px,24vw,318px)!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:auto!important;
  padding: 14px!important;
  overflow:hidden!important;
  background:linear-gradient(160deg,#f7fbfe 0%,#eaf3f8 100%)!important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-book-cover > img.syh-book-cover-ghost {display:none!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-book-cover > img.syh-book-cover-primary {
  position:relative!important;
  inset:auto!important;
  display:block!important;
  flex:0 1 auto!important;
  width:auto!important;
  height:100%!important;
  max-width:100%!important;
  max-height:100%!important;
  min-width:0!important;
  min-height:0!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  border-radius:6px!important;
  object-fit:contain!important;
  object-position:center!important;
  background:transparent!important;
  box-shadow:0 12px 22px rgba(21,55,84,.15)!important;
  transform:none!important;
  transition:transform .25s ease!important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-library-copy {
  display:flex!important;flex-direction:column!important;gap:8px!important;
  min-width:0!important;flex:1 1 auto!important;
  min-height:0!important;padding:13px 13px 12px!important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-library-copy h3 {
  font-size:15px!important;line-height:1.45!important;
  overflow-wrap:break-word!important;
  display:-webkit-box!important;-webkit-box-orient:vertical!important;-webkit-line-clamp:3!important;overflow:hidden!important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-library-card-action {margin-top:auto!important;}
/* Restore compact, consistent lower modules without decorative line art. */
body.syh-v1142-home #syh-app.syh-home-v1142 :is(.syh-tools-section,.syh-learning-entry-section,.syh-clinical-qa-section) > .syh-shell {padding:22px!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 :is(.syh-tools-section,.syh-learning-entry-section) :is(.syh-tool-grid,.syh-learning-feature-grid) {display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:14px!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-tools-section .syh-tool-card {min-height:250px!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-tools-section .syh-tool-visual,
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature-preview {display:none!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature {
  display:flex!important;flex-direction:column!important;align-items:flex-start!important;
  min-width:0!important;height:100%!important;min-height:226px!important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature-cta {margin-top:auto!important;max-width:calc(100% - 35px)!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature-arrow {pointer-events:none!important;}
/* Footer remains aligned to the same canvas; text and chips cannot collide. */
body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer > .syh-footer-grid {
  display:grid!important;
  grid-template-columns:minmax(0,1.5fr) minmax(0,.7fr) minmax(0,.7fr)!important;
  gap:20px!important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer .syh-footer-branding,
body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer .syh-footer-nav {min-width:0!important;}
body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer .syh-footer-pills {
  display:flex!important;flex-wrap:wrap!important;gap:8px!important;
  padding:0!important;margin:0!important;list-style:none!important;
}
body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer .syh-footer-pills > li {
  display:inline-flex!important;align-items:center!important;min-height:30px!important;
  padding:5px 10px!important;white-space:normal!important;
  list-style:none!important;
}
@media (hover:hover) and (pointer:fine) {
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card:hover .syh-book-cover > img.syh-book-cover-primary {transform:scale(1.045)!important;}
}
@media(max-width:1080px) {
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section :is(.syh-parent-category-grid,.syh-library-grid),
  body.syh-v1142-home #syh-app.syh-home-v1142 :is(.syh-tools-section,.syh-learning-entry-section) :is(.syh-tool-grid,.syh-learning-feature-grid) {grid-template-columns:repeat(2,minmax(0,1fr))!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer > .syh-footer-grid {grid-template-columns: minmax(0,1fr) minmax(0,1fr)!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer .syh-footer-branding {grid-column:1/-1!important;}
}
@media(max-width:650px) {
  body.syh-v1142-home #syh-app.syh-home-v1142 {--syh142-edge:12px;}
  body.syh-v1142-home :is(.syh-home-inspiration,.mpi-section) > .mpi-shell,
  body.syh-v1142-home :is(.syh-home-inspiration,.mpi-section) > .syh-shell {width:calc(100% - 24px)!important;max-width:calc(100% - 24px)!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section > .syh-shell,
  body.syh-v1142-home #syh-app.syh-home-v1142 :is(.syh-tools-section,.syh-learning-entry-section,.syh-clinical-qa-section) > .syh-shell {padding:14px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-grid {grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:9px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-media {height:138px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-media .syh-category-deck > img.syh-category-deck-cover {
    width:45%!important;max-width:74px!important;height:79%!important;bottom:8px!important;border-radius:7px!important;
  }
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-footer {min-height:57px!important;padding:9px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-parent-category-card-label {font-size:12px!important;line-height:1.35!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-grid {grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card a.syh-book-cover {height:clamp(175px,52vw,230px)!important;padding:9px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-book-cover > img.syh-book-cover-primary {width:auto!important;height:100%!important;max-width:100%!important;max-height:100%!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-library-copy {padding:11px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-library-copy h3 {font-size:12.5px!important;line-height:1.42!important;-webkit-line-clamp:3!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-library-copy > span {font-size:10px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 :is(.syh-tools-section,.syh-learning-entry-section) :is(.syh-tool-grid,.syh-learning-feature-grid) {grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature {min-height:198px!important;padding:12px!important;gap:10px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature-copy strong {font-size:14px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature-copy small {font-size:12px!important;line-height:1.48!important;-webkit-line-clamp:3!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature-cta {max-width:calc(100% - 28px)!important;min-height:30px!important;font-size:11px!important;padding-inline:10px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-learning-entry-section .syh-learning-feature-arrow {right:10px!important;bottom:10px!important;width:24px!important;height:24px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-tools-section .syh-tool-card {min-height:220px!important;padding:13px!important;gap:10px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-tools-section .syh-tool-card h3 {font-size:14px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-tools-section .syh-tool-card .syh-tool-summary {font-size:12px!important;line-height:1.48!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer > .syh-footer-grid {grid-template-columns:1fr!important;gap:12px!important;padding:18px!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer .syh-footer-branding {grid-column:auto!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 > footer.syh-footer > .syh-footer-bottom {flex-direction:column!important;gap:8px!important;padding:15px!important;}
}
@media(max-width:355px) {
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-grid {grid-template-columns:1fr!important;}
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card a.syh-book-cover {height:235px!important;}
}
@media(prefers-reduced-motion:reduce) {
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-library-card .syh-book-cover > img.syh-book-cover-primary,
  body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section .syh-category-deck-cover {transition:none!important;}
}
/* DARK mode uses solid contrast, does not depend on the previous pastel accents. */
:is(html.tvm-dark,html.yhlsm-dark,html.nah-sdp-dark-mode,html.nah-sdp-night-active,html.nah-sdp-night-mode,html[data-theme="dark"]) body.syh-v1142-home #syh-app.syh-home-v1142 .syh-library-section :is(.syh-parent-category-card-media,.syh-book-cover) {background:linear-gradient(180deg,#173043,#102538)!important;}
