/* ============================================================================
   PIZZA HUB STOREFRONT v8.0.0 — FAST-FOOD UNIFIED DESIGN SYSTEM
   Complète ph-themes-core.css sur les 10 thèmes (100% Marque Blanche).
   Zéro parallaxe • Zéro scroll-jacking • Corps >=16px • Tap >=48px
   ============================================================================ */

*, *::before, *::after { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: 148px;
    background: var(--ph-bg);
    overflow-x: clip;
    font-size: 16px;
}
html[data-ph-font-scale="compact"] { font-size: 15px; }
html[data-ph-font-scale="large"] { font-size: 17.5px; }

h1, h2, h3, .v8-brand, .v8-hero-title, .v8-section-title, .v8-bento-title {
    font-family: var(--ph-font-display);
    font-weight: var(--ph-font-display-weight, 700) !important;
}

/* ============================================================================
   V9.0 — ACCUEIL BEST-SELLERS, PAGE /commander/ & IMAGES 4:3 MAÎTRISÉES
   ============================================================================ */
.v9-bestsellers-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}
.v9-home-cat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}
.v9-order-hero {
    padding: 32px 0 18px;
}
.v9-order-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    align-items: start;
    padding-top: 24px;
    padding-bottom: 64px;
}
.v9-order-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}
.v9-desktop-cart {
    position: sticky;
    top: 158px;
}
.v9-desktop-cart-card {
    background: var(--ph-surface);
    border: 1px solid var(--ph-border);
    border-radius: var(--ph-radius-card, 20px);
    box-shadow: var(--ph-shadow-card, 0 12px 30px rgba(15, 23, 42, 0.06));
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 180px);
}
.v9-desktop-cart-head {
    padding: 16px 20px;
    border-bottom: 1px solid var(--ph-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.v9-desktop-cart-body {
    padding: 14px 20px;
    overflow-y: auto;
    flex: 1;
}
.v9-desktop-cart-foot {
    padding: 16px 20px;
    border-top: 1px solid var(--ph-border);
    background: var(--ph-surface);
}
.v9-side-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--ph-border);
}
.v9-side-item:last-child { border-bottom: none; }
.v9-side-qty {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--ph-bg);
    border: 1px solid var(--ph-border);
    border-radius: 999px;
    padding: 3px 6px;
    flex-shrink: 0;
}
.v9-side-qty button {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    border: none;
    background: var(--ph-surface);
    color: var(--ph-text);
    font-weight: 800;
    cursor: pointer;
}
/* Proportions d'images maîtrisées 4/3 & cartes respirantes */
.product-card .card-media,
.v8-card-media {
    aspect-ratio: 4 / 3 !important;
    background: var(--ph-bg, #F3F4F6);
    overflow: hidden;
}
.product-card .card-media img,
.v8-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}
@media (max-width: 1279px) {
    .v9-order-layout { grid-template-columns: 1fr; }
    .v9-desktop-cart { display: none; }
    .v9-order-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
    .v9-bestsellers-grid,
    .v9-order-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
    .v9-home-cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .v8-header-cta-order { display: none !important; }
    .v9-bestsellers-grid,
    .v9-order-grid { grid-template-columns: 1fr; gap: 16px; }
}

body {
    margin: 0;
    padding: 0;
    background: var(--ph-bg);
    color: var(--ph-text);
    font-family: var(--ph-font-body);
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select { font-family: inherit; }

.v8-container,
.ph-container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

/* ============================================================================
   1. HEADER STICKY (72PX) + MENU MOBILE PLEIN ÉCRAN
   ============================================================================ */
.v8-header {
    position: sticky;
    top: 0;
    z-index: 110;
    height: 74px;
    background: var(--ph-surface);
    border-bottom: 1px solid var(--ph-border);
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.04);
}

[data-ph-theme="american-diner"] .v8-header {
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    border-bottom-color: rgba(255, 255, 255, 0.16);
}

[data-ph-theme="flame-express"] .v8-header {
    background: var(--ph-hero-bg);
    color: var(--ph-hero-text);
    border-bottom-color: rgba(140, 15, 24, 0.16);
}

.v8-header-inner {
    height: 74px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.v8-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--ph-font-display);
    font-size: 24px;
    line-height: 1;
    letter-spacing: -0.01em;
    color: inherit;
    flex-shrink: 0;
}

.v8-brand img {
    height: 38px;
    width: auto;
    max-width: 140px;
    border-radius: 10px;
    object-fit: contain;
}

