/*
Theme Name: Belge.Media DarkMag
Theme URI: https://belge.media
Author: Saad Van Nassouwe
Author URI: https://belge.media/auteur/saad-van-nassouwe/
Description: Thème magazine dark/classy optimisé SEO et AdSense pour Belge.Media
Version: 2.3
License: GNU GPL v2 or later
Text Domain: belgemedia
*/

/* === GLOBAL === */
body {
  background: #0b1622;
  color: #e6edf5;
  font-family: "Poppins", sans-serif;
  margin: 0;
}

a {
  color: #e41921;
  text-decoration: none;
  transition: 0.3s;
}
a:hover { color: #fff; }

h1,h2,h3,h4,h5,h6 {
  color: #e41921;
  margin: 0 0 12px;
  font-weight: 600;
}

h1 { font-size: 24px; }
h2 { font-size: 20px; }
h3 { font-size: 18px; }
h4 { font-size: 16px; }
h5 { font-size: 14px; }
h6 { font-size: 13px; }

.container {
  width: 92%;
  max-width: 1200px;
  margin: 0 auto;
  box-sizing: border-box;
}

figure { margin: 0; }

/* === HEADER === */
header.site-header {
  background: #122235;
  padding: 12px 20px;
  border-bottom: 1px solid #294766;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 1000;
}

.site-branding {
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-logo {
  width: 38px;
  height: auto;
  display: block;
}

.site-title-text {
  font-size: 30px;
  font-weight: 500;
  color: #e41921;
  line-height: 1;
}
.site-title-text:hover { color: #fff; }

/* === NAVIGATION === */
.main-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 70%;
}
.main-nav ul {
  list-style: none;
  display: flex;
  gap: 16px;
  margin: 0;
  padding: 0;
}
.main-nav a { color: #e41921; }
.main-nav a:hover { color: #fff; }

.menu-toggle {
  display: none;
  font-size: 26px;
  cursor: pointer;
  color: #e41921;
  background: none;
  border: none;
}
/* === TITRE PRINCIPAL (home/cat/tag) === */
.container > h1 {
  margin: 20px 0 15px;
  font-size: 24px;
  text-align: center;
}
.container > h1 small {
  font-size: 0.5em;
  color: #9bb3cc;
  margin-left: 8px;
}

/* === ARTICLES GRID === */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin: 15px 0;
}
.articles-grid article {
  background: #122235;
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}
.articles-grid article:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}
.articles-grid article h2 {
  margin-bottom: 6px;
}
.articles-grid article p {
  margin-top: 0;
}
/* === VIGNETTES (16/9) === */
.thumb,
.single-thumb {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  overflow: hidden;
  border-radius: 6px;
  margin-bottom: 12px;
  background: #09121c;
}
.thumb img,
.single-thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* === HERO === */
.hero-article {
  position: relative;
  margin: 15px 0 30px;
  border-radius: 10px;
  overflow: hidden;
}
.hero-thumb img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
  filter: brightness(70%);
  transition: transform 0.4s ease;
}
.hero-article:hover .hero-thumb img { transform: scale(1.05); }
.hero-content {
  position: absolute;
  bottom: 15px;
  left: 15px;
  right: 15px;
  color: #fff;
  text-shadow: 0 2px 6px rgba(0,0,0,0.8);
}
.hero-content h1,
.hero-content h2 {
  font-size: 22px;
  margin: 0 0 6px;
  color: #e41921;
}
.hero-content p { font-size: 15px; margin: 0; }

/* === PAGINATION === */
.articles-pagination {
  margin: 15px 0;
  text-align: center;
}
.articles-pagination .nav-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.articles-pagination .page-numbers {
  flex: 0 0 auto;
  padding: 6px 10px;
  background: #1e3550;
  border-radius: 4px;
  color: #ff4d6d;
  font-size: 14px;
  white-space: nowrap;
}
.articles-pagination .page-numbers:hover {
  background: #294766;
  color: #fff;
}
.articles-pagination .page-numbers.current {
  background: #e41921;
  color: #0b1622;
  font-weight: bold;
}

/* === FOOTER === */
.site-footer {
  background: #122235;
  color: #9bb3cc;
  text-align: center;
  padding: 18px;
  margin-top: 30px;
  font-size: 14px;
}

.footer-menu {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 20px;
  margin: 10px 0 0;
  padding: 0;
}
.footer-menu li { display: inline; }
.footer-menu a {
  color: #e41921;
  text-decoration: none;
  font-size: 14px;
}
.footer-menu a:hover { color: #fff; }

/* === BOUTON REMONTER EN HAUT === */
.back-to-top {
  position: fixed;
  bottom: 25px;
  right: 25px;
  width: 45px;
  height: 45px;
  background: #e41921;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 4px 10px rgba(0,0,0,0.4);
  transition: opacity 0.3s, transform 0.3s;
  opacity: 0;
  pointer-events: none;
  z-index: 999;
}
.back-to-top::before {
  content: "";
  display: block;
  width: 12px;
  height: 12px;
  border-left: 3px solid #0b1622;
  border-bottom: 3px solid #0b1622;
  transform: rotate(135deg);
}
.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
}
.back-to-top:hover {
  background: #fff;
  transform: translateY(-3px);
}

/* === MENU MOBILE === */
@media (max-width: 768px) {
  .menu-toggle { display: block; }
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #0b1622;
    border-top: 1px solid #1e3550;
    z-index: 999;
    flex-direction: column;
  }
  .main-nav.active { display: flex; }
  .main-nav a {
    display: block;
    padding: 12px 16px;
    color: #e41921;
  }
  .main-nav a:hover {
    background: #1e3550;
    color: #fff;
  }
}

