/* ================================================================
   AGSP — GLOBAL CSS
   Association Guinéenne de Sciences Politiques
   Design : Editorial Swiss Brutalist · Blue #1239DB
   ================================================================ */

/* ── FONTS ────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,700;0,900;1,400;1,700&family=Barlow:wght@300;400;500;600;700;900&family=Barlow+Condensed:wght@600;700;800;900&family=Space+Mono:wght@400;700&display=swap');

/* ── VARIABLES ────────────────────────────────────────────────── */
:root {
  --ivory:      #F5F2EC;
  --white:      #FFFFFF;
  --ink:        #0C0C0C;
  --ink-mid:    #2A2A2A;
  --ink-soft:   #5A5A5A;
  --ink-mute:   #A0A0A0;
  --blue:       #1239DB;
  --blue-dark:  #0B2BA8;
  --blue-xdark: #071D72;
  --blue-light: #E8ECFB;
  --blue-mute:  rgba(18,57,219,0.08);
  --rule:       rgba(12,12,12,0.12);
  --col:        1px solid var(--rule);
  --col-blue:   2px solid var(--blue);
  --f-disp:     'Playfair Display', Georgia, serif;
  --f-cond:     'Barlow Condensed', sans-serif;
  --f-body:     'Barlow', sans-serif;
  --f-mono:     'Space Mono', monospace;
  --nav-h:      112px; /* edition-bar 36px + masthead 72px + rule 4px */
}

/* ── RESET ────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--f-body);
  background: var(--ivory);
  color: var(--ink);
  overflow-x: hidden;
}
::selection { background: var(--blue); color: white; }
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--ivory); }
::-webkit-scrollbar-thumb { background: var(--blue); border-radius: 3px; }
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
ul { list-style: none; }
button { cursor: pointer; border: none; font: inherit; }

/* ── EDITION BAR ──────────────────────────────────────────────── */
.edition-bar {
  background: var(--ink);
  color: white;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  position: sticky;
  top: 0;
  z-index: 900;
  border-bottom: 2px solid var(--blue);
}
.eb-left  { display: flex; align-items: center; gap: 20px; }
.eb-sep   { color: rgba(255,255,255,0.25); }
.eb-live  { display: flex; align-items: center; gap: 6px; font-weight: 700; color: var(--blue); }
.eb-live::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--blue); display: inline-block; animation: blink 1.5s infinite; }
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0.2} }
.eb-right { display: flex; gap: 20px; opacity: 0.6; }
.eb-right a:hover { opacity: 1; color: white; }

/* ── MASTHEAD ─────────────────────────────────────────────────── */
.masthead {
  background: var(--white);
  border-bottom: 4px solid var(--blue);
  position: sticky;
  top: 36px;
  z-index: 800;
  transition: box-shadow 0.25s;
}
.masthead.raised { box-shadow: 0 4px 24px rgba(0,0,0,0.1); }
.masthead-inner {
  display: flex;
  align-items: stretch;
  height: 72px;
  max-width: 1440px;
  margin: 0 auto;
  border-left: var(--col);
  border-right: var(--col);
}
.masthead-logo {
  display: flex;
  align-items: center;
  padding: 0 28px;
  border-right: var(--col);
  flex-shrink: 0;
}
.logo-img-nav {
  height: 52px;
  width: auto;
  object-fit: contain;
}
.nav-sections { display: flex; flex: 1; align-items: stretch; }
.nav-item {
  display: flex;
  align-items: center;
  padding: 0 20px;
  border-right: var(--col);
  font-family: var(--f-cond);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color 0.18s, background 0.18s;
  position: relative;
}
.nav-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.22s ease;
}
.nav-item:hover { color: var(--ink); background: rgba(18,57,219,0.03); }
.nav-item:hover::after { transform: scaleX(1); }
.nav-item.active { color: var(--blue); }
.nav-item.active::after { transform: scaleX(1); }
.nav-cta-cell {
  display: flex;
  align-items: center;
  padding: 0 24px;
  margin-left: auto;
  border-left: var(--col);
  flex-shrink: 0;
}
.hamburger-cell {
  display: none;
  align-items: center;
  padding: 0 20px;
  border-left: var(--col);
  cursor: pointer;
}
.hb-icon { display: flex; flex-direction: column; gap: 5px; }
.hb-icon span { display: block; width: 22px; height: 1.5px; background: var(--ink); transition: all 0.25s; }

