/* ============================================================
   ODYPRO — Design System & Custom CSS
   Complément au framework Tailwind CSS (CDN)
   Charte graphique conforme au CDC v1
   ============================================================ */

/* --- Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=League+Spartan:wght@700;900&family=Quicksand:wght@400;500;600&display=swap');

/* --- CSS Variables (Design Tokens) --- */
:root {
  /* Couleurs marque */
  --color-primary: #009EE0;
  --color-primary-dark: #0080B8;
  --color-noir-technique: #1B1B1B;
  --color-blanc: #FFFFFF;
  --color-gris-beton: #F5F5F7;
  --color-gris-tech: #8A8A8A;

  /* Couleurs produit */
  --color-desembouant: #E30613;
  --color-c1: #7ED321;
  --color-c2: #8B5CF6;
  --color-c3: #1E90FF;

  /* Couleurs matériaux (pastilles) */
  --color-acier: #1B1B1B;
  --color-alu: #8A8A8A;
  --color-per: #1E90FF;

  /* Couleurs fonctionnelles */
  --color-succes: #10B981;
  --color-attention: #F59E0B;

  /* Typographie */
  --font-heading: 'League Spartan', sans-serif;
  --font-body: 'Quicksand', sans-serif;

  /* Conteneur */
  --container-max: 1280px;
  --padding-mobile: 24px;
  --padding-desktop: 48px;
}

/* --- Reset léger --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-noir-technique);
  background: var(--color-blanc);
}

@media (min-width: 1024px) {
  body {
    font-size: 17px;
  }
}

/* --- Skip Link (accessibilité) --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 9999;
  padding: 8px 16px;
  background: var(--color-primary);
  color: #fff;
  font-family: var(--font-body);
  font-weight: 600;
  border-radius: 0 0 8px 8px;
  text-decoration: none;
  transition: top 0.2s;
}
.skip-link:focus {
  top: 0;
}

/* --- Typographie --- */
h1, h2, h3 {
  font-family: var(--font-heading);
  line-height: 1.15;
}

h1 {
  font-weight: 900;
  font-size: 32px;
  text-transform: uppercase;
  letter-spacing: -0.02em;
}
@media (min-width: 1024px) {
  h1 { font-size: 56px; }
}

h2 {
  font-weight: 700;
  font-size: 24px;
  text-transform: uppercase;
}
@media (min-width: 1024px) {
  h2 { font-size: 40px; }
}

h3 {
  font-weight: 700;
  font-size: 20px;
}
@media (min-width: 1024px) {
  h3 { font-size: 28px; }
}

h4 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 18px;
}
@media (min-width: 1024px) {
  h4 { font-size: 20px; }
}

.text-small {
  font-size: 14px;
  font-weight: 500;
}

.text-micro {
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* --- Conteneur --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-left: var(--padding-mobile);
  padding-right: var(--padding-mobile);
}
@media (min-width: 1024px) {
  .container {
    padding-left: var(--padding-desktop);
    padding-right: var(--padding-desktop);
  }
}

/* --- Sections spacing --- */
.section {
  padding-top: 48px;
  padding-bottom: 48px;
}
@media (min-width: 768px) {
  .section { padding-top: 64px; padding-bottom: 64px; }
}
@media (min-width: 1024px) {
  .section { padding-top: 96px; padding-bottom: 96px; }
}

/* --- Boutons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 28px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}
.btn-primary:hover {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
}

.btn-outline-white {
  background: transparent;
  color: #fff;
  border-color: #fff;
}
.btn-outline-white:hover {
  background: rgba(255,255,255,0.12);
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn-outline:hover {
  background: var(--color-primary);
  color: #fff;
}

.btn-white {
  background: #fff;
  color: var(--color-primary);
  border-color: #fff;
}
.btn-white:hover {
  background: var(--color-gris-beton);
}

.btn-dark {
  background: var(--color-noir-technique);
  color: #fff;
  border-color: var(--color-noir-technique);
}
.btn-dark:hover {
  background: #333;
}

/* États focus accessibilité */
.btn:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Bouton plein largeur mobile */
@media (max-width: 639px) {
  .btn-mobile-full {
    width: 100%;
  }
}

