/* ===================================
   Archivo: general.css
   version: 2.1.3
   =================================== */

/* ========================================
   ICONOS
   ======================================== */

.pais-tag .icono-tag {
    display: inline-block;
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    background-color: #fff;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.pais-tag .icono-playas {
    -webkit-mask-image: url("/imagenes/iconos/icono-playas-x1.svg");
    mask-image: url("/imagenes/iconos/icono-playas-x1.svg");
}

.pais-tag .icono-aventura {
    -webkit-mask-image: url("/imagenes/iconos/icono-aventura-x1.svg");
    mask-image: url("/imagenes/iconos/icono-aventura-x1.svg");
}

.pais-tag .icono-naturaleza {
    -webkit-mask-image: url("/imagenes/iconos/icono-naturaleza-x1.svg");
    mask-image: url("/imagenes/iconos/icono-naturaleza-x1.svg");
}

.pais-tag .icono-default {
    -webkit-mask-image: url("/imagenes/iconos/icono-mundo-x1.svg");
    mask-image: url("/imagenes/iconos/icono-mundo-x1.svg");
}
   
/* ========================================
   HERO DEL PAÍS
   ======================================== */
.pais-hero {
    position: relative;
    width: 100%;
    min-height: 500px;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    border-radius: 15px;
}

.pais-hero-imagen {
    position: absolute;
    top: 50px;
    left: 0;
    width: 100%;
    height: 500px;
    z-index: 0;
}

.pais-hero-imagen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 15px;
}

.pais-hero-imagen::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60%;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 100%);
    z-index: 1;
    border-radius: 0 0 15px 15px;
}

.pais-hero-contenido {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 30px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 20px;
}

.pais-hero-izquierda {
    flex: 1;
    max-width: 60%;
}

#landing .pais-hero h1 {
    font-size: 2.2rem;
    color: #fff;
    font-weight: 700;
    margin: 0 0 10px 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    background: none;
    width: auto;
    line-height: 1.2;
    text-align: left;
}

.pais-descripcion {
    font-size: 1.1rem;
    color: #fff;
    line-height: 1.5;
    margin: 0;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

.pais-hero-derecha {
    flex-shrink: 0;
    max-width: 35%;
}

.pais-tags {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: flex-end;
}

.pais-tag {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    line-height: 2.3;
    font-weight: 700;
}

/* ========================================
   BOTÓN SCROLL
   ======================================== */
#scroll-button {
    display: none;
}

@media (max-width: 768px) {
    #scroll-button {
        display: flex;
        justify-content: center;
        align-items: center;
        width: 50px;
        height: 50px;
        background: rgba(255, 255, 255, 0.1);
        border-radius: 50%;
        cursor: pointer;
        margin: 10px auto 0;
        animation: bounce 2s ease-in-out infinite;
        backdrop-filter: blur(1px);
        transition: background 0.3s ease;
    }

    #scroll-button:hover {
        background: rgba(255, 255, 255, 0.3);
    }

    #scroll-button svg {
        width: 24px;
        height: 24px;
        color: #fff;
    }

    @keyframes bounce {
        0%, 100% {
            transform: translateY(0);
        }
        50% {
            transform: translateY(10px);
        }
    }
}

/* Breadcrumb */
#breadcrumb {
    padding: 15px 0;
    color: #666;
    height: 50px;
}

#breadcrumb a {
    color: #666;
    text-decoration: none;
}

#breadcrumb a:hover {
    color: #9dc819;
    text-decoration: underline;
}

#breadcrumb span {
    color: #333;
    font-weight: 500;
}

#landing #caja-circuitos {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

#landing #caja-circuitos h2 {
    grid-column: 1 / -1;
    font-size: 2.2rem;
    color: #333;
    margin-top: 50px;
}

#landing #caja-circuitos .caja-circuito {
    display: flex;
    flex-direction: column;
    position: relative;
}

#landing #caja-circuitos .caja-circuito a {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 3;
}

#landing #caja-circuitos .caja-circuito .caja-imagen {
    width: 100%;
    height: 240px;
}

#landing #caja-circuitos .caja-circuito .caja-imagen .imagen {
    width: 100%;
    height: 100%;
    border-radius: 15px;
    object-fit: cover;
    object-position: center;
}

#landing #caja-circuitos .caja-circuito .informacion {
    width: 100%;
    padding: 15px 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

#landing #caja-circuitos .caja-circuito .informacion h3 {
    font-size: 1.3rem;
    width: 100%;
    font-weight: 700;
}

#landing #caja-circuitos .caja-circuito .informacion .description {
    margin: 4px 0 8px;
    color: #666;
    width: 100%;
    flex-grow: 1;
}

