/* ============================================================
   ECOVILLAGE MAHAVARIANA - Styles v2
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@300;400;600;700;800&family=Jost:wght@300;400;500;600&display=swap');

:root {
  --forest:    #2d4a2d;
  --moss:      #4a6741;
  --sage:      #7a9e6f;
  --leaf:      #a8c896;
  --cream:     #f5f0e8;
  --sand:      #e8dfc8;
  --earth:     #8b6f47;
  --bark:      #5c4033;
  --sky:       #c8dde0;
  --water:     #6a9eb5;
  --text:      #2a2a1e;
  --light-txt: #5a5a4a;
  --white:     #ffffff;
  --danger:    #c0392b;
  --success:   #27ae60;
  --warning:   #e67e22;
  --couleur-primaire:   #2d4a2d;
  --couleur-secondaire: #7a9e6f;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Jost', sans-serif;
  background: #f4f1ea;
  color: var(--text);
  min-height: 100vh;
  font-size: 15px;
  line-height: 1.6;
}

/* ─── HEADER ─────────────────────────────────────────────── */
.site-header {
  position: relative;
  width: 100%;
  height: 250px;
  overflow: hidden;
  background: var(--couleur-primaire, #2d4a2d);
}

.site-header-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.45;
  display: block;
}

.site-header-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.1) 0%, rgba(20,40,20,0.3) 60%, rgba(10,30,10,0.5) 100%);
}

/* Langue switcher - style référence */
.lang-switcher {
  position: absolute;
  top: 16px;
  right: 24px;
  display: flex;
  align-items: center;
  gap: 0;
  z-index: 10;
}

.lang-sep { color: rgba(255,255,255,0.35); padding: 0 2px; font-size: 12px; }

.lang-btn {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.65);
  padding: 4px 10px;
  cursor: pointer;
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 1px;
  transition: color .2s;
  text-decoration: none;
}

.lang-btn:hover { color: rgba(255,255,255,0.95); }

.lang-btn.active {
  color: #fff;
  background: rgba(255,255,255,0.18);
  border-radius: 4px;
  font-weight: 600;
}

.header-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 40px 10px;
}

.site-title {
  font-family: 'Nunito', sans-serif;
  font-size: clamp(26px, 5vw, 44px);
  font-weight: 700;
  letter-spacing: 0.03em;
  background: linear-gradient(135deg, #b5d99c 0%, #ffffff 40%, #c9a84c 80%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: none;
  line-height: 1.2;
  margin-bottom: 4px;
}

.site-subtitle {
  color: rgba(255,255,255,0.5);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  font-weight: 300;
  font-family: 'Jost', sans-serif;
  margin-bottom: 22px;
}

/* Navigation pilules dans header */
.header-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 4px;
}

.header-nav-link {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  padding: 7px 20px;
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 30px;
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.3px;
  transition: all .2s;
  backdrop-filter: blur(4px);
  background: rgba(255,255,255,0.06);
}

.header-nav-link:hover,
.header-nav-link.active {
  background: rgba(255,255,255,0.2);
  border-color: rgba(255,255,255,0.7);
  color: #fff;
}

/* ─── LAYOUT ─────────────────────────────────────────────── */
.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 36px 24px 60px;
}

.page-title {
  font-family: 'Nunito', sans-serif;
  font-size: clamp(20px, 3.5vw, 28px);
  font-weight: 800;
  color: var(--forest);
  margin-bottom: 28px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--leaf);
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

/* ─── CARDS ──────────────────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: 14px;
  padding: 24px;
  box-shadow: 0 2px 12px rgba(45,74,45,0.08);
  border-left: 4px solid var(--sage);
}

.card h3 {
  font-family: 'Nunito', sans-serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--forest);
  margin-bottom: 12px;
}

.card-blue  { border-left-color: var(--water); }
.card-earth { border-left-color: var(--earth); }

/* ─── ACTIVITÉS GRID ─────────────────────────────────────── */
.activites-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: 10px;
  margin: 16px 0 22px;
}

