/* ==========================================================================
   Mosquée Amitié (Metz) — Joomla 6 site template
   Palette : vert profond du logo, doré en accent, fond crème. Polices système.
   ========================================================================== */

:root {
  --am-green: #146b45;
  --am-green-dark: #0b4a31;
  --am-green-deep: #083726;
  --am-green-soft: #e3f0e8;
  --am-gold: #c89b2c;
  --am-gold-dark: #a37c1c;
  --am-gold-soft: #f7efd8;
  --am-cream: #faf8f3;
  --am-bg: #ffffff;
  --am-ink: #1b2622;
  --am-muted: #5d6b64;
  --am-border: #e2e6e1;
  --am-focus: #2563eb;
  --am-max: 1160px;
  --am-gutter: clamp(16px, 4vw, 32px);
  --am-radius: 16px;
  --am-shadow: 0 12px 32px rgba(11, 74, 49, 0.10);
  --am-font: "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --am-serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, "Times New Roman", serif;
  --hero-image: none;
  /* Motif étoile à 8 branches, discret, utilisé sur les fonds verts */
  --am-pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72' viewBox='0 0 72 72'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='0.10' stroke-width='1'%3E%3Cpath d='M36 6l6 24 24 6-24 6-6 24-6-24-24-6 24-6z'/%3E%3Cpath d='M36 18l3.5 14.5L54 36l-14.5 3.5L36 54l-3.5-14.5L18 36l14.5-3.5z'/%3E%3C/g%3E%3C/svg%3E");
}

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
body {
  margin: 0;
  font-family: var(--am-font);
  font-size: 1.02rem;
  line-height: 1.7;
  color: var(--am-ink);
  background: var(--am-bg);
  -webkit-font-smoothing: antialiased;
}
img, svg, video, iframe { max-width: 100%; }
img { height: auto; }
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 0.5em;
  font-family: var(--am-serif);
  font-weight: 600;
  line-height: 1.18;
  color: var(--am-green-deep);
  letter-spacing: 0.005em;
}
h1 { font-size: clamp(2rem, 1.4rem + 2.4vw, 3rem); }
h2 { font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.25rem); }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }
p, ul, ol, dl, figure, blockquote, table { margin: 0 0 1.15em; }
a { color: var(--am-green); text-decoration: none; }
a:hover { color: var(--am-green-dark); text-decoration: underline; }
:focus-visible { outline: 3px solid var(--am-focus); outline-offset: 2px; }
.container { width: 100%; max-width: var(--am-max); margin-inline: auto; padding-inline: var(--am-gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; top: -100px; left: 16px; z-index: 1000; padding: 10px 16px; background: var(--am-green-deep); color: #fff; border-radius: 8px; }
.skip-link:focus { top: 12px; color: #fff; }

/* Ornement sous les titres de section */
.ornament, .section-title::after {
  content: "";
  display: block;
  width: 64px; height: 10px;
  margin: 14px auto 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 10'%3E%3Cpath d='M0 5h22M42 5h22' stroke='%23c89b2c' stroke-width='1.5'/%3E%3Cpath d='M32 0l5 5-5 5-5-5z' fill='%23c89b2c'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* --------------------------------------------------------------------------
   Boutons
   -------------------------------------------------------------------------- */
.btn, button.btn, .btn-primary, .btn-secondary {
  display: inline-flex; align-items: center; gap: 0.5em;
  padding: 0.8em 1.5em;
  border: 2px solid transparent; border-radius: 999px;
  font: inherit; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.15s;
}
.btn-primary, .btn.validate { background: var(--am-green); border-color: var(--am-green); color: #fff; }
.btn-primary:hover, .btn.validate:hover { background: var(--am-green-dark); border-color: var(--am-green-dark); color: #fff; text-decoration: none; }
.btn-gold { background: var(--am-gold); border-color: var(--am-gold); color: #1b1b1b; }
.btn-gold:hover { background: var(--am-gold-dark); border-color: var(--am-gold-dark); color: #fff; text-decoration: none; }
.btn-secondary, .btn-outline { background: transparent; border-color: var(--am-green); color: var(--am-green); }
.btn-secondary:hover, .btn-outline:hover { background: var(--am-green); color: #fff; text-decoration: none; }
.btn-ghost { background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.55); color: #fff; }
.btn-ghost:hover { background: #fff; color: var(--am-green-deep); text-decoration: none; }
.btn:active { transform: translateY(1px); }

/* --------------------------------------------------------------------------
   En-tête et navigation
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.site-header.is-scrolled { border-color: var(--am-border); box-shadow: 0 4px 20px rgba(11, 74, 49, 0.08); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 84px; }
.brand { display: inline-flex; align-items: center; flex-shrink: 0; }
.brand img { width: auto; height: 60px; display: block; }

.site-nav ul.mod-menu { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 2px; }
.site-nav li { position: relative; }
.site-nav a, .site-nav .nav-header, .site-nav .separator {
  display: inline-block; padding: 0.6em 0.95em; border-radius: 10px;
  color: var(--am-ink); font-weight: 500; text-decoration: none;
  transition: background 0.15s, color 0.15s;
}
.site-nav a:hover { background: var(--am-green-soft); color: var(--am-green-deep); }
.site-nav > ul > li.active > a, .site-nav > ul > li.current > a { color: var(--am-green); }
.site-nav > ul > li.active > a::after { content: ""; display: block; height: 2px; margin: 2px 0.2em 0; background: var(--am-gold); border-radius: 2px; }
.site-nav li.parent > a::after, .site-nav li.parent > .nav-header::after {
  content: ""; display: inline-block; width: 7px; height: 7px; margin-left: 8px; vertical-align: 2px;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg);
}
.site-nav a.btn-cta { margin-left: 8px; padding: 0.65em 1.3em; border-radius: 999px; background: var(--am-gold); color: #1b1b1b; font-weight: 600; }
.site-nav a.btn-cta:hover { background: var(--am-gold-dark); color: #fff; }
.site-nav li.active > a.btn-cta::after { display: none; }
.site-nav .mod-menu__toggle-sub { display: none; }

/* Sous-menus (bureau) : un panneau ; un 3e niveau s'affiche en groupes dans le même panneau */
.site-nav ul.mod-menu__sub {
  list-style: none; margin: 0; padding: 10px;
  position: absolute; top: calc(100% + 4px); left: 0; min-width: 240px;
  background: #fff; border: 1px solid var(--am-border); border-radius: 14px; box-shadow: var(--am-shadow);
  display: none; z-index: 50;
}
.site-nav li:hover > ul.mod-menu__sub, .site-nav li:focus-within > ul.mod-menu__sub, .site-nav li.is-open > ul.mod-menu__sub { display: block; }
.site-nav ul.mod-menu__sub a, .site-nav ul.mod-menu__sub .nav-header { display: block; padding: 0.5em 0.8em; font-weight: 500; border-radius: 8px; }
.site-nav ul.mod-menu__sub li.parent > .nav-header,
.site-nav ul.mod-menu__sub li.parent > a { font-family: var(--am-serif); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--am-gold-dark); margin-top: 6px; }
.site-nav ul.mod-menu__sub li.parent > .nav-header::after, .site-nav ul.mod-menu__sub li.parent > a::after { display: none; }
.site-nav ul.mod-menu__sub ul.mod-menu__sub { position: static; display: block; padding: 0 0 4px; border: 0; box-shadow: none; min-width: 0; }
.site-nav ul.mod-menu__sub li.parent + li.parent { border-top: 1px solid var(--am-border); margin-top: 6px; padding-top: 4px; }
.site-nav > ul > li.parent.deeper-wide > ul.mod-menu__sub { min-width: 520px; column-count: 2; column-gap: 8px; }

.nav-toggle { display: none; width: 46px; height: 46px; padding: 0; border: 1px solid var(--am-border); border-radius: 12px; background: #fff; cursor: pointer; position: relative; }
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; display: block; width: 20px; height: 2px; background: var(--am-green-deep); border-radius: 2px; position: absolute; left: 12px; transition: transform 0.2s, opacity 0.2s; }
.nav-toggle-bars { top: 22px; }
.nav-toggle-bars::before { top: -6px; left: 0; }
.nav-toggle-bars::after { top: 6px; left: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 960px) {
  .nav-toggle { display: block; }
  .site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; max-height: calc(100vh - 84px); overflow-y: auto; background: #fff; border-bottom: 1px solid var(--am-border); box-shadow: var(--am-shadow); padding: 8px var(--am-gutter) 20px; }
  .nav-open .site-nav { display: block; }
  .site-nav ul.mod-menu { flex-direction: column; align-items: stretch; gap: 2px; }
  .site-nav a, .site-nav .nav-header, .site-nav .separator { display: block; padding: 0.8em 0.9em; font-size: 1.05rem; }
  .site-nav > ul > li.active > a::after { display: none; }
  .site-nav a.btn-cta { margin: 8px 0 0; text-align: center; }
  .site-nav ul.mod-menu__sub { position: static; display: block; border: 0; box-shadow: none; padding: 0 0 4px 14px; min-width: 0; column-count: 1 !important; }
  .site-nav li.parent > a::after { float: right; margin-top: 10px; }
}

/* --------------------------------------------------------------------------
   Sections d'accueil
   -------------------------------------------------------------------------- */
.section { padding-block: clamp(52px, 7vw, 92px); }
.section-title { text-align: center; max-width: 760px; margin: 0 auto 2.4rem; }

/* Bannière */
.hero { position: relative; color: #fff; background: var(--am-green-deep); background-image: var(--am-pattern); overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(120% 90% at 85% 20%, rgba(200, 155, 44, 0.22) 0%, rgba(8, 55, 38, 0) 55%); pointer-events: none; }
.hero-inner { position: relative; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(28px, 5vw, 64px); align-items: center; padding-block: clamp(56px, 8vw, 104px); }
.hero h1, .hero h2 { color: #fff; font-size: clamp(2.3rem, 1.6rem + 3vw, 3.8rem); margin-bottom: 0.35em; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 1.1rem; color: var(--am-gold); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.hero-eyebrow::before { content: ""; width: 28px; height: 2px; background: var(--am-gold); }
.hero-lead { font-size: 1.15rem; line-height: 1.65; color: rgba(255, 255, 255, 0.9); max-width: 560px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.8rem; }
.hero-media { position: relative; }
.hero-media::before { content: ""; position: absolute; inset: 18px -18px -18px 18px; border: 2px solid rgba(200, 155, 44, 0.6); border-radius: var(--am-radius); pointer-events: none; }
.hero-photo { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 40% 55%; border-radius: var(--am-radius); box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35); background: var(--hero-image) center / cover no-repeat; }
.hero-photo-img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 40% 55%; border-radius: var(--am-radius); box-shadow: 0 24px 50px rgba(0, 0, 0, 0.35); }
.hero-facts { display: flex; flex-wrap: wrap; gap: 10px 28px; margin: 1.8rem 0 0; padding: 0; list-style: none; color: rgba(255, 255, 255, 0.78); font-size: 0.95rem; }
.hero-facts strong { color: #fff; font-weight: 600; }
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-media { order: -1; max-width: 520px; }
  .hero-media::before { display: none; }
}

/* Bienvenue (article d'accueil) */
.section-welcome { background: var(--am-cream); }
.is-home .section-welcome h1 { font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.25rem); }
.split { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: clamp(28px, 5vw, 56px); align-items: center; }
.split-text { font-size: 1.05rem; }
.split-text p { color: var(--am-muted); }
.split-text p:first-of-type { color: var(--am-ink); font-size: 1.12rem; }
.split-media img { width: 100%; border-radius: var(--am-radius); box-shadow: var(--am-shadow); aspect-ratio: 1; object-fit: cover; }
.is-home .section-welcome .com-content-article > .page-header h1::after,
.is-home .section-welcome .com-content-article > h1::after { content: none; }

/* Horaires de prière */
.section-prayer { background: var(--am-green-deep); background-image: var(--am-pattern); color: #fff; }
.section-prayer .section-title { color: #fff; }
.prayer-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 420px); gap: clamp(24px, 4vw, 56px); align-items: start; }
.prayer-text { font-size: 1.08rem; color: rgba(255, 255, 255, 0.88); }
.prayer-text h3 { color: #fff; }
.prayer-text a { color: var(--am-gold); }
.prayer-widget { background: #fff; border-radius: var(--am-radius); overflow: hidden; box-shadow: 0 20px 44px rgba(0, 0, 0, 0.3); }
.prayer-widget iframe { display: block; width: 100%; height: 560px; border: 0; }
.prayer-note { font-size: 0.85rem; color: rgba(255, 255, 255, 0.65); margin-top: 1rem; }
@media (max-width: 760px) { .prayer-grid { grid-template-columns: 1fr; } }

/* Actualités */
.news-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 28px; }
.news-card { background: #fff; border: 1px solid var(--am-border); border-radius: var(--am-radius); overflow: hidden; display: flex; flex-direction: column; transition: transform 0.2s, box-shadow 0.2s; }
.news-card:hover { transform: translateY(-4px); box-shadow: var(--am-shadow); }
.news-card-media { display: block; aspect-ratio: 16 / 10; background: var(--am-green-soft); overflow: hidden; }
.news-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s; }
.news-card:hover .news-card-media img { transform: scale(1.04); }
.news-card-placeholder { display: block; height: 100%; background: var(--am-green-deep) var(--am-pattern); }
.news-card-body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 6px; }
.news-card-date { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--am-gold-dark); }
.news-card-title { font-size: 1.2rem; margin: 0; }
.news-card-title a { color: var(--am-green-deep); }
.news-card-text { color: var(--am-muted); margin: 0; font-size: 0.97rem; }
.section-more { text-align: center; margin-top: 2rem; }

/* Accès rapides */
.section-quicklinks { background: var(--am-cream); }
.quicklinks { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 22px; }
.quicklink { display: flex; flex-direction: column; gap: 10px; padding: 26px 24px; background: #fff; border: 1px solid var(--am-border); border-radius: var(--am-radius); color: var(--am-ink); text-decoration: none; transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s; }
.quicklink:hover { transform: translateY(-4px); box-shadow: var(--am-shadow); border-color: transparent; text-decoration: none; color: var(--am-ink); }
.quicklink-icon { width: 54px; height: 54px; display: grid; place-items: center; border-radius: 14px; background: var(--am-green-soft); color: var(--am-green); }
.quicklink h3 { margin: 4px 0 0; font-size: 1.15rem; }
.quicklink p { margin: 0; color: var(--am-muted); font-size: 0.95rem; }
.quicklink-more { margin-top: auto; color: var(--am-green); font-weight: 600; font-size: 0.92rem; }

/* Agenda */
.agenda-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; max-width: 860px; margin-inline: auto; }
.agenda-item { display: flex; gap: 20px; align-items: flex-start; padding: 18px 22px; background: #fff; border: 1px solid var(--am-border); border-radius: var(--am-radius); }
.agenda-date { flex: 0 0 72px; text-align: center; padding: 8px 4px; border-radius: 12px; background: var(--am-green-deep); color: #fff; line-height: 1.1; }
.agenda-day { display: block; font-size: 1.7rem; font-weight: 700; font-family: var(--am-serif); }
.agenda-month { display: block; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--am-gold); margin-top: 2px; }
.agenda-title { font-size: 1.15rem; margin-bottom: 0.2em; }
.agenda-text { margin: 0; color: var(--am-muted); font-size: 0.95rem; }

/* Accès et contact */
.section-map { background: #fff; }
.map-grid { display: grid; grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1.1fr); gap: clamp(24px, 4vw, 48px); align-items: stretch; }
.map-card { padding: 28px; background: var(--am-cream); border-radius: var(--am-radius); border: 1px solid var(--am-border); }
.map-card h3 { margin-bottom: 0.3em; }
.map-card address { font-style: normal; margin-bottom: 1rem; }
.map-links { display: flex; flex-wrap: wrap; gap: 10px; margin: 1rem 0 0; padding: 0; list-style: none; }
.map-links a { display: inline-flex; align-items: center; gap: 8px; padding: 0.55em 1em; border-radius: 999px; background: #fff; border: 1px solid var(--am-border); color: var(--am-green-deep); font-weight: 600; font-size: 0.92rem; }
.map-links a:hover { border-color: var(--am-green); text-decoration: none; }
.map-frame { border-radius: var(--am-radius); overflow: hidden; min-height: 320px; box-shadow: var(--am-shadow); }
.map-frame iframe { display: block; width: 100%; height: 100%; min-height: 320px; border: 0; }
@media (max-width: 760px) { .map-grid { grid-template-columns: 1fr; } }

/* --------------------------------------------------------------------------
   Pages intérieures
   -------------------------------------------------------------------------- */
.page { background: var(--am-bg); }
.page-inner { padding-block: clamp(28px, 4vw, 52px) clamp(56px, 7vw, 96px); }
.page-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; }
.has-sidebar .page-grid { grid-template-columns: minmax(0, 1fr) 300px; }
@media (max-width: 900px) { .has-sidebar .page-grid { grid-template-columns: 1fr; } }
.page-content { max-width: 800px; }
.page-content .page-header { margin-bottom: 1.6rem; }
.page-content .page-header h1, .page-content .page-header h2 { margin-bottom: 0.2em; }
.page-content .page-header h1::after, .page-content > h1::after, .com-contact .page-header h2::after, .com-content-category .page-header h1::after, .com-content-categories h1::after {
  content: ""; display: block; width: 64px; height: 10px; margin-top: 12px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 10'%3E%3Cpath d='M0 5h22M42 5h22' stroke='%23c89b2c' stroke-width='1.5'/%3E%3Cpath d='M32 0l5 5-5 5-5-5z' fill='%23c89b2c'/%3E%3C/svg%3E") left center / contain no-repeat;
}
.page-content img { border-radius: 12px; }
.page-content .article-info { color: var(--am-muted); font-size: 0.9rem; }
.page-content dl.article-info { margin-bottom: 1.5rem; }
.page-content .article-info-term { display: none; }
.page-content .article-info dd { display: inline; margin: 0 1em 0 0; }
.page-content ul.actions { display: none; }
.page-content blockquote { padding: 16px 22px; border-left: 4px solid var(--am-gold); background: var(--am-cream); border-radius: 0 12px 12px 0; color: var(--am-ink); }
.page-content table { width: 100%; border-collapse: collapse; }
.page-content th, .page-content td { padding: 0.6em 0.8em; border-bottom: 1px solid var(--am-border); text-align: left; vertical-align: top; }
.page-content th { background: var(--am-cream); }

/* Listes de catégorie (blog) */
.com-content-category-blog .items-row, .blog-items { display: grid; gap: 24px; }
.com-content-category-blog .blog-item, .com-content-category-blog .item-content { padding: 22px 24px; background: #fff; border: 1px solid var(--am-border); border-radius: var(--am-radius); }
.com-content-category-blog .blog-item .page-header h2, .com-content-category-blog .item-content h2 { font-size: 1.35rem; }
.com-content-category-blog .blog-item .page-header h2::after { content: none; }
.com-content-category-blog .readmore .btn { margin-top: 0.5rem; }
.com-content-category-blog .category-desc, .com-content-categories .category-desc { color: var(--am-muted); }
.com-content-categories .com-content-categories__items, .com-content-categories .category { margin-top: 1.5rem; }
.com-content-categories h3 { font-size: 1.25rem; }
.com-content-categories .collapse { display: block !important; }
.com-content-categories .mod-articles-category-category, .com-content-categories .category-item { padding: 18px 22px; background: #fff; border: 1px solid var(--am-border); border-radius: var(--am-radius); margin-bottom: 16px; }
.com-content-categories .category-item ul { margin-bottom: 0; }

/* Lecteur audio (Écouter le Coran) */
.audio-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.audio-item { display: grid; grid-template-columns: 1fr; gap: 8px; padding: 16px 20px; background: var(--am-cream); border: 1px solid var(--am-border); border-radius: 14px; }
.audio-item strong { font-family: var(--am-serif); font-size: 1.1rem; color: var(--am-green-deep); }
.audio-item .arabic { font-size: 1.2rem; margin-left: 10px; color: var(--am-gold-dark); }
.audio-item audio { width: 100%; }

/* Barre latérale */
.card-module { padding: 22px 24px; background: var(--am-cream); border: 1px solid var(--am-border); border-radius: var(--am-radius); margin-bottom: 20px; }
.card-title { font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--am-gold-dark); margin-bottom: 0.8rem; font-family: var(--am-font); font-weight: 700; }
.card-module ul.mod-menu { list-style: none; margin: 0; padding: 0; }
.card-module ul.mod-menu li a, .card-module ul.mod-menu li .nav-header { display: block; padding: 0.45em 0.2em; color: var(--am-ink); border-bottom: 1px solid var(--am-border); }
.card-module ul.mod-menu li:last-child > a { border-bottom: 0; }
.card-module ul.mod-menu li.active > a { color: var(--am-green); font-weight: 600; }
.card-module ul.mod-menu li.parent > .nav-header, .card-module ul.mod-menu li.parent > a { font-family: var(--am-serif); font-size: 1.02rem; color: var(--am-green-deep); font-weight: 600; margin-top: 0.4rem; }
.card-module ul.mod-menu__sub { list-style: none; margin: 0; padding: 0 0 0 12px; }
.card-module .mod-menu__toggle-sub { display: none; }
.card-module iframe { width: 100%; border: 0; border-radius: 10px; }

/* Fil d'Ariane */
.mod-breadcrumbs__wrapper { margin-bottom: 1rem; font-size: 0.9rem; }
ol.mod-breadcrumbs { list-style: none; display: flex; flex-wrap: wrap; gap: 4px; margin: 0; padding: 0; color: var(--am-muted); }
ol.mod-breadcrumbs li + li::before { content: "›"; margin: 0 8px; color: #b8bec6; }
ol.mod-breadcrumbs a { color: var(--am-muted); }
ol.mod-breadcrumbs .divider, ol.mod-breadcrumbs .float-start { display: none; }

/* Page d'erreur / hors ligne */
.error-page { text-align: center; max-width: 620px; margin: 0 auto; padding-block: 24px; }
.error-code { font-size: clamp(5rem, 14vw, 9rem); font-weight: 700; font-family: var(--am-serif); line-height: 1; color: var(--am-gold); margin-bottom: 0.1em; }
.error-page h1::after { display: none; }
.error-page .lead { color: var(--am-muted); font-size: 1.1rem; }
.offline-inner { max-width: 520px; margin: 0 auto; text-align: center; }
.offline-login { text-align: left; margin-top: 2rem; }

/* --------------------------------------------------------------------------
   Formulaires (contact)
   -------------------------------------------------------------------------- */
.com-contact { max-width: 820px; }
.com-contact .page-header h2 { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.2rem); }
.com-contact__container { display: flex; flex-wrap: wrap; gap: 24px; margin-bottom: 1.5rem; }
.com-contact__info { color: var(--am-muted); }
.com-contact dl.contact-address { display: grid; gap: 4px; margin: 0; }
.com-contact dl.contact-address dt { display: none; }
.com-contact dl.contact-address dd { margin: 0; }
.com-contact__miscinfo { margin-bottom: 1.5rem; }
.com-contact__miscinfo h3 { display: none; }
.com-contact .icons, .com-contact__links, .com-contact__tags { display: none; }
.contact-form, .com-contact__form { background: var(--am-cream); border: 1px solid var(--am-border); border-radius: var(--am-radius); padding: clamp(20px, 3vw, 32px); }
.contact-form h3, .com-contact__form legend { font-size: 1.15rem; margin-bottom: 1rem; font-family: var(--am-serif); }
.form-horizontal fieldset, .contact-form fieldset { border: 0; padding: 0; margin: 0 0 0.5rem; min-width: 0; }
legend { padding: 0; font-weight: 700; }
.control-group { margin-bottom: 1rem; }
.control-group .control-label label, .control-group > label, label.form-label { display: block; margin-bottom: 0.35rem; font-weight: 600; font-size: 0.95rem; }
.form-control, input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="url"], input[type="number"], select, textarea {
  display: block; width: 100%; padding: 0.7em 0.9em; font: inherit; color: var(--am-ink); background: #fff;
  border: 1px solid #cfd4d0; border-radius: 10px; transition: border-color 0.15s, box-shadow 0.15s;
}
.form-control:focus, input:focus, select:focus, textarea:focus { outline: none; border-color: var(--am-green); box-shadow: 0 0 0 3px rgba(20, 107, 69, 0.15); }
textarea { min-height: 140px; resize: vertical; }
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 0.9em center; background-size: 14px; padding-right: 2.4em; }
input[type="checkbox"], input[type="radio"] { width: auto; display: inline-block; margin-right: 0.4em; }
.form-check { display: flex; align-items: center; gap: 0.5em; }
.form-check-input { width: 1.1em; height: 1.1em; margin: 0; }
.star, .required-star { color: #b42318; }
.form-control.invalid, input.invalid, textarea.invalid { border-color: #b42318; }
.form-control-feedback, .invalid-feedback { color: #b42318; font-size: 0.875rem; }
.hint, .form-text { color: var(--am-muted); font-size: 0.875rem; }

/* Messages système */
#system-message-container { margin-bottom: 1.5rem; }
.alert, joomla-alert { display: block; padding: 14px 18px; margin-bottom: 1rem; border: 1px solid transparent; border-radius: 12px; background: var(--am-cream); }
.alert .alert-heading { font-weight: 700; margin-bottom: 0.25em; }
.alert-success, joomla-alert[type="success"] { background: #e9f8ee; border-color: #bfe7cd; color: #155c2d; }
.alert-danger, .alert-error, joomla-alert[type="danger"] { background: #fdeaea; border-color: #f4bcbc; color: #7a0b0b; }
.alert-warning, joomla-alert[type="warning"] { background: #fff6e0; border-color: #f6dc9c; color: #6d4b00; }
.alert-info, joomla-alert[type="info"] { background: #e8f1fd; border-color: #bcd4f4; color: #163e7a; }
.alert .btn-close, joomla-alert .joomla-alert--close { float: right; border: 0; background: transparent; font-size: 1.2rem; cursor: pointer; line-height: 1; }

/* --------------------------------------------------------------------------
   Pied de page
   -------------------------------------------------------------------------- */
.site-footer { background: var(--am-green-deep); background-image: var(--am-pattern); color: rgba(255, 255, 255, 0.8); margin-top: auto; }
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--am-gold); text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 40px; padding-block: clamp(44px, 6vw, 68px) clamp(28px, 4vw, 40px); }
.footer-title { color: var(--am-gold); font-family: var(--am-font); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.14em; margin-bottom: 1rem; font-weight: 700; }
.footer-brand { font-family: var(--am-serif); font-size: 1.5rem; color: #fff; margin-bottom: 0.2rem; }
.footer-logo { width: 180px; height: auto; background: #fff; padding: 8px 12px; border-radius: 10px; margin-bottom: 1rem; display: block; }
.footer-module p { margin-bottom: 0.6em; }
.footer-module address { font-style: normal; }
.footer-module ul.mod-menu { list-style: none; margin: 0; padding: 0; }
.footer-module ul.mod-menu li { margin-bottom: 0.4em; }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-links a { display: inline-flex; align-items: center; gap: 10px; }
.footer-links svg { flex: 0 0 auto; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, 0.12); font-size: 0.9rem; }
.footer-bottom-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; padding-block: 18px; }
.footer-bottom p { margin: 0; }
.footer-bottom ul.mod-menu { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 20px; }

.back-to-top { position: fixed; right: 20px; bottom: 20px; z-index: 90; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--am-green-deep); color: #fff; box-shadow: var(--am-shadow); opacity: 0.85; }
.back-to-top:hover { opacity: 1; color: #fff; }

/* Utilitaires */
.text-center { text-align: center; }
.lead { font-size: 1.15rem; }
.d-none { display: none !important; }
.badge { display: inline-block; padding: 0.25em 0.6em; border-radius: 6px; font-size: 0.75rem; font-weight: 700; background: var(--am-cream); }
hr { border: 0; border-top: 1px solid var(--am-border); margin: 2rem 0; }