/* --- Cartes --- */
.card {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

/* --- Pastilles matériau --- */
.pastille {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  color: #fff;
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.1;
  text-align: center;
}
@media (min-width: 1024px) {
  .pastille {
    width: 64px;
    height: 64px;
    font-size: 14px;
  }
}
.pastille-acier { background: var(--color-acier); }
.pastille-alu   { background: var(--color-alu); }
.pastille-per   { background: var(--color-per); }

.pastille-group {
  display: inline-flex;
}
.pastille-group .pastille + .pastille {
  margin-left: -8px;
}

/* --- Placeholder photo (pour les images non fournies) --- */
.placeholder-photo {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #E5E5E5;
  color: var(--color-gris-tech);
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 14px;
  text-align: center;
  padding: 16px;
  border-radius: 8px;
  min-height: 200px;
}

/* --- Top Bar (M1) --- */
.top-bar {
  background: var(--color-noir-technique);
  color: #fff;
  font-size: 13px;
  height: 36px;
  display: none;
  align-items: center;
}
@media (min-width: 768px) {
  .top-bar { display: flex; }
}

/* --- Navigation (M2) --- */
.navbar {
  background: #fff;
  height: 64px;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: box-shadow 0.2s ease;
}
@media (min-width: 1024px) {
  .navbar { height: 96px; }
}
.navbar.scrolled {
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* Logo mobile : version courte */
.nav-logo img {
  height: 44px;
  width: auto;
  display: block;
}
/* Logo desktop : version logo + tagline */
@media (min-width: 1024px) {
  .nav-logo img { height: 72px; }
}

/* Hamburger */
.hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: none;
  border: none;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
}
@media (min-width: 1024px) {
  .hamburger { display: none; }
}
.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-noir-technique);
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.hamburger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.hamburger.active span:nth-child(2) {
  opacity: 0;
}
.hamburger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Drawer */
.mobile-drawer {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: #fff;
  z-index: 99;
  transform: translateX(100%);
  transition: transform 0.25s ease;
  overflow-y: auto;
  padding: 80px 24px 24px;
}
.mobile-drawer.open {
  transform: translateX(0);
}
.mobile-drawer a {
  display: block;
  padding: 16px 0;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 20px;
  text-transform: uppercase;
  color: var(--color-noir-technique);
  text-decoration: none;
  border-bottom: 1px solid var(--color-gris-beton);
}
.mobile-drawer a:hover {
  color: var(--color-primary);
}

/* Desktop menu */
.nav-menu {
  display: none;
  list-style: none;
  gap: 32px;
  align-items: center;
}
@media (min-width: 1024px) {
  .nav-menu { display: flex; }
}
.nav-menu a {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  color: var(--color-noir-technique);
  text-decoration: none;
  transition: color 0.2s;
  position: relative;
}
.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  transition: width 0.2s;
}
.nav-menu a:hover {
  color: var(--color-primary);
}
.nav-menu a:hover::after,
.nav-menu a.active::after {
  width: 100%;
}

