﻿/* ==================== */
/* GLOBAL STYLES        */
/* ==================== */
:root {
    --MIN_WIDTH: 300px;
    --MAX_WIDTH: 1200px;
}

[v-cloak] {
    display: none;
}

* {
    margin: 0px;
    padding: 0px;
    box-sizing: border-box;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

body {
    background: #10384f;
    /*background-image: linear-gradient( 135deg, #10384f 65%, #00bcff 100%);*/
    background-image: linear-gradient(180deg, #10384F 12.98%, #0091E9 100%);
    font-size: 16px;
    min-width: var(--MIN_WIDTH);
}
body.poster {
    background: white;
}

/* LOADER */
#divLoading {
    width: 100%;
    height: 100vh;
}

#divLoading .loaderContainer {
    display: flex;
    gap: 10px;
    margin: 0 auto;
    height: 100%;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.loaderO {
    height: 45px;
}
#divLoading .text {
    font-size: 14px;
    line-height: normal;
    font-weight: bold;
    color: #10384F;
}
.loader {
    --c: no-repeat linear-gradient(#66B512 0 0);
    background: var(--c),var(--c),var(--c), var(--c),var(--c),var(--c), var(--c),var(--c),var(--c);
    background-size: 12px 12px;
    animation: l32-1 1s infinite, l32-2 1s infinite;
}
@keyframes l32-1 {
    0%,100% {width: 25px;height: 25px;}
    25%,75% {width: 45px;height: 45px;}
}
@keyframes l32-2 {
    0%,20% {background-position: 0 0,0 50%, 0 100%,50% 100%,100% 100%,100% 50%,100% 0,50% 0, 50% 50%;}
    80%,100% {background-position: 0 50%, 0 100%,50% 100%,100% 100%,100% 50%,100% 0,50% 0,0 0, 50% 50%;}
}

/* MAIN APP CONTAINER */
#app {
    margin: 0px auto;
    min-width: var(--MIN_WIDTH);
    max-width: var(--MAX_WIDTH);
}

/* ==================== */
/* POSTER PAGE STYLES   */
/* ==================== */
#content {
    display: none;
    list-style: none;
    margin-bottom: calc(var(--disclaimer-height, 120px) + 20px); /* allow space for disclaimer */
}

#content li {
    width: 100%;
    margin-bottom: 1.8vh;
    text-align: center;
}

#content li:first-child { 
    margin-top: calc(var(--menu-height, 90px) + 20px);  /* Uses CSS variable with 90px fallback, adds 20px buffer */
}

#content li img {
    display: inline-block;
}

#content li video {
    display: inline-block;
    cursor: pointer;
}

iframe, #content li img, #content li video {
    width: 90%;
    max-width: var(--MAX_WIDTH);
}

#divMenu {
    position: fixed;
    top: -14vh;
    left: 0;
    right: 0;
    width: 100%;
    min-height: 70px;
    background-color: #10384f;
    background-image: linear-gradient(180deg, #10384F 39.42%, #00617F 100%);
    color: white;
    z-index: 999;
    padding: 0 20px;
    min-width: var(--MIN_WIDTH);
}

