/* ============================================================
   Formation-Supracours — style.css
   ============================================================ */

/* === Variables === */
:root {
  --accent:       #C94419;
  --accent-dark:  #A33814;
  --dark:         #1E1E1E;
  --text:         #3D3D3D;
  --muted:        #6B6B6B;
  --light:        #F6F6F6;
  --border:       #E4E4E4;
  --white:        #FFFFFF;
  --max-w:        1100px;
  --nav-h:        68px;
  --radius:       6px;
  --shadow:       0 2px 16px rgba(0,0,0,.08);
}

/* === Reset === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
               'Helvetica Neue', Arial, sans-serif;
  color: var(--text);
  font-size: 16px;
  line-height: 1.65;
  background: var(--white);
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; }

/* === Container === */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* === Typography === */
h1, h2, h3, h4 { line-height: 1.25; color: var(--dark); }
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); font-weight: 700; }
h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 600; }
h4 { font-size: .95rem; font-weight: 600; }
p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 11px 24px;
  background: var(--accent);
  color: var(--white);
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, border-color .2s;
  white-space: nowrap;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.btn-outline {
  background: transparent;
  color: var(--accent);
}
.btn-outline:hover { background: var(--accent); color: var(--white); }
.btn-ghost {
  background: transparent;
  border-color: rgba(255,255,255,.4);
  color: var(--white);
}
.btn-ghost:hover { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.6); }
.btn-sm { padding: 8px 18px; font-size: .82rem; }

/* === Header === */
.site-header {
  position: sticky;
  top: 0;
  height: var(--nav-h);
  background: var(--white);
  border-bottom: 1px solid var(--border);
  z-index: 200;
}
.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.logo img { height: 42px; width: auto; }