/* --- Hero --- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 60vh;
  overflow: hidden;
}
@media (min-width: 1024px) {
  .hero { min-height: 80vh; }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(27,27,27,0.85), rgba(27,27,27,0.5));
  z-index: 1;
}
.hero-content {
  position: relative;
  z-index: 2;
  color: #fff;
}
.hero-subtitle {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 16px;
  margin-top: 16px;
  max-width: 600px;
  line-height: 1.5;
  opacity: 0.9;
}
@media (min-width: 1024px) {
  .hero-subtitle { font-size: 20px; }
}
.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

/* --- Hero layout split (texte gauche + badge droite) --- */
.hero-split {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.hero-split-text {
  flex: 1;
  min-width: 0;
}

/* Badge glassmorphisme */
.hero-logo-glass {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 340px;
  height: 230px;
  padding: 28px 36px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(24px) saturate(180%) brightness(1.1);
  -webkit-backdrop-filter: blur(24px) saturate(180%) brightness(1.1);
  border: 1px solid rgba(255, 255, 255, 0.80);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 0 0 4px rgba(255, 255, 255, 0.18),
    0 0 28px rgba(255, 255, 255, 0.22),
    0 16px 56px rgba(0, 0, 0, 0.40);
}
.hero-logo-glass img {
  width: 240px;
  height: auto;
  display: block;
}

/* Mobile : badge en dessous du texte, taille réduite */
@media (max-width: 900px) {
  .hero-split {
    flex-direction: column;
    align-items: flex-start;
    gap: 32px;
  }
  .hero-logo-glass {
    width: 220px;
    height: 150px;
    padding: 20px 24px;
    border-radius: 18px;
    align-self: center;
  }
  .hero-logo-glass img {
    width: 160px;
  }
}

/* --- Footer (M11) --- */
.footer {
  background: var(--color-noir-technique);
  color: #fff;
  padding-top: 64px;
  padding-bottom: 0;
}
.footer a {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  transition: color 0.2s;
}
.footer a:hover {
  color: #fff;
}
.footer h4 {
  color: #fff;
  margin-bottom: 16px;
  font-size: 16px;
}
.footer-bottom {
  margin-top: 48px;
  padding: 24px 0;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 13px;
  color: rgba(255,255,255,0.5);
}

/* --- Accordéon (M9) --- */
.accordion-item {
  border-bottom: 1px solid #E5E5E5;
}
.accordion-btn {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 20px 0;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  color: var(--color-noir-technique);
  text-align: left;
  min-height: 44px;
}
.accordion-btn svg {
  flex-shrink: 0;
  transition: transform 0.3s ease;
}
.accordion-btn.active svg {
  transform: rotate(180deg);
}
.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
.accordion-content-inner {
  padding: 0 0 20px;
  color: var(--color-gris-tech);
  line-height: 1.7;
}

/* --- Toast notification --- */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--color-succes);
  color: #fff;
  padding: 16px 24px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  z-index: 9999;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* --- Animations au scroll --- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Bandeau CTA plein --- */
.cta-banner {
  padding: 48px 0;
  text-align: center;
}
@media (min-width: 1024px) {
  .cta-banner { padding: 64px 0; }
}
.cta-banner h2 {
  margin-bottom: 12px;
}
.cta-banner p {
  margin-bottom: 24px;
  opacity: 0.9;
}

/* --- Grille produits --- */
.product-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 640px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .product-grid { grid-template-columns: repeat(4, 1fr); }
}

/* --- Carte produit (M4) --- */
.product-card {
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
  color: inherit;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}
.product-card-top {
  height: 30%;
  min-height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}
.product-card-top img {
  height: 160px;
  object-fit: contain;
}
.product-card-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.product-card-body h3 {
  font-size: 18px;
  text-transform: uppercase;
}
.product-card-link {
  margin-top: auto;
  font-weight: 600;
  font-size: 14px;
  color: var(--color-primary);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* --- Formulaires (M10) --- */
.form-group {
  margin-bottom: 20px;
}
.form-group label {
  display: block;
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 6px;
  color: var(--color-noir-technique);
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #D1D5DB;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 15px;
  background: #fff;
  transition: border-color 0.2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--color-primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(0, 158, 224, 0.15);
}
.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

/* --- Tableau responsive --- */
.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.table-responsive table {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
}
.table-responsive th,
.table-responsive td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #E5E5E5;
  font-size: 14px;
}
.table-responsive th {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  background: var(--color-gris-beton);
  color: var(--color-noir-technique);
}

/* --- Bouton flottant mobile --- */
.floating-cta {
  display: flex;
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  z-index: 90;
  gap: 8px;
}
@media (min-width: 1024px) {
  .floating-cta { display: none; }
}
.floating-cta .btn {
  flex: 1;
  justify-content: center;
  font-size: 13px;
  padding: 12px 16px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

/* --- Onglets (page ressources) --- */
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 32px;
}
.tab-btn {
  padding: 10px 20px;
  border: 1px solid #D1D5DB;
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  background: #fff;
  color: var(--color-gris-tech);
  cursor: pointer;
  transition: all 0.2s;
  min-height: 44px;
}
.tab-btn.active,
.tab-btn:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

/* --- Chiffres animés --- */
.stat-number {
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 40px;
  color: var(--color-primary);
  line-height: 1;
}
@media (min-width: 1024px) {
  .stat-number { font-size: 56px; }
}

