/* Accueil — L'Atelier (référence visuelle réseau + animations) */

body.page-atelier.theme-lumineux main#contenu {
    width: min(var(--page), calc(100% - 2rem));
    margin: 0 auto;
    padding: 1rem 0 3rem;
}

.hero-assemble {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
    gap: clamp(1.75rem, 4vw, 3.5rem);
    align-items: start;
    padding: clamp(0.75rem, 2vw, 1.5rem) 0 2rem;
}

.hero-assemble__copy {
    position: relative;
    z-index: 2;
    max-width: 38rem;
    padding: 1.15rem 1.25rem 1.35rem;
    border-radius: 1.5rem;
    background:
        linear-gradient(155deg, rgba(255, 255, 255, 0.72), rgba(241, 250, 255, 0.45));
    border: 1px solid rgba(139, 207, 244, 0.28);
    box-shadow:
        0 20px 50px rgba(36, 75, 105, 0.07),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.hero-assemble__eyebrow {
    margin: 0 0 0.65rem;
    font-family: var(--display);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--azur-vif);
}

.hero-assemble__titre {
    margin: 0 0 1.1rem;
    font-family: var(--display);
    font-weight: 700;
    font-size: clamp(1.35rem, 2.6vw, 1.85rem);
    line-height: 1.28;
    letter-spacing: -0.015em;
    color: var(--profond);
}

.hero-assemble__titre-suite {
    display: inline;
    font-weight: 600;
    color: var(--profond-soft);
}

.hero-assemble__lead,
.hero-assemble__p {
    margin: 0 0 0.9rem;
    color: var(--profond-soft);
    font-size: clamp(0.98rem, 1.35vw, 1.08rem);
    line-height: 1.62;
}

.hero-assemble__lead {
    color: var(--profond);
    font-weight: 600;
    font-size: clamp(1.02rem, 1.45vw, 1.14rem);
}

.hero-assemble__p--engage {
    margin-top: 0.35rem;
    padding: 0.75rem 0.9rem;
    border-radius: 0.9rem;
    background: rgba(217, 240, 255, 0.45);
    border: 1px solid rgba(139, 207, 244, 0.28);
}

/* ——— Ce qui guide mes créations ——— */

.valeurs-guide {
    margin: clamp(0.85rem, 2.4vw, 1.65rem) 0 0.5rem;
    padding: clamp(1.5rem, 3vw, 2.5rem) clamp(1rem, 2.5vw, 1.75rem);
    border-radius: 1.6rem;
    background:
        linear-gradient(165deg, rgba(255, 255, 255, 0.78), rgba(241, 250, 255, 0.5));
    border: 1px solid rgba(139, 207, 244, 0.32);
    box-shadow:
        0 22px 55px rgba(36, 75, 105, 0.07),
        inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.valeurs-guide__intro {
    max-width: 40rem;
    margin: 0 auto 1.75rem;
    text-align: center;
}

.valeurs-guide__titre {
    margin: 0 0 0.55rem;
    font-family: var(--display);
    font-size: clamp(1.35rem, 2.4vw, 1.75rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--profond);
}

.valeurs-guide__lead {
    margin: 0;
    color: var(--profond-soft);
    font-size: clamp(0.98rem, 1.4vw, 1.08rem);
    line-height: 1.55;
}

.valeurs-guide__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(1rem, 2.2vw, 1.5rem);
}

.valeur-card {
    display: grid;
    grid-template-rows: auto auto 1fr;
    gap: 0.35rem;
    padding: 0.55rem 0.7rem 1.15rem;
    border-radius: 1.2rem;
    background: #ffffff;
    border: 1px solid rgba(139, 207, 244, 0.38);
    box-shadow: 0 12px 28px rgba(36, 75, 105, 0.05);
}

.valeur-card__media {
    margin: 0;
    line-height: 0;
    border-radius: 0.95rem;
    overflow: hidden;
    background: #ffffff;
}

.valeur-card__media img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1024 / 682;
    object-fit: contain;
    object-position: center top;
}

.valeur-card__nom {
    margin: 0.15rem 0.35rem 0;
    font-family: var(--display);
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: var(--profond);
    min-height: 1.45em;
}

.valeur-card__texte {
    margin: 0 0.35rem;
    font-size: 0.95rem;
    line-height: 1.55;
    color: var(--profond-soft);
}

.hero-assemble__philosophie {
    margin: 1.15rem 0 1.35rem;
    font-family: var(--display);
    font-size: clamp(0.92rem, 1.3vw, 1.05rem);
    font-weight: 600;
    letter-spacing: 0.035em;
    color: var(--profond);
}

.hero-assemble__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

/* ——— Illustration (référence + surcouches animées) ——— */

