/* ==========================================================================
   Stager Events – Frontend Styles
   Compatibel met het Salient WordPress thema (WPBakery)
   ========================================================================== */

:root {
    --stager-accent:      #2c2c2c;
    --stager-radius:      6px;
    --stager-gap:         28px;
    --stager-transition:  .22s ease;
    --stager-shadow:      0 2px 12px rgba(0,0,0,.10), 0 1px 3px rgba(0,0,0,.07);
    --stager-shadow-hover:0 8px 28px rgba(0,0,0,.14), 0 2px 6px rgba(0,0,0,.08);
    --stager-text:        #1d2327;
    --stager-muted:       #646970;
    --stager-border:      #e2e4e7;
    --stager-img-ratio:   56.25%;   /* 16:9 standaard */
}

/* ==========================================================================
   Wrapper
   ========================================================================== */

.stager-events {
    display: grid;
    gap: var(--stager-gap);
}

/* Grid layout */
.stager-events--grid.stager-events--cols-2 { grid-template-columns: repeat(2, 1fr); }
.stager-events--grid.stager-events--cols-3 { grid-template-columns: repeat(3, 1fr); }
.stager-events--grid.stager-events--cols-4 { grid-template-columns: repeat(4, 1fr); }

/* List layout */
.stager-events--list { grid-template-columns: 1fr; }

@media (max-width: 1024px) {
    .stager-events--grid.stager-events--cols-4 { grid-template-columns: repeat(2, 1fr); }
    .stager-events--grid.stager-events--cols-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
    .stager-events--grid { grid-template-columns: 1fr !important; }
    :root { --stager-gap: 20px; }
}

/* Empty state */
.stager-events--empty p {
    text-align: center;
    padding: 40px 20px;
    color: var(--stager-muted);
    font-style: italic;
}

/* ==========================================================================
   Kaart – basis
   ========================================================================== */

.stager-event-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: var(--stager-radius);
    overflow: hidden;
    transition: transform var(--stager-transition), box-shadow var(--stager-transition);
}

/* Stijl: schaduw */
.stager-events--shadow .stager-event-card {
    box-shadow: var(--stager-shadow);
}
.stager-events--shadow .stager-event-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--stager-shadow-hover);
}

/* Stijl: omlijnd */
.stager-events--outlined .stager-event-card {
    border: 1.5px solid var(--stager-border);
}
.stager-events--outlined .stager-event-card:hover {
    border-color: var(--stager-accent);
}

/* Stijl: minimaal */
.stager-events--minimal .stager-event-card {
    border-bottom: 1px solid var(--stager-border);
    border-radius: 0;
}

/* Uitverkocht: overlay dimmen */
.stager-event-card--sold-out .stager-card__image-inner {
    filter: grayscale(40%);
}

/* ==========================================================================
   Kaart – lijstweergave
   ========================================================================== */

.stager-events--list .stager-event-card--list {
    flex-direction: row;
    align-items: stretch;
}

.stager-events--list .stager-card__image-wrap {
    flex: 0 0 260px;
    max-width: 260px;
}

.stager-events--list .stager-card__image-inner {
    height: 100%;
    padding-bottom: 0 !important;
}

.stager-events--list .stager-card__image-inner img {
    position: static;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 640px) {
    .stager-events--list .stager-event-card--list { flex-direction: column; }
    .stager-events--list .stager-card__image-wrap { flex: none; max-width: 100%; }
}

/* ==========================================================================
   Afbeelding
   ========================================================================== */

.stager-card__image-wrap {
    position: relative;
    flex-shrink: 0;
}

.stager-card__image-link {
    display: block;
}

.stager-card__image-inner {
    position: relative;
    overflow: hidden;
    padding-bottom: var(--stager-img-ratio);
    background: #f0f0f0;
}

.stager-card__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
    display: block;
}

.stager-event-card:hover .stager-card__img {
    transform: scale(1.04);
}

/* ==========================================================================
   Badges op de afbeelding
   ========================================================================== */

.stager-card__date-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--stager-accent);
    color: #fff;
    border-radius: 4px;
    padding: 6px 10px;
    text-align: center;
    line-height: 1.1;
    min-width: 42px;
}

.stager-card__date-day {
    display: block;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -.5px;
}

.stager-card__date-mon {
    display: block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    opacity: .9;
}

.stager-card__sold-out-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0,0,0,.65);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 3px;
}

