/* Layout */

.soft-resto-search-container {

    max-width: 1200px;

    margin: 0 auto;

    padding: 20px;

}



.soft-resto-search-form {

    display: flex;

    flex-direction: column;

    gap: 5px;

    margin-bottom: 30px;

    background-color: white;

}



.soft-resto-filters {

    display: flex;

    gap: 10px;

}



/* Search Input */

#soft-resto-search-input {

    padding: 12px 15px;

    border: 2px solid #e0e0e0;

    border-radius: 8px;

    border-color: #000000;

    font-size: 16px;

    transition: all 0.3s ease;

}



#soft-resto-search-input:focus {

    border-color: #ff6b6b;

    outline: none;

    box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.2);

}



/* Filters */

#soft-resto-city-filter,

#soft-resto-meal-filter {

    flex: 1;

    padding: 10px 15px;

    border: 2px solid #e0e0e0;

    border-radius: 8px;

    font-size: 14px;

    background-color: #ff7700;

    color: black;

}



/* Results Grid */

.soft-resto-results-grid {

    display: grid;

    grid-template-columns: repeat(2, 1fr);

    gap: 10px;

}



/* Restaurant Card */

.soft-resto-card {

    background: white;

    border-radius: 12px;

    overflow: hidden;

    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);

    transition: all 0.3s ease;

}



.soft-resto-card:hover {

    transform: scale(1.02);

    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);

}




.soft-resto-card:hover .soft-resto-card-banner img {

    transform: scale(1.05);

}



.soft-resto-card-content {

    padding: 10px;

}



.soft-resto-card-title {

    margin: 0 0 5px 0;

    font-size: 16px;

    font-weight: 600;

    color: #333;

}



/* Nouveau style pour les infos sur 2 lignes */

.soft-resto-card-meta {

    display: flex;

    flex-direction: column;

    gap: 5px;

    margin-top: 8px;

}



.soft-resto-meta-item {

    display: flex;

    align-items: center;

    gap: 6px;

    font-size: 13px;

}



.soft-resto-meta-item i {

    color: #ff6b6b;

    width: 16px;

    text-align: center;

}



.soft-resto-meta-item span {

    color: #555;

}



.soft-resto-card-city {

    font-weight: 500;

    color: #333;

    font-size: 14px;

}



.soft-resto-card-delivery {

    color: #ff6b6b;

    font-size: 13px;

}



.fas {

    margin-right: 5px;

    font-size: 12px;

}



/* No Results */

.soft-resto-no-results {

    text-align: center;

    grid-column: 1 / -1;

    padding: 20px;

    color: #666;

}



/* Single Restaurant */

.soft-resto-single-container {

    max-width: 1200px;

    margin: 0 auto;

    padding: 20px;

}



.soft-resto-single {

    background: white;

    border-radius: 12px;

    overflow: hidden;

    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);

}



.soft-resto-single-header {

    position: relative;

}



.soft-resto-single-banner {

    height: 300px;

    overflow: hidden;

}



.soft-resto-single-image {

    width: 100%;

    height: 100%;

    object-fit: cover;

}



