/* Modèle de page « Presse numérique » (page-templates/presse-numerique.php) */

.pn {
    --pn-vert: #008538;
    --pn-bleu: #2280fd;
    --pn-gris: #858892;
    --pn-cadre: #a09993;
    --pn-titre: 'League Spartan', 'Montserrat', sans-serif;
    --pn-texte: 'Montserrat', sans-serif;
    font-family: var(--pn-texte);
    color: #000;
    background: #fff;
    overflow: hidden;
}

/* Neutralise les styles globaux du thème sur section / titres */
.pn section {
    font-size: 1rem;
    padding: 0;
    background: transparent !important; /* section[class]:not(...) du thème impose #f9f9f9 */
}
.pn section:before,
.pn section:after { content: none; } /* clearfix du thème : en grid/flex, il crée une ligne vide sous l'en-tête */
.pn h1 + *, .pn h2 + * { padding-top: 0; }
.pn h1, .pn h2, .pn h3 { margin: 0; }
.pn h1 span, .pn h2 span, .pn h3 span { font-family: inherit; font-weight: inherit; } /* le thème force Quicksand sur les span */
.pn div, .pn p, .pn a, .pn li, .pn label, .pn input, .pn button { font-family: var(--pn-texte); }
.pn p { margin: 0; }
.pn img { display: block; max-width: 100%; height: auto; }
.pn ul { list-style: none; margin: 0; padding: 0; }

.pn .screen-reader-text {
    position: absolute !important;
    width: 1px; height: 1px;
    overflow: hidden;
    clip: rect(1px, 1px, 1px, 1px);
    white-space: nowrap;
}

/* Typographie commune */
.pn-accent { color: var(--pn-vert); }

.pn-h2 {
    font-family: var(--pn-titre);
    font-weight: 700;
    font-size: clamp(1.75rem, 3.6vw, 3.25rem);
    line-height: 1.1;
    text-align: center;
}
.pn-h2 span { display: block; }
.pn-h2--sans { font-family: var(--pn-texte); font-size: clamp(1.6rem, 3.2vw, 2.75rem); }
.pn-h2--blanc { color: #fff; }
.pn-h2--vert { color: var(--pn-vert); }

.pn-lead {
    font-size: clamp(1rem, 1.6vw, 1.375rem);
    line-height: 1.25;
    text-align: center;
}
.pn-texte {
    font-size: clamp(.95rem, 1.3vw, 1.125rem);
    line-height: 1.3;
    text-align: center;
}

.pn-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: clamp(2.5rem, 7vw, 6rem) 1rem !important;
}

/* Bandeaux verts (titres de section et séparateurs) */
.pn .pn-bandeau {
    margin: 0;
    padding: .9rem 1rem;
    background: var(--pn-vert);
    color: #fff;
    font-family: var(--pn-texte);
    font-weight: 700;
    font-size: clamp(1.25rem, 2.9vw, 2.5rem);
    line-height: 1.2;
    text-align: center;
}
.pn .pn-bandeau--vide { height: clamp(2.5rem, 5.6vw, 4.75rem); padding: 0; }