.stager-card__genres {
    position: absolute;
    bottom: 10px;
    left: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.stager-card__genre {
    background: rgba(0,0,0,.55);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .05em;
    padding: 3px 8px;
    border-radius: 3px;
    text-transform: uppercase;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

/* Genres inline (geen afbeelding) */
.stager-card__genres--inline {
    position: static;
    margin-bottom: 8px;
}

.stager-card__genres--inline .stager-card__genre {
    background: color-mix(in srgb, var(--stager-accent) 12%, transparent);
    color: var(--stager-accent);
}

/* ==========================================================================
   Kaart body
   ========================================================================== */

.stager-card__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 20px 22px 22px;
}

/* Meta rijen (datum, locatie) */
.stager-card__meta-row {
    display: flex;
    align-items: flex-start;
    gap: 7px;
    font-size: 13px;
    color: var(--stager-muted);
    margin-bottom: 8px;
    line-height: 1.4;
}

.stager-card__meta-row--date {
    color: var(--stager-accent);
    font-weight: 600;
    font-size: 12.5px;
    text-transform: uppercase;
    letter-spacing: .04em;
    margin-bottom: 6px;
}

.stager-card__end-time {
    font-weight: 400;
    opacity: .75;
}

.stager-icon {
    flex-shrink: 0;
    width: 15px;
    height: 15px;
    margin-top: 1px;
    color: inherit;
}

/* Titel */
.stager-card__title {
    font-size: 18px !important;
    font-weight: 700 !important;
    line-height: 1.3 !important;
    margin: 0 0 8px !important;
    padding: 0 !important;
}

.stager-card__title a {
    color: var(--stager-text) !important;
    text-decoration: none !important;
    transition: color var(--stager-transition);
}

.stager-card__title a:hover {
    color: var(--stager-accent) !important;
}

/* Excerpt */
.stager-card__excerpt {
    font-size: 14px !important;
    line-height: 1.6 !important;
    color: var(--stager-muted) !important;
    margin: 0 0 10px !important;
    flex: 1;
}

/* Locatie */
.stager-card__venue-city {
    color: var(--stager-muted);
}

.stager-card__venue-space {
    opacity: .75;
}

/* ==========================================================================
   Footer (prijs + knop)
   ========================================================================== */

.stager-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid var(--stager-border);
}

.stager-card__price {
    font-size: 16px;
    font-weight: 700;
    color: var(--stager-text);
    white-space: nowrap;
}

/* Ticket knop – sluit aan bij Salient's button-stijl */
.stager-card__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 20px;
    background: var(--stager-accent);
    color: #fff !important;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    text-decoration: none !important;
    border-radius: 3px;
    white-space: nowrap;
    transition: background var(--stager-transition), transform var(--stager-transition);
    cursor: pointer;
    border: none;
}

.stager-card__btn:hover {
    background: color-mix(in srgb, var(--stager-accent) 80%, #000);
    transform: translateY(-1px);
    color: #fff !important;
}

.stager-card__btn--soldout {
    background: var(--stager-border);
    color: var(--stager-muted) !important;
    cursor: not-allowed;
    pointer-events: none;
}

.stager-card__btn--soldout:hover {
    transform: none;
}

/* Als de kaart geen prijs heeft, knop rechts uitlijnen */
.stager-card__footer:not(:has(.stager-card__price)) {
    justify-content: flex-end;
}

/* ==========================================================================
   Galerij (aanvullende afbeeldingen, lijst-layout)
   ========================================================================== */

.stager-card__gallery {
    display: flex;
    gap: 6px;
    padding: 0 22px 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.stager-card__gallery-img {
    flex-shrink: 0;
    width: 100px;
    height: 70px;
    object-fit: cover;
    border-radius: 4px;
    opacity: .85;
    transition: opacity var(--stager-transition);
}

.stager-card__gallery-img:hover {
    opacity: 1;
}

/* ==========================================================================
   Salient-thema overrides
   Salient reset soms heading/link stijlen via .entry-content — dit
   zorgt ervoor dat de event-kaart er altijd goed uitziet.
   ========================================================================== */

.stager-events * {
    box-sizing: border-box;
}

.stager-events .stager-card__title {
    border: none !important;
}

.stager-events a:focus-visible {
    outline: 2px solid var(--stager-accent);
    outline-offset: 2px;
    border-radius: 2px;
}

/* Salient gebruikt soms negatieve marges op .wpb_column — opvangen */
.stager-events.vc_col-sm-12 {
    width: 100%;
}
