/* ============================================================
   NEOFLUX — Nos Valeurs Fondamentales
   css/nos-valeur.css
   ============================================================ */

/* ── Section ── */
.nv-section {
    background: #0f172a !important;
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}
.nv-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255,255,255,.04) 1px, transparent 1px);
    background-size: 30px 30px;
    pointer-events: none;
}
.nv-section::after {
    content: '';
    position: absolute;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(212,47,47,.1) 0%, transparent 65%);
    top: -200px;
    right: -200px;
    border-radius: 50%;
    pointer-events: none;
}
.nv-inner {
    position: relative;
    z-index: 1;
}

/* ── Header ── */
.nv-header {
    text-align: center;
    margin-bottom: 3.5rem;
}
.nv-badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: rgba(212,47,47,.15);
    border: 1px solid rgba(212,47,47,.35);
    color: #f87171;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    padding: .4rem .9rem;
    border-radius: 50px;
    margin-bottom: 1.2rem;
}
.nv-title {
    font-size: clamp(1.8rem, 3vw, 2.6rem);
    font-weight: 800;
    color: #fff;
    line-height: 1.2;
    margin-bottom: .8rem;
}
.nv-title span { color: #f87171; }
.nv-sub {
    font-size: 1rem;
    color: rgba(255,255,255,.55);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ── Grid ── */
.nv-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

/* ── Cards — animation CSS pure, sans dépendance JS ── */
@keyframes nvCardIn {
    from { opacity: 0; transform: translateY(28px); }
    to   { opacity: 1; transform: translateY(0); }
}

.nv-card {
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.09);
    border-radius: 20px;
    padding: 2rem 1.8rem;
    transition: border-color .35s ease, transform .35s ease,
                box-shadow .35s ease, background .35s ease;
    position: relative;
    overflow: hidden;
    /* Animation CSS garantie — visible même si script.js échoue */
    opacity: 0;
    animation: nvCardIn 0.55s ease forwards;
}
.nv-card:nth-child(1) { animation-delay: 0.05s; }
.nv-card:nth-child(2) { animation-delay: 0.13s; }
.nv-card:nth-child(3) { animation-delay: 0.21s; }
.nv-card:nth-child(4) { animation-delay: 0.29s; }
.nv-card:nth-child(5) { animation-delay: 0.37s; }
.nv-card:nth-child(6) { animation-delay: 0.45s; }

.nv-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(212,47,47,.06), transparent);
    opacity: 0;
    transition: opacity .35s ease;
    border-radius: 20px;
}
.nv-card:hover {
    border-color: rgba(212,47,47,.4);
    transform: translateY(-6px);
    box-shadow: 0 20px 48px rgba(0,0,0,.35), 0 0 0 1px rgba(212,47,47,.15);
    background: rgba(255,255,255,.07);
}
.nv-card:hover::before { opacity: 1; }

/* ── Numéro décoratif ── */
.nv-num {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    font-size: 3.5rem;
    font-weight: 900;
    color: rgba(255,255,255,.04);
    line-height: 1;
    user-select: none;
    transition: color .35s;
}
.nv-card:hover .nv-num { color: rgba(212,47,47,.08); }

/* ── Icône ── */
.nv-icon {
    width: 58px;
    height: 58px;
    border-radius: 16px;
    background: rgba(212,47,47,.12);
    border: 1px solid rgba(212,47,47,.25);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #f87171;
    font-size: 1.4rem;
    margin-bottom: 1.3rem;
    transition: all .35s ease;
    position: relative;
    z-index: 1;
}
.nv-card:hover .nv-icon {
    background: linear-gradient(135deg, #D42F2F, #ef4444);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 8px 20px rgba(212,47,47,.4);
}

/* ── Texte ── */
.nv-card-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: .6rem;
    position: relative;
    z-index: 1;
}
.nv-card-desc {
    font-size: .87rem;
    color: rgba(255,255,255,.55);
    line-height: 1.7;
    margin: 0;
    position: relative;
    z-index: 1;
    transition: color .35s;
}
.nv-card:hover .nv-card-desc { color: rgba(255,255,255,.75); }

/* ── Barre de bas de carte ── */
.nv-card-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #D42F2F, #ef4444);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .35s ease;
    border-radius: 0 0 20px 20px;
}
.nv-card:hover .nv-card-bar { transform: scaleX(1); }

/* ── Responsive ── */
@media (max-width: 1024px) {
    .nv-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    .nv-grid { grid-template-columns: 1fr; gap: 1.2rem; }
    .nv-section { padding: 4rem 0; }
}

/* Désactiver les animations pour les utilisateurs qui préfèrent pas de mouvement */
@media (prefers-reduced-motion: reduce) {
    .nv-card {
        animation: none;
        opacity: 1;
    }
}
