/* ============================================================
   MMNews — site.css — Charte graphique officielle v2
   Noir #0A0A0A · Rouge #C1272D · Blanc #FFFFFF
   "L'info qui compte. Tout le temps."
   ============================================================ */

/* ── Variables ──────────────────────────────────────────────── */
:root {
  --red:        #C1272D;
  --red-dark:   #9B1F24;
  --red-light:  rgba(193,39,45,.1);
  --black:      #000000;
  --bg:         #0A0A0A;
  --surface:    #111111;
  --surface2:   #1A1A1A;
  --border:     rgba(255,255,255,.08);
  --border2:    rgba(255,255,255,.14);
  --text:       #F5F5F5;
  --text-muted: #888888;
  --text-dim:   #555555;
  --white:      #FFFFFF;

  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body:    'Source Serif 4', Georgia, serif;
  --font-ui:      'Cairo', system-ui, -apple-system, sans-serif;
  --font-ar:      'Amiri', 'Cairo', serif;

  --radius:    4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,.4);
  --shadow-md: 0 8px 32px rgba(0,0,0,.5);

  --header-h: 64px;
  --max-w:    1220px;

  /* Compatibilité templates */
  --dark:     #F5F5F5;
  --green:    #22C55E;
  --gray-50:  #1A1A1A;
  --gray-100: #222222;
  --gray-200: #444444;
  --gray-400: #666666;
  --gray-500: #888888;
  --gray-700: #AAAAAA;
}

/* ── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; padding: 0;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--red); }
img { max-width: 100%; height: auto; display: block; }
p { margin: 0 0 1rem; }
h1,h2,h3,h4,h5,h6 { margin: 0 0 .5rem; line-height: 1.2; }

/* ── Utilitaires ────────────────────────────────────────────── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 16px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.text-muted { color: var(--text-muted); }
.text-red   { color: var(--red); }
[dir="rtl"] { font-family: var(--font-ar), var(--font-body); }
[dir="rtl"] .container { direction: rtl; }

/* ── Breaking news ──────────────────────────────────────────── */
.breaking-bar {
  background: var(--red);
  color: var(--white);
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 700;
  padding: 7px 0;
  overflow: hidden;
}
.breaking-bar .wrap { display: flex; align-items: center; gap: 14px; }
.breaking-label {
  background: var(--white);
  color: var(--red);
  padding: 2px 10px;
  border-radius: 2px;
  font-size: 10px;
  letter-spacing: .6px;
  text-transform: uppercase;
  font-weight: 900;
  flex-shrink: 0;
}
.breaking-ticker { overflow: hidden; flex: 1; white-space: nowrap; }
.breaking-ticker-inner {
  display: inline-block;
  animation: ticker 90s linear infinite;
}
@keyframes ticker { from{transform:translateX(100vw)} to{transform:translateX(-100%)} }
/* RTL : défilement de droite à gauche (arabe) */
[dir="rtl"] .breaking-ticker-inner {
  animation: ticker-rtl 90s linear infinite;
}
@keyframes ticker-rtl { from{transform:translateX(-100vw)} to{transform:translateX(100%)} }

/* ── Header ─────────────────────────────────────────────────── */
.site-header {
  background: var(--black);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 200;
}
.header-top {
  display: flex; align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  gap: 16px;
}