#landing #caja-circuitos .caja-circuito .informacion .info-footer {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

#landing #caja-circuitos .caja-circuito .informacion .info-footer-izq {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

#landing #caja-circuitos .caja-circuito .informacion .mas-info {
    color: #999;
    font-size: 0.9rem;
    text-decoration: underline;
}

#landing #caja-circuitos .caja-circuito .informacion .duracion {
    font-weight: 700;
}

#landing #caja-circuitos .caja-circuito .informacion .precio {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

#landing #caja-circuitos .caja-circuito .informacion .precio-original {
    color: #999;
    font-size: 0.9rem;
    text-decoration: line-through;
}

#landing #caja-circuitos .caja-circuito .informacion .precio-final {
    display: flex;
    align-items: center;
    gap: 5px;
}

#landing #caja-circuitos .caja-circuito .informacion .precio-final .descuento {
    background: #000;
    color: #fff;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.8rem;
}

#landing #caja-circuitos .caja-circuito .informacion .precio-final .cifra {
    font-size: 1.5rem;
    font-weight: 700;
}

#landing #caja-circuitos .caja-circuito .informacion .precio-final .divisa {
    font-size: 1.5rem;
    font-weight: 700;
    margin:0
}

/* ========================================
   SECCIÓN DE OPINIONES EN LANDING
   (Usa los estilos de opiniones.css)
   ======================================== */
#caja-opiniones-ajax {
    clear: both;
    padding: 40px 0;
    margin-top: 40px;
}

#caja-opiniones-ajax h2 {
    font-size: 2.2rem;
    color: #333;
    margin-bottom: 30px;
}

#caja-opiniones-ajax .cerrar-elemento {
    display: none !important;
}

/* ========================================
RESPONSIVE - TABLETS
======================================== */
@media (max-width: 1024px) {
    #landing #caja-circuitos {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========================================
RESPONSIVE - MÓVILES GRANDES Y TABLETS
======================================== */
@media (max-width: 768px) {

    #landing.wrapper {
        position: unset;
    }

    .pais-hero-imagen {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
    }

    .pais-hero-imagen img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 0;
    }

    .pais-hero-imagen::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.1) 30%, rgba(0,0,0,0.5) 100%);
        z-index: 1;
        border-radius: 0;
    }

    #breadcrumb {
        position: relative;
        z-index: 2;
        color: #fff;
        padding: 10px 0;
        height: auto;
    }

    #breadcrumb a {
        color: rgba(255,255,255,0.8);
    }

    #breadcrumb span {
        color: #fff;
    }

    .pais-hero {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 100vh;
        display: flex;
        align-items: flex-end;
        background: transparent;
        z-index: 2;
        width:92%;
        padding: 0 4%;
    }

    .pais-hero-contenido {
        flex-direction: column;
        align-items: flex-start;
        padding: 0;
        width: 100%;
        margin-bottom: 10px;
    }

    .pais-hero-izquierda,
    .pais-hero-derecha {
        max-width: 100%;
        width: 100%;
    }

    .pais-descripcion {
        font-size: 1.0rem;
        margin-bottom: 15px;
    }

    .pais-tags {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: flex-start;
        gap: 10px;
        width: 100%;
    }

    .pais-tag {
        gap: 5px;
        font-size: 0.85rem;
        white-space: nowrap;
    }

    .pais-tag .icono-tag {
        width: 16px;
        height: 16px;
    }

    #landing .titulo-con-filtros {
        margin-top: calc(100vh - 80px);
        flex-wrap: wrap;
    }
    #landing .titulo-con-filtros h2 {
        width: 100%;
    }
    #landing .titulo-con-filtros #btn-buscador-circuitos {
        margin-left: auto;
        margin-top: 20px;
        font-size: 0.90rem;
        padding: 8px 18px;
    }

    #caja-circuitos {
        gap:10px;
    }

    #landing #caja-circuitos .caja-circuito .informacion .description {
        font-size: 0.9rem;
    }

    #caja-opiniones-ajax {
        z-index: 2;
        background: #fff;
        width: 88%;
        margin: 0 3%;
        padding: 0 3%;
        margin-top: 50px;
        border-radius: 15px;
    }

    #caja-opiniones-ajax h2 {
        margin-top: 30px;
    }
}

/* ========================================
RESPONSIVE - MÓVILES PEQUEÑOS
======================================== */
@media (max-width: 480px) {
    
    #landing #caja-circuitos {
        grid-template-columns: 1fr;
    }
    
}

/* ========================================
SECCIONES DE CONTENIDO
======================================== */
.seccion-contenido {
    clear: both;
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
    display: none;
}

