/* =============================================================================
   ESTEYS.COM — Feuille de style
   Thème "mer & voile" : marine profond, bleu océan, sable, écume.
   Un seul fichier, organisé par sections. Modifie les variables ci-dessous
   pour changer les couleurs de tout le site d'un coup.
   ============================================================================= */

:root {
    /* Couleurs */
    --marine:      #0b2b45;   /* bleu marine profond (header, footer) */
    --marine-2:    #123a5c;   /* variante */
    --ocean:       #1e7aa8;   /* bleu océan (liens, accents) */
    --ocean-clair: #3aa0cf;
    --sable:       #f3ead6;   /* sable clair */
    --sable-fonce: #e7d8b8;
    --corail:      #e07a5f;   /* accent chaud (boutons secondaires) */
    --creme:       #fbf9f4;   /* fond de page */
    --encre:       #23303a;   /* texte principal */
    --gris:        #5c6b76;   /* texte secondaire */
    --blanc:       #ffffff;

    /* Mesures */
    --largeur:     1120px;
    --radius:      12px;
    --ombre:       0 6px 24px rgba(11, 43, 69, .10);
    --ombre-forte: 0 12px 40px rgba(11, 43, 69, .18);
    --transi:      .2s ease;

    /* Typographie */
    --police-titre: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    --police-texte: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

/* --- Base ---------------------------------------------------------------- */
* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--police-texte);
    color: var(--encre);
    background: var(--creme);
    line-height: 1.65;
    font-size: 17px;
}

h1, h2, h3, h4 {
    font-family: var(--police-titre);
    line-height: 1.2;
    color: var(--marine);
    margin: 0 0 .6em;
    font-weight: 700;
}
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1.1em; }

a { color: var(--ocean); text-decoration: none; transition: color var(--transi); }
a:hover { color: var(--marine); text-decoration: underline; }

img { max-width: 100%; height: auto; display: block; }

.wrap {
    width: min(100% - 2.5rem, var(--largeur));
    margin-inline: auto;
}