/* === MENU DESKTOP === */
@media (min-width: 769px) {
  .menu-toggle { display: none; }
  .main-nav { display: flex; background: transparent; border: 0; position: static; }
  .main-nav ul { flex-direction: row; gap: 20px; }
}
/* === SINGLE AVEC SIDEBAR === */
.single-layout {
  display: flex;
  flex-wrap: wrap;
  gap: 25px;
  align-items: flex-start;
  margin-top: 20px;
}

.single-article {
  flex: 1 1 700px;
  background: #122235;
  padding: 18px;
  border-radius: 8px;
  border: 1px solid #1e3550;
  box-sizing: border-box;
}

.single-header h1 {
  color: #e41921;
  font-size: 24px;
  margin-bottom: 10px;
}

.single-header .meta {
  font-size: 13px;
  color: #8aa0b6;
  margin-bottom: 15px;
}

.single-content p {
  line-height: 1.7;
  margin-bottom: 0.8em;
}

.single-footer {
  margin-top: 30px;
  border-top: 1px solid #1e3550;
  padding-top: 15px;
}

.post-nav {
  display: flex;
  justify-content: space-between;
}

/* === SIDEBAR === */
.sidebar {
  flex: 0 0 300px;
  background: #122235;
  padding: 15px;
  border-radius: 8px;
  border: 1px solid #1e3550;
  color: #a8c0d8;
  position: sticky;
  top: 25px;
  height: fit-content;
  box-sizing: border-box;
}

.sidebar h3 {
  color: #e41921;
  margin-bottom: 10px;
  font-size: 16px;
  border-bottom: 1px solid #1e3550;
  padding-bottom: 6px;
}

.widget { margin-bottom: 20px; }

/* === AUTEUR === */
.author-box {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
}
.author-photo {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #1e3550;
}

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .single-layout {
    flex-direction: column;
  }
  .sidebar {
    width: 100%;
    margin-top: 20px;
    position: static;
  }
}
/* === CORRECTION ALIGNEMENT LOGO + TITRE === */
.site-branding {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start;
  gap: 10px;
  flex-wrap: nowrap !important;
}

.site-logo {
  width: 38px;
  height: auto;
  display: block;
  flex-shrink: 0;
}

