/**
 * Mortex Collecties — Styling
 * 
 * Grid layout, kaarten met afbeelding + overlay titel,
 * hover zoom effect, meerdere titel-posities.
 */

/* ==========================================================================
   1. Container
   ========================================================================== */

.mortex-collecties {
    width: 100%;
}

.mortex-collecties__heading {
    font-family: var(--mortex-font-heading);
    font-weight: 300;
    letter-spacing: 0.02em;
    margin-top: 0;
}


/* ==========================================================================
   2. Grid
   ========================================================================== */

.mortex-collecties__grid {
    display: grid;
    width: 100%;
}

.mortex-collecties__grid--cols-1 { grid-template-columns: 1fr; }
.mortex-collecties__grid--cols-2 { grid-template-columns: repeat(2, 1fr); }
.mortex-collecties__grid--cols-3 { grid-template-columns: repeat(3, 1fr); }
.mortex-collecties__grid--cols-4 { grid-template-columns: repeat(4, 1fr); }


/* ==========================================================================
   3. Card
   ========================================================================== */

.mortex-collectie__card {
    position: relative;
    display: block;
    overflow: hidden;
    height: 500px;
    text-decoration: none;
    color: var(--mortex-white);
    cursor: pointer;
}

/* — Achtergrondafbeelding — */

.mortex-collectie__image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform;
}

.mortex-collectie__card:hover .mortex-collectie__image {
    transform: scale(1.05);
}

/* — Overlay — */

.mortex-collectie__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0) 0%,
        rgba(0, 0, 0, 0.05) 50%,
        rgba(0, 0, 0, 0.4) 100%
    );
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.mortex-collectie__card:hover .mortex-collectie__overlay {
    opacity: 0.5 !important;
}

/* — Content container — */

.mortex-collectie__content {
    position: absolute;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: var(--mortex-space-xs);
    pointer-events: none;
    transition: transform 0.5s ease;
}


/* ==========================================================================
   4. Titel posities
   ========================================================================== */

/* Links onder (default) */
.mortex-collectie__card--bottom-left .mortex-collectie__content {
    bottom: var(--mortex-space-2xl);
    left: var(--mortex-space-2xl);
    right: var(--mortex-space-2xl);
    align-items: flex-start;
}

/* Midden onder */
.mortex-collectie__card--bottom-center .mortex-collectie__content {
    bottom: var(--mortex-space-2xl);
    left: var(--mortex-space-2xl);
    right: var(--mortex-space-2xl);
    align-items: center;
    text-align: center;
}

/* Gecentreerd */
.mortex-collectie__card--center .mortex-collectie__content {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    align-items: center;
    text-align: center;
    width: 80%;
}

.mortex-collectie__card--center:hover .mortex-collectie__content {
    transform: translate(-50%, -50%);
}

/* Links boven */
.mortex-collectie__card--top-left .mortex-collectie__content {
    top: var(--mortex-space-2xl);
    left: var(--mortex-space-2xl);
    right: var(--mortex-space-2xl);
    align-items: flex-start;
}


/* ==========================================================================
   5. Titel & subtitel styling
   ========================================================================== */

.mortex-collectie__title {
    font-family: var(--mortex-font-heading);
    font-size: clamp(1.25rem, 2.5vw, 1.75rem);
    font-weight: 300;
    line-height: 1.25;
    color: var(--mortex-white);
    margin: 0;
    letter-spacing: 0.01em;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

.mortex-collectie__subtitle {
    font-family: var(--mortex-font-body);
    font-size: var(--mortex-fs-sm);
    font-weight: 300;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.75);
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Hover: lichte lift van de tekst */
.mortex-collectie__card:hover .mortex-collectie__content {
    transform: translateY(-4px);
}

.mortex-collectie__card--center:hover .mortex-collectie__content {
    transform: translate(-50%, -50%) translateY(-4px);
}


/* ==========================================================================
   6. Focus / Accessibility
   ========================================================================== */

.mortex-collectie__card:focus-visible {
    outline: 2px solid var(--mortex-gold);
    outline-offset: 2px;
}


/* ==========================================================================
   7. Responsive
   ========================================================================== */

@media (max-width: 768px) {
    .mortex-collecties__grid--cols-2,
    .mortex-collecties__grid--cols-3,
    .mortex-collecties__grid--cols-4 {
        grid-template-columns: 1fr;
    }

    .mortex-collectie__card {
        height: 350px;
    }

    .mortex-collectie__content {
        bottom: var(--mortex-space-lg) !important;
        left: var(--mortex-space-lg) !important;
        right: var(--mortex-space-lg) !important;
    }

    .mortex-collectie__title {
        font-size: 1.25rem;
    }
}


/* ==========================================================================
   8. Elementor editor
   ========================================================================== */

.elementor-editor-active .mortex-collectie__card:hover .mortex-collectie__image {
    transform: none;
}
