/*
Theme Name: TMOV
Author: Sidewave
Author URI: https://sidewave.it
Template: hello-elementor
Version: 1.0.0
*/

#app {
    max-height: 100vh;
}

:root {
    font-family: Inter, Arial, sans-serif;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.87);
    background-color: #000000;
    text-align: center;

    --primary: #A7865DE5;
    --primary-solid: #A7865D;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    margin: 0;
    padding: 0;
    border: none;
    outline: none !important;
    font-family: 'Montserrat', sans-serif;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-select: none;
}

/* Hide scrollbars for all elements while maintaining scroll functionality */
* {
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;     /* Firefox */
}

/* Hide scrollbars for Chrome, Safari and Opera */
*::-webkit-scrollbar {
    display: none;
}

html, body {
    overflow: hidden;
}

strong {
    font-weight: 500;
}

.modal-html p {
    margin: 1em 0 !important;
}

#loader {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background-color: black;
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    flex-wrap: nowrap;
    flex-direction: column;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

#canvas {
    width: 100%;
    height: 100vh;
}

.not-av-end .hide-till-av-end {
    display: none !important;
}

.av-end .hide-till-av-end {
    display: unset;
}

#av-overlay {
    display: none;
}

#av-overlay.active {
    display: flex;
}

#av-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    flex-wrap: nowrap;
    background: #A7865DCC;
    padding: 32px;
}

#av-text {
    color: white;
    font-size: 22px;
    font-weight: 400;
    width: 100%;
    margin: 0 auto;
}

@media screen and (max-width: 768px) {
    #av-text {
        font-size: 20px;
    }
}

#av-mute-btn {
    display: flex;
    align-items: center;
    border: 1px solid white;
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    padding: 0 10px 0 20px;
    height: 48px;
    position: fixed;
    bottom: 48px;
    left: 48px;
    cursor: pointer;
}

#av-skip-btn {
    display: flex;
    align-items: center;
    border: 1px solid white;
    font-family: 'Montserrat', sans-serif;
    font-weight: 500;
    height: 48px;
    position: fixed;
    bottom: 48px;
    cursor: pointer;
    left: 50%;
    margin-left: -45px;
    padding: 0 20px;
    width: 90px;
    justify-content: center;
}

div#av-loading-bar {
    position: absolute;
    bottom: 110px;
    width: 280px;
    height: 4px;
    background: #ffffff44;
    left: 50%;
    margin-left: -140px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: nowrap;
}

div#av-loading-bar-perc {
    width: 0;
    background: white;
    height: 100%;
    transition: width 0.5s linear;
}

.audio-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 10px;
}

.bar {
    width: 4px;
    height: 30px;
    background: white;
    border-radius: 2px;
}

.bar:nth-child(1) { animation: wave 1s ease-in-out infinite; }
.bar:nth-child(2) { animation: wave 1s ease-in-out infinite -0.2s; }
.bar:nth-child(3) { animation: wave 1s ease-in-out infinite -0.4s; }
.bar:nth-child(4) { animation: wave 1s ease-in-out infinite -0.6s; }
.bar:nth-child(5) { animation: wave 1s ease-in-out infinite -0.8s; }

@keyframes wave {
    0%, 100% { height: 10px; }
    50% { height: 30px; }
}

#av-mute-btn.muted .audio-icon .bar {
    animation: none;
    height: 5px;
}

/* es bottone start the experience */
.not-loaded .hide-till-loaded {
    display: none !important;
}

.loaded .hide-till-loaded {
    display: unset;
}

.loaded .hide-when-loaded {
    display: none !important;
}


/* es elementi in overlay */
.not-started .hide-till-started {
    display: none !important;
}

.started .hide-till-started {
    display: unset;
}

.started .hide-when-started {
    display: none !important;
}

.btn {
    cursor: pointer;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    border: 1px solid white;
    color: white;
    min-width: 200px;
    display: inline-block;
    text-decoration: none;
    padding: 0.75em;
}

.btn:hover {
    color: black;
    background: white;
}

/* modal */
#iframe-real-div,
.modal {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: #333333A0;
    z-index: 1000;
}

.modal.active {
    display: flex;
    flex-wrap: nowrap;
    align-content: center;
    justify-content: center;
    align-items: center;
}

