/*
 Theme Name: Site Wordpress Développé par UPARTNER
 Description: Par UPARTNER
 Author: UPARTNER
 Author URI: https://upartner.agency
 Template: hello-elementor
 Version: 1.0.2
*/



body {
    padding-top: 140px;
}

body::selection {
	background-color: rgba(203, 56, 54, .8);
	color: white;
}

.jet-listing-not-found {
    margin-top: 1em;
}

.ekit_search-field,
.ekit_search-field:focus {
    outline: none !important;
    color: white !important;
}

.elementor-widget-container {
    position: relative;
}

.wine,
.beer,
.alcohol {
    background-color: #CA0A1C;
    position: absolute;
    top: 100%;
    left: 10%;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.wine.visible,
.beer.visible,
.alcohol.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

/* Affichage des régions et sous-régions */
.regions-list {
    list-style: none;
    padding: 0;
}

.region-parent-item {
    position: relative;
    margin-bottom: 10px;
    cursor: pointer;
}

.regions-enfants-list {
    display: none;
    position: absolute;
    left: 100%;
    top: 0;
    background: #fff;
    border: 1px solid #ccc;
    padding: 10px;
    min-width: 180px;
    z-index: 10;
}

.region-parent-item:hover>.regions-enfants-list {
    display: block;
}

.region-enfant-item {
    margin-bottom: 5px;
}

.vins-produits {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* Desktop : 4 produits */
    gap: 32px;
    margin: 32px 0;
}

/* Tablette : 3 produits */
@media (max-width: 1024px) {
    .vins-produits {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile : 2 produits */
@media (max-width: 768px) {
    .vins-produits {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Styles du slider et des produits */
.swiper {
    width: 100%;
    padding: 20px 0 40px 0;
}

.swiper-slide {
    height: auto;
    display: flex;
    justify-content: center;
}

/* Style de base pour les produits en grille */
.vin-produit {
    background: #fff;
    border-radius: 0;
	border: 1px solid #f0f0f0;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
    padding: 24px 16px 16px 16px;
    /* 4 par ligne avec gap */
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: box-shadow 0.2s;
}

/* Styles spécifiques pour les produits dans le slider */
.swiper .vin-produit {
    width: 100% !important;
    /* Override la largeur de base */
    margin: 0 !important;
}

.vin-produit:hover {
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
}

.vin-produit a {
	width: 100%;
	text-align: center;
}

.vin-produit img {
    max-height: 180px;
    width: auto;
    margin-bottom: 16px;
}

.vin-produit h3 {
    font-size: 1.1rem;
    text-align: center;
    margin: 12px 0 8px 0;
    min-height: 48px;
    color: #222 !important;
    font-weight: 500;
    width: 100%;
}

.vin-produit h3 a {
    color: #222 !important;
}

.vin-produit .prix {
    font-weight: 400;
    font-size: 1rem;
    color: #222;
    margin-bottom: 12px;
    display: block;
    letter-spacing: 0.5px;
    width: 100%;
    text-align: center;
}

.vin-produit .button {
    background: white;
    color: #CA0A1C;
    font-weight: 400;
    padding: 10px 10px;
    border: 1px solid #CA0A1C;
    margin-top: auto;
    font-size: 1rem;
    box-shadow: none;
    transition: background 0.2s, color 0.2s;
    letter-spacing: 0.5px;
    text-align: center;
    width: 70%;
    max-width: 260px;
    cursor: pointer;
}

.vin-produit .button:hover {
    background: #b92d23;
    color: #fff;
}

.rupture-stock {
    display: inline-block;
    background: #e0e0e0;
    color: #b92d23;
    font-size: 1rem;
    font-weight: 400;
    padding: 10px 10px;
    margin-top: auto;
    margin-bottom: 0;
    letter-spacing: 0.5px;
    text-align: center;
    width: 70%;
    max-width: 260px;
    box-shadow: none;
}

#filtres-vins input[name="vin_search"] {
    margin-bottom: 18px;
    margin-top: 8px;
    box-sizing: border-box;
}

.infos-techniques-vin {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin: 32px 0;
}

.info-col {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.info-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-label {
    font-weight: 600;
    color: #333;
    font-size: 1.1rem;
}

.info-value {
    color: #666;
    font-size: 1rem;
}

.taxonomy-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.taxonomy-item {
    background: #f5f5f5;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.9rem;
}

/* Styles des boutons */
.button,
.recherche-btn,
button[type="submit"] {
    background: white;
    color: #CA0A1C;
    font-weight: 400;
    padding: 10px 18px;
    border: 1px solid #CA0A1C;
    font-size: 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
    letter-spacing: 0.5px;
}

.button:hover,
.recherche-btn:hover,
button[type="submit"]:hover {
    background: #CA0A1C;
    color: white;
}

.vin-produit .button {
    width: 70%;
    max-width: 260px;
    margin-top: auto;
}

/* Style spécifique pour les boutons de recherche */
form[id^="recherche"] button[type="submit"],
form[id^="filtres"] button[type="submit"] {
    background: #CA0A1C;
    color: white;
    border: none;
    white-space: nowrap;
    flex-shrink: 0;
}

form[id^="recherche"] button[type="submit"]:hover,
form[id^="filtres"] button[type="submit"]:hover {
    background: #b92d23;
}

/* Styles des boutons d'ajout au panier */
.vin-produit .add_to_cart_button,
.vin-produit .product_type_simple,
.vin-produit .ajax_add_to_cart {
    background: white !important;
    color: #CA0A1C !important;
    font-weight: 400 !important;
    padding: 10px 10px !important;
    border: 1px solid #CA0A1C !important;
    margin-top: auto !important;
    font-size: 1rem !important;
    box-shadow: none !important;
    transition: all 0.2s !important;
    letter-spacing: 0.5px !important;
    text-align: center !important;
    width: 70% !important;
    max-width: 260px !important;
    cursor: pointer !important;
    border-radius: 0 !important;
    text-transform: none !important;
    line-height: 1.5 !important;
}

.vin-produit .add_to_cart_button:hover,
.vin-produit .product_type_simple:hover,
.vin-produit .ajax_add_to_cart:hover {
    background: #CA0A1C !important;
    color: white !important;
    text-decoration: none !important;
}

.vin-produit .added_to_cart {
    display: none !important;
}



.caracteristiques-title {
    font-size: 28px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 32px;
}

.caracteristiques-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.caracteristique-card {
    background: #FFFFFF;
    padding: 24px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    border: 1px solid #f0f0f0;
}

.caracteristique-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.caracteristique-icon svg {
    width: 100%;
    height: 100%;
    stroke: #d8433a;
    fill: none;
    stroke-width: 1.5;
}

.caracteristique-label {
    color: #666;
    font-size: 15px;
    font-weight: 500;
    margin: 0;
    line-height: 1.4;
}

.caracteristique-value {
    color: #1a1a1a;
    font-size: 16px;
    font-weight: 600;
    margin: 0;
}

.appreciation-stars {
    color: #d8433a;
    font-size: 18px;
    letter-spacing: 2px;
}

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

@media (max-width: 480px) {
    .caracteristiques-grid {
        grid-template-columns: 1fr;
    }
}

.regions-cepages-container {
    margin: .5em 0em;
	padding: 1.25em 1em 1em;
	border: 1px solid #CACACA;
}

.regions-cepages-container:before {
	content: 'Plus d\'informations';
    position: absolute;
    top: 0;
    left: 6px;
    transform: translateY(-60%);
    z-index: 1;
    background-color: #fafafa;
    padding: 0 calc(1em - 6px);
}

.regions-cepages-container h3 {
	margin-top: 0;
}

.regions-cepages-flex {
    display: flex;
    gap: 48px;
    align-items: flex-start;
}

.region-section,
.cepage-section {
    flex: 1;
}

.section-title {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 12px;
}

.terms-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.term-link {
	font-size: 16px;
	color: #666666 !important;
}

.term-link:not(:last-of-type):after {
	content: ',';
}

.term-link:hover {
    color: var(--e-global-color-primary) !important;
}

@media (max-width: 768px) {
    .regions-cepages-flex {
        flex-direction: column;
        gap: 24px;
    }
}

/* ///////////////// */
/* Homepage filter */
/* ///////////////// */

#filter-form {
    .jet-container {
        padding: 0;
    }

    .jet-form-builder-row:has(.drink-type) {
        &:before {
            content: 'Je recherche';
        }

        .jet-form-builder__label {
            display: none;
        }
    }

    .jet-form-builder-row:has(.wine-type, .fake-field, .spirit-type) {
        .jet-form-builder__label {
            display: none;
        }
    }

    .jet-form-builder-row:has(.region) {
        &:before {
            content: 'de';
        }

        .jet-form-builder__label {
            display: none;
        }
    }

    .jet-form-builder-row:has(.to-serve-with) {
        &:before {
            content: 'pour accompagner un(e)';
        }

        .jet-form-builder__label {
            display: none;
        }
    }

    .jet-form-builder__field-wrap {
        width: inherit;
    }

    select {
        padding-right: 1.25em;
        font-size: 1em;
        color: white;
        background-color: transparent;
        border: 2px solid white;
        border-radius: 0;
        max-width: 300px;
        background-image:
            linear-gradient(45deg, transparent 50%, white 50%),
            linear-gradient(135deg, white 50%, transparent 50%);
        background-position:
            calc(100% - 18px) 50%,
            calc(100% - 12px) 50%;
        background-size: 6px 6px;
        background-repeat: no-repeat;

        appearance: none;
        -webkit-appearance: none;
        /* Safari / iOS */
        -moz-appearance: none;
        /* Firefox */

        option {
            font-size: 20px;
        }

        @media (max-width: 1024px) {
            padding-right: 1.75em;
            line-height: 1;
            border-width: 1px;
        }
    }

    .container-sentence {
        display: flex;
        justify-content: center;
        flex-direction: row;
        gap: 24px;

        
        .jet-form-builder-row {
            padding: 0;
            flex-direction: row;
            column-gap: 24px;
            align-items: center;
            font-size: 1.75em;
            color: white;
            width: fit-content;

            @media (max-width: 1024px) {
                flex-direction: row;
                font-size: 1.4rem;
            }

            @media (max-width: 767px) {
                flex-direction: column;
                row-gap: 12px;
            }
        }

        .jet-form-builder-row:has(.wine-type) {
            width: inherit;
        }
    }

    .container-sentence-first {
        padding-bottom: 2em;

        @media (max-width: 1024px) {
            padding-bottom: 1em;
        }
    }
}

.jet-form-builder__conditional:has(.wine-type, .fake-field, .spirit-type) {
    width: inherit;
}

.more_options {
    flex-direction: row;
    gap: 2em;
    flex-wrap: nowrap;
    justify-content: space-evenly;
    color: white;
    
    /* Animation smooth pour l'accordion */
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
                opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
                margin-top 0.6s cubic-bezier(0.4, 0, 0.2, 1),
                margin-bottom 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 0;
    margin-bottom: 0;

    @media (max-width: 767px) {
        flex-direction: column;
    }

    .jet-form-builder-row {
        width: fit-content;
    }

    .jet-form-builder__label-text {
        margin-bottom: 12px;
        font-size: 1.5em;
    }
    
    .jet-form-builder__field-label {
        color: white;
    }

    .field-type-checkbox-field .jet-form-builder__field-label.for-checkbox :not(:disabled):active+span::before {
        background-color: #e86b76;
        border-color: #e86b76;
    }

    .field-type-checkbox-field .jet-form-builder__field-label.for-checkbox :not(:disabled):not(:checked):hover+span::before {
        border-color: #e2e2e2;
    }

    .field-type-checkbox-field .jet-form-builder__field-label.for-checkbox>span::before {
        border: 1px solid #ffffff;
        border-radius: 0;
    }

    .field-type-checkbox-field .jet-form-builder__field-label.for-checkbox :checked+span::before {
        border-color: #ffffff;
        background-color: #ca0a1c;
    }
    
    /* État ouvert de l'accordion */
    &.accordion-open {
        max-height: 3000px;
        opacity: 1;
        margin-top: 20px;
        margin-bottom: 20px;
    }
}

.accordion-control {
    text-align: center;
    color: white;
    width: 100%;
    margin: 25px auto 0;
    padding: 25px 0;
    position: relative;
    cursor: pointer;
    user-select: none;
    transition: opacity 0.3s ease;

    &:hover {
        opacity: 0.85;
    }

    &::before {
        content: '';
        left: 0;
        top: 50%;
        position: absolute;
        width: 42%;
        height: 1px;
        background-color: #fff;
    }

    &::after {
        content: '';
        right: 0;
        top: 50%;
        position: absolute;
        width: 42%;
        height: 1px;
        background-color: #fff;
    }

    @media (max-width: 1024px) {
        &::before, &::after {
            width: 36%;
        }
    }

    @media (max-width: 767px) {
        &::before, &::after {
            width: 25%;
        }
    }
    
    /* Icône flèche pour l'accordion */
    .accordion-arrow {
        display: inline-block;
        font-size: .75em;
        margin-left: 8px;
        transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
        transform-origin: center;
    }
    
    &.accordion-open .accordion-arrow {
        transform: rotate(180deg);
    }
}

.field-type-submit-field {
    padding: 0;
}

.jet-form-builder__action-button-wrapper {
    margin-top: 36px;
    justify-content: center;

    .jet-form-builder__action-button {
        border-radius: 0;
        font-size: 1.5em;

        @media (max-width: 1024px) {
            font-size: 1em;
        }
    }
}

.spirit-type {

}

/* SEARCHBAR */

.up-woo-search { position: relative; }
.up-woo-suggest[hidden] { display: none; }

.up-woo-suggest__panel{
  background: #fff;
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 0 0 4px 4px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,.10);
}

.up-woo-suggest__item{
  display: flex;
  gap: .75rem;
  padding: .75rem;
  text-decoration: none;
  color: inherit;
}

.up-woo-suggest__item:hover{
  background: rgba(0,0,0,.03);
}

.up-woo-suggest__img{
  width: 44px; height: 44px;
  object-fit: cover;
  border-radius: .5rem;
}

.up-woo-suggest__text{ display: flex; flex-direction: column; }
.up-woo-suggest__price{ opacity: .7; font-size: .9em; }