.soft-resto-sponsored-badge.left {

    position: absolute;

    top: 2px;

    left: 2px;

    right: auto; /* Annule la position droite */

    background: linear-gradient(135deg, #8B4513, #DAA520); /* Dégradé marron/or */

    color: white;

    padding: 5px 5px;

    border-radius: 15px 3px 15px 3px; /* Bords arrondis asymétriques */

    font-size: 12px;

    font-weight: 600;

    display: flex;

    align-items: center;

    gap: 5px;

    box-shadow: 1px 2px 8px rgba(0,0,0,0.3);

    z-index: 2;

    text-transform: capitalize;

    letter-spacing: 0.5px;

}



.soft-resto-sponsored-badge.left i {

    font-size: 12px;

    color: #FFD700; /* Couleur or pour l'icône */

}



/* Animation au survol */

.soft-resto-card:hover .soft-resto-sponsored-badge.left {

    transform: translateY(-2px);

    box-shadow: 2px 4px 10px rgba(0,0,0,0.4);

}



.soft-resto-single-meta {

    padding: 20px;

    background: white;

}



.soft-resto-single-title {

    margin: 0 0 15px 0;

    font-size: 28px;

    color: #333;

}



.soft-resto-single-infos {

    display: flex;

    flex-wrap: wrap;

    gap: 15px;

    margin-bottom: 20px;

}



.soft-resto-single-info {

    display: flex;

    align-items: center;

    gap: 5px;

}



.soft-resto-info-label {

    font-weight: 600;

    color: #555;

}



.soft-resto-info-value {

    color: #333;

}



.soft-resto-visit-button {

    display: inline-block;

    padding: 10px 20px;

    background: linear-gradient(45deg, #ff6b6b, #ff8e8e);

    color: white;

    text-decoration: none;

    border-radius: 6px;

    font-weight: 600;

    transition: all 0.3s ease;

}



.soft-resto-visit-button:hover {

    transform: translateY(-2px);

    box-shadow: 0 4px 8px rgba(255, 107, 107, 0.3);

}



.soft-resto-single-content {

    padding: 20px;

    line-height: 1.6;

}



.soft-resto-single-meals {

    margin-top: 30px;

    padding-top: 20px;

    border-top: 1px solid #eee;

}



.soft-resto-meals-list {

    display: flex;

    flex-wrap: wrap;

    gap: 10px;

    list-style: none;

    padding: 0;

    margin: 10px 0 0 0;

}



.soft-resto-meals-list li {

    background: #f8f8f8;

    padding: 5px 10px;

    border-radius: 4px;

    font-size: 14px;

}



/* Archive Restaurants */

.soft-resto-archive-container {

    max-width: 1200px;

    margin: 0 auto;

    padding: 0px;

}



.soft-resto-archive-header {

    margin-bottom: 30px;

    text-align: center;

}



.soft-resto-archive-title {

    margin: 0 0 10px 0;

    font-size: 32px;

    color: #333;

}



.soft-resto-archive-description {

    color: #666;

    max-width: 800px;

    margin: 0 auto;

    line-height: 1.6;

}



.soft-resto-archive-filters {

    margin-bottom: 30px;

    padding: 20px;

    background: white;

    border-radius: 8px;

    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);

}



.soft-resto-filter-form {

    display: flex;

    flex-wrap: wrap;

    gap: 15px;

}



.soft-resto-filter-group {

    flex: 1;

    min-width: 200px;

}



.soft-resto-filter-group label {

    display: block;

    margin-bottom: 5px;

    font-weight: 600;

    color: #555;

}



.soft-resto-filter-group select {

    width: 100%;

    padding: 10px;

    border: 2px solid #eee;

    border-radius: 6px;

    background: white;

}



.soft-resto-archive-grid {

    display: grid;

    grid-template-columns: repeat(2, 1fr);

    gap: 15px;

}



.soft-resto-archive-pagination {

    margin-top: 30px;

    text-align: center;

}



/* Responsive */

@media (min-width: 768px) {

    .soft-resto-archive-grid {

        grid-template-columns: repeat(3, 1fr);

    }



    .soft-resto-search-container {

    max-width: 100%;

    margin: 0 auto;

    padding: 20px;

}

    

    .soft-resto-single-meta {

        display: flex;

        flex-wrap: wrap;

        align-items: center;

        justify-content: space-between;

    }

    

    .soft-resto-single-infos {

        margin-bottom: 0;

        order: 1;

    }

}



@media (min-width: 1024px) {

    .soft-resto-archive-grid {

        grid-template-columns: repeat(4, 1fr);

    }

    

    .soft-resto-single-banner {

        height: 400px;

    }

}



/* Responsive */

@media (min-width: 768px) {

    .soft-resto-search-form {

        flex-direction: row;

    }

    

    #soft-resto-search-input {

        flex: 2;

    }

    

    .soft-resto-filters {

        flex: 1;

    }

    

    .soft-resto-results-grid {

        grid-template-columns: repeat(2, 1fr);

    }

}



@media (min-width: 1024px) {

    .soft-resto-results-grid {

        grid-template-columns: repeat(4, 1fr);

    }

}





/* Grille personnalisée */

.soft-resto-custom-grid {

    display: grid;

    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));

    gap: 10px;

    margin: 30px 0;

}



@media (max-width: 768px) {

    .soft-resto-custom-grid {

        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));

    }

}



.soft-resto-notice {

    padding: 15px;

    background: #f8f9fa;

    border-left: 4px solid #ff6b6b;

    margin: 20px 0;

    border-radius: 4px;

}



.soft-resto-current-city {

    font-weight: 600;

    color: #ff6b6b;

    padding: 3px 8px;

    border-radius: 4px;

    background-color: rgba(255, 107, 107, 0.1);

}



/* Structure de base */

.soft-resto-container {

    max-width: 1200px;

    margin: 0 auto;

    padding: 0px;

}





/* Grille responsive */

.soft-resto-grid {

    display: grid;

    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));

    gap: 20px;

    margin: 30px 0;

}



@media (max-width: 768px) {

    .soft-resto-grid {

        grid-template-columns: repeat(2, 1fr);

    }

}



/* Pagination */

.soft-resto-pagination {

    grid-column: 1 / -1;

    display: flex;

    justify-content: center;

    margin-top: 40px;

}



.soft-resto-pagination .page-numbers {

    padding: 8px 16px;

    margin: 0 5px;

    border: 1px solid #e0e0e0;

    border-radius: 4px;

    transition: all 0.3s ease;

}