/* Bouton */
.pn .pn-bouton {
    display: inline-block;
    padding: .55em 1.5em .45em;
    border-radius: 2em;
    background: var(--pn-vert);
    color: #fff;
    font-family: var(--pn-titre);
    font-weight: 700;
    font-size: clamp(1.1rem, 1.9vw, 1.6rem);
    line-height: 1;
    text-decoration: none;
    transition: background-color .2s;
}
.pn .pn-bouton:hover, .pn .pn-bouton:focus { background: #006b2d; color: #fff; }

/* 1. En-tête */
.pn-hero {
    display: grid;
    grid-template-columns: 45% 55%;
    align-items: center;
    min-height: clamp(16rem, 32vw, 40rem); /* pleine largeur : les mains touchent le bord gauche et le bas */
}
.pn-hero__visuels {
    position: relative;
    align-self: stretch;
    min-height: 100%;
}
.pn-hero__img {
    position: absolute;
    bottom: 0;
    width: auto;
}
.pn .pn-hero__img--1 { left: -22%; height: 92%; max-width: none; }
.pn .pn-hero__img--2 { left: 52%; height: 74%; max-width: none; }
.pn-hero__texte { padding: 2rem 1rem; }
.pn-hero__titre {
    font-family: var(--pn-titre);
    font-weight: 700;
    font-size: clamp(2rem, 4.7vw, 4rem);
    line-height: .95;
    text-align: center;
    margin-bottom: .2em !important;
}
.pn-hero .pn-lead { line-height: 1.15; }
.pn-hero__titre span { display: block; }

/* 2. Bandeau vidéo */
.pn-video {
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(20rem, 56vw, 48rem);
}
.pn-video__media { position: absolute; inset: 0; }
.pn .pn-video__player {
    width: 100%;
    height: 100%;
    object-fit: cover;
    max-width: none;
}
.pn-video__bandeau {
    position: relative;
    width: 100%;
    padding: clamp(1.5rem, 4vw, 3.5rem) 1rem;
    background: var(--pn-vert);
    color: #fff;
}
.pn-video__bandeau .pn-lead { max-width: 50rem; margin: .6em auto 0; }

/* 3. Application */
.pn-appli__contenu {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: clamp(1rem, 3vw, 2.5rem);
    margin: 2rem 0;
}
.pn-appli__img { width: min(100%, 22rem); }
.pn-appli__stores { display: flex; flex-direction: column; gap: 1.25rem; }
.pn-appli__store { display: flex; flex-direction: column; align-items: center; gap: .5rem; }
.pn-appli__qr { width: 6rem; }
.pn-appli .pn-lead { max-width: 58rem; margin: 0 auto; }

.pn-store {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    min-width: 8.5rem;
    padding: .35rem .75rem;
    border-radius: .5rem;
    background: #000;
    color: #fff;
    text-decoration: none;
    line-height: 1;
}
.pn-store:hover, .pn-store:focus { background: #333; color: #fff; }
.pn-store__icon { width: 1.4rem; height: 1.4rem; flex-shrink: 0; }
.pn-store__label { display: flex; flex-direction: column; text-align: left; }
.pn-store__label small { font-size: .55rem; text-transform: uppercase; letter-spacing: .02em; }
.pn-store__label span { font-size: 1rem; font-weight: 600; }

/* 4. Sélection */
.pn-selection__liste {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem 1rem;
}
.pn-selection__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}
.pn-selection__titre {
    font-family: var(--pn-titre);
    font-weight: 700;
    font-size: clamp(1.4rem, 2.2vw, 1.9rem);
    line-height: 1.1;
}
.pn-selection__img { width: min(100%, 17rem); }
.pn-selection__item .pn-bouton { margin-top: auto; }

/* 5. Nouvelle façon de lire */
.pn .pn-lecture {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: clamp(26rem, 56vw, 48rem);
    background: var(--pn-vert) !important;
    color: #fff;
}
.pn-lecture__texte { position: relative; z-index: 1; max-width: 52rem; padding: 2rem 1rem; }
.pn-lecture__texte .pn-h2 { font-size: clamp(1.9rem, 3.8vw, 3.5rem); }
.pn-lecture__texte .pn-lead { margin-top: .5em; font-size: clamp(1.1rem, 1.7vw, 1.6rem); line-height: 1.2; }
.pn .pn-lecture__img { position: absolute; width: auto; max-width: none; }
/* visuels calés sur la largeur de l'écran : ils occupent les côtés sans passer sous le texte */
.pn .pn-lecture__img--1 { left: 0; top: 8%; width: 23.5vw; height: auto; }
.pn .pn-lecture__img--2 { right: 0; bottom: 0; width: 21vw; height: auto; }

/* 6. Partout dans le monde */
.pn-monde__img { width: min(100%, 32rem); margin: 2.5rem auto; }
.pn-monde .pn-texte { max-width: 56rem; margin: 0 auto; }

/* 7. Fonctionnalités */
.pn-fonctions__liste {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem 3.5rem;
}
.pn-card {
    display: flex;
    flex-direction: column;
    min-height: 26rem;
    overflow: hidden;
    border-radius: 2rem;
    padding: 1.4rem 1.4rem 0;
    color: #fff;
}
.pn-card--vert { background: var(--pn-vert); }
.pn-card--bleu { background: var(--pn-bleu); }
.pn-card--gris { background: var(--pn-gris); }
.pn-card__titre {
    font-family: var(--pn-texte);
    font-weight: 400;
    font-size: clamp(1.6rem, 2.4vw, 2.1rem);
    line-height: 1.1;
    text-align: center;
}
.pn-card__corps { flex: 1; display: flex; gap: 1rem; margin-top: 1rem; }
.pn-card__texte { font-size: .95rem; line-height: 1.2; text-align: center; }

.pn-card--cote .pn-card__corps { align-items: center; padding-bottom: 1.4rem; }
.pn-card--cote .pn-card__img { width: 48%; flex-shrink: 0; }

.pn-card--dessous .pn-card__corps { flex-direction: column-reverse; justify-content: space-between; align-items: center; }
.pn-card--dessous .pn-card__img { width: 72%; margin-bottom: -1px; }

/* 8. Newsletter */
.pn-newsletter__cadre {
    display: flex;
    align-items: center;
    gap: 2rem;
    max-width: 59rem;
    margin: 0 auto;
    padding: 1.5rem 2rem 1.5rem 1rem;
    border: 6px solid var(--pn-cadre);
}
.pn-newsletter__img { width: 44%; flex-shrink: 0; }
.pn-newsletter__texte { flex: 1; text-align: center; }
.pn-newsletter__form {
    display: flex;
    align-items: stretch;
    max-width: 19rem;
    margin: 1rem auto;
    border: 1px solid #555;
    background: #fff;
}
/* le thème donne aux champs un fond gris et une marge haute */
.pn .pn-newsletter__form input,
.pn .pn-newsletter__form button {
    height: 2.25rem;
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    font-size: .8rem;
    line-height: 1;
}
.pn .pn-newsletter__form input {
    flex: 1;
    min-width: 0;
    padding: 0 .6rem;
    background: #fff;
    color: #000;
}
.pn .pn-newsletter__form button {
    flex: 0 0 auto;
    width: auto;
    padding: 0 .8rem;
    background: var(--pn-vert);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}
.pn .pn-newsletter__form button:hover, .pn .pn-newsletter__form button:focus { background: #006b2d; }
.pn-newsletter .pn-h2 { font-size: clamp(1.5rem, 2.7vw, 2.4rem); }
.pn-newsletter .pn-texte { max-width: 31rem; margin: 0 auto; font-size: clamp(.85rem, 1.1vw, .95rem); line-height: 1.25; }
.pn-newsletter__message:empty { display: none; }
.pn-newsletter__message { margin-bottom: 1rem; font-size: .9rem; }
.pn-newsletter__message p { margin: 0; }

/* Tablette */
@media (max-width: 1000px) {
    .pn-selection__liste { grid-template-columns: repeat(2, 1fr); }
    .pn-fonctions__liste { grid-template-columns: 1fr; max-width: 28rem; margin: 0 auto; }
}

/* Mobile */
@media (max-width: 760px) {
    .pn-hero { grid-template-columns: 1fr; }
    .pn-hero__texte { order: -1; padding-top: 1.5rem; }
    .pn-hero__visuels { min-height: 18rem; }
    .pn .pn-hero__img--1 { left: -10%; height: 88%; }
    .pn .pn-hero__img--2 { left: 46%; height: 74%; }

    .pn-appli__contenu { flex-direction: column; }
    .pn-appli__stores { flex-direction: row; }
    .pn .pn-appli__qr { display: none; } /* sur mobile, on ne scanne pas son propre écran */
    .pn-lead br, .pn-texte br { display: none; }

    .pn .pn-lecture { flex-direction: column; justify-content: space-between; }
    .pn .pn-lecture__img { position: static; height: auto; }
    .pn .pn-lecture__img--1 { width: 55%; align-self: flex-start; margin-top: 2rem; }
    .pn .pn-lecture__img--2 { width: 70%; align-self: flex-end; }

    .pn-newsletter__cadre { flex-direction: column; padding: 1.5rem 1rem; }
    .pn-newsletter__img { width: 80%; }
}

@media (max-width: 450px) {
    .pn-card--cote .pn-card__corps { flex-direction: column; }
    .pn-card--cote .pn-card__img { width: 60%; }
}
