/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    background: #0e0e0e url('images/bg-pattern.jpg') repeat; /* Image de fond légère */
    color: #f5f5f5;
    line-height: 1.6;
}

/* HEADER */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #111;
    padding: 15px 50px;
    position: sticky;
    top: 0;
    z-index: 100;
}

header .logo img {
    height: 60px;
}

header nav ul {
    list-style: none;
    display: flex;
    gap: 25px;
}

header nav a {
    color: #f5f5f5;
    text-decoration: none;
    font-weight: 600;
    transition: 0.3s;
}

header nav a:hover {
    color: #c8a951;
}

/* HERO */
.hero {
    background: url('https://images.unsplash.com/photo-1581091012184-5c50e27e9a66') center/cover no-repeat;
    height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

.hero-text {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: #c8a951;
    transition: 0.3s;
}
.hero h1:hover {
    color: #fff;
    transform: scale(1.05);
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 25px;
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    background: #c8a951;
    color: #111;
    font-weight: bold;
    text-decoration: none;
    border-radius: 5px;
    transition: 0.3s;
    animation: pulse 2s infinite;
}

.btn:hover {
    background: #b09243;
    transform: scale(1.05);
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.08); }
    100% { transform: scale(1); }
}

/* SECTIONS */
section {
    padding: 70px 50px;
    text-align: center;
}

h2 {
    color: #c8a951;
    margin-bottom: 40px;
    font-size: 2rem;
    transition: 0.3s;
}
h2:hover {
    color: #fff;
    transform: scale(1.05);
}

/* SERVICES */
.service-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.service {
    background: #1a1a1a;
    padding: 25px;
    border-radius: 8px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.service:hover {
    transform: translateY(-8px);
    box-shadow: 0px 8px 20px rgba(0,0,0,0.5);
}

.service i {
    font-size: 2.5rem;
    color: #c8a951;
    margin-bottom: 15px;
}

/* ABOUT */
.about p {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1rem;
}

/* CONTACT */
.contact form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 500px;
    margin: 0 auto;
}

.contact input,
.contact textarea {
    padding: 12px;
    border: none;
    border-radius: 5px;
    outline: none;
}

.contact button {
    padding: 12px;
    background: #c8a951;
    color: #111;
    border: none;
    font-weight: bold;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
}

.contact button:hover {
    background: #b09243;
}

/* FOOTER */
footer {
    background: #111;
    text-align: center;
    padding: 25px 15px;
    font-size: 0.9rem;
    color: #aaa;
}

footer p {
    margin: 5px 0;
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 40px;
}

.contact-info {
    text-align: left;
}

.contact-info h3 {
    margin-bottom: 15px;
    color: #c8a951;
}

/* BUSINESS */
.business {
    padding: 70px 50px;
    text-align: center;
}

.business h2 {
    color: #c8a951;
    margin-bottom: 30px;
    font-size: 2rem;
}

.business-section {
    text-align: left;
    max-width: 900px;
    margin: 40px auto;
}

.business-section h3 {
    color: #c8a951;
    margin-bottom: 10px;
}

.business-section p, .business-section ul {
    font-size: 1.1rem;
    line-height: 1.6;
}

.business-section ul {
    list-style-type: disc;
    padding-left: 20px;
}

.business-section .btn {
    display: inline-block;
    margin-top: 10px;
    padding: 12px 25px;
    background: #c8a951;
    color: #111;
    font-weight: bold;
    border-radius: 5px;
    text-decoration: none;
    transition: 0.3s;
}

.business-section .btn:hover {
    background: #b09243;
}

.theme-toggle {
    position: absolute;
    right: 20px;
    top: 15px;
    cursor: pointer;
    font-size: 28px;
    color: #fff;
    transition: color 0.3s;
}

.light-mode .theme-toggle {
    color: #111;
}


/* MODE CLAIR ADAPTÉ */
.light-mode {
    background: #f2f2f2 url('images/bg-pattern-light.jpg') repeat; /* gris clair discret */
    color: #222; /* texte sombre mais doux */
}

