/* ==========================================================================
   OVIS Plugin Overrides - Holtkamper Huisstijl
   ========================================================================== */

/* --------------------------------------------------------------------------
   Variables (matching Holtkamper design tokens)
   -------------------------------------------------------------------------- */
:root {
    --hk-primary: #EA5D3C;
    --hk-dark: #1D1D1D;
    --hk-dark-800: #171717;
    --hk-dark-900: #2B1D15;
    --hk-white: #ffffff;
    --hk-grey-10: #F3F4F6;
    --hk-grey-30: #EEEDEB;
    --hk-grey-70: #B8B8B8;
    --hk-radius: 10px;
    --hk-radius-sm: 5px;
    --hk-font: 'Switzer Variable', sans-serif;
    --ovis-price-background-color: transparent;
}

/* --------------------------------------------------------------------------
   1. Container & Layout
   -------------------------------------------------------------------------- */
#ovis-container {
    max-width: 1340px;
    margin: 0 auto;
    padding: 45px 20px 0;
    font-family: var(--hk-font);
}

#l-ovis-presentation-container {
    margin-bottom: 100px;
}

/* --------------------------------------------------------------------------
   2. Filter Section
   -------------------------------------------------------------------------- */
#ovis-search {
    margin-bottom: 40px;
}

#ovis-filters-main-wrapper {
    border: none;
    background: none;
    padding: 0;
}

/* Filter dropdowns */
.contain-filters.main {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: stretch;
    border: none;
    padding: 0;
    background: none;
}

.contain-filter {
    flex: 1 1 180px;
    max-width: 280px;
}

.contain-filter select,
.contain-filter input[type="text"],
.contain-filter .choices,
.contain-filter .choices__inner {
    font-family: var(--hk-font);
    font-size: 15px;
    font-weight: 500;
    color: var(--hk-dark-800);
    background-color: var(--hk-grey-30);
    border: none;
    border-radius: var(--hk-radius-sm);
    padding: 12px 16px;
    min-height: 49px;
    width: 100%;
    appearance: none;
    -webkit-appearance: none;
    transition: all 0.25s ease-in-out;
    box-sizing: border-box;
}

.contain-filter select:focus,
.contain-filter input[type="text"]:focus,
.contain-filter .choices.is-open .choices__inner {
    background-color: var(--hk-dark);
    color: var(--hk-white);
    outline: none;
}

.contain-filter .choices__list--dropdown {
    border: 1px solid var(--hk-grey-30);
    border-radius: var(--hk-radius-sm);
    font-family: var(--hk-font);
    font-size: 14px;
}

/* Uitgebreid zoeken button */
.moreFilters,
button[rel="js-ovis-expand-form-button"] {
    font-family: var(--hk-font);
    font-size: 15px;
    font-weight: 500;
    color: var(--hk-dark-800);
    background: none;
    border: none;
    padding: 8px 0;
    cursor: pointer;
    transition: color 0.25s ease-in-out;
}

.moreFilters:hover,
button[rel="js-ovis-expand-form-button"]:hover {
    color: var(--hk-primary);
}

/* Sort dropdown */
.sorting-container {
    display: flex;
    justify-content: flex-end;
}

#ovis-sort-field {
    font-family: var(--hk-font);
    font-size: 14px;
    font-weight: 500;
    color: var(--hk-dark-800);
    background-color: var(--hk-grey-30);
    border: none;
    border-radius: var(--hk-radius-sm);
    padding: 8px 16px;
    min-height: 40px;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
}

/* Hidden filters section */
.contain-filters.filtershidden {
    border: none;
    background: none;
    padding: 16px 0;
}

/* Applied filters */
#ovis-presentation-filter__applied-filters {
    margin-bottom: 16px;
}

.ovis-presentation-filter__applied-filter {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--hk-font);
    font-size: 14px;
    background-color: var(--hk-grey-30);
    border-radius: 75px;
    padding: 6px 14px;
    margin: 0 8px 8px 0;
}

.ovis-presentation-filter__applied-filter__button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 2px;
    display: flex;
    align-items: center;
}

/* --------------------------------------------------------------------------
   3. Results Bar & View Toggle
   -------------------------------------------------------------------------- */
#l-ovis-presentation-results-layout {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--hk-grey-30);
    border-top: 1px solid var(--hk-grey-30);
}

#ovis-presentation-results {
    font-family: var(--hk-font);
    font-size: 14px;
    color: var(--hk-dark);
    margin: 0;
}

#ovis-presentation-count {
    font-weight: 600;
}

#ovis-presentation-layout {
    display: flex;
    gap: 8px;
}

