/* ============================================================
   Lesly Tech LLC — design system v2
   5 thèmes : clair (défaut) · ambre · émeraude · nuit · sombre
   ============================================================ */
:root {
  --radius: 18px; --radius-s: 12px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --maxw: 1140px;
  --shadow: 0 18px 45px -18px rgba(60, 30, 5, .25);
  --shadow-s: 0 8px 22px -10px rgba(60, 30, 5, .22);
  --tr: .25s ease;
}
[data-theme="clair"], :root {
  --bg: #faf6ef; --bg2: #f3ecdd; --surface: #fffdf8;
  --ink: #2b2118; --muted: #7a6a58; --line: #e8ddc9;
  --brand: #c2571b; --brand2: #e8932f; --on-brand: #fff8ef;
  --hero-a: rgba(232, 147, 47, .16); --hero-b: rgba(194, 87, 27, .10);
  --footer-bg: #241a12; --footer-ink: #f3e9d8;
}
[data-theme="ambre"] {
  --bg: #fdf7ec; --bg2: #f9edd6; --surface: #fffdf6;
  --ink: #3a2a12; --muted: #8a6f45; --line: #eedcb8;
  --brand: #b45309; --brand2: #f59e0b; --on-brand: #fffaf0;
  --hero-a: rgba(245, 158, 11, .20); --hero-b: rgba(180, 83, 9, .12);
  --footer-bg: #2b1f0e; --footer-ink: #f7ecd4;
}
[data-theme="emeraude"] {
  --bg: #f4faf5; --bg2: #e6f3e9; --surface: #fdfffd;
  --ink: #1e2f24; --muted: #5f7266; --line: #d5e8d9;
  --brand: #0e7a4f; --brand2: #34b37a; --on-brand: #f2fbf5;
  --hero-a: rgba(52, 179, 122, .18); --hero-b: rgba(14, 122, 79, .10);
  --footer-bg: #12261b; --footer-ink: #ddf0e3;
}
[data-theme="nuit"] {
  --bg: #141a26; --bg2: #1b2334; --surface: #1e2637;
  --ink: #f0e9d8; --muted: #a79c86; --line: #2e3a52;
  --brand: #e8a33d; --brand2: #f5c66b; --on-brand: #241a08;
  --hero-a: rgba(232, 163, 61, .16); --hero-b: rgba(120, 90, 200, .12);
  --footer-bg: #0d1220; --footer-ink: #e9dfc9;
  --shadow: 0 18px 45px -18px rgba(0,0,0,.6); --shadow-s: 0 8px 22px -10px rgba(0,0,0,.55);
}
[data-theme="sombre"] {
  --bg: #191410; --bg2: #221b15; --surface: #251e17;
  --ink: #f3e7d3; --muted: #ab987e; --line: #3a2f24;
  --brand: #e07b39; --brand2: #f2a65e; --on-brand: #231305;
  --hero-a: rgba(224, 123, 57, .16); --hero-b: rgba(150, 70, 30, .12);
  --footer-bg: #100c08; --footer-ink: #ecdfc8;
  --shadow: 0 18px 45px -18px rgba(0,0,0,.6); --shadow-s: 0 8px 22px -10px rgba(0,0,0,.55);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); background: var(--bg); color: var(--ink);
  line-height: 1.65; transition: background var(--tr), color var(--tr); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.02em; margin: 0 0 .6em; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); } .small { font-size: .85rem; }
main.wrap { padding-top: 12px; padding-bottom: 40px; min-height: 60vh; }

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand);
  border: 0; border-radius: 999px; padding: .8em 1.7em; font-weight: 700; font-size: 1rem;
  cursor: pointer; box-shadow: var(--shadow-s); transition: transform var(--tr), box-shadow var(--tr), filter var(--tr);
  text-decoration: none !important; }