/* Mobile menu */
.mobile-nav {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: var(--white);
  z-index: 700;
  flex-direction: column;
  padding: 100px 32px 40px;
  gap: 0;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  display: block;
  padding: 18px 0;
  border-bottom: var(--col);
  font-family: var(--f-cond);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
}
.mobile-nav a:hover, .mobile-nav a.active { color: var(--blue); }
.mobile-close {
  position: absolute;
  top: 24px;
  right: 24px;
  font-size: 28px;
  cursor: pointer;
  color: var(--ink);
  background: none;
  border: none;
}

/* ── BOUTONS ──────────────────────────────────────────────────── */
.btn-blue {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  background: var(--blue);
  color: white;
  font-family: var(--f-cond);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}
.btn-blue:hover { background: var(--blue-dark); transform: translateY(-1px); }

.btn-ink {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  background: var(--ink);
  color: white;
  font-family: var(--f-cond);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: background 0.2s;
}
.btn-ink:hover { background: var(--ink-mid); }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 22px;
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--rule);
  font-family: var(--f-cond);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: all 0.2s;
}
.btn-ghost:hover { border-color: var(--ink); background: rgba(0,0,0,0.04); }

/* ── LAYOUT UTILITAIRES ──────────────────────────────────────── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.section-rule { height: 1px; background: var(--rule); }
.section-rule.blue { background: var(--blue); height: 2px; }

/* ── SECTION HEADER ──────────────────────────────────────────── */
.sec-eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 16px;
}
.sec-tag-blue {
  background: var(--blue);
  color: white;
  padding: 2px 8px;
  font-size: 9px;
  font-weight: 700;
}
.sec-num { font-family: var(--f-mono); font-size: 10px; color: var(--ink-mute); }
.sec-rule { width: 40px; height: 2px; background: var(--blue); }
.sec-h2 {
  font-family: var(--f-disp);
  font-size: 42px;
  font-weight: 900;
  color: var(--ink);
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.sec-h2 em { font-style: italic; color: var(--blue); }
.sec-header-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: end;
  padding: 48px 0 32px;
  border-bottom: var(--col);
  margin-bottom: 40px;
}
.sec-desc-col p { font-size: 15px; color: var(--ink-soft); line-height: 1.72; }

/* ── PAGE HERO (interne) ─────────────────────────────────────── */
.page-hero {
  background: var(--white);
  border-bottom: var(--col);
  padding: 56px 0 48px;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--blue);
}
.ph-inner {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 48px;
  align-items: end;
}
.ph-num {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 12px;
}
.ph-rule { width: 40px; height: 3px; background: var(--blue); margin-bottom: 20px; }
.ph-title {
  font-family: var(--f-disp);
  font-size: clamp(36px, 5vw, 64px);
  font-weight: 900;
  color: var(--ink);
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}
.ph-title em { font-style: italic; color: var(--blue); }
.ph-desc {
  font-size: 16px;
  color: var(--ink-soft);
  line-height: 1.68;
  max-width: 520px;
}
.ph-breadcrumb {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--ink-mute);
  letter-spacing: 0.06em;
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.ph-breadcrumb a { color: var(--ink-mute); }
.ph-breadcrumb a:hover { color: var(--blue); }
.ph-breadcrumb span { color: var(--blue); }
.ph-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-end;
}
.ph-stat {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}
.ph-stat-val {
  font-family: var(--f-cond);
  font-size: 48px;
  font-weight: 900;
  color: var(--ink);
  line-height: 1;
}
.ph-stat-val em { color: var(--blue); font-style: normal; }
.ph-stat-lbl {
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--ink-mute);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ── CARDS PUBLICATION ───────────────────────────────────────── */
.pub-card {
  background: var(--white);
  border: var(--col);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: background 0.2s;
  position: relative;
  overflow: hidden;
}
.pub-card::after {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--blue);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.25s ease;
}
.pub-card:hover { background: rgba(18,57,219,0.03); }
.pub-card:hover::after { transform: scaleY(1); }
.pub-card.featured { background: var(--blue); color: white; }
.pub-card.featured .pc-cat { color: rgba(255,255,255,0.6); }
.pub-card.featured .pc-title { color: white; font-size: 24px; }
.pub-card.featured .pc-desc { color: rgba(255,255,255,0.8); }
.pub-card.featured .pc-read { color: rgba(255,255,255,0.6); }
.pub-card.featured::after { background: white; }
.pc-meta { display: flex; align-items: center; gap: 12px; }
.pc-cat {
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
  font-weight: 700;
}
.pc-date {
  font-family: var(--f-mono);
  font-size: 9px;
  color: var(--ink-mute);
}
.pc-title {
  font-family: var(--f-disp);
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.3;
}
.pc-desc { font-size: 13px; color: var(--ink-soft); line-height: 1.65; flex: 1; }
.pc-read {
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  color: var(--ink-mute);
  display: flex;
  align-items: center;
  gap: 4px;
  transition: gap 0.2s;
}
.pub-card:hover .pc-read { gap: 8px; color: var(--blue); }