.v8-brand-accent {
    color: var(--ph-primary);
}

[data-ph-theme="american-diner"] .v8-brand-accent {
    color: var(--ph-accent);
}

.v8-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.v8-nav a {
    padding: 9px 14px;
    border-radius: var(--ph-radius-btn);
    font-size: 15px;
    font-weight: 700;
    white-space: nowrap;
    transition: background-color 180ms var(--ph-ease), transform 140ms var(--ph-ease);
}

.v8-nav a:hover {
    background: rgba(128, 128, 128, 0.12);
}

.v8-header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.v8-mode-seg {
    display: inline-flex;
    padding: 3px;
    border-radius: var(--ph-radius-btn);
    background: rgba(20, 20, 22, 0.08);
}

[data-ph-theme="american-diner"] .v8-mode-seg,
[data-ph-theme="midnight-bucket"] .v8-mode-seg {
    background: rgba(255, 255, 255, 0.14);
}

.v8-mode-seg .mode-btn {
    min-height: 36px;
    padding: 0 13px;
    border: none;
    border-radius: var(--ph-radius-btn);
    background: transparent;
    color: inherit;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    opacity: 0.78;
    transition: background-color 180ms var(--ph-ease), color 180ms var(--ph-ease), opacity 180ms ease;
}

.v8-mode-seg .mode-btn.is-active {
    background: var(--ph-surface);
    color: var(--ph-text);
    opacity: 1;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
}

.v8-active-order-pill {
    display: none;
    align-items: center;
    gap: 6px;
    min-height: 40px;
    padding: 0 13px;
    border-radius: var(--ph-radius-btn);
    background: var(--ph-accent);
    color: var(--ph-accent-contrast);
    font-size: 13px;
    font-weight: 800;
    white-space: nowrap;
}

.v8-active-order-pill.is-visible {
    display: inline-flex;
}

.v8-cart-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-height: 48px;
    padding: 0 14px 0 18px;
    border: none;
    border-radius: var(--ph-radius-btn);
    background: var(--ph-secondary);
    color: var(--ph-secondary-contrast);
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16);
    transition: transform 150ms var(--ph-ease), opacity 160ms ease;
}

[data-ph-theme="american-diner"] .v8-cart-btn {
    background: #FFF7EB;
    color: #141414;
}

.v8-cart-btn:active { transform: scale(0.96); }

.v8-cart-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 26px;
    padding: 0 7px;
    border-radius: 999px;
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    font-size: 13px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.v8-burger-menu-btn {
    display: none;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    border: 1px solid var(--ph-border);
    background: var(--ph-surface);
    color: var(--ph-text);
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* Menu mobile plein écran */
.v8-mobile-nav-overlay {
    position: fixed;
    inset: 0;
    z-index: 260;
    background: var(--ph-bg);
    color: var(--ph-text);
    padding: 20px 24px 32px;
    display: none;
    flex-direction: column;
    gap: 16px;
}

.v8-mobile-nav-overlay.is-open {
    display: flex;
}

.v8-mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}

.v8-mobile-nav-links a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 58px;
    padding: 0 20px;
    border-radius: 16px;
    background: var(--ph-surface);
    border: 1px solid var(--ph-border);
    font-family: var(--ph-font-display);
    font-size: 22px;
}

/* ============================================================================
   2. HERO ADAPTATIF (MODE BOLD FAST-FOOD US & MODE SOFT BENTO)
   ============================================================================ */
.v8-hero {
    position: relative;
    overflow: hidden;
    background: var(--ph-hero-bg);
    color: var(--ph-hero-text);
    padding: 40px 0 44px;
}

/* Split jaune / bordeaux exclusif sur flame-express */
[data-ph-theme="flame-express"] .v8-hero::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 44%;
    background: var(--ph-hero-bg-2);
    clip-path: polygon(16% 0, 100% 0, 100% 100%, 0% 100%);
    z-index: 0;
    pointer-events: none;
}

.v8-hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    align-items: center;
    gap: 32px;
}

.v8-hero-copy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
}

.v8-hero-status-row {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.v8-hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: #141414;
    font-size: 13.5px;
    font-weight: 800;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}

.v8-hero-title {
    margin: 0;
    font-family: var(--ph-font-display);
    font-size: clamp(2.8rem, 5.8vw, 5rem);
    line-height: 0.96;
    letter-spacing: -0.02em;
    color: var(--ph-hero-text);
    text-transform: uppercase;
}