.soft-resto-pagination .page-numbers.current {

    background-color: #ff6b6b;

    color: white;

    border-color: #ff6b6b;

}



.soft-resto-pagination a.page-numbers:hover {

    background-color: #f8f8f8;

}



.soft-resto-pagination-arrow {

    font-size: 18px;

}



/* Structure principale */

.soft-resto-single-container {

    max-width: 1200px;

    margin: 0 auto;

    padding: 10px 0px;

}



.soft-resto-single-grid {

    display: grid;

    grid-template-columns: 1fr;

    gap: 20px;

}



@media (min-width: 992px) {

    .soft-resto-single-grid {

        grid-template-columns: 1fr 1fr;

    }

}



/* Colonne de gauche - Image */

.soft-resto-single-left {

    position: relative;

}



.soft-resto-single-banner {

    border-radius: 12px;

    overflow: hidden;

    box-shadow: 0 10px 30px rgba(0,0,0,0.1);

}



.soft-resto-single-image {

    width: 100%;

    height: auto;

    display: block;

    transition: transform 0.3s ease;

}



.soft-resto-single-left:hover .soft-resto-single-image {

    transform: scale(1.02);

}



/* Colonne de droite - Contenu */

.soft-resto-single-right {

    padding: 0px;

}



.soft-resto-single-header {

    margin-bottom: 30px;

}



.soft-resto-single-title {

    font-size: 2.5rem;

    margin: 0 0 15px 0;

    color: #333;

    line-height: 1.2;

}



/* Bouton Visiter */

.soft-resto-visit-button {

    display: inline-flex;

    align-items: center;

    padding: 12px 25px;

    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);

    color: white;

    text-decoration: none;

    border-radius: 50px;

    font-weight: 600;

    transition: all 0.3s ease;

    box-shadow: 0 4px 15px rgba(255,107,107,0.3);

}



.soft-resto-visit-button i {

    margin-right: 10px;

}



.soft-resto-visit-button:hover {

    transform: translateY(-3px);

    box-shadow: 0 6px 20px rgba(255,107,107,0.4);

}



/* Contenu */

.soft-resto-single-content {

    line-height: 1.8;

    color: #555;

}



/* Grille des détails */

.soft-resto-details-grid {

    display: grid;

    grid-template-columns: 1fr;

    gap: 20px;

    margin-top: 40px;

}



.soft-resto-detail-card {

    display: flex;

    background: #fff;

    border-radius: 10px;

    padding: 20px;

    box-shadow: 0 5px 15px rgba(0,0,0,0.05);

    transition: transform 0.3s ease;

}



.soft-resto-detail-card:hover {

    transform: translateY(-5px);

}



.soft-resto-detail-icon {

    margin-right: 15px;

}



.soft-resto-detail-icon i {

    font-size: 1.5rem;

    color: #ff6b6b;

}



.soft-resto-detail-content h4 {

    margin: 0 0 8px 0;

    color: #333;

}



.soft-resto-detail-content p {

    margin: 0;

    color: #666;

}



/* Tags des repas */

.soft-resto-meals-tags {

    display: flex;

    flex-wrap: wrap;

    gap: 8px;

}



.soft-resto-meal-tag {

    background: #f8f8f8;

    padding: 5px 12px;

    border-radius: 20px;

    font-size: 0.9rem;

    color: #555;

}



/* Badge sponsorisé */

.soft-resto-sponsored-badge {

    position: absolute;

    top: 15px;

    left: 15px;

    background: linear-gradient(135deg, #8B4513, #DAA520);

    color: white;

    padding: 5px 15px;

    border-radius: 20px;

    font-size: 0.9rem;

    font-weight: 600;

    display: flex;

    align-items: center;

    z-index: 2;

}



.soft-resto-sponsored-badge i {

    margin-right: 5px;

    color: #FFD700;

}

/* ============================================= */
/* == Shortcode [soft_choix_ville]            == */
/* ============================================= */

.soft-ville-chooser-container {
    max-width: 500px;
    margin: 40px auto;
    padding: 30px;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    text-align: center;
    border: 1px solid #f0f0f0;
}

.soft-ville-chooser-container h2 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 24px;
    color: #333;
    font-weight: 600;
}

.soft-ville-chooser-container h2 .fas {
    color: #ff6b6b;
    margin-right: 10px;
}

.soft-ville-chooser-container p {
    margin-top: 0;
    margin-bottom: 25px;
    color: #666;
}

