/*
Theme Name: AMAP44
Description: Styles front du thème enfant AMAP44.
*/

/* ==========================================================================
   Base
   ========================================================================== */

:root {
    --amap44-green: #0b7a2a;
    --amap44-green-dark: #063f1a;
    --amap44-green-soft: #e9f5e7;
    --amap44-blue: #1d6f9f;
    --amap44-text: #172033;
    --amap44-muted: #667085;
    --amap44-border: #e5e7eb;
    --amap44-bg: #f5f6f4;
    --amap44-white: #ffffff;
    --amap44-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
    --amap44-radius: 14px;
}

body {
    color: var(--amap44-text);
}

a {
    color: #1769aa;
}

a:hover,
a:focus {
    color: var(--amap44-green);
}

.amap44-muted {
    color: var(--amap44-muted);
}

.amap44-button,
.amap44-more-link {
    font-weight: 700;
    color: var(--amap44-green);
}

.amap44-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: var(--amap44-green-soft);
    text-decoration: none;
}

/* ==========================================================================
   Fiches annuaire AMAP / Producteur / Lieu / Événement
   ========================================================================== */

.amap44-single {
    background: var(--amap44-bg);
}

/* GeneratePress dimensionne #primary en shrink-to-fit (flex-basis: auto,
   sans width) quand la mise en page n'appelle pas generate_construct_sidebars()
   — ce qui est le cas de tous nos templates. Sans width explicite, la largeur
   du bloc suit alors le contenu le plus large (ex. longueur du titre) au lieu
   de remplir le conteneur, d'où des largeurs de boîte incohérentes d'une page
   à l'autre. */
#primary.amap44-single,
#primary.amap44-archive {
    width: 100%;
}

.amap44-single .amap44-entry,
.amap44-entry {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 24px 64px;
}

/* --------------------------------------------------------------------------
   Cartouche haut
   -------------------------------------------------------------------------- */

.amap44-single .amap44-hero,
.amap44-page-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 32px;
    align-items: center;
    margin: 0 0 28px;
    padding: 32px;
    background: var(--amap44-white);
    border-radius: var(--amap44-radius);
    box-shadow: var(--amap44-shadow);
}

.amap44-single .amap44-hero:not(:has(.amap44-hero__image)),
.amap44-page-header:not(:has(.amap44-page-header__image)) {
    grid-template-columns: minmax(0, 1fr);
}

.amap44-single .amap44-hero__content,
.amap44-page-header__text {
    min-width: 0;
}

.amap44-kicker,
.amap44-single .amap44-kicker {
    margin: 0 0 12px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--amap44-green);
}

.amap44-single .amap44-hero h1,
.amap44-page-header h1,
.amap44-page-header__text h1 {
    margin: 0 0 16px;
    font-size: clamp(2rem, 4vw, 3.4rem);
    line-height: 1.1;
    color: var(--amap44-text);
}

.amap44-single .amap44-hero__image,
.amap44-page-header__image {
    width: 100%;
}

.amap44-single .amap44-hero__image img,
.amap44-page-header__image img {
    display: block;
    width: 100%;
    height: 210px;
    object-fit: cover;
    border-radius: 10px;
}

.amap44-single--producteur .amap44-hero__image img {
    height: 230px;
}

.amap44-single--amap .amap44-hero__image img {
    height: 210px;
}

/* Les images mises en avant AMAP/producteur sont le plus souvent des logos
   carrés : "cover" dans une cartouche large et basse les rognait en haut et
   en bas. "contain" affiche le logo entier, quitte à laisser un léger
   entourage neutre au lieu de le recadrer. */
.amap44-single--producteur .amap44-hero__image img,
.amap44-single--amap .amap44-hero__image img {
    box-sizing: border-box;
    object-fit: contain;
    background: var(--amap44-white);
    padding: 12px;
}

/* --------------------------------------------------------------------------
   Badges / taxonomies
   -------------------------------------------------------------------------- */

.amap44-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 18px 0 0;
    padding: 0;
    list-style: none;
}

.amap44-tags li {
    margin: 0;
}

.amap44-tags a,
.amap44-review-badge {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 999px;
    background: var(--amap44-green-soft);
    color: var(--amap44-green-dark);
    font-size: 13px;
    text-decoration: none;
}

.amap44-review-badge {
    margin: 0 0 8px;
}

