/*
====================================================
SWIPEWEB v0.8
Ficha fotográfica mobile-first: una URL = una pantalla.
====================================================
*/

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    overscroll-behavior: none;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #ffffff;
    color: #101828;
}

.screen {
    position: relative;
    width: 100%;
    min-height: 100vh;
    height: 100vh;
    min-height: 100dvh;
    height: 100dvh;
    overflow: hidden;
    touch-action: pinch-zoom;
}

.gallery-card {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto auto auto;
    align-items: stretch;
    overflow: hidden;
    background: #ffffff;
}

.gallery-header {
    padding: max(14px, env(safe-area-inset-top)) 18px 10px;
    text-align: center;
}

.eyebrow {
    margin: 0 0 5px;
    color: #475467;
    font-size: 0.72rem;
    font-weight: 650;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

h1 {
    max-width: 760px;
    margin: 0 auto;
    font-size: clamp(1.15rem, 5vw, 1.7rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

.hero-figure {
    min-height: 0;
    margin: 0;
    overflow: hidden;
    border-radius: 0;
    background: #f2f4f7;
}

.hero-image {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    object-fit: cover;
    object-position: center;
}


/*
====================================================
CTA DE AFILIADO GLOBAL
Se configura en config/site.php > affiliate_button.
====================================================
*/

.affiliate-cta-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 18px 2px;
    background: #ffffff;
}

.affiliate-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 136px;
    min-height: 48px;
    padding: 0.78rem 1.45rem;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb 0%, #4f46e5 100%);
    box-shadow:
        0 7px 16px rgba(37, 99, 235, 0.26),
        0 2px 5px rgba(16, 24, 40, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.22);
    font-size: 0.96rem;
    font-weight: 750;
    line-height: 1;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transform: translateY(0) scale(1);
    transition:
        transform 160ms ease,
        box-shadow 160ms ease,
        filter 160ms ease;
    -webkit-tap-highlight-color: transparent;
}

.affiliate-button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 11px 22px rgba(37, 99, 235, 0.3),
        0 4px 8px rgba(16, 24, 40, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.24);
    filter: brightness(1.04);
}

.affiliate-button:active {
    transform: translateY(1px) scale(0.975);
    box-shadow:
        0 3px 8px rgba(37, 99, 235, 0.22),
        inset 0 2px 4px rgba(16, 24, 40, 0.16);
    filter: brightness(0.98);
}

.affiliate-button:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.42);
    outline-offset: 4px;
}

.gallery-copy {
    position: relative;
    padding: 11px 18px 4px;
    background: #ffffff;
}

.intro {
    max-width: 760px;
    margin: 0 auto 8px;
    color: #344054;
    font-size: clamp(0.9rem, 3.6vw, 1rem);
    line-height: 1.38;
    text-align: left;
}

.more-details {
    max-width: 760px;
    margin: 0 auto;
    text-align: left;
}

.more-details summary {
    width: max-content;
    max-width: 100%;
    color: #1d2939;
    font-size: 0.86rem;
    font-weight: 650;
    cursor: pointer;
    user-select: none;
}

.more-details summary:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 4px;
    border-radius: 4px;
}

.details-panel {
    position: fixed;
    z-index: 20;
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    left: 12px;
    max-height: min(46dvh, 360px);
    padding: 18px;
    overflow-y: auto;
    overscroll-behavior: contain;
    touch-action: pan-y pinch-zoom;
    border: 1px solid #d0d5dd;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 16px 40px rgba(16, 24, 40, 0.16);
}

.more-details:not([open]) .details-panel {
    display: none;
}

.details-panel p {
    max-width: 760px;
    margin: 0 auto;
    color: #344054;
    font-size: 0.95rem;
    line-height: 1.55;
}

.direction-map {
    padding: 4px 18px max(10px, env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: #344054;
    font-size: 1.25rem;
    line-height: 1;
}

.direction-slot {
    width: 1.2em;
    min-height: 1em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.fallback-navigation {
    position: absolute;
    z-index: 5;
    right: 18px;
    bottom: max(18px, env(safe-area-inset-bottom));
    left: 18px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 10px 22px;
}

.fallback-navigation a {
    color: #344054;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
}

.fallback-navigation a:hover,
.fallback-navigation a:focus-visible {
    color: #101828;
    text-decoration: underline;
}

@media (min-width: 768px) {
    .gallery-header {
        padding-right: 32px;
        padding-left: 32px;
    }

    
/*
====================================================
CTA DE AFILIADO GLOBAL
Se configura en config/site.php > affiliate_button.
====================================================
*/

.affiliate-cta-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 18px 2px;
    background: #ffffff;
}

.affiliate-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 136px;
    min-height: 48px;
    padding: 0.78rem 1.45rem;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb 0%, #4f46e5 100%);
    box-shadow:
        0 7px 16px rgba(37, 99, 235, 0.26),
        0 2px 5px rgba(16, 24, 40, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.22);
    font-size: 0.96rem;
    font-weight: 750;
    line-height: 1;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transform: translateY(0) scale(1);
    transition:
        transform 160ms ease,
        box-shadow 160ms ease,
        filter 160ms ease;
    -webkit-tap-highlight-color: transparent;
}

.affiliate-button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 11px 22px rgba(37, 99, 235, 0.3),
        0 4px 8px rgba(16, 24, 40, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.24);
    filter: brightness(1.04);
}

