/* =========================================================
   HIMMA SERVICE — main.css
   Palette : #D4500A · #2B2B2B · #FFFFFF
   ========================================================= */

/* ── Reset & base ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --orange : #D4500A;
  --dark   : #2B2B2B;
  --white  : #FFFFFF;
  --gray   : #F8F8F8;
  --mid    : #888888;
  --border : #E5E5E5;
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'Poppins', sans-serif;
  color: var(--dark);
  background: var(--white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
picture { display: block; width: 100%; }

a { text-decoration: none; color: inherit; }

/* ── Focus visible ── */
:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }

/* =========================================================
   NAVBAR
   ========================================================= */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  background: var(--white);
  border-bottom: 2px solid var(--orange);
}

.nav-logo img { height: 36px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--dark);
  transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { color: var(--orange); }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.hamburger span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--dark);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile menu */
.nav-mobile {
  display: none;
  position: fixed;
  top: 64px;
  left: 0; right: 0;
  background: var(--dark);
  z-index: 999;
  padding: 24px 32px;
  flex-direction: column;
  gap: 20px;
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--white);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  padding-bottom: 16px;
}
.nav-mobile a:last-child { border-bottom: none; }

@media (max-width: 768px) {
  .navbar { padding: 0 20px; height: 56px; }
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .nav-mobile { top: 56px; }
}

/* =========================================================
   HERO
   ========================================================= */
.hero {
  position: relative;
  min-height: 100svh;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: url('../images/hero.jpg') center center / cover no-repeat;
  background-color: var(--dark);
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(43, 43, 43, 0.82);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.8rem);
  font-weight: 800;
  color: var(--white);
  line-height: 1.15;
}
.hero h1 em {
  font-style: normal;
  color: var(--orange);
}

.hero-sub {
  font-size: clamp(0.9rem, 2vw, 1.05rem);
  color: #CCCCCC;
  font-weight: 400;
  line-height: 1.6;
  max-width: 560px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.btn-primary {
  display: inline-block;
  background: var(--orange);
  color: var(--white);
  font-family: 'Poppins', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 14px 28px;
  border-radius: 6px;
  border: 2px solid var(--orange);
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}
.btn-primary:hover { background: #b84008; border-color: #b84008; transform: translateY(-2px); }

.btn-outline-white {
  display: inline-block;
  background: transparent;
  color: var(--white);
  font-family: 'Poppins', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 14px 28px;
  border-radius: 6px;
  border: 2px solid var(--white);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.btn-outline-white:hover { background: var(--white); color: var(--dark); }

.hero-badges {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 8px;
}
.hero-badge {
  font-size: 0.82rem;
  color: var(--white);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 7px;
}
.hero-badge::before {
  content: '✓';
  color: var(--orange);
  font-size: 1rem;
}

/* =========================================================
   SECTION COMMUNES
   ========================================================= */
section { padding: 80px 24px; }
.container { max-width: 1200px; margin: 0 auto; }

.section-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 700;
  color: var(--dark);
  line-height: 1.2;
  margin-bottom: 48px;
}

.section-title.white { color: var(--white); }

.section-divider {
  width: 60px;
  height: 3px;
  background: var(--orange);
  margin: 16px 0 40px;
}

/* =========================================================
   SERVICES
   ========================================================= */
#services { background: var(--white); }

.services-category { margin-bottom: 60px; }
.services-category:last-child { margin-bottom: 0; }

.category-separator {
  border: none;
  border-top: 2px solid var(--orange);
  margin: 56px 0;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 32px;
}

.service-card {
  border: 1.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--white);
  transition: box-shadow 0.25s, transform 0.25s;
}
.service-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
  transform: translateY(-4px);
}

.service-card-img {
  width: 100%;
  height: auto;
  display: block;
}

.service-card-body {
  padding: 18px 20px 20px;
}
.service-card-body h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 6px;
}
.service-card-body p {
  font-size: 0.82rem;
  color: var(--mid);
  line-height: 1.55;
}

.category-cta { text-align: center; }

@media (max-width: 1023px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .services-grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  .service-card-img { height: 130px; }
}

/* =========================================================
   AVANTAGES
   ========================================================= */
#avantages { background: var(--gray); }

.avantages-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.avantage-card {
  background: var(--white);
  border-radius: 10px;
  padding: 32px 28px;
  border-left: 4px solid var(--orange);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.avantage-icon {
  width: 44px;
  height: 44px;
  color: var(--orange);
}

.avantage-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
}

.avantage-card p {
  font-size: 0.87rem;
  color: var(--mid);
  line-height: 1.6;
}

@media (max-width: 640px) {
  .avantages-grid { grid-template-columns: 1fr; }
}

/* =========================================================
   TEASER CATALOGUES
   ========================================================= */
#catalogues-teaser {
  background: var(--dark);
  padding: 80px 24px;
}

.teaser-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.teaser-text .section-label { color: #f0a070; }
.teaser-text .section-title { color: var(--white); margin-bottom: 16px; }

.teaser-sub {
  font-size: 0.95rem;
  color: rgba(255,255,255,0.65);
  line-height: 1.7;
  margin-bottom: 32px;
}

.teaser-mosaic {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  border-radius: 10px;
  overflow: hidden;
}

.teaser-mosaic-item {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1;
}

.teaser-mosaic-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}
.teaser-mosaic-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(212, 80, 10, 0);
  transition: background 0.2s ease;
}
.teaser-mosaic-item:hover img { transform: scale(1.05); }
.teaser-mosaic-item:hover::after { background: rgba(212, 80, 10, 0.35); }