.menu-container {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px;
    min-height: 70px;
    padding: 15px 0;
    margin: 0px auto;
    max-width: var(--MAX_WIDTH);
    align-items: start;
    justify-items: end;
}
.menu-home {
    grid-column: 1;
    grid-row: 1 / 3; /* Span both rows */
    align-self: start;
}
#icoBayer {
    width: 60px;
    height: 60px;
    transition: transform 0.3s;
    display: block;
}
.menu-links {
    grid-column: 2;
    grid-row: 2;
}
.navLinksContainer {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.navButtons {
    grid-column: 2;
    grid-row: 1;
}
.navButtons .navButton {
    display: inline-flex;
    background:#0091E9;
    clip-path: polygon(14% 0, 100% 0, 88% 100%, 0 100%);
    cursor: pointer;
    padding: 8px 40px 8px 20px;
    background-size: 20px 20px;
    background-repeat: no-repeat;
    background-position: center right 16px;
}
.navButtons .navButton.home {
    background-image: url(../assets/iconHome.png);
}
.navButtons .navButton.back {
    background-image: url(../assets/iconBack.png);
    background-color: #66B512;
}
.navButtons .navButton div {
    font-size: 14px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    color: #ffffff;
}
.navLinks {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
}
.navLinks .navLinkItem {
    cursor: pointer;
    font-size: 18px;
    font-style: normal;
    font-weight: 400;
    line-height: 1.4;
}
.menu-separator {
    display: inline;
    color: #00BCFF;
    user-select: none;
    padding: 0 6px;
    font-size: 18px;
    font-style: normal;
    font-weight: 400;
    line-height: 1.4;
}

.menu-break {
    width: 100%;
    height: 0;
    flex-basis: 100%;
}

/* Responsive Menu */
@media (max-width: 767px) {
    #divMenu {
        min-height: auto;
        padding: 0 10px;
    }

    .menu-container {
        display: grid;
        grid-template-columns: auto 1fr; /* logo takes space it needs, rest is flexible */
        grid-template-rows: auto auto; /* 2 rows */
        gap: 4px;
        align-items: center;
        min-height: auto;
        padding: 10px 0;
    }

    .menu-home {
        grid-column: 1;
        grid-row: 1;
    }

    #icoHome {
        width: 40px;
        height: 40px;
    }

    .menu-links {
        grid-column: 1 / -1; /* span both columns = full width */
        grid-row: 2;
        gap: 2px 10px;
        padding-top: 5px;
        justify-self: flex-start;
    }
    .navLinks {
        justify-content: flex-start;
    }

    .navButtons {
        grid-area: 1 / 2;
    }

    .navButtons .navButton {
        padding: 5px 40px 5px 20px;
        clip-path: polygon(10% 0, 100% 0, 90% 100%, 0 100%);
    }
    .navButtons .navButton div {
        font-size: 12px;
    }
    .menu-separator {
        padding: 0 4px;
    }
}
@media (max-width: 479px) {
    .navLinks .navLinkItem {
        font-size: 15px;
        line-height: 1.3;
    }

    .menu-separator {
        font-size: 15px;
        line-height: 1.3;
    }
    .card-grid {
        gap: 3vw!important;
    }
}

/* ELEMENTS */
.audio {outline: none;}

.pdf {
    width: 35% !important;
    min-width: 180px;
    cursor: pointer;
    max-width: 300px !important;
}

.molecule {
    width: 40% !important;
    margin-top: -4vh !important;
    margin-bottom: -4vh !important;
}

/* Custom Classes for Left To Right Transitions */
.LTR_HTRS2019_reding2_figure5 {
    width: 1812px;
    height: 1178px;
}

.disclaimerLink,
.disclaimerLink:visited {
    /*font-size: 14px;*/
    color: white;
}

/* ==================== */
/* LANDING PAGE STYLES  */
/* ==================== */
#divNoPosterSelected {
    width: 94%;
    min-height: 100vh;
    padding-bottom: 140px;
    text-align: center;
    max-width: var(--MAX_WIDTH);
    margin: 0 auto;
}

#divLogo {
    width: 100%;
    text-align: right;
    padding: 20px 0px;
    display: flex;
    justify-content: center;
}

#divLogo > div {
    width: 16vw;
    height: 16vw;
    min-width: 60px;
    min-height: 60px;
    max-width: 120px;
    max-height: 120px;
    background-image: url(../assets/logoBayer.png);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    cursor: pointer;
}

body.mainLanding #divLogo > div {cursor: default;}

.page-title {text-align: center;}
.page-title h1 {
    font-size: 24px;
    color: #ffffff;
    margin-bottom: 10px;
}
.congress-subtitle {
    line-height: 1.2;
    font-size: 16px;
    color: #ffffff;
}
.subtitle {
    color: #00BCFF;
    margin-bottom: 20px;
    font-size: 14px;
}