.light-mode header {
    background: #fff; /* header clair */
}

.light-mode header nav a {
    color: #222;
}

.light-mode header nav a:hover {
    color: #c8a951; /* accent doré */
}

.light-mode .hero::after {
    background: rgba(255,255,255,0.2); /* voile clair subtil pour texte */
}

.light-mode .hero h1 {
    color: #c8a951;
}

.light-mode .hero p {
    color: #222;
}

.light-mode .btn {
    background: #c8a951;
    color: #111;
}

.light-mode .btn:hover {
    background: #b09243;
}

.light-mode h2 {
    color: #c8a951;
}

.light-mode .service {
    background: #fff;
    color: #222;
}

.light-mode .service i {
    color: #c8a951;
}

.light-mode .contact input,
.light-mode .contact textarea {
    background: #fff;
    color: #222;
}

.light-mode .contact button {
    background: #c8a951;
    color: #111;
}

.light-mode footer {
    background: #e5e5e5;
    color: #555;
}

/* Organigramme complet avec images et flexbox */
.organigramme {
    padding: 70px 20px;
    text-align: center;
}

.organigramme h2 {
    color: #c8a951;
    margin-bottom: 50px;
}

/* Container principal */
.tree-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px; /* espace vertical entre les lignes */
}

/* Chaque ligne */
.level {
    display: flex;
    justify-content: center;
    gap: 40px; /* espace horizontal par défaut */
    position: relative;
}

/* Ligne Direction Général */
.level-0 {
    display: flex;
    justify-content: center; /* centre la direction */
    gap: 20px;
    margin-bottom: 30px;
}

/* Ligne Associés */
.level-1 {
    display: flex;
    justify-content: center;
    gap: 30px;
}

/* Niveau 4 (agents) */
.level-4 .node, .level-4 .node-img {
    width: 80px;   
    height: 80px;  
    padding: 8px 15px;
    font-size: 0.85rem; 
}

/* Wrapper pour chaque photo avec nom */
.node-img-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

/* Nom au-dessus de la photo */
.node-name {
    display: none; /* caché par défaut */
    margin-bottom: 10px;
    font-weight: bold;
    color: #c8a951;
    font-size: 1rem;
    text-align: center;
}

/* Affiche le nom au hover sur la photo */
.node-img-wrapper:hover .node-name {
    display: block;
}

/* Cercles pour images */
.node-img {
    width: 100px;
    height: 100px;
    border: 3px solid #c8a951;
    border-radius: 50%;
    overflow: hidden;
    transition: transform 0.3s, border-color 0.3s;
}

.node-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.node-img:hover {
    transform: scale(1.05);
    border-color: #fff;
}

/* Nodes classiques */
.node {
    padding: 10px 20px;
    border: 2px solid #c8a951;
    border-radius: 8px;
    background: #1a1a1a;
    color: #f5f5f5;
    transition: transform 0.3s, background 0.3s, color 0.3s, box-shadow 0.3s;
    font-size: 1rem;
    text-align: center;
}

.node:hover {
    transform: scale(1.05);
    background: #1a1a1a; 
    color: #c8a951;
    box-shadow: 0 4px 15px rgba(200, 169, 81, 0.5);
}

/* Connecteurs verticaux */
.level:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    width: 2px;
    height: 25px; /* réduit la longueur verticale */
    background: #c8a951;
}

/* Connecteurs horizontaux (entre plusieurs nodes) */
.level-1, .level-4 {
    position: relative;
}

.level-1::after, .level-4::after {
    display: none; /* pas de ligne verticale unique pour ces niveaux */
}

/* Responsive */
@media (max-width: 1200px) {
    .level-4 .node, .level-4 .node-img {
        width: 70px;
        height: 70px;
        font-size: 0.75rem;
    }
}