.modal-close {
    position: absolute;
    color: #333;
    top: 0;
    right: 0;
    margin: 8px 8px 0 0;
    font-weight: bold;
    display: block;
    cursor: pointer;
    width: 32px;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.modal-close svg {
    width: 32px;
    height: 32px;
}

.modal-close svg path {
    width: 32px;
    height: 32px;
    fill: var(--primary-solid) !important;
}

.modal-content {
    background: #ffffffee;
    color: var(--primary-solid);
    position: relative;
    border-radius: 8px;
    overflow: clip;
    max-width: 960px;
    max-height: 480px;
    width: calc(100% - 32px);
    height: calc(100% - 32px);
}

.modal-container {
    overflow-x: hidden;
    overflow-y: scroll;
    padding: 0 48px;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.modal-body {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: space-around;
    align-items: center;
    flex: 1;
    gap: 16px;
    height: 100%;
}

.modal-media,
.modal-html {
    flex: 1 1 0;
    width: 0;
}

.modal-media {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: center;
    height: 100%;
    align-items: center;
}

.html-slider {
    height: 95%;
}
.html-slider-child {
    overflow: scroll;
}

.modal-youtube-video {
    height: 95%;
    aspect-ratio: 16 / 9;
}

.modal-html {
    text-align: left;
    font-family: 'Montserrat', sans-serif;
    padding: 48px 0;
    overflow-x: hidden;
    overflow-y: clip;
    height: 100%;
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
}

.modal-html .modal-html-single {
    overflow-y: scroll;
    height: 100%;
    display: flex;
    flex-wrap: nowrap;
    flex-direction: column;
    justify-content: center;
}

.modal-title {
    font-size: 24px;
    padding: 0 0 16px 0;
    flex: 0;
    font-family: 'Cormorant', serif;
    font-weight: 600;
}

.modal-cta {
    margin-top: 16px;
    text-align: center;
}

.modal-cta a.btn {
    color: var(--primary-solid);
    border-color: var(--primary-solid);
}

/* splidejs */
.splide__slide img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: contain;
}

.splide__slide {
    opacity: 0.6;
}

.splide__slide.is-active {
    opacity: 1;
}

.splide__arrows {
    display: none;
    background: transparent;
}

.carousel-thumbnails {
    margin-top: 16px;
}

.image-carousel-arrows{
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 100;
}

.image-carousel-arrows button{
    cursor: pointer;
}

.image-carousel-arrows button svg{
    background: #f6f6f6;
}

/* rotate device */
.rotate-container {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--primary-solid);
    z-index: 9999;
    color: white;
}
.rotate-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}
.rotate-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M16.48 2.52c3.27 1.55 5.61 4.72 5.97 8.48h1.5C23.44 4.84 18.29 0 12 0l-.66.03 3.81 3.81 1.33-1.32zm-6.25-.77c-.59-.59-1.54-.59-2.12 0L1.75 8.11c-.59.59-.59 1.54 0 2.12l12.02 12.02c.59.59 1.54.59 2.12 0l6.36-6.36c.59-.59.59-1.54 0-2.12L10.23 1.75zm4.6 19.44L2.81 9.17l6.36-6.36 12.02 12.02-6.36 6.36zm-7.31.29C4.25 19.94 1.91 16.76 1.55 13H.05C.56 19.16 5.71 24 12 24l.66-.03-3.81-3.81-1.33 1.32z'/%3E%3C/svg%3E") no-repeat center center;
    background-size: contain;
    animation: rotate 1.5s ease-in-out infinite;
}
.rotate-text {
    font-size: 18px;
}
@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(90deg); }
}
@media (orientation: portrait) {
    .rotate-container {
        display: flex;
    }
}

/* HUD */

#top-left {
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    margin: 8px;
    z-index: 1000;
}

#keys {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

#keys svg{
    width: 32px;
    height: auto;
}

#keys svg.active {
    fill: black;
}

#exit-btn {
    cursor: pointer;
    display: none;
}

#exit-btn svg {
    width: 48px;
    height: auto;
}

#top-right {
    position: fixed;
    top: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    margin: 8px;
    z-index: 1000;
}

#map-btn,
#faq-btn {
    width: 39px;
    height: auto;
    cursor: pointer;
}

#navigation {
    z-index: 1000;
}

div#load-title {
    font-family: 'Cormorant', serif;
    font-size: 70px;
    font-weight: 400;
    text-transform: uppercase;
    line-height: 65px;
    z-index: 1000;
    text-shadow: 0 0 20px black;
}

#start-btn,
#load-btn{
    width: 120px;
    height: 120px;
    border-radius: 100%;
    color: black;
    font-size: 14px;
    cursor: pointer;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;

    background: rgba(255, 255, 255, 0.19);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    border: 1px solid rgba(51, 51, 51, 0.2);

    font-family: 'Cormorant', serif;
    text-transform: uppercase;
    font-weight: 400;
}