.v8-hero-sub {
    margin: 0;
    font-size: 18px;
    line-height: 1.5;
    font-weight: 600;
    color: var(--ph-hero-sub);
    max-width: 44ch;
}

.v8-hero-ctas {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 6px;
}

.v8-btn-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 54px;
    padding: 0 28px;
    border: none;
    border-radius: var(--ph-radius-btn);
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    font-family: var(--ph-font-display);
    font-size: 18px;
    letter-spacing: 0.01em;
    cursor: pointer;
    box-shadow: 0 8px 22px -6px rgba(0, 0, 0, 0.28);
    transition: transform 150ms var(--ph-ease), background-color 180ms var(--ph-ease);
}

[data-ph-theme="american-diner"] .v8-btn-cta {
    background: #FFF7EB;
    color: #D61C1C;
}

.v8-btn-cta:hover { transform: translateY(-2px); }
.v8-btn-cta:active { transform: scale(0.96); }

.v8-btn-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 54px;
    padding: 0 24px;
    border: 2px solid currentColor;
    border-radius: var(--ph-radius-btn);
    background: transparent;
    color: var(--ph-hero-text);
    font-size: 15.5px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 150ms var(--ph-ease), background-color 180ms var(--ph-ease);
}

.v8-btn-outline:hover { background: rgba(255, 255, 255, 0.14); }
.v8-btn-outline:active { transform: scale(0.96); }

.v8-hero-reassurance {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
    margin-top: 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--ph-hero-sub);
}

.v8-hero-reassurance span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.v8-hero-stage {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 340px;
}

.v8-hero-bg-word {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--ph-font-display);
    font-size: clamp(3.6rem, 8vw, 6.8rem);
    line-height: 0.9;
    text-align: center;
    text-transform: uppercase;
    color: var(--ph-hero-text);
    opacity: 0.14;
    user-select: none;
    pointer-events: none;
    z-index: 0;
}

[data-ph-theme="cheesy-grill"] .v8-hero-bg-word,
[data-ph-theme="sweet-scoop"] .v8-hero-bg-word {
    opacity: 0.92;
}

.v8-hero-dish {
    position: relative;
    z-index: 2;
    width: min(440px, 95%);
    max-height: 410px;
    object-fit: contain;
    filter: drop-shadow(0 24px 32px rgba(0, 0, 0, 0.26));
}

.v8-price-sticker {
    position: absolute;
    top: 14px;
    right: 12px;
    z-index: 4;
    width: 108px;
    height: 108px;
    border-radius: 50%;
    background: var(--ph-price-badge-bg);
    color: var(--ph-price-badge-ink);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 8px;
    transform: rotate(-6deg);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
    border: 3px solid rgba(255, 255, 255, 0.85);
}

.v8-price-sticker small {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    line-height: 1.1;
    max-width: 82px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.v8-price-sticker strong {
    font-family: var(--ph-font-display);
    font-size: 24px;
    line-height: 1.05;
    font-variant-numeric: tabular-nums;
}

/* Mode Hero Bento Soft (pour soft-clay-3d, coral-bento, parisian-pizza, crispy-tacos, fresh-poke) */
.v8-hero--soft {
    background: var(--ph-bg);
    padding: 28px 0 24px;
}

.v8-soft-bento {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
    gap: 20px;
    align-items: stretch;
}

.v8-soft-main {
    position: relative;
    background: var(--ph-hero-bg);
    border: 1px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 36px;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    align-items: center;
    gap: 20px;
    box-shadow: var(--ph-shadow-card);
    overflow: hidden;
}

.v8-soft-main .v8-hero-title {
    font-size: clamp(2.1rem, 3.6vw, 3.3rem);
}

.v8-soft-side {
    display: grid;
    grid-template-rows: 1fr auto;
    gap: 18px;
}

.v8-soft-deal-card {
    background: var(--ph-surface);
    border: 1px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 22px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 118px;
    align-items: center;
    gap: 16px;
    box-shadow: var(--ph-shadow-card);
    cursor: pointer;
    text-align: left;
    transition: transform 180ms var(--ph-ease), box-shadow 180ms var(--ph-ease);
}

.v8-soft-deal-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--ph-shadow-lift);
}

.v8-soft-deal-thumb {
    width: 118px;
    height: 118px;
    border-radius: 16px;
    overflow: hidden;
    background: var(--ph-surface-alt);
}

