html{
    background-color: #121212;
}
body {
    margin: 0;
    padding: 0;
    background-color: #121212;
    overflow: hidden;
    /* color: white; */
}
.overflow{
    overflow: auto;
}
.front-title{
    color: white;
    text-align: center;
    padding-top: 20px;
    margin-bottom: 20px;
}

/* front page */
.card{
    background-color: black!important;
}
.model-card {
    position: relative;
    overflow: hidden;
    height: 100%;
    min-height: 200px;
}
.model-card img, .model-card video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.model-card:hover img, .model-card:hover video {
    transform: scale(1.1);
}
.remove-zoom:hover img, .remove-zoom:hover video {
    transform: scale(1);
}




.model-card .card-body {
    position: absolute;
    bottom: 5px;
    left: 0;
    right: 0;
    
    color: white;
    text-align: center;
    padding: 10px;
    border-radius: 0 0 5px 5px;
    
}
.card-body span{
    font-weight: 1.5rem;
    font-weight: 600;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    background-color: rgba(0, 0, 0, 0.7);
    padding: 6px 10px 8px 10px;
    border-radius: 5px;
}

.top{
    top: 0;
    bottom:unset !important;
height:auto;
}

.model-card{
    border: none;
}
.grid-item{
    /* min-height: 400px; */
    height: 400px;
    padding: 20px !important;
    margin: 0px !important;
    border: none;
}

.video-controls video{
    /* padding: 30px; */

}

/* pages */





body.hidden {
    opacity: 0;
    transition: opacity 1s ease-in-out;
}





.model-viewer-canvas {
    width: 100%;
    height: 100%;
    position: relative;
}
model-viewer {
    width: 100%;
    height: 100%;
    background-color: black;
}
.progress-bar {
    position: absolute;
    bottom: 50vh;
    left: 50%;
    transform: translateX(-50%);
    width: 50%;
    height: 10px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    overflow: hidden;
}
.update-bar {
    width: 0;
    height: 100%;
    background-color: #ffffff;
    transition: width 0.3s;
}
.hotspot {
    display: block;
    width: 20px;
    height: 20px;
    border-radius: 10px;
    border: none;
    background-color: blue;
    box-sizing: border-box;
    pointer-events: none;
}
.annotation {
    background-color: #ffffff;
    position: absolute;
    transform: translate(10px, 10px);
    border-radius: 10px;
    padding: 10px;
}

  /* Sidebar styles */
  #sidebar {
    position: absolute;
    left: -350px; /* Hidden by default */
    width: 300px;
    height: auto;
    top: 140px;
    background: rgba(255, 255, 255, 1);
    transition: left 0.3s;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.5);
    z-index: 10;
    border-radius: 5px;
}
#sidebar.active {
    left: 30px; /* Show sidebar */
}
.back-button {
position: absolute;
display: flex;
top: 20px;
left: 30px;
z-index: 100;
}
.back-button a{
    width: 100%;
    height: 100%;
}
.reset-button {
position: absolute;
top: 20px;
right: 30px;
z-index: 100;
}
.menu-toggle-button {
position: absolute;
top: 80px;
left: 30px;
z-index: 100;
}
.ui-button svg {
    width: 40px;
    height: 40px;
    color: black;
    fill: black;
}

.view-button {
    background: #fff;
    border-radius: 4px;
    border: none;
    box-sizing: border-box;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.25);
    color: white;
    background-color: rgba(0,0,0,0.5);
    display: block;
    font-family: Futura, Helvetica Neue, sans-serif;
    font-size: 12px;
    font-weight: 700;
    width:200px;
    overflow-wrap: break-word;
    padding: 0.5em 1em;
    position: absolute;
    width: max-content;
    height: max-content;
    transform: translate3d(-50%, -50%, 0);
  }
  .view-button:hover {
    background-color: rgba(0,0,0,0.7);
  }
  .view-button h4{
    color: white;
    font-weight: 800;
    margin: 0;
  }

  .reset-3d-button{
    /* position: relative; */
  }
  .ar-button {
    display: none;
    }
/* ar button */
  .fab{
    z-index: 100;
  }
  
  /* mobile */
