/* =====================================================================
   jcaparos.com 2026 — feuille de style principale
   Univers : courses hippiques premium. Bleu marine + or + vert turf.
   ===================================================================== */

:root {
    --navy:      #0f1e3d;
    --navy-2:    #16294f;
    --navy-soft: #1d345e;
    --gold:      #c9a44c;
    --gold-2:    #e0c074;
    --green:     #1f9d57;
    --green-2:   #178a4a;
    --ink:       #1a2236;
    --muted:     #5b6679;
    --line:      #e4e7ef;
    --bg:        #f6f7fb;
    --white:     #ffffff;
    --radius:    14px;
    --shadow:    0 10px 30px rgba(15, 30, 61, .10);
    --shadow-sm: 0 4px 14px rgba(15, 30, 61, .08);
    --font:      'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --font-head: 'Fira Sans Condensed', 'Montserrat', sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font);
    color: var(--ink);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.15; margin: 0 0 .5em; color: var(--navy); }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 900; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); font-weight: 700; }

.container { width: min(1140px, 92%); margin-inline: auto; }
.section { padding: 72px 0; }
.text-center { text-align: center; }
.muted { color: var(--muted); }

/* ---------- Boutons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    font-family: var(--font-head); font-weight: 700; font-size: 1.02rem;
    padding: 13px 26px; border-radius: 999px; border: 0; cursor: pointer;
    text-decoration: none; transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
    letter-spacing: .2px;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn-green { background: var(--green); color: #fff; box-shadow: 0 8px 20px rgba(31,157,87,.35); }
.btn-green:hover { background: var(--green-2); color: #fff; }
.btn-gold { background: var(--gold); color: var(--navy); box-shadow: 0 8px 20px rgba(201,164,76,.35); }
.btn-gold:hover { background: var(--gold-2); color: var(--navy); }
.btn-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.5); }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.btn-outline { background: #fff; color: var(--navy); border: 1.5px solid var(--line); }
.btn-red { background: #d9342b; color: #fff; box-shadow: 0 8px 20px rgba(217,52,43,.35); }
.btn-red:hover { background: #b82a22; color: #fff; }
.btn-lg { padding: 16px 34px; font-size: 1.12rem; }
.btn-block { width: 100%; justify-content: center; }

/* ---------- En-tête / navigation ---------- */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(15,30,61,.96); backdrop-filter: blur(8px);
    border-bottom: 2px solid var(--gold);
}
.nav { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; }
.brand { display: flex; align-items: center; gap: 12px; color: #fff; font-family: var(--font-head); font-weight: 900; }
.brand:hover { text-decoration: none; }
.brand img { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--gold); }
.brand .brand-name { font-size: 1.15rem; line-height: 1.1; }
.brand .brand-sub { display: block; margin-top: 6px; font-size: .62rem; font-weight: 400; letter-spacing: 2px; color: var(--gold-2); text-transform: uppercase; }
.nav-links { display: flex; align-items: center; gap: 8px; }
.nav-links a { color: #dfe5f1; font-weight: 600; padding: 8px 14px; border-radius: 8px; font-size: .95rem; }
.nav-links a:hover { color: #fff; background: rgba(255,255,255,.08); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 0; color: #fff; font-size: 1.6rem; cursor: pointer; }

/* ---------- Hero ---------- */
.hero {
    position: relative; color: #fff; overflow: hidden;
    background:
        radial-gradient(1200px 500px at 80% -10%, rgba(201,164,76,.20), transparent 60%),
        linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 60%, #0b1730 100%);
}
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; padding: 70px 0 60px; }
.hero h1 { color: #fff; }
.hero h1 .accent { color: var(--gold-2); }
.hero p.lead { font-size: 1.18rem; color: #cdd6e6; max-width: 36ch; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0 28px; }
.chip { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); color: #eaf0fb; padding: 7px 14px; border-radius: 999px; font-size: .82rem; font-weight: 600; }
.chip i { color: var(--gold-2); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-photo { position: relative; }
.hero-photo img { margin-inline: auto; filter: drop-shadow(0 20px 40px rgba(0,0,0,.45)); max-height: 460px; }
.hero-photo .ring { position: absolute; inset: auto 0 -2% 0; height: 80%; background: radial-gradient(closest-side, rgba(201,164,76,.22), transparent); border-radius: 50%; z-index: 0; }

/* bandeau de confiance */
.trust { background: var(--navy-2); color: #cdd6e6; }
.trust .container { display: flex; flex-wrap: wrap; gap: 30px; justify-content: center; padding: 18px 0; font-size: .9rem; }
.trust b { color: var(--gold-2); }

/* ---------- Cartes ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
    box-shadow: var(--shadow-sm); padding: 28px; transition: transform .15s ease, box-shadow .15s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
/* Back-office : pas d'animation de survol sur les cards/cadres */
.bo .card { transition: none; }
.bo .card:hover { transform: none; box-shadow: var(--shadow-sm); }
.card .icon { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 12px; background: rgba(31,157,87,.12); color: var(--green); font-size: 1.3rem; margin-bottom: 16px; }

/* ---------- Offres / tarifs ---------- */
.section-head { text-align: center; max-width: 60ch; margin: 0 auto 48px; }
.section-head .eyebrow { color: var(--gold); font-weight: 700; letter-spacing: 3px; text-transform: uppercase; font-size: .78rem; }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; align-items: stretch; }
/* Variante : cartes de taille fixe qui ne s'étirent pas (1 ou 2 offres). */
.plans-fixed { display: flex; flex-wrap: wrap; justify-content: center; gap: 24px; align-items: stretch; }
.plans-fixed .plan { flex: 1 1 300px; max-width: 380px; }
.plan {
    background: #fff; border: 1px solid var(--line); border-radius: 18px; overflow: hidden;
    display: flex; flex-direction: column; box-shadow: var(--shadow-sm); position: relative;
}
.plan.is-featured { border-color: var(--gold); box-shadow: 0 14px 40px rgba(201,164,76,.22); }
.plan-flag { position: absolute; top: 14px; right: -34px; transform: rotate(45deg); background: var(--gold); color: var(--navy); font-weight: 700; font-size: .72rem; padding: 5px 40px; }
.plan-head { padding: 26px 26px 18px; background: linear-gradient(180deg, #fbfcff, #fff); border-bottom: 1px solid var(--line); min-height: 195px; }
.plan-head h3 { margin-bottom: 4px; }
.plan-kind { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; }
.plan-kind.premium { color: var(--gold); }
.plan-kind.solidaire { color: var(--green); }
.plan-kind.africa { color: #d97706; }
.plan-price { display: flex; align-items: baseline; gap: 6px; margin-top: 12px; }
.plan-price .amount { font-family: var(--font-head); font-size: 2.6rem; font-weight: 900; color: var(--navy); }
.plan-price .per { color: var(--muted); font-weight: 600; }
.plan-head .field-hint { font-size: 1.05rem; color: var(--ink); font-weight: 600; margin-top: 8px; }
.plan-body { padding: 22px 26px; flex: 1; }
.plan-body ul { list-style: none; margin: 0; padding: 0; }
.plan-body li { padding: 7px 0 7px 28px; position: relative; font-size: .95rem; }
.plan-body li::before { content: "\f00c"; font-family: "Font Awesome 6 Free"; font-weight: 900; color: var(--green); position: absolute; left: 0; top: 8px; font-size: .8rem; }
.plan-foot { padding: 0 26px 26px; }

/* ---------- Section Afrique ---------- */
.alert-vpn {
    background: #fff7e6; border: 1px solid #f0c674; color: #7a5b00;
    border-radius: 12px; padding: 14px 18px; display: flex; gap: 12px; align-items: flex-start;
    font-size: .95rem; margin: 18px auto; max-width: 760px;
}
.alert-vpn i { color: #d98e00; font-size: 1.2rem; margin-top: 2px; }

/* ---------- Formulaires (style imposé : fond #f3f5fe, bordure #99abfd) ---------- */
.auth-wrap { display: grid; grid-template-columns: 1fr 1fr; min-height: calc(100vh - 70px); }
.auth-aside { background: linear-gradient(160deg, var(--navy), var(--navy-2)); color: #fff; padding: 56px; display: flex; flex-direction: column; justify-content: center; }
.auth-aside h2 { color: #fff; }
.auth-aside .pic { width: 120px; height: 120px; border-radius: 50%; border: 3px solid var(--gold); margin-bottom: 24px; }
.auth-main { display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.auth-card { width: min(440px, 100%); }
.auth-card h1 { font-size: 1.9rem; }

.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 7px; font-size: .92rem; color: var(--ink); }
.input,
input:not([type]),
input[type="text"], input[type="email"], input[type="password"],
input[type="tel"], input[type="number"], input[type="date"], input[type="time"],
select, textarea {
    width: 100%; padding: 12px 14px; font-size: 1rem; font-family: var(--font);
    color: var(--ink); background: #f3f5fe; border: 1px solid #99abfd; border-radius: 10px;
    transition: border-color .12s ease, box-shadow .12s ease;
}
.input:focus, input:focus, select:focus, textarea:focus {
    outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(31,157,87,.15);
}

/* Éditeur de texte enrichi (WYSIWYG) — importé du back-office « Les Conseils de Daniel » */
.wz { border: 1px solid #99abfd; border-radius: 10px; overflow: hidden; background: #fff; }
.wz-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 2px; padding: 6px; background: #e9edfd; border-bottom: 1px solid #c5d0fb; }
.wz-btn { min-width: 32px; height: 30px; border: 1px solid transparent; background: transparent; border-radius: 6px; cursor: pointer; font-size: .9rem; color: var(--ink); padding: 0 9px; line-height: 1; }
.wz-btn:hover { background: #dbe2fb; }
.wz-btn.active { background: #cdd8fb; border-color: #99abfd; }
.wz-sep { width: 1px; align-self: stretch; background: #c5d0fb; margin: 2px 4px; }
.wz-size, .wz-color {
    height: 30px; border: 1px solid #c5d0fb; border-radius: 6px;
    background: #fff; color: var(--ink); font-size: .85rem;
    padding: 0 6px; cursor: pointer; width: auto;
}
.wz-size:hover, .wz-color:hover { background: #eef1fd; }
.wz-editor { min-height: 140px; padding: 12px 14px; outline: none; line-height: 1.35; font-family: var(--font); color: var(--ink); background: #fff; }
.wz-editor:focus { box-shadow: inset 0 0 0 2px rgba(31,157,87,.18); }
.wz-editor p { margin: 0 0 6px; }
.wz-editor h2 { margin: 0 0 10px; font-size: 1.2rem; color: var(--navy); }
.wz-editor ul, .wz-editor ol { margin: 0 0 10px; padding-left: 22px; }
.wz textarea.wz-source { display: none; width: 100%; min-height: 170px; border: none !important; border-radius: 0 !important; box-shadow: none !important; font-family: Consolas, Menlo, monospace; font-size: .88rem; padding: 12px 14px; resize: vertical; background: #fff; }
.wz.is-source .wz-editor { display: none; }
.wz.is-source textarea.wz-source { display: block; }

/* Hauteurs d'éditeur par champ */
.wz:has(textarea[name="news_titre"]) .wz-editor { min-height: 250px; }
.wz:has(textarea[name="news_texte"]) .wz-editor { min-height: 300px; }
.wz:has(textarea[name="news_description"]) .wz-editor { min-height: 110px; }
.input-icon { position: relative; }
.input-icon > i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: #6b7bbd; }
.input-icon input { padding-left: 42px; padding-right: 46px; }
.field-hint { font-size: .82rem; color: var(--muted); margin-top: 6px; }
.password-toggle { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); cursor: pointer; color: #6b7bbd; background: none; border: 0; padding: 0; line-height: 1; font-size: 1.05rem; }
.password-toggle:hover { color: var(--navy); }

.captcha-row { display: flex; align-items: center; gap: 12px; }
.captcha-q { font-family: var(--font-head); font-weight: 700; font-size: 1.2rem; background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 10px; white-space: nowrap; }
.captcha-row input { max-width: 110px; text-align: center; font-weight: 700; }

/* ---------- Messages ---------- */
.alert { border-radius: 10px; padding: 12px 16px; margin-bottom: 18px; font-size: .95rem; }
.alert-error { background: #fdecec; border: 1px solid #f3b4b4; color: #a01919; }
.alert-success { background: #e9f8ef; border: 1px solid #a9e0c1; color: #146c3f; }
.alert-info { background: #eaf1fd; border: 1px solid #b6cdf6; color: #1f4f9c; }
.alert-warn { background: #fff6e5; border: 1px solid #f0cf8e; color: #8a5a00; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--navy); color: #aeb8cc; padding: 54px 0 24px; }
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 36px; }
.site-footer a { color: #aeb8cc; }
.site-footer a:hover { color: var(--gold-2); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 32px; padding-top: 18px; font-size: .85rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }

/* ---------- Espace membre ---------- */
.dash { display: grid; grid-template-columns: 240px 1fr; min-height: calc(100vh - 70px); }
.dash-side { background: var(--navy); color: #cdd6e6; padding: 24px 16px; }
.dash-side a { display: flex; align-items: center; gap: 10px; color: #cdd6e6; padding: 11px 14px; border-radius: 10px; font-weight: 600; font-size: .92rem; margin-bottom: 4px; }
.dash-side a:hover, .dash-side a.active { background: rgba(255,255,255,.10); color: #fff; text-decoration: none; }
/* Menu déroulant (mobile) : masqué en bureau (espace membre + back-office) */
.dash-side-select-wrap { display: none; padding: 12px; }
.dash-main { padding: 36px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px,1fr)); gap: 18px; margin-bottom: 28px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px; box-shadow: var(--shadow-sm); }
.stat .n { font-family: var(--font-head); font-size: 1.8rem; font-weight: 900; color: var(--navy); }
.badge-status { display: inline-flex; align-items: center; gap: 7px; padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: .85rem; }
.badge-status.active { background: rgba(31,157,87,.14); color: var(--green-2); }
.badge-status.inactive { background: #fdecec; color: #a01919; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr; text-align: center; }
    .hero-photo { order: -1; }
    .hero-cta, .hero-badges { justify-content: center; }
    .hero p.lead { margin-inline: auto; }
    .cards { grid-template-columns: 1fr; }
    .auth-wrap { grid-template-columns: 1fr; }
    .auth-aside { display: none; }
    .footer-grid { grid-template-columns: 1fr; }
    .dash { grid-template-columns: 1fr; }
    /* Menus latéraux (espace membre + back-office) remplacés par une liste déroulante */
    .dash-side { display: none; }
    .dash-side-select-wrap { display: block; }
    .nav-links { position: fixed; inset: 64px 0 auto 0; flex-direction: column; background: var(--navy-2); padding: 16px; display: none; }
    .nav-links.open { display: flex; }
    .nav-toggle { display: block; }
}

/* Pages légales (mentions, CGUV) — contenu riche éditable */
.legal-content { line-height: 1.65; color: #2a2f45; }
.legal-content h3 { font-size: 1.4rem; margin: 0 0 14px; color: var(--navy); }
.legal-content h4 { font-size: 1.12rem; margin: 26px 0 8px; color: var(--navy); }
.legal-content h5 { font-size: 1rem; margin: 18px 0 6px; }
.legal-content p { margin: 0 0 14px; }
.legal-content hr { border: none; border-top: 1px solid var(--line); margin: 22px 0; }
.legal-content a { color: var(--green); text-decoration: underline; }