.divider {
    height: 1px;
    background-color: #ffffff;
    margin: 10px auto 20px auto;
}

.homeButton {
    background-color: #10384F;
    display: block;
    text-align: left;
    margin-left: 0;
    margin-right: auto;
    width: fit-content;
    color: #ffffff;
    padding: 10px 40px 10px 10px;
    background-image: url(../assets/iconHome.png);
    background-position: center right 14px;
    background-repeat: no-repeat;
    background-size: 20px 20px;
    font-size: 14px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    clip-path: polygon(0 0, 100% 0, 92% 100%, 0 100%);
    cursor: pointer;
}

/* Card Grid Layout */
.card-grid {
    display: grid;
    /*grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));*/
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.2vw;
    max-width: var(--MAX_WIDTH);
    margin: 0 auto 2vw auto;
    text-align: left;
    justify-content: center;
}

/* Card Styles */
.card {
    background: white;
    border-radius: 4px;
    padding: 15px;
    box-shadow: 0 3px 4px 0 rgba(0, 0, 0, 0.25);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    min-height: 180px;
    cursor: pointer;
    transform-origin: center center;
}
.card:hover {
    transform: scale(1.01);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}
.card.unavailable {
    /*opacity: 0.7;*/
    cursor: default;
}

.card.unavailable:hover {
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Pinned congress card styling */
.card.pinned {
    border: 2px solid #00BCFF;
    box-shadow: 0 0px 12px #00BCFF;
    /* make stretch whole grid container */
    grid-column: 1 / -1;
}

.card-header {
    flex-grow: 1;
    margin-bottom: 16px;
}

.card-title {
    font-size: 16px;
    font-weight: bold;
    color: #00617F;
    line-height: normal;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 10px;
}

.card-meta.poster-count {
    margin-top: 8px;
}

.congress-card .card-title {
    -webkit-line-clamp: 2;
}

.card-details {
    font-size: 14px;
    color: #0091E9;
    line-height: 1.5;
}

.card-meta {
    font-size: 14px;
    color: #0091E9;
}

.card-author {
    font-size: 14px;
    color: #0091E9;
    margin-top: 12px;
    font-weight: 500;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid #66B512;
}
.availability-notice {
    background: #E8E8E8;
    padding: 6px 10px;
    font-size: 14px;
    color: #10384F;
    margin-top: 12px;
    line-height: 1.5;
    clip-path: polygon(0 0, 100% 0, 96% 100%, 0 100%);
}
.availability-notice strong {display: block;}

/* Buttons */
.button {
    background-image: url(../assets/button_arrow.png);
    background-size: 22px 22px;
    background-repeat: no-repeat;
    background-position: center right 16px;
    background-color: #66B512;
    border: 0px;
    border-radius: 0px;
    color: white;
    padding: 10px 44px 10px 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 700;
    transition: all 0.3s;
    clip-path: polygon(0 0, 100% 0, 96% 100%, 0 100%);
}

body.mainLanding .card-grid .card-footer .button {
    /*margin: 0 0 0 auto;*/ /* right align view posters button */
}

.pdf-icon {
    width: 36px;
    height: 36px;
    background: #2B6636;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    cursor: pointer;
    flex-shrink: 0;
    background-image: url(../assets/posterShared/pdfIcon.png);
    background-size: contain;
    background-position: center right 2px;
    background-repeat: no-repeat;
    transform-origin: center;
    transition: 0.3s;
    clip-path: polygon(12% 0, 100% 0, 100% 100%, 0 100%);
    padding: 0px 45px 0px 0px;
}

/* ==================== */
/* FOOTER DISCLAIMER    */
/* ==================== */
.disclaimer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    background-color: #10384F;
    color: white;
    font-size: 12px;
    line-height: 16px;
    padding: 1vh 2.5%;
    text-align: center;
    z-index: 100;
}
/*.disclaimer.poster {
    background: #10384fee;
}*/
.disclaimer a {
    color: white;
    text-decoration: underline;
}
.privacyLinks {
    /*margin: 8px 0px 0px 0px;*/
}
.privacyLinks a {color: white;}