.btn:hover { transform: translateY(-2px); filter: brightness(1.05); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }
.btn-small { padding: .5em 1.1em; font-size: .88rem; }
.btn-light { background: var(--on-brand); color: var(--brand); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); box-shadow: none; }
.btn-ghost:hover { border-color: var(--brand); }
.btn-danger { background: linear-gradient(135deg, #b3372a, #d95f4b); color: #fff; }
.btn-ok { background: linear-gradient(135deg, #1e7a4c, #35a56c); color: #fff; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 20px; padding-top: 12px; padding-bottom: 12px; }
.logo { font-size: 1.35rem; font-weight: 800; letter-spacing: -.02em; color: var(--ink); text-decoration: none !important; }
.logo span { background: linear-gradient(135deg, var(--brand), var(--brand2));
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.site-nav { display: flex; gap: 4px; margin-left: 8px; }
.site-nav a { color: var(--muted); font-weight: 600; font-size: .95rem; padding: .5em .9em;
  border-radius: 999px; text-decoration: none !important; transition: all var(--tr); }
.site-nav a:hover { color: var(--ink); background: var(--bg2); }
.site-nav a.active { color: var(--on-brand); background: linear-gradient(135deg, var(--brand), var(--brand2)); }
.header-tools { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.tool { display: flex; align-items: center; gap: 8px; font-size: .82rem; color: var(--muted); }
.tool-label { font-weight: 600; }
.lang-links { display: flex; gap: 2px; background: var(--bg2); border-radius: 999px; padding: 3px; }
.lang-links a { padding: .3em .7em; border-radius: 999px; font-weight: 700; font-size: .78rem;
  color: var(--muted); text-decoration: none !important; }
.lang-links a.active { background: var(--surface); color: var(--brand); box-shadow: var(--shadow-s); }
.theme-select { font: inherit; font-size: .82rem; font-weight: 600; color: var(--ink);
  background: var(--bg2); border: 1px solid var(--line); border-radius: 999px; padding: .4em .8em; cursor: pointer; }
.nav-toggle { display: none; } .nav-burger { display: none; font-size: 1.5rem; cursor: pointer; color: var(--ink); }

/* Hero */
.hero { position: relative; overflow: hidden; border-radius: calc(var(--radius) * 1.4);
  margin: 26px 0 10px; padding: clamp(48px, 7vw, 96px) clamp(24px, 5vw, 72px);
  background: radial-gradient(700px 340px at 12% 8%, var(--hero-a), transparent 65%),
              radial-gradient(620px 380px at 88% 90%, var(--hero-b), transparent 60%), var(--surface);
  border: 1px solid var(--line); box-shadow: var(--shadow); text-align: center; }
.hero-badge { display: inline-flex; align-items: center; gap: .5em; font-size: .8rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; color: var(--brand); background: var(--bg2);
  border: 1px solid var(--line); padding: .55em 1.2em; border-radius: 999px; margin-bottom: 22px; }
.hero-badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand2)); }
.hero-title { font-size: clamp(1.7rem, 4.6vw, 3.4rem); font-weight: 800; max-width: 20em; margin: 0 auto .5em; text-wrap: balance; }
.hero-title .hl { background: linear-gradient(120deg, var(--brand), var(--brand2));
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-sub { max-width: 44em; margin: 0 auto 30px; color: var(--muted); font-size: 1.08rem; }
.hero-ctas { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* Stats */
.stats-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 26px 0 8px; }
.stat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 12px; text-align: center; box-shadow: var(--shadow-s); transition: transform var(--tr); }
.stat-card:hover { transform: translateY(-3px); }
.stat-card b { display: block; font-size: 2rem; font-weight: 800; letter-spacing: -.02em;
  background: linear-gradient(135deg, var(--brand), var(--brand2));
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat-card span { font-size: .85rem; color: var(--muted); font-weight: 600; }

/* Sections */
.section { padding: 44px 0 8px; }
.eyebrow { display: inline-block; font-size: .78rem; font-weight: 800; letter-spacing: .14em;
  text-transform: uppercase; color: var(--brand); margin-bottom: 10px; }
.sec-title { font-size: clamp(1.5rem, 3vw, 2.2rem); font-weight: 800; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 24px; flex-wrap: wrap; }
.section-head p { margin: 6px 0 0; }

/* Cartes */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 22px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow-s);
  transition: transform var(--tr), box-shadow var(--tr); }
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.card-media { display: block; background: var(--bg2); overflow: hidden; }
.card-media-book { aspect-ratio: 3/4; } .card-media-app { aspect-ratio: 1/1; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card-media img { transform: scale(1.04); }
.card-ph { display: flex; align-items: center; justify-content: center; height: 100%; min-height: 220px;
  background: linear-gradient(135deg, var(--brand), var(--brand2)); }
.card-ph span { font-size: 4rem; font-weight: 800; color: var(--on-brand); }
.card-body { padding: 20px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.tag { font-size: .72rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  background: var(--bg2); color: var(--muted); border: 1px solid var(--line); padding: .35em .8em; border-radius: 999px; }
.tag-type { background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand); border: 0; }
.tag-update { background: #1e7a4c; color: #fff; border: 0; }
.tag-off { background: #6b6259; color: #fff; border: 0; }
.card-title { font-size: 1.12rem; margin: 0; }
.card-title a { color: var(--ink); text-decoration: none !important; }
.card-title a:hover { color: var(--brand); }
.card-desc { color: var(--muted); font-size: .93rem; margin: 0; flex: 1; }
.card-body .btn { align-self: flex-start; margin-top: 6px; }

/* Bandeau LeVent */
.band { position: relative; overflow: hidden; border-radius: calc(var(--radius) * 1.4);
  margin: 48px 0 8px; padding: clamp(44px, 6vw, 80px) clamp(24px, 5vw, 64px);
  background: linear-gradient(130deg, var(--brand) 0%, var(--brand2) 100%);
  color: var(--on-brand); text-align: center; box-shadow: var(--shadow); }
.band::before { content: ""; position: absolute; inset: 0; opacity: .14;
  background: radial-gradient(500px 260px at 15% 20%, #fff, transparent 60%),
              radial-gradient(500px 300px at 85% 80%, #000, transparent 65%); }
.band > * { position: relative; }
.band h2 { font-size: clamp(1.6rem, 3.4vw, 2.5rem); font-weight: 800; }
.band p { max-width: 46em; margin: 0 auto 28px; opacity: .94; font-size: 1.05rem; }

/* Pages */
.page-head { padding: 34px 0 6px; }
.page-head h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 800; }
.filters { display: flex; gap: 8px; margin: 18px 0 26px; flex-wrap: wrap; }
.filters a { padding: .55em 1.2em; border-radius: 999px; font-weight: 700; font-size: .9rem;
  color: var(--muted); background: var(--surface); border: 1px solid var(--line);
  text-decoration: none !important; transition: all var(--tr); }
.filters a:hover { color: var(--ink); border-color: var(--brand); }
.filters a.active { color: var(--on-brand); background: linear-gradient(135deg, var(--brand), var(--brand2)); border: 0; }
.product-detail { display: grid; grid-template-columns: minmax(280px, 400px) 1fr;
  gap: clamp(24px, 4vw, 56px); padding: 34px 0; align-items: start; }
.detail-media { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line);
  box-shadow: var(--shadow); background: var(--surface); position: sticky; top: 96px; }
.detail-media img { width: 100%; height: auto; }
.card-ph-big { min-height: 420px; }
.detail-body h1 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); font-weight: 800; margin: .4em 0 .5em; }
.detail-desc { font-size: 1.05rem; color: var(--muted); max-width: 44em; }
.links-title { font-size: 1.1rem; margin: 28px 0 12px; }
.links-list { display: flex; gap: 12px; flex-wrap: wrap; }
.back-link { display: inline-block; margin-bottom: 6px; font-weight: 600; font-size: .92rem; }

/* Footer */
.site-footer { background: var(--footer-bg); color: var(--footer-ink); margin-top: 56px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; padding: 52px 0 36px; }
.footer-brand .logo { color: var(--footer-ink); font-size: 1.5rem; }
.footer-brand p { opacity: .75; font-size: .94rem; max-width: 30em; }
.footer-col h4 { font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; opacity: .6; margin: 0 0 14px; }
.footer-col a { display: block; color: var(--footer-ink); opacity: .85; padding: .3em 0; font-size: .95rem; text-decoration: none !important; }
.footer-col a:hover { opacity: 1; color: var(--brand2); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding: 18px 0;
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: .85rem; opacity: .7; }

/* Légal / divers */
.legal { max-width: 760px; padding: 30px 0; } .legal h1 { font-size: 2rem; }
.legal h2 { margin-top: 1.8em; font-size: 1.25rem; }
.lead { font-size: 1.1rem; color: var(--muted); }
.maintenance, .notfound { text-align: center; padding: 80px 20px; }
.maintenance h1, .notfound h1 { font-size: 2.2rem; }

/* Formulaires */
.form { max-width: 640px; display: grid; gap: 16px; padding: 10px 0 30px; }
.form-row { display: grid; gap: 6px; } .form-row label { font-weight: 700; font-size: .92rem; }
.form-row input[type="text"], .form-row input[type="password"], .form-row input[type="number"],
.form-row textarea, .form-row select { font: inherit; padding: .7em .9em; border-radius: var(--radius-s);
  border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); width: 100%; }
.form-row textarea { min-height: 110px; resize: vertical; }
.form-row input:focus, .form-row textarea:focus, .form-row select:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--hero-a); }
.form-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.auth { max-width: 420px; margin: 60px auto; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 36px; box-shadow: var(--shadow); text-align: center; }
.auth h1 { font-size: 1.5rem; }
.check-row { display: flex; align-items: center; gap: 10px; }
.check-row input { width: 1.1em; height: 1.1em; accent-color: var(--brand); }
.ai-box { background: var(--bg2); border: 1px dashed var(--line); border-radius: var(--radius-s); padding: 16px; display: grid; gap: 10px; }

/* Admin */
.dash-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; margin: 22px 0; box-shadow: var(--shadow-s); }
.dash-panel h2 { font-size: 1.25rem; margin-bottom: 16px; }
.contact-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
@media (max-width: 760px) { .contact-grid { grid-template-columns: 1fr; } }
.dash-actions { display: flex; gap: 10px; }
.inline-form { display: inline; }
.status-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.status-badge { font-weight: 800; font-size: .85rem; letter-spacing: .06em; text-transform: uppercase;
  padding: .55em 1.1em; border-radius: 999px; }
