/* ==========================================================================
   Institut Supérieur Plus Oultre — feuille de style principale
   Palette conservée du site original (WebAcappella) :
   fond crème #fef4e8, accent orange #ea5b0c, accent doux #fddfbc
   ========================================================================== */

:root {
  --color-bg: #fef4e8;
  --color-surface: #ffffff;
  --color-surface-soft: #fffaf2;
  --color-accent: #ea5b0c;
  --color-accent-dark: #c94a08;
  --color-accent-soft: #fddfbc;
  --color-text: #3a2f22;
  --color-text-muted: #7a7a7a;
  --color-border: #f0ddc4;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 2px 8px rgba(58, 47, 34, 0.08);
  --shadow-md: 0 10px 30px rgba(58, 47, 34, 0.12);
  --font-head: "Poppins", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, sans-serif;
  --header-h: 84px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--color-accent-dark); text-decoration: none; }
a:hover { color: var(--color-accent); }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  line-height: 1.25;
  margin: 0 0 0.6em;
  font-weight: 600;
  color: var(--color-text);
}
h1 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
ul { margin: 0 0 1em; padding-left: 1.2em; }
li { margin-bottom: 0.4em; }

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 2000;
  background: var(--color-accent); color: #fff; padding: 10px 18px;
  border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; color: #fff; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; padding: 13px 26px; border-radius: 999px;
  font-family: var(--font-head); font-weight: 600; font-size: 0.95rem;
  border: 2px solid transparent; cursor: pointer; transition: all .18s ease;
}
.btn-primary { background: var(--color-accent); color: #fff; }
.btn-primary:hover { background: var(--color-accent-dark); color: #fff; transform: translateY(-2px); }
.btn-outline { background: transparent; color: var(--color-accent-dark); border-color: var(--color-accent-soft); }
.btn-outline:hover { background: var(--color-accent-soft); color: var(--color-accent-dark); }
.btn-light { background: #fff; color: var(--color-accent-dark); }
.btn-light:hover { background: var(--color-accent-soft); }
.btn-sm { padding: 8px 18px; font-size: 0.85rem; }

/* ---------- En-tête / navigation ---------- */
.site-header {
  position: sticky; top: 0; z-index: 900;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
}
/* backdrop-filter est volontairement évité ici : il transformerait le header
   en bloc conteneur pour ses descendants "position: fixed" (le menu mobile
   plein écran), ce qui casserait son affichage sur petits écrans. */
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand img { height: 52px; width: auto; }
.brand-text { font-family: var(--font-head); font-weight: 700; line-height: 1.15; color: var(--color-text); }
.brand-text small { display: block; font-weight: 400; font-size: 0.7rem; color: var(--color-text-muted); text-transform: uppercase; letter-spacing: .05em; }

.nav-toggle {
  display: none; background: none; border: none; cursor: pointer;
  width: 44px; height: 44px; position: relative; z-index: 1100;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; position: absolute; left: 10px; right: 10px; height: 2px;
  background: var(--color-text); transition: all .25s ease;
}
.nav-toggle span { top: 21px; }
.nav-toggle span::before { top: -8px; }
.nav-toggle span::after { top: 8px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: rotate(45deg); top: 0; }
.nav-toggle[aria-expanded="true"] span::after { transform: rotate(-45deg); top: 0; }

.main-nav > ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.main-nav > ul > li { position: relative; }
.main-nav > ul > li > a, .main-nav > ul > li > button.nav-link {
  display: flex; align-items: center; gap: 6px; padding: 10px 14px;
  border-radius: 999px; font-family: var(--font-head); font-weight: 500;
  font-size: 0.95rem; color: var(--color-text); background: none; border: none;
  cursor: pointer; white-space: nowrap;
}
.main-nav > ul > li > a:hover, .main-nav > ul > li > button.nav-link:hover,
.main-nav > ul > li.is-open > button.nav-link { background: var(--color-accent-soft); color: var(--color-accent-dark); }
.main-nav .caret { width: 9px; height: 9px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s ease; margin-top: -3px; }
.main-nav li.is-open .caret { transform: rotate(-135deg); margin-top: 3px; }

.dropdown {
  list-style: none; margin: 0; padding: 10px; position: absolute; top: calc(100% + 8px); left: 0;
  min-width: 280px; background: #fff; border-radius: var(--radius-md);
  box-shadow: var(--shadow-md); display: none; border: 1px solid var(--color-border);
}
li.is-open > .dropdown { display: block; }
.dropdown li a { display: block; padding: 9px 12px; border-radius: var(--radius-sm); font-size: 0.92rem; color: var(--color-text); }
.dropdown li a:hover { background: var(--color-bg); color: var(--color-accent-dark); }

.cta-link { background: var(--color-accent) !important; color: #fff !important; margin-left: 6px; }
.cta-link:hover { background: var(--color-accent-dark) !important; }

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .main-nav {
    position: fixed; inset: 0; top: var(--header-h); background: var(--color-bg);
    transform: translateX(100%); transition: transform .25s ease; overflow-y: auto;
    padding: 20px 0 60px;
  }
  .main-nav.is-open { transform: translateX(0); }
  .main-nav > ul { flex-direction: column; align-items: stretch; padding: 0 20px; gap: 2px; }
  .main-nav > ul > li > a, .main-nav > ul > li > button.nav-link { width: 100%; justify-content: space-between; padding: 14px 16px; }
  .dropdown { position: static; box-shadow: none; border: none; background: var(--color-surface-soft); margin: 4px 0 8px; }
  .cta-link { margin-left: 0; margin-top: 10px; text-align: center; justify-content: center; }
}

/* ---------- Hero (accueil) ---------- */
.hero {
  position: relative; color: #fff; overflow: hidden;
  background: linear-gradient(135deg, #2c2013 0%, #4a3419 55%, var(--color-accent-dark) 130%);
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(234,91,12,.35), transparent 55%);
}
.hero-inner { position: relative; z-index: 1; padding: 90px 24px 100px; max-width: 900px; margin: 0 auto; text-align: center; }
.hero h1 { color: #fff; }
.hero p.lead { font-size: 1.15rem; color: #f3e6d3; max-width: 640px; margin: 0 auto 2em; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Bandeau de page (pages intérieures) ---------- */
.page-band {
  background: linear-gradient(120deg, var(--color-accent-soft), #fef4e8 65%);
  border-bottom: 1px solid var(--color-border);
  padding: 56px 0 40px;
}
.breadcrumb { font-size: 0.85rem; color: var(--color-text-muted); margin-bottom: 10px; }
.breadcrumb a { color: var(--color-text-muted); }
.breadcrumb a:hover { color: var(--color-accent-dark); }
.page-band h1 { margin-bottom: 0.2em; }
.page-band .subtitle { color: var(--color-text-muted); font-size: 1.05rem; max-width: 60ch; }

/* ---------- Sections génériques ---------- */
main { display: block; }
.section { padding: 64px 0; }
.section-tight { padding: 40px 0; }
.section-alt { background: var(--color-surface-soft); }
.section-title { text-align: center; max-width: 700px; margin: 0 auto 44px; }
.section-title h2 { margin-bottom: .3em; }
.section-title p { color: var(--color-text-muted); }
.eyebrow {
  display: inline-block; font-family: var(--font-head); font-weight: 600; font-size: .78rem;
  letter-spacing: .08em; text-transform: uppercase; color: var(--color-accent-dark);
  background: var(--color-accent-soft); padding: 5px 14px; border-radius: 999px; margin-bottom: 14px;
}

.prose { max-width: 76ch; }
.prose p { color: var(--color-text); }

/* ---------- Cartes formation (grille photos) ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 22px; }
.photo-card {
  position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4/3.1;
  box-shadow: var(--shadow-sm); background: #ddd;
}
.photo-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.photo-card:hover img { transform: scale(1.06); }
.photo-card::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(0deg, rgba(30,20,8,.82) 0%, rgba(30,20,8,.15) 55%, transparent 75%);
}
.photo-card .label {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; padding: 18px;
  color: #fff; font-family: var(--font-head); font-weight: 600; font-size: 1.02rem;
}
.photo-card .label span { display: block; font-family: var(--font-body); font-weight: 400; font-size: .8rem; color: var(--color-accent-soft); margin-top: 2px; }
.photo-card { display: block; }

/* ---------- Infos pratiques (icônes) ---------- */
.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.info-card {
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg);
  padding: 28px; box-shadow: var(--shadow-sm);
}
.info-card .icon {
  width: 52px; height: 52px; border-radius: var(--radius-sm); background: var(--color-accent-soft);
  display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.info-card .icon img { width: 28px; height: 28px; object-fit: contain; }
.info-card h3 { margin-bottom: .5em; }
.info-card ul { padding-left: 1.1em; }
.info-card ul li::marker { color: var(--color-accent); }

/* ---------- Liste de documents ---------- */
.doc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.doc-list li { margin: 0; }
.doc-link {
  display: flex; align-items: center; gap: 12px; padding: 13px 16px;
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-md); color: var(--color-text); font-size: .93rem; font-weight: 500;
}
.doc-link:hover { border-color: var(--color-accent); color: var(--color-accent-dark); background: var(--color-surface-soft); }
.doc-link .doc-ic {
  flex: none; width: 34px; height: 34px; border-radius: 8px; background: var(--color-accent-soft);
  color: var(--color-accent-dark); display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-weight: 700; font-size: .62rem;
}

/* ---------- Callout / bandeau CTA ---------- */
.callout {
  background: linear-gradient(120deg, var(--color-accent-dark), var(--color-accent));
  color: #fff; border-radius: var(--radius-lg); padding: 44px; text-align: center;
}
.callout h2 { color: #fff; }
.callout p { color: #ffe6cc; }

/* ---------- Partenaires ---------- */
.partners-strip { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 36px; }
.partners-strip img { height: 54px; width: auto; max-width: 140px; object-fit: contain; filter: grayscale(45%); opacity: .85; transition: all .2s ease; }
.partners-strip img:hover { filter: none; opacity: 1; }

/* ---------- Contacts ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 22px; }
.contact-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 26px; }
.contact-card h3 { color: var(--color-accent-dark); font-size: 1rem; text-transform: uppercase; letter-spacing: .04em; }
.contact-card a { display: block; color: var(--color-text); }
.contact-card a:hover { color: var(--color-accent-dark); }

/* ---------- Simple list (procedures, points) ---------- */
.check-list { list-style: none; padding: 0; display: grid; gap: 12px; }
.check-list li { position: relative; padding-left: 30px; }
.check-list li::before {
  content: "✓"; position: absolute; left: 0; top: -1px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--color-accent-soft); color: var(--color-accent-dark); font-size: .7rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

/* ---------- Sub-nav (pages hub) ---------- */
.sub-links { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; }
.sub-link-card {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md);
  padding: 20px 22px; font-family: var(--font-head); font-weight: 600; color: var(--color-text);
}
.sub-link-card:hover { border-color: var(--color-accent); background: var(--color-surface-soft); color: var(--color-accent-dark); }
.sub-link-card .arrow { color: var(--color-accent); font-size: 1.2rem; }

/* ---------- Notice / alerte ---------- */
.notice {
  background: var(--color-surface-soft); border: 1px dashed var(--color-border); border-radius: var(--radius-md);
  padding: 18px 22px; color: var(--color-text-muted); font-size: .92rem;
}

/* ---------- Pied de page ---------- */
.site-footer { background: #2c2013; color: #e7dbc9; padding: 60px 0 0; margin-top: 80px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 36px; padding-bottom: 40px; }
.footer-grid h4 { color: #fff; font-size: .95rem; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 1em; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-grid a { color: #e7dbc9; }
.footer-grid a:hover { color: var(--color-accent-soft); }
.footer-brand img { height: 44px; margin-bottom: 14px; filter: brightness(0) invert(1); opacity: .9; }
.footer-brand p { color: #c9b99c; font-size: .9rem; max-width: 32ch; }
.social-row { display: flex; gap: 10px; margin-top: 14px; }
.social-row a {
  width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,.08);
  display: flex; align-items: center; justify-content: center; color: #fff;
}
.social-row a:hover { background: var(--color-accent); }
.social-row svg { width: 18px; height: 18px; fill: currentColor; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12); padding: 18px 0 26px;
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between;
  color: #a8987b; font-size: .82rem;
}
.footer-bottom a { color: #a8987b; }
.footer-bottom a:hover { color: var(--color-accent-soft); }

@media (max-width: 820px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
  .hero-inner { padding: 64px 20px 76px; }
  .callout { padding: 30px 22px; }
}

/* ---------- Accueil : bloc à propos ---------- */
.about-split { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
@media (max-width: 860px) { .about-split { grid-template-columns: 1fr; } }
.about-split .photo-frame { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); }

/* ---------- Utilitaires ---------- */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }
