/* ---------- Design tokens — Union pour la Continuité Nationale ---------- */
:root {
  --navy:        #0f1f3d;
  --navy-light:  #1f3f74;
  --navy-dim:    #2c3c5c;
  --red:         #a3121b;
  --red-light:   #c94a3e;
  --gold:        #a9822c;

  --bg:          #f7f5ee;
  --bg-2:        #efeadd;
  --bg-card:     #ffffff;
  --border:      rgba(15, 31, 61, 0.14);
  --border-hover:rgba(15, 31, 61, 0.38);

  --text:        #182238;
  --text-muted:  #4d5873;
  --text-dim:    #838da3;

  --grad-main:   linear-gradient(135deg, var(--navy-light), var(--navy));
  --grad-tricolor: linear-gradient(90deg, var(--navy) 0%, var(--navy) 32%, #ffffff 32%, #ffffff 66%, var(--red) 66%, var(--red) 100%);
  --shadow-soft: 0 10px 34px rgba(15, 31, 61, 0.08);
  --shadow-card: 0 4px 20px rgba(15, 31, 61, 0.06);

  --font-display: 'Marcellus', serif;
  --font-heading: 'Cormorant Garamond', serif;
  --font-body:    'EB Garamond', serif;

  --nav-height: 84px;
  --max-width: 1080px;
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 18px;
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-heading); font-weight: 600; margin: 0; color: var(--navy); }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; list-style: none; }

.wrap { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }

.tricolor-rule { height: 3px; width: 72px; background: var(--grad-tricolor); border-radius: 2px; }
.tricolor-bar { height: 4px; width: 100%; background: var(--grad-tricolor); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; min-height: var(--nav-height);
  background: rgba(247, 245, 238, .92); backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; width: 100%; gap: 20px; padding: 14px 0; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--navy); }
.brand-mark { width: 42px; height: 42px; flex: none; }
.brand-text { display: inline-block; font-family: var(--font-display); font-weight: 400; font-size: .82rem; line-height: 1.5; letter-spacing: .08em; color: var(--navy); }
.brand-sub { display: block; font-family: var(--font-body); font-size: .68rem; letter-spacing: .18em; text-transform: uppercase; color: var(--text-dim); margin-top: 2px; }

.primary-nav { display: flex; gap: 30px; align-items: center; }
.primary-nav a {
  text-decoration: none; color: var(--text-muted); font-family: var(--font-heading); font-weight: 600; font-size: 15px;
  letter-spacing: .03em; transition: color .2s ease; white-space: nowrap; position: relative;
}
.primary-nav a::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -6px; height: 2px;
  background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .2s ease;
}
.primary-nav a:hover, .primary-nav a.active { color: var(--navy); }
.primary-nav a:hover::after, .primary-nav a.active::after { transform: scaleX(1); }