.activite-chip {
  position: relative;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 13.5px;
  font-weight: 700;
  font-family: 'Nunito', sans-serif;
  color: #fff;
  cursor: default;
  transition: transform .18s, box-shadow .18s;
  line-height: 1.3;
}

.activite-chip:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.2);
  z-index: 10;
}

.activite-chip .tooltip {
  display: none;
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15,30,15,0.96);
  color: rgba(255,255,255,0.92);
  font-size: 12px;
  font-weight: 400;
  font-family: 'Jost', sans-serif;
  padding: 9px 13px;
  border-radius: 8px;
  width: 210px;
  line-height: 1.55;
  text-align: center;
  z-index: 200;
  pointer-events: none;
  box-shadow: 0 4px 16px rgba(0,0,0,0.35);
}

.activite-chip .tooltip::after {
  content: '';
  position: absolute;
  top: 100%; left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: rgba(15,30,15,0.96);
}

.activite-chip:hover .tooltip { display: block; }

/* ─── THEMES CHECKBOXES ──────────────────────────────────── */
.themes-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 16px;
}

.theme-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 20px;
  padding: 7px 16px;
  font-size: 13px;
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s;
  color: rgba(255,255,255,0.75);
  user-select: none;
  border: 2px dashed rgba(255,255,255,0.45);
  opacity: 1;
  filter: saturate(0.55) brightness(0.82);
}

.theme-chip:hover {
  filter: saturate(0.85) brightness(0.92);
  color: #fff;
  transform: translateY(-1px);
  border-style: solid;
}
.theme-chip input { display: none; }
.theme-chip.checked {
  color: #fff;
  filter: none;
  border: 2px solid rgba(255,255,255,0.75);
  box-shadow: 0 2px 12px rgba(0,0,0,0.25);
}
.theme-chip.checked::before { content: '✓ '; }

/* ─── FORMULAIRES ────────────────────────────────────────── */
.form-card {
  background: var(--white);
  border-radius: 14px;
  padding: 26px 28px;
  margin-bottom: 20px;
  box-shadow: 0 2px 12px rgba(45,74,45,0.07);
}

.form-card h2 {
  font-family: 'Nunito', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--forest);
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--light-txt);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  border: 1.5px solid #ddd8c8;
  border-radius: 8px;
  padding: 10px 14px;
  font-family: 'Jost', sans-serif;
  font-size: 14px;
  color: var(--text);
  background: #fafaf6;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  margin-bottom: 16px;
}

.form-control:focus {
  border-color: var(--sage);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(122,158,111,0.15);
}

textarea.form-control { resize: vertical; min-height: 90px; }
select.form-control { cursor: pointer; }

.row { display: flex; gap: 16px; flex-wrap: wrap; }
.row > .col { flex: 1; min-width: 200px; }

.radio-group { display: flex; flex-direction: column; gap: 8px; }

.radio-item, .check-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-radius: 9px;
  cursor: pointer;
  transition: background .15s;
  font-size: 14px;
}

.radio-item:hover, .check-item:hover { background: var(--sand); }

.radio-item input[type=radio],
.check-item input[type=checkbox] {
  width: 17px; height: 17px;
  accent-color: var(--moss);
  flex-shrink: 0;
}

/* ─── BOUTONS ─────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: none;
  border-radius: 30px;
  padding: 11px 28px;
  font-family: 'Nunito', sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.3px;
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--forest);
  color: var(--white);
  box-shadow: 0 3px 12px rgba(45,74,45,0.28);
}
.btn-primary:hover {
  background: var(--moss);
  transform: translateY(-1px);
  box-shadow: 0 5px 18px rgba(45,74,45,0.38);
  color: var(--white);
}

.btn-secondary {
  background: transparent;
  color: var(--forest);
  border: 2px solid var(--forest);
}
.btn-secondary:hover { background: var(--forest); color: var(--white); }

.btn-success { background: var(--success); color: white; }
.btn-danger  { background: var(--danger);  color: white; }
.btn-info    { background: var(--water);   color: white; }
.btn-sm      { padding: 6px 16px; font-size: 12px; }

.btn-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 22px;
  align-items: center;
}

/* ─── STEPS ──────────────────────────────────────────────── */
.steps-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 30px;
  background: white;
  border-radius: 40px;
  padding: 10px 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.07);
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.step-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-family: 'Nunito', sans-serif;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: #bbb;
  font-weight: 700;
}