.ovis-layout__button {
    background: none;
    border: 1px solid var(--hk-grey-30);
    border-radius: var(--hk-radius-sm);
    padding: 6px;
    cursor: pointer;
    transition: all 0.25s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ovis-layout__button:hover,
.ovis-layout__button.active {
    background-color: var(--hk-dark);
    border-color: var(--hk-dark);
}

.ovis-layout__button:hover svg path,
.ovis-layout__button.active svg path {
    stroke: var(--hk-white);
    fill: var(--hk-white);
}

/* --------------------------------------------------------------------------
   4. Product Grid
   -------------------------------------------------------------------------- */
#ovis-presentation-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

#ovis-presentation-container.ovis-presentation-container--list {
    grid-template-columns: 1fr;
}

/* Loading skeleton section - same grid */
#ovis-loading-wrapper {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
    grid-column: 1 / -1;
}

/* --------------------------------------------------------------------------
   5. Product Card
   -------------------------------------------------------------------------- */
.ovis-presentation {
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    background: var(--hk-white);
    box-shadow: 0 18px 44px rgba(15, 23, 42, 0.08);
    transition: transform 0.25s ease-in-out, box-shadow 0.25s ease-in-out;
    display: flex;
    flex-direction: column;
}

.ovis-presentation:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 44px rgba(15, 23, 42, 0.14);
}

/* Card link - make entire card clickable */
.ovis-presentation > a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* ---- News-card style: image first, then title + content ---- */

/* Move image to the top via order */
.l-ovis-presentation__img {
    position: relative;
    overflow: hidden;
    order: -1;
    margin: 0;
}

/* Move grid title below image via order (image has order:-1) */
#ovis-presentation-container .ovis-presentation__title-container--grid {
    order: 0;
    background: var(--hk-white);
    padding: 24px 24px 0;
    min-height: auto;
}

/* Image */
.ovis-presentation__img {
    width: 100%;
    height: 320px;
    overflow: hidden;
    display: block;
    border-radius: 0;
}

.ovis-presentation__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease-in-out;
}

.ovis-presentation:hover .ovis-presentation__img img {
    transform: scale(1.03);
}

/* Verkocht / Sold overlay on image */
.l-ovis-presentation__img .ovis-row.price.soldprice,
.l-ovis-presentation__img [data-ovis-translation-key="Verkocht"] {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

/* Details section – news-card content area */
.ovis-presentation__details {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 12px 24px 26px;
    background: var(--hk-white);
    min-height: 0;
    order: 1;
}

/* Hide the list title in grid view (grid title is used instead) */
#ovis-presentation-container .ovis-presentation__title-container--list {
    display: none;
}

#ovis-presentation-container .ovis-presentation__title {
    font-family: var(--hk-font);
    font-size: 32px;
    font-weight: 700;
    color: var(--hk-dark);
    letter-spacing: -0.7px;
    line-height: 0.98;
    display: block;
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
}

#ovis-presentation-container .ovis-presentation__subtitle {
    font-family: var(--hk-font);
    font-size: 14px;
    color: var(--hk-grey-70);
    margin-top: 4px;
    display: none;
}

/* Specifications – compact inline style */
.ovis-presentation__specifications {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    flex: 1 1 auto;
}

#ovis-presentation-container .ovis-presentation__spec {
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding: 6px 0;
    font-family: var(--hk-font);
    font-size: 14px;
    border-bottom: 1px solid var(--hk-grey-10);
}

#ovis-presentation-container .ovis-presentation__spec:last-child {
    border-bottom: none;
}

#ovis-presentation-container .ovis-presentation__spec__title {
    color: var(--hk-grey-70);
    font-weight: 400;
}

#ovis-presentation-container .ovis-presentation__spec__value {
    color: var(--hk-dark);
    font-weight: 600;
    text-align: right;
}

/* Price – prominent, at the bottom */
#ovis-presentation-container > .ovis-presentation .ovis-presentation__price {
    margin-top: auto;
    text-align: left;
    padding: 16px 0 0;
    border-top: 1px solid var(--hk-grey-30);
    background: transparent !important;
    border-radius: 0;
}

#ovis-presentation-container .ovis-presentation__price__label {
    font-family: var(--hk-font);
    font-size: 13px;
    color: var(--hk-grey-70);
    display: block;
    margin-bottom: 2px;
}

#ovis-presentation-container .ovis-presentation__price__value {
    font-family: var(--hk-font);
    font-size: 24px;
    font-weight: 700;
    color: var(--hk-dark);
    display: block;
    letter-spacing: -0.3px;
}

/* --------------------------------------------------------------------------
   6. Verkocht (Sold) Badge
   -------------------------------------------------------------------------- */
.ovis-row.price.soldprice {
    background: none;
}