.amap44-review-badge--needs_fix {
    background: #fff4d6;
    color: #8a5b00;
}

.amap44-review-badge--reviewed {
    background: #e7f0ff;
    color: #164a8b;
}

/* --------------------------------------------------------------------------
   Layout 2/3 - 1/3
   -------------------------------------------------------------------------- */

.amap44-single .amap44-layout,
.amap44-archive .amap44-layout,
.amap44-detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr);
    gap: 28px;
    align-items: start;
}

.amap44-single .amap44-layout__main,
.amap44-single .amap44-layout__side,
.amap44-archive .amap44-layout__main,
.amap44-archive .amap44-layout__side,
.amap44-detail-layout__main,
.amap44-detail-layout__side {
    min-width: 0;
}

.amap44-single .amap44-layout__side,
.amap44-archive .amap44-layout__side,
.amap44-detail-layout__side {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.amap44-archive .amap44-layout__side {
    position: sticky;
    top: 24px;
}

/* --------------------------------------------------------------------------
   Panels blancs
   -------------------------------------------------------------------------- */

.amap44-panel {
    margin-bottom: 24px;
    padding: 28px;
    background: var(--amap44-white);
    border-radius: var(--amap44-radius);
    box-shadow: var(--amap44-shadow);
}

.amap44-layout__side .amap44-panel,
.amap44-detail-layout__side .amap44-panel {
    margin-bottom: 0;
}

.amap44-panel h2 {
    margin-top: 0;
    margin-bottom: 18px;
    font-size: 1.45rem;
    line-height: 1.25;
    color: var(--amap44-green-dark);
}

.amap44-panel h3 {
    margin-top: 0;
    font-size: 1.2rem;
    line-height: 1.3;
    color: var(--amap44-green-dark);
}

.amap44-panel h4 {
    margin-top: 0;
    font-size: 1.05rem;
    line-height: 1.35;
    color: var(--amap44-green-dark);
}

/* --------------------------------------------------------------------------
   Contenu éditorial
   -------------------------------------------------------------------------- */

.amap44-content {
    font-size: 16px;
    line-height: 1.7;
}

.amap44-content > *:first-child {
    margin-top: 0;
}

.amap44-content > *:last-child {
    margin-bottom: 0;
}

.amap44-content img {
    max-width: 100%;
    height: auto;
}

/* --------------------------------------------------------------------------
   Informations pratiques
   -------------------------------------------------------------------------- */

.amap44-info-list {
    margin: 0;
}

.amap44-info-list > div {
    padding: 12px 0;
    border-bottom: 1px solid var(--amap44-border);
}

.amap44-info-list > div:first-child {
    padding-top: 0;
}

.amap44-info-list > div:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.amap44-info-list dt {
    margin-bottom: 4px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #6b7280;
}

.amap44-info-list dd {
    margin: 0;
}

/* --------------------------------------------------------------------------
   Listes de liens simples
   -------------------------------------------------------------------------- */

.amap44-related-list {
    margin: 0;
    padding-left: 1.1rem;
}

.amap44-related-list li + li {
    margin-top: 6px;
}

/* --------------------------------------------------------------------------
   Cartes liées : Producteurs / AMAP
   -------------------------------------------------------------------------- */

.amap44-card-list,
.amap44-related-cards,
.amap44-panel--related-main .amap44-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.amap44-related-card {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 14px;
    padding: 14px;
    border: 1px solid #e1e5dc;
    border-radius: 14px;
    background: #fbfcf8;
}

.amap44-related-card__image img,
.amap44-related-card__thumb img {
    display: block;
    width: 92px;
    height: 92px;
    object-fit: cover;
    border-radius: 10px;
}

.amap44-related-card h3,
.amap44-related-card__title {
    margin: 0 0 6px;
    font-size: 1.05rem;
    font-weight: 700;
}

.amap44-related-card h3 a,
.amap44-related-card__title a {
    text-decoration: none;
}

.amap44-related-card p,
.amap44-related-card__excerpt {
    margin: 0 0 8px;
    font-size: 13px;
    line-height: 1.45;
    color: #4b5563;
}

.amap44-card-meta {
    margin: 0 0 8px;
    padding: 0;
    list-style: none;
    font-size: .92rem;
    color: #4e5b4d;
}

.amap44-related-card__link {
    font-weight: 700;
    font-size: 13px;
}

/* --------------------------------------------------------------------------
   Galerie + lightbox
   -------------------------------------------------------------------------- */

.amap44-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
}