.soft-ville-chooser-form-wrapper {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

@media (min-width: 768px) {
    .soft-ville-chooser-form-wrapper {
        flex-direction: row;
        align-items: center;
    }
}

.soft-ville-select-wrapper {
    position: relative;
    flex-grow: 1;
}

.soft-ville-chooser-select {
    width: 100%;
    padding: 14px 45px 14px 20px;
    font-size: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 50px;
    background-color: #f9f9f9;
    color: #333;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.soft-ville-chooser-select:focus {
    outline: none;
    border-color: #ff8e8e;
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(255, 107, 107, 0.15);
}

.soft-ville-select-wrapper::after {
    content: '\f078'; /* Icône flèche bas de Font Awesome */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    color: #888;
    pointer-events: none;
    transition: color 0.3s ease;
}

.soft-ville-chooser-select:focus + .soft-ville-select-wrapper::after {
    color: #ff6b6b;
}


.soft-ville-chooser-submit {
    padding: 14px 25px;
    border: none;
    border-radius: 50px;
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

.soft-ville-chooser-submit:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4);
}

.soft-ville-chooser-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* ============================================= */
/* == Styles pour le chargement de la recherche == */
/* ============================================= */

/* Wrapper pour la barre de recherche */
.soft-resto-search-input-wrapper {
    position: relative;
    flex-grow: 2; /* Donne plus d'espace à la barre de recherche */
}

/* Positionnement de l'icône de chargement */
.soft-resto-loader {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    width: 24px; /* Ajustez la taille si besoin */
    height: 24px; /* Ajustez la taille si besoin */
    display: none; /* Cachée par défaut */
    z-index: 2;
}

/* Ajustement de la barre de recherche pour ne pas que le texte passe sous l'icône */
#soft-resto-search-input {
    width: 100%;
    box-sizing: border-box; /* Assure que le padding est inclus dans la largeur */
    padding-right: 45px !important; /* Espace pour l'icône */
}

/* Style et positionnement du badge de prix */
.soft-resto-price-badge {
    position: absolute;
    bottom: 5px;
    left: 5px;
    z-index: 10;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
    color: #fff;
    padding: 1px 1px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
}

/* ============================================= */
/* == Statut Ouvert/Fermé (Pastille)          == */
/* ============================================= */

.soft-resto-status-dot, .soft-resto-status-dot-placeholder {
    position: absolute;
    bottom: 5px; 
    right: 5px; 
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid white; 
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    z-index: 5;
    background-color: #bdc3c7; /* Couleur grise par défaut/chargement */
    transition: background-color 0.3s ease;
}

.soft-resto-status-dot.open {
    background-color: #2ecc71; /* Vert */
}

.soft-resto-status-dot.closed {
    background-color: #e74c3c; /* Rouge */
}

/* ============================= */
/* == Système d'avis          == */
/* ============================= */

/* Section principale des avis */
.soft-resto-reviews-section {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid #e0e0e0;
}
.soft-resto-reviews-section h2 {
    font-size: 2rem;
    margin-bottom: 20px;
}

/* Formulaire d'avis */
.soft-resto-review-form {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 40px;
}
.soft-resto-review-form h3 {
    margin-top: 0;
}
.soft-resto-review-form .form-group {
    margin-bottom: 15px;
}
.soft-resto-review-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
}
.soft-resto-review-form select,
.soft-resto-review-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
}
.soft-resto-submit-review {
    background: #ff6b6b;
    color: white;
    border: none;
    padding: 12px 25px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}
.soft-resto-submit-review:hover {
    background: #ff4757;
}

/* Liste des avis */
.soft-resto-reviews-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
}
.soft-resto-review-item {
    display: flex;
    gap: 20px;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}
.review-author {
    flex-shrink: 0;
    text-align: center;
}
.review-author img {
    border-radius: 50%;
    margin-bottom: 5px;
}
.review-date {
    font-size: 0.8rem;
    color: #777;
}
.review-content p {
    margin: 10px 0;
    line-height: 1.6;
}

/* Affichage des étoiles */
.review-rating { display: flex; align-items: center; gap: 10px; }
.stars-outer {
    position: relative;
    display: inline-block;
    font-family: 'Font Awesome 6 Free';
}
.stars-inner {
    position: absolute;
    top: 0;
    left: 0;
    white-space: nowrap;
    overflow: hidden;
    width: 0;
    color: #f8ce0b;
}
.stars-outer::before {
    content: '\f005 \f005 \f005 \f005 \f005'; /* 5 étoiles vides */
    font-weight: 400; /* regular */
    color: #ccc;
}

/* Résumé de la note sur la carte */
.soft-resto-rating-summary {
    color: #f8ce0b;
    font-weight: bold;
}
.soft-resto-rating-summary i {
    color: #f8ce0b;
}

/* Bouton Signaler */
.soft-resto-report-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 0.8rem;
    cursor: pointer;
}
.soft-resto-report-btn:hover {
    color: #e74c3c;
    text-decoration: underline;
}

/* Message de succès/notice */
.soft-resto-notice.success {
    border-left-color: #2ecc71;
    background-color: rgba(46, 204, 113, 0.1);
}

/* Rendre la ligne de note cliquable visuellement */
.soft-resto-rating-link {
    cursor: pointer;
    transition: transform 0.2s ease;
}

