/**
 * template.css — Styles principaux du template L'Un pour l'Autre
 * Design system : palette, typographie, layout, sections
 */

/* ═══════════════════════════════════════════════
   VARIABLES — Design Tokens
   ═══════════════════════════════════════════════ */
:root {
  --color-primary:       #0158A7;
  --color-primary-dark:  #023E7D;
  --color-primary-light: #E8F4FF;
  --color-accent:        #F5A623;
  --color-success:       #2ECC9A;
  --color-warm:          #F9F5EF;
  --color-white:         #FFFFFF;
  --color-text-dark:     #1A2B4A;
  --color-text-medium:   #4A6080;
  --color-text-light:    #8A9BB0;

  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --radius-sm:  12px;
  --radius-md:  20px;
  --radius-lg:  24px;
  --radius-xl:  50px;

  --shadow-soft:   0 8px 40px rgba(1, 88, 167, 0.12);
  --shadow-medium: 0 16px 60px rgba(1, 88, 167, 0.15);
  --shadow-strong: 0 32px 80px rgba(0, 0, 0, 0.2);

  --transition-base: 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  --transition-smooth: 0.3s ease;
}

/* ═══════════════════════════════════════════════
   RESET & BASE
   ═══════════════════════════════════════════════ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.lun-pour-lautre {
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.8;
  color: var(--color-text-dark);
  background: var(--color-warm);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-smooth);
}

a:hover {
  color: var(--color-accent);
}

a:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ═══════════════════════════════════════════════
   HEADER / NAVIGATION
   ═══════════════════════════════════════════════ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  transition: background var(--transition-smooth), padding var(--transition-smooth), box-shadow var(--transition-smooth);
}

.site-header.scrolled {
  background: rgba(1, 88, 167, 0.95);
  backdrop-filter: blur(12px);
  padding: 10px 0;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.15);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.header-logo {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--color-white);
  text-decoration: none;
  white-space: nowrap;
}

.header-logo:hover {
  color: var(--color-white);
}

.logo-accent {
  color: var(--color-accent);
  font-style: italic;
}

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

.nav-link {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  padding: 8px 14px;
  border-radius: var(--radius-xl);
  transition: color var(--transition-smooth), background var(--transition-smooth);
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--color-white);
  background: rgba(255, 255, 255, 0.12);
}

/* Bouton hamburger mobile */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle-bar {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-white);
  border-radius: 2px;
  transition: transform var(--transition-smooth), opacity var(--transition-smooth);
}

.nav-toggle.active .nav-toggle-bar:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active .nav-toggle-bar:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Pages non-accueil : header avec fond */
body:not(.is-home) .site-header {
  background: var(--color-primary);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* ═══════════════════════════════════════════════
   CONTAINER
   ═══════════════════════════════════════════════ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ═══════════════════════════════════════════════
   TYPOGRAPHIE
   ═══════════════════════════════════════════════ */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-text-dark);
}

h2 {
  font-size: clamp(32px, 5vw, 48px);
  margin-bottom: 24px;
}

h2 em {
  color: var(--color-primary);
  font-style: italic;
}

h3 {
  font-size: clamp(22px, 3vw, 28px);
  margin-bottom: 12px;
}

/* ═══════════════════════════════════════════════
   SECTIONS — Layout de base
   ═══════════════════════════════════════════════ */
.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 64px;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: 16px;
  padding: 6px 16px;
  background: var(--color-primary-light);
  border-radius: var(--radius-xl);
}

.section-tag.light {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.9);
}

.section-lead {
  font-size: clamp(17px, 2vw, 20px);
  color: var(--color-text-medium);
  line-height: 1.8;
  max-width: 640px;
  margin: 0 auto;
}

/* ═══════════════════════════════════════════════
   SECTION — Pourquoi ce projet ?
   ═══════════════════════════════════════════════ */
.section-why {
  padding: 120px 0;
  background: var(--color-white);
}

.quote-hero-card {
  background: var(--color-primary-light);
  border-radius: var(--radius-lg);
  padding: 48px 40px;
  text-align: center;
  max-width: 700px;
  margin: 0 auto 64px;
  position: relative;
}

.quote-marks {
  font-family: var(--font-display);
  font-size: 120px;
  color: var(--color-primary);
  opacity: 0.15;
  position: absolute;
  top: -10px;
  left: 30px;
  line-height: 1;
}

.quote-hero-card blockquote {
  font-family: var(--font-display);
  font-size: clamp(24px, 4vw, 32px);
  font-style: italic;
  color: var(--color-primary-dark);
  margin-bottom: 16px;
  position: relative;
}

.quote-hero-card p {
  font-size: 15px;
  color: var(--color-text-medium);
}

.impact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.impact-card {
  background: var(--color-warm);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  text-align: center;
  transition: transform var(--transition-smooth), box-shadow var(--transition-smooth);
}

.impact-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-soft);
}

.impact-icon {
  font-size: 48px;
  margin-bottom: 20px;
}

.impact-card h3 {
  font-size: 22px;
  margin-bottom: 12px;
  color: var(--color-primary);
}

.impact-card p {
  font-size: 16px;
  color: var(--color-text-medium);
  line-height: 1.7;
}

/* ═══════════════════════════════════════════════
   SECTION — Comment ça marche ?
   ═══════════════════════════════════════════════ */
.section-how {
  padding: 120px 0;
  background: linear-gradient(135deg, #0158A7 0%, #023E7D 50%, #01326A 100%);
  color: var(--color-white);
}

.section-how .section-header h2 {
  color: var(--color-white);
}

.section-how .section-header h2 em {
  color: var(--color-accent);
}

.steps-timeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  position: relative;
}