.affiliate-button:active {
    transform: translateY(1px) scale(0.975);
    box-shadow:
        0 3px 8px rgba(37, 99, 235, 0.22),
        inset 0 2px 4px rgba(16, 24, 40, 0.16);
    filter: brightness(0.98);
}

.affiliate-button:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.42);
    outline-offset: 4px;
}

.gallery-copy {
        padding-right: 32px;
        padding-left: 32px;
    }

    .hero-figure {
        width: 100%;
        margin: 0;
        justify-self: stretch;
        border-radius: 0;
    }
}

@media (hover: none) and (pointer: coarse) {
    .fallback-navigation {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        clip-path: inset(50%);
        white-space: nowrap;
        border: 0;
    }
}

@media (max-height: 680px) {
    .gallery-header {
        padding-top: max(9px, env(safe-area-inset-top));
        padding-bottom: 7px;
    }

    .eyebrow {
        display: none;
    }

    
/*
====================================================
CTA DE AFILIADO GLOBAL
Se configura en config/site.php > affiliate_button.
====================================================
*/

.affiliate-cta-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 18px 2px;
    background: #ffffff;
}

.affiliate-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 136px;
    min-height: 48px;
    padding: 0.78rem 1.45rem;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb 0%, #4f46e5 100%);
    box-shadow:
        0 7px 16px rgba(37, 99, 235, 0.26),
        0 2px 5px rgba(16, 24, 40, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.22);
    font-size: 0.96rem;
    font-weight: 750;
    line-height: 1;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transform: translateY(0) scale(1);
    transition:
        transform 160ms ease,
        box-shadow 160ms ease,
        filter 160ms ease;
    -webkit-tap-highlight-color: transparent;
}

.affiliate-button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 11px 22px rgba(37, 99, 235, 0.3),
        0 4px 8px rgba(16, 24, 40, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.24);
    filter: brightness(1.04);
}

.affiliate-button:active {
    transform: translateY(1px) scale(0.975);
    box-shadow:
        0 3px 8px rgba(37, 99, 235, 0.22),
        inset 0 2px 4px rgba(16, 24, 40, 0.16);
    filter: brightness(0.98);
}

.affiliate-button:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.42);
    outline-offset: 4px;
}