.nav-toggle {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 40px; height: 40px; border: none; background: none; cursor: pointer; padding: 0;
}
.nav-toggle span { display: block; width: 100%; height: 2px; background: var(--navy); border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.cta-row { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 32px; border-radius: 3px; text-decoration: none;
  font-family: var(--font-heading); font-weight: 600; font-size: 16px; letter-spacing: .04em;
  border: 1px solid transparent; transition: all .25s var(--ease-smooth); cursor: pointer;
}
.btn-primary { background: var(--navy); color: #fff; box-shadow: var(--shadow-soft); }
.btn-primary:hover { background: var(--navy-light); transform: translateY(-1px); box-shadow: 0 14px 30px rgba(15,31,61,.16); }
.btn-ghost { color: var(--navy); border-color: var(--border-hover); background: rgba(255,255,255,.5); }
.btn-ghost:hover { border-color: var(--navy); background: #fff; }
.btn-red { background: var(--red); color: #fff; box-shadow: 0 10px 26px rgba(163,18,27,.22); }
.btn-red:hover { background: var(--red-light); transform: translateY(-1px); }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 80px 0 64px; text-align: center; overflow: hidden; }
.hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(ellipse 60% 50% at 50% 0%, rgba(31,63,116,.08), transparent 70%);
}
.hero-inner { max-width: 760px; margin: 0 auto; }
.kicker {
  display: inline-flex; align-items: center; gap: 10px;
  text-transform: uppercase; letter-spacing: .22em; font-size: 12px; color: var(--red);
  font-family: var(--font-heading); font-weight: 600; margin-bottom: 18px;
}
.hero-emblem { width: 88px; height: 88px; margin: 0 auto 26px; }
.hero-title {
  font-family: var(--font-display); font-weight: 400; color: var(--navy);
  font-size: clamp(2rem, 5.2vw, 3.4rem); letter-spacing: .01em; line-height: 1.15;
  margin-bottom: 22px;
}
.hero-sub { font-size: 1.18rem; color: var(--text-muted); max-width: 620px; margin: 0 auto 34px; }
.hero-motto { font-family: var(--font-heading); font-style: italic; font-size: 1.15rem; color: var(--navy); margin: 34px 0 0; }
.hero-motto span { color: var(--red); }

/* ---------- Sections ---------- */
.section { padding: 76px 0; position: relative; }
.section-alt { background: var(--bg-2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-navy { background: var(--navy); color: #eef1f7; }
.section-navy h2, .section-navy h3 { color: #fff; }
.section-navy .text-muted { color: rgba(238,241,247,.72); }
.section-head { max-width: 680px; margin: 0 auto 44px; text-align: center; }
.section-head.left { margin-left: 0; text-align: left; }
.section h2 { font-size: clamp(1.7rem, 3.2vw, 2.35rem); margin-bottom: 16px; }
.section .kicker { display: block; }
.prose { max-width: 720px; color: var(--text-muted); font-size: 1.05rem; }
.prose p:last-child { margin-bottom: 0; }
.prose.center { margin: 0 auto; text-align: center; }

/* ---------- Feature / principle grid ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 22px; margin-top: 36px; }
.feature-card {
  border: 1px solid var(--border); border-radius: 4px; background: var(--bg-card);
  padding: 28px; box-shadow: var(--shadow-card); transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.feature-card:hover { border-color: var(--border-hover); transform: translateY(-3px); box-shadow: var(--shadow-soft); }
.feature-num { font-family: var(--font-display); font-size: 1.6rem; color: var(--red); margin-bottom: 10px; }
.feature-card h3 { font-size: 1.15rem; margin-bottom: 8px; }
.feature-card p { color: var(--text-muted); font-size: .96rem; margin: 0; }

/* ---------- Article list (déclaration de principes, programme) ---------- */
.article-list { display: flex; flex-direction: column; gap: 4px; margin-top: 34px; }
.article {
  display: grid; grid-template-columns: 64px 1fr; gap: 22px;
  padding: 26px 0; border-top: 1px solid var(--border);
}
.article:last-child { border-bottom: 1px solid var(--border); }
.article-index { font-family: var(--font-display); font-size: 1.5rem; color: var(--red); line-height: 1.2; }
.article-body h3 { font-size: 1.15rem; margin-bottom: 8px; }
.article-body p { color: var(--text-muted); margin: 0; }

/* ---------- Blockquote / doctrine ---------- */
.doctrine-block { border-left: 3px solid var(--red); padding-left: 24px; margin: 0 0 34px; max-width: 720px; }
.doctrine-block:last-child { margin-bottom: 0; }
.doctrine-block h3 { font-family: var(--font-heading); font-style: italic; font-size: 1.3rem; margin-bottom: 10px; color: var(--navy); }
.doctrine-block p { color: var(--text-muted); margin: 0; }

/* ---------- Timeline (histoire) ---------- */
.history-note {
  border: 1px solid var(--border); background: var(--bg-card); border-radius: 4px;
  padding: 30px 34px; box-shadow: var(--shadow-card); max-width: 780px;
}
.history-note p { color: var(--text-muted); }
.history-note p:last-child { margin: 0; }

/* ---------- Org chart ---------- */
.org-chart { display: flex; flex-direction: column; gap: 14px; margin-top: 40px; }
.org-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.org-box {
  border-radius: 4px; padding: 16px 18px; font-family: var(--font-heading); font-weight: 600;
  font-size: .96rem; letter-spacing: .02em; text-align: center; box-shadow: var(--shadow-card);
  border: 1px solid transparent;
}
.org-box.navy { background: var(--navy); color: #fff; }
.org-box.red { background: var(--red); color: #fff; }
.org-box.gold { background: var(--gold); color: #fff; }
.org-box.outline { background: var(--bg-card); color: var(--navy); border-color: var(--border-hover); }
.org-arrow { text-align: center; color: var(--text-dim); font-size: 1.1rem; }

.body-card {
  border: 1px solid var(--border); background: var(--bg-card); border-radius: 4px;
  padding: 28px 30px; box-shadow: var(--shadow-card); margin-bottom: 20px;
}
.body-card h3 { font-size: 1.2rem; margin-bottom: 4px; color: var(--navy); }
.body-card .body-role { font-size: .82rem; text-transform: uppercase; letter-spacing: .14em; color: var(--red); margin-bottom: 16px; display: block; }
.body-card ul { display: flex; flex-direction: column; gap: 8px; }
.body-card li { color: var(--text-muted); font-size: .98rem; padding-left: 18px; position: relative; }
.body-card li::before { content: '—'; position: absolute; left: 0; color: var(--text-dim); }
.body-card li.vacant { color: var(--text-dim); text-decoration: line-through; text-decoration-color: rgba(131,141,163,.5); }
.body-card li .tag-vacant { text-decoration: none; display: inline-block; margin-left: 8px; font-size: .74rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-dim); }
.honor-card {
  border: 1px solid var(--gold); background: linear-gradient(180deg, #fbf6e9, var(--bg-card));
  border-radius: 4px; padding: 30px 34px; box-shadow: var(--shadow-card); margin-bottom: 34px;
}
.honor-card .body-role { color: var(--gold); }
.honor-card h3 { font-family: var(--font-display); font-size: 1.35rem; }
.honor-card p { color: var(--text-muted); margin: 6px 0 0; }

/* ---------- Notice / callout ---------- */
.notice {
  border: 1px dashed var(--border-hover); border-radius: 4px; background: rgba(169,130,44,.06);
  padding: 18px 22px; font-size: .92rem; color: var(--text-muted); margin-top: 20px;
}
.notice strong { color: var(--navy); }

/* ---------- Contact / rejoindre ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; margin-top: 40px; }
.contact-card {
  border: 1px solid var(--border); background: var(--bg-card); border-radius: 4px;
  padding: 30px; text-align: center; box-shadow: var(--shadow-card);
}
.contact-card h3 { font-size: 1.1rem; margin-bottom: 10px; }
.contact-card p { color: var(--text-muted); font-size: .95rem; }
.contact-card a.btn { margin-top: 14px; }

.steps-list { display: flex; flex-direction: column; gap: 20px; max-width: 620px; margin: 36px auto 0; }
.step { display: flex; gap: 18px; align-items: flex-start; }
.step-num {
  flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--navy); color: #fff;
  display: flex; align-items: center; justify-content: center; font-family: var(--font-heading); font-weight: 600; font-size: .95rem;
}
.step-body h3 { font-size: 1.05rem; margin-bottom: 4px; }
.step-body p { color: var(--text-muted); margin: 0; font-size: .95rem; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 40px 0 30px; background: var(--bg-2); }
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.footer-emblem { width: 30px; height: 30px; opacity: .7; }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; font-size: .85rem; }
.footer-links a { text-decoration: none; color: var(--text-muted); }
.footer-links a:hover { color: var(--navy); }
.footer-fine { font-size: .78rem; color: var(--text-dim); max-width: 560px; }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

@media (max-width: 760px) {
  .primary-nav {
    position: fixed; top: var(--nav-height); left: 0; right: 0; bottom: 0;
    background: var(--bg); flex-direction: column; align-items: flex-start; gap: 4px;
    padding: 20px 24px; transform: translateX(100%); transition: transform .25s ease;
    overflow-y: auto; z-index: 40;
  }
  .primary-nav.open { transform: translateX(0); }
  .primary-nav a { width: 100%; padding: 14px 0; border-bottom: 1px solid var(--border); font-size: 17px; }
  .nav-toggle { display: flex; }
  .article { grid-template-columns: 40px 1fr; gap: 14px; }
}
