/* BestSolar — réplique statique HTML/CSS */
@import url("../assets/fonts/flaticon/flaticon.css");

@font-face {
  font-family: "Font Awesome 5 Brands";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("../assets/fonts/webfonts/fa-brands-400.woff2") format("woff2"),
       url("../assets/fonts/webfonts/fa-brands-400.woff") format("woff");
}
.fab { font-family: "Font Awesome 5 Brands"; font-style: normal; font-weight: 400; line-height: 1; -webkit-font-smoothing: antialiased; display: inline-block; }
.fa-instagram::before { content: "\f16d"; }
.fa-facebook-f::before { content: "\f39e"; }
.fa-facebook::before { content: "\f09a"; }
.fa-linkedin-in::before { content: "\f0e1"; }
.fa-linkedin::before { content: "\f08c"; }

:root {
  --orange: #ff7029;
  --green: #57b33e;
  --green-btn: #5cb85c;
  --dark: #232323;
  --text: #616161;
  --footer: #1f242c;
  --light: #f7f7f7;
  --container: 1170px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Mulish", "Muli", sans-serif;
  font-size: 16px;
  line-height: 1.875;
  color: var(--text);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: color .3s, background-color .3s; }
h1, h2, h3, h4 { color: var(--dark); font-weight: 800; margin: 0; line-height: 1.25; }
p { margin: 0 0 1.25em; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 15px; }

