/*
Theme Name: Astra Child - Chroniques d'antan
Theme URI: https://www.chroniquesdantan.com
Description: Thème enfant Astra - Header identique à l'actuel
Author: Brigitte Billard
Template: astra
Version: 2.3.0
*/

/* ═══════════════════════════════════════════════════════════════
   VARIABLES
   ═══════════════════════════════════════════════════════════════ */
:root {
  --blue-primary:    #1a49a1;
  --blue-mid:        #2a5fc0;
  --gold:            #c9a84c;
  --white:           #ffffff;
  --text-dark:       #2c2824;
}

/* ═══════════════════════════════════════════════════════════════
   POLICES
   ═══════════════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&family=Montserrat:wght@300;400;500;600;700&family=Raleway:wght@400;500;600&display=swap');

body {
  font-family: 'Raleway', sans-serif;
  color: var(--text-dark);
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', sans-serif;
  color: var(--blue-primary);
}

/* ═══════════════════════════════════════════════════════════════
   HEADER — Identique à votre actuel
   ═══════════════════════════════════════════════════════════════ */

/* Masquer le header Astra */
.site-header {
  display: none;
}

/* Header personnalisé — JUSTE VOTRE IMAGE, rien d'autre */
.custom-header-chroniques {
  position: relative;
  height: auto;
  background: var(--white);
  border-bottom: 1px solid #e0e0e0;
}

/* Votre image bannière — c'est tout */
.custom-header-chroniques img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
}

/* On masque le contenu généré par le PHP */
.custom-header-content {
  display: none;
}

/* ═══════════════════════════════════════════════════════════════
   NAVIGATION
   ═══════════════════════════════════════════════════════════════ */
.custom-main-nav {
  background: var(--white);
  border-bottom: 1px solid #e0e0e0;
  padding: 1rem 2rem;
  text-align: center;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.custom-main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.8rem;
}

.custom-main-nav li {
  margin: 0;
  position: relative;
}

.custom-main-nav a {
  font-family: 'Raleway', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--blue-primary);
  padding: 0.3rem 0;
  position: relative;
  text-decoration: none;
  transition: color 0.3s;
  display: block;
  white-space: nowrap;
}

.custom-main-nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 1.5px;
  background: var(--gold);
  transition: width 0.3s;
}

.custom-main-nav a:hover {
  color: var(--blue-mid);
}

.custom-main-nav a:hover::after {
  width: 65%;
}

/* ─── Sous-menus déroulants ─── */
.custom-main-nav ul ul {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--white);
  border: 1px solid #e0e0e0;
  border-top: 2px solid var(--gold);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  padding: 0.5rem 0;
  display: none;
  flex-direction: column;
  gap: 0;
  z-index: 1000;
}

.custom-main-nav li:hover > ul {
  display: block;
}

.custom-main-nav ul ul li {
  width: 100%;
}

.custom-main-nav ul ul a {
  padding: 0.6rem 1.2rem;
  font-size: 0.78rem;
  text-align: left;
  white-space: normal;
}

.custom-main-nav ul ul a::after {
  display: none;
}

.custom-main-nav ul ul a:hover {
  background: rgba(26, 73, 161, 0.05);
}

/* Sous-sous-menus (3e niveau) */
.custom-main-nav ul ul ul {
  top: 0;
  left: 100%;
  margin-left: 1px;
}

/* ═══════════════════════════════════════════════════════════════
   LAYOUT — Sans sidebar
   ═══════════════════════════════════════════════════════════════ */
#secondary {
  display: none !important;
}

#primary {
  width: 100%;
  max-width: 100%;
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════════
   STYLES DE BASE
   ═══════════════════════════════════════════════════════════════ */
a {
  color: var(--blue-primary);
  transition: color 0.3s;
}

a:hover {
  color: var(--blue-mid);
}

.wp-block-button__link,
button[type="submit"] {
  background-color: var(--blue-primary) !important;
  color: var(--white) !important;
  border-radius: 2px !important;
  padding: 0.7rem 1.5rem !important;
  font-weight: 600;
  border: none !important;
}

.wp-block-button__link:hover,
button[type="submit"]:hover {
  background-color: var(--blue-mid) !important;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .custom-main-nav ul {
    gap: 0.4rem 1.2rem;
  }
}

@media (max-width: 480px) {
  .custom-main-nav ul {
    gap: 0.3rem 0.8rem;
  }
  
  .custom-main-nav a {
    font-size: 0.75rem;
  }
}