.v8-soft-deal-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.v8-soft-info-card {
    background: var(--ph-surface);
    border: 1px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 20px 22px;
    box-shadow: var(--ph-shadow-card);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

/* ============================================================================
   3. RANGÉE VISUELLE DES CATÉGORIES (TUILES BICOLORES ACCÈS 1-CLIC)
   ============================================================================ */
.v8-cat-showcase {
    padding: 32px 0 18px;
}

.v8-cat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(156px, 1fr));
    gap: 14px;
}

.v8-cat-tile-big {
    position: relative;
    background: var(--ph-surface);
    border: 2px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    overflow: hidden;
    padding: 0;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    text-align: center;
    box-shadow: var(--ph-shadow-card);
    transition: transform 180ms var(--ph-ease), border-color 180ms var(--ph-ease), box-shadow 180ms var(--ph-ease);
}

.v8-cat-tile-big:hover {
    transform: translateY(-3px);
    border-color: var(--ph-primary);
    box-shadow: var(--ph-shadow-lift);
}

.v8-cat-tile-big:active { transform: scale(0.97); }

.v8-cat-tile-photo {
    aspect-ratio: 16 / 10;
    width: 100%;
    overflow: hidden;
    background: var(--ph-surface-alt);
}

.v8-cat-tile-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 240ms var(--ph-ease);
}

.v8-cat-tile-big:hover .v8-cat-tile-photo img {
    transform: scale(1.06);
}

.v8-cat-tile-band {
    background: var(--ph-surface-alt);
    padding: 12px 10px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    flex: 1;
}

.v8-cat-tile-pill {
    display: inline-block;
    padding: 5px 14px;
    border-radius: var(--ph-radius-btn);
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    font-family: var(--ph-font-display);
    font-size: 15px;
    line-height: 1.15;
    letter-spacing: 0.01em;
}

.v8-cat-tile-count {
    font-size: 13px;
    font-weight: 700;
    color: var(--ph-text-muted);
    font-variant-numeric: tabular-nums;
}

/* ============================================================================
   ENTÊTES DE SECTIONS
   ============================================================================ */
.v8-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.v8-section-title {
    margin: 0;
    font-family: var(--ph-font-display);
    font-size: clamp(1.9rem, 3.2vw, 2.75rem);
    line-height: 1.05;
    letter-spacing: -0.015em;
    color: var(--ph-text);
}

.v8-section-sub {
    margin: 6px 0 0;
    font-size: 16px;
    color: var(--ph-text-muted);
    max-width: 56ch;
}

/* ============================================================================
   4. BENTO « BONS PLANS & FORMULES STARS » (3 BLOCS COLORÉS)
   ============================================================================ */
.v8-deals-section {
    padding: 28px 0 36px;
}

.v8-deals-bento {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 20px;
}

.v8-deal-hero-card {
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    border-radius: var(--ph-radius-card);
    padding: 28px;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    align-items: center;
    gap: 20px;
    cursor: pointer;
    border: none;
    text-align: left;
    box-shadow: var(--ph-shadow-card);
    transition: transform 180ms var(--ph-ease);
}

.v8-deal-hero-card:hover { transform: translateY(-3px); }

.v8-deal-img-frame {
    aspect-ratio: 4 / 3;
    border-radius: 16px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.14);
}

.v8-deal-img-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.v8-deals-stack {
    display: grid;
    grid-template-rows: 1fr 1fr;
    gap: 18px;
}

.v8-deal-mini-card {
    border-radius: var(--ph-radius-card);
    padding: 22px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 116px;
    align-items: center;
    gap: 16px;
    cursor: pointer;
    border: 1px solid var(--ph-border);
    text-align: left;
    box-shadow: var(--ph-shadow-card);
    transition: transform 180ms var(--ph-ease);
}

.v8-deal-mini-card:hover { transform: translateY(-2px); }

.v8-deal-mini-card--accent {
    background: var(--ph-accent);
    color: var(--ph-accent-contrast);
    border-color: transparent;
}

.v8-deal-mini-card--surface {
    background: var(--ph-surface);
    color: var(--ph-text);
}

.v8-deal-mini-thumb {
    width: 116px;
    height: 116px;
    border-radius: 14px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.08);
}

.v8-deal-mini-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.v8-deal-price {
    font-family: var(--ph-font-display);
    font-size: 26px;
    font-variant-numeric: tabular-nums;
}

