﻿.tarifs {
    --t-card: #17181c;
    --t-card-bottom: #121316;
    --t-line: rgba(231, 198, 130, 0.28);
    --t-line-strong: rgba(231, 198, 130, 0.6);
    --header-h: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: calc(var(--header-h) + clamp(1.5rem, 4vw, 3rem)) clamp(1rem, 4vw, 4rem) clamp(2.5rem, 4vw, 4rem);
    background: var(--bg-color);
    color: var(--text-gold-color);
    width: 100%;
    min-height: 100svh;
}

/*Tarifs header*/
.tarifs-head {
    max-width: 1000px;
    margin: 0 auto clamp(2rem, 4vw, 3.5rem);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
}

.tarifs-head h1::after {
    content: "";
    display: block;
    width: 80px;
    height: 2px;
    margin: 1.25rem auto 0;
    background: linear-gradient(90deg, transparent, var(--text-gold-color), transparent);
}

/*Tarifs Grid*/
.tarifs-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: 1fr;
    gap: clamp(1.25rem, 2vw, 2rem);
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

/*Tarifs Grid card*/
.tarif-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    background: linear-gradient(180deg, var(--t-card) 0%, var(--t-card-bottom) 100%);
    border: 4px solid var(--t-line);
    border-radius: 14px;
    box-shadow: 0 20px 50px -24px rgba(0, 0, 0, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.04);
    overflow: hidden;
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.tarif-card:hover {
    transform: translateY(-6px);
    border-color: var(--text-gold-color);
    box-shadow: 0 24px 48px -24px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(231, 198, 130, 0.25);
}

.tarif-card--featured {
    border-color: var(--t-line-strong);
    background: linear-gradient(180deg, #231e12 0%, var(--t-card) 55%, var(--t-card-bottom) 100%);
    box-shadow: 0 0 40px -12px rgba(231, 198, 130, 0.35), 0 20px 50px -24px rgba(0, 0, 0, 0.85);
}

.tarif-card--featured::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    z-index: 4;
    height: 4px;
    background: linear-gradient(90deg, var(--text-gold-dark-color), var(--text-gold-light-color), var(--text-gold-dark-color));
}

.tarif-card--featured .tarif-price-value {
    font-size: clamp(2.6rem, 3.8vw, 3.3rem);
}

.tarif-media {
    position: relative;
    isolation: isolate;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    flex-shrink: 0;
}

.tarif-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(0.25) brightness(0.8);
    -webkit-mask-image: linear-gradient(to bottom, #000 35%, transparent 92%);
    mask-image: linear-gradient(to bottom, #000 35%, transparent 92%);
    transition: transform 0.8s ease, filter 0.8s ease;
}

.tarif-card:hover .tarif-media img {
    transform: scale(1.06);
    filter: grayscale(0) brightness(0.85);
}

.tarif-media::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg, rgba(0,0,0,0.15) 0%, rgba(0,0,0,0.25) 40%, transparent 100%);
}

.tarif-media-text {
    position: absolute;
    left: 1.25rem;
    right: 1.25rem;
    bottom: 2.5rem;
    z-index: 2;
}

.tarif-media-text h3 {
    color: var(--text-gold-color);
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7);
}

.tarif-badge {
    font-family: Arial;
    position: absolute;
    top: 0;
    right: 0;
    z-index: 3;
    padding: 0.5rem 0.9rem;
    background: var(--text-gold-color);
    color: var(--bg-color);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    border-bottom-left-radius: 10px;
}

.tarif-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding: 1.5rem 1.25rem 0;
}

.tarif-intro {
    text-align: center;
}

.tarif-price {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    padding: 1rem 0;
    border-top: 1px solid var(--t-line);
    border-bottom: 1px solid var(--t-line);
}

.tarif-price-amount {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.tarif-price-from {
    font-size: 0.8rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text-muted-color);
}

.tarif-price-value {
    font-size: clamp(2.2rem, 3.2vw, 2.8rem);
    font-weight: 600;
    line-height: 1;
    color: var(--text-gold-color);
    background: linear-gradient(135deg, var(--text-gold-light-color) 0%, var(--text-gold-color) 50%, var(--text-gold-dark-color) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.tarif-price-currency {
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--text-gold-color);
}

.tarif-price-extra {
    margin-top: 0.2rem;
    font-size: 0.95rem;
    line-height: 1.5;
}

.tarif-price-extra strong {
    white-space: nowrap;
    font-weight: 600;
    color: var(--text-gold-color);
}

.tarif-price-tax {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-gold-color);
}

.tarif-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.tarif-list li {
    position: relative;
    padding-left: 1.1rem;
    font-size: 1.1rem;
    line-height: 1.5;
    color: var(--text-light-color);
}