/* ── BADGES / TAGS ───────────────────────────────────────────── */
.tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  font-family: var(--f-mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--blue-light);
  color: var(--blue-xdark);
  border: 1px solid var(--blue);
}
.tag.dark { background: var(--ink); color: white; border-color: var(--ink); }
.tag.outline { background: transparent; color: var(--ink-soft); border-color: var(--rule); }

/* ── TICKER ──────────────────────────────────────────────────── */
.ticker-wrap {
  background: var(--blue);
  overflow: hidden;
  padding: 8px 0;
  border-bottom: var(--col);
}
.ticker-inner {
  display: flex;
  align-items: center;
  gap: 0;
}
.ticker-label {
  background: var(--ink);
  color: white;
  padding: 4px 16px;
  font-family: var(--f-mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
  margin-right: 20px;
}
.ticker-track {
  overflow: hidden;
  flex: 1;
}
.ticker-text {
  display: inline-block;
  white-space: nowrap;
  font-family: var(--f-mono);
  font-size: 10px;
  color: white;
  letter-spacing: 0.04em;
  animation: ticker 35s linear infinite;
}
@keyframes ticker { from{transform:translateX(100vw)} to{transform:translateX(-100%)} }

/* ── FOOTER ──────────────────────────────────────────────────── */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.6);
  border-top: 4px solid var(--blue);
}
.footer-main {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  max-width: 1440px;
  margin: 0 auto;
}
.footer-col {
  padding: 48px 40px;
  border-right: 1px solid rgba(255,255,255,0.07);
}
.footer-col:last-child { border-right: none; }
.footer-logo-img {
  height: 44px;
  width: auto;
  object-fit: contain;
  filter: brightness(10);
  opacity: 0.9;
  margin-bottom: 20px;
}
.footer-desc {
  font-size: 13px;
  line-height: 1.75;
  margin-bottom: 24px;
  max-width: 280px;
}
.footer-tagline {
  font-family: var(--f-disp);
  font-style: italic;
  font-size: 13px;
  color: rgba(255,255,255,0.35);
  border-left: 2px solid var(--blue);
  padding-left: 12px;
}
.footer-col-title {
  font-family: var(--f-mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  margin-bottom: 20px;
}
.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links a {
  font-size: 13px;
  color: rgba(255,255,255,0.55);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s;
}
.footer-links a:hover { color: white; }
.footer-links a::before { content: '—'; font-size: 10px; color: var(--blue); flex-shrink: 0; }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 40px;
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.25);
  max-width: 1440px;
  margin: 0 auto;
}
.footer-socials { display: flex; gap: 12px; }
.footer-socials a {
  width: 30px; height: 30px;
  border: 1px solid rgba(255,255,255,0.15);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  transition: all 0.2s;
}
.footer-socials a:hover { border-color: var(--blue); color: var(--blue); background: rgba(18,57,219,0.1); }

/* ── BARRES DE RÉSULTATS ─────────────────────────────────────── */
.result-bar { display: flex; flex-direction: column; gap: 5px; }
.rb-head { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-soft); }
.rb-head strong { color: var(--ink); font-weight: 700; font-family: var(--f-cond); font-size: 14px; }
.rb-track { height: 4px; background: rgba(0,0,0,0.07); }
.rb-fill { height: 100%; background: var(--blue); transform-origin: left; animation: barIn 1.5s ease forwards; }
@keyframes barIn { from{transform:scaleX(0)} to{transform:scaleX(1)} }

/* ── RESPONSIVE ──────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .footer-main { grid-template-columns: 1fr 1fr; }
  .ph-inner { grid-template-columns: 1fr; gap: 24px; }
  .ph-side { align-items: flex-start; flex-direction: row; }
  .sec-header-row { grid-template-columns: 1fr; gap: 16px; }
}

@media (max-width: 768px) {
  :root { --nav-h: 108px; }
  .edition-bar { display: none; }
  .masthead { top: 0; }
  .nav-sections, .nav-cta-cell { display: none; }
  .hamburger-cell { display: flex; }
  .footer-main { grid-template-columns: 1fr; }
  .footer-col { border-right: none; border-bottom: 1px solid rgba(255,255,255,0.07); padding: 32px 24px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; padding: 18px 24px; }
  .sec-h2 { font-size: 28px; }
  .ph-title { font-size: 32px; }
}