/* --- Boutons ------------------------------------------------------------- */
.btn {
    display: inline-block;
    padding: .8em 1.6em;
    border-radius: 999px;
    background: var(--ocean);
    color: var(--blanc);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform var(--transi), background var(--transi), box-shadow var(--transi);
    box-shadow: var(--ombre);
    text-decoration: none;
}
.btn:hover { background: var(--marine); color: var(--blanc); transform: translateY(-2px); text-decoration: none; }
.btn--corail { background: var(--corail); }
.btn--corail:hover { background: #c9603f; }
.btn--ghost {
    background: transparent;
    color: var(--blanc);
    border: 2px solid rgba(255,255,255,.7);
    box-shadow: none;
}
.btn--ghost:hover { background: rgba(255,255,255,.15); color: var(--blanc); border-color: #fff; }

/* --- En-tête + navigation ------------------------------------------------ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--marine);
    box-shadow: 0 2px 12px rgba(0,0,0,.15);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 68px;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    color: var(--blanc);
    font-family: var(--police-titre);
    font-weight: 700;
    font-size: 1.4rem;
    text-decoration: none;
}
.brand:hover { color: var(--blanc); text-decoration: none; }
.brand-mark { font-size: 1.5rem; }
.brand-dot { color: var(--ocean-clair); }

.site-nav ul {
    display: flex;
    gap: .3rem;
    list-style: none;
    margin: 0; padding: 0;
}
.site-nav a {
    display: block;
    padding: .55em .9em;
    color: #dbe7f0;
    font-weight: 500;
    border-radius: 8px;
    transition: background var(--transi), color var(--transi);
}
.site-nav a:hover { background: rgba(255,255,255,.1); color: #fff; text-decoration: none; }
.site-nav a.active { color: #fff; background: var(--ocean); }
.site-nav .caret { font-size: .7em; opacity: .8; }

/* Sous-menu déroulant */
.site-nav .has-sub { position: relative; }
.site-nav .sub-menu {
    position: absolute; top: 100%; left: 0; min-width: 210px;
    background: var(--marine-2); border-radius: 0 0 10px 10px;
    box-shadow: var(--ombre-forte); padding: .4rem;
    display: none; flex-direction: column; z-index: 60;
}
.site-nav .has-sub:hover > .sub-menu,
.site-nav .has-sub:focus-within > .sub-menu { display: flex; }
.site-nav .sub-menu a { color: #dbe7f0; padding: .55em .8em; border-radius: 6px; }
.site-nav .sub-menu a:hover { background: var(--ocean); color: #fff; }

/* Menu "burger" (mobile) */
.nav-burger { display: none; cursor: pointer; padding: .4rem; }
.nav-burger span {
    display: block; width: 26px; height: 3px; margin: 5px 0;
    background: #fff; border-radius: 2px; transition: var(--transi);
}

/* --- Sections génériques ------------------------------------------------- */
.section { padding: clamp(3rem, 6vw, 5rem) 0; }
.section--sable { background: var(--sable); }
.section-titre { text-align: center; margin-bottom: 2.5rem; }
.section-titre p { color: var(--gris); max-width: 640px; margin-inline: auto; }

/* --- Hero (bandeau d'accueil) -------------------------------------------- */
.hero {
    position: relative;
    color: #fff;
    text-align: center;
    padding: clamp(4rem, 12vw, 8rem) 0;
    background: linear-gradient(180deg, rgba(11,43,69,.55), rgba(11,43,69,.75)),
                var(--marine-2) center/cover no-repeat;
}
.hero.has-img { background-image: linear-gradient(180deg, rgba(11,43,69,.45), rgba(11,43,69,.72)), var(--hero-img); }
.hero h1 { color: #fff; margin-bottom: .4em; }
.hero p.lead { font-size: 1.25rem; max-width: 720px; margin: 0 auto 2rem; color: #eaf2f8; }
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* --- Cartes (articles / bateaux) ----------------------------------------- */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.8rem;
}
.card {
    background: var(--blanc);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--ombre);
    transition: transform var(--transi), box-shadow var(--transi);
    display: flex;
    flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--ombre-forte); }
.card-img {
    aspect-ratio: 16/10;
    background: linear-gradient(135deg, #d7e6ef, #eef4f6) center/cover no-repeat;
}
/* Tuiles de catégorie (accueil) : dégradé + libellé, sans photo */
.card-img--cat { display: flex; align-items: center; justify-content: center; }
.card-img--cat .tile-label {
    color: #fff; font-family: var(--police-titre); font-weight: 700;
    font-size: 1.7rem; text-shadow: 0 2px 10px rgba(0,0,0,.35); text-align: center; padding: 0 1rem;
}
.card-img--nord-bassin    { background-image: linear-gradient(135deg, #1e7aa8, #0b2b45); }
.card-img--sud-bassin     { background-image: linear-gradient(135deg, #3aa0cf, #145a86); }
.card-img--plages-oceanes { background-image: linear-gradient(135deg, #e0a86a, #1e7aa8); }
.card-body { padding: 1.3rem 1.4rem 1.5rem; display: flex; flex-direction: column; flex: 1; }
.card-body h3 { margin-bottom: .4rem; }
.card-body h3 a { color: var(--marine); }
.card-date { font-size: .82rem; color: var(--gris); text-transform: uppercase; letter-spacing: .04em; margin-bottom: .5rem; }
.card-body p { color: var(--gris); font-size: .96rem; }
.card-link { margin-top: auto; font-weight: 600; }

/* --- Bloc de catégorie (page bassin) ------------------------------------- */
.cat-block { margin-bottom: 3.5rem; scroll-margin-top: 90px; }
.cat-head {
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 1rem; flex-wrap: wrap;
    border-bottom: 2px solid var(--sable-fonce); padding-bottom: .6rem; margin-bottom: 1.8rem;
}
.cat-head h2 { margin: 0; }
.cat-link { font-weight: 600; white-space: nowrap; }

/* --- Deux colonnes texte/image ------------------------------------------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--ombre); }
.split--reverse .split-text { order: 2; }

/* --- Contenu d'article --------------------------------------------------- */
.article { max-width: 760px; margin-inline: auto; }
.article-header { text-align: center; margin-bottom: 2.5rem; }
.article-date { color: var(--gris); font-size: .9rem; }
.article-body { font-size: 1.08rem; }
.article-body h2 { margin-top: 1.8em; }
.article-body img { border-radius: var(--radius); margin: 1.5rem 0; box-shadow: var(--ombre); }
.article-body blockquote {
    border-left: 4px solid var(--ocean);
    margin: 1.5rem 0; padding: .5rem 1.3rem;
    background: var(--sable); color: var(--marine-2); font-style: italic;
    border-radius: 0 8px 8px 0;
}
.article-body code { background: var(--sable-fonce); padding: .1em .4em; border-radius: 5px; font-size: .9em; }

/* Fil d'Ariane */
.breadcrumb { font-size: .9rem; color: var(--gris); margin-bottom: 1.5rem; }
.breadcrumb a { color: var(--gris); }
.breadcrumb a:hover { color: var(--ocean); }

/* --- Pagination ---------------------------------------------------------- */
.pagination { display: flex; justify-content: center; gap: .5rem; margin-top: 3rem; }
.pagination a, .pagination span {
    padding: .5em .9em; border-radius: 8px; background: var(--blanc);
    box-shadow: var(--ombre); color: var(--marine); font-weight: 600;
}
.pagination .current { background: var(--ocean); color: #fff; }

/* --- Galerie photos ------------------------------------------------------ */
.galerie {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
}
.galerie-item {
    display: block;
    aspect-ratio: 4/3;
    border-radius: var(--radius);
    background: var(--sable-fonce) center/cover no-repeat;
    box-shadow: var(--ombre);
    transition: transform var(--transi), box-shadow var(--transi);
}
.galerie-item:hover { transform: translateY(-3px) scale(1.01); box-shadow: var(--ombre-forte); }

/* --- Bloc météo / vent (iframe Windy) ------------------------------------ */
.meteo-embed {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--ombre);
    background: var(--marine-2);
}
.meteo-embed iframe {
    display: block;
    width: 100%;
    height: 460px;
    border: 0;
}
@media (max-width: 600px) { .meteo-embed iframe { height: 360px; } }

/* --- Formulaire de contact ----------------------------------------------- */
.form-contact { max-width: 620px; margin-inline: auto; }
.form-row { margin-bottom: 1.2rem; }
.form-row label { display: block; font-weight: 600; margin-bottom: .35rem; color: var(--marine); }
.form-row input, .form-row textarea {
    width: 100%; padding: .8em 1em; font: inherit;
    border: 1px solid var(--sable-fonce); border-radius: 8px; background: #fff;
    transition: border var(--transi), box-shadow var(--transi);
}
.form-row input:focus, .form-row textarea:focus {
    outline: none; border-color: var(--ocean);
    box-shadow: 0 0 0 3px rgba(30,122,168,.15);
}
.form-row textarea { min-height: 160px; resize: vertical; }
/* Pot de miel anti-spam : caché aux humains, visible pour les robots */
.hp-field { position: absolute; left: -9999px; top: -9999px; width: 1px; height: 1px; overflow: hidden; }

.alert { padding: 1rem 1.3rem; border-radius: 8px; margin-bottom: 1.5rem; }
.alert--ok  { background: #e3f4e8; color: #1c6b39; border: 1px solid #b6e0c4; }
.alert--err { background: #fdecea; color: #9e3b2c; border: 1px solid #f3c7bf; }

/* --- Pied de page -------------------------------------------------------- */
.site-footer { background: var(--marine); color: #c6d5e1; margin-top: 4rem; }
.footer-grid {
    display: grid; grid-template-columns: 1.4fr 1fr 1.4fr; gap: 2.5rem;
    padding: 3rem 0 2.5rem;
}
.footer-col h4 { color: #fff; font-size: 1.05rem; margin-bottom: 1rem; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: .5rem; }
.footer-col a { color: #c6d5e1; }
.footer-col a:hover { color: #fff; }
.brand--footer { color: #fff; margin-bottom: 1rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding: 1.2rem 0; font-size: .88rem; }
.footer-bottom p { margin: 0; color: #9fb3c4; }

/* --- Responsive ---------------------------------------------------------- */
@media (max-width: 768px) {
    .nav-burger { display: block; }
    .site-nav {
        position: absolute; top: 68px; left: 0; right: 0;
        background: var(--marine); max-height: 0; overflow: hidden;
        transition: max-height .3s ease;
    }
    .nav-toggle:checked ~ .site-nav { max-height: 600px; overflow-y: auto; }
    .site-nav ul { flex-direction: column; padding: .5rem 1rem 1rem; }
    .site-nav a { padding: .8em .9em; }
    /* En mobile, le sous-menu s'affiche en liste indentée (pas de survol) */
    .site-nav .sub-menu {
        position: static; display: flex; box-shadow: none;
        background: rgba(255,255,255,.06); border-radius: 8px;
        margin: .2rem 0 .4rem .8rem; padding: .2rem;
    }
    .site-nav .caret { display: none; }

    .split, .split--reverse .split-text { grid-template-columns: 1fr; order: 0; }
    .footer-grid { grid-template-columns: 1fr; gap: 1.8rem; }
}
