/* Show cards (template-parts/show-card.php) in the home page grid, the
   featured card on the home page
   (template-parts/show-card-featured.php). */

.shows-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-xl) var(--space-md);
}

@media (min-width: 640px) {
    .shows-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .show-card.featured,
    .show-card--wide {
        grid-column: span 2;
    }
}

@media (min-width: 1024px) {
    .shows-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .show-card.featured {
        grid-column: 1 / -1;
    }
}

/* ---------- Card ---------- */

.show-card {
    position: relative;
    display: flex;
    flex-direction: column;
}

.card-image {
    aspect-ratio: 4 / 5;
    overflow: hidden;
    margin-bottom: var(--space-sm);
    background-color: var(--line);
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.show-card:hover .card-image img {
    transform: scale(1.04);
}

.show-card--regular .card-image,
.show-card--wide .card-image {
    aspect-ratio: 3 / 2;
}

@media (min-width: 640px) {
    .show-card--regular .card-image {
        aspect-ratio: 1;
    }

    .show-card--wide .card-image {
        aspect-ratio: 2 / 1;
    }
}

.card-title {
    font-family: var(--font-serif);
    font-size: var(--text-lg);
    font-weight: 600;
    line-height: 1.1;
}

@media (min-width: 640px) {
    .card-title {
        font-size: var(--text-xl);
    }
}

/* The title link covers the whole card. */
.card-title a::after {
    content: '';
    position: absolute;
    inset: 0;
}

.card-title a {
    text-decoration: underline;
    text-decoration-color: transparent;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.15em;
    transition: text-decoration-color var(--duration-normal) ease;
}

.show-card:hover .card-title a {
    text-decoration-color: var(--gold);
}

.card-date {
    margin: var(--space-2xs) 0 0;
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--gold-ink);
    font-variant-numeric: tabular-nums;
}

/* Status: a gold tag on the photo. */
.card-status {
    position: absolute;
    top: var(--space-sm);
    left: var(--space-sm);
    z-index: 1;
    margin: 0;
    padding: var(--space-2xs) var(--space-xs);
    background-color: var(--gold);
    color: var(--ink);
    font-size: var(--text-xs);
    font-weight: 600;
}

/* ---------- Featured card (home) ---------- */

.show-card.featured {
    background-color: var(--ink);
    color: var(--paper);
}

.card-split-container {
    display: flex;
    flex-direction: column;
}

.card-image-side {
    position: relative;
    aspect-ratio: 3 / 2;
    overflow: hidden;
}

.card-image-side img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-info-side {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-lg) var(--gutter);
}

.card-title-featured {
    font-family: var(--font-serif);
    font-size: var(--text-2xl);
    font-weight: 600;
    line-height: 1.05;
}

.show-intro-text {
    max-width: var(--measure);
    color: var(--muted-on-ink);
}

.show-intro-text p:last-child {
    margin-bottom: 0;
}

.shows-list-featured {
    width: 100%;
}

.show-row-featured {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0 var(--space-md);
    padding: var(--space-xs) 0;
    border-bottom: 1px solid var(--line-on-ink);
    font-variant-numeric: tabular-nums;
}

.show-day-featured {
    font-weight: 600;
    color: var(--gold);
}

.show-date-featured {
    color: var(--muted-on-ink);
}

.card-location {
    margin: 0;
    color: var(--muted-on-ink);
}

/* The venue, linked to Google Maps, like in the fixed block. */
.card-location a {
    color: inherit;
    text-decoration: underline;
    text-decoration-color: var(--gold);
    text-decoration-thickness: 1.5px;
    text-underline-offset: 0.3em;
    transition: color var(--duration-normal) ease;
}

.card-location a:hover {
    color: var(--paper);
}

.ticket-badge {
    position: absolute;
    top: var(--space-md);
    left: var(--space-md);
    padding: var(--space-xs) var(--space-sm);
    background-color: var(--gold);
    color: var(--ink);
    font-size: var(--text-xs);
    font-weight: 600;
}

@media (min-width: 640px) {
    .card-split-container {
        flex-direction: row;
    }

    .card-image-side {
        width: 50%;
        aspect-ratio: auto;
        min-height: 26rem;
    }

    .card-info-side {
        width: 50%;
        justify-content: center;
        padding: var(--space-2xl) var(--space-xl);
    }
}

@media (min-width: 1024px) {
    .card-title-featured {
        font-size: var(--text-4xl);
    }
}
