.mfub-book-card{background:linear-gradient(145deg,#185487,#0b2d4c);border-radius:17px;overflow:hidden;box-shadow:0 10px 28px rgba(10,35,65,.14);height:100%;display:flex;flex-direction:column;transition:transform .25s ease,box-shadow .25s ease;color:#fff}
.mfub-book-card:hover{transform:translateY(-4px);box-shadow:0 16px 36px rgba(10,35,65,.22)}
.mfub-book-cover{height:260px;background:#09263e;display:flex;justify-content:center;align-items:center;padding:19px;box-sizing:border-box}
.mfub-book-cover img{height:100%;width:100%;object-fit:contain;display:block}
.mfub-book-placeholder{text-align:center;color:#fdcf0c;font:700 22px/1.4 Arial,sans-serif}
.mfub-book-info{padding:23px 24px 25px;display:flex;flex-direction:column;align-items:flex-start;flex:1;gap:12px}
.mfub-book-rule{height:3px;width:42px;background:#fdcf0c;border-radius:4px}
.mfub-book-card .mfub-book-info h3{font:700 19px/1.4 Montserrat,Arial,sans-serif!important;color:#fff!important;margin:0!important;font-style:normal!important}
.mfub-book-card .mfub-book-author{font:400 14px/1.6 Arial,sans-serif!important;color:#d9e7f2!important;margin:0!important}
.mfub-book-open{margin-top:auto;background:transparent!important;border:1px solid rgba(255,255,255,.5)!important;border-radius:8px;color:#fff!important;padding:9px 13px;cursor:pointer;font:600 13px Arial,sans-serif!important}
.mfub-book-open:hover,.mfub-book-open:focus-visible{background:#fdcf0c!important;color:#092b49!important;border-color:#fdcf0c!important}
.mfub-book-modal[hidden]{display:none!important}
.mfub-book-modal{position:fixed;inset:0;z-index:999999;display:flex;align-items:center;justify-content:center;padding:20px;box-sizing:border-box}
.mfub-book-backdrop{position:absolute;inset:0;background:rgba(4,20,35,.77)}
.mfub-book-dialog{position:relative;z-index:1;width:min(860px,100%);max-height:min(88vh,900px);overflow:auto;background:#fff;border-radius:18px;padding:34px;box-shadow:0 25px 70px rgba(0,0,0,.3);box-sizing:border-box;outline:none}
.mfub-book-close{position:absolute;right:15px;top:12px;border:0;background:#edf3f7;color:#123b5e;font-size:26px;line-height:1;width:37px;height:37px;border-radius:50%;cursor:pointer}
.mfub-book-dialog-content{display:grid;grid-template-columns:minmax(130px,210px) 1fr;gap:30px;align-items:start}
.mfub-book-dialog-cover{width:100%;max-height:320px;object-fit:contain;border-radius:8px;background:#f3f6f8}
.mfub-book-dialog-label{color:#12568d;font:700 12px Arial,sans-serif;letter-spacing:1.5px;text-transform:uppercase}
.mfub-book-dialog h2{font:700 27px/1.3 Montserrat,Arial,sans-serif!important;color:#10365a!important;margin:12px 0!important;font-style:normal!important}
.mfub-book-dialog-author{color:#587184;font:600 15px Arial,sans-serif;margin:0 0 20px}
.mfub-book-description{color:#33485a;font:400 15px/1.75 Arial,sans-serif;overflow-wrap:anywhere}
@media(max-width:600px){.mfub-book-cover{height:220px}.mfub-book-dialog{padding:55px 20px 22px}.mfub-book-dialog-content{grid-template-columns:1fr;gap:20px}.mfub-book-dialog-cover{max-height:200px}.mfub-book-dialog h2{font-size:22px!important}}

/* v1.1: Full viewport modal, independent of Avada container clipping */
body > .mfub-book-modal:not([hidden]){
  position:fixed!important;
  inset:0!important;
  width:100vw!important;
  height:100vh!important;
  height:100dvh!important;
  z-index:2147483000!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:clamp(12px,3vh,28px)!important;
  margin:0!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
  transform:none!important;
}
body > .mfub-book-modal .mfub-book-backdrop{position:absolute;inset:0;z-index:0}
body > .mfub-book-modal .mfub-book-dialog{
  position:relative!important;
  z-index:1!important;
  flex:0 1 860px!important;
  width:100%!important;
  max-width:860px!important;
  max-height:100%!important;
  overflow-x:hidden!important;
  overflow-y:auto!important;
  overscroll-behavior:contain;
  padding:54px 32px 32px!important;
  box-sizing:border-box!important;
}
body > .mfub-book-modal .mfub-book-close{
  position:sticky!important;
  top:0!important;
  float:right!important;
  margin-top:-39px!important;
  margin-right:-16px!important;
  z-index:5!important;
  flex-shrink:0;
}
body > .mfub-book-modal .mfub-book-dialog-content{clear:both;min-width:0}
body > .mfub-book-modal .mfub-book-dialog-content > div{min-width:0}
@media(max-width:600px){
 body > .mfub-book-modal:not([hidden]){padding:10px!important}
 body > .mfub-book-modal .mfub-book-dialog{padding:50px 19px 24px!important;border-radius:13px!important}
 body > .mfub-book-modal .mfub-book-close{margin-right:-4px!important}
}

/* v1.2: spacing between rows of publication cards */
.mfub-book-card{margin-bottom:26px!important;height:calc(100% - 26px)!important;box-sizing:border-box!important}

/* v1.3: justified publication description text (modal only) */
.mfub-book-modal .mfub-book-description p,
.mfub-book-modal .mfub-book-description li {
  text-align: justify !important;
  text-justify: inter-word;
  hyphens: auto;
}

/* v1.4: force justified text inside the expanded publication window only */
body > .mfub-book-modal .mfub-book-dialog .mfub-book-description,
body > .mfub-book-modal .mfub-book-dialog .mfub-book-description p,
body > .mfub-book-modal .mfub-book-dialog .mfub-book-description li,
body > .mfub-book-modal .mfub-book-dialog .mfub-book-description div {
  text-align: justify !important;
  text-justify: inter-word !important;
  hyphens: auto;
}

/* v1.5: full-width content when no book cover is supplied */
.mfub-book-modal .mfub-book-dialog-content.mfub-book-no-cover,
body > .mfub-book-modal .mfub-book-dialog-content.mfub-book-no-cover {
  display:block!important;
  grid-template-columns:none!important;
  width:100%!important;
}
.mfub-book-modal .mfub-book-dialog-content.mfub-book-no-cover > div {
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
}

/* v1.6: optional responsive YouTube video below modal description */
.mfub-book-modal .mfub-book-video{margin-top:25px;max-width:100%}
.mfub-book-modal .mfub-book-video h3{font-size:18px!important;line-height:1.35!important;margin:0 0 12px!important;color:#12568d!important;text-align:left!important}
.mfub-book-modal .mfub-book-video-frame{position:relative;width:100%;aspect-ratio:16/9;overflow:hidden;border-radius:12px;background:#09263f}
.mfub-book-modal .mfub-book-video-frame iframe{position:absolute;inset:0;width:100%!important;height:100%!important;border:0!important}


/* v1.9: static first-page PDF cover on desktop and mobile */
.mfub-book-modal .mfub-book-pdf{margin-top:28px;min-width:0;font-family:'Montserrat',Arial,sans-serif}
.mfub-book-modal .mfub-book-pdf-heading h3{font-family:inherit!important;font-size:19px!important;line-height:1.35!important;font-weight:700!important;color:#12568d!important;text-align:left!important;margin:0 0 15px!important}
.mfub-book-modal .mfub-book-pdf-cover{display:flex;align-items:center;justify-content:center;max-width:100%;width:100%;min-height:220px;padding:20px;background:#f4f7fa;border:1px solid #dbe5ed;border-radius:13px;overflow:hidden;text-decoration:none!important}
.mfub-book-modal .mfub-book-pdf-cover img{display:block!important;width:auto!important;max-width:100%!important;height:auto!important;max-height:420px!important;object-fit:contain!important;object-position:center!important;border-radius:3px;box-shadow:0 9px 26px rgba(12,39,64,.15)}
.mfub-book-modal .mfub-book-pdf-fallback{display:flex;flex-direction:column;gap:12px;align-items:center;justify-content:center;color:#48647b;text-align:center!important;font-size:13px!important}
.mfub-book-modal .mfub-book-pdf-fallback strong{font-size:25px!important;color:#12568d!important}
.mfub-book-modal .mfub-book-pdf-link{display:inline-flex!important;align-items:center;justify-content:center;gap:8px;margin-top:15px;padding:12px 22px;background:#12568d;color:#fff!important;border-radius:9px;font-family:inherit!important;font-size:14px!important;font-weight:700!important;text-decoration:none!important}
.mfub-book-modal .mfub-book-pdf-link:hover{background:#0b2942}
@media(max-width:767px){
 .mfub-book-modal .mfub-book-pdf-cover{padding:15px;min-height:180px}
 .mfub-book-modal .mfub-book-pdf-cover img{max-height:310px!important}
 .mfub-book-modal .mfub-book-pdf-link{width:100%}
}
