/* ─── Rondreis Grid ────────────────────────────────────────────────────────────
   3-column responsive grid of rondreis cards.
   Shortcode: [rondreis_grid]
   ─────────────────────────────────────────────────────────────────────────── */

/* ── Wrapper ─────────────────────────────────────────────────────────────── */

.rdg-wrapper {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

/* ── Filter bar ──────────────────────────────────────────────────────────── */

.rdg-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.rdg-filter__btn {
    display: inline-flex;
    align-items: center;
    height: 44px;
    padding: 0 20px;
    border-radius: 100px;
    border: 1.5px solid #e8e0d5;
    background: transparent;
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    font-weight: 400;
    color: #504d49;
    cursor: pointer;
    white-space: nowrap;
    transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.rdg-filter__btn:hover {
    border-color: #364940;
    color: #364940;
}

.rdg-filter__btn.is-active {
    background: #364940;
    border-color: #364940;
    color: #ffffff;
    font-weight: 500;
}

/* ── Grid ────────────────────────────────────────────────────────────────── */

.rdg-track {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    align-items: stretch; /* all cards in a row share the same height */
}

/* ── Card ────────────────────────────────────────────────────────────────── */

.rdg-card {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border-radius: 16px;
    overflow: hidden;
    text-decoration: none;
    transition: box-shadow 0.25s ease;
}

.rdg-card:hover {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.10);
}

/* ── Photo ───────────────────────────────────────────────────────────────── */

.rdg-card__image-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 420 / 237;
    overflow: hidden;
    flex-shrink: 0;
}

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

.rdg-card:hover .rdg-card__img {
    transform: scale(1.03);
}

.rdg-card__img-placeholder {
    position: absolute;
    inset: 0;
    background: #ddd3c5;
}

/* ── Tip van badge ───────────────────────────────────────────────────────── */

.rdg-card__tip-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #ffffff;
    border-radius: 4px;
    padding: 8px 12px;
    font-family: 'DM Sans', sans-serif;
    font-weight: 500;
    font-size: 14px;
    line-height: 1.1;
    color: #504d49;
    white-space: nowrap;
    z-index: 1;
}

/* ── Body ────────────────────────────────────────────────────────────────── */

.rdg-card__body {
    display: flex;
    flex-direction: column;
    gap: 32px;
    padding: 24px 32px 32px;
    flex: 1;
}

/* ── Meta (badge + title + excerpt) ─────────────────────────────────────── */

.rdg-card__meta {
    display: flex;
    flex-direction: column;
    gap: 16px;
    flex: 1; /* pushes footer to bottom regardless of content height */
}

.rdg-card__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    background: #ddd3c5;
    border-radius: 4px;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.1;
    color: #364940;
    white-space: nowrap;
    align-self: flex-start;
}

.rdg-card__title {
    font-family: 'DM Sans', sans-serif;
    font-size: 28px;
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -0.28px;
    color: #504d49;
    margin: 0;
    padding-bottom:0;
}

.rdg-card__excerpt {
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.6;
    color: #504d49;
    margin: 0;
}

/* ── Footer (price + CTA) ────────────────────────────────────────────────── */

.rdg-card__footer {
    display: flex;
    align-items: center;
    gap: 24px;
}

.rdg-card__price {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 120px;
    flex-shrink: 0;
}

.rdg-card__price-label {
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.1;
    color: #364940;
}

.rdg-card__price-value {
    font-family: 'DM Sans', sans-serif;
    font-size: 24px;
    font-weight: 500;
    line-height: 1.1;
    color: #79a870;
}

.rdg-card__cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex: 1;
    height: 52px;
    padding: 0 24px;
    background: #79a870;
    border-radius: 100px;
    font-family: 'DM Sans', sans-serif;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.16px;
    color: #364940;
    white-space: nowrap;
    transition: background 0.2s ease;
}

.rdg-card:hover .rdg-card__cta {
    background: #364940;
    color: #79A870;
}

.rdg-card__cta svg path {
    stroke: #364940;
}

.rdg-card:hover .rdg-card__cta svg path {
    stroke: #79A870;
}

/* ── Bestemming slider ───────────────────────────────────────────────────── */

.rdg-slider-wrapper {
    display: flex;
    flex-direction: column;
    gap: 48px;
    overflow: visible;
    position: relative;
}

.rdg-slider-track {
    display: flex;
    align-items: stretch;
    flex-wrap: nowrap;
    gap: 24px;
    overflow-x: auto;
    overflow-y: visible;
    width: 100%;
    scrollbar-width: none;
    -ms-overflow-style: none;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
    scroll-snap-type: x mandatory;
}

.rdg-slider-track::-webkit-scrollbar {
    display: none;
}

.rdg-slider-track.is-dragging {
    cursor: grabbing;
}

.rdg-slider-track.is-dragging * {
    pointer-events: none;
    user-select: none;
}

/* Card width is set by JS: (wrapperWidth - 2 × 24px gap) / 3 */
.rdg-slider-track .rdg-card {
    flex-shrink: 0;
    scroll-snap-align: start;
}

/* ── Progress bar ────────────────────────────────────────────────────────── */

.rdg-slider-progress-bar {
    height: 2px;
    background: #DDD3C5;
    border-radius: 1px;
    overflow: hidden;
}

.rdg-slider-progress-fill {
    height: 100%;
    width: 0%;
    background: #AB9472;
    border-radius: 1px;
    transition: width 0.15s linear;
}

/* ── Skeleton placeholder cards ──────────────────────────────────────────── */

.rdg-card--skeleton {
    pointer-events: none;
    position: relative;
    overflow: hidden;
}

.rdg-card--skeleton::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.55) 50%, transparent 100%);
    background-size: 200% 100%;
    animation: rdg-shimmer 1.6s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes rdg-shimmer {
    0%   { background-position: -200% 0; }
    100% { background-position:  200% 0; }
}

.rdg-card--skeleton .rdg-card__image-wrap {
    background: #ddd3c5;
}

.rdg-skel-line {
    background: #e8e0d5;
    border-radius: 4px;
    flex-shrink: 0;
}

.rdg-skel-line--badge       { width: 90px;  height: 32px; }
.rdg-skel-line--title       { width: 100%;  height: 30px; }
.rdg-skel-line--title-short { width: 60%;   height: 30px; }
.rdg-skel-line--text        { width: 100%;  height: 15px; }
.rdg-skel-line--text-short  { width: 75%;   height: 15px; }
.rdg-skel-line--price       { width: 90px;  height: 52px; border-radius: 6px; }
.rdg-skel-line--cta         { flex: 1;      height: 52px; border-radius: 100px; }

/* ── IntersectionObserver sentinel ───────────────────────────────────────── */

.rdg-sentinel {
    grid-column: 1 / -1;
    height: 1px;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */

@media (max-width: 980px) {
    .rdg-track {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .rdg-track {
        grid-template-columns: 1fr;
    }

    .rdg-card__title {
        font-size: 22px;
    }

    .rdg-card__footer {
        flex-direction: column;
        align-items: stretch;
    }

    .rdg-card__price {
        width: auto;
    }

    .rdg-card__cta {
        padding: 16px 24px !important;
        height: auto !important;
    }
}