.amap44-gallery-item {
    display: block;
    overflow: hidden;
    border-radius: 10px;
    background: #f3f4f6;
}

.amap44-gallery-item img {
    display: block;
    width: 100%;
    height: 140px;
    object-fit: cover;
    transition: transform .2s ease;
}

.amap44-gallery-item:hover img {
    transform: scale(1.04);
}

.amap44-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 32px;
    background: rgba(0, 0, 0, 0.88);
}

.amap44-lightbox.is-open {
    display: flex;
}

.amap44-lightbox-open {
    overflow: hidden;
}

.amap44-lightbox__figure {
    max-width: min(1100px, 90vw);
    max-height: 90vh;
    margin: 0;
    text-align: center;
}

.amap44-lightbox__image {
    display: block;
    max-width: 100%;
    max-height: 82vh;
    margin: 0 auto;
    object-fit: contain;
    background: #111;
}

.amap44-lightbox__caption {
    margin-top: 12px;
    color: #fff;
    font-size: 14px;
}

.amap44-lightbox__close,
.amap44-lightbox__prev,
.amap44-lightbox__next {
    position: absolute;
    border: 0;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    cursor: pointer;
    line-height: 1;
}

.amap44-lightbox__close {
    top: 18px;
    right: 18px;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    font-size: 34px;
}

.amap44-lightbox__prev,
.amap44-lightbox__next {
    top: 50%;
    transform: translateY(-50%);
    width: 54px;
    height: 72px;
    border-radius: 8px;
    font-size: 54px;
}

.amap44-lightbox__prev {
    left: 18px;
}

.amap44-lightbox__next {
    right: 18px;
}

.amap44-lightbox__close:hover,
.amap44-lightbox__prev:hover,
.amap44-lightbox__next:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* --------------------------------------------------------------------------
   Localisation / carte
   -------------------------------------------------------------------------- */

.amap44-location-wide .amap44-panel {
    margin-top: 0;
}

.amap44-map-embed iframe,
.amap44-location-wide iframe,
.amap44-location-wide .amap44-map,
.amap44-location-wide .amap44-location-map,
.amap44-single iframe[src*="openstreetmap"] {
    display: block;
    width: 100%;
    min-height: 360px;
    border: 0;
    border-radius: 12px;
    overflow: hidden;
}

.amap44-map-embed iframe {
    height: 360px;
}

/* ==========================================================================
   Archives annuaire
   ========================================================================== */

.amap44-archive {
    background: var(--amap44-bg);
}

.amap44-archive .amap44-archive-header,
.amap44-archive-header {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 24px 24px;
}

.amap44-archive-header h1 {
    margin: 0;
    font-size: clamp(2rem, 4vw, 3rem);
}

.amap44-archive-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 22px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px 64px;
}

.amap44-archive-card {
    overflow: hidden;
    background: var(--amap44-white);
    border-radius: var(--amap44-radius);
    box-shadow: var(--amap44-shadow);
}