.site-title-text {
  font-size: 30px;
  font-weight: 500;
  color: #e41921;
  line-height: 1;
  white-space: nowrap;
  display: flex;
  align-items: center;
}
.site-title-text:hover { color: #ffffff; }

/* === MENU NAVIGATION === */
.main-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 20px;
  flex-wrap: nowrap;
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 18px;
  margin: 0;
  padding: 0;
}

/* === MENU BURGER (MOBILE) === */
@media (max-width: 768px) {
  .main-nav {
    display: none;
    flex-direction: column;
    align-items: center;
    background: #0b1622;
    border-top: 1px solid #1e3550;
    width: 100%;
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 999;
    padding: 10px 0;
  }

  .main-nav.active {
    display: flex !important;
    animation: fadeIn 0.3s ease-in-out;
  }

  .main-nav ul {
    flex-direction: column;
    width: 100%;
    text-align: center;
  }

  .main-nav li {
    width: 100%;
    border-top: 1px solid #1e3550;
  }

  .main-nav li:first-child {
    border-top: none;
  }

  .main-nav a {
    display: block;
    padding: 14px;
    font-size: 16px;
    color: #e41921;
  }

  .main-nav a:hover {
    background: #13263a;
    color: #ffffff;
  }

  @keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

/* === HEADER ALIGNEMENT GLOBAL === */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  background: #0b1622;
  padding: 12px 20px;
  border-bottom: 1px solid #1e3550;
}

.site-branding {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 10px;
}

.logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.site-logo {
  width: 38px;
  height: auto;
  display: block;
  flex-shrink: 0;
}

.site-title-text {
  font-size: 40px;
  font-weight: 500;
  color: #e41921;
  line-height: 1;
  white-space: nowrap;
}
.site-title-text:hover { color: #ffffff; }

/* === MENU BURGER MOBILE (textes à gauche) === */
@media (max-width: 768px) {
  .main-nav {
    display: none;
    flex-direction: column;
    align-items: flex-start; /* Alignement à gauche */
    justify-content: flex-start;
    background: #0b1622;
    border-top: 1px solid #1e3550;
    width: 100%;
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 999;
    padding: 0;
  }

  .main-nav.active {
    display: flex;
    animation: fadeIn 0.3s ease-in-out;
  }

  .main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
  }

  .main-nav li {
    width: 100%;
    border-top: 1px solid #1e3550;
  }

  .main-nav li:first-child {
    border-top: none;
  }

  .main-nav a {
    display: block;
    width: 100%;
    padding: 14px 20px;
    font-size: 16px;
    color: #e41921;
    text-align: left;
  }

  .main-nav a:hover {
    background: #13263a;
    color: #ffffff;
  }
}

/* === SIDEBAR RESPONSIVE (fix overflow) === */
.sidebar {
  background: #122235;
  padding: 15px;
  border-radius: 8px;
  border: 1px solid #1e3550;
  color: #a8c0d8;
  position: sticky;
  top: 25px;
  height: fit-content;
  box-sizing: border-box;
  max-width: 100%;
}

@media (max-width: 900px) {
  .single-layout {
    flex-direction: column;
  }
  .sidebar {
    position: static;
    margin-top: 20px;
    width: 100%;
  }
}

/* Animation */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}