/* Logo MMNews */
.site-logo { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.site-logo img { height: 52px; width: auto; max-width: 160px; object-fit: contain; }
.site-logo-text { display: none; flex-direction: column; }
.site-logo-name {
  font-family: var(--font-ui);
  font-size: 24px; font-weight: 900;
  color: var(--white);
  letter-spacing: -.5px;
  line-height: 1;
}
.site-logo-name em { color: var(--red); font-style: normal; }
.site-logo-tagline {
  font-size: 9px;
  color: var(--text-muted);
  font-family: var(--font-ui);
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-top: 2px;
}

/* Barre recherche */
.header-search { flex: 1; max-width: 360px; position: relative; }
.header-search input {
  width: 100%;
  border: 1px solid var(--border2);
  background: var(--surface);
  color: var(--text);
  padding: 9px 38px 9px 14px;
  border-radius: 6px;
  font-size: 13px;
  font-family: var(--font-ui);
  outline: none;
  transition: border-color .15s;
}
.header-search input::placeholder { color: var(--text-dim); }
.header-search input:focus { border-color: var(--red); background: var(--surface2); }
.header-search button {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  background: none; border: none; cursor: pointer; color: var(--text-muted);
  padding: 4px; font-size: 15px;
}
[dir="rtl"] .header-search input { padding: 9px 14px 9px 38px; }
[dir="rtl"] .header-search button { right: auto; left: 10px; }

/* Actions */
.header-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.lang-switcher  { display: flex; gap: 4px; }
.lang-btn {
  background: none; border: 1px solid var(--border2);
  padding: 5px 9px; border-radius: var(--radius);
  font-size: 12px; font-weight: 700; cursor: pointer;
  color: var(--text-muted); font-family: var(--font-ui);
  transition: .15s;
}
.lang-btn:hover, .lang-btn.active {
  background: var(--red); border-color: var(--red); color: var(--white);
}

/* ── Navigation ─────────────────────────────────────────────── */
.site-nav {
  background: var(--surface);
  border-bottom: 2px solid var(--red);
}
.nav-inner {
  display: flex; align-items: center;
  overflow-x: auto; scrollbar-width: none;
}
.nav-inner::-webkit-scrollbar { display: none; }
.nav-link {
  display: inline-flex; align-items: center;
  padding: 11px 15px;
  color: var(--text-muted);
  font-size: 13px; font-weight: 700;
  font-family: var(--font-ui);
  white-space: nowrap;
  transition: color .15s;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  text-decoration: none;
}
.nav-link:hover, .nav-link.active { color: var(--white); border-bottom-color: var(--red); }
.nav-link.home { color: var(--white); }

/* Burger mobile */
.burger-btn {
  display: none; background: none; border: none;
  color: var(--text); font-size: 22px; cursor: pointer; padding: 4px 8px;
}

/* ══════════════════════════════════════════════════════════
   Section "À la une" — Design professionnel MMNews
   Layout : 1 grand article à gauche + 4 petits à droite
   ══════════════════════════════════════════════════════════ */
.une-section {
  display: grid;
  grid-template-columns: 1.8fr 1fr;
  gap: 3px;
  background: var(--black);
  margin: 20px 0 28px;
  border-radius: 4px;
  overflow: hidden;
}
/* Si pas d'articles secondaires → article principal pleine largeur */
.une-section:not(:has(.une-grid)) {
  grid-template-columns: 1fr;
}

/* Article principal */
.une-main { position: relative; overflow: hidden; background: #111; }
.une-main-link {
  display: block; text-decoration: none;
  position: relative; overflow: hidden;
  height: 520px;
}
.une-main-link img {
  width: 100%; height: 520px; object-fit: cover;
  display: block; vertical-align: bottom;
  transition: transform .5s ease;
}
.une-main-link:hover img { transform: scale(1.03); }

.une-main-overlay {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top,
    rgba(0,0,0,.98) 0%,
    rgba(0,0,0,.75) 40%,
    rgba(0,0,0,.2)  70%,
    transparent     100%
  );
  padding: 40px 22px 22px;
}

.une-cat {
  display: inline-block;
  background: var(--red);
  color: #fff;
  font-family: var(--font-ui);
  font-size: 10px; font-weight: 900;
  padding: 3px 10px;
  border-radius: 2px;
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 10px;
}

.une-title {
  font-family: var(--font-heading);
  font-size: 24px; font-weight: 900;
  color: #fff; line-height: 1.25;
  margin: 0 0 8px;
}
[dir="rtl"] .une-title { font-family: var(--font-ar); font-size: 20px; }

.une-desc {
  font-size: 14px; color: rgba(255,255,255,.72);
  line-height: 1.55; margin: 0 0 12px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.une-meta {
  display: flex; gap: 14px;
  font-family: var(--font-ui); font-size: 12px;
  color: rgba(255,255,255,.55);
}

/* Grille articles secondaires */
.une-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 3px;
}

.une-sub {
  position: relative; overflow: hidden;
  display: block; text-decoration: none;
  background: #111;
}
.une-sub img {
  width: 100%; height: 258px; object-fit: cover;
  display: block; vertical-align: bottom;
  transition: transform .4s ease;
}
.une-sub:hover img { transform: scale(1.06); }

.une-sub-overlay {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top, rgba(0,0,0,.95) 0%, rgba(0,0,0,.4) 60%, transparent 100%);
  padding: 22px 10px 10px;
}
.une-sub-cat {
  display: inline-block;
  font-family: var(--font-ui); font-size: 9px; font-weight: 900;
  color: var(--red); text-transform: uppercase; letter-spacing: .4px;
  margin-bottom: 4px;
}
.une-sub-title {
  font-size: 12px; font-weight: 700; color: #fff;
  line-height: 1.35; margin: 0 0 4px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
[dir="rtl"] .une-sub-title { font-family: var(--font-ar); }
.une-sub-date { font-size: 10px; color: rgba(255,255,255,.45); font-family: var(--font-ui); }

/* Responsive */

/* ── Section Podcast (même style que hv-section) ────────────── */
.pod-main-player {
  background: linear-gradient(135deg,#1a1a1a,#111);
  border-radius: var(--radius-md);
  overflow: hidden;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pod-main-player iframe {
  width: 100%; border: none; display: block;
}
.pod-no-embed {
  text-align: center; padding: 32px 24px; color: var(--white);
}
.pod-ext-btn {
  display: inline-block;
  background: var(--red); color: #fff;
  padding: 10px 24px; border-radius: 4px;
  font-weight: 700; text-decoration: none; font-size: 14px;
}
.pod-ext-btn:hover { opacity: .85; }

@media (max-width: 900px) {
  .une-section { grid-template-columns: 1fr; }
  .une-main-link { height: 320px; }
  .une-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .une-grid { grid-template-columns: 1fr; }
  .une-main-link { height: 260px; }
  .une-title { font-size: 18px; }
}


/* ── Badges ─────────────────────────────────────────────────── */
.badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 2px;
  font-size: 10px; font-weight: 900;
  font-family: var(--font-ui);
  text-transform: uppercase; letter-spacing: .5px;
}
.badge-red   { background: var(--red); color: var(--white); }
.badge-dark  { background: var(--surface2); color: var(--text); border: 1px solid var(--border2); }
.badge-cat   { background: var(--red-light); color: var(--red); border: 1px solid rgba(193,39,45,.25); }
.badge-gold  { background: #b8860b; color: #fff; }

/* ── Hero variant (article-card variante hero) ───────────── */
.hero-overlay-link {
  display: flex; flex-direction: column; justify-content: flex-end;
  position: absolute; inset: 0; padding: 28px 22px 22px;
  text-decoration: none;
  background: linear-gradient(to top, rgba(0,0,0,.9) 0%, rgba(0,0,0,.4) 55%, transparent 100%);
}
.hero-cat-badge {
  display: inline-block; background: var(--red); color: #fff;
  font-family: var(--font-ui); font-size: 10px; font-weight: 900;
  padding: 3px 10px; border-radius: 2px;
  text-transform: uppercase; letter-spacing: .5px;
  margin-bottom: 10px; align-self: flex-start;
}
.hero-headline {
  font-family: var(--font-heading); font-size: 22px; font-weight: 900;
  color: #fff; line-height: 1.25; margin: 0 0 10px;
}
[dir="rtl"] .hero-headline { font-family: var(--font-ar); font-size: 18px; }
.hero-meta-bar {
  display: flex; gap: 12px; flex-wrap: wrap;
  font-family: var(--font-ui); font-size: 12px;
  color: rgba(255,255,255,.7);
}
.hero-date, .hero-views, .hero-comments { display: inline-flex; align-items: center; gap: 4px; }

/* ── Article cards ──────────────────────────────────────────── */
.article-card {
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color .2s, transform .2s;
}
.article-card:hover { border-color: rgba(193,39,45,.45); transform: translateY(-2px); }
.article-card-img { aspect-ratio: 16/9; overflow: hidden; background: var(--surface2); }
.article-card-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .3s;
}
.article-card:hover .article-card-img img { transform: scale(1.04); }
.article-card-body { padding: 14px 16px 16px; flex: 1; display: flex; flex-direction: column; }
.article-card-meta {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 8px; flex-wrap: wrap;
}
.article-card-title {
  font-family: var(--font-heading);
  font-size: 16px; font-weight: 700; line-height: 1.38;
  color: var(--text); margin-bottom: 8px; flex: 1;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
[dir="rtl"] .article-card-title { font-family: var(--font-ar); }
.article-card-title:hover { color: var(--red); }
.article-card-desc {
  font-size: 13px; color: var(--text-muted);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  margin-bottom: 12px;
}
.article-card-footer {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: auto; padding-top: 10px;
  border-top: 1px solid var(--border);
  font-size: 12px; color: var(--text-dim); font-family: var(--font-ui);
}

/* Card horizontale */
.article-card-h {
  display: flex; gap: 12px; padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.article-card-h:last-child { border-bottom: none; }
.article-card-h-img {
  width: 88px; height: 66px; flex-shrink: 0;
  border-radius: var(--radius); overflow: hidden; background: var(--surface2);
}
.article-card-h-img img { width: 100%; height: 100%; object-fit: cover; }
.article-card-h-title {
  font-family: var(--font-heading);
  font-size: 14px; font-weight: 700; line-height: 1.4;
  color: var(--text); margin-bottom: 4px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
[dir="rtl"] .article-card-h-title { font-family: var(--font-ar); }
.article-card-h-title:hover { color: var(--red); }
.article-card-h-meta { font-size: 11px; color: var(--text-dim); font-family: var(--font-ui); }

/* Hero text */
.hero-title {
  font-family: var(--font-heading);
  font-size: 28px; font-weight: 900; line-height: 1.18;
  color: var(--white); margin-bottom: 8px;
}
[dir="rtl"] .hero-title { font-family: var(--font-ar); font-size: 24px; }
.hero-title:hover { text-decoration: underline; text-underline-offset: 3px; }
.hero-meta {
  font-size: 12px; color: rgba(255,255,255,.75);
  font-family: var(--font-ui);
  display: flex; align-items: center; gap: 10px;
}
.hero-side-title {
  font-family: var(--font-heading);
  font-size: 14px; font-weight: 700; line-height: 1.3;
  color: var(--white); margin-bottom: 4px;
}
[dir="rtl"] .hero-side-title { font-family: var(--font-ar); }

/* ── Grilles ─────────────────────────────────────────────────── */
.grid-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 18px; }
.grid-4 { display: grid; grid-template-columns: repeat(4,1fr); gap: 14px; }
.grid-2 { display: grid; grid-template-columns: repeat(2,1fr); gap: 18px; }

/* ── Layout 2 colonnes ──────────────────────────────────────── */
.layout-main { display: grid; grid-template-columns: 1fr 300px; gap: 28px; margin: 28px 0; }
.sidebar { display: flex; flex-direction: column; gap: 20px; }

/* ── Sidebar widgets ─────────────────────────────────────────── */
.widget { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); overflow: hidden; }
.widget-header {
  background: var(--surface2);
  color: var(--white); padding: 10px 16px;
  font-family: var(--font-ui); font-size: 12px; font-weight: 900;
  letter-spacing: .4px; text-transform: uppercase;
  display: flex; align-items: center; gap: 8px;
  border-left: 3px solid var(--red);
}
.widget-body { padding: 12px 16px; }

/* ── Section titres ──────────────────────────────────────────── */
.section-title {
  font-family: var(--font-ui);
  font-size: 13px; font-weight: 900;
  color: var(--white); padding-bottom: 10px;
  border-bottom: 2px solid var(--red);
  margin-bottom: 18px;
  display: flex; align-items: center; gap: 8px;
  text-transform: uppercase; letter-spacing: .5px;
}
.section-title span { color: var(--red); }

/* ── Article détail ──────────────────────────────────────────── */
.article-detail-header { margin-bottom: 24px; }
.article-detail-title {
  font-family: var(--font-heading);
  font-size: 34px; font-weight: 900; line-height: 1.18;
  color: var(--text); margin-bottom: 16px;
}
[dir="rtl"] .article-detail-title { font-family: var(--font-ar); font-size: 28px; }
.article-detail-desc {
  font-size: 19px; color: var(--text-muted);
  font-style: italic; line-height: 1.55; margin-bottom: 16px;
  border-left: 3px solid var(--red); padding-left: 16px;
}
[dir="rtl"] .article-detail-desc { border-left: none; border-right: 3px solid var(--red); padding-left: 0; padding-right: 16px; }
.article-detail-meta {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  padding: 12px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  font-size: 13px; color: var(--text-muted); font-family: var(--font-ui); margin-bottom: 24px;
}
.article-detail-meta strong { color: var(--text); }
.article-hero-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius-md); margin-bottom: 24px; }
.article-content { font-size: 17px; line-height: 1.9; color: var(--text-muted); margin-bottom: 32px; }
.article-content p { margin-bottom: 1.2rem; }
.article-content h2 {
  font-family: var(--font-heading);
  font-size: 22px; font-weight: 700; color: var(--text);
  margin: 2rem 0 1rem; padding-bottom: .5rem;
  border-bottom: 1px solid var(--border);
}
.article-content blockquote {
  border-left: 3px solid var(--red);
  margin: 1.5rem 0; padding: .5rem 1rem;
  color: var(--text-muted); font-style: italic;
  background: var(--surface); border-radius: 0 var(--radius) var(--radius) 0;
}
[dir="rtl"] .article-content blockquote {
  border-left: none; border-right: 3px solid var(--red);
  border-radius: var(--radius) 0 0 var(--radius);
}

/* ── Share buttons ───────────────────────────────────────────── */
.share-bar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 16px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  margin: 24px 0; font-family: var(--font-ui);
}
.share-label { font-size: 13px; font-weight: 700; color: var(--text-muted); margin-right: 4px; }
.share-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 4px;
  font-size: 12px; font-weight: 700; cursor: pointer;
  border: none; transition: opacity .15s;
}
.share-btn:hover { opacity: .85; }
.share-fb  { background: #1877F2; color: #fff; }
.share-tw  { background: #111;    color: #fff; }
.share-wa  { background: #25D366; color: #fff; }
.share-copy{ background: var(--surface2); color: var(--text); border: 1px solid var(--border2); }

/* ── Newsletter ──────────────────────────────────────────────── */
.newsletter-box {
  background: var(--red);
  color: var(--white); padding: 40px 32px;
  border-radius: var(--radius-md); text-align: center; margin: 40px 0;
}
.newsletter-box h2 { font-family: var(--font-heading); font-size: 26px; font-weight: 900; margin-bottom: 8px; }
.newsletter-box p  { color: rgba(255,255,255,.8); margin-bottom: 20px; }
.newsletter-form { display: flex; gap: 8px; max-width: 460px; margin: 0 auto; }
.newsletter-form input {
  flex: 1; padding: 12px 16px;
  border: 2px solid rgba(255,255,255,.3);
  background: rgba(0,0,0,.2); color: var(--white);
  border-radius: 4px; font-size: 14px; font-family: var(--font-ui); outline: none;
}
.newsletter-form input::placeholder { color: rgba(255,255,255,.6); }
.newsletter-form input:focus { border-color: var(--white); }
.newsletter-form button {
  padding: 12px 22px; background: var(--black); color: var(--white);
  border: none; border-radius: 4px; font-size: 14px; font-weight: 900;
  font-family: var(--font-ui); cursor: pointer; white-space: nowrap; transition: background .15s;
}
.newsletter-form button:hover { background: var(--surface2); }

/* ── Commentaires ────────────────────────────────────────────── */
.comments-section, #comments { border-top: 1px solid var(--border); padding-top: 40px; margin-top: 40px; }
.comment-item { padding: 16px 0; border-bottom: 1px solid var(--border); }
.comment-author { font-weight: 700; font-family: var(--font-ui); font-size: 14px; color: var(--text); margin-bottom: 4px; }
.comment-date   { font-size: 12px; color: var(--text-dim); font-family: var(--font-ui); }
.comment-text   { font-size: 15px; color: var(--text-muted); margin-top: 8px; line-height: 1.6; }
.comment-form {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-md); padding: 24px; margin-top: 24px;
}
.comment-form h3 { font-size: 16px; font-weight: 700; font-family: var(--font-ui); margin-bottom: 16px; color: var(--text); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.form-group { display: flex; flex-direction: column; gap: 5px; }
.form-group label { font-size: 12px; font-weight: 700; font-family: var(--font-ui); color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.form-group input, .form-group textarea {
  border: 1px solid var(--border2); background: var(--surface2);
  color: var(--text); padding: 10px 12px; border-radius: var(--radius);
  font-size: 14px; font-family: var(--font-body); outline: none; transition: border-color .15s;
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--red); }
.form-group textarea { resize: vertical; min-height: 100px; }
.btn-submit {
  background: var(--red); color: var(--white); border: none;
  padding: 12px 28px; border-radius: var(--radius);
  font-size: 14px; font-weight: 700; font-family: var(--font-ui); cursor: pointer; transition: background .15s;
}
.btn-submit:hover { background: var(--red-dark); }

/* ── Ad slots ────────────────────────────────────────────────── */
.ad-slot {
  background: var(--surface); border: 1px dashed var(--border2);
  border-radius: var(--radius); text-align: center;
  padding: 8px; min-height: 90px;
  display: flex; align-items: center; justify-content: center;
}
.ad-slot-banner { min-height: 90px; }
.ad-slot-rect   { min-height: 250px; }
.ad-slot-sky    { min-height: 600px; }
.ad-label { font-size: 10px; color: var(--text-dim); font-family: var(--font-ui); display: block; margin-bottom: 4px; text-transform: uppercase; letter-spacing: .5px; }

/* ── Pagination ──────────────────────────────────────────────── */
.pagination { display: flex; justify-content: center; gap: 6px; margin: 32px 0; flex-wrap: wrap; }
.page-btn {
  padding: 8px 14px; border: 1px solid var(--border2);
  border-radius: var(--radius); font-size: 14px;
  font-family: var(--font-ui); cursor: pointer;
  background: var(--surface); color: var(--text); transition: .15s;
}
.page-btn:hover  { border-color: var(--red); color: var(--red); }
.page-btn.active { background: var(--red); border-color: var(--red); color: var(--white); font-weight: 700; }
.page-btn:disabled { opacity: .4; cursor: default; }

/* ── Footer ──────────────────────────────────────────────────── */
.site-footer {
  background: var(--black);
  border-top: 1px solid rgba(193,39,45,.3);
  color: var(--text-muted);
  margin-top: 60px;
}
.footer-top { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; padding: 48px 0 32px; }
.footer-logo-name {
  font-family: var(--font-ui);
  font-size: 26px; font-weight: 900; color: var(--white);
  margin-bottom: 8px; display: block;
  letter-spacing: -.3px;
}
.footer-logo-name em { color: var(--red); font-style: normal; }
.footer-tagline { font-size: 12px; margin-bottom: 20px; color: var(--text-dim); }
.footer-social  { display: flex; gap: 8px; }
.social-btn {
  width: 34px; height: 34px; border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface);
  font-size: 15px; transition: background .15s; text-decoration: none;
  border: 1px solid var(--border);
}
.social-btn:hover { background: var(--red); border-color: var(--red); }
.footer-col h4 {
  font-family: var(--font-ui); font-size: 11px; font-weight: 900;
  color: var(--white); text-transform: uppercase; letter-spacing: .7px;
  margin-bottom: 14px; padding-bottom: 8px;
  border-bottom: 1px solid rgba(193,39,45,.3);
}
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a { font-size: 13px; transition: color .15s; color: var(--text-dim); }
.footer-col ul li a:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 16px 0;
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12px; flex-wrap: wrap; gap: 8px;
}
.footer-bottom a:hover { color: var(--white); }

/* ── Loader ──────────────────────────────────────────────────── */
.loader { display: flex; align-items: center; justify-content: center; padding: 40px; gap: 8px; color: var(--text-dim); font-family: var(--font-ui); font-size: 14px; }
.spinner { width: 20px; height: 20px; border: 2px solid var(--border2); border-top-color: var(--red); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Toast ───────────────────────────────────────────────────── */
.toast-msg {
  position: fixed; bottom: 24px; right: 24px; z-index: 9999;
  background: var(--surface2); color: var(--white);
  padding: 12px 20px; border-radius: var(--radius-md);
  font-size: 14px; font-family: var(--font-ui);
  box-shadow: var(--shadow-md); transition: opacity .3s;
  border-left: 3px solid var(--red);
}
[dir="rtl"] .toast-msg { right: auto; left: 24px; border-left: none; border-right: 3px solid var(--red); }

/* ── Bouton dark toggle ──────────────────────────────────────── */
.dark-toggle {
  background: none; border: 1px solid var(--border2);
  color: var(--text); width: 34px; height: 34px; border-radius: 4px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  font-size: 15px; transition: background .2s; flex-shrink: 0;
}
.dark-toggle:hover { background: var(--surface2); }

/* Breaking news séparateur */
.brk-sep { color: rgba(255,255,255,.35); margin: 0 12px; font-size: 10px; vertical-align: middle; display: inline-block; }

/* ── Dark mode (override — le site est déjà sombre, mais on garde le toggle) ── */
/* En mode "light" (si jamais activé), on inverse */
[data-theme="light"] {
  --bg:         #F8F8F8;
  --surface:    #FFFFFF;
  --surface2:   #F0F0F0;
  --border:     rgba(0,0,0,.09);
  --border2:    rgba(0,0,0,.15);
  --text:       #111111;
  --text-muted: #555555;
  --text-dim:   #888888;
}
[data-theme="light"] body    { background: var(--bg); color: var(--text); }
[data-theme="light"] .site-header { background: #fff; border-bottom: 1px solid rgba(0,0,0,.1); }
[data-theme="light"] .site-nav    { background: #111; }
[data-theme="light"] .article-card { background: #fff; }
[data-theme="light"] .widget       { background: #fff; }
[data-theme="light"] .site-footer  { background: #0A0A0A; }
[data-theme="light"] .page-btn     { background: #fff; color: #111; }
[data-theme="light"] .comment-form { background: #f5f5f5; }

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .grid-4      { grid-template-columns: repeat(2,1fr); }
  .layout-main { grid-template-columns: 1fr; }
  .sidebar     { display: grid; grid-template-columns: 1fr 1fr; }
  .footer-top  { grid-template-columns: 1fr 1fr; gap: 24px; }
}
@media (max-width: 768px) {
  :root { --header-h: 54px; }
  .hero                 { grid-template-columns: 1fr; }
  .hero-main img        { height: 280px; }
  .hero-side            { flex-direction: row; }
  .hero-side-item       { min-height: 130px; }
  .hero-title           { font-size: 20px; }
  .grid-3, .grid-2      { grid-template-columns: 1fr; }
  .grid-4               { grid-template-columns: 1fr 1fr; }
  .article-detail-title { font-size: 22px; }
  .article-content      { font-size: 16px; }
  .header-search        { display: none; }
  .header-top           { gap: 8px; }
  .burger-btn           { display: block; }
  .newsletter-form      { flex-direction: column; }
  .form-row             { grid-template-columns: 1fr; }
  .footer-top           { grid-template-columns: 1fr; }
  .footer-bottom        { flex-direction: column; text-align: center; }
  .video-grid-layout    { grid-template-columns: 1fr !important; }
  .contact-grid         { grid-template-columns: 1fr !important; }
  /* Layout sidebar */
  .layout-main          { grid-template-columns: 1fr; }
  .sidebar              { grid-template-columns: 1fr 1fr; display: grid; gap: 16px; }
  /* Sections À la une */
  .une-section          { grid-template-columns: 1fr; }
  .une-main-link        { height: 260px; }
  .une-grid             { grid-template-columns: 1fr 1fr; }
  .une-sub img          { height: 140px; }
  .une-title            { font-size: 18px; }
  /* Cards */
  .article-card-body    { padding: 12px; }
  .article-card-title   { font-size: 15px; }
  /* Réactions */
  .article-reactions    { padding: 16px 12px; }
  .react-btn            { padding: 8px 16px; }
  /* Conteneur */
  .container            { padding: 0 14px; }
}
@media (max-width: 480px) {
  .grid-4    { grid-template-columns: 1fr; }
  .hero-side { flex-direction: column; }
  .newsletter-box { padding: 24px 16px; }
  .newsletter-box h2 { font-size: 22px; }
}

/* Transitions globales */
body, .site-header, .site-nav, .article-card,
.widget, .page-btn, .site-footer {
  transition: background-color .2s ease, color .15s ease, border-color .15s ease;
}

/* ── Logo MMNews adaptatif ───────────────────────────────── */
.logo-text { color: #fff; }
[data-theme="light"] .logo-text { color: #111; }

/* Overrides mode clair : grays inversés */
[data-theme="light"] {
  --dark:     #111111;
  --gray-50:  #F8F8F8;
  --gray-100: #F0F0F0;
  --gray-200: #DDDDDD;
  --gray-400: #999999;
  --gray-500: #666666;
  --gray-700: #444444;
}

/* ── Hero : texte toujours blanc (sur image) ─────────────── */
.hero-main-overlay,
.hero-main-overlay * { color: #fff !important; }
.hero-side-overlay,
.hero-side-overlay * { color: #fff !important; }
.hero-title           { color: #fff !important; }
.hero-side-title      { color: #fff !important; }
.hero-meta            { color: rgba(255,255,255,.8) !important; }

/* ── Texte général en mode sombre ────────────────────────── */
.article-card-title  { color: var(--text); }
.article-card-h-title{ color: var(--text); }
.widget-body a       { color: var(--text); }

/* Liens dans sidebar most-read */
.widget-body a:hover { color: var(--red); }

/* ── Section titres ──────────────────────────────────────── */
.hv-hdr-title { color: var(--text) !important; }

/* ── Newsletter widget ───────────────────────────────────── */
.widget-body input {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
}
.widget-body input:focus { border-color: var(--red); }

/* ══════════════════════════════════════════════════════════════
   Reactions — Likes / Dislikes
   ══════════════════════════════════════════════════════════════ */
.article-reactions {
  display: flex; flex-direction: column; align-items: center;
  gap: 12px; margin: 32px 0;
  padding: 20px; border: 1px solid var(--border);
  border-radius: var(--radius-lg); background: var(--surface);
  text-align: center;
}
.react-label {
  font-size: 14px; color: var(--text-muted); font-family: var(--font-ui);
}
.react-btns { display: flex; gap: 16px; }
.react-btn {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 20px; border-radius: 50px;
  border: 1px solid var(--border); background: var(--surface2);
  color: var(--text); font-size: 15px; cursor: pointer;
  transition: all .2s; font-family: var(--font-ui);
}
.react-btn:hover  { border-color: var(--red); transform: scale(1.05); }
.react-btn.active { background: var(--red); border-color: var(--red); color: #fff; }
.react-count { font-weight: 700; font-size: 14px; }
.react-bar {
  width: 100%; max-width: 300px; height: 6px;
  background: rgba(193,39,45,.2); border-radius: 3px; overflow: hidden;
}
.react-bar-like {
  height: 100%; background: var(--red);
  border-radius: 3px; transition: width .4s ease;
}
/* Mini boutons pour commentaires */
.react-btn-sm {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px; border-radius: 20px;
  border: 1px solid var(--border); background: transparent;
  color: var(--text-muted); font-size: 12px; cursor: pointer;
  transition: all .15s; font-family: var(--font-ui);
}
.react-btn-sm:hover  { border-color: var(--red); color: var(--text); }
.react-btn-sm.active { background: rgba(193,39,45,.1); border-color: var(--red); color: var(--red); }

/* ══════════════════════════════════════════════════════════════
   Responsive — Améliorations multi-navigateurs
   ══════════════════════════════════════════════════════════════ */

/* Correctifs cross-browser */
* { -webkit-box-sizing: border-box; box-sizing: border-box; }
img { max-width: 100%; height: auto; }
button { cursor: pointer; font-family: inherit; }

/* Tablette (768–1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
  .container         { padding: 0 20px; }
  .layout-main       { grid-template-columns: 1fr 260px; gap: 20px; }
  .une-section       { grid-template-columns: 1.4fr 1fr; }
  .une-main-link     { height: 380px; }
  .une-sub img       { height: 190px; }
  .article-card-body { padding: 14px; }
}


/* Mobile petit (< 480px) */
@media (max-width: 480px) {
  :root { font-size: 15px; }

  .une-grid        { grid-template-columns: 1fr; }
  .une-sub img     { height: 180px; }
  .sidebar         { grid-template-columns: 1fr; }

  /* Nav horizontale scrollable */
  .nav-inner {
    overflow-x: auto; -webkit-overflow-scrolling: touch;
    scrollbar-width: none; padding-bottom: 2px;
  }
  .nav-inner::-webkit-scrollbar { display: none; }
  .nav-link { white-space: nowrap; font-size: 13px; }

  /* Articles */
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }

  /* Article detail */
  .article-detail-title { font-size: 20px; }
  .article-content      { font-size: 15px; line-height: 1.75; }

  /* Reactions */
  .react-btns { gap: 10px; }
  .react-btn  { padding: 8px 14px; font-size: 14px; }
}

/* Correctif Safari iOS — font rendering */
@supports (-webkit-touch-callout: none) {
  body { -webkit-text-size-adjust: 100%; }
}

/* Correctif Firefox — scrollbar width */
@supports (-moz-appearance: none) {
  .nav-inner { scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
}

/* ══════════════════════════════════════════════════════════════
   CARROUSEL "À LA UNE"
   ══════════════════════════════════════════════════════════════ */
.hero-carousel {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--surface);
  margin: 20px 0 28px;
  -webkit-user-select: none;
  user-select: none;
}
.hc-track { position: relative; width: 100%; }
.hc-slide {
  display: none;
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 7;
}
.hc-slide.active { display: block; }
.hc-img-link { display: block; width: 100%; height: 100%; }
.hc-img-link img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}
.hc-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0,0,0,.88) 0%,
    rgba(0,0,0,.45) 50%,
    rgba(0,0,0,.08) 100%
  );
  display: flex;
  align-items: flex-end;
}
.hc-content {
  padding: 28px 32px;
  color: #fff;
  width: 100%;
  max-width: 720px;
}
.hc-cat {
  display: inline-block;
  background: var(--red);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-ui);
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 3px 10px;
  border-radius: 3px;
  margin-bottom: 10px;
}
.hc-title-link { text-decoration: none; }
.hc-title {
  font-family: var(--font-heading);
  font-size: clamp(20px, 3vw, 34px);
  font-weight: 700;
  color: #fff;
  line-height: 1.25;
  margin: 0 0 8px;
  text-shadow: 0 2px 8px rgba(0,0,0,.6);
}
.hc-title:hover { color: #f9d5d6; }
.hc-desc {
  font-size: 14px;
  color: rgba(255,255,255,.82);
  margin: 0 0 10px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.hc-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  font-family: var(--font-ui);
  color: rgba(255,255,255,.7);
}
/* Boutons précédent / suivant */
.hc-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,.55);
  color: #fff;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 50%;
  width: 44px; height: 44px;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, transform .2s;
  z-index: 10;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.hc-btn:hover { background: var(--red); transform: translateY(-50%) scale(1.08); }
.hc-prev { left: 14px; }
.hc-next { right: 14px; }
/* Points indicateurs */
.hc-dots {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}
.hc-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.4);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: all .25s;
}
.hc-dot.active {
  background: #fff;
  width: 24px;
  border-radius: 4px;
}

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE COMPLET — Tablette & Mobile
   ══════════════════════════════════════════════════════════════ */

/* ── Desktop large (> 1220px) ─────────────────────────────── */
@media (min-width: 1220px) {
  .layout-main { gap: 32px; }
  .hc-slide    { aspect-ratio: 16/6; }
}

/* ── Tablette paysage (900–1220px) ────────────────────────── */
@media (max-width: 1220px) and (min-width: 900px) {
  .container    { padding: 0 20px; }
  .layout-main  { grid-template-columns: 1fr 280px; gap: 24px; }
  .grid-4       { grid-template-columns: repeat(2,1fr); }
  .hc-content   { padding: 22px 24px; }
  .hc-btn       { width: 38px; height: 38px; font-size: 20px; }
}

/* ── Tablette portrait (600–900px) ────────────────────────── */
@media (max-width: 900px) {
  .container    { padding: 0 16px; }
  .layout-main  { grid-template-columns: 1fr; gap: 20px; }
  .sidebar      { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

  /* Carrousel */
  .hc-slide     { aspect-ratio: 16/8; }
  .hc-content   { padding: 18px 20px; max-width: 100%; }
  .hc-title     { font-size: clamp(17px,3.5vw,26px); }
  .hc-desc      { display: none; }
  .hc-btn       { width: 36px; height: 36px; font-size: 18px; }
  .hc-prev      { left: 8px; }
  .hc-next      { right: 8px; }

  /* Grilles */
  .grid-3       { grid-template-columns: 1fr 1fr; gap: 14px; }
  .grid-4       { grid-template-columns: 1fr 1fr; gap: 14px; }

  /* Nav */
  .burger-btn    { display: block; }
}

/* ── Mobile large (480–600px) ─────────────────────────────── */
@media (max-width: 600px) {
  .container    { padding: 0 12px; }

  /* Carrousel */
  .hc-slide     { aspect-ratio: 4/3; }
  .hc-content   { padding: 14px 16px; }
  .hc-title     { font-size: 16px; }
  .hc-cat       { font-size: 10px; padding: 2px 8px; }
  .hc-meta      { font-size: 11px; gap: 8px; }
  .hc-btn       { width: 32px; height: 32px; font-size: 16px; }

  /* Grilles → 1 colonne */
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .grid-4          { grid-template-columns: 1fr 1fr; }

  /* Sidebar → 1 colonne */
  .sidebar    { grid-template-columns: 1fr; }

  /* Cartes */
  .article-card-title { font-size: 15px; }
  .article-card-body  { padding: 12px 14px; }
}

/* ── Mobile petit (< 480px) ───────────────────────────────── */
@media (max-width: 480px) {
  :root { --header-h: 50px; }
  .container  { padding: 0 10px; }

  /* Carrousel */
  .hc-slide   { aspect-ratio: 3/2; }
  .hc-dots    { bottom: 10px; }
  .hc-dot     { width: 6px; height: 6px; }
  .hc-dot.active { width: 18px; }

  /* Nav scrollable */
  .site-nav .container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .site-nav .container::-webkit-scrollbar { display: none; }
  .nav-link { white-space: nowrap; font-size: 13px; padding: 10px 10px; }

  /* Grilles */
  .grid-4 { grid-template-columns: 1fr; }

  /* Article detail */
  .article-detail-title { font-size: 20px; }
  .article-content      { font-size: 15px; line-height: 1.75; }

  /* Footer */
  .footer-top    { grid-template-columns: 1fr; gap: 20px; }
  .footer-bottom { flex-direction: column; text-align: center; gap: 10px; }
}

/* ── Correctifs cross-browser ─────────────────────────────── */

/* Safari iOS — tap highlight */
* { -webkit-tap-highlight-color: transparent; }

/* Safari — font rendering */
@supports (-webkit-touch-callout: none) {
  body                { -webkit-text-size-adjust: 100%; }
  .hc-title           { -webkit-font-smoothing: antialiased; }
}

/* Firefox — scrollbar thin */
@supports (-moz-appearance: none) {
  .site-nav .container { scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
}

/* IE / Edge legacy — fallback aspect-ratio */
@supports not (aspect-ratio: 16/7) {
  .hc-slide    { height: 460px; }
  .hc-img-link { height: 100%; }
  @media (max-width: 900px) { .hc-slide { height: 320px; } }
  @media (max-width: 600px) { .hc-slide { height: 250px; } }
  @media (max-width: 480px) { .hc-slide { height: 200px; } }
}

/* Animations réduites pour accessibilité */
@media (prefers-reduced-motion: reduce) {
  .hc-slide, .hc-btn, .hc-dot, .article-card { transition: none !important; }
}

/* ══════════════════════════════════════════════════════════════
   Sections Vidéos & Shorts — page d'accueil
   (déplacé depuis index.php)
   ══════════════════════════════════════════════════════════════ */
.hv-section { margin: 40px 0; }
.hv-hdr {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px; padding-bottom: 10px;
  border-bottom: 2px solid var(--red);
  flex-wrap: wrap; gap: 10px;
}
.hv-hdr-title {
  font-family: var(--font-heading); font-size: 22px; font-weight: 900; margin: 0;
  color: var(--text);
}
.hv-hdr-link {
  font-size: 13px; font-weight: 700; color: var(--red); text-decoration: none;
}
.hv-hdr-link:hover { text-decoration: underline; }

/* Lecteur vidéo + playlist */
.hv-main-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 20px;
  background: var(--dark-bg, #111);
  border-radius: 12px;
  overflow: hidden;
  padding: 20px;
}
@media (max-width: 860px) {
  .hv-main-layout { grid-template-columns: 1fr; }
  .hv-playlist    { display: flex !important; overflow-x: auto; gap: 10px; }
  .hv-pl-item     { min-width: 160px; flex-direction: column; }
}
.hv-player {
  background: #000; border-radius: 10px; overflow: hidden;
  aspect-ratio: 16/9; position: relative;
}
.hv-player iframe,
.hv-player video { width: 100%; height: 100%; border: none; display: block; }
.hv-player img   { width: 100%; height: 100%; object-fit: cover; display: block; cursor: pointer; }
.hv-player-icon  {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.3); cursor: pointer;
}
.hv-player-icon span {
  width: 60px; height: 60px; background: var(--red); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 24px; color: #fff;
  box-shadow: 0 4px 16px rgba(193,39,45,.5);
  transition: transform .2s;
}
.hv-player-icon:hover span { transform: scale(1.1); }
.hv-vid-title {
  font-family: var(--font-heading); font-size: 16px; font-weight: 700;
  color: #fff; margin: 12px 0 6px; line-height: 1.4;
}
.hv-vid-meta {
  font-size: 12px; color: rgba(255,255,255,.5);
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
}
.hv-vid-link { color: var(--red); font-weight: 700; font-size: 12px; text-decoration: none; }

/* Playlist latérale */
.hv-pl-hdr {
  font-size: 11px; font-weight: 700; color: rgba(255,255,255,.45);
  text-transform: uppercase; letter-spacing: .5px;
  padding-bottom: 8px; border-bottom: 1px solid rgba(255,255,255,.1);
  margin-bottom: 8px;
}
.hv-playlist { display: flex; flex-direction: column; gap: 4px; }
.hv-pl-item {
  display: flex; gap: 10px; padding: 8px; border-radius: 8px;
  background: transparent; border: none; cursor: pointer;
  transition: background .15s; border-left: 3px solid transparent;
  align-items: flex-start; width: 100%; text-decoration: none;
}
.hv-pl-item:hover  { background: rgba(255,255,255,.07); }
.hv-pl-item.active { background: rgba(255,255,255,.1); border-left-color: var(--red); }
.hv-pl-thumb {
  width: 85px; height: 52px; flex-shrink: 0; border-radius: 6px;
  overflow: hidden; background: #111; position: relative;
}
.hv-pl-thumb img { width: 100%; height: 100%; object-fit: cover; }
.hv-pl-play {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.25); font-size: 12px; color: #fff;
}
.hv-pl-title {
  font-size: 12px; font-weight: 600; color: rgba(255,255,255,.8); line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.hv-pl-date { font-size: 11px; color: rgba(255,255,255,.35); margin-top: 3px; }

/* Grille Shorts */
.hv-shorts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
}
@media (max-width: 580px) { .hv-shorts-grid { grid-template-columns: repeat(2,1fr); } }
.hv-short {
  aspect-ratio: 9/16; border-radius: 12px; overflow: hidden;
  position: relative; cursor: pointer; display: block; background: #111;
  text-decoration: none; transition: transform .2s;
}
.hv-short:hover { transform: scale(1.03); }
.hv-short img   { width: 100%; height: 100%; object-fit: cover; }
.hv-short-grad  {
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,.85), rgba(0,0,0,.05) 55%, transparent);
}
.hv-short-top {
  position: absolute; top: 0; left: 0; right: 0;
  display: flex; align-items: center; justify-content: space-between; padding: 10px;
}
.hv-short-plat {
  background: rgba(0,0,0,.65); color: #fff; font-size: 10px; font-weight: 700;
  padding: 3px 7px; border-radius: 20px; backdrop-filter: blur(4px);
}
.hv-short-play {
  width: 28px; height: 28px; background: rgba(255,255,255,.2);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 11px; backdrop-filter: blur(4px);
}
.hv-short-info { position: absolute; bottom: 0; left: 0; right: 0; padding: 26px 10px 10px; }
.hv-short-title {
  font-size: 11px; font-weight: 700; color: #fff; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}

/* Modal vidéo */
.hv-modal-bg {
  display: none; position: fixed; inset: 0; z-index: 2000;
  background: rgba(0,0,0,.92); align-items: center; justify-content: center; padding: 20px;
}
.hv-modal-bg.open { display: flex; }
.hv-modal-box {
  width: min(95vw, 900px); background: #000; border-radius: 14px;
  overflow: hidden; position: relative; box-shadow: 0 0 80px rgba(0,0,0,.8);
}
.hv-modal-close {
  position: absolute; top: 12px; right: 12px; z-index: 10;
  background: rgba(255,255,255,.15); border: none; color: #fff;
  width: 34px; height: 34px; border-radius: 50%; font-size: 16px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(4px);
}
.hv-modal-close:hover { background: rgba(255,255,255,.3); }
#hvMC iframe { width: 100%; aspect-ratio: 16/9; border: none; display: block; }
.hv-modal-info  { padding: 14px 20px; background: #111; }
.hv-modal-title { font-size: 15px; font-weight: 700; color: #fff; margin: 0 0 5px; font-family: var(--font-heading); }
.hv-modal-link  { color: var(--red); font-weight: 700; text-decoration: none; font-size: 12px; }

/* ── Widget Éditorial : dernière caricature ─────────────────── */
.editorial-caricature {
  display: block; padding: 0 16px 12px;
  border-bottom: 1px solid var(--border); text-decoration: none;
}
.editorial-caricature img {
  display: block; width: 100%; height: 170px; object-fit: contain;
  background: #fff; border-radius: var(--radius-md);
}
.editorial-caricature span {
  display: block; margin-top: 8px; font-family: var(--font-ui);
  font-size: 12px; font-weight: 600; line-height: 1.4; color: var(--text-muted);
}

/* ── Galerie des caricatures ────────────────────────────────── */
.caricature-card {
  display: flex; flex-direction: column; gap: 6px; padding: 10px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-md); text-decoration: none;
  transition: border-color .15s;
}
.caricature-card:hover { border-color: var(--red); }
.caricature-card-img {
  display: block; aspect-ratio: 4/3; background: #fff;
  border-radius: var(--radius); overflow: hidden;
}
.caricature-card-img img { display: block; width: 100%; height: 100%; object-fit: contain; }
.caricature-card-title { font-family: var(--font-ui); font-size: 14px; font-weight: 700; line-height: 1.4; color: var(--text); }
.caricature-card time  { font-family: var(--font-ui); font-size: 12px; color: var(--text-muted); }

/* ── Page Jeunesse : BLADI ──────────────────────────────────── */
.bladi-promo {
  display: grid; grid-template-columns: minmax(0, 340px) 1fr; gap: 40px;
  align-items: center; max-width: 900px; margin: 32px auto 48px;
}
.bladi-cover {
  display: block; width: 100%; aspect-ratio: 3/4; object-fit: cover;
  background: var(--surface2); border-radius: var(--radius-md); box-shadow: var(--shadow-md);
}
.bladi-kicker { margin: 0 0 6px; font-family: var(--font-ui); font-size: 13px; font-weight: 700; color: var(--red); }
.bladi-title  { margin: 0 0 8px; font-family: var(--font-heading); font-size: 44px; font-weight: 900; line-height: 1.1; }
.bladi-tagline { margin: 0 0 16px; font-family: var(--font-ui); font-size: 18px; font-weight: 600; color: var(--text); }
.bladi-text   { margin: 0 0 24px; font-size: 15px; line-height: 1.8; color: var(--gray-700); }
.bladi-buy {
  display: inline-block; padding: 12px 28px; border-radius: 6px;
  background: var(--red); color: #fff; font-family: var(--font-ui);
  font-size: 15px; font-weight: 700; text-decoration: none;
}
.bladi-buy:hover { background: var(--red-dark); }
.bladi-soon { margin: 0; font-family: var(--font-ui); font-size: 14px; font-weight: 700; color: var(--text-muted); }
@media (max-width: 700px) {
  .bladi-promo { grid-template-columns: 1fr; gap: 24px; justify-items: center; text-align: center; }
  .bladi-cover { max-width: 280px; }
  .bladi-title { font-size: 36px; }
}

/* ── Recherche dans le menu mobile ──────────────────────────── */
.nav-search { display: none; }
@media (max-width: 768px) {
  .nav-search { display: flex; gap: 8px; margin-bottom: 8px; }
  .nav-search input[type="search"] {
    flex: 1; min-width: 0; padding: 11px 14px; border-radius: 6px;
    border: 1px solid var(--border2); background: var(--surface); color: var(--text);
    font-family: var(--font-ui); font-size: 16px; outline: none;
  }
  .nav-search input[type="search"]:focus { border-color: var(--red); }
  .nav-search button {
    padding: 0 14px; border: none; border-radius: 6px;
    background: var(--red); color: #fff; font-size: 16px; cursor: pointer;
  }
}

/* Le slogan repousse le menu hors de l'écran sur téléphone */
@media (max-width: 560px) { .logo-tagline { display: none; } }

/* --dark est une couleur de texte ici : le menu ouvert garde un fond sombre */
body .site-nav.nav-open { background: #111; }

/* Mode jour : titres écrits en blanc sur fond clair */
[data-theme="light"] .widget-header,
[data-theme="light"] .section-title { color: #111; }

/* ── Page Jeunesse : autres numéros ─────────────────────────── */
.bladi-more { max-width: 900px; margin: 0 auto 48px; }
.bladi-issue { display: flex; flex-direction: column; gap: 10px; font-family: var(--font-ui); font-size: 14px; }
.bladi-issue img {
  display: block; width: 100%; aspect-ratio: 3/4; object-fit: cover;
  background: var(--surface2); border-radius: var(--radius-md);
}
.bladi-issue .bladi-buy { padding: 8px 12px; font-size: 13px; text-align: center; }

/* ── Fond zellige « rosace de la médina » (templates/header.php) ──────────
   Le motif n'occupe que les marges latérales : la colonne de lecture reste vierge.
   Il glisse lentement (transform, sans redessin) ; un reflet passe toutes les 24 s. */
:root {
  --zl-line: rgba(214, 178, 98, .15);
  --zl-hi:   rgba(240, 205, 125, .65);
  --zl-band: rgba(214, 178, 98, .32);
}
[data-theme="light"] {
  --zl-line: rgba(15, 107, 79, .15);
  --zl-hi:   rgba(181, 83, 47, .55);
  --zl-band: rgba(15, 107, 79, .3);
}
.zl-bg {
  position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden;
  --zl-edge: calc(50% - var(--max-w) / 2);
  -webkit-mask-image: linear-gradient(90deg, #000 calc(var(--zl-edge) - 60px), transparent calc(var(--zl-edge) + 4px),
                                             transparent calc(100% - var(--zl-edge) - 4px), #000 calc(100% - var(--zl-edge) + 60px));
          mask-image: linear-gradient(90deg, #000 calc(var(--zl-edge) - 60px), transparent calc(var(--zl-edge) + 4px),
                                             transparent calc(100% - var(--zl-edge) - 4px), #000 calc(100% - var(--zl-edge) + 60px));
}
.zl-layer {
  position: absolute; top: -120px; left: -120px;
  width: calc(100% + 240px); height: calc(100% + 240px);
  animation: zl-drift 90s linear infinite; will-change: transform;
}
.zl-shine {
  -webkit-mask-image: linear-gradient(105deg, transparent 44%, #000 50%, transparent 56%);
          mask-image: linear-gradient(105deg, transparent 44%, #000 50%, transparent 56%);
  -webkit-mask-size: 300% 100%; mask-size: 300% 100%;
  -webkit-mask-position: 120% 0; mask-position: 120% 0;
  animation: zl-drift 90s linear infinite, zl-sweep 24s ease-in-out infinite;
}
@keyframes zl-drift { to { transform: translate(120px, 120px); } }
@keyframes zl-sweep {
  0%   { -webkit-mask-position: 120% 0; mask-position: 120% 0; }
  18%, 100% { -webkit-mask-position: -20% 0; mask-position: -20% 0; }
}
.zl-band { height: 26px; overflow: hidden; border-bottom: 1px solid var(--border); }
.zl-band svg { display: block; }
@media (prefers-reduced-motion: reduce) {
  .zl-layer { animation: none; }
  .zl-shine { display: none; }
}
@media print { .zl-bg, .zl-band { display: none; } }

/* ══════════════════════════════════════════════════════════════
   Application installable (app.php, templates/footer.php, assets/js/app.js)
   Fil immersif : un article par écran, défilement vertical aimanté.
   ══════════════════════════════════════════════════════════════ */
body.ap-page { background: #000; overflow: hidden; }
.ap-page .site-footer, .ap-page .zl-bg, .ap-page .zl-band { display: none; }

.ap-top {
  position: fixed; top: 0; left: 0; right: 0; z-index: 20;
  display: flex; align-items: center; gap: 12px;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 0 18px;
  padding-inline-start: max(16px, env(safe-area-inset-left, 0px)); /* côté du logo, à droite en arabe */
  background: linear-gradient(rgba(0,0,0,.7), rgba(0,0,0,0));
}
.ap-logo { flex-shrink: 0; font: 900 21px var(--font-ui); color: #fff; letter-spacing: -.5px; }
.ap-logo span { color: #ff5a60; }
.ap-lang { position: relative; flex-shrink: 0; }
.ap-lang summary {
  list-style: none; cursor: pointer; min-width: 38px; height: 30px; padding: 0 10px; border-radius: 999px;
  display: flex; align-items: center; justify-content: center; gap: 4px;
  font: 800 13px var(--font-ui); color: #fff; border: 1px solid rgba(255,255,255,.45); background: rgba(0,0,0,.25);
}
.ap-lang summary::-webkit-details-marker { display: none; }
.ap-lang summary::after { content: ''; width: 6px; height: 6px; border: solid currentColor; border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); }
.ap-lang[open] summary { background: #fff; color: #0a0a0a; }
.ap-lang-menu {
  position: absolute; top: calc(100% + 8px); inset-inline-start: 0; z-index: 30; min-width: 150px;
  display: flex; flex-direction: column; padding: 6px; border-radius: 14px;
  background: #151515; border: 1px solid rgba(255,255,255,.14); box-shadow: 0 10px 30px rgba(0,0,0,.5);
}
.ap-lang-menu a { padding: 11px 14px; border-radius: 9px; color: #e5e5e5; font: 700 15px var(--font-ui); }
.ap-lang-menu a.on { background: #c1272d; color: #fff; }
.ap-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-inline-end: 16px; }
.ap-chips::-webkit-scrollbar { display: none; }
.ap-chips a {
  flex-shrink: 0; padding: 6px 13px; border-radius: 999px; font: 700 13px var(--font-ui);
  color: rgba(255,255,255,.82); background: rgba(255,255,255,.12); backdrop-filter: blur(6px);
}
.ap-chips a.on { background: #fff; color: #0a0a0a; }

.ap-feed {
  height: 100vh; height: 100dvh; overflow-y: auto; overscroll-behavior: contain;
  scroll-snap-type: y mandatory; scrollbar-width: none;
}
.ap-feed::-webkit-scrollbar { display: none; }
.ap-card {
  position: relative; height: 100vh; height: 100dvh; overflow: hidden;
  scroll-snap-align: start; scroll-snap-stop: always;
  display: flex; flex-direction: column; justify-content: flex-end; color: #fff;
  background: radial-gradient(120% 80% at 50% 0%, #6e1a1e 0%, #1a0a0b 55%, #050505 100%);
}
.ap-card.ap-noimg { background: radial-gradient(120% 80% at 50% 0%, #0f4a2a 0%, #08160f 55%, #050505 100%); }
/* Photo affichée en entier (rien n'est coupé) dans l'espace au-dessus du texte ;
   la même photo, floutée et assombrie, remplit le reste de l'écran */
.ap-bg {
  position: absolute; inset: -40px; width: calc(100% + 80px); height: calc(100% + 80px);
  object-fit: cover; filter: blur(28px) brightness(.5) saturate(1.2);
}
.ap-img {
  position: relative; display: block; flex: 1 1 auto; min-height: 0; width: 100%;
  margin-top: calc(62px + env(safe-area-inset-top, 0px)); margin-bottom: 14px;
  object-fit: contain; object-position: center;
}
.ap-noimg .ap-body, .ap-card:not(:has(.ap-img)) .ap-body { margin-top: auto; }
.ap-shade {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,.6) 0%, rgba(0,0,0,0) 12%, rgba(0,0,0,0) 50%, rgba(0,0,0,.55) 75%, rgba(0,0,0,.8) 100%);
}
.ap-body {
  position: relative; display: flex; flex-direction: column; gap: 10px; max-width: 640px;
  padding-block: 0 calc(88px + env(safe-area-inset-bottom, 0px));
  padding-inline: max(20px, env(safe-area-inset-left, 0px)) 76px;
}
.ap-cat {
  align-self: flex-start; padding: 3px 9px; border-radius: 4px; background: #c1272d; color: #fff;
  font: 800 12px var(--font-ui); letter-spacing: .05em; text-transform: uppercase;
}
.ap-title { margin: 0; font: 900 clamp(24px, 7vw, 34px)/1.15 var(--font-heading); text-wrap: balance; }
[dir="rtl"] .ap-title { font-family: var(--font-ui); line-height: 1.35; }
.ap-title a { color: #fff; }
.ap-desc { margin: 0; font: 400 15px/1.5 var(--font-ui); color: rgba(255,255,255,.86); }
.ap-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; font: 600 13px var(--font-ui); color: rgba(255,255,255,.75); }
.ap-read { padding: 9px 16px; border-radius: 999px; background: #fff; color: #0a0a0a; font: 800 14px var(--font-ui); }
.ap-hint { display: flex; flex-direction: column; align-items: center; gap: 2px; margin-top: 4px; font: 600 11px var(--font-ui); color: rgba(255,255,255,.6); animation: ap-hint 1.8s ease-in-out infinite; }
@keyframes ap-hint { 50% { transform: translateY(-4px); } }
.ap-actions {
  position: absolute; inset-inline-end: 12px; bottom: calc(190px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; gap: 16px;
}
.ap-act {
  width: 48px; min-height: 48px; border: 0; border-radius: 24px; padding: 10px 0 6px; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  background: rgba(0,0,0,.38); color: #fff; backdrop-filter: blur(6px); font: 700 11px var(--font-ui);
}
.ap-like.on { color: #ff4d57; }
.ap-like.on svg { fill: currentColor; }
.ap-act:focus-visible, .app-tabs a:focus-visible, .app-tabs button:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.ap-end { justify-content: center; text-align: center; background: #0a0a0a; }
.ap-end .ap-body { align-items: center; margin: 0 auto; padding-inline: 24px; }
.ap-toast {
  position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 9500;
  padding: 10px 18px; border-radius: 999px; background: rgba(0,0,0,.85); color: #fff; font: 700 14px var(--font-ui);
}
@media (prefers-reduced-motion: reduce) { .ap-hint { animation: none; } }

/* Listes des onglets Rubriques et Plus */
.ap-list {
  min-height: 100dvh; box-sizing: border-box; color: #f5f5f5; background: #0a0a0a; overflow-y: auto;
  padding: calc(24px + env(safe-area-inset-top, 0px)) max(18px, env(safe-area-inset-right, 0px)) calc(100px + env(safe-area-inset-bottom, 0px)) max(18px, env(safe-area-inset-left, 0px));
}
body.ap-page:has(.ap-list) { overflow: auto; }
.ap-list h1 { margin: 0 0 18px; font: 900 28px var(--font-heading); }
.ap-list h2 { margin: 26px 0 10px; font: 800 13px var(--font-ui); letter-spacing: .06em; text-transform: uppercase; color: #9a9a9a; }
.ap-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ap-grid a {
  display: flex; flex-direction: column; justify-content: space-between; gap: 18px; min-height: 84px; padding: 14px;
  border-radius: 14px; background: #161616; border: 1px solid rgba(255,255,255,.08); color: #fff; font: 800 16px var(--font-ui);
}
.ap-grid small { font: 600 12px var(--font-ui); color: #9a9a9a; }
.ap-links { margin: 0; padding: 0; list-style: none; }
.ap-links a { display: block; padding: 15px 2px; border-bottom: 1px solid rgba(255,255,255,.08); color: #f5f5f5; font: 700 16px var(--font-ui); }
.ap-langs { display: flex; gap: 8px; }
.ap-langs a { padding: 9px 16px; border-radius: 999px; background: #1a1a1a; color: #ddd; font: 700 14px var(--font-ui); }
.ap-langs a.on { background: #c1272d; color: #fff; }

/* Barre d'onglets : sur /app, et dans l'application installée sur téléphone ou tablette */
.app-tabs {
  display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 8500;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  padding: 6px max(4px, env(safe-area-inset-right, 0px)) calc(6px + env(safe-area-inset-bottom, 0px)) max(4px, env(safe-area-inset-left, 0px));
  background: rgba(0,0,0,.9); backdrop-filter: blur(10px); border-top: 1px solid rgba(255,255,255,.1);
}
.app-tabs a, .app-tabs button {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 48px;
  border: 0; background: none; cursor: pointer; color: #a3a3a3; font: 600 11px var(--font-ui);
}
.app-tabs .on { color: #ff5a60; font-weight: 800; }
body.ap-page .app-tabs { display: grid; }
body.ap-page .cb-fab, body.ap-page .cb-pulse { display: none !important; }
@media (display-mode: standalone) and (max-width: 1024px) {
  .app-tabs { display: grid; }
  body { padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px)); }
  body.ap-page { padding-bottom: 0; }
  .cb-fab, .cb-pulse { display: none !important; }
  .site-footer { display: none; }
}

/* Invitation à installer */
.app-install { position: fixed; inset: 0; z-index: 9400; background: rgba(0,0,0,.55); display: flex; align-items: flex-end; }
.app-install[hidden] { display: none; }
.app-install-sheet {
  width: 100%; max-width: 560px; margin: 0 auto; box-sizing: border-box; color: #f5f5f5;
  background: #151515; border-radius: 22px 22px 0 0; border-top: 1px solid rgba(255,255,255,.12);
  padding: 22px 22px calc(24px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; gap: 14px; animation: ap-sheet .35s ease both;
}
@keyframes ap-sheet { from { transform: translateY(100%); } to { transform: none; } }
.app-install-head { display: flex; gap: 14px; align-items: center; }
.app-install-head img { border-radius: 14px; flex-shrink: 0; }
.app-install-head h2 { margin: 0; font: 900 20px var(--font-heading); }
[dir="rtl"] .app-install-head h2 { font-family: var(--font-ui); }
.app-install-head p { margin: 2px 0 0; font: 400 13px var(--font-ui); color: #a5a5a5; }
.app-install-sheet ul { margin: 0; padding-inline-start: 20px; font: 400 14px/1.7 var(--font-ui); }
.app-install-ios { margin: 0; padding: 10px 12px; border-radius: 10px; background: #1f1f1f; font: 400 13px/1.5 var(--font-ui); color: #d0d0d0; }
.app-install-btns { display: flex; gap: 10px; }
.app-install-btns button { flex: 1; min-height: 48px; border-radius: 12px; border: 1px solid rgba(255,255,255,.18); background: transparent; color: #d0d0d0; font: 700 15px var(--font-ui); cursor: pointer; }
.app-install-btns .primary { flex: 2; border: 0; background: #c1272d; color: #fff; font-weight: 800; }
.app-install-btns [hidden] { display: none; }

/* Boutons permanents « installer l'application » (pied de page, menu mobile) */
.app-install-badge {
  display: inline-flex; align-items: center; gap: 8px; min-width: 130px; padding: 8px 14px; cursor: pointer;
  background: #1a1a2e; border: 1px solid rgba(255,255,255,.15); border-radius: 8px; color: #fff;
  font: 700 14px var(--font-ui); line-height: 1.2; text-align: start; transition: border-color .2s;
}
.app-install-badge:hover, .app-install-badge:focus-visible { border-color: #C1272D; }
.app-install-badge small { display: block; font-size: 9px; font-weight: 400; color: rgba(255,255,255,.7); }
.nav-install { display: none; background: none; border: 0; cursor: pointer; font: inherit; text-align: start; color: #ff8a8f; }
@media (max-width: 1024px) { .nav-install { display: block; } }
.app-install-badge[hidden], .nav-install[hidden] { display: none; }
@media (display-mode: standalone) { .app-install-badge, .nav-install { display: none; } }
.app-install-store {
  display: block; padding: 13px; border-radius: 12px; text-align: center;
  background: #fff; color: #0a0a0a; font: 800 15px var(--font-ui);
}
.app-install-store[hidden] { display: none; }

/* ══════════════════════════════════════════════════════════════
   Page contact (contact.php) — couleurs du thème, lisible en sombre comme en clair
   ══════════════════════════════════════════════════════════════ */
.ct-page { max-width: 1040px; margin: 36px auto 64px; font-family: var(--font-ui); }
.ct-head { margin-bottom: 26px; }
.ct-head h1 { margin: 0 0 6px; font: 900 clamp(28px, 4vw, 38px)/1.15 var(--font-heading); color: var(--text); }
[dir="rtl"] .ct-head h1 { font-family: var(--font-ui); }
.ct-head p { margin: 0; color: var(--text-muted); font-size: 16px; }
.ct-head h1::after { content: ''; display: block; width: 56px; height: 4px; margin-top: 12px; border-radius: 2px; background: var(--red); }

.ct-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.ct-side { display: flex; flex-direction: column; gap: 20px; }
.ct-card { background: var(--surface); border: 1px solid var(--border2); border-radius: 14px; padding: 24px; color: var(--text); }
.ct-h2 { margin: 0 0 18px; font: 800 17px var(--font-ui); color: var(--text); }
.ct-sub { margin: -10px 0 16px; font-size: 13px; color: var(--text-muted); }

.ct-form { display: flex; flex-direction: column; gap: 16px; }
.ct-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.ct-field { display: flex; flex-direction: column; gap: 6px; }
.ct-field > span { font-size: 14px; font-weight: 700; color: var(--text); }
.ct-field b, .ct-req b { color: #ff5a60; }
.ct-field input, .ct-field textarea {
  width: 100%; padding: 12px 14px; border-radius: 10px; font: 400 15px var(--font-ui);
  background: var(--surface2); color: var(--text); border: 1px solid var(--border2);
  transition: border-color .15s, box-shadow .15s;
}
.ct-field textarea { resize: vertical; min-height: 160px; line-height: 1.55; }
.ct-field input:focus, .ct-field textarea:focus { outline: none; border-color: var(--red); box-shadow: 0 0 0 3px rgba(193,39,45,.25); }
.ct-field input:user-invalid, .ct-field textarea:user-invalid { border-color: #ef4444; }
.ct-count { align-self: flex-end; font-size: 12px; color: var(--text-muted); }
.ct-count.warn { color: #ff5a60; }

.ct-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.ct-btn {
  display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 26px; border: 0; border-radius: 10px;
  background: var(--red); color: #fff; font: 800 15px var(--font-ui); cursor: pointer; transition: background .15s;
}
.ct-btn:hover { background: var(--red-dark); }
.ct-btn:disabled { opacity: .6; cursor: wait; }
.ct-btn:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; }
[dir="rtl"] .ct-btn svg { transform: scaleX(-1); }
.ct-req { font-size: 12px; color: var(--text-muted); }
.ct-result { padding: 14px 16px; border-radius: 10px; font-size: 14px; font-weight: 700; }
.ct-result.ok  { background: rgba(34,197,94,.12); border: 1px solid rgba(34,197,94,.4); color: #4ade80; }
.ct-result.err { background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.4); color: #f87171; }
[data-theme="light"] .ct-result.ok  { color: #15803d; }
[data-theme="light"] .ct-result.err { color: #b91c1c; }

.ct-info { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 16px; }
.ct-info li { display: flex; gap: 12px; align-items: center; }
.ct-ico { flex-shrink: 0; width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; background: rgba(193,39,45,.15); color: #ff5a60; }
.ct-info small { display: block; font-size: 12px; color: var(--text-muted); }
.ct-info a, .ct-info span { font-size: 15px; font-weight: 700; color: var(--text); word-break: break-word; }
.ct-info a:hover { color: #ff5a60; }

.ct-socials { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ct-social {
  display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 10px; border-radius: 10px;
  background: var(--surface2); border: 1px solid var(--border); color: var(--text); transition: border-color .15s, transform .15s;
}
.ct-social:hover { border-color: var(--red); transform: translateY(-1px); }
.ct-social-ico { flex-shrink: 0; width: 34px; height: 34px; border-radius: 9px; display: flex; align-items: center; justify-content: center; }
.ct-social-txt { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.ct-social-txt strong { font-size: 14px; }
.ct-social-txt small { font-size: 11px; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 900px) {
  .ct-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .ct-page { margin-top: 22px; }
  .ct-card { padding: 18px; }
  .ct-row { grid-template-columns: 1fr; }
  .ct-btn { width: 100%; justify-content: center; }
}