.step-item.active { color: var(--forest); }
.step-item.done   { color: var(--sage); }

.step-num {
  width: 26px; height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  background: #eee;
  color: #bbb;
  flex-shrink: 0;
  font-weight: 800;
}

.step-item.active .step-num { background: var(--forest); color: white; }
.step-item.done  .step-num  { background: var(--sage);   color: white; }
.step-sep { color: #ddd; font-size: 16px; margin: 0 4px; }

/* ─── DEVIS ──────────────────────────────────────────────── */
.quote-box {
  background: linear-gradient(135deg, #1e3520, #2d4a2d, #3d5e35);
  color: white;
  border-radius: 16px;
  padding: 28px 32px;
  margin: 18px 0;
  box-shadow: 0 6px 24px rgba(45,74,45,0.3);
}

.quote-box h2 {
  font-family: 'Nunito', sans-serif;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 18px;
}

.quote-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 9px 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  font-size: 14px;
}
.quote-row:last-of-type { border-bottom: none; }

.quote-total {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 2px solid rgba(255,255,255,0.3);
  display: flex;
  justify-content: space-between;
  font-family: 'Nunito', sans-serif;
  font-size: 22px;
  font-weight: 800;
}

.groupe-notice {
  background: linear-gradient(135deg, #1a3558, #1e4a7a);
  color: white;
  border-radius: 12px;
  padding: 18px 22px;
  margin: 16px 0;
  font-size: 14px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  box-shadow: 0 4px 16px rgba(30,74,122,0.25);
}

.groupe-notice-icon { font-size: 26px; flex-shrink: 0; margin-top: 2px; }

/* ─── RÉSUMÉ ─────────────────────────────────────────────── */
.summary-box {
  background: linear-gradient(135deg, #f5f0e8, #ede7d5);
  border-radius: 12px;
  padding: 20px 24px;
  margin-bottom: 20px;
}

.s-row {
  display: flex;
  gap: 10px;
  padding: 6px 0;
  font-size: 14px;
  border-bottom: 1px solid rgba(139,111,71,0.12);
}
.s-row:last-child { border-bottom: none; }
.s-label {
  font-weight: 700;
  min-width: 185px;
  color: var(--light-txt);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding-top: 2px;
  font-family: 'Nunito', sans-serif;
}

/* ─── ALERTES ────────────────────────────────────────────── */
.alert {
  border-radius: 10px;
  padding: 13px 17px;
  margin-bottom: 16px;
  font-size: 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.alert-warning { background: #fff8e1; border-left: 4px solid #f0c040; color: #7a5c00; }
.alert-success { background: #e8f5e9; border-left: 4px solid var(--success); color: #1b5e20; }
.alert-info    { background: #e3f2fd; border-left: 4px solid var(--water); color: #0d47a1; }
.alert-danger  { background: #fdecea; border-left: 4px solid var(--danger); color: #7f1d1d; }

/* ─── TABLEAUX ───────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border-radius: 12px; box-shadow: 0 2px 10px rgba(0,0,0,0.06); }

table { width: 100%; border-collapse: collapse; font-size: 14px; background: white; }
thead th {
  background: var(--forest);
  color: white;
  padding: 11px 16px;
  text-align: left;
  font-weight: 700;
  font-family: 'Nunito', sans-serif;
  font-size: 12px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}
tbody td { padding: 10px 16px; border-bottom: 1px solid var(--sand); vertical-align: top; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: rgba(168,200,150,0.08); }

/* ─── CONFIRMATION ───────────────────────────────────────── */
.success-card {
  background: white;
  border: 2px solid var(--leaf);
  border-radius: 18px;
  padding: 36px 40px;
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}

.success-card .icon { font-size: 56px; margin-bottom: 12px; }
.success-card h2 {
  font-family: 'Nunito', sans-serif;
  font-size: 26px;
  font-weight: 800;
  color: var(--forest);
  margin-bottom: 10px;
}

.notice-box {
  background: rgba(139,111,71,0.1);
  border-left: 4px solid var(--earth);
  border-radius: 8px;
  padding: 14px 18px;
  margin: 14px 0;
  font-size: 14px;
  color: var(--bark);
  text-align: left;
}

/* ─── CODE BOX ───────────────────────────────────────────── */
.code-box {
  background: var(--forest);
  color: white;
  border-radius: 14px;
  padding: 20px 28px;
  text-align: center;
  margin: 18px 0;
}

.code-box .code {
  font-size: 32px;
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  letter-spacing: 6px;
  color: #b5d99c;
  display: block;
  margin: 8px 0;
  cursor: pointer;
}

/* ─── CTA / Vous venez ───────────────────────────────────── */
.cta-banner {
  background: linear-gradient(135deg, var(--forest) 0%, var(--moss) 60%, #5a7a4a 100%);
  border-radius: 16px;
  padding: 34px 40px;
  color: white;
  text-align: center;
  margin-top: 24px;
}

.cta-banner h3 {
  font-family: 'Nunito', sans-serif;
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 10px;
}

.cta-banner p {
  color: rgba(255,255,255,0.8);
  font-size: 15px;
  margin-bottom: 24px;
}

/* ─── ADMIN ──────────────────────────────────────────────── */
.admin-sidebar {
  width: 230px;
  background: #1a2e1a;
  min-height: 100vh;
  flex-shrink: 0;
}

.admin-layout { display: flex; min-height: 100vh; }

.admin-main {
  flex: 1;
  padding: 32px 36px;
  overflow-x: auto;
  background: #f7f5ef;
}

.admin-nav a {
  display: block;
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  padding: 11px 24px;
  font-size: 13.5px;
  font-family: 'Jost', sans-serif;
  transition: all .2s;
  border-left: 3px solid transparent;
}

.admin-nav a:hover, .admin-nav a.active {
  color: white;
  background: rgba(255,255,255,0.08);
  border-left-color: #a8c896;
}

.admin-logo {
  color: white;
  text-align: center;
  padding: 24px 16px 20px;
  font-family: 'Nunito', sans-serif;
  font-size: 15px;
  font-weight: 700;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 8px;
}

.stat-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(155px, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}

.stat-card {
  background: white;
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.stat-card .stat-num {
  font-family: 'Nunito', sans-serif;
  font-size: 34px;
  font-weight: 800;
  color: var(--forest);
  line-height: 1;
}

.stat-card .stat-label {
  font-size: 11px;
  color: var(--light-txt);
  margin-top: 6px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 600;
}

.admin-title {
  font-family: 'Nunito', sans-serif;
  font-size: 24px;
  font-weight: 800;
  color: #1a2e1a;
  margin-bottom: 22px;
}

/* ─── FOOTER ─────────────────────────────────────────────── */
.site-footer {
  background: #1a2e1a;
  color: rgba(255,255,255,0.6);
  text-align: center;
  padding: 22px 20px;
  font-size: 13px;
}

.site-footer a { color: #a8c896; text-decoration: none; }

/* ─── SECTION LOGIN ──────────────────────────────────────── */
.login-option-card {
  background: white;
  border-radius: 14px;
  padding: 28px;
  box-shadow: 0 3px 16px rgba(0,0,0,0.08);
  border-top: 4px solid var(--sage);
}

.login-option-card h3 {
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 17px;
  color: var(--forest);
  margin-bottom: 14px;
}

/* ─── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 680px) {
  .header-nav { gap: 6px; }
  .header-nav-link { padding: 5px 13px; font-size: 12px; }
  .container { padding: 20px 14px 40px; }
  .form-card { padding: 18px 16px; }
  .admin-layout { flex-direction: column; }
  .admin-sidebar { width: 100%; min-height: auto; }
  .admin-main { padding: 20px 16px; }
  .row > .col { min-width: 100%; }
  .steps-bar { gap: 2px; padding: 8px 12px; }
  .step-item > span:not(.step-num) { display: none; }
  .activites-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
}