.seccion-contenido h2 {
    font-size: 2.2rem;
    color: #333;
    margin-bottom: 30px;
}


.contenido-card a {
    text-decoration: none;
    color: inherit;
    display: block;
    position: relative;
}

.contenido-card a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6) 0%, transparent 100%);
    border-radius: 0 0 15px 15px;
    pointer-events: none;
}

.contenido-card .imagen-contenido {
    width: 100%;
    object-fit: cover;
    border-radius: 15px;
}

.contenido-card .titulo-contenido {
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    position: absolute;
    bottom: 10px;
    width: 100%;
    text-align: center;
    z-index: 1;
}

/* Responsive contenido */


@media (max-width: 480px) {
    
    .contenido-card .imagen-contenido {
        height: 150px;
    }
    
    .contenido-card .titulo-contenido {
        padding: 12px;
    }
}

/* ===========================================
   EXPLICACIÓN DEL PRECIO — el botón (i) y su banner
   Sustituye al «Desde » que había en .precio-original (31-jul-2026). El texto lo
   escribe PHP con explicacionPrecioViaje(), la misma función que alimenta al carril
   agente, para que la web y el asistente no puedan decir cosas distintas.
   =========================================== */

/* Va DENTRO de .precio-original, que lleva line-through: hay que quitárselo o el
   icono sale tachado. Y por encima del <a> que cubre la tarjeta entera (z-index 3),
   o el clic abriría el circuito en vez del banner. */
/* ★ MISMO ICONO QUE EL (i) DEL EQUIPAJE DEL BUSCADOR DE VUELOS (Miguel, 31-jul: «el del
   equipaje de los vuelos me gusta más»). Los valores están copiados de
   servivuelo/mostrar-airavailsearch.css (.info-equipaje): 16px, borde y texto #888, 11px
   en cursiva serif, y al pasar por encima se rellena en vez de solo cambiar de color.
   Se copia y no se comparte porque son hojas de estilo de dos secciones distintas del
   sitio; si algún día divergen, este comentario dice de dónde salió. */
#landing #caja-circuitos .caja-circuito .informacion .precio-original .info-precio {
    position: relative;
    z-index: 4;
    -webkit-appearance: none;
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    margin-right: 6px;
    padding: 0;
    border: 1px solid #888;
    border-radius: 50%;
    background: transparent;
    color: #888;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 11px;
    font-style: italic;
    line-height: 1;
    /* .precio-original va tachado: sin esto el icono sale con la raya encima. */
    text-decoration: none;
    cursor: pointer;
    vertical-align: middle;
    transition: background .2s, color .2s, border-color .2s;
}

/* El icono mide 18px, que es lo que pide el diseño, pero 18px es un objetivo táctil
   pequeño y el 68% del tráfico es móvil. Este pseudo-elemento agranda SOLO la zona
   sensible al dedo, sin mover nada de sitio y sin que se vea. Queda por encima del
   enlace de la tarjeta por el z-index del propio botón. */
#landing #caja-circuitos .caja-circuito .informacion .precio-original .info-precio::after {
    content: '';
    position: absolute;
    top: -9px;
    right: -5px;
    bottom: -9px;
    left: -9px;
}

#landing #caja-circuitos .caja-circuito .informacion .precio-original .info-precio:hover,
#landing #caja-circuitos .caja-circuito .informacion .precio-original .info-precio:focus-visible {
    background: #888;
    border-color: #888;
    color: #fff;
    outline: none;
}

/* El texto viaja dentro de cada tarjeta y el JS lo mueve al banner. Nunca se ve aquí. */
#landing .explicacion-precio { display: none; }

/* Mismo patrón que circuito.php: fondo oscurecido + caja centrada. */
.overlay-general {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10006;
    display: none;
    cursor: pointer;
}

.overlay-general.visible { display: block; }

.modal-precio {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10007;
    width: calc(100% - 40px);
    max-width: 460px;
    max-height: 80vh;
    overflow-y: auto;
    padding: 26px 24px 22px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    text-align: left;
}

.modal-precio[hidden] { display: none; }

.modal-precio h4 {
    margin: 0 0 14px;
    padding-right: 24px;
    color: #d45715;
    font-size: 1.05rem;
}

.modal-precio p {
    margin: 0 0 12px;
    color: #333;
    font-size: 0.92rem;
    line-height: 1.55;
}

.modal-precio p:last-child { margin-bottom: 0; }

.modal-precio-cerrar {
    position: absolute;
    top: 10px;
    right: 12px;
    padding: 0 4px;
    border: 0;
    background: none;
    color: #999;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
}

.modal-precio-cerrar:hover { color: #333; }