/* Mobile styles */
@media (max-width: 768px) {
    .back-button {
        top: 10px;
        left: 10px;
    }
    .reset-button {
        top: 10px;
        right: 10px;
    }
    .menu-toggle-button {
        top: 70px;
        left: 10px;
    }
    .ar-button {
        display: flex;
        position: absolute !important;
        top: 70px;
        right: 10px;
        z-index: 100;
    }
    .ui-button {
        font-size: 7px;
        padding: 0.5em 0.5em;
    }
    #sidebar {
        top: unset;
        bottom: unset;
        left: unset;
        
        width: calc(100% - 20px);
        transition: bottom 0.3s;
        transition: top 0.3s;
        border-radius: 5px 5px 0 0;
        overflow: scroll;
        margin-left: 10px;
        margin-right: 10px;
        top: 85%;
        height: 100%;
        
    }
    #sidebar.active {
        left: unset;
        top: 130px;
        height: 100%;
        ttransition: bottom 0.3s;
        transition: top 0.3s;
    }
    
}

/* 3D */



/* segmentaiton */

.segments-canvas {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    width: 100%;
    background-color: black;
    /* position: relative; */
    /* margin: 20px auto;  */
}
.segments-items {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    height: auto;
    width: 50%;
    background-color: black;
    cursor: pointer;
    /* max-height: 50vh; */
    /* position: relative; */
    /* margin: 20px auto;  */
}
.segments-canvas img {
    border-radius: 5px;
    position: absolute;
    width: 100%;
    height: auto;
    opacity: 0;
    z-index: 0;
    transition: opacity 0.5s ease-in-out;
    object-fit: contain;
}
.segments-canvas img.active {
    opacity: 1;
    z-index: 1;
}
.segment-controls button {
    width: 80px;
    height: 50px;
    margin: 0 auto;
    margin: 10px;
}
@media (max-width: 768px) {
    .segments-items {
        width: calc(100% - 20px);
    }
}
/* .segment-controls{
    opacity: 0;
} */

/* game */
.game-canvas {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    width: 100%;
    background-color: black;
}
.game-items {
    position: absolute;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    width: 100%;
    background-color: black;
}
.image-container {
position: absolute;
width: 100%;
height: 100%;
pointer-events: none;
}

.image-container img {
pointer-events: auto;
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
object-fit: contain;
transform: translate(-50%, -50%);
top: 50%;
left: 50%;
}
.game-background {
    position: absolute;
    display: flex;
    justify-content: center;
    align-items: center;
    height: auto;
    width: 50%;
    background-color: black;
    cursor: pointer;
}
.game-background img {
    border-radius: 5px;
    position: absolute;
    width: 100%;
    height: auto;
    opacity: 1;
    z-index: 0;
    transition: opacity 0.5s ease-in-out;
    object-fit: contain;
}
.game-layers {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    height: auto;
    width: 50%;
    background-color: black;
    cursor: pointer;
}
.game-layers img {
    border-radius: 5px;
    position: absolute;
    width: 100%;
    height: auto;
    z-index: 1;
    transition: opacity 0.5s ease-in-out;
    object-fit: contain;
}
.game-controls button {
    width: 80px;
    height: 50px;
    margin: 0 auto;
    margin: 10px;
}
/* game */
.right {
opacity: 0;
pointer-events: none;
}
.wrong {
opacity: 1;
pointer-events: auto;
}
.instructions {
display: block;
}
.game-over {
display: none;
}

@media (max-width: 768px) {
    .segments-items {
        width: calc(100% - 20px);
    }
    .game-background, .game-layers {
        width: calc(100% - 20px);
    }
}



/* restauration */

.restoration-canvas {
    top: 30px;
    left: 0px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    /* max-width: 900px; */
    
    min-height: calc(100vh - 60px);
    /* margin: 20px auto; */
}

#oldCanvas,
#newCanvas {
    display: flex;
justify-content: center;
align-items: center;
position: absolute; /* Keep only one position property */
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}

@media (max-width: 768px) {
    .restoration-canvas {
      
        width: calc(100% - 20px);
    }
    .segments-items {
        width: calc(100% - 20px);
    }
    .restoration-canvas {
        width: calc(100% - 20px);
    }
}


