/* SNGWIS - thème Somalie : bleu du drapeau (#4189DD) et blanc.
   Les couleurs sont des variables : changer ici pour modifier tout le site. */
:root {
    --so-primary: #4189DD;  /* bleu du drapeau */
    --so-nav:     #2B6CB8;  /* barre de menu (contraste suffisant avec le texte blanc) */
    --so-deep:    #1F5AA6;
    --so-dark:    #0d2747;  /* menus déroulants et pied de page */
    --so-soft:    #eaf2fc;
    --so-text:    #1b2a3a;
}

html, body { margin: 0; padding: 0; font-family: 'Segoe UI', Arial, sans-serif; }
body { top: 0 !important; background: #fff; color: var(--so-text); }

/* Google Translate : masquer les éléments natifs */
.goog-te-banner-frame, .skiptranslate, #google_translate_element, .goog-te-menu-value { display: none !important; }

/* ── Bandeau supérieur ─────────────────────────────────────────── */
.top-bar {
    position: relative;
    padding: 18px 20px;
    text-align: center;
    background: linear-gradient(270deg, var(--so-deep), var(--so-primary), var(--so-deep));
    background-size: 300% 300%;
    color: #fff;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 1px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.35);
    animation: soWater 12s ease infinite;
    overflow: visible;
}
.top-bar-title { display: inline-block; position: relative; overflow: hidden; }
.top-bar-title::after {
    content: '';
    position: absolute; top: 0; left: -150%;
    width: 70%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.7), transparent);
    animation: soShine 6s infinite;
}
@keyframes soWater { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
@keyframes soShine { 0% { left: -150%; } 100% { left: 180%; } }
@media (prefers-reduced-motion: reduce) {
    .top-bar, .top-bar-title::after { animation: none; }
}

/* Sélecteur de langue */
.language-box { position: absolute; right: 22px; top: 50%; transform: translateY(-50%); font-size: 14px; font-weight: 500; }
.language-dropdown { position: relative; display: inline-block; }
.language-dropdown .dropbtn { color: #fff; padding: 8px 12px; text-decoration: none; display: flex; align-items: center; gap: 7px; border-radius: 4px; }
.language-dropdown .dropbtn:hover { background: rgba(255,255,255,0.18); }
.language-dropdown .dropdown-content {
    display: none; position: absolute; right: 0; top: 100%;
    background: #fff; min-width: 130px; border-radius: 4px; z-index: 3000;
    box-shadow: 0 8px 18px rgba(0,0,0,0.25);
}
.language-dropdown:hover .dropdown-content, .language-dropdown:focus-within .dropdown-content { display: block; }
.language-dropdown .dropdown-content a {
    color: #000 !important; background: #fff; padding: 10px 14px; display: block;
    text-decoration: none; text-align: left; text-shadow: none !important; font-weight: 600;
}
.language-dropdown .dropdown-content a:hover { background: var(--so-nav); color: #fff !important; }

/* ── En-tête : identité + partenaires ──────────────────────────── */
.header { display: flex; justify-content: space-between; align-items: center; padding: 18px 28px; background: #fff; z-index: 999; gap: 20px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--so-dark); }
.logo { height: 64px; width: auto; border-radius: 4px; box-shadow: 0 1px 5px rgba(0,0,0,0.25); }
.brand-text strong { display: block; font-size: 1.1rem; line-height: 1.25; }
.brand-text small { display: block; font-size: 0.85rem; color: #4a5b6e; line-height: 1.3; }
.partner-logos { display: flex; align-items: center; gap: 18px; }
.partner-logos img { height: 48px; object-fit: contain; }

/* ── Barre de navigation ───────────────────────────────────────── */
.nav-bar { background-color: var(--so-nav); color: #fff; padding: 0; display: flex; align-items: center; z-index: 1001; position: relative; box-shadow: 0 3px 8px rgba(0,0,0,0.18); }
.nav-bar a { color: #fff; text-decoration: none; padding: 15px 12px; font-size: 14px; white-space: nowrap; display: inline-block; transition: background 0.25s ease; }
.nav-bar a:hover, .nav-bar a:focus-visible { background: rgba(255,255,255,0.18); }
.home-icon { background-color: var(--so-deep); padding: 15px 18px !important; }
#nav-menu { display: flex; flex-wrap: nowrap; align-items: center; flex: 1; }

.dropdown { position: relative; display: inline-block; }
.dropdown-content {
    display: none; position: absolute; top: 100%; left: 0;
    background-color: var(--so-dark); min-width: 230px; z-index: 2000;
    box-shadow: 0 8px 18px rgba(0,0,0,0.28);
}
.dropdown-content a { color: #fff !important; padding: 12px 16px; display: block; font-size: 13px; text-align: left; border-bottom: 1px solid rgba(255,255,255,0.08); }
.dropdown-content a:hover { background-color: var(--so-primary) !important; }
.dropdown:hover > .dropdown-content, .dropdown:focus-within > .dropdown-content { display: block; }

.hamburger { display: none; flex-direction: column; justify-content: center; align-items: center; background: none; border: none; cursor: pointer; padding: 14px 18px; margin-left: auto; gap: 5px; }
.hamburger span { display: block; width: 26px; height: 2px; background: #fff; border-radius: 2px; transition: all 0.3s; }

.content, #map { position: relative; z-index: 1; }

/* Recherche et pagination (utilisées par certaines pages) */
.search-bar { display: flex; align-items: center; }
.search-bar input[type="text"] { padding: 8px; border: none; border-radius: 4px 0 0 4px; width: 200px; margin: 10px; }
.search-bar button { padding: 8px 15px; background-color: var(--so-deep); border: none; color: #fff; border-radius: 0 4px 4px 0; cursor: pointer; margin: 10px; }
.pagination { margin-top: 20px; text-align: center; }
.pagination a { color: #000; padding: 8px 16px; text-decoration: none; transition: background-color .3s; border: 1px solid #ddd; margin: 0 4px; }
.pagination a.active { background-color: var(--so-nav); color: #fff; border: 1px solid var(--so-nav); }
.pagination a:hover:not(.active) { background-color: #ddd; }

/* ── Responsive ────────────────────────────────────────────────── */
@media screen and (max-width: 1024px) {
    .header { flex-wrap: wrap; gap: 14px; }
    .partner-logos { width: 100%; justify-content: center; }
}
@media screen and (max-width: 768px) {
    .top-bar { font-size: 18px; padding: 14px 10px 52px; }
    .language-box { top: auto; bottom: 8px; right: 50%; transform: translateX(50%); }
    .hamburger { display: flex; }
    #nav-menu { display: none; }
    #nav-menu.open { display: flex; flex-direction: column; align-items: flex-start; width: 100%; background: var(--so-nav); }
    #nav-menu a { display: block; width: 100%; padding: 12px 20px; border-bottom: 1px solid rgba(255,255,255,0.12); box-sizing: border-box; }
    #nav-menu .home-icon { padding: 12px 20px !important; }
    #nav-menu .dropdown { display: block; width: 100%; }
    #nav-menu .dropdown:hover > .dropdown-content { display: none; }
    #nav-menu .dropdown.open > .dropdown-content { display: block; }
    .dropdown-content { position: static !important; box-shadow: none; background: rgba(0,0,0,0.25) !important; }
    .dropdown-content a { padding-left: 36px !important; }
    .dropbtn::after { content: '  ▾'; font-size: 10px; }
    .dropdown.open .dropbtn::after { content: '  ▴'; }
    .nav-bar { flex-wrap: wrap; }
}
@media screen and (max-width: 480px) {
    .header { padding: 12px; }
    .logo { height: 44px; }
    .brand-text strong { font-size: 0.95rem; }
    .partner-logos img { height: 32px; }
}

/* ── Pied de page ──────────────────────────────────────────────── */
.gwis-footer { background-color: var(--so-dark); color: #cfd8e3; margin-top: 60px; font-family: 'Segoe UI', Arial, sans-serif; font-size: 0.88rem; line-height: 1.7; }
.gwis-footer-top { max-width: 1280px; margin: 0 auto; padding: 48px 32px 40px; display: grid; grid-template-columns: 280px 1fr 1fr 1fr; gap: 40px; }
.footer-brand img { height: 56px; width: auto; margin-bottom: 14px; border-radius: 4px; }
.footer-brand p { color: #b4c0ce; font-size: 0.83rem; margin: 0 0 18px; line-height: 1.7; }
.footer-social { display: flex; gap: 10px; flex-wrap: wrap; }
.footer-social a { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; text-decoration: none; overflow: hidden; transition: opacity 0.3s, transform 0.2s; }
.footer-social a:hover { opacity: 0.85; transform: scale(1.1); }
.footer-col h4 { color: #fff; font-size: 0.8rem; font-weight: 700; letter-spacing: 1px; margin: 0 0 14px; padding-bottom: 10px; border-bottom: 2px solid var(--so-primary); }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col ul li { margin-bottom: 7px; }
.footer-col ul li a { color: #b4c0ce; text-decoration: none; transition: color 0.2s; }
.footer-col ul li a:hover { color: #fff; }
.gwis-footer-divider { border: none; border-top: 1px solid rgba(255,255,255,0.1); margin: 0; }
.gwis-footer-bottom { max-width: 1280px; margin: 0 auto; padding: 16px 32px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; font-size: 0.8rem; color: #93a1b2; }
.footer-bottom-links { display: flex; flex-wrap: wrap; }
.footer-bottom-links a { color: #93a1b2; text-decoration: none; padding: 0 10px; border-right: 1px solid #3b4f68; transition: color 0.2s; }
.footer-bottom-links a:last-child { border-right: none; }
.footer-bottom-links a:hover { color: #fff; }
@media (max-width: 900px) {
    .gwis-footer-top { grid-template-columns: 1fr 1fr; gap: 28px; }
    .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
    .gwis-footer-top { grid-template-columns: 1fr; padding: 32px 20px; }
    .gwis-footer-bottom { flex-direction: column; text-align: center; padding: 16px 20px; }
    .footer-bottom-links { justify-content: center; }
}