.ovis-row.price.soldprice .priceTo {
    font-family: var(--hk-font);
    font-size: 16px;
    font-weight: 600;
    color: var(--hk-primary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Sold overlay on the image */
.ovis-presentation .l-ovis-presentation__img::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 1;
}

/* --------------------------------------------------------------------------
   7. Verkocht overlay text styling
   -------------------------------------------------------------------------- */
.ovis-presentation__price__value [data-ovis-translation-key="Verkocht"],
.ovis-presentation [data-ovis-translation-key="Verkocht"] {
    color: var(--hk-primary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --------------------------------------------------------------------------
   8. Pagination
   -------------------------------------------------------------------------- */
nav.ovis-pagination {
    margin-top: 40px;
    text-align: center;
}

.ovis-pagination ul {
    display: flex;
    justify-content: center;
    gap: 4px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.ovis-pagination__item {
    font-family: var(--hk-font);
    font-size: 14px;
    padding: 8px 14px;
    border-radius: var(--hk-radius-sm);
    cursor: pointer;
    transition: all 0.25s ease-in-out;
    color: var(--hk-dark);
}

.ovis-pagination__item:hover,
.ovis-pagination__item.active {
    background-color: var(--hk-dark);
    color: var(--hk-white);
}

/* --------------------------------------------------------------------------
   9. Loading skeleton animation
   -------------------------------------------------------------------------- */
.ovis-presentation--loading {
    background: var(--hk-grey-10);
    border-radius: var(--hk-radius);
    overflow: hidden;
}

.ovis-presentation--loading .ovis-presentation__title,
.ovis-presentation--loading .ovis-presentation__img,
.ovis-presentation--loading .ovis-presentation__specifications,
.ovis-presentation--loading .ovis-presentation__price__value {
    background: linear-gradient(90deg, var(--hk-grey-10) 25%, #e0e0e0 50%, var(--hk-grey-10) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}

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

/* --------------------------------------------------------------------------
   10. List View Overrides
   -------------------------------------------------------------------------- */
.ovis-presentation-container--list .ovis-presentation {
    flex-direction: row;
}

.ovis-presentation-container--list .ovis-presentation > a {
    flex-direction: row;
    width: 100%;
}

.ovis-presentation-container--list .ovis-presentation__title-container--grid {
    display: none;
}

.ovis-presentation-container--list .l-ovis-presentation__img {
    flex: 0 0 360px;
    max-width: 360px;
    order: unset;
}

.ovis-presentation-container--list .ovis-presentation__img {
    height: 100%;
    min-height: 240px;
}

.ovis-presentation-container--list .ovis-presentation__details {
    flex: 1;
    align-items: flex-start;
    justify-content: center;
    border-left: 1px solid var(--hk-grey-30);
    min-height: auto;
}

/* --------------------------------------------------------------------------
   11. No Results / Empty State
   -------------------------------------------------------------------------- */
#ovis-presentation-container:empty::after {
    content: 'Geen resultaten gevonden';
    display: block;
    text-align: center;
    padding: 40px 24px;
    background: var(--hk-grey-10);
    border-radius: var(--hk-radius);
    font-family: var(--hk-font);
    font-size: 16px;
    color: var(--hk-dark-800);
    grid-column: 1 / -1;
}

/* --------------------------------------------------------------------------
   12. Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
    #ovis-container {
        padding-top: 30px;
    }

    #l-ovis-presentation-container {
        margin-bottom: 60px;
    }

    .ovis-presentation__img {
        height: 250px;
    }
}

@media (max-width: 767px) {
    #ovis-presentation-container,
    #ovis-loading-wrapper {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .contain-filters.main {
        flex-direction: column;
    }

    .contain-filter {
        max-width: 100%;
    }

    .ovis-presentation__title {
        font-size: 22px;
    }

    .ovis-presentation__img {
        height: 240px;
    }

    .ovis-presentation__details {
        padding: 18px 18px 20px;
        gap: 12px;
        min-height: 0;
    }

    .ovis-presentation__price__value {
        font-size: 20px;
    }

    /* List view becomes card on mobile */
    .ovis-presentation-container--list .ovis-presentation,
    .ovis-presentation-container--list .ovis-presentation > a {
        flex-direction: column;
    }

    .ovis-presentation-container--list .l-ovis-presentation__img {
        flex: none;
        max-width: 100%;
    }

    .ovis-presentation-container--list .ovis-presentation__img {
        height: 220px;
    }

    .ovis-presentation-container--list .ovis-presentation__details {
        border-left: none;
        border-top: 1px solid var(--hk-grey-30);
    }

    #l-ovis-presentation-results-layout {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}
