/* =========================================================
   GOTIFIESTAS — VISTA LISTA
   Diseño exclusivo de la vista compacta horizontal.

   IMPORTANTE:
   - No modifica la vista cuadrícula.
   - Conserva .gf-event-card y todas las clases existentes.
   - Fecha y ubicación usan los mismos datos que el modal.
   ========================================================= */

/* Estado de las dos representaciones de fecha.
   La cuadrícula conserva su fecha original; la fecha de lista
   solo se muestra cuando el wrapper está en modo lista. */
.gf-events-wrapper.gf-grid-view .gf-grid-date {
    display: inline-block !important;
}

.gf-events-wrapper.gf-grid-view .gf-list-date {
    display: none !important;
}

.gf-events-wrapper.gf-list-view .gf-grid-date {
    display: none !important;
}

/* Contenedor */
.gf-events-wrapper.gf-list-view .gf-events-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

/* Tarjeta */
.gf-events-wrapper.gf-list-view .gf-event-card {
    display: grid;
    grid-template-columns: 265px minmax(0, 1fr);
    grid-template-rows: 58px 40px minmax(0, 1fr) 58px;
    grid-template-areas:
        "image title"
        "image location"
        "image date"
        "image bottom";
    min-height: 268px;
    height: 268px;
    overflow: hidden;
    transform: none !important;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, .5);
}

.gf-events-wrapper.gf-list-view .gf-event-card:hover {
    transform: none !important;
    box-shadow: 0 8px 22px rgba(0, 0, 0, .35);
}

/* Imagen */
.gf-events-wrapper.gf-list-view .gf-event-image-wrap {
    grid-area: image;
    width: 100%;
    height: 100%;
    min-height: 0;
    aspect-ratio: auto;
    border-right: 6px solid var(--ast-global-color-1);
    border-radius: 0;
}

.gf-events-wrapper.gf-list-view .gf-event-card:hover .gf-event-image-wrap img {
    transform: scale(1.04);
}

/* El contenido deja sus hijos directamente en el grid de la tarjeta. */
.gf-events-wrapper.gf-list-view .gf-event-content {
    display: contents;
    padding: 0;
    height: auto;
}