/* ============================================================================
   5. « LES PLUS COMMANDÉS » (THE LINEUP — 4 BEST-SELLERS)
   ============================================================================ */
.v8-lineup-section {
    padding: 24px 0 36px;
}

.v8-lineup-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

/* ============================================================================
   6. « TOUTE LA CARTE » — BARRE STICKY + QUICK MOOD + GRILLE 4 COLONNES
   ============================================================================ */
.v8-carte-section {
    padding: 20px 0 60px;
}

.v8-carte-sticky {
    position: sticky;
    top: 74px;
    z-index: 85;
    background: var(--ph-bg);
    border-top: 1px solid var(--ph-border);
    border-bottom: 1px solid var(--ph-border);
    padding: 12px 0;
    margin-bottom: 32px;
    box-shadow: 0 6px 18px -10px rgba(0, 0, 0, 0.1);
}

.v8-sticky-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 10px;
}

.v8-cat-pills-row {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    flex: 1;
    padding: 2px 0;
}

.v8-cat-pills-row::-webkit-scrollbar { display: none; }

.carte-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 16px;
    border-radius: var(--ph-radius-btn);
    border: 1.5px solid var(--ph-border);
    background: var(--ph-surface);
    color: var(--ph-text);
    font-size: 14.5px;
    font-weight: 800;
    white-space: nowrap;
    cursor: pointer;
    flex-shrink: 0;
    transition: background-color 180ms var(--ph-ease), color 180ms var(--ph-ease), border-color 180ms var(--ph-ease), transform 140ms var(--ph-ease);
}

.carte-tab-btn:active { transform: scale(0.96); }

.carte-tab-btn.is-active {
    background: var(--ph-primary);
    border-color: var(--ph-primary);
    color: var(--ph-primary-contrast);
}

.v8-search-box {
    position: relative;
    width: 270px;
    flex-shrink: 0;
}

.v8-search-input {
    width: 100%;
    height: 44px;
    padding: 0 36px 0 40px;
    border-radius: var(--ph-radius-btn);
    border: 1.5px solid var(--ph-border-strong);
    background: var(--ph-surface);
    color: var(--ph-text);
    font-size: 15px;
    font-weight: 600;
    outline: none;
}

.v8-search-input:focus {
    border-color: var(--ph-primary);
}

.v8-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--ph-text-muted);
    pointer-events: none;
    display: flex;
}

.search-clear {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: var(--ph-surface-alt);
    color: var(--ph-text);
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
}

.search-clear.is-visible { display: inline-flex; }

/* L'Envie du Moment (Quick Mood Filters) */
.v8-mood-row {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
}

.v8-mood-row::-webkit-scrollbar { display: none; }

.v8-mood-label {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--ph-text-muted);
    white-space: nowrap;
    margin-right: 4px;
}

.v8-mood-chip {
    min-height: 36px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid var(--ph-border);
    background: var(--ph-surface);
    color: var(--ph-text);
    font-size: 13.5px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 160ms var(--ph-ease), color 160ms var(--ph-ease), border-color 160ms var(--ph-ease);
}

.v8-mood-chip.is-active {
    background: var(--ph-secondary);
    border-color: var(--ph-secondary);
    color: var(--ph-secondary-contrast);
}

/* Catégories & Grille Produits 4 colonnes */
.cat-section { margin-bottom: 48px; }
.cat-section.is-tab-hidden { display: none !important; }

.cat-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 20px;
}

.cat-section-title {
    margin: 0;
    font-family: var(--ph-font-display);
    font-size: clamp(1.5rem, 2.4vw, 2.1rem);
    color: var(--ph-text);
}

.cat-section-sub {
    margin: 4px 0 0;
    font-size: 15px;
    color: var(--ph-text-muted);
}

.cat-section-count {
    font-size: 13.5px;
    font-weight: 800;
    padding: 6px 14px;
    border-radius: 999px;
    background: var(--ph-surface);
    border: 1px solid var(--ph-border);
    color: var(--ph-text-muted);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
    align-items: stretch;
}

/* CARTE PRODUIT V8.0 ULTRA-LISIBLE & HOMOGÈNE */
.prod-card {
    background: var(--ph-surface);
    border: 1.5px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 12px;
    display: flex;
    flex-direction: column;
    box-shadow: var(--ph-shadow-card);
    transition: transform 180ms var(--ph-ease), box-shadow 180ms var(--ph-ease), border-color 180ms var(--ph-ease);
}