/* === Nav === */
.site-nav > ul {
  display: flex;
  align-items: center;
  gap: 2px;
}
.site-nav li > a {
  display: block;
  padding: 8px 14px;
  border-radius: var(--radius);
  font-size: .88rem;
  font-weight: 500;
  color: var(--text);
  transition: color .15s, background .15s;
}
.site-nav li > a:hover { color: var(--accent); background: var(--light); }
.site-nav li > a.active { color: var(--accent); }
.site-nav .btn { padding: 8px 18px; font-size: .85rem; border-radius: var(--radius); }
.site-nav li > a.btn,
.site-nav li > a.btn:visited,
.site-nav li > a.btn.active {
  color: var(--white);
  background: var(--accent);
  border-color: var(--accent);
}
.site-nav li > a.btn:hover,
.site-nav li > a.btn:focus,
.site-nav li > a.btn:active {
  color: var(--white);
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

/* Dropdown */
.has-dropdown { position: relative; }
.dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 240px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .15s, transform .15s, visibility .15s;
  z-index: 10;
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown li a {
  border-radius: 0;
  padding: 10px 18px;
  font-size: .85rem;
  color: var(--text);
}
.dropdown li:first-child a { border-radius: var(--radius) var(--radius) 0 0; }
.dropdown li:last-child a { border-radius: 0 0 var(--radius) var(--radius); }
.dropdown li a:hover { background: var(--light); color: var(--accent); }

/* Hamburger toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius);
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--dark);
  border-radius: 2px;
  transition: transform .22s, opacity .22s;
  display: block;
}
.nav-toggle.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-active span:nth-child(2) { opacity: 0; }
.nav-toggle.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* === Hero (homepage) === */
.hero {
  padding: 88px 0 104px;
  background: var(--light);
  border-bottom: 1px solid var(--border);
}
.hero-tag {
  display: inline-block;
  background: rgba(201,68,25,.1);
  color: var(--accent);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 100px;
  margin-bottom: 20px;
}
.hero h1 { margin-bottom: 18px; max-width: 680px; }
.hero .lead {
  font-size: 1.1rem;
  color: var(--muted);
  margin-bottom: 36px;
  max-width: 560px;
}
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

/* === Page hero (sub-pages) === */
.page-hero {
  padding: 48px 0 52px;
  background: var(--light);
  border-bottom: 1px solid var(--border);
}
.breadcrumb {
  font-size: .78rem;
  color: var(--muted);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.breadcrumb a { color: var(--muted); transition: color .15s; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span { color: var(--border); }
.page-hero h1 { font-size: clamp(1.5rem, 3vw, 2.2rem); margin-bottom: 8px; }
.page-hero .lead { color: var(--muted); font-size: 1rem; }

/* === Section basics === */
.section { padding: 72px 0; }
.section-alt { background: var(--light); }
.section-title { margin-bottom: 48px; }
.section-title h2 { margin-bottom: 10px; }
.section-title .sub { color: var(--muted); max-width: 560px; font-size: 1rem; }

/* === Service Cards Grid === */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: box-shadow .2s, transform .2s;
  display: flex;
  flex-direction: column;
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.card-icon { font-size: 1.7rem; margin-bottom: 14px; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--muted); font-size: .88rem; flex: 1; margin-bottom: 18px; }
.card p a.cpf-link,
.card p a.external-link {
  color: #0b63ce;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.card p a.cpf-link:hover,
.card p a.external-link:hover { color: #084a99; }
.card-link {
  font-size: .85rem;
  font-weight: 600;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: gap .15s;
  margin-top: auto;
}
.card-link:hover { gap: 8px; }

/* === CPF strip === */
.cpf-strip {
  background: var(--accent);
  padding: 40px 0;
}
.cpf-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.cpf-text h3 { color: var(--white); font-size: 1.15rem; margin-bottom: 6px; }
.cpf-text p { color: rgba(255,255,255,.82); margin: 0; font-size: .9rem; }

/* === Approach section === */
.approach-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.steps-list { display: flex; flex-direction: column; gap: 20px; margin-top: 24px; }
.step-item { display: flex; gap: 16px; align-items: flex-start; }
.step-num {
  width: 32px;
  height: 32px;
  background: var(--accent);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .8rem;
  font-weight: 700;
  flex-shrink: 0;
}
.step-item p { font-size: .9rem; color: var(--muted); margin: 4px 0 0; }
.step-item h4 { margin-bottom: 2px; }

/* === Content + Sidebar layout === */
.content-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 48px;
  align-items: start;
}
.sidebar { position: sticky; top: calc(var(--nav-h) + 20px); }
.sidebar-box {
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.sidebar-box h4 {
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--muted);
  margin-bottom: 14px;
}
.sidebar-box ul { display: flex; flex-direction: column; gap: 2px; }
.sidebar-box a {
  display: block;
  padding: 8px 10px;
  border-radius: 4px;
  font-size: .875rem;
  color: var(--text);
  transition: background .15s, color .15s;
}
.sidebar-box a:hover { background: var(--border); }
.sidebar-box a.current { color: var(--accent); font-weight: 600; }
.sidebar-box .btn { width: 100%; justify-content: center; margin-top: 16px; }

/* === Checklist === */
.checklist { display: flex; flex-direction: column; gap: 10px; margin: 20px 0; }
.checklist li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: .9rem;
  color: var(--text);
}
.checklist li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}

/* === Accordion === */
.accordion { display: flex; flex-direction: column; gap: 4px; }
.acc-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.acc-trigger {
  width: 100%;
  text-align: left;
  padding: 16px 20px;
  background: var(--white);
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .95rem;
  font-weight: 600;
  color: var(--dark);
  transition: background .15s, color .15s;
}
.acc-trigger:hover { background: var(--light); }
.acc-trigger.open { color: var(--accent); }
.acc-trigger .caret { font-size: .7rem; transition: transform .2s; }
.acc-trigger.open .caret { transform: rotate(180deg); }
.acc-body {
  display: none;
  padding: 16px 20px 20px;
  font-size: .9rem;
  color: var(--muted);
  border-top: 1px solid var(--border);
}
.acc-body.open { display: block; }
.acc-body p { margin-bottom: .6rem; }
.acc-body ul { margin-top: .5rem; }
.acc-body li {
  padding: 3px 0 3px 14px;
  position: relative;
  font-size: .88rem;
}
.acc-body li::before { content: '–'; position: absolute; left: 0; color: var(--accent); }

/* === Engagements grid === */
.eng-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 24px;
}
.eng-item { display: flex; gap: 14px; align-items: flex-start; }
.eng-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  background: rgba(201,68,25,.08);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
}
.eng-item h4 { margin-bottom: 3px; font-size: .92rem; }
.eng-item p { font-size: .85rem; color: var(--muted); margin: 0; }

/* === Concours list === */
.concours-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 28px 0;
}
.citem {
  background: var(--light);
  border-radius: var(--radius);
  padding: 18px 20px;
  border-left: 3px solid var(--accent);
}
.citem h4 { color: var(--dark); margin-bottom: 4px; font-size: .9rem; }
.citem p { font-size: .82rem; color: var(--muted); margin: 0; }

/* === Modules === */
.module-list { display: flex; flex-direction: column; gap: 14px; margin-top: 24px; }
.module {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  align-items: start;
}
.module-num {
  width: 36px;
  height: 36px;
  background: var(--accent);
  color: var(--white);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: .85rem;
  flex-shrink: 0;
}
.module h4 { margin-bottom: 2px; }
.module .hours { font-size: .78rem; color: var(--accent); font-weight: 600; margin-bottom: 6px; display: block; }
.module p { font-size: .85rem; color: var(--muted); margin: 0; }