/* ==================== */
/* HCP OPT-IN MODAL     */
/* ==================== */
#hcp_optin {
    width: 100%;
    height: 100%;
    display: grid;
    position: fixed;
    top: 0px;
    left: 0px;
    align-content: center;
    align-items: center;
    justify-items: center;
    background: rgba(0,0,0,0.96);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 500ms ease-in-out;
}
#hcp_optin.active {
    visibility: visible !important;
    opacity: 1 !important;
}

#hcp_optin .inner {
    padding: 30px;
    text-align: center;
    background: white;
    border-radius: 10px;
    width: 90%;
    max-width: 600px;
    color: #000000;
    font-size: 18px;
    line-height: 1.6;
}

#hcp_optin .inner #hcp_optin_btn {
    max-width: 70%;
    margin: 0 auto;
    display: inline-block;
}

/* ==================== */
/* EMBEDDED PDF STYLES */
/* ==================== */
.pdf-containerOuter {
    position: relative;
    padding: 0px 0px 40px 0px;
    width: 94%;
    max-width: var(--MAX_WIDTH);
    margin: 0 auto;
    display: inline-block;
}
.pdf-container {
    width:100%;
    display: inline-block;
    background: #fafafa;
    border: 1px solid #9f9f9f;
    min-height: 36vh;
    max-height: 68vh;
    height: 68vh;
    overflow: hidden;
}

.pdf-loading {
    min-height: 36vh; /* Match container */
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
}
.pdf-loading > div {
    color: #000000;
    font-size: clamp(12px, 3vw, 22px);
}
.pdf-error {
    min-height: 36vh; /* Match container */
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffebee;
    color: #c62828;
}
.pdf-viewport {
    width: 100%;
    height: 100%;
    overflow: hidden;
    position: relative;
    cursor: grab;
    user-select: none;
}
.pdf-viewport:active {cursor: grabbing;}
.pdf-wrapper {transform-origin: 0 0;}
/* Override image constraints for PDF */
.pdf-container img {
    width: 100% !important;
    max-width: none !important;
    height: auto !important;
}
/* Edge fade indicators */
.edge-arrow {
    width: 16px;
    height: 16px;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="rgba(0,0,0,1)"><path d="M3 19 L12 5 L21 19 Z"/></svg>');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}
/* Rotate for each direction (base arrow points UP) */
.pdf-edge-top .edge-arrow {
    transform: rotate(0deg); /* Up */
}

.pdf-edge-right .edge-arrow {
    transform: rotate(90deg); /* Right */
}

.pdf-edge-bottom .edge-arrow {
    transform: rotate(180deg); /* Down */
}

.pdf-edge-left .edge-arrow {
    transform: rotate(270deg); /* Left */
}

.pdf-edge-fade {
    position: absolute;
    pointer-events: none;
    z-index: 5;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdf-edge-fade.active {
    opacity: 1;
    pointer-events: auto;
}

.pdf-edge-fade.active:hover {
    cursor: pointer;
}

.pdf-edge-fade.active:hover .edge-arrow {color: #ff0000;}

.pdf-edge-fade .edge-arrow {
    color: #000000;
    font-size: 16px;
    /*text-shadow: 0 0 4px #ffffff;*/
    transition: all 200ms ease-in-out;
}

.pdf-edge-top {
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to bottom, rgba(255,255,255,0.9), rgba(255,255,255,0));
}

.pdf-edge-right {
    top: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to left, rgba(255,255,255,0.9), rgba(255,255,255,0));
}

.pdf-edge-bottom {
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(255,255,255,0.9), rgba(255,255,255,0));
}

.pdf-edge-left {
    top: 0;
    left: 0;
    bottom: 0;
    background: linear-gradient(to right, rgba(255,255,255,0.9), rgba(255,255,255,0));
}

/* ==================== */
/* MINI-MAP */
/* ==================== */

