/* =============================================
   CELIB-RENCONTRES.FR — Design System
   Ultra-léger, thème rencontres rose/violet
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --pink-50: #fdf2f8;
  --pink-100: #fce7f3;
  --pink-200: #fbcfe8;
  --pink-300: #f9a8d4;
  --pink-400: #f472b6;
  --pink-500: #ec4899;
  --pink-600: #db2777;
  --pink-700: #be185d;
  --violet-500: #8b5cf6;
  --violet-600: #7c3aed;
  --violet-700: #6d28d9;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  --white: #ffffff;
  --gradient-main: linear-gradient(135deg, var(--pink-500) 0%, var(--violet-600) 100%);
  --gradient-soft: linear-gradient(135deg, var(--pink-50) 0%, #ede9fe 100%);
  --gradient-cta: linear-gradient(135deg, var(--pink-600) 0%, var(--violet-600) 100%);
  --shadow-sm: 0 1px 3px rgba(0,0,0,.08);
  --shadow-md: 0 4px 14px rgba(0,0,0,.1);
  --shadow-lg: 0 10px 30px rgba(0,0,0,.12);
  --shadow-cta: 0 8px 25px rgba(219,39,119,.35);
  --radius: 12px;
  --radius-lg: 20px;
  --max-w: 1140px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--gray-800);
  background: var(--white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--pink-600); text-decoration: none; transition: color .2s; }
a:hover { color: var(--violet-600); }

img { max-width: 100%; display: block; }

/* ---- LAYOUT ---- */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 20px; }

/* ---- HEADER ---- */
.site-header {
  background: var(--gradient-main);
  padding: 18px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 20px rgba(139,92,246,.25);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.logo {
  color: var(--white);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -.5px;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}
.logo span { opacity: .85; font-weight: 500; font-size: .85rem; }

/* ---- SEARCH BAR ---- */
.search-box {
  position: relative;
  width: 100%;
  max-width: 380px;
}
.search-box input {
  width: 100%;
  padding: 10px 16px 10px 40px;
  border: none;
  border-radius: 50px;
  font-size: .9rem;
  background: rgba(255,255,255,.2);
  color: var(--white);
  backdrop-filter: blur(8px);
  outline: none;
  transition: background .2s;
}
.search-box input::placeholder { color: rgba(255,255,255,.7); }
.search-box input:focus { background: rgba(255,255,255,.3); }
.search-box .search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1rem;
  color: rgba(255,255,255,.7);
  pointer-events: none;
}
.search-results {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  max-height: 320px;
  overflow-y: auto;
  display: none;
  z-index: 200;
}
.search-results.active { display: block; }
.search-results a {
  display: block;
  padding: 10px 16px;
  color: var(--gray-800);
  font-size: .88rem;
  border-bottom: 1px solid var(--gray-100);
  transition: background .15s;
}
.search-results a:hover { background: var(--pink-50); color: var(--pink-600); }
.search-results a:last-child { border-bottom: none; }
.search-results .zip-tag {
  display: inline-block;
  background: var(--gray-100);
  color: var(--gray-600);
  font-size: .72rem;
  padding: 2px 7px;
  border-radius: 4px;
  margin-left: 6px;
}

/* ---- HERO ---- */
.hero {
  background: var(--gradient-soft);
  padding: 70px 0 60px;
  text-align: center;
}
.hero h1 {
  font-size: clamp(1.8rem, 4.5vw, 2.8rem);
  font-weight: 800;
  color: var(--gray-900);
  line-height: 1.2;
  margin-bottom: 16px;
}
.hero h1 .accent {
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero .subtitle {
  font-size: 1.1rem;
  color: var(--gray-600);
  max-width: 620px;
  margin: 0 auto 30px;
}

/* ---- CTA BUTTON ---- */
.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--gradient-cta);
  color: var(--white);
  font-weight: 700;
  font-size: 1.05rem;
  padding: 16px 36px;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow-cta);
  transition: transform .2s, box-shadow .2s;
  text-decoration: none;
}
.cta-btn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 12px 35px rgba(219,39,119,.45);
  color: var(--white);
}
.cta-btn:active { transform: translateY(0) scale(.99); }

.cta-btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: var(--pink-600);
  font-weight: 600;
  font-size: .95rem;
  padding: 12px 28px;
  border-radius: 50px;
  border: 2px solid var(--pink-300);
  cursor: pointer;
  transition: all .2s;
}
.cta-btn-outline:hover {
  background: var(--pink-50);
  border-color: var(--pink-500);
  color: var(--pink-700);
}

/* ---- SECTIONS ---- */
.section { padding: 60px 0; }
.section-alt { background: var(--gray-50); }
.section-title {
  font-size: 1.6rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 10px;
  color: var(--gray-900);
}
.section-subtitle {
  text-align: center;
  color: var(--gray-600);
  max-width: 560px;
  margin: 0 auto 40px;
  font-size: .95rem;
}