.adsbygoogle {
  background-color: #0b1622 !important;
  color: #cfe2f3 !important;
  border: 0px solid #1e3550 !important;
  border-radius: 8px;
  padding: 10px;
}
.adsbygoogle a { color: #e41921 !important; }

body::after {
  content: "";
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 90px;
  background: linear-gradient(to top, rgba(11,22,34,0.9), transparent);
  pointer-events: none;
  z-index: 10;
}

.thumb, .post-thumb, .featured-image, .wp-post-image {
  position: relative;
}

article a figure,
article a .thumb,
article a .post-thumb,
article a .featured-image {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
}

/* CTA "Lire l’article" */
article a figure::after,
article a .thumb::after,
article a .post-thumb::after,
article a .featured-image::after {
  content: "Lire l’article";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .2px;
  color: #ffffff;
  background: rgba(11,22,34,.65);
  border: 1px solid rgba(255,77,109,.35);
  border-radius: 999px;
  pointer-events: none;
  backdrop-filter: blur(3px);
  transition: transform .2s ease, background .2s ease, opacity .2s ease;
  opacity: .95;
}

/* petit effet hover */
article a:hover figure::after,
article a:hover .thumb::after,
article a:hover .post-thumb::after,
article a:hover .featured-image::after {
  transform: translate(-50%, -50%) scale(1.06);
  background: rgba(11,22,34,.85);
}


/* ===============================
   GRID PRINCIPAL
=============================== */
.rencontre-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

/* ===============================
   SIDEBAR
=============================== */
.rencontre-sidebar {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

/* ===============================
   PROFIL
=============================== */
.profil {
    text-align: center;
}

/* ===============================
   IMAGE CARRÉ (clé du problème)
=============================== */
.profil a {
    display: block;
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 8px;
}

.profil img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ===============================
   NOM
=============================== */
.profil .name {
    display: block;
    margin-top: 6px;
    font-size: 14px;
    color: #fff;
}

/* ===============================
   ❌ SUPPRIME "Lire l'article"
=============================== */
.profil a::after,
.profil a::before,
.profil .thumb::after,
.profil figure::after {
    display: none !important;
    content: none !important;
}

/* ===============================
   MOBILE
=============================== */
@media (max-width: 768px) {
    .rencontre-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}


.rencontre-hook {
    font-size: 22px;
    font-weight: bold;
    color: #fff;
    margin-bottom: 0px;
}



/* ===== SENIFLIRT PROFILES GRID ===== */

.sf-profiles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.sf-profile-item {
    text-align: center;
}

.sf-profile-item img {
    width: 100%;
    border-radius: 10px;
    transition: transform 0.2s ease;
}

.sf-profile-item img:hover {
    transform: scale(1.05);
}

.sf-profile-name {
    display: block;
    margin-top: 6px;
    font-size: 14px;
    color: #fff;
}


.sf-chat-box {
    margin-top: 20px;
    max-width: 400px;
}

.sf-fake-message {
    background: #1a2a3a;
    padding: 10px 12px;
    border-radius: 10px;
    color: #fff;
    font-size: 14px;
    margin-bottom: 10px;
}

.sf-input {
    width: 95%;
    height: 70px;
    border-radius: 8px;
    border: none;
    padding: 10px;
    font-size: 14px;
    margin-bottom: 10px;
}

.sf-send-btn {
    width: 97%;
    background: #e41921;
    color: #fff;
    border: none;
    padding: 10px;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.2s;
}

.sf-send-btn:hover {
    background: #b3151b;
}

/* wrapper global */
.sf-chat-wrapper {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    align-items: flex-start;
}

/* bloc photo */
.sf-chat-left img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 10px;
}

/* bloc droit */
.sf-chat-right {
    flex: 1;
}

/* mobile */
@media (max-width: 600px) {
    .sf-chat-wrapper {
        flex-direction: column;
        align-items: center;
    }

    .sf-chat-left img {
        width: 100px;
        height: 100px;
    }

    .sf-chat-right {
        width: 100%;
    }
}

@media (max-width: 600px) {

    .sf-chat-wrapper {
        flex-direction: column;
        align-items: stretch;
    }

    .sf-chat-left {
        width: 100%;
    }

    .sf-chat-left img {
        width: 100%;
        height: auto;
        border-radius: 12px;
    }

    .sf-chat-right {
        width: 100%;
        margin-top: 10px;
    }
}

.sf-profile-description {
    margin-top: 12px;
    padding: 12px;
    background: #16293b;
    border-radius: 10px;
    color: #ccc;
    font-size: 14px;
    line-height: 1.5;
}