/* ═══════════════════════════════════════════════════════════════
   DEPT.CSS — Landing Pages Départements
   Mission Adventiste du 7e Jour — Polynésie Française
   ═══════════════════════════════════════════════════════════════ */

:root {
  --sage: #E8651A;
  --sage-dark: #c4541a;
  --sage-light: #fff7ed;
  --text-dark: #111827;
  --text-mid: #4b5563;
  --text-light: #9ca3af;
  --bg: #fafaf8;
  --white: #ffffff;
  --border: #f0ebe4;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.07);
  --shadow-md: 0 4px 24px rgba(0,0,0,0.09);
  --shadow-lg: 0 12px 48px rgba(0,0,0,0.14);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg);
  color: var(--text-dark);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* ──────────────────────────
   NAVBAR
────────────────────────── */
.dept-nav {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(8, 8, 18, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

.dept-nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
  height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.dept-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 7px 16px;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.18);
  transition: all 0.2s;
  white-space: nowrap;
}
.dept-back:hover { color: #fff; border-color: rgba(255,255,255,0.4); background: rgba(255,255,255,0.06); }

.dept-nav-logo {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
}
.dept-nav-logo img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 9px;
}
.dept-nav-logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}
.dept-nav-logo-text strong { color: #fff; font-size: 0.82rem; }
.dept-nav-logo-text span   { color: rgba(255,255,255,0.45); font-size: 0.7rem; }

.dept-nav-contact {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--sage);
  color: #fff;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 100px;
  transition: background 0.2s, transform 0.15s;
  white-space: nowrap;
}
.dept-nav-contact:hover { background: var(--sage-dark); transform: translateY(-1px); }

/* ──────────────────────────
   LANGUAGE SWITCHER
────────────────────────── */
.dept-lang-wrap { display: flex; align-items: center; gap: 4px; }
.lang-btn {
  background: transparent; border: 2px solid transparent;
  width: 38px; height: 38px; border-radius: 50%; cursor: pointer;
  font-size: 1.5rem; line-height: 1; padding: 0;
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.2s, border-color 0.2s, opacity 0.2s;
  opacity: 0.5;
}
.lang-btn:hover { opacity: 0.85; transform: scale(1.1); }
.lang-btn.active { opacity: 1; border-color: var(--sage); transform: scale(1.08); box-shadow: 0 0 0 3px rgba(232,101,26,0.25); }

/* ──────────────────────────
   HERO
────────────────────────── */
.dept-hero {
  position: relative;
  height: 520px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dept-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.28;
  transform: scale(1.04);
}

.dept-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 30%, rgba(0,0,0,0.45) 100%);
}

.dept-hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 28px;
  max-width: 760px;
}

.dept-hero-tag {
  display: inline-block;
  color: rgba(255,255,255,0.72);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.18);
  padding: 5px 16px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.dept-hero-content h1 {
  color: #fff;
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  line-height: 1.12;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 20px rgba(0,0,0,0.4);
}

.dept-hero-motto {
  color: rgba(255,255,255,0.88);
  font-size: 1.1rem;
  font-weight: 600;
  font-style: italic;
  margin-bottom: 12px;
}
.dept-hero-motto strong { color: #E8651A; }

.dept-hero-director {
  color: rgba(255,255,255,0.55);
  font-size: 0.9rem;
}

/* ──────────────────────────
   META BAR
────────────────────────── */
.dept-meta-bar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow-x: auto;
}

.dept-meta-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  flex-wrap: wrap;
}

.dept-meta-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 22px;
  font-size: 0.85rem;
  color: var(--text-mid);
  border-right: 1px solid var(--border);
  white-space: nowrap;
}
.dept-meta-item:last-child { border-right: none; }
.dept-meta-item strong { color: var(--text-dark); font-weight: 600; }

/* ──────────────────────────
   LAYOUT (content + sidebar)
────────────────────────── */
.dept-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 28px 80px;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 52px;
  align-items: start;
}

/* ──────────────────────────
   CONTENT AREA
────────────────────────── */
.dept-content { min-width: 0; }

.dept-content h3 {
  color: var(--sage);
  font-size: 1.2rem;
  font-weight: 700;
  margin: 40px 0 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--border);
}
.dept-content h3:first-child { margin-top: 0; }

.dept-content h4 {
  color: #333;
  font-size: 0.97rem;
  font-weight: 700;
  margin: 22px 0 10px;
}

.dept-content p {
  color: var(--text-mid);
  line-height: 1.78;
  margin-bottom: 14px;
}

