/*************/
/* GENERALES */

body {
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    padding: 0;    
    color: #333;
    background-color: white;
}
p {    
    color: #3d454b;   
    font-weight: 600;
}
h1 {
    color: #3d454b;   
    font-size: 24px;
}
text {
    font-family: 'Montserrat', sans-serif;    
}
label {
    display: block;
    color: #3d454b;
}
select {    
    color: #3d454b;
    font-weight: 600;
    padding: 8px;
    margin: 5px 0 5px 0;
    border-radius: 5px;
    border: 1px solid #3d454b;
    font-size: 16px;
    max-width: 100vw;
}
.label-box {    
    color: #3d454b;
    font-weight: 600;
    text-align: center;
    padding: 8px;
    margin: 5px 0 5px 0;
    border-radius: 5px;
    border: 1px solid #3d454b;
    font-size: 16px;
    max-width: 100vw;
}

/*****************/
/* WELCOME PAGE  */

/* welcome-card */
.welcome-container {
    background: white;           
    text-align: center;
    margin: 0;
    padding: 0;
    width: 100vw;
    /*     
    display: flex;
    justify-content: center;
    align-items: center; */     
}
.welcome-logo {                
    height: 20vh;                        
    margin: 3vw auto 1vw auto; 
}
.welcome-h1 {            
    color: #ff6a00;
    font-weight: 600;
    font-size: 2.5rem;
    margin-bottom: 2vw;
}
.welcome-btn-text {
    display: inline-block; /* Hace que el botón no ocupe toda la línea */
    padding: 10px 20px; /* Añade espacio interno al botón */
    border: 3px solid #3d454b; /* Añade un borde al botón */
    border-radius: 10px;
    color: #3d454b;
    background: white;
    font-weight: 600;
    font-size: 1.3rem;
    margin: 10px 0; 
    padding: 15px 80px;            
}
.welcome-flags {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
    margin: 1vw auto 2vw auto;
}
.welcome-flags-sub {
    display: flex;
    justify-content: center;
    gap: 30px;    
}
.welcome-flags img {    
    height: 8vh;
    border-radius: 50%;
    border: 4px solid #d1d3d4; /* Añade un borde al botón */
    cursor: pointer;
}
.welcome-footer {
    /* background: #ffffff; */
    /* color: white; */
    display: flex;
    flex-direction: column;
    /* width: 100vw; */
    padding: 0px;
    border-radius: 0px;
    /* padding: 15px; */
}
.welcome-footer-info {
    /* Hace que el botón no ocupe toda la línea */            
    display: inline-block; 
    background: #ff6a00;
    /* width: 100vw; */
    color: white;
    padding: 10px;
    font-size: 20px;
    border-radius: 0px;
    padding: 15px;
}
.welcome-footer-banner {
    width: 100vw;
    margin-top: 0px;
}

/*************/
/* MAIN PAGE */


/* HEARDER */
header {        
    background-color: #ff6a00;
    /* height: 10vh; */
    padding-top: 2vh;
    margin-bottom: 1vh;
}
.header-content {
    display: flex;
    align-items: center;
    justify-content: left;
}
.header-div-country {
    width: 100%; 
    height: 8vh; 
    display: flex;
    justify-content: end;
    align-items: center;
    background: linear-gradient(to bottom, #ff6a00 50%, white 50%);    
}

.header-div-country img{
    height: 5vh;
    width: height;
    border-radius: 50%;
    border: 3px solid #d1d3d4; /* Añade un borde al botón */
}
.dropdown-arrow {
    /* transform: scaleX(1.5); */
    font-size: 2rem;
    color: #ff6a00;
    /* margin-left: 5px; */
    margin-top: 15px;
    cursor: pointer;
    padding: 10px;
    transform: rotate(90deg);
}
.main-back-btn{ 
    border: 1px solid #fff; 
    border-radius: 10px;
    color: #fff;
    background: #fff transparent;    
    font-size: 3vh;
    cursor: pointer;
    padding: 5px 12px;
    margin-left: 1.5vw;
}

/*********************/
/* ESTILOS CARROUSEL */

.carousel-wrapper {
    position: relative;
    width: 100%;
    max-height: 30vh;
    overflow: hidden;
}

.carousel-container {
    display: flex;
    gap: 8px;
    transition: transform 0.5s ease-in-out;
    width: 100%;
}

.carousel-item {
    flex: 0 0 calc(100% / var(--items-visible) - 8px);
    height: 30vh;
    background: #ebeced;
    border-radius: 8px;
    overflow: hidden;
    text-align: center;
}

.carousel-item img {
    width: 100%;
    height: 75%;
    object-fit: contain;
}

.image-caption {
    height: 25%;
    background: #ff6a00;
    color: white;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    cursor: pointer;
    padding: 10px 15px;
    font-size: 24px;
    z-index: 10;
    border-radius: 5px;
    transition: opacity 0.3s, cursor 0.3s;
}

.prev {
    left: 10px;
}

.next {
    right: 10px;
}

/* Estilos para cuando los botones están deshabilitados */
.disabled {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}


/* Ajuste responsivo */
@media (max-width: 2048px) {
    :root { --items-visible: 7; }
}

@media (max-width: 1024px) {
    :root { --items-visible: 5; }
}

@media (max-width: 768px) {
    :root { --items-visible: 3; }
}

@media (max-width: 480px) {
    :root { --items-visible: 2; }
}

/* DROPDOWN */
/* .dropdown-menu {
    display: none;
    position: absolute;
    top: 40px;
    left: 0;
    background-color: white;
    border: 1px solid #ddd;
    list-style: none;
    padding: 0;
    margin: 0;
    width: 120px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  }
  
  .dropdown-menu li {
    padding: 10px;
    display: flex;
    align-items: center;
    cursor: pointer;
  }
  
  .dropdown-menu li img {
    width: 20px;
    height: 20px;
    margin-right: 10px;
  }
  
  .dropdown-menu li:hover {
    background-color: #f0f0f0;
  } */


/* BODY MAIN */
main {
    display: grid;
    gap: 2vw;
    max-width: 100vw;
    padding: 0 3vw;
    background-color: #fff;
}

.main-container {
    display: flex;
    flex-wrap: wrap;
    gap: 2vw;   
    margin-top: 1vw;
}

/* SIDEBAR CONTAINER */
.sidebar {
    flex: 1.5;
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    align-items: left;    
    /* max-width: 25vw; */    
}
.sidebar-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    /* flex-direction: column;
    align-items: center;
    justify-content: center;     */
}
.material-div-img {    
    display: flex;
    background: #ebeced;
    align-items: center;
    border-radius: 10px;
    width: 12vw;
    /* height: inherit; */
    height: 30vh;
    max-height: 40vh;
}
.material-img {
    width: inherit;
    height: auto;    
}