/* Título */
.gf-events-wrapper.gf-list-view .gf-event-title {
    grid-area: title;
    align-self: center;
    margin: 0;
    padding: 0 18px;
    font-size: 28px;
    line-height: 1.15;
    color: var(--ast-global-color-2, #fff);
    font-weight: normal;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Ubicación: mismos datos/clase que usa el modal */
.gf-events-wrapper.gf-list-view .gf-event-location {
    grid-area: location;
    align-self: center;
    margin: 0;
    padding: 0 18px;
    background: transparent !important;
    background-color: transparent !important;
    font-size: 18px;
    line-height: 1.2;
    font-weight: 700;
}

.gf-events-wrapper.gf-list-view .gf-event-location a {
    color: var(--ast-global-color-2, #fff);
    padding: 0 !important;
    background: transparent !important;
    display: flex;
    align-items: center;
    gap: 9px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border-radius: 0;
}

.gf-events-wrapper.gf-list-view .gf-event-location i {
    flex: 0 0 auto;
    font-size: 20px;
}

/* Fecha: mismo dato que data-date / #gf-modal-meta */
.gf-events-wrapper.gf-list-view .gf-event-date {
    grid-area: date;
    position: static;
    align-self: start;
    justify-self: start;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0 18px;
    background: transparent !important;
    background-color: transparent !important;
    color: var(--ast-global-color-2, #fff);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    text-transform: none;
    border-radius: 0;
    z-index: auto;
    font-size: 18px;
    line-height: 1.2;
    font-weight: 700;
}

/* Cuadrícula oculta solo cuando estamos en lista. */
.gf-events-wrapper.gf-list-view .gf-grid-date {
    display: none !important;
}

/* Fecha específica de lista. */
.gf-events-wrapper.gf-list-view .gf-list-date {
    display: inline-flex !important;
    align-items: center;
    width: auto;
    min-width: 0;
    height: auto;
    padding: 0 !important;
    margin: 0;
    background: transparent !important;
    color: inherit;
    border: 0;
    border-radius: 0;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit;
    text-align: left;
    white-space: nowrap;
    overflow: visible;
}

.gf-events-wrapper.gf-list-view .gf-list-date i.fa-calendar {
    display: inline-block;
    flex: 0 0 auto;
    margin-right: 9px;
    font-size: 18px;
    line-height: 1;
    color: inherit;
}

/* Clasificación */
.gf-events-wrapper.gf-list-view .gf-event-classification {
    grid-area: bottom;
    align-self: center;
    margin: 0;
    padding: 0 18px;
    min-width: 0;
}

.gf-events-wrapper.gf-list-view .gf-event-category {
    padding: 8px 12px;
    font-size: 14px;
}

.gf-events-wrapper.gf-list-view .gf-event-tag {
    padding: 7px 10px;
    font-size: 12px;
}

/* Descripción no se muestra en la lista compacta. */
.gf-events-wrapper.gf-list-view .gf-event-excerpt {
    display: none;
}

/* Acciones */
.gf-events-wrapper.gf-list-view .gf-event-actions {
    grid-area: bottom;
    align-self: center;
    justify-self: stretch;
    margin: 0;
    padding: 0 18px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    min-width: 0;
    pointer-events: auto;
}

.gf-events-wrapper.gf-list-view .gf-event-actions > div:last-child {
    display: flex;
    gap: 8px;
    margin-left: 0 !important;
}

.gf-events-wrapper.gf-list-view .gf-event-socials {
    display: flex;
    gap: 8px;
}

.gf-events-wrapper.gf-list-view .gf-event-socials a {
    width: 46px;
    height: 46px;
    font-size: 22px;
}

.gf-events-wrapper.gf-list-view .gf-event-link {
    min-height: 46px;
    padding: 0 17px;
    border-radius: 5px;
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* En lista mostramos redes + Ver evento. Los demás siguen en el DOM. */
.gf-events-wrapper.gf-list-view .gf-event-readmore,
.gf-events-wrapper.gf-list-view .gf-event-tickets,
.gf-events-wrapper.gf-list-view .gf-event-facebook {
    display: none;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 900px) {
    .gf-events-wrapper.gf-list-view .gf-event-card {
        grid-template-columns: 210px minmax(0, 1fr);
        min-height: 235px;
        height: 235px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-title {
        font-size: 23px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-location,
    .gf-events-wrapper.gf-list-view .gf-event-date {
        font-size: 16px;
    }
}

@media (max-width: 768px) {
    .gf-events-wrapper.gf-list-view .gf-event-card {
        grid-template-columns: 150px minmax(0, 1fr);
        grid-template-rows: 50px 36px minmax(0, 1fr) 52px;
        min-height: 210px;
        height: 210px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-title {
        font-size: 19px;
        padding: 0 12px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-location,
    .gf-events-wrapper.gf-list-view .gf-event-date,
    .gf-events-wrapper.gf-list-view .gf-event-classification,
    .gf-events-wrapper.gf-list-view .gf-event-actions {
        padding-left: 12px;
        padding-right: 12px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-location,
    .gf-events-wrapper.gf-list-view .gf-event-date {
        font-size: 13px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-location i,
    .gf-events-wrapper.gf-list-view .gf-list-date i.fa-calendar {
        font-size: 14px;
    }

    .gf-events-wrapper.gf-list-view .gf-list-date i.fa-calendar {
        margin-right: 6px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-category {
        padding: 6px 9px;
        font-size: 11px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-socials {
        gap: 5px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-socials a {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-link {
        min-height: 36px;
        padding: 0 11px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .gf-events-wrapper.gf-list-view .gf-event-card {
        grid-template-columns: 105px minmax(0, 1fr);
        grid-template-rows: 45px 32px minmax(0, 1fr) 48px;
        min-height: 180px;
        height: 180px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-image-wrap {
        border-right-width: 4px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-title {
        font-size: 15px;
        padding: 0 9px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-location,
    .gf-events-wrapper.gf-list-view .gf-event-date {
        font-size: 11px;
        padding-left: 9px;
        padding-right: 9px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-classification,
    .gf-events-wrapper.gf-list-view .gf-event-actions {
        padding-left: 9px;
        padding-right: 9px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-socials a {
        width: 32px;
        height: 32px;
        font-size: 16px;
    }

    .gf-events-wrapper.gf-list-view .gf-event-link {
        min-height: 32px;
        padding: 0 8px;
        font-size: 11px;
    }
}

/* =========================================================
   IMAGEN A PANTALLA COMPLETA
   Funciona en cuadrícula y en lista.
   ========================================================= */

.gf-event-image-wrap {
    cursor: zoom-in;
}

.gf-event-image-wrap img {
    cursor: zoom-in;
}

.gf-image-lightbox {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    box-sizing: border-box;
    background: rgba(0, 0, 0, .94);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .22s ease, visibility .22s ease;
}

.gf-image-lightbox.gf-image-lightbox-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.gf-image-lightbox-content {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100dvh;
    min-height: 100dvh;
    margin: 0;
    padding: 0;
    background: rgba(0, 0, 0, 0.95);

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

    z-index: 999999;
    overflow: hidden;
}

.gf-image-lightbox-img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.gf-image-lightbox-close {
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 2;
    width: 46px;
    height: 46px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ast-global-color-1, #d52227);
    color: var(--ast-global-color-0, #fff);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.gf-image-lightbox-close:hover {
    filter: brightness(.85);
}

body.gf-image-lightbox-active {
    overflow: hidden !important;
}

/* =========================================================
   TAGS: OCULTAR SOLO EN MÓVIL
   La categoría permanece visible.
   ========================================================= */

@media (max-width: 768px) {
    .gf-events-wrapper.gf-list-view .gf-event-category,
    .gf-events-wrapper.gf-list-view .gf-event-tag {
        display: none !important;
    }

    /* Si una clasificación solo contenía tags, no dejamos
       un espacio vacío en la tarjeta. */
    .gf-events-wrapper .gf-event-classification:not(:has(.gf-event-category)) {
        display: none !important;
    }

    .gf-image-lightbox {
        padding: 12px;
    }
	
    .gf-image-lightbox-content {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;

        width: 100vw;
        height: 100dvh;
        min-height: 100dvh;

        padding: 0;
        margin: 0;
    }
	
    .gf-image-lightbox-close {
        top: 12px;
        right: 12px;
        width: 42px;
        height: 42px;
        font-size: 20px;
    }

    .gf-image-lightbox-img {
        max-width: 100%;
        max-height: 100%;
        border-radius: 2px;
    }
}

@supports not (height: 100dvh) {
    .gf-image-lightbox-content {
        height: 100vh;
        min-height: 100vh;
    }
}