/* Base Styles */
:root {
  --primary-color: #8b4513;
  --secondary-color: #d2b48c;
  --accent-color: #a0522d;
  --light-color: #f5f5dc;
  --dark-color: #3e2723;
  --text-color: #333;
  --text-light: #777;
  --white: #fff;
  --transition: all 0.3s ease;
  --shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  --border-radius: 5px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--white);
}

.custom-alert {
  background-color: #d4edda;
  color: #155724;
  border-left: 6px solid #28a745;
  padding: 15px 20px;
  font-size: 16px;
  font-weight: 500;
  border-radius: 6px;
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1050;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  animation: fadeIn 0.5s ease-out;
  display: flex;
  align-items: center;
  gap: 10px;
}

.custom-alert .icon {
  font-size: 20px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 15px;
}

p {
  margin-bottom: 15px;
}

a {
  text-decoration: none;
  color: var(--primary-color);
  transition: var(--transition);
}

a:hover {
  color: var(--accent-color);
}

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

.btn {
  display: inline-block;
  background-color: var(--primary-color);
  color: var(--white);
  padding: 12px 25px;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: var(--transition);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 14px;
}

.btn:hover {
  background-color: var(--accent-color);
  color: var(--white);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.btn-small {
  padding: 8px 15px;
  font-size: 12px;
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 50px;
  position: relative;
  color: var(--dark-color);
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: var(--primary-color);
}

/* Header & Navigation */
header {
  background-color: var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 1000;
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 60px;
}

.logo span {
  color: var(--primary-color);
  font-weight: 400;
}

.nav-links {
  display: flex;
  list-style: none;
}

.nav-links li {
  margin-left: 30px;
}

.nav-links a {
  color: var(--text-color);
  font-weight: 500;
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: var(--transition);
}

.nav-links a:hover::after {
  width: 100%;
}

.burger {
  display: none;
  cursor: pointer;
}

.burger div {
  width: 25px;
  height: 3px;
  background-color: var(--text-color);
  margin: 5px;
  transition: var(--transition);
}

/* Hero Section */
.hero {
  position: relative;
  height: 100vh;
  display: flex;
  align-items: center;
  text-align: center;
  color: var(--white);
  padding-top: 80px;
  overflow: hidden;
}

.hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}

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

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: -1;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero-content h1 {
  font-size: 3.5rem;
  margin-bottom: 20px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

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

/* About Section */
.about {
  padding: 100px 0;
  background-color: var(--light-color);
}

.about-content {
  display: flex;
  align-items: center;
  gap: 50px;
}

.about-image {
  flex: 1;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.about-text {
  flex: 1;
}

.about-text h3 {
  font-size: 2rem;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.about-features {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  margin-top: 30px;
}

.feature {
  flex: 1;
  min-width: 200px;
  text-align: center;
  padding: 20px;
  background-color: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.feature:hover {
  transform: translateY(-10px);
}

.feature i {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.feature h4 {
  font-size: 1.2rem;
  margin-bottom: 10px;
}

/* Services Section Updated */
.services {
  padding: 100px 0;
}

.services-intro {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px;
  font-size: 1.1rem;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 30px;
}

.service-card {
  background-color: var(--white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  border-bottom: 4px solid transparent;
}

.service-card:hover {
  transform: translateY(-10px);
  border-bottom: 4px solid var(--primary-color);
}

.service-image {
  height: 200px;
  overflow: hidden;
}

.service-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.service-card:hover .service-image img {
  transform: scale(1.05);
}

.service-card h3 {
  font-size: 1.5rem;
  margin: 20px 20px 10px;
  color: var(--dark-color);
}

.service-card p {
  padding: 0 20px 20px;
  color: var(--text-light);
}

/* Réalisations Section */
.realisations {
  padding: 64px 0;
  background: var(--light-color);
}

.realisations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 32px;
}

.realisation-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.realisation-card:hover {
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  transform: translateY(-4px);
}

.realisation-image {
  position: relative;
  height: 250px;
}

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

.category-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background: var(--primary-color);
  color: white;
  padding: 4px 12px;
  border-radius: 16px;
  font-size: 12px;
  font-weight: 500;
}

.realisation-content {
  padding: 24px;
}

.realisation-content h4 {
  font-size: 18px;
  font-weight: 700;
  color: #111827;
  margin-bottom: 12px;
}

.realisation-meta {
  display: flex;
  gap: 16px;
  font-size: 14px;
  color: #6b7280;
  margin-bottom: 12px;
}

.realisation-content p {
  color: #6b7280;
  font-size: 14px;
}

.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  padding-top: 100px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.9);
}
    
.modal-content {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  max-height: 80vh;
  object-fit: contain;
}
    
.close {
  position: absolute;
  top: 15px;
  right: 35px;
  color: #f1f1f1;
  font-size: 40px;
  font-weight: bold;
  transition: 0.3s;
  cursor: pointer;
  z-index: 1001;
}
    
.close:hover,
.close:focus {
  color: #bbb;
  text-decoration: none;
}
    
#caption {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  text-align: center;
  color: #ccc;
  padding: 10px 0;
}

/* Procedure Section */
.procedure {
  padding: 100px 0;
}

.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 4px;
  background-color: var(--secondary-color);
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  justify-content: flex-end;
  padding-right: 30px;
  position: relative;
  margin-bottom: 50px;
  width: 50%;
}