/* ---- ADVANTAGES GRID ---- */
.adv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}
.adv-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: transform .2s, box-shadow .2s;
}
.adv-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.adv-card .icon {
  font-size: 1.8rem;
  margin-bottom: 12px;
}
.adv-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--gray-900);
}
.adv-card p {
  font-size: .88rem;
  color: var(--gray-600);
  line-height: 1.55;
}

/* ---- ACTIVITIES ---- */
.act-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}
.act-card {
  background: var(--gradient-soft);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
  transition: transform .2s;
}
.act-card:hover { transform: translateY(-3px); }
.act-card .act-icon { font-size: 2rem; margin-bottom: 10px; }
.act-card h3 {
  font-size: .95rem;
  font-weight: 700;
  color: var(--gray-800);
  margin-bottom: 6px;
}
.act-card p { font-size: .82rem; color: var(--gray-600); }

/* ---- STATS BAR ---- */
.stats-bar {
  background: var(--gradient-main);
  padding: 32px 0;
  color: var(--white);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  text-align: center;
}
.stat-item .num {
  font-size: 1.8rem;
  font-weight: 800;
}
.stat-item .label {
  font-size: .82rem;
  opacity: .85;
  margin-top: 4px;
}

/* ---- DEPARTMENTS HUB ---- */
.dept-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
}
.dept-link {
  display: block;
  padding: 10px 14px;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  font-size: .85rem;
  color: var(--gray-700);
  transition: all .15s;
}
.dept-link:hover {
  border-color: var(--pink-300);
  color: var(--pink-600);
  background: var(--pink-50);
}
.dept-link .dept-num {
  font-weight: 700;
  color: var(--pink-500);
  margin-right: 4px;
}

/* ---- COMMUNE PAGE ---- */
.breadcrumb {
  font-size: .82rem;
  color: var(--gray-600);
  margin-bottom: 20px;
}
.breadcrumb a { color: var(--pink-500); }
.breadcrumb .sep { margin: 0 6px; opacity: .5; }

.commune-hero {
  background: var(--gradient-soft);
  padding: 50px 0 40px;
}
.commune-hero h1 {
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 12px;
}
.commune-hero .lead {
  font-size: 1rem;
  color: var(--gray-600);
  max-width: 650px;
  margin-bottom: 24px;
}

/* FAQ */
.faq-list { max-width: 720px; margin: 0 auto; }
.faq-item {
  border-bottom: 1px solid var(--gray-200);
  padding: 18px 0;
}
.faq-item h3 {
  font-size: .95rem;
  font-weight: 700;
  color: var(--gray-800);
  margin-bottom: 8px;
  cursor: default;
}
.faq-item p {
  font-size: .88rem;
  color: var(--gray-600);
  line-height: 1.6;
}

/* ---- INTERNAL LINKS ---- */
.links-section { margin-top: 20px; }
.links-section h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--gray-800);
}
.links-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.links-grid a {
  display: inline-block;
  padding: 6px 14px;
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: 20px;
  font-size: .8rem;
  color: var(--gray-700);
  transition: all .15s;
}
.links-grid a:hover {
  background: var(--pink-50);
  border-color: var(--pink-300);
  color: var(--pink-600);
}

/* ---- DEPARTMENT PAGE ---- */
.dept-hero {
  background: var(--gradient-soft);
  padding: 50px 0 40px;
}
.dept-hero h1 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 10px;
}
.communes-list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
}
.communes-list-grid a {
  display: block;
  padding: 8px 14px;
  font-size: .85rem;
  color: var(--gray-700);
  border-radius: 6px;
  transition: all .15s;
}
.communes-list-grid a:hover {
  background: var(--pink-50);
  color: var(--pink-600);
}

/* ---- FOOTER ---- */
.site-footer {
  background: var(--gray-900);
  color: rgba(255,255,255,.6);
  padding: 40px 0 24px;
  font-size: .82rem;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: start;
  gap: 30px;
}
.footer-brand {
  color: var(--white);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 8px;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.footer-links a { color: rgba(255,255,255,.6); transition: color .2s; }
.footer-links a:hover { color: var(--white); }
.footer-copy {
  text-align: center;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.1);
  font-size: .78rem;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 768px) {
  .hero { padding: 50px 0 40px; }
  .section { padding: 40px 0; }
  .header-inner { flex-wrap: wrap; }
  .search-box { max-width: 100%; order: 3; }
  .adv-grid { grid-template-columns: 1fr; }
  .act-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .dept-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .act-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr; }
  .cta-btn { width: 100%; justify-content: center; font-size: .95rem; padding: 14px 24px; }
}