.dept-content ul,
.dept-content ol {
  color: var(--text-mid);
  margin: 0 0 20px 24px;
  line-height: 2.1;
}

.dept-content a { color: var(--sage); font-weight: 600; }
.dept-content a:hover { color: var(--sage-dark); }

/* ──────────────────────────
   SIDEBAR
────────────────────────── */
.dept-sidebar {
  position: sticky;
  top: 86px;
}

.dept-sidebar-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  margin-bottom: 18px;
}

.dept-sidebar-card:last-child { margin-bottom: 0; }

.dept-sidebar-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-light);
  margin-bottom: 14px;
}

.dept-sidebar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 13px 18px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all 0.2s;
  margin-bottom: 10px;
  cursor: pointer;
  border: none;
}
.dept-sidebar-btn:last-child { margin-bottom: 0; }

.dept-sidebar-btn.primary {
  background: var(--sage);
  color: white;
}
.dept-sidebar-btn.primary:hover { background: var(--sage-dark); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(232,101,26,0.35); }

.dept-sidebar-btn.outline {
  background: transparent;
  color: var(--sage);
  border: 2px solid var(--sage);
}
.dept-sidebar-btn.outline:hover { background: var(--sage-light); }

.dept-sidebar-btn.ghost {
  background: #f8f6f3;
  color: var(--text-mid);
  border: none;
}
.dept-sidebar-btn.ghost:hover { background: #f0ebe4; color: var(--text-dark); }

/* Resources sidebar card */
.dept-resources-card { border-top: 3px solid var(--sage); }
.dept-resources-card .dept-sidebar-label {
  color: var(--sage);
  font-size: 0.75rem;
}
.dept-resource-btn {
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  text-decoration: none;
  padding: 9px 14px !important;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s !important;
}
.dept-resource-btn:hover {
  background: var(--sage-light) !important;
  color: var(--sage) !important;
  transform: translateX(3px) !important;
  box-shadow: -3px 0 0 var(--sage) !important;
}

/* Dept list in sidebar */
.dept-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.dept-list a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.83rem;
  color: var(--text-mid);
  text-decoration: none;
  transition: all 0.15s;
}
.dept-list a:hover { background: #f0ebe4; color: var(--text-dark); }
.dept-list a.active { background: var(--sage-light); color: var(--sage); font-weight: 700; }

/* ──────────────────────────
   SHARE BUTTON
────────────────────────── */
.dept-share-row {
  display: flex;
  gap: 8px;
}

.dept-share-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid var(--border);
  background: white;
  color: var(--text-mid);
  cursor: pointer;
  transition: all 0.15s;
}
.dept-share-btn:hover { border-color: #ccc; background: #f8f6f3; }

/* ──────────────────────────
   AGENDA — EVENT CAROUSEL
────────────────────────── */
.dept-agenda {
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 64px 0 64px;
}

.dept-agenda-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
}

.dept-agenda-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 36px;
}

.dept-agenda-header h2 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-dark);
  display: flex;
  align-items: center;
  gap: 10px;
}