.assemble-scene {
    position: sticky;
    top: 6.5rem;
    z-index: 1;
    /* Proportions exactes de reseau-reference.jpg (1024×682) */
    aspect-ratio: 1024 / 682;
    width: min(100%, 36rem);
    max-width: 100%;
    margin-inline: auto;
    border-radius: 1.35rem;
    overflow: hidden;
    isolation: isolate;
    background: #eaf6fd;
    border: 1px solid rgba(139, 207, 244, 0.4);
    box-shadow:
        0 24px 60px rgba(36, 75, 105, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.assemble-scene__glow {
    position: absolute;
    inset: 10% 14%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(125, 205, 245, 0.28), transparent 70%);
    filter: blur(24px);
    opacity: 0;
    pointer-events: none;
    z-index: 0;
}

.assemble-ref {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.985);
}

.assemble-ref__img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
}

.assemble-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.fiber-pulses {
    opacity: 0;
}

.fiber-pulse {
    fill: #ffffff;
    stroke: rgba(160, 220, 245, 0.9);
    stroke-width: 0.55;
}

.wifi-boost {
    opacity: 0;
}

.wifi-ring {
    fill: none;
    stroke: rgba(77, 180, 232, 0.55);
    stroke-width: 1.6;
    stroke-linecap: round;
}

.wifi-ring--b {
    stroke: rgba(180, 230, 250, 0.4);
}

/* États */

.assemble-scene.is-ready .assemble-scene__glow {
    animation: glow-in 1s ease forwards;
}

.assemble-scene.is-ready .assemble-ref {
    animation: ref-appear 1.15s cubic-bezier(0.22, 0.8, 0.28, 1) forwards;
}

.assemble-scene.is-assembled .assemble-ref {
    opacity: 1;
    transform: scale(1);
    animation: none;
}

.assemble-scene.is-assembled .assemble-scene__glow {
    opacity: 0.7;
    animation: none;
}

.assemble-scene.is-linked .fiber-pulses {
    animation: pulses-fade-in 0.55s ease 0.35s forwards;
}

.assemble-scene.is-alive .fiber-pulses {
    opacity: 1;
    animation: none;
}

.assemble-scene.is-wireless .wifi-boost {
    animation: wifi-boost-in 0.7s ease forwards;
}

.assemble-scene.is-alive .wifi-boost {
    opacity: 1;
    animation: none;
}

.assemble-scene.is-alive .wifi-ring {
    animation: wifi-ring-pulse 2.6s ease-in-out infinite;
}

.assemble-scene.is-alive .wifi-ring--b {
    animation-delay: -1.3s;
}

.assemble-scene.is-alive .wifi-ring:nth-child(3) {
    animation-delay: -0.65s;
}

@keyframes glow-in {
    from { opacity: 0; }
    to { opacity: 0.75; }
}

@keyframes ref-appear {
    from {
        opacity: 0;
        transform: scale(0.96);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulses-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes wifi-boost-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes wifi-ring-pulse {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 0.85; }
}

@media (max-width: 980px) {
    .hero-assemble {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .assemble-scene {
        position: relative;
        top: auto;
        order: 0;
        width: min(100%, 100%);
        max-width: 32rem;
        margin-top: 0.25rem;
        margin-inline: auto;
    }

    .hero-assemble__copy {
        order: -1;
        max-width: none;
    }

    .hero-assemble__titre {
        font-size: clamp(1.2rem, 5.2vw, 1.55rem);
    }

    .valeurs-guide__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 620px) {
    .valeurs-guide {
        padding: 1.25rem 0.9rem 1.4rem;
    }

    .valeurs-guide__grid {
        grid-template-columns: 1fr;
        gap: 0.9rem;
    }
}

@media (max-width: 520px) {
    .hero-assemble__copy {
        padding: 1rem 0.95rem 1.15rem;
    }

    .hero-assemble__actions {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-assemble__actions .btn {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .assemble-scene.is-ready .assemble-scene__glow,
    .assemble-scene.is-ready .assemble-ref,
    .assemble-scene.is-linked .fiber-pulses,
    .assemble-scene.is-wireless .wifi-boost,
    .assemble-scene.is-alive .wifi-boost,
    .assemble-scene.is-alive .wifi-ring,
    body.theme-lumineux .btn-primary {
        animation: none !important;
        transition: none !important;
    }

    .assemble-ref {
        opacity: 1 !important;
        transform: none !important;
    }

    .assemble-scene__glow {
        opacity: 0.6 !important;
    }

    .fiber-pulses {
        display: none !important;
    }

    .wifi-boost {
        opacity: 0.45 !important;
    }

    body.theme-lumineux .btn-primary:hover {
        transform: none;
    }
}