#start-btn > div,
#load-btn > div {
    width: 100px;
    height: 100px;
    background: white;
    border-radius: 100%;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
}

#start-btn:hover,
#load-btn:hover {
    background: #A7865D30;
}


#start-btn:hover > div,
#load-btn:hover > div {
    background: var(--primary);
    color: white;
}

/* keys */
.key path {
    stroke: #000;
}

.key.owned path {
    stroke: var(--primary-solid);
}

/* audio player */

.modal-audio-player {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-content: center;
    border: 1px solid var(--primary-solid);
    height: 64px;
    align-items: center;
}

.modal-audio-player-ctrl {
    cursor: pointer;
    aspect-ratio: 1 / 1;
    height: 64px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-audio-player-wavesurfer {
    width: 100%;
    margin: 0 24px;
    height: 64px;
}

.modal-audio-player-ctrl.play .modal-audio-player-ctrl-play,
.modal-audio-player-ctrl .modal-audio-player-ctrl-pause {
    display: none;
}

.modal-audio-player-ctrl .modal-audio-player-ctrl-play,
.modal-audio-player-ctrl.play .modal-audio-player-ctrl-pause {
    display: block;
}

.modal-audio-container {
    padding-top: 48px;
}

.glb-viewer {
    width: 100%;
    aspect-ratio: 1;
    background: transparent;
}

.modal-canvas {
    width: 100%;
    height: 100%;
    touch-action: none;
}

/* html slider */
.swiper-button-prev::after,
.swiper-button-next::after {
    content: none !important;
}

/* map */
.modal-map-item img {
    width: 100%;
}

/* sondaggio farmacia / organo */
.modal-sondaggio,
.modal-sondaggio-organo {
    width: 100%;
}

.modal-domanda {
    display: none;
}
.modal-domanda.active {
    display: block;
}

.modal-domanda {
    width: 100%;
}

.modal-risposte {
    margin: 16px auto 0px;
    width: 75%;
}

.modal-risposta {
    border: 1px solid var(--primary-solid);
    padding: 8px;
    cursor: pointer;
    margin-top: 16px;
}

.modal-risposta.active,
.modal-risposta:hover {
    background: white;
    color: var(--primary-solid);
}

.modal-domande-next,
.modal-domande-prev {
    margin-top: 16px;
}

.modal-domande-next svg,
.modal-domande-prev svg{
    cursor: pointer;
}

.modal-domande-next svg:hover,
.modal-domande-prev svg:hover {
    background: white;
}

.modal-domande-next.disabled,
.modal-domande-prev.disabled,
.modal-domande-submit.disabled {
    display: none !important;
}

.modal-domande-submit,
.modal-domande-submit-results a {
    margin-top: 32px;
    padding: 8px 24px;
    border: 1px solid var(--primary-solid);
    display: inline-block;
    cursor: pointer;
    color: var(--primary-solid);
    text-decoration: none;
}

.modal-domande-submit.disabled,
.modal-domande-submit:hover.disabled {
    border: 1px solid darkgray;
    color: darkgray;
    background: transparent;
}

.modal-domande-submit:hover,
.modal-domande-submit-results a:hover{
    background: white;
    color: var(--primary-solid);
}

.modal-sondaggio-progress {
    height: 4px;
    border-radius: 4px;
    text-align: left;
    line-height: 0;
}

.modal-sondaggio-progress-bar {
    background: var(--primary-solid);
    height: 100%;
    border-radius: 4px;
    display: inline-block;
    width: 0;
}

.modal-sondaggio-organo {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: space-between;
    height: 90%;
}

.modal-result-img img {
    height: 200px;
    margin-bottom: 16px;
}

.modal-result-img {
    aspect-ratio: 1 / 1;
    height: 200px;
    margin: 0 auto 16px;
    background: #A7865D44;
}

.modal-result-desc-title,
.modal-result-desc-subtitle {
    font-weight: 500;
    margin-bottom: 16px;
    font-size: 20px;
}

.modal-result-desc-subtitle {
    margin-top: 32px;
    margin-bottom: 16px;
}

.modal-result-desc-perc {
    margin: 16px auto;
    border: 1px solid var(--primary-solid);
    height: 12px;
    text-align: left;
    line-height: 0;
    width: 50%;
}

.modal-result-desc-perc-bar {
    background: var(--primary-solid);
    height: 100%;
    display: inline-block;
}

.modal-result-desc-knowledge {
    font-size: 20px;
}

.carousel,
.carousel .splide,
.carousel .splide * {
    max-height: 440px;
}

/* faqs */

.modal-faqs {
    height: 100%;
}

.modal-faq {
    border: 1px solid var(--primary-solid);
    margin: 16px 0;
}

.modal-faq-domanda {
    padding: 16px;
    text-align: left;
    cursor: pointer;
}

.modal-faq-domanda.active {
    border-bottom: 1px solid var(--primary-solid);
}

.modal-faq-domanda:after {
    content: '\2335';
    float: right;
    rotate: -90deg;
}

.modal-faq-domanda.active:after {
    content: '\2335';
    rotate: 0deg;
}

.modal-faq-risposta {
    text-align: left;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-in-out, padding 0.3s ease-in-out;
    padding: 0 16px;
}

.modal-faq-domanda.active + .modal-faq-risposta {
    max-height: 400px;
    padding: 16px;
    transition: max-height 0.3s ease-in;
}

/* navigator */

section#bottom-center {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    margin-bottom: 48px;
    pointer-events: none;
}