.status-badge.on { background: #1e7a4c; color: #fff; } .status-badge.off { background: #b3372a; color: #fff; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.stat { background: var(--bg2); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 18px 14px; text-align: center; }
.stat-num { display: block; font-size: 1.9rem; font-weight: 800; color: var(--brand); }
.stat-label { font-size: .82rem; color: var(--muted); font-weight: 600; }
.stats-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 18px; }
.stats-detail h3 { font-size: .95rem; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.mini-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: .9rem; }
.mini-list li { background: var(--bg2); border-radius: 8px; padding: 8px 12px; }
.table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.admin-table th, .admin-table td { padding: 12px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.admin-table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.admin-table tr.row-off td { opacity: .55; }
.row-actions { display: flex; gap: 8px; white-space: nowrap; }
.cred-group { display: grid; gap: 12px; margin-bottom: 22px; } .cred-group > h3 { margin: 0; font-size: 1.05rem; }
.logo-line { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 1.1rem; margin-bottom: 18px; }
.nowrap { white-space: nowrap; }

/* Panel live */
.live-panel { border-color: var(--brand); }
.live-head { display: flex; align-items: center; gap: 12px; }
.live-badge { display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 800;
  letter-spacing: .14em; color: #22a35c; text-transform: uppercase; }
.live-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 16px; }
.live-chart { background: var(--bg2); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 16px; }
.live-chart h3 { font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 0 0 10px; }
.live-chart svg { width: 100%; height: auto; display: block; }
.live-dot { width: 11px; height: 11px; border-radius: 50%; background: #22a35c; position: relative; }
.live-dot::after { content: ""; position: absolute; inset: -5px; border-radius: 50%;
  border: 2px solid #22a35c; opacity: .6; animation: ping 1.6s ease-out infinite; }
@keyframes ping { 0% { transform: scale(.5); opacity: .8; } 100% { transform: scale(1.4); opacity: 0; } }
.live-label { font-size: .78rem; font-weight: 800; letter-spacing: .14em; color: #22a35c; }
.charts { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 16px; }
.chart-box { background: var(--bg2); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 16px; }
.chart-box h3 { font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 0 0 10px; }
.chart-box svg { width: 100%; height: auto; display: block; }
.activity-feed { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; max-height: 260px; overflow: auto; }
.activity-feed li { display: flex; gap: 10px; align-items: baseline; background: var(--bg2); border-radius: 8px; padding: 8px 12px; font-size: .88rem; }
.activity-feed time { color: var(--muted); font-size: .78rem; white-space: nowrap; }
.pill { font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; padding: .25em .7em; border-radius: 999px; }
.pill-visit { background: #dbeafe; color: #1d4ed8; } .pill-click { background: #fef3c7; color: #b45309; }
[data-theme="nuit"] .pill-visit, [data-theme="sombre"] .pill-visit { background: #1e3a5f; color: #9cc3ff; }
[data-theme="nuit"] .pill-click, [data-theme="sombre"] .pill-click { background: #4a3413; color: #f5c66b; }

/* Reveal */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

@media (max-width: 900px) {
  .stats-strip { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .product-detail { grid-template-columns: 1fr; }
  .detail-media { position: static; max-width: 420px; }
  .charts, .stats-detail { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .nav-burger { display: block; }
  .site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--surface);
    border-bottom: 1px solid var(--line); flex-direction: column; padding: 12px 24px 18px; gap: 2px; }
  .nav-toggle:checked ~ .site-nav { display: flex; }
  .header-tools { gap: 8px; } .tool-label { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-ctas .btn { width: 100%; }
}

/* Newsletter + recherche catalogue */
.footer-newsletter .newsletter-form { display:flex; gap:8px; flex-wrap:wrap; margin-top:10px; }
.footer-newsletter .newsletter-form input[type=email] { flex:1 1 180px; }
.catalogue-search { display:flex; gap:8px; margin:0 0 18px; max-width:560px; }
.catalogue-search input[type=search] { flex:1; }

/* « Ajouter » universel + vidéos */
.btn-big { padding: .95em 2em; font-size: 1.05rem; }
.add-form { max-width: 760px; }
.dropzone { position: relative; display: flex; align-items: center; justify-content: center; text-align: center;
  min-height: 200px; margin-top: 16px; padding: 22px; border: 2px dashed var(--line); border-radius: var(--radius);
  background: var(--bg2); cursor: pointer; transition: border-color var(--tr), background var(--tr); }
.dropzone:hover, .dropzone.is-over { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 6%, var(--bg2)); }
.dropzone input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.dropzone img { max-height: 260px; width: auto; border-radius: var(--radius-s); box-shadow: var(--shadow-s); }
.add-options summary { cursor: pointer; font-weight: 700; }
.add-options[open] summary { margin-bottom: 14px; }
.card-media { position: relative; }
.card-media-video { aspect-ratio: 16/9; }
.play-badge { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 62px; height: 62px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  padding-left: 4px; font-size: 1.4rem; color: #fff; background: rgba(0, 0, 0, .55);
  backdrop-filter: blur(4px); box-shadow: 0 6px 20px rgba(0, 0, 0, .35); transition: transform var(--tr); }
.card:hover .play-badge { transform: translate(-50%, -50%) scale(1.1); }
.detail-media-video { aspect-ratio: 16/9; position: static; }
.detail-media-video iframe { width: 100%; height: 100%; border: 0; display: block; }
.product-detail:has(.detail-media-video) { grid-template-columns: 1fr; }

/* ============================================================
   Refonte « pro » v3 — typographie, en-tête, hero, cartes, formulaires
   ============================================================ */
:root { --font: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; --radius: 16px; }
body { font-size: 1rem; letter-spacing: -.005em; }
h1, h2, h3 { letter-spacing: -.025em; }
html { overflow-x: hidden; }

/* En-tête : une ligne nette, sans débordement */
.header-inner { gap: 24px; padding-top: 14px; padding-bottom: 14px; }
.logo { display: inline-flex; align-items: center; gap: 10px; white-space: nowrap; font-size: 1.2rem; flex-shrink: 0; }
.logo img { width: 30px; height: 30px; border-radius: 8px; box-shadow: var(--shadow-s); }
.site-nav { gap: 2px; margin-left: 12px; }
.site-nav a { white-space: nowrap; font-size: .93rem; padding: .5em .95em; }
.site-nav a.active { color: var(--brand); background: color-mix(in srgb, var(--brand) 10%, transparent); }
.header-tools { flex-shrink: 0; }
.theme-select { max-width: 150px; }

/* Hero en deux colonnes avec vitrine de couvertures */
.hero { text-align: left; margin-top: 28px; }
.hero-split { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(28px, 4vw, 64px); align-items: center; }
.hero-title { margin: 0 0 .45em; max-width: 14em; font-size: clamp(2rem, 4.4vw, 3.5rem); line-height: 1.08; }
.hero-tagline { font-size: .74rem; font-weight: 700; letter-spacing: .12em; color: var(--muted); margin: 0 0 18px; max-width: 46em; }
.hero-sub { margin: 0 0 30px; max-width: 36em; font-size: 1.08rem; }
.hero-ctas { justify-content: flex-start; }
.hero:not(.hero-split) { text-align: center; }
.hero:not(.hero-split) .hero-title, .hero:not(.hero-split) .hero-sub { margin-left: auto; margin-right: auto; }
.hero:not(.hero-split) .hero-ctas { justify-content: center; }
.hero-showcase { position: relative; height: clamp(300px, 34vw, 420px); }
.showcase-item { position: absolute; top: 50%; left: 50%; width: 46%; aspect-ratio: 3/4; border-radius: 14px; overflow: hidden;
  background: var(--bg2); box-shadow: 0 30px 60px -20px rgba(30, 15, 0, .45), 0 0 0 1px rgba(255,255,255,.4) inset;
  transition: transform .5s cubic-bezier(.2,.8,.2,1); }
.showcase-item img { width: 100%; height: 100%; object-fit: cover; }
.showcase-1 { transform: translate(-50%, -50%) rotate(0deg); z-index: 3; }
.showcase-2 { transform: translate(-108%, -46%) rotate(-9deg); z-index: 2; }
.showcase-3 { transform: translate(8%, -46%) rotate(9deg); z-index: 1; }
.hero-showcase:hover .showcase-2 { transform: translate(-118%, -48%) rotate(-12deg); }
.hero-showcase:hover .showcase-3 { transform: translate(18%, -48%) rotate(12deg); }

/* Statistiques */
.stat-card { padding: 22px 12px; }
.stat-card b { font-size: 2.1rem; }

/* Cartes : visuel uniforme (couverture entière sur fond flouté) */
.grid { gap: 26px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.card { border-radius: var(--radius); }
.card-media, .card-media-book, .card-media-app, .card-media-video { aspect-ratio: 4/5; position: relative; isolation: isolate; }
.card-media .card-bg { position: absolute; inset: -20px; width: calc(100% + 40px); height: calc(100% + 40px); max-width: none;
  object-fit: cover; filter: blur(22px) saturate(1.2); opacity: .55; z-index: -1; transform: none !important; }
.card-media .card-img { width: 100%; height: 100%; object-fit: contain; padding: 18px;
  filter: drop-shadow(0 14px 22px rgba(0, 0, 0, .28)); }
.card-media-video .card-img { padding: 0; object-fit: cover; filter: none; }
.card:hover .card-media .card-img { transform: scale(1.035); }
.card-body { padding: 18px 20px 20px; gap: 8px; }
.card-title { font-size: 1.06rem; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-desc { font-size: .9rem; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; flex: 0 1 auto; }
.card-body .btn { margin-top: auto; align-self: stretch; background: transparent; color: var(--brand); box-shadow: none;
  border: 1.5px solid color-mix(in srgb, var(--brand) 35%, var(--line)); }
.card-body .btn:hover { background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand); border-color: transparent; }
.tag { font-size: .68rem; padding: .32em .75em; }

/* Fiche produit */
.detail-media img { aspect-ratio: auto; }
.links-list .btn { min-width: 140px; }

/* Champs de formulaire : un seul style partout */
main input[type=text], main input[type=email], main input[type=search], main input[type=password],
main input[type=url], main input[type=number], main textarea, main select:not(.theme-select) {
  font: inherit; font-size: .97rem; width: 100%; padding: .75em 1em; border-radius: var(--radius-s);
  border: 1.5px solid var(--line); background: var(--surface); color: var(--ink);
  transition: border-color var(--tr), box-shadow var(--tr); }
main input:focus, main textarea:focus, main select:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px var(--hero-a); }
.form > label, .form .form-row > label, .add-options label { display: grid; gap: 6px; font-weight: 700; font-size: .9rem; }
.form-row { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.catalogue-search { max-width: 620px; }
.catalogue-search input[type=search] { border-radius: 999px; padding-left: 1.3em; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 55%, transparent); outline-offset: 2px; }

/* Pied de page */
.footer-grid { padding-top: 56px; }

/* Responsive */
@media (max-width: 1060px) {
  .nav-burger { display: block; order: 3; }
  .site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; margin: 0; background: var(--surface);
    border-bottom: 1px solid var(--line); flex-direction: column; padding: 12px 24px 18px; gap: 2px; box-shadow: var(--shadow); }
  .nav-toggle:checked ~ .site-nav { display: flex; }
  .header-tools { margin-left: auto; }
}
@media (max-width: 900px) {
  .hero-split { grid-template-columns: 1fr; }
  .hero-showcase { height: 300px; order: -1; }
}
@media (max-width: 600px) {
  .wrap { padding: 0 16px; }
  .tool-label { display: none; }
  .theme-select { max-width: 170px; }
  .hero { padding: 36px 20px; }
  .hero-showcase { height: 240px; }
  .stats-strip { grid-template-columns: repeat(2, 1fr); }
  .grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  .card-body { padding: 14px; }
  .card-desc { -webkit-line-clamp: 2; }
}
@media (max-width: 420px) {
  .grid { grid-template-columns: 1fr; }
  .logo { font-size: 1.05rem; }
}
@media (max-width: 600px) {
  .header-inner { flex-wrap: wrap; row-gap: 10px; }
  .nav-burger { margin-left: auto; }
  .header-tools { order: 4; width: 100%; margin-left: 0; justify-content: space-between; }
}

/* Vidéos hébergées sur le site */
.detail-media-file { background: #000; display: flex; justify-content: center; }
.detail-media-file video { width: 100%; max-height: 78vh; display: block; background: #000; }
.detail-video video { width: 100%; max-width: 960px; max-height: 80vh; border-radius: var(--radius); background: #000; box-shadow: var(--shadow); display: block; }
.detail-cta { margin-top: 22px; }
.card-media-video .card-img { padding: 0; object-fit: contain; filter: none; }
.video-pick { margin-top: 14px; display: grid; gap: 6px; font-weight: 700; font-size: .9rem; }
.publisher-card { display: flex; align-items: center; gap: 18px; }
.publisher-card img { width: 84px; height: 84px; border-radius: 14px; background: #fff; box-shadow: var(--shadow-s); }
.band-logo { width: 96px; height: 96px; border-radius: 20px; margin: 0 auto 18px; box-shadow: 0 12px 30px rgba(0,0,0,.25); }
.band-mail { margin: 18px auto 0 !important; font-weight: 700; }
.band-mail a { color: var(--on-brand); text-decoration: underline; }

/* Admin : bouton « Ajouter / Enlever » et gestion des publications */
.admin-fab { position: fixed; right: 20px; bottom: 20px; z-index: 90; display: flex; border-radius: 999px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .28); overflow: hidden; }
.admin-fab-main, .admin-fab-side { font: inherit; font-weight: 800; border: 0; cursor: pointer; padding: .9em 1.4em; text-decoration: none !important; }
.admin-fab-main { background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand); font-size: 1rem; }
.admin-fab-side { background: var(--ink); color: var(--bg); font-size: .85rem; display: flex; align-items: center; }
.admin-fab-main:hover, .admin-fab-side:hover { filter: brightness(1.08); }
.upload-overlay { position: fixed; inset: 0; z-index: 120; background: rgba(0, 0, 0, .55); display: flex; align-items: center; justify-content: center; padding: 16px; }
.upload-overlay[hidden] { display: none; }
.upload-box { background: var(--surface); color: var(--ink); border-radius: var(--radius); padding: 26px 28px; width: min(460px, 100%); box-shadow: var(--shadow); }
.upload-bar { height: 10px; border-radius: 999px; background: var(--bg2); overflow: hidden; margin: 14px 0 8px; }
.upload-bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--brand), var(--brand2)); transition: width .2s; }
body.drop-ready::after { content: "Dépose tes fichiers pour les publier"; position: fixed; inset: 12px; z-index: 110; border: 4px dashed var(--brand);
  border-radius: 24px; background: color-mix(in srgb, var(--bg) 80%, transparent); display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem; font-weight: 800; color: var(--brand); pointer-events: none; }
.card { position: relative; }
.card-admin { position: absolute; top: 10px; left: 10px; right: 10px; z-index: 5; display: flex; justify-content: space-between; gap: 6px; }
.card-admin-btn { font: inherit; font-size: .75rem; font-weight: 800; border: 0; border-radius: 999px; padding: .45em .85em; cursor: pointer;
  background: rgba(255, 255, 255, .92); color: #222; box-shadow: 0 4px 12px rgba(0, 0, 0, .2); }
.card-admin-del { background: #b3372a; color: #fff; }
.card-hidden .card-media, .card-hidden .card-body { opacity: .45; }
.card-hidden::after { content: "MASQUÉE"; position: absolute; top: 52px; left: 10px; z-index: 5; font-size: .7rem; font-weight: 800;
  letter-spacing: .1em; background: #6b6259; color: #fff; padding: .3em .7em; border-radius: 999px; }
.files-drop { text-align: center; border: 2px dashed var(--line); }
.files-list { display: grid; gap: 10px; }
.files-row { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-s); background: var(--bg); }
.files-row.is-hidden { opacity: .6; }
.files-thumb { width: 64px; height: 64px; border-radius: 10px; overflow: hidden; background: var(--bg2); display: flex; align-items: center; justify-content: center; font-size: 1.6rem; text-decoration: none !important; }
.files-thumb img { width: 100%; height: 100%; object-fit: cover; }
.files-info { display: grid; gap: 2px; min-width: 0; }
.files-info strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.files-actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 640px) {
  .files-row { grid-template-columns: 52px 1fr; }
  .files-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .admin-fab { right: 12px; bottom: 12px; }
  .admin-fab-main { padding: .8em 1.1em; font-size: .9rem; }
}

/* Bouton Admin de l'en-tête */
.admin-link { order: -1; white-space: nowrap; font-size: .82rem; font-weight: 800; padding: .45em .95em; border-radius: 999px;
  border: 1.5px solid var(--line); color: var(--ink); background: var(--surface); text-decoration: none !important; transition: all var(--tr); }
.admin-link:hover { border-color: var(--brand); color: var(--brand); }
.admin-link.is-on { background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand); border-color: transparent; }

/* Aperçu du rapport quotidien */
.report-preview { border: 1px solid var(--line); border-radius: var(--radius-s); padding: 12px; background: #fff; color: #2b2118; overflow-x: auto; }
.report-short { white-space: pre-wrap; background: var(--bg2); border-radius: var(--radius-s); padding: 14px; font-size: .9rem; }

/* Assistant IA des visiteurs */
.chat-widget { position: fixed; left: 20px; bottom: 20px; z-index: 95; font-size: .95rem; }
.chat-toggle { font: inherit; font-weight: 800; border: 0; cursor: pointer; border-radius: 999px; padding: .85em 1.3em;
  background: var(--ink); color: var(--bg); box-shadow: 0 14px 34px rgba(0, 0, 0, .28); display: flex; gap: .5em; align-items: center; }
.chat-toggle:hover { filter: brightness(1.15); }
.chat-widget.is-open .chat-toggle { display: none; }
.chat-panel { width: min(380px, calc(100vw - 32px)); height: min(560px, calc(100vh - 120px)); display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 24px 60px rgba(0, 0, 0, .3); overflow: hidden; }
.chat-panel[hidden] { display: none; }
.chat-head { display: flex; gap: 10px; align-items: center; padding: 14px 16px; background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand); }
.chat-head img { border-radius: 10px; background: #fff; }
.chat-head span { font-size: .78rem; opacity: .9; }
.chat-close { margin-left: auto; background: transparent; border: 0; color: inherit; font-size: 1.1rem; cursor: pointer; }
.chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; background: var(--bg); }
.chat-msg { max-width: 86%; padding: .65em .9em; border-radius: 14px; line-height: 1.5; word-wrap: break-word; }
.chat-msg.bot { background: var(--surface); border: 1px solid var(--line); align-self: flex-start; border-bottom-left-radius: 4px; }
.chat-msg.user { background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand); align-self: flex-end; border-bottom-right-radius: 4px; }
.chat-msg.typing { opacity: .65; font-style: italic; }
.chat-msg a { font-weight: 700; }
.chat-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }
.chat-form input { flex: 1; font: inherit; padding: .65em .9em; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); }
.chat-note { margin: 0; padding: 0 12px 10px; font-size: .7rem; color: var(--muted); text-align: center; }
@media (max-width: 640px) {
  .chat-widget { left: 12px; bottom: 12px; }
  .chat-toggle span { display: none; }
  .chat-panel { height: calc(100vh - 90px); }
}
.conv { border: 1px solid var(--line); border-radius: var(--radius-s); padding: 10px 14px; margin-bottom: 10px; background: var(--bg); }
.conv summary { cursor: pointer; }
.conv-log { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }

.dash-actions { flex-wrap: wrap; }

/* Avertissement : ebooks non remboursables */
.no-refund { margin: 10px 0 14px; padding: .7em 1em; border-radius: var(--radius-s); font-size: .9rem; line-height: 1.5;
  background: color-mix(in srgb, #e8932f 12%, var(--surface)); border: 1px solid color-mix(in srgb, #e8932f 45%, var(--line)); color: var(--ink); }
.no-refund a { font-weight: 700; }

/* Chat : copie, flèche bas, trombone */
.chat-body { position: relative; flex: 1; min-height: 0; display: flex; }
.chat-body .chat-log { flex: 1; }
.chat-msg { position: relative; user-select: text; }
.chat-msg .chat-text { padding-right: 18px; }
.chat-copy { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 6px; border: 1px solid var(--line);
  background: var(--surface); color: var(--muted); font-size: .75rem; line-height: 1; cursor: pointer; opacity: .55; transition: opacity var(--tr); }
.chat-msg:hover .chat-copy, .chat-copy:focus { opacity: 1; }
.chat-msg.user .chat-copy { background: rgba(255, 255, 255, .25); border-color: transparent; color: var(--on-brand); }
.chat-msg.typing .chat-copy { display: none; }
.chat-down { position: absolute; right: 14px; bottom: 12px; width: 38px; height: 38px; border-radius: 50%; border: 0; cursor: pointer;
  font-size: 1.15rem; font-weight: 800; color: var(--on-brand); background: linear-gradient(135deg, var(--brand), var(--brand2));
  box-shadow: 0 6px 16px rgba(0, 0, 0, .25); }
.chat-down[hidden] { display: none; }
.chat-head-btn { background: rgba(255, 255, 255, .2); border: 0; color: inherit; width: 30px; height: 30px; border-radius: 8px; cursor: pointer; margin-left: auto; }
.chat-head-btn + .chat-close { margin-left: 4px; }
.chat-files { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 10px 0; }
.chat-files[hidden] { display: none; }
.chat-chip { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; background: var(--bg2); border: 1px solid var(--line);
  border-radius: 999px; padding: .25em .4em .25em .7em; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-chip button { border: 0; background: transparent; cursor: pointer; color: var(--muted); }
.chat-clip { border: 0; background: transparent; font-size: 1.2rem; cursor: pointer; padding: 0 2px; }
.chat-form { align-items: flex-end; }
.chat-form textarea { flex: 1; font: inherit; padding: .6em .9em; border-radius: 18px; border: 1.5px solid var(--line); background: var(--surface);
  color: var(--ink); resize: none; max-height: 120px; line-height: 1.4; }
.chat-panel.drop { outline: 3px dashed var(--brand); outline-offset: -6px; }

/* Connexion Google facultative */
.login-link { cursor: pointer; font: inherit; font-size: .82rem; font-weight: 800; }
.visitor-chip { display: inline-flex; align-items: center; gap: 6px; font-size: .82rem; font-weight: 700; white-space: nowrap; }
.visitor-chip img { border-radius: 50%; }
.visitor-logout { font: inherit; font-size: .75rem; border: 0; background: transparent; color: var(--muted); cursor: pointer; text-decoration: underline; }
.auth-modal { position: fixed; inset: 0; z-index: 130; background: rgba(0, 0, 0, .5); display: flex; align-items: center; justify-content: center; padding: 16px; }
.auth-modal[hidden] { display: none; }
.auth-box { position: relative; width: min(420px, 100%); background: var(--surface); border-radius: 22px; padding: 30px 26px 22px; text-align: center; box-shadow: 0 30px 70px rgba(0, 0, 0, .35); }
.auth-logo { border-radius: 16px; margin: 0 auto 10px; }
.auth-box h2 { margin: 0 0 8px; }
.auth-x { position: absolute; top: 12px; right: 14px; border: 0; background: transparent; font-size: 1.1rem; cursor: pointer; color: var(--muted); }
.auth-consent { text-align: left; font-size: .85rem; margin: 14px 0; align-items: flex-start; }
.google-btn { display: flex; justify-content: center; min-height: 44px; margin: 6px 0 10px; }
.auth-anon { width: 100%; margin-bottom: 8px; }

/* Liste des modèles IA cliquables */
.model-list { display: flex; flex-wrap: wrap; gap: 8px; }
.model-pill { font: inherit; font-size: .82rem; font-family: ui-monospace, Consolas, monospace; padding: .4em .8em; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--bg); color: var(--ink); cursor: pointer; }
.model-pill:hover { border-color: var(--brand); color: var(--brand); }
.model-pill.is-current { background: linear-gradient(135deg, var(--brand), var(--brand2)); color: var(--on-brand); border-color: transparent; }
.model-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 4px 0; border-bottom: 1px dashed var(--line); }
.model-row.ok .model-pill { border-color: #1e7a4c; color: #1e7a4c; }
.model-row.ko .model-pill { opacity: .6; cursor: default; }
#ai-test-result { white-space: pre-line; }
.chat-sep { text-align: center; font-size: .72rem; color: var(--muted); margin: 4px 0; }

/* Historique d'un visiteur */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.timeline li { display: grid; grid-template-columns: 52px 1fr; gap: 10px; align-items: start; }
.timeline .tl-time { font-family: ui-monospace, Consolas, monospace; font-size: .8rem; color: var(--muted); padding-top: 2px; }
.timeline .chat-msg { max-width: 100%; }
.timeline .tl-click { color: #1e7a4c; font-weight: 700; }

/* Bandeau d'information (cookie d'identification) */
.site-notice { position: fixed; left: 50%; transform: translateX(-50%); bottom: 84px; z-index: 92; width: min(560px, calc(100vw - 24px));
  display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line);
  box-shadow: 0 16px 40px rgba(0, 0, 0, .22); font-size: .85rem; }
.site-notice[hidden] { display: none; }
.site-notice p { margin: 0; flex: 1; line-height: 1.45; }
@media (max-width: 640px) { .site-notice { bottom: 76px; flex-direction: column; align-items: stretch; } }

.promo-products { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 6px 16px; }

/* Promotions : bandeau, badges, encadré, fenêtre d'offre */
.promo-bar { background: linear-gradient(135deg, #b3372a, #e8932f); color: #fff; font-size: .88rem; }
.promo-bar-inner { display: flex; align-items: center; gap: 12px; padding-top: 8px; padding-bottom: 8px; flex-wrap: wrap; }
.promo-bar-tag { background: rgba(255, 255, 255, .22); border-radius: 999px; padding: .15em .7em; font-weight: 800; font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; }
.promo-bar-link { margin-left: auto; color: #fff; font-weight: 800; text-decoration: underline; }
.tag-promo { background: #b3372a; color: #fff; border: 0; }
.promo-box { margin: 12px 0; padding: .8em 1em; border-radius: var(--radius-s); background: color-mix(in srgb, #b3372a 10%, var(--surface));
  border: 1.5px dashed #b3372a; color: var(--ink); line-height: 1.55; }
.promo-code { font-family: ui-monospace, Consolas, monospace; letter-spacing: .05em; }
.lead-modal { position: fixed; inset: 0; z-index: 131; background: rgba(0, 0, 0, .5); display: flex; align-items: center; justify-content: center; padding: 16px; }
.lead-modal[hidden] { display: none; }
.lead-box { position: relative; width: min(420px, 100%); background: var(--surface); border-radius: 22px; padding: 28px 24px 20px; text-align: center; box-shadow: 0 30px 70px rgba(0, 0, 0, .35); }
.lead-box h2 { margin: 0 0 8px; }
.lead-box input[type=email] { width: 100%; font: inherit; padding: .75em 1em; border-radius: 999px; border: 1.5px solid var(--line); background: var(--bg); color: var(--ink); margin: 8px 0 4px; }
.lead-err { color: #b3372a; font-size: .85rem; margin: 4px 0 8px; }
.lead-code { font-size: 1.3rem; font-weight: 800; color: #b3372a; font-family: ui-monospace, Consolas, monospace; }
.chat-offer { width: auto; padding: 0 10px; font-size: .78rem; font-weight: 800; white-space: nowrap; }
@media (max-width: 640px) { .promo-bar-link { margin-left: 0; } }
.chat-offer + .chat-head-btn { margin-left: 4px; }

/* En-tête mobile : les outils passent à la ligne au lieu de déborder */
@media (max-width: 600px) {
  .header-tools { flex-shrink: 1; min-width: 0; flex-wrap: wrap; row-gap: 8px; justify-content: flex-start; }
  .header-tools .tool { min-width: 0; }
  .header-tools .theme-select { max-width: 130px; min-width: 0; }
}