.prod-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--ph-shadow-lift);
    border-color: var(--ph-border-strong);
}

.prod-media {
    position: relative;
    aspect-ratio: 4 / 3;
    border-radius: calc(var(--ph-radius-card) - 6px);
    overflow: hidden;
    background: var(--ph-surface-alt);
    cursor: pointer;
    flex-shrink: 0;
}

.prod-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 240ms var(--ph-ease);
}

.prod-card:hover .prod-media img { transform: scale(1.04); }

.prod-tag {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    padding: 5px 11px;
    border-radius: 999px;
    background: var(--ph-accent);
    color: var(--ph-accent-contrast);
    font-size: 12px;
    font-weight: 800;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.14);
}

.prod-tag.is-accent {
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
}

/* Badge « Déjà dans votre panier » sur l'image */
.v8-in-cart-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 3;
    display: none;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    padding: 0 9px;
    border-radius: 999px;
    background: #16A34A;
    color: #FFFFFF;
    font-size: 13px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.4);
}

.v8-in-cart-badge.has-qty { display: inline-flex; }

.prod-body {
    padding: 14px 4px 4px;
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 8px;
    min-width: 0;
}

.prod-title {
    margin: 0;
    font-size: 18px;
    font-weight: 800;
    line-height: 1.25;
    color: var(--ph-text);
    cursor: pointer;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.prod-title:hover { color: var(--ph-primary); }

.prod-desc {
    margin: 0;
    font-size: 14.5px;
    line-height: 1.45;
    color: var(--ph-text-muted);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.prod-allergens {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.prod-allergen-pill {
    font-size: 11.5px;
    font-weight: 700;
    color: var(--ph-text-muted);
    background: var(--ph-surface-alt);
    padding: 3px 8px;
    border-radius: 6px;
}

/* Sélecteurs inline propres */
.inline-variants {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 4px;
}

.seg-group {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
    padding: 3px;
    border-radius: 12px;
    background: var(--ph-surface-alt);
}

.seg-opt {
    min-height: 34px;
    padding: 0 8px;
    border: none;
    border-radius: 9px;
    background: transparent;
    color: var(--ph-text-muted);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.seg-opt.is-selected {
    background: var(--ph-surface);
    color: var(--ph-text);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
}

/* Bas de carte aligné + Bouton + AJOUTER qui passe en [ - 1 + ] */
.prod-footer {
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--ph-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.prod-price {
    font-family: var(--ph-font-display);
    font-size: 22px;
    color: var(--ph-text);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.v8-card-add-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 44px;
    padding: 0 16px;
    border: none;
    border-radius: var(--ph-radius-btn);
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    transition: transform 140ms var(--ph-ease), background-color 160ms var(--ph-ease);
}

.v8-card-add-btn:hover { background: var(--ph-primary-hover); }
.v8-card-add-btn:active { transform: scale(0.96); }

.v8-card-stepper {
    display: none;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    padding: 3px 5px;
    border-radius: var(--ph-radius-btn);
    background: var(--ph-secondary);
    color: var(--ph-secondary-contrast);
}

.v8-card-stepper.is-active { display: inline-flex; }
.v8-card-add-btn.is-hidden { display: none; }

.v8-step-btn {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.16);
    color: inherit;
    font-size: 18px;
    font-weight: 900;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.v8-step-qty {
    min-width: 24px;
    text-align: center;
    font-size: 15px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

/* ============================================================================
   7. « POURQUOI C'EST SI BON ? » + « ILS ONT ADORÉ » + INFOS PRATIQUES
   ============================================================================ */
.v8-craft-section {
    padding: 20px 0 56px;
}

.v8-craft-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 24px;
    align-items: center;
    background: var(--ph-surface);
    border: 1.5px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 28px;
    box-shadow: var(--ph-shadow-card);
}

.v8-craft-photo {
    aspect-ratio: 16 / 10;
    border-radius: calc(var(--ph-radius-card) - 6px);
    overflow: hidden;
    background: var(--ph-surface-alt);
}

.v8-craft-photo img { width: 100%; height: 100%; object-fit: cover; }

.v8-pillars-list {
    display: grid;
    gap: 14px;
    margin-top: 18px;
}

.v8-pillar-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 16px;
    border-radius: 16px;
    background: var(--ph-surface-alt);
}

.v8-pillar-num {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    font-family: var(--ph-font-display);
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.v8-reviews-section {
    padding: 12px 0 56px;
}

.v8-reviews-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.v8-review-card {
    background: var(--ph-surface);
    border: 1.5px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 24px;
    box-shadow: var(--ph-shadow-card);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 14px;
}

.v8-review-card--tinted {
    background: var(--ph-surface-alt);
}

.v8-review-stars {
    display: inline-flex;
    gap: 3px;
    color: #F59E0B;
}

.v8-review-quote {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.5;
    color: var(--ph-text);
}

.v8-review-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.v8-review-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    font-family: var(--ph-font-display);
    font-size: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Infos Pratiques */
.v8-info-section {
    padding: 8px 0 60px;
}

.v8-info-card {
    background: var(--ph-surface);
    border: 1.5px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 28px;
    box-shadow: var(--ph-shadow-card);
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

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

.v8-info-col h3 {
    margin: 0;
    font-family: var(--ph-font-display);
    font-size: 20px;
    color: var(--ph-text);
}

/* ============================================================================
   8. FOOTER DE MARQUE MASSIF (WORDMARK GÉANT DYNAMIQUE)
   ============================================================================ */
.v8-footer {
    background: var(--ph-secondary);
    color: var(--ph-secondary-contrast);
    padding: 56px 0 32px;
}

[data-ph-theme="cheesy-grill"] .v8-footer {
    background: #4A1906;
    color: #FFF6E6;
}

[data-ph-theme="midnight-bucket"] .v8-footer {
    background: #0C0A0D;
    color: #FFF8F0;
    border-top: 1px solid var(--ph-border);
}

.v8-footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.1fr);
    gap: 28px;
    padding-bottom: 36px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.v8-footer h3 {
    margin: 0 0 14px;
    font-family: var(--ph-font-display);
    font-size: 18px;
    letter-spacing: 0.02em;
}

.v8-footer-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 15px;
    opacity: 0.88;
}

.v8-footer-links a:hover {
    opacity: 1;
    text-decoration: underline;
}

.v8-footer-giant-brand {
    margin: 28px 0 18px;
    font-family: var(--ph-font-display);
    font-size: clamp(2.8rem, 9.5vw, 8.2rem);
    line-height: 0.92;
    letter-spacing: -0.02em;
    text-align: center;
    text-transform: uppercase;
    opacity: 0.95;
    word-break: break-word;
}

.v8-footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    font-size: 13.5px;
    opacity: 0.78;
}

/* ============================================================================
   BARRE PANIER STICKY BAS D'ÉCRAN (MOBILE, TABLETTE & OPTION DESKTOP)
   ============================================================================ */
.v8-sticky-cart-bar {
    position: fixed;
    left: 50%;
    bottom: 18px;
    transform: translateX(-50%) translateY(120%);
    z-index: 140;
    width: min(560px, calc(100% - 28px));
    transition: transform 240ms var(--ph-ease);
    pointer-events: none;
}

.ph-toast {
    bottom: 90px !important;
}

.v8-sticky-cart-bar.has-items {
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.v8-sticky-cart-btn {
    width: 100%;
    min-height: 58px;
    padding: 0 20px;
    border: none;
    border-radius: var(--ph-radius-btn);
    background: var(--ph-primary);
    color: var(--ph-primary-contrast);
    font-size: 16px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.3);
}

.v8-sticky-cart-qty {
    padding: 5px 12px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.22);
    font-size: 13.5px;
    font-variant-numeric: tabular-nums;
}

/* ============================================================================
   CONFIGURATEUR 2 COLONNES + MINI-TICKET LIVE & JAUGE LIVRAISON PANIER
   ============================================================================ */
.ph-drawer-wide {
    max-width: 820px !important;
}

.v8-wiz-split {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.85fr);
    gap: 20px;
    align-items: start;
}

.v8-live-ticket {
    position: sticky;
    top: 0;
    background: var(--ph-bg);
    border: 1.5px dashed var(--ph-border-strong);
    border-radius: 16px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.v8-ticket-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 10px;
    border-bottom: 1px dashed var(--ph-border-strong);
}

.v8-ticket-head img {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
}

.v8-ticket-lines {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 13.5px;
    color: var(--ph-text-muted);
}

.v8-ticket-total-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding-top: 10px;
    border-top: 1px dashed var(--ph-border-strong);
    font-weight: 800;
    font-size: 16px;
}

