/* ==========================================
    CONTAINER PRINCIPAL
========================================== */
.carte {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2em;
}

/* ==========================================
    GROUPES DE CATÉGORIES
========================================== */
.carte .group {
    margin: 0 0 3em 0;
    position: relative;
    padding: 2em;
    background: var(--color0);
    border-radius: var(--border-radius);
    border: 1px solid rgba(var(--color4_rgb), 0.06);
    transition: all 0.4s ease;
}

.carte .group:hover {
    box-shadow: 0 8px 40px rgba(var(--color4_rgb), 0.08);
    border-color: rgba(var(--color1_rgb), 0.1);
}

/* Barre latérale animée */
.carte .group::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 3px;
    height: 0;
    background: linear-gradient(to bottom, var(--color1), var(--color2));
    transition: height 0.5s ease;
    border-radius: var(--border-radius) 0 0 var(--border-radius);
}

.carte .group:hover::before {
    height: 100%;
}

.carte .group::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translateY(-50%);
    width: 120px;
    height: 120px;
    opacity: 0.04;
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.carte .group:hover::after {
    opacity: 0.08;
}

/* SVG funambule - fil */
.carte .group:nth-child(4n+1)::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath d='M10 80 Q50 20 90 80' stroke='%23A63A3A' stroke-width='2' fill='none'/%3E%3Ccircle cx='50' cy='50' r='8' fill='%23A63A3A'/%3E%3Cline x1='50' y1='42' x2='50' y2='25' stroke='%23A63A3A' stroke-width='2'/%3E%3Cline x1='50' y1='58' x2='50' y2='75' stroke='%23A63A3A' stroke-width='2'/%3E%3Cline x1='42' y1='50' x2='25' y2='45' stroke='%23A63A3A' stroke-width='2'/%3E%3Cline x1='58' y1='50' x2='75' y2='45' stroke='%23A63A3A' stroke-width='2'/%3E%3C/svg%3E");
}

/* SVG étoile cirque */
.carte .group:nth-child(4n+2)::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpolygon points='50,5 61,40 98,40 68,62 79,97 50,75 21,97 32,62 2,40 39,40' fill='none' stroke='%23D6A635' stroke-width='2'/%3E%3C/svg%3E");
}

/* SVG chapiteau */
.carte .group:nth-child(4n+3)::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath d='M50 10 L85 70 L15 70 Z' fill='none' stroke='%23A63A3A' stroke-width='2'/%3E%3Cline x1='50' y1='10' x2='50' y2='0' stroke='%23D6A635' stroke-width='2'/%3E%3Cpath d='M15 70 Q50 85 85 70' fill='none' stroke='%23A63A3A' stroke-width='2'/%3E%3Cline x1='50' y1='10' x2='35' y2='70' stroke='%23A63A3A' stroke-width='1' stroke-dasharray='3,3'/%3E%3Cline x1='50' y1='10' x2='65' y2='70' stroke='%23A63A3A' stroke-width='1' stroke-dasharray='3,3'/%3E%3C/svg%3E");
}

/* SVG balancier */
.carte .group:nth-child(4n)::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cline x1='10' y1='50' x2='90' y2='50' stroke='%23D6A635' stroke-width='3'/%3E%3Ccircle cx='10' cy='50' r='6' fill='none' stroke='%23A63A3A' stroke-width='2'/%3E%3Ccircle cx='90' cy='50' r='6' fill='none' stroke='%23A63A3A' stroke-width='2'/%3E%3Ccircle cx='50' cy='50' r='3' fill='%23A63A3A'/%3E%3C/svg%3E");
}

/* ==========================================
    TITRES DE CATÉGORIE
========================================== */
.group h2 {
    font-family: var(--font_family_1);
    font-size: calc(var(--taille_font) * 3.2);
    font-weight: 400;
    color: var(--color1);
    padding: 0.1em 0 0.2em;
    margin-bottom: 0.5em;
    position: relative;
    /* letter-spacing: 0.03em; */
}

.group h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, var(--color2), transparent);
}
.group h2.h1::after {display: none;}
/* ==========================================
    LISTE DES PLATS
========================================== */
.carte ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.carte ul li.item {
    display: flex;
    align-items: flex-start;
    width: 100%;
    padding: 1.2em 0.5em;
    border-bottom: 1px solid rgba(var(--color4_rgb), 0.06);
    position: relative;
    transition: all 0.3s ease;
}

.carte ul li.item:last-child {
    border-bottom: none;
}