.gallery-copy {
        padding-top: 8px;
    }

    .intro {
        margin-bottom: 5px;
        font-size: 0.86rem;
        line-height: 1.3;
    }

    .direction-map {
        padding-top: 2px;
        font-size: 1.05rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* =========================================================
   SWIPEWEB v2.2.1 - CTA al final de la descripción ampliada
   Reutiliza el mismo enlace y estilo del CTA principal.
   ========================================================= */
.affiliate-cta-details {
    margin-top: 18px;
    padding: 8px 0 4px;
    background: transparent;
}

/* =========================================================
   SWIPEWEB v2.3.2 - PAGINACIÓN HORIZONTAL POR PUNTOS

   Mantiene el aspecto compacto original.
   El círculo visible sigue siendo pequeño.
   El enlace dispone de un área táctil mayor.
   ========================================================= */

.horizontal-dots {
    min-height: 28px;
    padding: 2px 8px;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 4px;
}


/*
 * El elemento clicable mide 24 x 24 px.
 * El círculo visible se crea con ::before,
 * por lo que visualmente sigue siendo pequeño.
 */
.horizontal-dot {
    position: relative;

    width: 24px;
    height: 24px;
    flex: 0 0 24px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 0;
    border-radius: 999px;

    background: transparent;

    text-decoration: none;

    -webkit-tap-highlight-color: transparent;
}


/*
 * Punto visual normal: 7 px.
 */
.horizontal-dot::before {
    content: "";

    width: 7px;
    height: 7px;

    border: 1px solid #667085;
    border-radius: 999px;

    background: transparent;

    transition:
        transform 160ms ease,
        background-color 160ms ease,
        border-color 160ms ease;
}


/*
 * Punto actual: 9 px y relleno.
 */
.horizontal-dot.is-active::before {
    width: 9px;
    height: 9px;

    border-color: #344054;
    background: #344054;

    transform: scale(1.08);
}


/*
 * Hover solo afecta al círculo visible.
 */
.horizontal-dot:not(.is-active):hover::before {
    transform: scale(1.22);
    background: #d0d5dd;
}


/*
 * Foco de teclado sobre toda el área clicable.
 */
.horizontal-dot:not(.is-active):focus-visible {
    outline: 3px solid rgba(52, 64, 84, 0.25);
    outline-offset: 0;
}

.horizontal-dot:not(.is-active):focus-visible::before {
    background: #d0d5dd;
}


/*
 * Pulsación táctil.
 */
.horizontal-dot:not(.is-active):active::before {
    transform: scale(0.9);
}


/*
 * En móviles pequeños mantenemos exactamente
 * el mismo tamaño táctil.
 */
@media (max-width: 380px) {

    .horizontal-dots {
        gap: 2px;
        padding-right: 4px;
        padding-left: 4px;
    }

}
/* =========================================================
   ACCESO RÁPIDO POR PRECIO
   ========================================================= */

.price-shortcut {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 15;

    display: inline-flex;
    align-items: center;
    gap: 7px;

    min-height: 44px;
    padding: 8px 12px;

    color: #344054;
    background: rgba(255, 255, 255, 0.94);

    border: 1px solid #d0d5dd;
    border-radius: 999px;

    box-shadow:
        0 4px 12px rgba(16, 24, 40, 0.08),
        0 1px 3px rgba(16, 24, 40, 0.06);

    font-size: 0.84rem;
    font-weight: 650;
    line-height: 1;

    text-decoration: none;

    -webkit-tap-highlight-color: transparent;

    transition:
        transform 160ms ease,
        box-shadow 160ms ease;
}

.price-shortcut:hover {
    transform: translateY(-2px);

    box-shadow:
        0 7px 16px rgba(16, 24, 40, 0.12),
        0 2px 4px rgba(16, 24, 40, 0.08);
}

.price-shortcut:focus-visible {
    outline: 3px solid rgba(52, 64, 84, 0.25);
    outline-offset: 3px;
}

.price-shortcut-arrow {
    font-size: 1rem;
    line-height: 1;
}
/* =========================================================
   ENLACE INTERNO POR 100 EUROS DENTRO DE DETAILS
   ========================================================= */

.price-shortcut-details {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 7px;

    width: max-content;
    min-height: 44px;

    margin:
        18px
        0
        0
        auto;

    padding:
        8px
        12px;

    color: #344054;

    background:
        rgba(
            255,
            255,
            255,
            0.94
        );

    border:
        1px solid
        #d0d5dd;

    border-radius:
        999px;

    box-shadow:
        0 4px 12px
        rgba(
            16,
            24,
            40,
            0.08
        ),
        0 1px 3px
        rgba(
            16,
            24,
            40,
            0.06
        );

    font-size:
        0.84rem;

    font-weight:
        650;

    line-height:
        1;

    text-decoration:
        none;

    -webkit-tap-highlight-color:
        transparent;

    transition:
        transform
        160ms ease,
        box-shadow
        160ms ease;
}


.price-shortcut-details:hover {

    transform:
        translateY(-2px);

    box-shadow:
        0 7px 16px
        rgba(
            16,
            24,
            40,
            0.12
        ),
        0 2px 4px
        rgba(
            16,
            24,
            40,
            0.08
        );
}


.price-shortcut-details:active {

    transform:
        translateY(1px)
        scale(0.98);

}


.price-shortcut-details:focus-visible {

    outline:
        3px solid
        rgba(
            52,
            64,
            84,
            0.25
        );

    outline-offset:
        3px;

}

/* =========================================================
   SWIPE ENTRE RANGOS DE PRECIO

   Las flechas están SUPERPUESTAS sobre la imagen.
   No modifican su ancho ni añaden padding.
   ========================================================= */


/*
 * hero-figure se convierte en el punto de referencia
 * de las flechas absolutas.
 */

.hero-figure {
    position: relative;
}


/*
 * ESTILO COMÚN DE LAS DOS FLECHAS
 */

.price-swipe-hint {
    position: absolute;

    top: 50%;

    z-index: 20;

    width: 36px;
    height: 36px;

    display: flex;
    align-items: center;
    justify-content: center;

    transform: translateY(-50%);

    color: #344054;

    background:
        rgba(
            255,
            255,
            255,
            0.92
        );

    border:
        1px solid
        rgba(
            208,
            213,
            221,
            0.92
        );

    border-radius: 50%;

    box-shadow:
        0 3px 10px
        rgba(
            16,
            24,
            40,
            0.14
        ),
        0 1px 3px
        rgba(
            16,
            24,
            40,
            0.08
        );

    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1;

    /*
     * Muy importante:
     *
     * la flecha no intercepta el dedo.
     * El usuario puede empezar el swipe
     * justo encima de ella.
     */

    pointer-events: none;

    user-select: none;

    -webkit-user-select: none;

    backdrop-filter: blur(3px);

    -webkit-backdrop-filter:
        blur(3px);
}


/*
 * FLECHA IZQUIERDA
 */

.price-swipe-hint-left {
    left: 10px;
}


/*
 * FLECHA DERECHA
 */

.price-swipe-hint-right {
    right: 10px;
}
/* =========================================================
   PORTADA -> SEGUNDO ROBOT
   ========================================================= */

.second-robot-arrow {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 44px;
    height: 44px;

    margin: 10px auto 0;

    color: #344054;

    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1;

    text-decoration: none;

    cursor: pointer;

    -webkit-tap-highlight-color: transparent;
}

.second-robot-arrow:hover {
    transform: translateY(-2px);
}

.second-robot-arrow:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
    border-radius: 50%;
}
/* =========================================================
   NAVEGACIÓN DE PORTADA PARA DESKTOP
   ========================================================= */

