/**
 * Memed Fullscreen Styles
 * Makes Memed prescription interface occupy full screen
 */

/* Memed container - fullscreen overlay with highest specificity */
div#mdhub-module-plataforma\.prescricao,
#mdhub-module-plataforma\.prescricao {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    max-width: 100vw !important;
    max-height: 100vh !important;
    min-width: 100vw !important;
    min-height: 100vh !important;
    z-index: 10000 !important;
    background: white !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    transform: none !important;
}

/* Parent containers should not restrict Memed */
#iframe-container:has(#mdhub-module-plataforma\.prescricao),
div:has(> #mdhub-module-plataforma\.prescricao) {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 10000 !important;
}

/* Iframe container inside Memed module */
div#mdhub-module-plataforma\.prescricao #iframe-container,
div#mdhub-module-plataforma\.prescricao .iframe-container,
#iframe-container {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* Iframe itself - full viewport */
div#mdhub-module-plataforma\.prescricao iframe,
div#mdhub-module-plataforma\.prescricao #iframe-container iframe,
div#mdhub-module-plataforma\.prescricao .iframe-container iframe,
#iframe-container iframe {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    border: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
}

/* Ensure body and html doesn't scroll when Memed is open */
html.memed-open,
body.memed-open {
    overflow: hidden !important;
    position: fixed !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Force any parent container to not constrain Memed */
.memed-open .col-md-12,
.memed-open .target-div,
.memed-open #prescriptionTab {
    overflow: visible !important;
}