.tarif-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.75em;
    width: 0.5rem;
    height: 1px;
    background: var(--text-gold-color);
}

.tarif-btn {
    font-family: Arial;
    display: block;
    margin: auto -1.25rem 0;
    padding: 1.1rem 1rem;
    text-align: center;
    font-size: 1rem;
    font-weight: bold;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-gold-color);
    border-top: 1px solid var(--t-line);
    transition: background 0.3s ease, color 0.3s ease;
}

.tarif-card:hover .tarif-btn {
    background: var(--text-gold-color);
    color: var(--bg-color);
}

.tarif-btn:focus-visible {
    outline: 2px solid var(--text-gold-color);
    outline-offset: -4px;
}

@media (max-width: 1100px) {
    .tarif-body {
        padding: 1.25rem 1rem 0;
    }

    .tarif-btn {
        margin: auto -1rem 0;
    }
}

@media (max-width: 900px) {
    .tarifs-grid {
        grid-template-columns: minmax(0, 1fr);
        max-width: 520px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tarif-card,
    .tarif-media img,
    .tarif-btn {
        transition: none;
    }

    .tarif-card:hover {
        transform: none;
    }

    .tarif-card:hover .tarif-media img {
        transform: none;
    }
}

/*Ce qui fait la différence*/
.sectioncontainer2.differences {
    --d-line: rgba(231, 198, 130, 0.22);
    container-type: inline-size;
}

.differences-head {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    text-align: center;
}

.differences-head h3 {
    font-size: clamp(1.35rem, 2.6vw, 2.2rem);
}

.differences-head h2::after {
    content: "";
    display: block;
    width: 80px;
    height: 2px;
    margin: 1.25rem auto 0;
    background: linear-gradient(90deg, transparent, var(--text-gold-color), transparent);
}

/*différence Grid*/
.differences-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(1rem, 2vw, 1.5rem);
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

.difference {
    display: grid;
    grid-template-rows: subgrid;
    grid-row: span 2; 
    gap: 1rem;
    padding: clamp(1.75rem, 2.2vw, 2.25rem) clamp(1.25rem, 1.6vw, 1.5rem);
    background: var(--bg-color);
    border: 1px solid var(--d-line);
    border-radius: 14px;
    transition: border-color 0.4s ease, translate 0.4s ease, box-shadow 0.4s ease;
}

.difference:hover {
    border-color: var(--text-gold-color);
    translate: 0 -4px;
    box-shadow: 0 20px 40px -24px rgba(0, 0, 0, 0.9);
}

.difference:hover::before {
    border-color: var(--text-gold-color);
}

.difference h3 {
    align-self: center;
    text-align: center;
    font-size: clamp(1.05rem, 1.4vw, 1.35rem);
    color: var(--text-gold-color);
}

/* Petit trait doré sous chaque engagement (dessiné à l'apparition) */
.difference h3::after {
    content: "";
    display: block;
    width: 2rem;
    height: 2px;
    margin: .9rem auto 0;
    background: var(--text-gold-color);
}

@media (max-width: 1000px) {
    .differences-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-width: 900px;
    }
}

@media (max-width: 680px) {
    .differences-grid {
        grid-template-columns: minmax(0, 1fr);
        max-width: 520px;
    }
}

/* Animations d'apparition (mécanisme [data-reveal] dans site.css / site.js) */
@media (prefers-reduced-motion: no-preference) {
    /* Décalages en cascade : titre puis sous-titre, cartes l'une après l'autre */
    .tarifs-head h3,
    .differences-head h3 {
        --reveal-delay: .15s;
    }

    /* Cartes de prix : glissement sans fondu, lancé dès l'affichage (sans JS).
       Elles restent visibles dès le départ : la photo Corporate est l'élément mesuré par Google (LCP) */
    .tarif-card {
        animation: card-rise .9s cubic-bezier(.22, 1, .36, 1) var(--card-delay, 0s) backwards;
    }

    .tarifs-grid > :nth-child(2) { --card-delay: .1s; }
    .tarifs-grid > :nth-child(3) { --card-delay: .2s; }

    .differences-grid > :nth-child(2) { --reveal-delay: .12s; }
    .differences-grid > :nth-child(3) { --reveal-delay: .24s; }
    .differences-grid > :nth-child(4) { --reveal-delay: .36s; }

    /* Traits dorés sous les titres qui se dessinent */
    .tarifs-head h1::after,
    .differences-head h2.is-visible::after {
        animation: line-draw 1s cubic-bezier(.22, 1, .36, 1) .35s backwards;
    }

    /* Photo des cartes : léger dézoom à l'arrivée */
    .tarif-media img {
        animation: tarif-img-in 1.6s cubic-bezier(.22, 1, .36, 1) var(--card-delay, 0s) backwards;
    }

    .tarif-card--featured .tarif-badge {
        animation: badge-in .6s cubic-bezier(.22, 1, .36, 1) calc(var(--card-delay, 0s) + .5s) backwards;
    }

    .difference.is-visible h3::after {
        animation: line-draw .8s cubic-bezier(.22, 1, .36, 1) calc(var(--reveal-delay, 0s) + .4s) backwards;
    }

    @media (max-width: 680px) {
        .differences-grid > * { --reveal-delay: 0s; }
    }
}