.dept-agenda-add {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--sage);
  background: var(--sage-light);
  padding: 6px 14px;
  border-radius: 20px;
  text-decoration: none;
  border: 1px solid rgba(232,101,26,0.2);
  transition: background 0.2s;
}
.dept-agenda-add:hover { background: #ffe8d4; }

/* ── Carousel wrapper ── */
.dept-evt-carousel-wrap { position: relative; }
.dept-evt-track-wrap {
  overflow: hidden;
  margin: 0 -20px;
}
.dept-evt-track {
  display: flex;
  gap: 28px;
  padding: 12px 40px 20px;
  transition: transform 0.4s cubic-bezier(0.25,0.46,0.45,0.94);
  will-change: transform;
}

/* ── Event card ── */
.dept-evt-card {
  flex-shrink: 0;
  width: 320px;
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,0.08);
  transition: transform 0.3s, box-shadow 0.3s;
  cursor: default;
}
.dept-evt-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.12);
}
.dept-evt-card-placeholder {
  width: 100%;
  height: 180px;
  background: linear-gradient(160deg, #fff7ed 0%, #ffedd5 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
}
.dept-evt-card-img {
  width: 100%; height: 180px; object-fit: cover; display: block;
}
.dept-evt-card-body { padding: 20px; }
.dept-evt-card-tag {
  font-size: 0.68rem; font-weight: 700;
  color: var(--sage); text-transform: uppercase;
  letter-spacing: 0.08em; margin-bottom: 8px; display: block;
}
.dept-evt-card-title {
  font-size: 1rem; font-weight: 800;
  color: #111; margin-bottom: 8px; line-height: 1.3;
}
.dept-evt-card-desc {
  font-size: 0.83rem; color: rgba(0,0,0,0.55);
  line-height: 1.65; margin-bottom: 6px;
  display: -webkit-box; -webkit-line-clamp: 3;
  -webkit-box-orient: vertical; overflow: hidden; transition: all 0.3s;
}
.dept-evt-card-desc.expanded { display: block; -webkit-line-clamp: unset; }
.dept-evt-read-more { display: inline-block; font-size: 0.78rem; font-weight: 700; color: var(--sage); background: none; border: none; cursor: pointer; padding: 0; margin-bottom: 12px; font-family: inherit; }
.dept-evt-read-more:hover { text-decoration: underline; }
.dept-evt-card-footer {
  display: flex; align-items: center;
  justify-content: space-between; flex-wrap: wrap; gap: 8px;
}
.dept-evt-card-date {
  font-size: 0.78rem; color: rgba(0,0,0,0.38);
}
.dept-evt-btn {
  background: var(--sage); color: #fff;
  border: none; border-radius: 20px;
  padding: 7px 16px; font-size: 0.78rem;
  font-weight: 700; cursor: pointer;
  font-family: inherit;
  transition: background 0.2s, transform 0.15s;
  text-decoration: none; display: inline-block;
}
.dept-evt-btn:hover { background: var(--sage-dark); transform: translateY(-1px); }

/* ── Nav arrows ── */
.dept-evt-nav {
  display: flex; justify-content: center;
  gap: 14px; margin-top: 28px;
}
.dept-evt-nav-btn {
  width: 44px; height: 44px; border-radius: 50%;
  border: 2px solid var(--sage);
  background: transparent; color: var(--sage);
  font-size: 1.1rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s, color 0.2s;
}
.dept-evt-nav-btn:hover:not(:disabled) { background: var(--sage); color: #fff; }
.dept-evt-nav-btn:disabled { border-color: rgba(0,0,0,0.15); color: rgba(0,0,0,0.2); cursor: default; }

/* ── Empty state ── */
.dept-evt-empty {
  text-align: center; padding: 48px 24px;
  background: var(--bg); border: 2px dashed var(--border);
  border-radius: var(--radius-md); margin: 0 20px;
}
.dept-evt-empty-icon { font-size: 2.5rem; display: block; margin-bottom: 12px; }
.dept-evt-empty p { font-size: 0.9rem; color: var(--text-mid); margin-bottom: 18px; }

@media (max-width: 640px) {
  .dept-agenda { padding: 48px 0; }
  .dept-agenda-inner { padding: 0 16px; }
  .dept-evt-card { width: 280px; }
}

/* ──────────────────────────
   FOOTER
────────────────────────── */
.dept-footer {
  padding: 72px 28px;
  text-align: center;
  margin-top: 0;
}

.dept-footer-inner { max-width: 600px; margin: 0 auto; }

.dept-footer h2 {
  color: #fff;
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.dept-footer p {
  color: rgba(255,255,255,0.6);
  font-size: 0.9rem;
  margin-bottom: 28px;
  line-height: 1.7;
}

.dept-footer-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.dept-footer-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 100px;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  transition: all 0.2s;
}

.dept-footer-btn.primary {
  background: var(--white);
  color: var(--text-dark);
}
.dept-footer-btn.primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }

.dept-footer-btn.outline {
  background: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.88);
  border: 1px solid rgba(255,255,255,0.25);
}
.dept-footer-btn.outline:hover { background: rgba(255,255,255,0.18); }

.dept-footer-copy {
  margin-top: 36px;
  color: rgba(255,255,255,0.28);
  font-size: 0.75rem;
}

/* ──────────────────────────
   RESPONSIVE
────────────────────────── */
@media (max-width: 960px) {
  .dept-main {
    grid-template-columns: 1fr;
    gap: 40px;
    padding: 48px 20px 60px;
  }
  .dept-sidebar {
    position: static;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  .dept-sidebar-card { margin-bottom: 0; }
}

@media (max-width: 640px) {
  .dept-hero { height: 440px; }
  .dept-nav-logo-text { display: none; }
  .dept-nav-inner { padding: 0 16px; }
  .dept-meta-item { font-size: 0.8rem; padding: 10px 14px; }
  .dept-main { padding: 32px 16px 48px; }
  .dept-footer { padding: 52px 20px; }
  .dept-footer h2 { font-size: 1.5rem; }
  .dept-sidebar { grid-template-columns: 1fr; }
  .dept-content h3 { font-size: 1.1rem; }
}