/* Container (wrapper) */
.pdf-minimap-container {
    position: absolute;
    bottom: 46px;
    right: 5px;
    z-index: 10;
    pointer-events: none;
}

/* Minimap (controlled by active class on container) */
.pdf-minimap {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid #ccc;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.5);
    padding: 0px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

/* Toggle button */
.minimap-toggle {
    position: absolute;
    bottom: -40px;
    right: -5px;
    width: 45px;
    height: 30px;
    cursor: pointer;
    filter: drop-shadow(0px 0px 4px rgba(0, 0, 0, 0.45));
    z-index: 15;
    pointer-events: auto;
    transition: top 0.3s ease, bottom 0.3s ease;
    background-image: url(../assets/minimapOpen.png);
    background-size: 45px 30px;
    background-position: center center;
    background-repeat: no-repeat;
}

.pdf-minimap-container.active .minimap-toggle {
    background-image: url(../assets/minimapClose.png);
}

/* Button moves to top when minimap open */
.pdf-minimap-container.active .minimap-toggle {
    bottom: auto;
    top: -30px;
}

.pdf-minimap-container.active .pdf-minimap {
    opacity: 1;
    pointer-events: auto;
}

.pdf-page-separator {
    /*margin: .2% 0; DONT USE MARGIN ELSE THROWS CALCULATIONS OFF */
    padding: .2% 0px;
}
.pdf-page-separator span {
    display: block;
    background: #10384F;
    padding: .75%;
    text-align: center;
    color: #ffffff;
    font-weight: bold;
    font-size: 1vw;

}
/* Minimap canvas */
.minimap-canvas {
    display: block;
    cursor: pointer;
}
/* Default for mobile */
.minimap-canvas {
    display: block;
    cursor: pointer;
    width: 192px;
    max-height: 52vh; /*200px;*/ /* Limit for tall PDFs */
}
/* Desktop */
@media (min-width: 768px) {
    .minimap-canvas {
        width: 260px;
        /*max-height: 240px;*/
    }
}
/* Large desktop */
@media (min-width: var(--MAX_WIDTH)) {
    .minimap-canvas {
        width: 380px;
        /*max-height: 300px;*/
    }
}

/* Viewport box */
.minimap-viewport-box {
    position: absolute;
    cursor: grab;
    background: rgba(0, 186, 237, 0.1);
    border: 2px solid #ff0000;
    pointer-events: auto;
}

.minimap-viewport-box:active {cursor: grabbing;}

/* ==================== */
/* RESPONSIVE           */
/* ==================== */

/* Tablet breakpoint - keep menu stable */
@media (min-width: 768px) and (max-width: 1024px) {
    #divMenu {
        min-height: 80px;
    }

    .menu-container {
        gap: 15px;
    }

    #icoHome {
        width: 45px;
        height: 45px;
    }
}

/* mobile (incl tablet etc) */
@media (max-width: 767px) {
    .page-title h1 {
        font-size: 28px;
    }

    .card {
        min-height: 160px;
    }

    .card-title {
        font-size: 16px;
        -webkit-line-clamp: 6; /* try and allow whole title on mobile */
    }

    .congress-card .card-title {
        font-size: 18px;
    }

    .disclaimer {
        font-size: 11px;
        line-height: 12px;
        padding: 2% 2.5%;
    }

    #divNoPosterSelected {
        padding-bottom: 120px;
    }

    .menu-break {
        display: none !important;
    }
}
/* small mobiles */
@media (max-width: 359px) {
    .disclaimer {font-size: 10px;}
    .card .card-title {font-size: 14px;}
    .card .card-details {font-size:12px;}
    .card .card-author {font-size: 12px;}
    .card .card-meta {font-size: 12px;}
    .card .availability-notice {font-size: 12px;}
    .button {padding: 6px 44px 6px 10px;}
    .pdf-icon {
        width: 28px;
        height: 28px;
        padding: 0px 35px 0px 0px;
    }
    .pdf-containerOuter {
        width: 86%;
    }
    .pdf-container {
        height: 62vh;
    }
}