/* =========================================================
   EMBED MODE – GLOBAL BACKGROUNDS
   ========================================================= */

html:has(#app-root.embed-mode),
body:has(#app-root.embed-mode) {
    color-scheme: inherit !important;
    background: transparent !important;
    background-color: transparent !important;
    background-image: none !important;
}
body:has(#app-root.embed-mode) {
    margin: 0 !important;
    padding: 0 !important;
}


/* =========================================================
   EMBED MODE – REMOVE ALL WIDTH RESTRICTIONS
   ========================================================= */

html:has(#app-root.embed-mode),
body:has(#app-root.embed-mode),
body:has(#app-root.embed-mode) #react-entry-point,
body:has(#app-root.embed-mode) #react-entry-point > div,
body:has(#app-root.embed-mode) #react-entry-point > div > div,
#app-root.embed-mode,
#app-root.embed-mode main,
#app-root.embed-mode #main-content,
#app-root.embed-mode #page-container {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    box-sizing: border-box !important;
}


/* =========================================================
   EMBED MODE – TRANSPARENT BACKGROUNDS
   ========================================================= */

#app-root.embed-mode,
#app-root.embed-mode *,
#app-root.embed-mode *::before,
#app-root.embed-mode *::after {
    background-color: transparent !important;
    background-image: none !important;
}

/* =========================================================
   EMBED MODE – ROOT AND MAIN CONTENT
   ========================================================= */

#app-root.embed-mode {
    width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

#app-root.embed-mode main,
#app-root.embed-mode #main-content,
#app-root.embed-mode #page-container,
#app-root.embed-mode #spinner {
    width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* =========================================================
   EMBED MODE – REMOVE UNNECESSARY SPACING
   ========================================================= */

#app-root.embed-mode main {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}


/* =========================================================
   EMBED MODE – HIDDEN ELEMENTS
   ========================================================= */

#app-root.embed-mode #header-container,
#app-root.embed-mode #footer-container,
#app-root.embed-mode #disclaimer-container,
#app-root.embed-mode #promotion-container {
    display: none !important;
}

/* =========================================================
   EMBED MODE – REACT ENTRY POINT
   ========================================================= */

html:has(#app-root.embed-mode) #react-entry-point {
    background: transparent !important;
}