.timeline-item:nth-child(even) {
  align-self: flex-end;
  justify-content: flex-start;
  padding-left: 30px;
  padding-right: 0;
  left: 50%;
}

.timeline-icon {
  position: absolute;
  width: 50px;
  height: 50px;
  background-color: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  right: -25px;
  top: 0;
  z-index: 1;
}

.timeline-item:nth-child(even) .timeline-icon {
  left: -25px;
  right: auto;
}

.timeline-content {
  background-color: var(--white);
  border-radius: var(--border-radius);
  padding: 20px;
  box-shadow: var(--shadow);
  width: 100%;
}

.timeline-content h3 {
  color: var(--primary-color);
  font-size: 1.3rem;
}

/* Contact Section */
.contact {
  padding: 100px 0;
  background-color: var(--light-color);
}

.contact-content {
  display: flex;
  gap: 50px;
}

.contact-info,
.contact-form {
  flex: 1;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 30px;
}

.contact-item i {
  font-size: 1.5rem;
  color: var(--primary-color);
  margin-right: 20px;
  margin-top: 5px;
}

.contact-item h3 {
  font-size: 1.2rem;
  margin-bottom: 5px;
}

.social-links {
  display: flex;
  gap: 15px;
  margin-top: 30px;
}

.social-link {
  width: 40px;
  height: 40px;
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.social-link:hover {
  background-color: var(--accent-color);
  color: white;
  transform: translateY(-5px);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: 600;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  font-family: inherit;
  font-size: 1rem;
}

.form-group textarea {
  resize: vertical;
}

/* Footer */
footer {
  background-color: var(--dark-color);
  color: var(--white);
  padding: 70px 0 20px;
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  gap: 50px;
  margin-bottom: 50px;
}

.footer-logo,
.footer-links,
.footer-newsletter {
  flex: 1;
  min-width: 250px;
}

.footer-logo h2 {
  font-size: 1.8rem;
  margin-bottom: 10px;
}

.footer-logo span {
  color: var(--secondary-color);
}

.footer-links h3,
.footer-newsletter h3 {
  font-size: 1.3rem;
  margin-bottom: 20px;
  color: var(--secondary-color);
}

.footer-links ul {
  list-style: none;
}

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

.footer-links a {
  color: var(--white);
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--secondary-color);
  padding-left: 5px;
}

.newsletter-form {
  display: flex;
  margin-top: 20px;
}

.newsletter-form input {
  flex: 1;
  padding: 10px;
  border: none;
  border-radius: var(--border-radius) 0 0 var(--border-radius);
}

.newsletter-form button {
  background-color: var(--primary-color);
  color: var(--white);
  border: none;
  padding: 0 15px;
  border-radius: 0 var(--border-radius) var(--border-radius) 0;
  cursor: pointer;
  transition: var(--transition);
}

.newsletter-form button:hover {
  background-color: var(--accent-color);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive Design */
@media screen and (max-width: 992px) {
  .about-content {
    flex-direction: column;
  }

  .contact-content {
    flex-direction: column;
  }

  .timeline-item {
    width: 100%;
    padding-right: 0;
    padding-left: 70px;
  }

  .timeline-item:nth-child(even) {
    left: 0;
    padding-left: 70px;
  }

  .timeline::before {
    left: 30px;
  }

  .timeline-icon {
    left: 5px;
    right: auto;
  }

  .timeline-item:nth-child(even) .timeline-icon {
    left: 5px;
  }
}

@media screen and (max-width: 768px) {
  .nav-links {
    position: absolute;
    right: 0;
    top: 80px;
    background-color: var(--white);
    width: 100%;
    flex-direction: column;
    align-items: center;
    transform: translateY(-150%);
    transition: var(--transition);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    padding: 20px 0;
  }

  .nav-links.active {
    transform: translateY(0);
  }

  .nav-links li {
    margin: 15px 0;
  }

  .burger {
    display: block;
  }

  .hero-content h1 {
    font-size: 2.5rem;
  }

  .section-title {
    font-size: 2rem;
  }
}

@media screen and (max-width: 576px) {
  .hero-content h1 {
    font-size: 2rem;
  }

  .about-features {
    flex-direction: column;
  }

  .services-grid,
  .projects-grid {
    grid-template-columns: 1fr;
  }
}