@media (max-width: 900px) {
  .teaser-inner {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

/* =========================================================
   DEVIS
   ========================================================= */
#devis { background: var(--white); padding: 0; }

.devis-header {
  background: var(--orange);
  padding: 40px 24px;
  text-align: center;
}
.devis-header h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  color: var(--white);
}
.devis-header p {
  color: rgba(255,255,255,0.85);
  font-size: 0.92rem;
  margin-top: 8px;
}

.devis-body {
  padding: 56px 24px;
  background: var(--white);
}

.devis-form-wrap {
  max-width: 640px;
  margin: 0 auto;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 18px;
}

.form-group label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--dark);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.form-group input,
.form-group select,
.form-group textarea {
  font-family: 'Poppins', sans-serif;
  font-size: 0.95rem;
  color: var(--dark);
  background: var(--gray);
  border: 1.5px solid var(--border);
  border-radius: 7px;
  padding: 13px 16px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(212,80,10,0.12);
  background: var(--white);
}
.form-group textarea { resize: vertical; min-height: 110px; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 540px) { .form-row { grid-template-columns: 1fr; } }

.btn-submit {
  width: 100%;
  height: 52px;
  font-family: 'Poppins', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  background: var(--dark);
  border: none;
  border-radius: 7px;
  cursor: pointer;
  margin-top: 8px;
  transition: background 0.2s;
}
.btn-submit:hover { background: #111; }
.btn-submit:disabled { opacity: 0.5; cursor: not-allowed; }

.form-note {
  text-align: center;
  font-size: 0.78rem;
  color: var(--mid);
  margin-top: 12px;
}

/* Messages */
.form-error-msg {
  display: none;
  background: #fef2f2;
  border: 1px solid #fca5a5;
  color: #b91c1c;
  border-radius: 7px;
  padding: 12px 16px;
  font-size: 0.85rem;
  margin-bottom: 12px;
}
.form-error-msg.show { display: block; }

.form-success {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
  padding: 48px 24px;
  background: #f0fdf4;
  border-radius: 10px;
  border: 1.5px solid #86efac;
}
.form-success.show { display: flex; }
.form-success svg { color: #16a34a; }
.form-success h3 { font-size: 1.3rem; font-weight: 700; color: var(--dark); }
.form-success p { color: var(--mid); font-size: 0.9rem; }
.form-success a { color: var(--orange); font-weight: 600; }

/* =========================================================
   TÉMOIGNAGES
   ========================================================= */
#temoignages { background: var(--white); }

.temoignages-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.temoignage-card {
  background: var(--gray);
  border-radius: 10px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.stars {
  display: flex;
  gap: 3px;
}
.stars svg { color: var(--orange); }

.temoignage-quote {
  font-size: 0.9rem;
  color: var(--dark);
  line-height: 1.65;
  font-style: italic;
  flex: 1;
}

.temoignage-author strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 700;
}
.temoignage-author span {
  font-size: 0.78rem;
  color: var(--mid);
}

@media (max-width: 900px) {
  .temoignages-grid {
    grid-template-columns: 1fr;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    display: flex;
  }
  .temoignage-card {
    min-width: 280px;
    scroll-snap-align: start;
  }
}

/* =========================================================
   CONTACT
   ========================================================= */
#contact { background: var(--dark); }
#contact .section-title { color: var(--white); }
#contact .section-label { color: #f0a070; }

.contact-cards {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.contact-card {
  flex: 1;
  min-width: 200px;
  background: rgba(255,255,255,0.06);
  border: 1.5px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.2s, background 0.2s;
}
.contact-card:hover {
  border-color: var(--orange);
  background: rgba(212,80,10,0.08);
}

.contact-wa-icon { color: #25D366; }

.contact-card-num {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--white);
}

.contact-card-hint {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
}

.contact-info {
  margin-top: 32px;
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
}
.contact-info-item {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.65);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* =========================================================
   FOOTER
   ========================================================= */
footer {
  background: var(--dark);
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 56px 24px 24px;
}

.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 24px;
}

.footer-logo { height: 40px; margin-bottom: 14px; filter: brightness(0) invert(1); }

.footer-tagline {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
  font-style: italic;
  margin-bottom: 6px;
}
.footer-sub {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.3);
}

.footer-col h4 {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  margin-bottom: 16px;
}

.footer-nav { display: flex; flex-direction: column; gap: 10px; }
.footer-nav a {
  font-size: 0.87rem;
  color: rgba(255,255,255,0.65);
  transition: color 0.2s;
}
.footer-nav a:hover { color: var(--white); }

.footer-contacts { display: flex; flex-direction: column; gap: 12px; }
.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.87rem;
  color: rgba(255,255,255,0.65);
  transition: color 0.2s;
}
.footer-contact-item:hover { color: var(--white); }
.footer-contact-item svg { color: #25D366; flex-shrink: 0; }

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.25);
}

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* =========================================================
   WHATSAPP FLOTTANT
   ========================================================= */
.whatsapp-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 999;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25D366;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 4px 16px rgba(37,211,102,0.45);
  animation: wa-pulse 2s infinite;
}
.whatsapp-float:hover { animation: none; transform: scale(1.1); }

@keyframes wa-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(37,211,102,0.5); }
  70%  { box-shadow: 0 0 0 14px rgba(37,211,102,0); }
  100% { box-shadow: 0 0 0 0 rgba(37,211,102,0); }
}

/* =========================================================
   FADE-IN AU SCROLL
   ========================================================= */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.fade-in.visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .fade-in { opacity: 1; transform: none; transition: none; }
}

/* =========================================================
   UTILITAIRES
   ========================================================= */
.text-center { text-align: center; }
.mt-0 { margin-top: 0 !important; }