.step-item {
  position: relative;
  text-align: center;
}

.step-connector {
  position: absolute;
  top: 30px;
  left: 60%;
  width: 80%;
  height: 2px;
  background: rgba(255, 255, 255, 0.2);
}

.step-number {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--color-accent);
  margin-bottom: 16px;
  letter-spacing: 1px;
}

.step-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  backdrop-filter: blur(10px);
  transition: transform var(--transition-smooth), background var(--transition-smooth);
}

.step-card:hover {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.12);
}

.step-icon {
  font-size: 40px;
  margin-bottom: 16px;
}

.step-card h3 {
  color: var(--color-white);
  font-size: 22px;
  margin-bottom: 12px;
}

.step-card p {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.7;
  margin-bottom: 16px;
}

.step-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--color-accent);
  padding: 4px 12px;
  border: 1px solid rgba(245, 166, 35, 0.3);
  border-radius: var(--radius-xl);
}

/* ═══════════════════════════════════════════════
   SECTION — De la lettre à la rencontre
   ═══════════════════════════════════════════════ */
.section-journey {
  padding: 120px 0;
  background: var(--color-white);
}

.journey-cards {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
}

.journey-card {
  flex: 1;
  max-width: 320px;
  background: var(--color-warm);
  border-radius: var(--radius-lg);
  padding: 40px 28px;
  text-align: center;
  transition: transform var(--transition-smooth), box-shadow var(--transition-smooth);
}

.journey-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-soft);
}

.journey-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.journey-subtitle {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.journey-card p:last-child {
  font-size: 15px;
  color: var(--color-text-medium);
  line-height: 1.7;
}

.journey-arrow {
  font-size: 32px;
  color: var(--color-primary);
  font-weight: 700;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════
   SECTION — La vision à long terme
   ═══════════════════════════════════════════════ */
.section-vision {
  padding: 120px 0;
  position: relative;
  background: linear-gradient(135deg, #012756 0%, #01326A 40%, #0158A7 100%);
  color: var(--color-white);
  overflow: hidden;
}

.vision-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(245, 166, 35, 0.08) 0%, transparent 60%);
}

.vision-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.vision-content h2 {
  color: var(--color-white);
}

.vision-content h2 em {
  color: var(--color-accent);
}

.vision-text {
  margin-bottom: 64px;
}

.vision-text p {
  font-size: clamp(17px, 2vw, 20px);
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 16px;
  line-height: 1.8;
}

.vision-emphasis {
  font-family: var(--font-display);
  font-size: clamp(20px, 3vw, 26px) !important;
  font-style: italic;
  color: var(--color-accent) !important;
  margin-top: 32px !important;
}

.vision-timeline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.timeline-point {
  text-align: center;
  padding: 0 32px;
}

.timeline-point .year {
  display: block;
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 700;
  color: var(--color-accent);
  margin-bottom: 8px;
}

.timeline-point .desc {
  display: block;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.65);
  white-space: nowrap;
}

.timeline-line {
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, rgba(245, 166, 35, 0.5), rgba(255, 255, 255, 0.2));
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════
   SECTION — Participer
   ═══════════════════════════════════════════════ */
.section-participate {
  padding: 120px 0;
  background: var(--color-warm);
}

.participate-hero {
  text-align: center;
  margin-bottom: 64px;
}

.participate-hero h2 {
  color: var(--color-primary);
}

.participate-lead {
  font-size: clamp(17px, 2vw, 20px);
  color: var(--color-text-medium);
  line-height: 1.7;
}

.participate-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.participate-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  position: relative;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition-smooth), box-shadow var(--transition-smooth);
}

.participate-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-medium);
}

.participate-card.primary {
  background: var(--color-primary);
  color: var(--color-white);
}

.participate-card.primary h3 {
  color: var(--color-white);
}

.participate-card.primary p {
  color: rgba(255, 255, 255, 0.85);
}

.card-number {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 700;
  color: var(--color-primary-light);
  opacity: 0.3;
  position: absolute;
  top: 16px;
  right: 24px;
}

.participate-card.primary .card-number {
  color: var(--color-white);
  opacity: 0.15;
}

.participate-card h3 {
  font-size: 22px;
  margin-bottom: 12px;
}

.participate-card p {
  font-size: 16px;
  color: var(--color-text-medium);
  line-height: 1.7;
  margin-bottom: 16px;
}

.participate-card address {
  font-style: normal;
  font-size: 15px;
  color: var(--color-text-medium);
  line-height: 1.8;
  margin-bottom: 16px;
}

/* ═══════════════════════════════════════════════
   CONTENU PRINCIPAL (pages non-accueil)
   ═══════════════════════════════════════════════ */
.site-main {
  padding: 80px 0 120px;
  min-height: 60vh;
  background: var(--color-white);
}

/* ═══════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════ */
.site-footer {
  background: var(--color-text-dark);
  color: rgba(255, 255, 255, 0.7);
  padding: 80px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand h3 {
  font-family: var(--font-display);
  font-size: 28px;
  color: var(--color-white);
  margin-bottom: 8px;
}

.footer-brand p {
  margin-bottom: 16px;
}

.footer-quote {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.65);
}

.site-footer h4 {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--color-accent);
  margin-bottom: 20px;
}

.footer-contact address {
  font-style: normal;
  line-height: 1.8;
  margin-bottom: 12px;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.7);
}

.site-footer a:hover {
  color: var(--color-accent);
}

.footer-nav ul {
  list-style: none;
}

.footer-nav li {
  margin-bottom: 10px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 24px;
  text-align: center;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.65);
}

/* ═══════════════════════════════════════════════
   PRÉFÉRENCE MOUVEMENT RÉDUIT
   ═══════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