.amap44-archive-card__image img {
    display: block;
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.amap44-archive-card__body {
    padding: 20px;
}

.amap44-archive-card h2 {
    margin: 0 0 10px;
    font-size: 1.25rem;
}

.amap44-archive-search {
    margin: 18px 0 24px;
    padding: 18px;
    border: 1px solid #dbe7d7;
    border-radius: 14px;
    background: #f7fbf6;
}

.amap44-archive-search label {
    display: block;
    margin-bottom: 8px;
    color: var(--amap44-green-dark);
    font-weight: 800;
}

.amap44-archive-search__row {
    display: flex;
    gap: 10px;
}

.amap44-archive-search input[type="search"] {
    flex: 1;
    min-width: 0;
    height: 44px;
    padding: 0 14px;
    border: 1px solid #cbd5c7;
    border-radius: 999px;
    background: #fff;
}

.amap44-archive-search button {
    min-height: 44px;
    padding: 0 18px;
    border: 0;
    border-radius: 999px;
    background: var(--amap44-green);
    color: #fff;
    font-weight: 800;
    cursor: pointer;
}

@media (max-width: 700px) {
    .amap44-archive-search__row {
        display: grid;
    }

    .amap44-archive-search button {
        width: 100%;
    }
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 900px) {
    .amap44-single .amap44-hero,
    .amap44-page-header,
    .amap44-single .amap44-layout,
    .amap44-archive .amap44-layout,
    .amap44-detail-layout {
        grid-template-columns: 1fr;
    }

    .amap44-archive .amap44-layout__side {
        position: static;
    }

    .amap44-single .amap44-hero__image img,
    .amap44-page-header__image img {
        height: 220px;
    }

    .amap44-location-wide iframe,
    .amap44-location-wide .amap44-map,
    .amap44-location-wide .amap44-location-map,
    .amap44-map-embed iframe,
    .amap44-single iframe[src*="openstreetmap"] {
        min-height: 280px;
    }
}

@media (max-width: 600px) {
    .amap44-single .amap44-entry,
    .amap44-entry {
        padding: 24px 14px 48px;
    }

    .amap44-single .amap44-hero,
    .amap44-page-header,
    .amap44-panel {
        padding: 20px;
        border-radius: 12px;
    }

    .amap44-single .amap44-hero h1,
    .amap44-page-header h1,
    .amap44-page-header__text h1 {
        font-size: 2rem;
    }

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

    .amap44-gallery-item img {
        height: 110px;
    }

    .amap44-related-card {
        grid-template-columns: 1fr;
    }

    .amap44-related-card__image img,
    .amap44-related-card__thumb img {
        width: 100%;
        height: 160px;
    }

    .amap44-lightbox {
        padding: 16px;
    }

    .amap44-lightbox__prev,
    .amap44-lightbox__next {
        width: 42px;
        height: 56px;
        font-size: 42px;
    }

    .amap44-lightbox__prev {
        left: 8px;
    }

    .amap44-lightbox__next {
        right: 8px;
    }
}

/* Cartes liées avec / sans image */
.amap44-related-card.has-image {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.amap44-related-card.has-image .amap44-related-card__image {
    flex: 0 0 96px;
}

.amap44-related-card.has-image .amap44-related-card__image img {
    display: block;
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: 10px;
}

.amap44-related-card.no-image {
    display: block;
}

.amap44-related-card.no-image .amap44-related-card__body {
    width: 100%;
}

.amap44-related-card__body {
    min-width: 0;
}

.amap44-related-card__body h3 {
    margin-top: 0;
}

/* ==========================================================================
   Archives AMAP44
   ========================================================================== */

.amap44-archive {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 24px 64px;
}

.amap44-archive-hero {
    margin-bottom: 28px;
    padding: 32px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}

.amap44-archive-hero h1 {
    margin: 0 0 12px;
    font-size: clamp(2rem, 4vw, 3.2rem);
    line-height: 1.1;
}

.amap44-archive-hero p:last-child {
    margin-bottom: 0;
}

.amap44-archive-header {
    display: flex;
    gap: 16px;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 20px;
}

.amap44-archive .amap44-card-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
    gap: 18px;
}

.amap44-card-list--archive .amap44-related-card {
    min-height: 180px;
}

.amap44-card-list--archive .amap44-related-card.has-image {
    align-items: flex-start;
}

.amap44-card-list--archive .amap44-related-card__image {
    flex-basis: 110px;
}

.amap44-card-list--archive .amap44-related-card__image img {
    width: 110px;
    height: 110px;
}

.amap44-archive .pagination,
.amap44-archive .nav-links {
    margin-top: 28px;
}

.amap44-archive .nav-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.amap44-archive .page-numbers {
    display: inline-flex;
    min-width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    padding: 0 10px;
    border-radius: 999px;
    background: #fff;
    text-decoration: none;
}

.amap44-archive .page-numbers.current {
    background: #087a25;
    color: #fff;
}

@media (max-width: 700px) {
    .amap44-archive {
        padding: 24px 14px 48px;
    }

    .amap44-archive-hero,
    .amap44-archive .amap44-panel {
        padding: 20px;
        border-radius: 12px;
    }

    .amap44-archive-header {
        display: block;
    }

    .amap44-archive .amap44-card-list {
        grid-template-columns: 1fr;
    }
}

/* Badge type de fiche dans les cartes liées */
.amap44-card-type {
    display: inline-flex;
    width: fit-content;
    margin: 0 0 6px;
    padding: 3px 8px;
    border-radius: 999px;
    background: #e9f5e7;
    color: #087a25;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.amap44-card-type--producteur {
    background: #eef6ff;
    color: #075985;
}

.amap44-card-type--lieu_distribution {
    background: #fef3c7;
    color: #92400e;
}

.amap44-card-type--evenement {
    background: #fce7f3;
    color: #9d174d;
}

.amap44-lieu-map {
    min-height: 460px;
}

@media (max-width: 700px) {
    .amap44-lieu-map {
        min-height: 360px;
    }
}

/* ==========================================================================
   Archives événements / actualités
   ========================================================================== */

.amap44-event-list,
.amap44-news-list {
    display: grid;
    gap: 18px;
}

.amap44-event-card,
.amap44-news-card {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 22px;
    padding: 22px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #fff;
}

.amap44-event-card__date,
.amap44-news-card__date {
    align-self: start;
    padding: 14px;
    border-radius: 12px;
    background: #e9f5e7;
    color: #087a25;
    font-weight: 700;
    line-height: 1.4;
}

.amap44-event-card__body,
.amap44-news-card__body {
    min-width: 0;
}

.amap44-event-card__body h3,
.amap44-news-card__body h3 {
    margin: 0 0 10px;
    font-size: 1.35rem;
    line-height: 1.25;
}

.amap44-event-card__body p,
.amap44-news-card__body p {
    margin-top: 0;
}

@media (max-width: 700px) {
    .amap44-event-card,
    .amap44-news-card {
        grid-template-columns: 1fr;
    }
}

/* Image dans les cartes d'événements / actualités */
.amap44-event-card__side,
.amap44-news-card__side {
    display: grid;
    gap: 12px;
    align-content: start;
}

.amap44-event-card__image,
.amap44-news-card__image {
    display: block;
    overflow: hidden;
    border-radius: 12px;
    background: #f3f4f6;
}

.amap44-event-card__image img,
.amap44-news-card__image img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

@media (max-width: 700px) {
    .amap44-event-card__side,
    .amap44-news-card__side {
        display: block;
    }

    .amap44-event-card__image,
    .amap44-news-card__image {
        margin-top: 12px;
    }
}

/* ==========================================================================
   Pages cartes AMAP / Producteurs
   ========================================================================== */

.amap44-map-page {
    max-width: none;
    width: 100%;
    margin: 0;
    padding: 40px 24px 64px;
}

.amap44-map-page .amap44-archive-hero,
.amap44-map-page .amap44-panel {
    max-width: none;
    width: 100%;
}

.amap44-front-map {
    width: 100%;
    min-height: 720px;
    border-radius: 14px;
    overflow: hidden;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
}

.amap44-front-map .leaflet-popup-content {
    font-size: 14px;
    line-height: 1.45;
}

.amap44-front-map .leaflet-popup-content strong {
    display: block;
    margin-bottom: 4px;
}

.amap44-front-map .leaflet-popup-content a {
    color: #087a25;
    font-weight: 700;
}

.amap44-front-map .amap44-map-popup-type {
    display: inline-block;
    margin-bottom: 3px;
    color: #087a25;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

@media (max-width: 700px) {
    .amap44-map-page {
        padding: 24px 14px 48px;
    }

    .amap44-front-map {
        min-height: 520px;
        border-radius: 12px;
    }
}

/* Recherche de proximité sur les cartes */
.amap44-map-search {
    margin-bottom: 18px;
    padding: 18px;
    border: 1px solid #dbe7d7;
    border-radius: 14px;
    background: #f7fbf6;
}

.amap44-map-search label {
    display: block;
    margin-bottom: 8px;
    color: #12351f;
    font-weight: 700;
}

.amap44-map-search__row {
    display: flex;
    gap: 10px;
}

.amap44-map-search__input {
    flex: 1;
    min-width: 0;
    height: 44px;
    padding: 0 14px;
    border: 1px solid #cbd5c7;
    border-radius: 999px;
    background: #fff;
    font-size: 15px;
}

.amap44-map-search__button {
    min-height: 44px;
    padding: 0 18px;
    border: 0;
    border-radius: 999px;
    background: #087a25;
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.amap44-map-search__button:hover,
.amap44-map-search__button:focus {
    background: #065f1d;
}

.amap44-nearby-results {
    margin-top: 22px;
}

.amap44-nearby-results h3 {
    margin: 0 0 12px;
}

.amap44-nearby-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.amap44-nearby-list li {
    display: grid;
    gap: 8px;
    padding: 14px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #fff;
}

.amap44-nearby-list button {
    display: grid;
    gap: 4px;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.amap44-nearby-list button strong {
    color: #12351f;
    font-size: 15px;
}

.amap44-nearby-list button span {
    color: #087a25;
    font-weight: 700;
}

.amap44-nearby-list small {
    color: #64748b;
    line-height: 1.35;
}

.amap44-nearby-list a {
    color: #087a25;
    font-weight: 700;
    text-decoration: none;
}

.amap44-nearby-list a:hover,
.amap44-nearby-list a:focus {
    text-decoration: underline;
}

@media (max-width: 700px) {
    .amap44-map-search__row {
        display: grid;
    }

    .amap44-map-search__button {
        width: 100%;
    }

    .amap44-nearby-list {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Home page
   ========================================================================== */

.amap44-home--legacy {
    max-width: none;
    width: 100%;
    margin: 0;
    padding: 28px 24px 64px;
    background: #eef1ed;
}

.amap44-home-shell {
    max-width: 1240px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
}

/* Carte + recherche */
.amap44-home-map-section {
    background: #fff;
}

.amap44-home-map {
    width: 100%;
    min-height: 390px;
    border: 0;
    border-radius: 0;
}

.amap44-home-map-search {
    max-width: none;
    margin: 0;
    padding: 10px 28px;
    background: #176f9d;
}

.amap44-home-map-search .amap44-map-search {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0;
    border: 0;
    background: transparent;
}

.amap44-home-map-search .amap44-map-search label {
    color: #fff;
}

.amap44-home-map-search .amap44-muted {
    color: rgba(255, 255, 255, .85);
}

.amap44-home-nearby-results {
    max-width: none;
    margin: 0;
    padding: 0 36px 28px;
    background: #176f9d;
}

.amap44-home-nearby-results h3,
.amap44-home-nearby-results .amap44-nearby-list {
    max-width: 1160px;
    margin-right: auto;
    margin-left: auto;
}

.amap44-home-nearby-results h3 {
    margin-top: 0;
    margin-bottom: 12px;
    color: #fff;
}

/* Zone principale : colonne éditable + flux */
.amap44-home-main {
    display: grid;
    grid-template-columns: 330px minmax(0, 1fr);
    gap: 44px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 42px 36px 0;
}

.amap44-home-left,
.amap44-home-right {
    min-width: 0;
}

.amap44-home-editable {
    font-size: 15px;
    line-height: 1.65;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.035);
    padding: 15px;
}

/* Boîte de connexion (gestionnaires de fiche AMAP / Producteur) */
.amap44-account-box {
    margin-bottom: 24px;
    padding: 18px 20px;
    background: var(--amap44-white);
    border-radius: var(--amap44-radius);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.035);
}

.amap44-account-box__title,
.amap44-account-box__greeting {
    margin: 0 0 14px;
    font-weight: 700;
    color: #001b5c;
}

.amap44-account-box form p {
    margin: 0 0 10px;
}

.amap44-account-box label {
    display: block;
    margin-bottom: 4px;
    font-size: 13px;
    font-weight: 600;
}

.amap44-account-box input[type="text"],
.amap44-account-box input[type="password"],
.amap44-account-box input[type="email"] {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-sizing: border-box;
}

.amap44-account-box p.login-remember {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 400;
}

.amap44-account-box p.login-remember label {
    display: inline;
    margin: 0;
    font-weight: 400;
}

.amap44-account-box p.login-submit {
    margin-top: 4px;
}

.amap44-account-box input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border: 0;
    border-radius: 999px;
    background: var(--amap44-green-soft);
    color: var(--amap44-green);
    font-weight: 700;
    cursor: pointer;
}

.amap44-account-box__actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.amap44-account-box__logout {
    font-size: 13px;
    color: var(--amap44-muted);
    text-decoration: underline;
}

.amap44-home-editable h2,
.amap44-home-editable h3 {
    color: #001b5c;
}

.amap44-home-editable h2 {
    margin: 0 0 24px;
    font-size: 1.45rem;
}

.amap44-home-editable h3 {
    margin: 28px 0 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #222;
    font-size: 1rem;
    text-transform: uppercase;
}

.amap44-home-left-block {
    margin-bottom: 26px;
}

/* Titres sections */
.amap44-home-section-title {
    display: flex;
    gap: 16px;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 22px;
}

.amap44-home-section-title h2 {
    margin: 0;
    color: #001b5c;
    font-size: 1.7rem;
    line-height: 1.2;
}

.amap44-home-section-title a {
    color: #087a25;
    font-weight: 700;
    text-decoration: none;
}

.amap44-home-section-title a:hover,
.amap44-home-section-title a:focus {
    text-decoration: underline;
}

/* Actus + événements */
.amap44-home-news-grid,
.amap44-home-event-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 26px 34px;
}

.amap44-home-events {
    margin-top: 48px;
}

.amap44-home-news-card,
.amap44-home-event-card {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 18px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.035);

}

.amap44-home-card-side {
    display: grid;
    gap: 8px;
    align-content: start;
}

.amap44-home-news-card__date,
.amap44-home-event-card__date {
    overflow: hidden;
    border-radius: 2px;
    background: #1775a6;
    color: #fff;
    font-weight: 800;
    text-align: center;
    text-transform: uppercase;
}

.amap44-home-news-card__date span,
.amap44-home-event-card__date span {
    display: block;
    padding: 8px 6px;
    font-size: .78rem;
    line-height: 1.2;
}

.amap44-home-event-card__date small {
    display: block;
    padding: 0 6px 7px;
    font-size: .7rem;
    font-weight: 700;
    opacity: .9;
}

.amap44-home-card-thumb {
    display: block;
    overflow: hidden;
    width: 72px;
    height: 72px;
    border-radius: 6px;
    background: #f3f4f6;
}

.amap44-home-card-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.amap44-home-news-card__body,
.amap44-home-event-card__body {
    min-width: 0;
}

.amap44-home-news-card h3,
.amap44-home-event-card h3 {
    margin: 0 0 8px;
    color: #111;
    font-size: 1.05rem;
    line-height: 1.25;
}

.amap44-home-news-card h3 a,
.amap44-home-event-card h3 a {
    color: inherit;
    text-decoration: none;
}

.amap44-home-news-card h3 a:hover,
.amap44-home-news-card h3 a:focus,
.amap44-home-event-card h3 a:hover,
.amap44-home-event-card h3 a:focus {
    color: #087a25;
    text-decoration: underline;
}

.amap44-home-news-card p,
.amap44-home-event-card p {
    margin: 0 0 8px;
    color: #111827;
    font-size: .92rem;
    line-height: 1.5;
}

.amap44-home-event-card.is-past {
    opacity: .82;
}

.amap44-home-event-card__status {
    color: #087a25 !important;
    font-size: .75rem !important;
    font-weight: 800;
    text-transform: uppercase;
}

.amap44-home-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 8px;
}