/* CHART CONTAINER */
.chart-container {
    display: flex;
    align-items: center; 
    flex-direction: column;
}
.chart {
    flex: 2;        
    text-align: center;
    padding: 10px;
    background-color: #fff;
}
.chart-title-h2 {
    text-align: center;
    font-size: 1.1rem;
    border-radius: 10px;
    font-weight: 600;
    padding: 5px 40px;    
    background: #ff6a00;
    color: #fff;
    margin: 0px;
    margin-top: 20px;
}
/* Estilos del tooltip para D3JS*/
.tooltip {
    position: absolute;
    background-color: #3d454b;
    color: white;
    padding: 8px;
    border-radius: 4px;
    box-shadow: 0px 0px 12px rgba(0, 0, 0, 0.3);
    font-size: 16px;
    border: 1px solid #3d454b;
    visibility: hidden; /* Oculto por defecto */
    transition: opacity 0.2s ease-in-out; /* Animación para hacer la aparición más suave */
    opacity: 0; /* Inicia con opacidad cero */
}

/* Estilos del tooltip para HTML */
.tooltip-container {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.tooltip-container .tooltip {
    position: absolute;
    top: -40px; /* Ajusta según necesites */
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.tooltip-container:hover .tooltip {
    visibility: visible;
    opacity: 1;
}


/* PRICE CONTAINER */
.price-container {
    flex: 1;
    display: flex;    
    flex-direction: column;
    align-items: center;      /* Alinea el contenido verticalmente */
    justify-content: center;  /* Alinea el contenido horizontalmente */    
    font-weight: bold;
    color: #ff6600;
}
.precio {    
    font-size: 2.5rem;
    border: 3px solid #ff6600; /* Añade un borde al botón */
    padding: 0px 25px;    
    border-radius: 10px;    
}
.moneda {    
    font-size: 1.5rem;
    padding-bottom: 10px;
}


/*********************/
/* RESPONSIVE DESIGN */

/* SMARTHPHONE */
@media (max-width: 768px) {

    /*****************/
    /* WELCOME PAGE  */
    .welcome-logo {                
        height: 15vh;                        
        margin: 15vw auto 5vw auto; 
    }
    .welcome-h1 {                    
        font-size: 2rem;
        margin-bottom: 10vw;
    }
    .welcome-btn-text {        
        font-size: 1rem;
        margin: 25px 0; 
        padding: 15px 80px;            
    }
    .welcome-flags {        
        gap: 10px;  
        margin: 30px 0;      
    }
    .welcome-flags img {    
        height: 6vh;
    }
    .welcome-footer {
        background: #ff6a00;        
        border-radius: 20px;
    }
    .welcome-footer-info {
        border-radius: 20px;
    }
    /*************/
    /* MAIN PAGE */

    /* HEARDER */
    .header-div-country img{
        height: 5vh;                
    }
        
    /* SIDEBAR CONTAINER */    
    .material-div-img {            
        width: 40vw;        
        height: 25vh;
    }     

    /* CHART CONTAINER */
    .chart-container {
        margin: 5vw;
        width: 100%;        
        overflow: hidden; /* Evita el desplazamiento del contenedor en sí */
        display: flex;
        align-items: center;
        justify-content: center;
    }    
    #chart {
        width: 100%;
        overflow-x: auto; /* Permite desplazamiento horizontal solo en el gráfico interno */
        padding: 20px;
    }    
    #chart svg {
        min-width: 700px; /* Ancho mínimo para habilitar el scroll si el SVG es más grande que el contenedor */
    }

    /* PRICE CONTAINER */
    .price-container {
        margin: 3vh 0;
    }
}

/* SMARTHPHONE LANDSCAPE*/
@media (orientation: landscape) and (max-width: 1024px) {

    .header-div-country img{
        height: 8vh;                
    }

    .welcome-flags img {    
        height: 12vh;
    }    
    
    .carousel-wrapper {
        max-height: 70vh;
    }
    
    .carousel-item {
        height: 60vh;
    }
    
    .material-div-img {
        width: 20vw;        
        height: 80vh;
    }

}