.v8-ticket-total-row strong {
    font-family: var(--ph-font-display);
    font-size: 24px;
    color: var(--ph-primary);
    font-variant-numeric: tabular-nums;
}

.v8-delivery-gauge {
    background: var(--ph-surface-alt);
    border: 1px solid var(--ph-border);
    border-radius: 14px;
    padding: 12px 14px;
    margin-bottom: 14px;
}

.v8-delivery-gauge-text {
    font-size: 13.5px;
    font-weight: 800;
    color: var(--ph-text);
    margin-bottom: 8px;
}

.v8-delivery-gauge-track {
    height: 8px;
    border-radius: 999px;
    background: rgba(128, 128, 128, 0.2);
    overflow: hidden;
}

.v8-delivery-gauge-fill {
    height: 100%;
    border-radius: 999px;
    background: var(--ph-primary);
    transition: width 260ms var(--ph-ease);
}

.v8-delivery-gauge.is-unlocked .v8-delivery-gauge-fill {
    background: #16A34A;
}

/* Pages secondaires (page.php, single.php, 404.php) */
.ph-universal-hero {
    padding: 40px 0 26px;
    background: var(--ph-surface);
    border-bottom: 1px solid var(--ph-border);
    margin-bottom: 32px;
}

.ph-universal-title {
    margin: 0;
    font-family: var(--ph-font-display);
    font-size: clamp(2rem, 3.6vw, 3rem);
    color: var(--ph-text);
}