.amap44-home-tag {
    display: inline-flex;
    margin-top: 0;
    padding: 3px 8px;
    border-radius: 3px;
    background: #e9f5e7;
    color: #087a25;
    font-size: .72rem;
    font-weight: 700;
    text-decoration: none;
}

/* Compteurs */
.amap44-home-stats {
    display: flex;
    gap: 14px;
    align-items: center;
    justify-content: center;
    max-width: 1200px;
    margin: 58px auto 0;
    padding: 24px 36px 30px;
    border-top: 1px solid #111;
}

.amap44-home-stat {
    display: inline-flex;
    align-items: center;
    background: #fff;
    box-shadow: 0 4px 14px rgba(15, 23, 42, .08);
}

.amap44-home-stat strong {
    display: inline-flex;
    min-width: 44px;
    min-height: 36px;
    align-items: center;
    justify-content: center;
    padding: 0 10px;
    background: #1775a6;
    color: #fff;
    font-size: 1rem;
    font-weight: 800;
}

.amap44-home-stat span {
    padding: 0 14px;
    color: #111;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

@media (max-width: 1000px) {
    .amap44-home-main,
    .amap44-home-news-grid,
    .amap44-home-event-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .amap44-home--legacy {
        padding: 18px 14px 48px;
    }

    .amap44-home-shell {
        border-radius: 14px;
    }

    .amap44-home-main {
        padding: 30px 20px 0;
    }

    .amap44-home-map-search {
        padding: 20px;
    }

    .amap44-home-stats {
        padding: 22px 20px 28px;
    }
}

@media (max-width: 700px) {
    .amap44-home-map {
        min-height: 420px;
    }

    .amap44-home-section-title {
        display: block;
    }

    .amap44-home-news-card,
    .amap44-home-event-card {
        grid-template-columns: 64px minmax(0, 1fr);
        gap: 14px;
    }

    .amap44-home-card-thumb {
        width: 64px;
        height: 64px;
    }
}

/* ==========================================================================
   Pages FAQ
   ========================================================================== */

.amap44-faq {
    display: grid;
    gap: 12px;
}

.amap44-faq-item {
    padding: 0;
    border: 1px solid var(--amap44-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: var(--amap44-shadow);
}

.amap44-faq-item summary {
    cursor: pointer;
    padding: 16px 18px;
    color: var(--amap44-green-dark);
    font-weight: 800;
}

.amap44-faq-answer {
    padding: 0 18px 18px;
    line-height: 1.65;
}

.amap44-faq-answer > *:first-child {
    margin-top: 0;
}

.amap44-faq-answer > *:last-child {
    margin-bottom: 0;
}

/* --------------------------------------------------------------------------
   Arborescence des productions (archives + page dédiée)
   -------------------------------------------------------------------------- */

.amap44-production-browse {
    margin-bottom: 24px;
}

.amap44-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    align-items: start;
}

@media (max-width: 900px) {
    .amap44-two-col {
        grid-template-columns: 1fr;
    }
}

.amap44-production-tree,
.amap44-production-tree ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.amap44-production-tree > li {
    margin: 0 0 8px;
}

.amap44-production-tree ul {
    margin: 8px 0 8px 20px;
    padding-left: 14px;
    border-left: 2px solid var(--amap44-border);
}

.amap44-production-tree ul li {
    margin: 8px 0 0;
}

.amap44-production-tree ul li:first-child {
    margin-top: 0;
}

.amap44-production-tree a {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 999px;
    background: var(--amap44-green-soft);
    color: var(--amap44-green-dark);
    font-size: 13px;
    text-decoration: none;
}

.amap44-production-tree a:hover,
.amap44-production-tree a:focus {
    background: var(--amap44-green);
    color: var(--amap44-white);
}

/* Sous-menus GeneratePress / AMAP44 */
.main-navigation ul ul {
    background: #fff;
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.14);
    border-radius: 0 0 2px 2px;
}