div#bottom-navigation-tip {
    margin-bottom: 16px;
}

div#navigation-tip-btn {
    padding: 8px 16px;
    border: 1px solid white;
}

div.navigation-tip-box {
    padding: 8px 16px;
    border: 1px solid white;
    display: none;
}

section#navigator {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    gap: 32px;
    font-size: 32px;
}

div#position-name {
    min-width: 250px;
    pointer-events: none;
    font-family: 'Cormorant', serif;
    text-transform: uppercase;
}

#next-btn, #prev-btn {
    cursor: pointer;
    pointer-events: all;
    line-height: 0;
}

/* vimeo */

.video-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    opacity: 1;
    transition: opacity 0.5s ease-out;
}

/* Il div che contiene l'iframe deve mantenere le proporzioni */
#vimeo-player {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

#vimeo-player > div {
    position: unset !important;
}

#vimeo-player iframe {
    position: absolute;
    top: 50vh !important;
    left: 50vw !important;
    border: none;
    transform: translate(-50%, -50%);
    min-width: 100%;
    min-height: 100%;
    aspect-ratio: 16 / 9;
    width: unset !important;
    height: unset !important;
}

/* Classe per nascondere il container al termine */
.video-container.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Ateneo */
div#iframe-div.html-overlay {
    display: flex;
}

.html-overlay {
    position:absolute;
    z-index: 10;
    transform-origin: 0 0;
    -webkit-transform-origin: 0 0;
    -moz-transform-origin: 0 0;
    -o-transform-origin: 0 0;
    background-image: url('/wp-content/themes/tmov/img/ateneo-cover.webp');
    background-size: cover;
    background-repeat: no-repeat;
    aspect-ratio: 4 / 3;
    width: 25vw;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.html-overlay svg {
    width: 96px;
}

/* Google Map */
.modal-media div:has(>.gmap) {
    width: 100%;
    height: 100%;
    margin: 16px;
}

.gmap {
    height: 100%;
    width: 100%;
}

.gmap-modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    width: 80%;
    max-width: 928px;
    max-height: 448px;
}

.gmap-modal-title{
    font-size: 18px;
    margin-bottom: 16px;
}

.gmap-modal-body{
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 16px;
}

.gmap-modal-body > img {
    width: 50%;
}

.gmap-modal-body > div {
    width: 50%;
}

@media screen and (max-width: 1024px) {
@media screen and (max-width: 1024px) {
    section#bottom-center {
        margin-bottom: 6px;
    }
    section#navigator {
        font-size: 22px;
    }
}

/* Safari... -.-" */
/* Reset base per il testo su Safari */
html {
    -webkit-text-size-adjust: 100%;
}

/* Previene l'ingrandimento automatico del testo sui dispositivi iOS */
body {
    -webkit-text-size-adjust: none;
    text-size-adjust: none;
}

/* Sistema la dimensione del testo per gli input su iOS */
input, textarea, select, button {
    font-size: 16px; /* Previene lo zoom automatico su iOS */
}

/* Media query per garantire la coerenza su tutti i dispositivi */
@media screen and (max-width: 768px) {
    body {
        /* Forza Safari a rispettare le dimensioni del testo specificate */
        -webkit-text-size-adjust: 100%;
        -moz-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
    }

    /* Gestione specifica per i font su Safari */
    h1, h2, h3, h4, h5, h6, p, span, div {
        /* Previene il ridimensionamento non voluto */
        max-height: 100000px;
    }
}

/* Fix specifico per Safari su macOS */
@media not all and (min-resolution:.001dpcm) {
    @supports (-webkit-appearance:none) {
        body {
            font-size-adjust: none;
            -webkit-font-smoothing: antialiased;
        }
    }
}