.carte ul li.item:hover {
    background: linear-gradient(90deg, rgba(var(--color2_rgb), 0.03), transparent);
    padding-left: 1em;
    margin-left: -1em;
    margin-right: -1em;
    padding-right: 1em;
    border-radius: var(--border-radius);
}

/* Titre ligne multiprix */
.carte ul li.item.multiprix {
    display: flex;
    justify-content: flex-end;
    gap: 0;
    padding: 0.5em 0;
    border-bottom: none;
}

.carte ul li.item.multiprix .cellule {
    display: inline-block;
}

.carte ul li.item.multiprix .titre {
    font-family: var(--font_family_2);
    font-size: 0.9em;
    color: var(--color2);
    font-weight: 600;
    text-transform: uppercase;
    /* letter-spacing: 0.1em; */
}

/* ==========================================
    STRUCTURE TABLEAU PLAT
========================================== */
.carte .tableau {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    width: 100%;
    gap: 1em;
}

.carte .item-title {
    flex: 1;
    padding-right: 1em;
}

.carte .item-title span {
    font-family: var(--font_family_2);
    font-size: calc(var(--taille_font) * 1.1);
    font-weight: 600;
    color: var(--color3);
    text-transform: uppercase;
    /* letter-spacing: 0.05em; */
    display: block;
    transition: color 0.3s ease;
}

.carte ul li.item:hover .item-title span {
    color: var(--color1);
}

.carte .item-title small {
    display: block;
    font-family: var(--font_family_3);
    font-size: 0.95em;
    font-weight: 400;
    color: rgba(var(--color4_rgb), 0.7);
    text-transform: none;
    margin-top: 0.4em;
    line-height: 1.5;
    font-style: italic;
}

/* ==========================================
    PRIX
========================================== */
.carte .price {
    font-family: var(--font_family_2);
    font-size: 1.2em;
    font-weight: 600;
    color: var(--color1);
    white-space: nowrap;
    min-width: 80px;
    text-align: right;
    padding-top: 0.2em;
    position: relative;
}

.carte .price::before {
    content: '';
    position: absolute;
    left: -1em;
    top: 50%;
    width: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(var(--color2_rgb), 0.3));
    transition: width 0.3s ease;
}

.carte ul li.item:hover .price::before {
    width: 1em;
}

/* Prix multiples */
.carte ul li.item.multiprix .price {
    text-align: center;
    min-width: 100px;
    font-size: 1em;
    padding: 0;
}

.carte ul li.item.multiprix .price::before {
    display: none;
}

.carte .tableau .price1,
.carte .tableau .price2 {
    min-width: 100px;
    text-align: center;
}

/* ==========================================
    SECTION VÉGÉTARIENNE - STYLE SPÉCIAL
========================================== */
.carte .group-12 {
    background: linear-gradient(135deg, rgba(var(--color2_rgb), 0.03), transparent);
}

.carte .group-12 h2 {
    color: var(--color2);
}

.carte .group-12 h2::after {
    background: linear-gradient(90deg, var(--color1), transparent);
}

/* ==========================================
    RESPONSIVE
========================================== */
@media (max-width: 768px) {
    .carte {
        padding: 0;
    }

    .carte .group {
        padding: 1.5em 1em;
        margin-bottom: 2em;
    }

    .carte .group::after {
        display: none;
    }

    .group h2 {
        font-size: calc(var(--taille_font) * 2.5);
    }

    .carte .tableau {
        flex-direction: column;
        gap: 0.5em;
    }

    .carte .price {
        text-align: left;
        min-width: auto;
    }

    .carte .price::before {
        display: none;
    }

    .carte ul li.item:hover {
        padding-left: 0.5em;
        margin-left: -0.5em;
        margin-right: -0.5em;
        padding-right: 0.5em;
    }

    .carte ul li.item.multiprix {
        justify-content: space-around;
    }

    .carte .tableau .price1,
    .carte .tableau .price2 {
        min-width: 70px;
    }
}

/* ==========================================
    ANIMATIONS
========================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.carte .group {
    animation: fadeInUp 0.6s ease forwards;
    opacity: 0;
}

.carte .group:nth-child(1) {
    animation-delay: 0.1s;
}

.carte .group:nth-child(2) {
    animation-delay: 0.2s;
}

.carte .group:nth-child(3) {
    animation-delay: 0.3s;
}

.carte .group:nth-child(4) {
    animation-delay: 0.4s;
}

.carte .group:nth-child(5) {
    animation-delay: 0.5s;
}

.carte .group:nth-child(6) {
    animation-delay: 0.6s;
}

.carte .group:nth-child(7) {
    animation-delay: 0.7s;
}

.carte .group:nth-child(8) {
    animation-delay: 0.8s;
}