.main-navigation ul ul li {
    background: #fff;
}

.main-navigation ul ul li a {
    background: #fff;
    color: #002060;
    font-weight: 500;
}

.main-navigation ul ul li a:hover,
.main-navigation ul ul li.sfHover > a {
    background: #f4f7f2;
    color: var(--amap44-green);
}

/* Titres de section dans les sous-menus */
.main-navigation ul ul li.amap44-menu-section > a {
    cursor: default;
    pointer-events: none;
    color: #111;
    font-weight: 800;
    font-size: 16px;
    line-height: 1.35;
    background: #fff;
    padding-top: 18px;
    padding-bottom: 8px;
}

/* Premier titre de section : pas trop d'espace au-dessus */
.main-navigation ul ul li.amap44-menu-section:first-child > a {
    padding-top: 14px;
}

/* Optionnel : largeur de dropdown proche de l'ancien site */
.main-navigation ul ul {
    min-width: 250px;
}

.main-navigation ul ul li a {
    padding: 10px 20px;
}

/* Titre front-page GeneratePress / AMAP44 */
.main-title a, .main-title a:hover {
    color: #4e4848e3;
    font-style: italic;
    font-variant-caps: small-caps;
}

/* ==========================================================================
   Menu de pied de page
   ========================================================================== */

.amap44-footer-menu {
    width: 100%;
    padding: 10px 0;
}

.amap44-footer-menu__list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 24px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.amap44-footer-menu__list li {
    margin: 0;
}

.amap44-footer-menu__list a {
    color: inherit;
    text-decoration: none;
    font-size: 14px;
}

.amap44-footer-menu__list a:hover,
.amap44-footer-menu__list a:focus {
    text-decoration: underline;
}