.ph-page-shell {
    background: var(--ph-surface);
    border: 1.5px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 32px;
    box-shadow: var(--ph-shadow-card);
    margin-bottom: 56px;
}

.empty-state {
    display: none;
    background: var(--ph-surface);
    border: 1.5px solid var(--ph-border);
    border-radius: var(--ph-radius-card);
    padding: 40px 24px;
    text-align: center;
    margin-bottom: 24px;
}

.empty-state.is-visible { display: block; }

/* ============================================================================
   RESPONSIVE DESKTOP / TABLETTE / MOBILE (390PX ZÉRO OVERFLOW)
   ============================================================================ */
@media (max-width: 1279px) {
    .product-grid,
    .v8-lineup-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    .v8-nav { display: none; }
    .v8-burger-menu-btn { display: inline-flex; }
}

@media (max-width: 959px) {
    .v8-hero-grid,
    .v8-soft-bento,
    .v8-deals-bento,
    .v8-craft-grid,
    .v8-info-card {
        grid-template-columns: 1fr;
    }
    [data-ph-theme="flame-express"] .v8-hero::after {
        display: none;
    }
    .product-grid,
    .v8-lineup-grid,
    .v8-reviews-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .v8-footer-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .v8-wiz-split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .v8-container,
    .ph-container {
        padding-left: 14px;
        padding-right: 14px;
    }
    .v8-header-inner {
        gap: 8px;
    }
    .v8-brand {
        font-size: 17px;
        min-width: 0;
        flex: 1 1 auto;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    .v8-header-actions {
        gap: 6px;
        flex-shrink: 0;
    }
    .v8-active-order-pill {
        padding: 0 9px;
        height: 34px;
        font-size: 11px;
        white-space: nowrap;
    }
    .v8-active-order-pill .v8-order-label {
        display: none;
    }
    .v8-cart-btn {
        height: 36px;
        padding: 0 9px;
        gap: 5px;
    }
    .v8-burger-menu-btn {
        width: 36px;
        height: 36px;
        flex-shrink: 0;
    }
    .v8-cart-btn .js-ph-cart-total {
        display: none;
    }
    .v8-mode-seg { display: none; }
    .v8-hero { padding: 26px 0 32px; }
    .v8-soft-main {
        grid-template-columns: 1fr;
        padding: 22px 18px;
    }
    .v8-deal-hero-card {
        grid-template-columns: 1fr;
        padding: 22px 18px;
    }
    .v8-hero-stage { min-height: 240px; }
    .v8-price-sticker {
        width: 88px;
        height: 88px;
        top: 6px;
        right: 4px;
    }
    .v8-price-sticker strong { font-size: 20px; }
    .v8-cat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }
    .v8-sticky-top-row {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    .v8-search-box { width: 100%; }
    .product-grid,
    .v8-lineup-grid,
    .v8-reviews-grid,
    .v8-footer-grid {
        grid-template-columns: 1fr;
    }
    body { padding-bottom: 88px; }
}
