html, body {
    margin: 0;
    /* font-family: Arial, sans-serif; */
    width: 100%;
    height: 100%;

    /* ⚠️ CUIDADO */
    /* Esconde a posição x e y de debug */
    overflow: hidden;
}
canvas { 
    display: block; 
    width: 100% !important;
    height: 100% !important;
}

#camera-info {
    display:none;
    position: fixed;
    bottom: 10px;
    left: 10px;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 10px;
    font-family: Arial, sans-serif;
    font-size: 10px;
    z-index:999;
}

.loading-gif {
    width: 60%;
    height: 200px;
    margin-bottom: 20px;
    background-image: url('/static/verticalia.webp');
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    pointer-events: none;
    user-select: none; 
    margin: 0 auto;
}

.loading-text {
    display: block;
}

#loading-message {
    text-align: center;
    position: fixed;
    width: 500px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(0, 0, 0, 0.7);
    border-radius: 20px; 
    color: white;
    padding: 20px;
    font-family: Arial, sans-serif;
    font-size: 21px;
    z-index: 10;
}

#fullscreen-button {
    display: none;
    background-color: #444;
    color: #fc0;
    padding: 8px 12px;
    font-size: 14px;
    border: 1px solid #222;
    border-radius: 4px;
    cursor: pointer;
    z-index: 20;
}

#toggleButton {
    position: fixed;
    bottom: 20px; 
    right: 20px; 
    display: none;
    padding: 10px 15px; 
    background-color: #333; 
    color: #fff; 
    border: none; 
    border-radius: 5px;
    font-size: 21px; 
    cursor: pointer;
    z-index: 1000; 
}

#toggleButton:hover {
    background-color: #555;
}

.slide-btn {
    position: fixed;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    padding: 5px;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    font-size: 20px;
    border: none;
    cursor: pointer;
    z-index: 1001;
    display: none;
    transition: left 0.4s ease;
}

.slide-btn:hover {
    background-color: rgba(255, 255, 255, 0.5);
}

#climbingRouteInfo {
    display:none;
    position: absolute;
    top: 150px;
    left: 20px;
    width: 250px;                    
    max-height: 500px;
    padding: 15px;
    background-color: rgba(0, 0, 0, 0.7);
    color: rgba(255, 255, 255, 0.63);
    font-family: Arial, sans-serif;
    font-size: 13px;
    border-radius: 5px;
    z-index: 1000;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: #888 #333;
    transition: left 0.3s ease;      /* Animação suave ao deslizar */
  }

#climbingRouteInfo.collapsed {
    left: -300px;
}

#routeInfoHandle {
    z-index: 99;
    position: absolute;
    right: 10px;
    top: 1px;
    height: 50px;
    padding: 5px;
    cursor: pointer;
    transition: background-color 0.2s;
  }

  /* A seta em si, dentro do handle */
  #routeInfoHandle .arrow {
    font-size: 1.2em;
    color: #fff;
    user-select: none;
    transition: transform 0.3s ease;
  }

  /* Quando o painel estiver colapsado, a seta vira para a direita */
  #climbingRouteInfo.collapsed #routeInfoHandle .arrow {
    transition: left 0.3s ease;
    background-color: rgba(0, 0, 0, 0.85);
    padding: 10px;
    border-top-right-radius: 5px;
    border-bottom-right-radius: 5px;
    position:fixed;
    left: 0px;
  }


#climbingRouteInfo h3{
    margin: 5px 0 5px 0;
    color: #ffffff;
}

#climbingRouteInfo::-webkit-scrollbar {
    width: 8px;
}

#climbingRouteInfo::-webkit-scrollbar-track {
    background: #333;
    border-radius: 5px;
}

#climbingRouteInfo::-webkit-scrollbar-thumb {
    background-color: #888;
    border-radius: 5px;
    border: 2px solid #333;
}

#climbingRouteInfo::-webkit-scrollbar-thumb:hover {
    background-color: #555;
}


#routeTitle {
    position: absolute;
    display: block;
    top: 80px;
    left: 20px;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.7); 
    color: white;
    font-family: Arial, sans-serif;
    font-size: 20px;
    border-radius: 5px;
    z-index: 1000;
}

.route-item {
    align-items: center;
    padding:2px 0;
    margin: 0;
    cursor: pointer;
}

.route-item:hover {
    color: #fff;
}

.color-square {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 8px;
    border-radius: 3px;
}

.color-circle{
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 8px;
    border-radius: 10px;
}

.settings-panel {
    display: none;
    position: fixed;
    /*top: 80px;*/
    right: 20px;
    max-height: calc(100vh - 150px);
    overflow-y: auto;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 20px;
    border-radius: 5px;
    z-index: 1100;
    font-family: Arial, sans-serif;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
}

.settings-options {
    margin-bottom: 10px;
    padding: 5px;
    padding-top: -10px;
    border-radius: 5px;
    border: solid 1px #575757;
}

.settings-options h3 {
    font-size: 18px;
    margin-top:0px;
    padding: 5px;
}

.settings-options label {
    display: block;
    font-size: 16px;
}
.textureQuality{
    margin:10px 0 10px 0;
}

.radio-inline{
    display: inline-block !important;
}

input[type="radio"] {
    margin-right: 5px;
}

#progress-container {
    width: 100%;
    background-color: rgba(255, 255, 255, 0.3);
    height: 20px;
    border-radius: 5px;
    margin-top: 10px;
    position: relative;
  }
  
  #progress-bar {
    background-color: #ffcc00d0;
    height: 100%;
    width: 0%;
    text-align: center;
    color: white;
    line-height: 20px;
    border-radius: 5px;
  }
  #labelSizeInput, #boltSizeInput{
    margin: 5px;
    padding: 1px;
  }
  .mobile-size-buttons{
    display:none;
  }
  input[type=number]::-webkit-inner-spin-button {
    opacity: 1
}
  
/* Responsive styles for mobile devices */

@media (max-width: 500px) {
    #climbingRouteInfo {
        display: none;
        top: 120px;
        left: 10px;
        padding: 10px;
        font-size: 10px;
        max-width: 35%;
        max-height: 300px;
    }

    #routeTitle {
        /* top: unset; */
        /*bottom: 10px; */
        left: 10px;
        padding: 5px 10px 5px 10px;
        font-size: 17px;
        max-width: max-content;
        max-height: max-content;
    }


    #loading-message {
        max-width: 80%;
        font-size: 12px;
    }
    .route-item {
        padding:2px;
        font-size: 10px;
    }
    .color-square {
        width: 10px;
        height: 10px;
    }

    #labelSizeInput,
    #boltSizeInput {
        display: none;
    }
    .mobile-size-buttons {
        display: inline-flex;
        align-items: center;
    }
    .mobile-size-buttons button, #resetLabelSize, #resetBoltSize {
        margin: 0 2px;
        padding: 5px 10px;
        font-size: 14px;
        background-color: #444;
        color: #fc0;
        border: 1px solid #222;
        border-radius: 4px;
        cursor: pointer;
    }
    .mobile-size-buttons span {
        margin: 0 4px;
        min-width: 2.2em;
        text-align: center;
        color: #ebebeb;
    }
    #fullscreen-button{
        text-align: center;
    }
    #resetLabelSize{
        margin-bottom:10px;
    }
}