@media (max-width: 768px) {
    .level {
        flex-direction: column;
        gap: 15px;
    }
    .level-4 {
        gap: 10px;
    }
}




/* Page Matériel */
.materiel {
    padding: 70px 20px;
    text-align: center;
}

.materiel h2 {
    color: #c8a951;
    margin-bottom: 50px;
}

.materiel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    justify-items: center;
}

.materiel-item {
    background: #1a1a1a;
    border: 2px solid #c8a951;
    border-radius: 10px;
    padding: 20px;
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
    max-width: 300px;
    color: #f5f5f5;
}

.materiel-item:hover {
    transform: scale(1.05);
    border-color: #c8a951;
    box-shadow: 0 8px 20px rgba(200, 169, 81, 0.5);
    background: #1a1a1a; /* fond reste sombre */
}

.materiel-item img {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 15px;
}

.materiel-item h3 {
    margin-bottom: 10px;
    color: #c8a951;
    transition: color 0.3s, text-shadow 0.3s;
}

.materiel-item:hover h3 {
    color: #fff;
    text-shadow: 1px 1px 5px #000;
}

.materiel-item p {
    font-size: 0.95rem;
    line-height: 1.4;
    transition: color 0.3s;
}

.materiel-item:hover p {
    color: #fff;
}

/* Mode clair */
.light-mode .materiel-item {
    background: #fff;
    color: #222;
}

.light-mode .materiel-item:hover {
    border-color: #c8a951;
    box-shadow: 0 8px 20px rgba(200, 169, 81, 0.5);
    color: #111;
}

.light-mode .materiel-item:hover h3,
.light-mode .materiel-item:hover p {
    color: #111;
    text-shadow: none;
}

/* FOOTER LÉGAL */
footer {
    background: #111;
    padding: 30px 20px;
    text-align: center;
    font-size: 0.9rem;
    color: #aaa;
    border-top: 2px solid #c8a951;
}

.footer-links {
    margin-bottom: 10px;
}

.footer-links a {
    color: #c8a951;
    text-decoration: none;
    margin: 0 8px;
    transition: color 0.3s, text-shadow 0.3s;
}

.footer-links a:hover {
    color: #fff;
    text-shadow: 0px 0px 6px #c8a951;
}

footer p {
    margin-top: 10px;
    color: #777;
    font-size: 0.85rem;
}

/* Mode clair */
.light-mode footer {
    background: #f2f2f2;
    border-top: 2px solid #c8a951;
    color: #333;
}

.light-mode .footer-links a {
    color: #c8a951;
}

.light-mode .footer-links a:hover {
    color: #111;
    text-shadow: none;
}

/* PAGE RECRUTEMENT */
.recrutement {
    padding: 70px 30px;
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.recrutement h2 {
    color: #c8a951;
    font-size: 2.2rem;
    margin-bottom: 20px;
}

.recrutement p {
    font-size: 1.1rem;
    margin-bottom: 40px;
}

.recrutement-info {
    text-align: left;
    margin-bottom: 40px;
    background: #1a1a1a;
    padding: 25px;
    border-radius: 8px;
    border: 2px solid #c8a951;
}

.recrutement-info h3 {
    margin-top: 20px;
    color: #c8a951;
}

.recrutement-info ul {
    margin: 10px 0 20px 20px;
    list-style-type: disc;
}

.recrutement .btn {
    font-size: 1.1rem;
    padding: 14px 30px;
}

.parking {
  padding: 70px 20px;
  text-align: center;
}

.parking h2 {
  color: #c8a951;
  margin-bottom: 40px;
}

.parking-grid {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.parking-item {
  position: relative;
  max-width: 220px;
  text-align: center;
}

.parking-item img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  border-radius: 8px;
  transition: transform 0.3s;
  cursor: pointer;
}

.parking-item img:hover {
  transform: scale(1.05);
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  z-index: 999;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.9);
  justify-content: center;
  align-items: center;
}

.lightbox-content {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
}

.lightbox .close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #c8a951;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
}

    