@keyframes line-draw {
    from {
        scale: 0 1;
    }
}

@keyframes card-rise {
    from {
        translate: 0 28px;
    }
}

@keyframes tarif-img-in {
    from {
        scale: 1.15;
    }
}

@keyframes badge-in {
    from {
        opacity: 0;
        translate: 100% 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .difference {
        transition: none;
    }

        .difference:hover {
            translate: none;
        }
}

/*faq*/
.faq {
    --faq-line: rgba(255, 255, 255, 0.12);
    --faq-hover: rgba(255, 255, 255, 0.03);
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: clamp(2.5rem, 6vw, 4rem);
    align-items: start;
    padding-block: clamp(3rem, 8vw, 6rem);
    padding-inline: max(clamp(1rem, 5vw, 2rem), (100% - 1400px) / 2);
    interpolate-size: allow-keywords; 
}

.faq-header {
    max-width: 820px;
    width: 100%;
    margin: 0 auto;
    text-align: center;
}

.faq-header h2 {
    display: inline-block;
    margin: 0;
}

.faq-header h2::after {
    content: "";
    display: block;
    width: clamp(48px, 8vw, 64px);
    height: 1px;
    margin: clamp(0.8rem, 2vw, 1.1rem) auto 0;
    background: linear-gradient(90deg, transparent, var(--text-gold-color), transparent);
}

.faq-tagline {
    margin: clamp(0.9rem, 2.2vw, 1.3rem) 0 0;
}

.faq-list {
    max-width: 820px;
    width: 100%;
    margin: 0 auto;
    border-top: 1px solid var(--faq-line);
}

.faq details {
    border-bottom: 1px solid var(--faq-line);
}

.faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: clamp(1.1rem, 2.5vw, 1.5rem) clamp(0.25rem, 1.5vw, 1rem);
    cursor: pointer;
    list-style: none;
    transition: background-color 0.2s ease;
}

.faq summary::-webkit-details-marker {
    display: none;
}

.faq summary:hover {
    background-color: var(--faq-hover);
}

.faq summary:focus-visible {
    outline: 2px solid var(--text-gold-color);
    outline-offset: 2px;
}

.faq summary h4 {
    margin: 0;
    text-transform: none;
    transition: color 0.2s ease;
}

.faq summary:hover h4,
.faq details[open] summary h4 {
    color: var(--text-gold-color);
}

.faq summary::after {
    content: "";
    flex: 0 0 auto;
    width: 2.25rem;
    height: 2.25rem;
    border: 1px solid var(--faq-line);
    border-radius: 50%;
    background: linear-gradient(var(--text-gold-color), var(--text-gold-color)) center / 12px 1.5px no-repeat, linear-gradient(var(--text-gold-color), var(--text-gold-color)) center / 1.5px 12px no-repeat;
    transition: border-color 0.2s ease, background-size 0.3s ease;
}

.faq details[open] summary::after {
    border-color: var(--text-gold-color);
    background-size: 12px 1.5px, 1.5px 0;
}

.faq details p {
    margin: 0;
    padding: 0 clamp(0.25rem, 1.5vw, 1rem) clamp(1.25rem, 2.5vw, 1.75rem);
}

.faq details::details-content {
    height: 0;
    overflow: hidden;
    transition: height 0.35s ease, content-visibility 0.35s allow-discrete;
}

.faq details[open]::details-content {
    height: auto;
}

.faq details[open] p {
    animation: faq-fade 0.35s ease;
}

@keyframes faq-fade {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

@media (min-width: 992px) {
    .faq {
        grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
        gap: clamp(3rem, 6vw, 6rem);
    }

    .faq-header {
        max-width: none;
        align-self: center;
        text-align: center;
    }

    .faq-list {
        max-width: none;
    }
}

@media (max-width: 600px) {
    .faq summary {
        gap: 1rem;
    }

        .faq summary::after {
            width: 1.75rem;
            height: 1.75rem;
        }
}

@media (prefers-reduced-motion: reduce) {
    .faq *,
    .faq details::details-content {
        transition: none !important;
        animation: none !important;
    }
}
