/* ==========================================================================
   Page d'accueil (extrait de index.php)
   ========================================================================== */

.bg-navy { background-color: #1a1a2e; }

/* Perf : on évite que le navigateur calcule le rendu des sections hors-écran
   (réduit fortement le travail du thread principal / TBT sur les longues pages). */
.cv-auto { content-visibility: auto; contain-intrinsic-size: auto 600px; }
#productsGrid { content-visibility: auto; contain-intrinsic-size: auto 640px; }
.offers-grid { content-visibility: auto; contain-intrinsic-size: auto 1600px; }

/* FAQ (accordéon natif <details>) — séparateurs + icône +/× sans dépendre du build Tailwind purgé */
.home-faq > details { border-top: 1px solid #f0f1f2; }
.home-faq > details:first-child { border-top: 0; }
.home-faq > details > summary::-webkit-details-marker { display: none; }
.home-faq > details[open] > summary i { transform: rotate(45deg); }

/* ==========================================================================
   "Les meilleures offres par boutique" — cartes horizontales (logo + code)
   ========================================================================== */
.offers-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}
@media (max-width: 767px) { .offers-grid { grid-template-columns: 1fr; } }

.offer-card {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    background: #fff;
    border: 1px solid #eef0f2;
    border-radius: .5rem;
    padding: 1.1rem 1.25rem;
    box-shadow: 0 1px 2px rgba(8, 24, 42, .05);
    transition: box-shadow .2s ease, border-color .2s ease;
}
.offer-card:hover { box-shadow: 0 12px 26px -14px rgba(8, 24, 42, .4); border-color: #e2e6ea; }

.offer-logo {
    position: relative;
    flex: none;
    width: 84px;
    height: 84px;
    border-radius: .35rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #f0f1f2;
    overflow: hidden;
}
.offer-logo img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: .45rem;
    background: #fff;
}
.offer-mono { font-family: "Golos Text", system-ui, sans-serif; font-weight: 700; font-size: 1.7rem; color: #6FB01F; }

.offer-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .65rem; }
.offer-title { margin: 0; font-size: .95rem; line-height: 1.3; font-weight: 700; }
.offer-title a { color: #08182A; text-decoration: none; }
.offer-title a:hover { color: #6FB01F; }

/* Bouton "Voir l'offre" (bon plan, sans code) */
.offer-link-btn {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 220px;
    max-width: 100%;
    padding: .62rem 1.3rem;
    border-radius: .35rem;
    background: #8FD13F;
    color: #08182A;
    font-weight: 700;
    font-size: .9rem;
    text-decoration: none;
    transition: background .2s ease, color .2s ease;
}
.offer-link-btn:hover { background: #6FB01F; color: #fff; }

/* Bloc code promo : bouton de révélation puis code + copie */
.offer-code { align-self: flex-start; max-width: 100%; }
.offer-code-btn {
    display: inline-flex;
    align-items: stretch;
    min-width: 240px;
    max-width: 100%;
    border: 0;
    padding: 0;
    border-radius: .35rem;
    overflow: hidden;
    cursor: pointer;
    font: inherit;
}
.offer-code-label {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: .62rem 1.2rem;
    background: linear-gradient(90deg, #F5A623, #ED8A12);
    color: #fff;
    font-weight: 700;
    font-size: .9rem;
}
.offer-code-peek {
    display: flex;
    align-items: center;
    padding: 0 .85rem;
    background: #fff;
    border: 2px dashed #e0bd80;
    border-left: 0;
    color: #a37d3a;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.offer-code.is-open .offer-code-btn { display: none; }
.offer-code-open {
    display: inline-flex;
    align-items: stretch;
    min-width: 240px;
    max-width: 100%;
    border-radius: .35rem;
    overflow: hidden;
    border: 2px dashed #cdd3da;
}
.offer-code-open[hidden] { display: none; }
.offer-code-value {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: .55rem 1rem;
    background: #f6f8fa;
    font-weight: 800;
    letter-spacing: .1em;
    color: #08182A;
    text-transform: uppercase;
}
.offer-code-copy {
    border: 0;
    cursor: pointer;
    padding: .55rem 1.1rem;
    background: #08182A;
    color: #fff;
    font-weight: 700;
    font-size: .85rem;
    transition: background .2s ease;
}
.offer-code-copy:hover { background: #13293D; }
.offer-code-copy.is-copied { background: #6FB01F; }

/* Pied de carte : expiration + vérifié */
.offer-foot { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem 1.1rem; margin-top: .15rem; }
.offer-meta { display: inline-flex; align-items: center; gap: .35rem; color: #6b7280; font-size: .78rem; }
.offer-verified { color: #6FB01F; }
.offer-verified i { color: #6FB01F; }

@media (max-width: 480px) {
    .offer-card { gap: .8rem; padding: 1rem; }
    .offer-logo { width: 60px; height: 60px; }
    .offer-code-btn, .offer-code-open, .offer-link-btn { min-width: 0; width: 100%; }
}

/* ==========================================================================
   Marges latérales de la page d'accueil — gouttières larges (style ma-reduc).
   On élargit le retrait gauche/droite de chaque conteneur `.container`.
   ========================================================================== */
.home .container {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}
@media (min-width: 768px) {
    .home .container { padding-left: 3rem; padding-right: 3rem; }
}
@media (min-width: 1024px) {
    .home .container { padding-left: 5rem; padding-right: 5rem; }
}
@media (min-width: 1280px) {
    .home .container { padding-left: 7rem; padding-right: 7rem; }
}
@media (min-width: 1536px) {
    .home .container { padding-left: 9rem; padding-right: 9rem; }
}

/* Effet de reflet sur les boutons au survol */
.btn-reflect { position: relative; overflow: hidden; }
.btn-reflect::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 60%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .5), transparent);
    transform: skewX(-20deg);
    transition: left .6s ease;
}
.group:hover .btn-reflect::after { left: 140%; }

/* Limitation à 2 lignes */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ==========================================================================
   Bloc "Nos boutiques à la une" — cartes illustrées (photo d'activité)
   Composant autonome : indépendant du build Tailwind purgé.
   ========================================================================== */
.feat-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}
.feat-title {
    position: relative;
    color: #08182A;                 /* ink */
    font-weight: 700;
    font-size: clamp(1.25rem, 1rem + 1.4vw, 1.75rem);
    line-height: 1.15;
    padding-bottom: .6rem;
}
.feat-title::after {                 /* soulignement orange (pièce/coin) */
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 56px;
    height: 4px;
    border-radius: 999px;
    background: #F5A623;
}
.feat-all {
    flex: none;
    font-size: .875rem;
    font-weight: 700;
    color: #6FB01F;                 /* brand-dark */
    white-space: nowrap;
    transition: color .2s ease;
}
.feat-all:hover { color: #08182A; }

.feat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.feat-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #eef0f2;
    border-radius: .9rem;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 1px 2px rgba(8, 24, 42, .05);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.feat-card:hover {
    transform: translateY(-4px);
    border-color: rgba(143, 209, 63, .55);
    box-shadow: 0 16px 30px -14px rgba(8, 24, 42, .45);
}

.feat-media {
    position: relative;
    aspect-ratio: 720 / 432;
    overflow: hidden;
    background: #eef2f0;
}
.feat-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .6s ease;
}
.feat-card:hover .feat-media img { transform: scale(1.06); }

.feat-tag {
    position: absolute;
    top: .6rem;
    left: .6rem;
    z-index: 2;
    background: #8FD13F;             /* brand */
    color: #08182A;
    font-size: .66rem;
    font-weight: 800;
    letter-spacing: .03em;
    text-transform: uppercase;
    padding: .25rem .55rem;
    border-radius: 999px;
    box-shadow: 0 2px 6px rgba(8, 24, 42, .25);
}

.feat-body {
    display: flex;
    flex-direction: column;
    gap: .4rem;
    padding: .9rem 1rem 1rem;
    flex: 1;
}
.feat-name {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: #08182A;
}
.feat-logo {
    width: 1.6rem;
    height: 1.6rem;
    border-radius: 50%;
    object-fit: contain;
    background: #fff;
    padding: .15rem;
    border: 1px solid #eef0f2;
    flex: none;
}
.feat-desc {
    margin: 0;
    color: #5b6671;
    font-size: .85rem;
    line-height: 1.45;
    flex: 1;
}
.feat-cta {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    margin-top: .2rem;
    color: #6FB01F;                 /* brand-dark */
    font-weight: 700;
    font-size: .85rem;
}
.feat-cta i { transition: transform .2s ease; }
.feat-card:hover .feat-cta i { transform: translateX(4px); }

/* Tablette : 2 colonnes, la 3ᵉ carte (impaire seule) passe en pleine largeur */
@media (max-width: 1023px) {
    .feat-grid { grid-template-columns: repeat(2, 1fr); }
    .feat-card:last-child:nth-child(odd) { grid-column: 1 / -1; }
    .feat-card:last-child:nth-child(odd) .feat-media { aspect-ratio: 21 / 9; }
}

/* Mobile : pile verticale */
@media (max-width: 639px) {
    .feat-grid { grid-template-columns: 1fr; gap: 1rem; }
    .feat-card:last-child:nth-child(odd) .feat-media { aspect-ratio: 720 / 432; }
}