.soft-resto-rating-link:hover {
    transform: scale(1.03); /* Léger effet de zoom au survol */
}

/*
==============================================
Styles pour le slider sur les cartes
==============================================
*/

.soft-resto-card {
    position: relative; /* Indispensable pour positionner les éléments absolus */
    overflow: hidden;
}

.soft-resto-card .soft-resto-card-banner {
    position: relative; /* Contexte pour le positionnement des badges et du bouton */
}

.soft-resto-slider {
    width: 100%;
    height: 100%;
}

.soft-resto-slider .swiper-slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* ✅ AJOUTEZ CE NOUVEAU STYLE pour le conteneur des avis */
.soft-resto-rating-wrapper {
    display: flex;
    justify-content: space-between; /* Pousse la note à gauche et le bouton à droite */
    align-items: center;            /* Aligne verticalement l'icône coeur et l'étoile */
    width: 100%;
}

/* ✅ MODIFIEZ le nom de cette classe */
.soft-resto-delivery-wrapper { /* Ancien nom : .soft-resto-rating-wrapper */
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

/* Style des flèches de navigation */
.soft-resto-card .swiper-button-next,
.soft-resto-card .swiper-button-prev {
    color: #fff;
    background-color: rgba(0, 0, 0, 0.3);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    transition: opacity 0.3s;
    opacity: 0;
    z-index: 15;
}
.soft-resto-card:hover .swiper-button-next,
.soft-resto-card:hover .swiper-button-prev {
    opacity: 1;
}

.soft-resto-card .swiper-button-next::after,
.soft-resto-card .swiper-button-prev::after {
    font-size: 14px;
    font-weight: bold;
}

/* Style de la pagination */
.soft-resto-card .swiper-pagination {
    bottom: 5px !important;
    z-index: 10;
}
.soft-resto-card .swiper-pagination-bullet {
    background-color: rgba(255, 255, 255, 0.7);
    opacity: 1;
}
.soft-resto-card .swiper-pagination-bullet-active {
    background-color: #fff;
}

/* ✅ AJOUT : Masquer les flèches sur mobile */
@media (max-width: 767px) {
    .soft-resto-card .swiper-button-next,
    .soft-resto-card .swiper-button-prev {
        display: none;
    }
}

/* ============================================= */
/* == Style pour le lien de catégorie sur la carte == */
/* ============================================= */

.soft-resto-meta-item a {
    color: inherit; /* Le lien aura la même couleur que le texte normal */
    text-decoration: none; /* On enlève le soulignement par défaut */
    transition: color 0.2s ease;
}

.soft-resto-meta-item a:hover {
    color: #ff6b6b; /* Au survol, le lien prend la couleur principale du thème */
    text-decoration: underline; /* On ajoute un soulignement au survol */
}

/* ======================================================= */
/* == NOUVEAU STYLE ÉLÉGANT POUR LE BOUTON FAVORI      == */
/* ======================================================= */

/* On garde les règles de base pour la superposition qui fonctionnent */
.soft-resto-card-banner {
    height: 130px;

    overflow: hidden;

    border-radius: 12px 12px 0 0;

    border: 3px solid;

    border-image: linear-gradient(45deg, #ff9a9e, #fad0c4) 1;

    position: relative;
}
.soft-resto-card-banner .soft-resto-card-banner-link {
    z-index: 1 !important;
}

/* --- Style principal du bouton --- */
.soft-resto-card-banner .soft-resto-favorite-btn {
    /* Positionnement précis et superposition */
    position: absolute !important;
    z-index: 100 !important;
    top: 5px;      /* Plus proche du coin */
    right: 5px;     /* Plus proche du coin */
    left: auto;

    /* Apparence visuelle */
    width: 20px;   /* Taille légèrement réduite */
    height: 20px;
    background-color: rgba(0, 0, 0, 0.3); /* Fond sombre et transparent */
    border: 1px solid rgba(255, 255, 255, 0.4); /* Fine bordure blanche transparente */
    border-radius: 50%;
    box-shadow: 0 1px 4px rgba(0,0,0,0.15); /* Ombre plus subtile */
    backdrop-filter: blur(4px); /* Effet de verre dépoli pour la lisibilité */
    cursor: pointer;

    /* Centrage de l'icône à l'intérieur */
    display: flex;
    align-items: center;
    justify-content: center;

    /* Animation douce */
    transition: all 0.25s ease-in-out;
}

/* --- Style de l'icône (le coeur) --- */
.soft-resto-card-banner .soft-resto-favorite-btn i {
    font-size: 16px;
    line-height: 1; /* Assure un centrage parfait */
    color: #ffffff; /* Icône blanche par défaut pour un bon contraste */
    transition: all 0.2s ease;
    /* On retire la marge de l'icône pour un meilleur centrage */
    margin-right: 0;
}

/* --- Style au survol (hover) --- */
.soft-resto-card-banner .soft-resto-favorite-btn:hover {
    transform: scale(1.1);
    background-color: rgba(0, 0, 0, 0.5); /* Un peu plus foncé au survol */
}

/* --- Style quand le restaurant EST en favori (classe .active) --- */
.soft-resto-card-banner .soft-resto-favorite-btn.active {
    background-color: #e03131; /* Un rouge vif et moderne */
    border-color: rgba(255, 255, 255, 0.6); /* Bordure un peu plus visible */
}

.soft-resto-card-banner .soft-resto-favorite-btn.active i {
    transform: scale(1.1); /* Petite animation sur l'icône active */
    color: #ffffff; /* On s'assure que le coeur reste blanc sur fond rouge */
}

/* ======================================================= */
/* == STYLE POUR LE RÉSUMÉ (NOTE ET FAVORIS) SUR LA FICHE == */
/* ======================================================= */

.soft-resto-summary-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 20px; /* Espace vertical et horizontal */
    margin: 15px 0;
}

.soft-resto-summary-rating,
.soft-resto-summary-favorites {
    display: flex;
    align-items: center;
    font-size: 1.25rem; /* Taille de police plus grande */
    font-weight: 700;
}

/* Style spécifique pour la note */
.soft-resto-summary-rating {
    color: #333;
    text-decoration: none;
    transition: all 0.2s ease;
    background-color: #f8f9fa;
    padding: 8px 15px;
    border-radius: 50px;
    border: 1px solid #e0e0e0;
}

.soft-resto-summary-rating:hover {
    background-color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

.soft-resto-summary-rating i {
    color: #f8ce0b; /* Étoile jaune */
    font-size: 1.1rem;
    margin-right: 8px;
}

.soft-resto-summary-rating span {
    font-size: 1rem;
    font-weight: 500;
    color: #666;
    margin-left: 8px;
}

/* Style spécifique pour les favoris */
.soft-resto-summary-favorites {
    color: #555;
}

.soft-resto-summary-favorites i {
    color: #ff4757; /* Coeur rouge */
    font-size: 1.1rem;
    margin-right: 8px;
}

/* ======================================================= */
/* == STYLE POUR LA NOUVELLE GALERIE PHOTO              == */
/* ======================================================= */

/* Conteneur principal de la galerie */
.soft-resto-photo-gallery-wrapper {
    position: relative;
}

/* Style de l'image principale (Héro) */
.hero-item {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 10px;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.hero-item .soft-resto-single-image {
    transition: transform 0.4s ease-out;
}

.hero-item:hover .soft-resto-single-image {
    transform: scale(1.05);
}

/* Superposition sur l'image Héro */
.hero-overlay {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    padding: 8px 15px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(4px);
    transition: all 0.3s ease;
}

.hero-item:hover .hero-overlay {
    background-color: rgba(0, 0, 0, 0.7);
    transform: scale(1.05);
}

/* Grille pour les miniatures */
.thumbnail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
}

/* Style de chaque miniature */
.thumbnail-grid .gallery-item {
    display: block;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.thumbnail-grid .gallery-item:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.thumbnail-grid .gallery-item img {
    width: 100%;
    height: 80px; /* Hauteur fixe pour des miniatures uniformes */
    object-fit: cover; /* Assure que l'image remplit l'espace sans se déformer */
    display: block;
}

/* ======================================================= */
/* == STYLE POUR LA GALERIE PHOTO INTELLIGENTE          == */
/* ======================================================= */

/* On rend chaque miniature "relative" pour positionner le calque "+ photos" par-dessus */
.thumbnail-grid .gallery-item.thumbnail-item {
    position: relative;
}

/* Style du calque "+ XX photos" */
.more-photos-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    color: #fff;
    font-size: 1.5rem;
    font-weight: 700;
    border-radius: 8px; /* Doit correspondre au radius des miniatures */
    pointer-events: none; /* Permet de cliquer sur l'image en dessous */
    
    /* Gère l'affichage et le centrage du texte */
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0; /* Caché par défaut */
    transition: opacity 0.3s ease;
}

/* --- VUE MOBILE PAR DÉFAUT (jusqu'à 767px) --- */

/* On cache les miniatures à partir de la 5ème (index 4) */
.thumbnail-item:nth-child(n+5) {
    display: none;
}

/* Sur la 4ème miniature, si le calque mobile existe, on l'affiche */
.thumbnail-item:nth-child(4) .more-photos-mobile {
    opacity: 1;
}

/* On s'assure que le calque desktop est bien caché sur mobile */
.more-photos-desktop {
    display: none;
}

/* --- VUE PC (à partir de 768px) --- */
@media (min-width: 768px) {
    
    /* On ré-affiche les miniatures de la 5ème à la 8ème */
    .thumbnail-item:nth-child(n+5):nth-child(-n+8) {
        display: block;
    }

    /* On cache les miniatures à partir de la 9ème */
    .thumbnail-item:nth-child(n+9) {
        display: none;
    }

    /* On cache le calque mobile */
    .more-photos-mobile {
        display: none;
    }

    /* On ré-affiche le calque desktop (car il était en display:none) */
    .more-photos-desktop {
        display: flex;
    }

    /* Sur la 8ème miniature, si le calque desktop existe, on l'affiche */
    .thumbnail-item:nth-child(8) .more-photos-desktop {
        opacity: 1;
    }
}

/* ======================================================= */
/* == STYLE POUR LE TABLEAU DE BORD ET FORMULAIRE FRONT-END == */
/* ======================================================= */

/* Tableau de bord */
.soft-resto-dashboard { background: #fff; padding: 25px; border-radius: 8px; box-shadow: 0 4px 15px rgba(0,0,0,0.07); }
.soft-resto-dashboard h2 { margin-top: 0; }
.soft-resto-dashboard ul { list-style: none; padding: 0; margin-top: 20px; }
.soft-resto-dashboard li { display: flex; align-items: center; padding: 15px 0; border-bottom: 1px solid #f0f0f0; }
.soft-resto-dashboard li:last-child { border-bottom: none; }
.soft-resto-dashboard .status { font-size: 0.8em; padding: 4px 8px; border-radius: 4px; color: #fff; margin-left: auto; margin-right: 15px; }
.soft-resto-dashboard .status.publish { background: #2ecc71; }
.soft-resto-dashboard .status.pending { background: #f39c12; }
.soft-resto-dashboard .edit-link { font-weight: 600; }
.soft-resto-btn-add { display: inline-block; background: #ff6b6b; color: #fff; padding: 10px 20px; text-decoration: none; border-radius: 5px; margin-bottom: 20px; }

/* Formulaire de soumission */
.soft-resto-submission-form { background: #fff; padding: 25px; border-radius: 8px; }
.soft-resto-submission-form h2 { margin-top: 0; }
.soft-resto-submission-form label { display: block; font-weight: 600; margin-bottom: 5px; }
.soft-resto-submission-form input[type="text"],
.soft-resto-submission-form input[type="tel"] { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 4px; }
.soft-resto-submission-form .wp-editor-wrap { border: 1px solid #ccc; border-radius: 4px; }
.soft-resto-submission-form button[type="submit"] { background: #ff6b6b; color: #fff; border: none; padding: 12px 25px; font-size: 16px; border-radius: 5px; cursor: pointer; }

/* ======================================================= */
/* == STYLE POUR LE CHAMP GALERIE DU FORMULAIRE FRONT-END == */
/* ======================================================= */

/* Conteneur pour le champ de la galerie */
.gallery-field-wrapper {
    background-color: #f8f9fa;
    border: 1px solid #e0e0e0;
    padding: 20px;
    border-radius: 4px;
    margin-top: 20px;
}

/* Conteneur pour les miniatures des images existantes */
.existing-images-preview {
    margin-top: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* Style de chaque miniature */
.existing-images-preview img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    border: 2px solid #ddd;
}

/* ======================================================= */
/* == STYLE POUR LES HORAIRES D'OUVERTURE (FORMULAIRE)  == */
/* ======================================================= */

.opening-hours-wrapper {
    background-color: #f8f9fa;
    border: 1px solid #e0e0e0;
    padding: 20px;
    border-radius: 4px;
    margin-top: 20px;
}

.opening-hours-wrapper > label {
    font-size: 1.1em;
    font-weight: 600;
    display: block;
    margin-bottom: 15px;
}

.day-hours-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.day-hours-row:last-child {
    margin-bottom: 0;
}

.day-label {
    font-weight: 500;
    flex-basis: 100px; /* Donne une largeur fixe au label du jour */
}

.time-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.time-inputs input[type="time"] {
    padding: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

/* ======================================================= */
/* == STYLE POUR LE BLOC HORAIRES D'OUVERTURE (FICHE)   == */
/* ======================================================= */

.soft-resto-opening-hours-card {
    background: #fff;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin-top: 20px;
}

/* En-tête du bloc (Titre + Statut) */
.hours-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.hours-header h4 {
    margin: 0;
    font-size: 1.1rem;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.hours-header h4 i {
    color: #ff6b6b;
}

/* Indicateur de statut (Ouvert/Fermé) */
.status-indicator {
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.85rem;
    color: #fff;
}

.status-indicator.open {
    background-color: #2ecc71; /* Vert */
}

.status-indicator.closed {
    background-color: #e74c3c; /* Rouge */
}

/* Liste des jours */
.hours-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.hours-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 0.95rem;
}

.hours-row .day {
    color: #555;
}

.hours-row .time {
    font-weight: 600;
    color: #333;
}

.hours-row .closed-text {
    color: #999;
    font-style: italic;
    font-weight: 500;
}

/* Style pour mettre en évidence le jour actuel */
.hours-row.is-today {
    color: #ff6b6b;
}
.hours-row.is-today .day,
.hours-row.is-today .time {
    font-weight: 700;
    color: #ff6b6b;
}

/* ============================================= */
/* == STYLE POUR LES IMAGES DANS LES AVIS     == */
/* ============================================= */

/* Champ d'upload dans le formulaire */
.soft-resto-review-form input[type="file"] {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
}

/* Galerie d'images sous un commentaire */
.review-images {
    margin-top: 15px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.review-images a {
    display: block;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.2s ease;
}

.review-images a:hover {
    transform: scale(1.05);
}

.review-images img {
    display: block;
    width: 50px;
    height: 50px;
    object-fit: cover;
}

/* Style pour le niveau de prix sur la fiche */
.soft-resto-summary-price {
    display: flex;
    align-items: center;
    font-size: 1.25rem;
    font-weight: 700;
    color: #555;
}

.soft-resto-summary-price i {
    color: #27ae60; /* Une couleur verte pour l'argent */
    font-size: 1.1rem;
    margin-right: 8px;
}

/* --- STYLE DU TABLEAU DE BORD PROPRIO --- */
.soft-resto-dashboard .mycred-balance {
    font-size: 1.1em;
    background-color: #f8f9fa;
    padding: 10px 15px;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
    display: inline-block;
    margin-bottom: 20px;
}

.restaurant-dashboard-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.restaurant-dashboard-list li {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.07);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.restaurant-dashboard-list .restaurant-info {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-grow: 1;
}

/* --- CORRECTION RESPONSIVE POUR LE FORMULAIRE DE SPONSORING DU TABLEAU DE BORD --- */
@media (max-width: 767px) {
  .restaurant-dashboard-list li {
    flex-direction: column; /* Fait en sorte que les infos du resto et le formulaire se placent l'un sous l'autre */
    align-items: flex-start; /* Aligne tout à gauche */
  }

  .sponsorship-form-wrapper {
    width: 100%; /* Le conteneur du formulaire prend toute la largeur */
    text-align: left; /* Le texte à l'intérieur est aligné à gauche */
    margin-top: 15px; /* Ajoute un peu d'espace avec les infos du restaurant au-dessus */
  }

  .soft-resto-sponsorship-form {
    flex-direction: column; /* Le champ et le bouton se placent l'un sous l'autre */
    align-items: stretch; /* Les deux éléments s'étirent sur toute la largeur */
  }

  .sponsorship-days-input,
  .buy-sponsorship-btn {
    width: 100%; /* Force le champ et le bouton à prendre 100% de la largeur */
    text-align: center; /* Centre le texte à l'intérieur pour un meilleur look */
  }
}

/* --- STYLE DU FORMULAIRE DE SPONSORING --- */
.sponsorship-form-wrapper {
    text-align: right;
    flex-shrink: 0;
}

.sponsorship-status {
    display: block;
    font-size: 0.9em;
    color: #666;
    margin-bottom: 8px;
}

.soft-resto-sponsorship-form {
    display: flex;
    gap: 8px;
}

.sponsorship-days-input {
    width: 120px;
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 20px;
    text-align: center;
}

.buy-sponsorship-btn {
    background: linear-gradient(135deg, #1e90ff, #00bfff);
    color: white;
    border: none;
    padding: 8px 18px;
    font-size: 0.9em;
    font-weight: 600;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.buy-sponsorship-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(30, 144, 255, 0.3);
}

.buy-sponsorship-btn:disabled {
    background: #bdc3c7;
    cursor: not-allowed;
}

.buy-sponsorship-btn .cost {
    font-weight: bold;
}

/* --- STYLE DU POPUP DE CODE PARRAIN --- */
#referral-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.3s ease;
}
#referral-popup-overlay.referral-popup-hidden {
    display: none;
    opacity: 0;
}
#referral-popup-box {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.2);
    width: 90%;
    max-width: 450px;
    text-align: center;
    position: relative;
}
#referral-popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    color: #aaa;
    cursor: pointer;
}
#referral-popup-box h3 {
    margin-top: 0;
    font-size: 1.5em;
}
#referral-code-form {
    margin-top: 20px;
}
#referral-code-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    text-align: center;
    font-size: 1.1em;
    margin-bottom: 15px;
}
#referral-code-form button {
    width: 100%;
    padding: 12px;
    background-color: #ff6b6b;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1.1em;
    font-weight: bold;
    cursor: pointer;
}
#referral-popup-feedback {
    margin-top: 10px;
    font-weight: bold;
    min-height: 1.2em;
}
#referral-popup-dismiss {
    margin-top: 15px;
    font-size: 0.9em;
    color: #999;
    text-decoration: underline;
}