/* === CECRL === */
.cecrl-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 28px;
}
.cecrl-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.cecrl-level { font-size: 1.6rem; font-weight: 700; color: var(--accent); }
.cecrl-label { font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: 2px 0 12px; }
.cecrl-card p { font-size: .83rem; color: var(--text); }

/* === Software list (bureautique) === */
.software-section { margin-bottom: 40px; }
.software-section h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border);
  margin-bottom: 16px;
}
.software-section h3 .icon { font-size: 1.1rem; }
.course-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.tag {
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 4px 12px;
  font-size: .8rem;
  color: var(--text);
}

/* === Contact form === */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.contact-info h3 { margin-bottom: 20px; }
.info-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 20px;
}
.info-icon {
  width: 40px;
  height: 40px;
  background: rgba(201,68,25,.08);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.info-item h4 { font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 2px; }
.info-item a { color: var(--text); font-weight: 500; }
.info-item a:hover { color: var(--accent); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 5px; margin-bottom: 16px; }
.form-group.full { grid-column: 1 / -1; }
label { font-size: .82rem; font-weight: 600; color: var(--dark); }
input[type=text],
input[type=email],
input[type=tel],
select,
textarea {
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 13px;
  font-size: .9rem;
  font-family: inherit;
  color: var(--text);
  background: var(--white);
  width: 100%;
  transition: border-color .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }
textarea { min-height: 130px; resize: vertical; }
.form-hidden { display: none; }
.alert {
  padding: 14px 18px;
  border-radius: var(--radius);
  margin-bottom: 20px;
  font-size: .88rem;
}
.alert-ok { background: #edf7f1; border: 1px solid #9dd4b4; color: #1a5e36; }
.alert-err { background: #fef2f2; border: 1px solid #fca5a5; color: #7f1d1d; }

/* === CTA section === */
.cta-section {
  text-align: center;
  padding: 72px 0;
  background: var(--light);
}
.cta-section h2 { margin-bottom: 12px; }
.cta-section p { color: var(--muted); margin-bottom: 28px; max-width: 500px; margin-left: auto; margin-right: auto; }
.cta-btns { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }

/* === Footer === */
.site-footer {
  background: var(--dark);
  color: rgba(255,255,255,.75);
  padding-top: 60px;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
}
.footer-brand-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: rgba(255,255,255,.95);
  margin-bottom: 8px;
  letter-spacing: -.01em;
}
.footer-brand-name em { color: var(--accent); font-style: normal; }
.footer-brand p { font-size: .85rem; color: rgba(255,255,255,.5); }
.footer-col h4 {
  font-size: .7rem;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: rgba(255,255,255,.35);
  margin-bottom: 16px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 8px; }
.footer-col a {
  font-size: .85rem;
  color: rgba(255,255,255,.65);
  transition: color .15s;
}
.footer-col a:hover { color: var(--white); }
.footer-col p { font-size: .85rem; margin-bottom: 6px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 18px 0;
}
.footer-bottom p { font-size: .78rem; color: rgba(255,255,255,.3); }

/* === Responsive === */
@media (max-width: 960px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .content-grid { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .approach-grid { grid-template-columns: 1fr; }
  .concours-grid { grid-template-columns: 1fr; }
  .cecrl-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  .nav-toggle { display: flex; }
  .site-nav {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0; right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    padding: 12px 0 20px;
    box-shadow: var(--shadow);
    z-index: 199;
  }
  .site-nav.open { display: block; }
  .site-nav > ul { flex-direction: column; gap: 0; }
  .site-nav li > a { border-radius: 0; padding: 13px 24px; border-bottom: 1px solid var(--border); font-size: .9rem; }
  .site-nav li:last-child > a { border: none; }
  .has-dropdown .caret { float: right; }
  .dropdown {
    position: static;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    box-shadow: none;
    border: none;
    border-radius: 0;
    display: none;
    background: var(--light);
  }
  .dropdown.open { display: block; }
  .dropdown li a { padding: 11px 36px; font-size: .85rem; border-bottom: 1px solid var(--border); }
  .cards-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .eng-grid { grid-template-columns: 1fr; }
  .cecrl-grid { grid-template-columns: 1fr; }
  .cpf-inner { flex-direction: column; align-items: flex-start; }
  .footer-inner { grid-template-columns: 1fr; gap: 28px; }
  .hero { padding: 60px 0 72px; }
  .section { padding: 52px 0; }
}