/* ---------- Top bar ---------- */
.topbar { background: var(--footer); color: #c9c9c9; font-size: 14px; }
.topbar .inner { display: flex; justify-content: space-between; align-items: center; height: 48px; padding: 0 10px; }
.topbar .left, .topbar .right { display: flex; align-items: center; gap: 14px; }
.topbar .phone { color: var(--orange); font-weight: 800; }
.topbar a:hover { color: #fff; }
.topbar .links { display: flex; gap: 14px; margin-right: 30px; }
.topbar .socials { display: flex; gap: 18px; font-size: 12px; color: #fff; }

/* ---------- Header ---------- */
.header { background: #fff; position: relative; z-index: 50; box-shadow: 0 1px 0 rgba(0,0,0,.06); }
.header .inner { display: flex; align-items: center; height: 120px; padding-left: 25px; }
.header .logo img { width: 175px; }
.nav { flex: 1; display: flex; justify-content: center; }
.nav ul { list-style: none; margin: 0 0 0 40px; padding: 0; display: flex; gap: 56px; }
.nav a {
  position: relative; display: block; line-height: 120px;
  font-size: 17px; font-weight: 700; color: var(--dark); text-transform: uppercase;
}
.nav a::before {
  content: ""; position: absolute; left: -32px; top: 50%; width: 0; height: 2px;
  background: var(--green); transition: width .3s;
}
.nav a:hover::before, .nav a.active::before { width: 20px; }
.header .tools { display: flex; align-items: center; gap: 36px; margin-right: 40px; font-size: 18px; color: var(--dark); }
.header .tools .cart { position: relative; }
.cart-icon { width: 20px; height: 20px; }
.burger {
  width: 120px; height: 120px; background: var(--orange); border: 0; cursor: pointer;
  display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px;
}
.burger span { width: 22px; height: 2px; background: #fff; display: block; }

/* Side panel */
.side-panel {
  position: fixed; top: 0; right: 0; height: 100%; width: 370px; background: #fff;
  transform: translateX(100%); transition: transform .45s ease; z-index: 200;
  display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px;
  text-align: center;
}
.side-panel .close {
  position: absolute; top: 0; left: -80px; width: 80px; height: 80px; background: var(--orange);
  color: #fff; border: 0; font-size: 28px; cursor: pointer; opacity: 0; transition: opacity .3s;
}
.side-panel .logo-burger { width: 180px; background: var(--footer); padding: 20px; border-radius: 4px; margin-bottom: 30px; }
.side-panel p { margin: 0 0 6px; }
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); opacity: 0; visibility: hidden; transition: .4s; z-index: 150; }
body.panel-open .side-panel { transform: none; }
body.panel-open .side-panel .close { opacity: 1; }
body.panel-open .overlay { opacity: 1; visibility: visible; }

/* Search */
.search-overlay {
  position: fixed; inset: 0; background: rgba(31,36,44,.96); z-index: 300; display: flex; align-items: center;
  justify-content: center; opacity: 0; visibility: hidden; transition: .3s;
}
.search-overlay.open { opacity: 1; visibility: visible; }
.search-overlay input {
  width: min(700px, 90vw); background: transparent; border: 0; border-bottom: 2px solid #fff;
  font: 700 36px "Mulish", sans-serif; color: #fff; padding: 10px 0; outline: none;
}
.search-overlay .close-search { position: absolute; top: 30px; right: 40px; background: none; border: 0; color: #fff; font-size: 40px; cursor: pointer; }

/* Mobile header */
.mobile-header { display: none; background: var(--footer); height: 78px; align-items: center; justify-content: space-between; padding: 0 25px; color: #fff; }
.mobile-header .logo img { width: 76px; }
.mobile-header button { background: none; border: 0; color: #fff; cursor: pointer; font-size: 18px; padding: 8px; }
.mobile-header .hamb span { display: block; width: 18px; height: 2px; background: #fff; margin: 3px 0; }
.mobile-menu { display: none; background: var(--footer); }
.mobile-menu.open { display: block; }
.mobile-menu a { display: block; color: #fff; padding: 14px 25px; border-top: 1px solid rgba(255,255,255,.08); font-weight: 700; text-transform: uppercase; font-size: 15px; }
.mobile-menu a.active { color: var(--orange); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: 14px 28px; border-radius: 0; font-weight: 700; color: #fff;
  background: var(--orange); box-shadow: 0 10px 20px rgba(0,0,0,.1); transition: .3s; border: 0; cursor: pointer; font-family: inherit; font-size: 16px;
}
.btn:hover { transform: translateY(-2px); filter: brightness(1.05); }
.btn--green { background: var(--green); }
.btn--lg { font-size: 18px; font-weight: 400; padding: 20px 26px; border-radius: 3px; background: var(--green-btn); }
.phone-link { display: inline-flex; align-items: center; gap: 12px; font-weight: 800; color: var(--dark); }
.phone-link i { color: var(--orange); font-size: 22px; }
.phone-link--green i { color: var(--green); }

/* ---------- Hero (accueil) ---------- */
.hero {
  position: relative; overflow: hidden; height: 820px;
  background: #fdfdfd url("../assets/img/Slide3.jpg") center 35% / auto 108% no-repeat;
}
.hero__deco { position: absolute; width: 781px; right: -680px; top: -245px; opacity: .9; pointer-events: none; }
.hero__content { position: absolute; left: 60%; top: 50%; transform: translateY(-50%); max-width: 640px; }
.hero__bg-text {
  position: absolute; top: -100px; left: -60px; font: 800 180px/1 "Poppins", sans-serif;
  color: transparent; -webkit-text-stroke: 1px rgba(35,35,35,.08); white-space: nowrap; z-index: 0;
}
.hero h1 { position: relative; font-size: 100px; line-height: 1; font-weight: 900; color: var(--dark); }
.hero__lead { position: relative; font-size: 22px; line-height: 30px; color: var(--dark); margin: 22px 0 28px; }
.hero__actions { position: relative; display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }

/* ---------- Counters ---------- */
.counters { background: var(--light); }
.counters .grid { display: grid; grid-template-columns: repeat(4, 1fr); max-width: none; padding: 0 40px; }
.counter { display: flex; gap: 22px; padding: 40px 30px 30px; position: relative; }
.counter + .counter::before { content: ""; position: absolute; left: 0; bottom: 20px; height: 20px; border-left: 1px solid #e0e0e0; }
.counter i { color: var(--orange); font-size: 48px; line-height: 1; }
.counter .num { font-size: 24px; font-weight: 800; color: var(--dark); line-height: 1.2; }
.counter .label { font-size: 16px; line-height: 30px; max-width: 160px; }

/* ---------- Double heading (texte en filigrane) ---------- */
.dbl { position: relative; }
.dbl__bg {
  position: absolute; font: 700 150px/1 "Poppins", sans-serif; color: transparent;
  -webkit-text-stroke: 1px rgba(214,214,214,.5); text-transform: uppercase; white-space: nowrap; z-index: 0;
  top: -50px; left: 50%; transform: translateX(-50%); pointer-events: none;
}
.dbl--left .dbl__bg { left: -10px; transform: none; }
.dbl__sub { position: relative; color: var(--green); font-weight: 700; font-size: 18px; line-height: 40px; }
.dbl--left .dbl__sub { padding-left: 8px; border-left: 2px solid var(--green); line-height: 1.3; margin-bottom: 6px; }
.dbl__title { position: relative; font-size: 36px; line-height: 48px; }

/* ---------- About teaser (accueil) ---------- */
.about-teaser { text-align: center; padding: 130px 0 110px; }
.about-teaser p { max-width: 830px; margin: 20px auto 40px; }

/* ---------- Page title ---------- */
.page-title {
  height: 350px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  background-position: center; background-size: cover; position: relative;
}
.page-title::before { content: ""; position: absolute; inset: 0; background: rgba(35,35,35,.35); }
.page-title > * { position: relative; }
.page-title h1 { color: #fefefe; font-size: 52px; line-height: 1; }
.breadcrumbs { color: #fff; font-size: 14px; margin-top: 22px; }
.breadcrumbs span { margin: 0 10px; }

/* ---------- Qui sommes-nous ---------- */
.about { padding: 150px 0 120px; }
.about .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; }
.about .text { max-width: 480px; }
.about .dbl { margin-bottom: 30px; }
.about .dbl__bg { top: -40px; font-size: 140px; }
.about h2 { font-size: 36px; margin: 40px 0 16px; }
.about h2:first-of-type { margin-top: 10px; }
.about p, .about li { font-size: 15px; line-height: 1.85; }
.about ul { padding-left: 18px; margin: 0 0 1.25em; }
.about li { line-height: 2.2; }
.about .actions { display: flex; align-items: center; gap: 28px; margin-top: 40px; }
.about-images { position: relative; height: 521px; }
.about-images img { position: absolute; top: 0; left: 0; width: 572px; }

/* ---------- Médias ---------- */
.medias { padding: 130px 0 160px; }
.medias .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; }
.medias .dbl__bg { font-size: 130px; top: -55px; left: -30px; }
.medias .dbl__sub { font-size: 15px; text-transform: uppercase; }
.medias .dbl__title { font-size: 36px; }
.medias p { margin-top: 26px; font-size: 15px; }
.downloads { list-style: none; padding: 0; margin: 0; }
.downloads li { position: relative; padding-left: 20px; font-size: 15px; line-height: 2.5; }
.downloads li::before { content: ""; position: absolute; left: 6px; top: 50%; width: 5px; height: 5px; border-radius: 50%; background: var(--dark); }
.downloads a { color: var(--orange); }
.downloads a:hover { color: var(--green); }
.media-card { max-width: 500px; box-shadow: 0 10px 40px rgba(0,0,0,.12); background: #fff; }
.media-card img { width: 100%; height: 375px; object-fit: cover; }
.media-card .caption {
  position: relative; padding: 30px 20px 26px; text-align: center; font-size: 24px; font-weight: 800; color: var(--dark); line-height: 1.4;
  background: url("../assets/img/history_01-2.png") 4px 6px / 50px no-repeat;
}
.media-card .caption em { font-style: normal; color: var(--orange); }

/* ---------- Contact ---------- */
.contact { padding: 160px 0 120px; }
.contact .grid { display: grid; grid-template-columns: 280px 1fr; gap: 0; align-items: start; }
.contact .dbl__bg { font-size: 150px; top: -70px; left: -20px; }
.contact .dbl__title { font-size: 30px; }
.contact-info { list-style: none; padding: 0; margin: 30px 0; }
.contact-info li { display: flex; gap: 20px; margin-bottom: 22px; font-size: 15px; line-height: 1.95; }
.contact-info i { color: var(--orange); font-size: 22px; line-height: 1.4; }
.contact-info .tel { color: var(--dark); font-weight: 800; }
.socials-round { display: flex; gap: 14px; }
.socials-round a {
  width: 36px; height: 36px; border-radius: 50%; border: 1px solid #e3e3e3; display: flex; align-items: center; justify-content: center;
  font-size: 12px; color: #888;
}
.socials-round a:hover { background: var(--orange); border-color: var(--orange); color: #fff; }
.form-card { background: #fff; box-shadow: 0 10px 40px rgba(0,0,0,.1); padding: 50px 50px 30px; margin-top: -10px; }
.form-card h3 { font-size: 30px; margin-bottom: 30px; }
.form-card .row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-card input, .form-card textarea {
  width: 100%; border: 1px solid #e1e1e1; padding: 12px 20px; font: 400 15px "Mulish", sans-serif; color: var(--dark);
  margin-bottom: 20px; outline: none; border-radius: 0; transition: border-color .3s;
}
.form-card input:focus, .form-card textarea:focus { border-color: var(--orange); }
.form-card textarea { height: 120px; resize: vertical; }
.form-card .btn { padding: 18px 30px; margin-bottom: 20px; }
.form-status { font-size: 14px; color: var(--green); }
.map iframe { display: block; width: 100%; height: 500px; border: 0; filter: grayscale(1); }

/* ---------- Footer ---------- */
.footer { background: var(--footer); }
.footer .spacer { height: 98px; border-bottom: 1px solid rgba(255,255,255,.08); }
.footer .copy { color: #9f9f9f; font-size: 14px; padding: 23px 0 25px; margin: 0; }

.scroll-top {
  position: fixed; right: 20px; bottom: 20px; width: 70px; height: 70px; border-radius: 50%; background: var(--orange); color: #fff;
  font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: 16px; z-index: 100; border: 0; cursor: pointer;
  opacity: 0; visibility: hidden; transition: .3s; box-shadow: 0 10px 20px rgba(255,112,41,.3);
}
.scroll-top.visible { opacity: 1; visibility: visible; }

/* ---------- Responsive ---------- */
@media (max-width: 1440px) {
  .hero__content { left: 58%; }
}
@media (max-width: 1200px) {
  .nav ul { gap: 32px; }
  .hero h1 { font-size: 76px; }
  .hero__bg-text { font-size: 140px; }
  .hero__content { left: 54%; }
}
@media (max-width: 1024px) {
  .topbar, .header { display: none; }
  .mobile-header { display: flex; }
  .hero { height: auto; min-height: 640px; background-size: auto 100%; }
  .hero__content { position: relative; left: auto; top: auto; transform: none; margin: 0 0 0 auto; padding: 120px 30px; width: 55%; }
  .counters .grid { grid-template-columns: repeat(2, 1fr); }
  .about .grid, .medias .grid, .contact .grid { grid-template-columns: 1fr; }
  .about-images { height: auto; aspect-ratio: 572 / 521; max-width: 572px; }
  .about-images img { width: 100%; }
  .contact .form-card { margin-top: 30px; }
}
@media (max-width: 767px) {
  .hero { background-position: 20% center; }
  .hero__content { width: 100%; padding: 330px 20px 60px; background: linear-gradient(transparent 300px, rgba(255,255,255,.92) 300px); }
  .hero h1 { font-size: 52px; }
  .hero__bg-text { font-size: 90px; top: -50px; left: 0; }
  .hero__lead { font-size: 18px; }
  .counters .grid { grid-template-columns: 1fr; }
  .counter + .counter::before { display: none; }
  .dbl__bg { font-size: 70px !important; top: -20px !important; }
  .about, .medias, .contact { padding: 80px 0; }
  .about-teaser { padding: 80px 0; }
  .page-title { height: 220px; }
  .page-title h1 { font-size: 36px; }
  .form-card { padding: 30px 20px 10px; }
  .form-card .row { grid-template-columns: 1fr; gap: 0; }
  .media-card img { height: 260px; }
  .side-panel { width: 85vw; }
  .scroll-top { width: 54px; height: 54px; font-size: 14px; }
}

/* ---------- Animations d'apparition ---------- */
/* Hero : reprend les calques Slider Revolution (décalage d'entrée, durée, délai) */
@keyframes appear { from { opacity: 0; translate: var(--from, none); } }
@keyframes spin { to { rotate: 360deg; } }
.hero h1 { --from: 0 -50px; animation: appear 1.1s cubic-bezier(.645,.045,.355,1) .3s both; }
.hero__lead { --from: 0 50px; animation: appear 1.1s cubic-bezier(.645,.045,.355,1) .8s both; }
.hero__bg-text { --from: 0 -50px; animation: appear 1.1s cubic-bezier(.645,.045,.355,1) 1.3s both; }
.hero__actions { animation: appear 1.5s cubic-bezier(.77,0,.175,1) 1.8s both; }
.hero__deco { --from: 50px 0; animation: appear 1s cubic-bezier(.645,.045,.355,1) 2.3s both, spin 100s linear 3.3s infinite; }

/* Images superposées (Qui sommes-nous) : slide_up, slide_down puis zoom_in à l'apparition */
.js .about-images img { opacity: 0; transition: opacity .8s, translate .8s, scale .8s; }
.js .about-images img:nth-child(2) { translate: 0 50%; transition-delay: .6s; z-index: 1; }
.js .about-images img:nth-child(3) { translate: 0 -50%; transition-delay: 1.2s; z-index: 1; }
.js .about-images img:nth-child(1) { scale: .2; transition-delay: 1.8s; }
.js .about-images.is-in img { opacity: 1; translate: none; scale: none; }

@media (prefers-reduced-motion: reduce) {
  .hero *, .hero__deco { animation: none !important; }
  .js .about-images img { transition: none; }
}