.desktop-home-navigation {
    display: none;
}


/*
 * Solo ordenadores / dispositivos con ratón.
 */
@media (hover: hover) and (pointer: fine) {

    .desktop-home-navigation {
        position: fixed;

        left: 50%;
        bottom: 18px;

        z-index: 30;

        display: flex;
        align-items: center;
        justify-content: center;

        gap: 10px;

        transform: translateX(-50%);
    }


    .desktop-home-link {
        display: inline-flex;
        align-items: center;
        justify-content: center;

        min-height: 44px;

        padding: 9px 14px;

        white-space: nowrap;

        color: #344054;
        background: rgba(255, 255, 255, 0.96);

        border: 1px solid #d0d5dd;
        border-radius: 999px;

        box-shadow:
            0 4px 12px rgba(16, 24, 40, 0.08),
            0 1px 3px rgba(16, 24, 40, 0.06);

        font-size: 0.84rem;
        font-weight: 650;

        text-decoration: none;

        transition:
            transform 160ms ease,
            box-shadow 160ms ease;
    }


    .desktop-home-link:hover {
        transform: translateY(-2px);

        box-shadow:
            0 7px 16px rgba(16, 24, 40, 0.12),
            0 2px 4px rgba(16, 24, 40, 0.08);
    }


    .desktop-home-link:focus-visible {
        outline: 3px solid rgba(52, 64, 84, 0.25);
        outline-offset: 3px;
    }


    .desktop-home-link-primary {
        font-weight: 750;
    }
}
/* =========================================================
   AVISO DE NAVEGACIÓN POR TECLADO - SOLO DESKTOP
   ========================================================= */

.desktop-keyboard-hint {
    display: none;
}

@media (hover: hover) and (pointer: fine) {

    .desktop-keyboard-hint {
        display: block;

        width: max-content;
        max-width: calc(100% - 36px);

        margin: 4px auto 12px;

        padding: 7px 12px;

        color: #667085;
        background: rgba(255, 255, 255, 0.94);

        border: 1px solid #e4e7ec;
        border-radius: 999px;

        box-shadow:
            0 2px 8px rgba(16, 24, 40, 0.06);

        font-size: 0.78rem;
        font-weight: 600;
        line-height: 1.2;

        text-align: center;
        white-space: nowrap;

        user-select: none;
    }
}
/* =========================================================
   AVISO DE SWIPE - SOLO MÓVIL/TABLET Y SOLO EN PORTADA
   El PHP decide que solo exista en /por-100-euros/.
   Este CSS impide que aparezca en desktop.
   ========================================================= */

.mobile-swipe-hint {
    display: none;
}

/*
 * Solo dispositivos táctiles de tamaño móvil/tablet.
 * Así evitamos que aparezca en un desktop, incluso si
 * el navegador informa capacidades táctiles.
 */
@media screen and (max-width: 1024px) and (pointer: coarse) {

    .mobile-swipe-hint {
        display: inline-flex;
        align-items: center;
        justify-content: center;

        width: max-content;
        max-width: calc(100% - 32px);

        margin: 2px auto 4px;
        padding: 7px 12px;

        color: #667085;
        background: rgba(255, 255, 255, 0.96);

        border: 1px solid rgba(208, 213, 221, 0.92);
        border-radius: 999px;

        box-shadow:
            0 4px 12px rgba(16, 24, 40, 0.07),
            0 1px 3px rgba(16, 24, 40, 0.05),
            inset 0 1px 0 rgba(255, 255, 255, 0.75);

        font-size: 0.76rem;
        font-weight: 600;
        line-height: 1.2;
        letter-spacing: 0.01em;

        text-align: center;
        white-space: nowrap;

        user-select: none;
        -webkit-user-select: none;

        pointer-events: none;

        backdrop-filter: blur(5px);
        -webkit-backdrop-filter: blur(5px);
    }
}
