/*
====================================================
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;
    }

}