/* ============================= */
/* RESET GLOBAL */
/* ============================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #E63946;
  --primary-dark: #C92A34;
  --bg: #ffffff;
  --bg-alt: #f8f9fa;
  --text: #212529;
  --text-light: #6c757d;
  --radius: 14px;
  --shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  --transition: all 0.3s ease;
  --max-width: 1200px;
  --font: 'Inter', sans-serif;
}

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: 1rem;
  overflow-x: hidden;
}

/* ============================= */
/* TYPOGRAPHIE */
/* ============================= */
h1, h2, h3, h4 {
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
}

h1 { font-size: clamp(2.2rem, 4vw, 3.2rem); }
h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); margin-bottom: 1rem; }
h3 { font-size: 1.5rem; }
p { color: var(--text-light); 
  margin-bottom: 1rem; }

/* ============================= */
/* NAVIGATION */
/* ============================= */
.navbar {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  z-index: 1000;
}

/* Espacement pour éviter le chevauchement avec la navbar */
.page {
  scroll-margin-top: 90px; /* Hauteur navbar + marge */
}

.nav-container {
  max-width: var(--max-width);
  margin: auto;
  padding: 0 1.5rem;
  height: 70px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--primary);
  text-decoration: none;
}

.nav-menu {
  list-style: none;
  display: flex;
  gap: 2rem;
}

.nav-link {
  text-decoration: none;
  font-weight: 600;
  color: var(--text);
  position: relative;
  transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary);
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 0; bottom: -4px;
  width: 0; height: 2px;
  background: var(--primary);
  transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* ============================= */
/* MENU MOBILE */
/* ============================= */
.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
}

.mobile-toggle span {
  width: 26px;
  height: 3px;
  background: var(--text);
  border-radius: 2px;
  transition: var(--transition);
}
/* ============================= */
/* HERO - DESIGN MINIMALISTE */
/* ============================= */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 1rem 4rem;
  position: relative;
  background: linear-gradient(135deg, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.6) 100%), 
              url('../assets/background-hero.jpg') center/cover no-repeat;
  background-attachment: fixed;
}

.hero-container {
  max-width: 1100px;
  margin: auto;
  width: 100%;
  text-align: center;
}

.hero-content {
  max-width: 100%;
  color: white;
}

.hero h1 {
  margin-bottom: 2rem;
  font-size: clamp(2.8rem, 6vw, 5rem);
  font-weight: 800;
  line-height: 1.1;
  color: white;
  letter-spacing: -0.02em;
}

.hero-highlight { 
  color: white;
  display: block;
  margin-top: 0.5rem;
  font-weight: 800;
}

.hero p {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  margin-bottom: 3rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 400;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.cta-buttons {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

/* Boutons avec style minimaliste */
.hero .btn-primary {
  background: var(--primary-dark);
  color: white;
  padding: 1.2rem 3rem;
  font-size: 1rem;
  font-weight: 700;
  box-shadow: none;
  border: none;
  letter-spacing: 0.02em;
}

.hero .btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.hero .btn-secondary {
  border: 2px solid  var(--primary-dark);
  color: white;
  background: transparent;
  padding: 1.2rem 3rem;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.hero .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary-dark);
  transform: translateY(-2px);
}

/* Indicateur de scroll */
.hero-scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  color: white;
  font-size: 2rem;
  animation: bounce 2s infinite;
  cursor: pointer;
  opacity: 0.7;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translate(-50%, 0); }
  40% { transform: translate(-50%, -10px); }
  60% { transform: translate(-50%, -5px); }
}

/* Responsive */
@media (max-width: 768px) {
  .hero {
    padding: 5rem 1.5rem 3rem;
    background-attachment: scroll;
  }
  
  .cta-buttons {
    flex-direction: column;
    gap: 1rem;
    max-width: 400px;
    margin: 0 auto;
  }
  
  .hero .btn-primary,
  .hero .btn-secondary {
    width: 100%;
    justify-content: center;
    padding: 1rem 2rem;
  }
  
  .hero h1 {
    font-size: clamp(2.5rem, 8vw, 3.5rem);
  }
  
  .hero p {
    font-size: 1.1rem;
  }
  
  .hero-scroll-indicator {
    bottom: 30px;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 4rem 1rem 2rem;
  }
  
  .hero h1 {
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
  }
  
  .hero p {
    font-size: 1rem;
    margin-bottom: 2rem;
  }
}

/* ============================= */
/* BOUTONS */
/* ============================= */
.btn-primary,
.btn-secondary {
  display: inline-block;
  padding: 0.9rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(230,57,70,0.25);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

.btn-secondary {
  border: 2px solid var(--primary);
  color: var(--primary);
}

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

/* ============================= */
/* SECTIONS */
/* ============================= */
.section {
  padding: 5rem 1.5rem;
}

.container {
  max-width: var(--max-width);
  margin: auto;
}

/* ============================= */
/* SERVICES */
/* ============================= */
.services-preview {
  background: var(--bg-alt);
}

.services-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.service-preview-card {
  background: #fff;
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
  transition: var(--transition);
  border-top: 4px solid var(--primary);
}

.service-preview-card:hover {
  transform: translateY(-6px);
}

.service-icon {
  font-size: 2.2rem;
  margin-bottom: 1rem;
}

/* ============================= */
/* CTA SECTION */
/* ============================= */
.cta-section {
  background: var(--primary);
  color: #fff;
  text-align: center;
  padding: 4rem 2rem;
  border-radius: var(--radius);
  margin: 3rem 1rem;
}

.cta-section p {
  color: #ffffff;
  opacity: 0.9;
}

.cta-section .btn-primary {
  background: #fff;
  color: var(--primary);
}

.cta-section .btn-primary:hover {
  background: var(--bg-alt);
}

/* ============================= */
/* FOOTER */
/* ============================= */

/* Uniformiser les liens du footer (pas d'état :visited visible) */
.footer a:link,
.footer a:visited {
  color: inherit;         /* même couleur que le texte environnant */
  text-decoration: none;  /* pas de soulignement par défaut */
}

.footer a:hover {
  text-decoration: underline; /* soulignement au survol */
}

.footer {
  background: var(--text);
  color: rgba(255,255,255,0.2);
  padding: 3rem 1rem 2rem;
}

.footer-content {
  max-width: var(--max-width);
  margin: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  color: var(--primary);
  margin-bottom: 1rem;
}

.footer-bottom {
  text-align: center;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.7);
  border-top: 1px solid rgba(255,255,255,0.2);
  padding-top: 1rem;
}

/* ============================= */
/* CTA MOBILE STICKY */
/* ============================= */
.mobile-cta {
  display: none;
  position: fixed;
  bottom: 15px; right: 15px;
  background: var(--primary);
  color: #fff;
  padding: 0.8rem 1.2rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.95rem;
  box-shadow: var(--shadow);
  z-index: 2000;
  text-decoration: none;
}

/* ============================= */
/* RESPONSIVE */
/* ============================= */
@media (max-width: 900px) {
  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-image img {
    max-width: 85%;
    margin: auto;
  }
}

@media (max-width: 768px) {
  .mobile-toggle { display: flex; }
  .nav-menu {
    position: fixed;
    top: 70px; left: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background: #fff;
    flex-direction: column;
    justify-content: start;
    align-items: center;
    padding-top: 3rem;
    gap: 2rem;
    transition: var(--transition);
  }
  .nav-menu.active { left: 0; }
  .mobile-cta { display: inline-block; }
}

/* ==============================
   STYLES COMPLÉMENTAIRES
   ============================== */

/* Page Header */
.page-header {
    text-align: center;
    padding: 4rem 0 2rem;
}

.page-header h2 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #333;
}

.page-header p {
    font-size: 1.2rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* Stats Section */
.stats-section {
    background-color: #f8f9fa;
    padding: 4rem 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: center;
}

.stat-item {
    padding: 2rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: #d32f2f;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1.1rem;
    color: #333;
    font-weight: 600;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-card h3 {
    color: #d32f2f;
    margin: 1rem 0;
}

.service-card ul {
    list-style: none;
    margin-top: 1rem;
}

.service-card ul li {
    padding: 0.3rem 0;
    position: relative;
    padding-left: 1.5rem;
}

.service-card ul li:before {
    content: "✓";
    color: #d32f2f;
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* Process Section */
.process-section {
    margin: 5rem 0;
    text-align: center;
}

.process-steps {
    display: grid;
    /* MODIFICATION ICI : On passe de 200px à 150px pour permettre aux 6 blocs de tenir */
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    /* MODIFICATION ICI : On réduit l'écart de 2rem à 1rem pour gagner de la place */
    gap: 1rem; 
    margin-top: 3rem;
    /* AJOUT : Pour s'assurer que tout est bien aligné en haut */
    align-items: start;
}

.process-step {
    padding: 2rem 1rem;
}

.step-number {
    width: 60px;
    height: 60px;
    background: #d32f2f;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1rem;
}

/* Section About */
#about {
  padding: 5rem 2rem;
  background: #fafafa;
  text-align: center; /* centre tout le texte par défaut */
}

/* Header */
.page-header {
  text-align: center;
  margin-bottom: 3rem;
}

.page-header h2 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #222;
}

.page-header h2 span {
  color: #d32f2f;
}

.page-header .subtitle {
  font-size: 1.2rem;
  color: #555;
  margin-top: 0.5rem;
}

/* Layout texte + image */
.about-content {
  display: flex;
  flex-direction: column; /* vertical sur mobile / centré */
  align-items: center;
  gap: 3rem;
  margin-bottom: 4rem;
}

.about-text {
  max-width: 800px;
  text-align: center; /* centre texte */
}

.about-text h2 {
  color: #d32f2f;
  font-size: 1.6rem;
  margin: 2rem 0 1rem;
}

.about-text p {
  line-height: 1.7;
  color: #444;
}

/* Image */
.about-image img {
  width: 100%;
  max-width: 500px; /* limite la largeur */
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  object-fit: cover;
}

/* Engagements - cartes */
.commitments-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center; /* centre les cartes horizontalement */
  gap: 2rem;
  margin-top: 2rem;
}

.commitment-card {
  perspective: 1000px;
  flex: 1 1 200px; /* cartes flexibles */
  max-width: 250px;
}

.card-inner {
  position: relative;
  width: 100%;
  height: 180px;
  transform-style: preserve-3d;
  transition: transform 0.8s ease;
  cursor: pointer;
}

.commitment-card:hover .card-inner {
  transform: rotateY(180deg);
}

.card-front,
.card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  backface-visibility: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center; /* centre le texte */
  font-size: 1.1rem;
  padding: 1rem;
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.card-front {
  background: #fff;
  color: #d32f2f;
  font-weight: bold;
}

.card-back {
  background: #d32f2f;
  color: #fff;
  transform: rotateY(180deg);
  font-size: 0.95rem;
  line-height: 1.4;
}

/* Valeurs */
.values-section {
  margin: 5rem 0;
  text-align: center;
}

.values-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center; /* centre horizontalement */
  gap: 2rem;
  margin-top: 3rem;
}

.value-item {
  text-align: center;
  padding: 2rem;
  max-width: 300px;
  flex: 1 1 250px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.value-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.value-item h3 {
  color: #d32f2f;
  margin-bottom: 1rem;
}

/* Contact Section */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    margin: 3rem 0;
}

.contact-info h2 {
    color: #d32f2f;
    margin-bottom: 2rem;
}

.contact-item {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.contact-item h3 {
    color: #333;
    margin-bottom: 0.5rem;
}

.contact-item a {
    color: #d32f2f;
    text-decoration: none;
}

.contact-item a:hover {
    text-decoration: underline;
}

.contact-form {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 10px;
}

.contact-form h2 {
    color: #d32f2f;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #d32f2f;
}

.form-submit {
    width: 100%;
    padding: 15px;
    background-color: #d32f2f;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.form-submit:hover {
    background-color: #b71c1c;
}

/* FAQ Section */
.faq-section {
    margin: 5rem 0;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.faq-item {
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.faq-item h3 {
    color: #d32f2f;
    margin-bottom: 1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .page-header h2 {
        font-size: 2.5rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .process-steps {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .page-header h2 {
        font-size: 2rem;
    }
    
    .service-card {
        padding: 1.5rem;
    }
}

/* ============================= */
/* PAGE RÉALISATIONS */
/* ============================= */

/* Navigation des catégories */
.categories-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin: 2rem 0 3rem;
    padding-top: 1rem; /* Espacement supplémentaire pour le scroll */
    scroll-margin-top: 90px; /* Position de scroll optimale */
}

.cat-btn {
    padding: 0.75rem 1.5rem;
    border: 2px solid var(--primary);
    background: white;
    color: var(--primary);
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    font-family: var(--font);
}

.cat-btn.active,
.cat-btn:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* Grille des réalisations */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.portfolio-item {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
    border-top: 4px solid var(--primary);
}

.portfolio-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

/* ================================= */
/* GESTION INTELLIGENTE DES FORMATS  */
/* ================================= */

.portfolio-image {
    width: 100%;
    /* On retire la hauteur fixe en pixels */
    height: auto; 
    position: relative;
    overflow: hidden;
}

/* 1. CAS HORIZONTAL (Paysage) */
/* Par défaut ou si la classe 'project-horizontal' est là */
.portfolio-item .portfolio-image,
.portfolio-item.project-horizontal .portfolio-image {
    /* Format 4/3 (Standard photo appareil) ou 16/9 (Écran large) */
    aspect-ratio: 4 / 3; 
}

/* 2. CAS VERTICAL (Portrait) */
.portfolio-item.project-vertical .portfolio-image {
    /* Format 3/4 (Standard photo téléphone vertical) */
    /* Cela va agrandir la hauteur automatiquement par rapport à la largeur */
    aspect-ratio: 3 / 4; 
}

.portfolio-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #ffffff;
    display: block;
}

.portfolio-item:hover .portfolio-image img {
    transform: scale(1.03);
}

.portfolio-content {
    padding: 1.8rem;
}

.portfolio-category {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.portfolio-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text);
    line-height: 1.3;
}

.portfolio-description {
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.portfolio-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.2rem;
    padding-top: 1.2rem;
    border-top: 1px solid var(--bg-alt);
    font-size: 0.9rem;
    color: var(--text-light);
}

.portfolio-location {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.portfolio-date {
    font-weight: 600;
    color: var(--primary);
}

/* État vide */
.no-projects {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-light);
    font-size: 1.1rem;
    grid-column: 1 / -1;
}

.no-projects::before {
    content: "📋";
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Animation de chargement */
.portfolio-item {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Filtrage avec transition */
.portfolio-grid {
  align-items: start;
  transition: all 0.3s ease;
}

/* ============================= */
/* RESPONSIVE RÉALISATIONS */
/* ============================= */
@media (max-width: 900px) {
    .portfolio-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .categories-nav {
        gap: 0.5rem;
    }
    
    .cat-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }
    
    .portfolio-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .portfolio-content {
        padding: 1.5rem;
    }
    
    .portfolio-meta {
        flex-direction: column;
        gap: 0.5rem;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .categories-nav {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 0.5rem;
        margin: 1.5rem 0 2rem;
    }
    
    .cat-btn {
        white-space: nowrap;
        flex-shrink: 0;
    }
}

/* Effet de superposition sur les images */
.portfolio-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0) 70%, rgba(0,0,0,0.1) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.portfolio-item:hover .portfolio-image::after {
    opacity: 1;
}

/* Indicateur de catégorie active */
.categories-nav {
    position: relative;
}

.cat-btn.active {
    position: relative;
    z-index: 1;
}

/* Amélioration de l'accessibilité */
.cat-btn:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.portfolio-item:focus-within {
    outline: 2px solid var(--primary);
    outline-offset: 4px;
}

/* ============================= */
/* ANIMATIONS DE SCROLL */
/* ============================= */

/* État initial des éléments animés */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* État animé */
.animate-on-scroll.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* Animations spécifiques pour différents éléments */
.service-card.animate-on-scroll,
.service-preview-card.animate-on-scroll {
    transition-delay: 0.1s;
}

.stat-item.animate-on-scroll {
    transition-delay: 0.2s;
}

.portfolio-item.animate-on-scroll {
    transition-delay: 0.1s;
}

.process-step.animate-on-scroll {
    transition-delay: 0.15s;
}

.commitment-card.animate-on-scroll {
    transition-delay: 0.1s;
}

/* Animation en cascade pour les grilles */
.services-grid .service-card:nth-child(1).animate-on-scroll { transition-delay: 0.1s; }
.services-grid .service-card:nth-child(2).animate-on-scroll { transition-delay: 0.2s; }
.services-grid .service-card:nth-child(3).animate-on-scroll { transition-delay: 0.3s; }
.services-grid .service-card:nth-child(4).animate-on-scroll { transition-delay: 0.4s; }
.services-grid .service-card:nth-child(5).animate-on-scroll { transition-delay: 0.5s; }
.services-grid .service-card:nth-child(6).animate-on-scroll { transition-delay: 0.6s; }

.stats-grid .stat-item:nth-child(1).animate-on-scroll { transition-delay: 0.1s; }
.stats-grid .stat-item:nth-child(2).animate-on-scroll { transition-delay: 0.2s; }
.stats-grid .stat-item:nth-child(3).animate-on-scroll { transition-delay: 0.3s; }
.stats-grid .stat-item:nth-child(4).animate-on-scroll { transition-delay: 0.4s; }

.process-steps .process-step:nth-child(1).animate-on-scroll { transition-delay: 0.1s; }
.process-steps .process-step:nth-child(2).animate-on-scroll { transition-delay: 0.2s; }
.process-steps .process-step:nth-child(3).animate-on-scroll { transition-delay: 0.3s; }
.process-steps .process-step:nth-child(4).animate-on-scroll { transition-delay: 0.4s; }
.process-steps .process-step:nth-child(5).animate-on-scroll { transition-delay: 0.5s; }

/* Animation pour les titres de section */
.section-title.animate-on-scroll {
    transform: translateY(20px);
    transition-delay: 0.1s;
}

.section-subtitle.animate-on-scroll {
    transform: translateY(20px);
    transition-delay: 0.2s;
}

/* Animation pour les éléments de contact */
.contact-item.animate-on-scroll {
    transition-delay: 0.1s;
}

/* Animation pour les FAQ */
.faq-item.animate-on-scroll {
    transition-delay: 0.1s;
}

/* Animation pour le contenu about */
.about-text.animate-on-scroll {
    transition-delay: 0.1s;
}

.about-image.animate-on-scroll {
    transition-delay: 0.3s;
}

/* Animation pour la section CTA */
.cta-section.animate-on-scroll {
    transform: translateY(40px);
    transition-delay: 0.2s;
}

/* Animation pour les cartes d'engagement */
.commitments-grid .commitment-card:nth-child(1).animate-on-scroll { transition-delay: 0.1s; }
.commitments-grid .commitment-card:nth-child(2).animate-on-scroll { transition-delay: 0.2s; }
.commitments-grid .commitment-card:nth-child(3).animate-on-scroll { transition-delay: 0.3s; }
.commitments-grid .commitment-card:nth-child(4).animate-on-scroll { transition-delay: 0.4s; }
.commitments-grid .commitment-card:nth-child(5).animate-on-scroll { transition-delay: 0.5s; }

/* Animation pour les éléments de portfolio */
.portfolio-grid .portfolio-item:nth-child(1).animate-on-scroll { transition-delay: 0.1s; }
.portfolio-grid .portfolio-item:nth-child(2).animate-on-scroll { transition-delay: 0.2s; }
.portfolio-grid .portfolio-item:nth-child(3).animate-on-scroll { transition-delay: 0.3s; }
.portfolio-grid .portfolio-item:nth-child(4).animate-on-scroll { transition-delay: 0.4s; }
.portfolio-grid .portfolio-item:nth-child(5).animate-on-scroll { transition-delay: 0.5s; }
.portfolio-grid .portfolio-item:nth-child(6).animate-on-scroll { transition-delay: 0.6s; }

/* Désactiver les animations pour les utilisateurs qui préfèrent moins de mouvement */
@media (prefers-reduced-motion: reduce) {
    .animate-on-scroll {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* ============================= */
/* SYSTÈME DE COOKIES */
/* ============================= */

/* Bannière de cookies */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-top: 1px solid #e0e0e0;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    z-index: 10000;
    padding: 1.5rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-content {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.cookie-text {
    flex: 1;
    min-width: 300px;
}

.cookie-text h4 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.cookie-text p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn-cookie {
    padding: 0.7rem 1.5rem;
    border: none;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-accept {
    background: var(--primary);
    color: white;
}

.btn-accept:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-reject {
    background: #6c757d;
    color: white;
}

.btn-reject:hover {
    background: #5a6268;
}

.btn-customize {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-customize:hover {
    background: var(--primary);
    color: white;
}

.btn-save {
    background: var(--primary);
    color: white;
}

.btn-save:hover {
    background: var(--primary-dark);
}

/* Modal de cookies */
.cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.cookie-modal.show {
    opacity: 1;
    visibility: visible;
}

.cookie-modal-content {
    background: white;
    border-radius: var(--radius);
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.cookie-modal.show .cookie-modal-content {
    transform: scale(1);
}

.cookie-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
}

.cookie-modal-header h3 {
    color: var(--text);
    margin: 0;
    font-size: 1.3rem;
}

.close-modal {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.close-modal:hover {
    background: #f8f9fa;
    color: var(--text);
}

.cookie-modal-body {
    padding: 1.5rem;
}

.cookie-modal-body > p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.cookie-category {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: var(--bg-alt);
    border-radius: 8px;
}

.cookie-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.cookie-category-header h4 {
    color: var(--text);
    margin: 0;
    font-size: 1rem;
}

.cookie-category p {
    color: var(--text-light);
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.4;
}

/* Toggle switch */
.cookie-toggle {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.cookie-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background-color: var(--primary);
}

input:checked + .toggle-slider:before {
    transform: translateX(26px);
}

input:disabled + .toggle-slider {
    background-color: var(--primary);
    opacity: 0.6;
    cursor: not-allowed;
}

.cookie-modal-footer {
    padding: 1.5rem;
    border-top: 1px solid #e0e0e0;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    flex-wrap: wrap;
}

/* Responsive */
@media (max-width: 768px) {
    .cookie-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .cookie-text {
        min-width: auto;
    }
    
    .cookie-buttons {
        justify-content: center;
        width: 100%;
    }
    
    .btn-cookie {
        flex: 1;
        min-width: 120px;
    }
    
    .cookie-modal-content {
        margin: 1rem;
        max-height: 90vh;
    }
    
    .cookie-modal-footer {
        flex-direction: column;
    }
    
    .cookie-modal-footer .btn-cookie {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .cookie-banner {
        padding: 1rem;
    }
    
    .cookie-buttons {
        flex-direction: column;
    }
    
    .btn-cookie {
        width: 100%;
    }
}

/* ============================= */
/* AVANT / APRÈS SLIDER */
/* ============================= */
.ba-slider {
  position: relative;
  width: 100%;
  max-width: 1100px;
  margin: 2rem auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  background: #000;
}

.ba-media {
  position: relative;
  width: 100%;
  background: #000;
}

.ba-media > img {
  position: relative;
  display: block;
  width: 100%;
  height: auto;

  max-height: 1000px;  
  
  object-fit: cover;  
}

/* Mode "contain" pour les images très verticales */
.ba-media.ba-contain img {
  object-fit: contain;
  background: #000;
}

.ba-reveal {
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 100%; 
  clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0);
  z-index: 2;
}

.ba-reveal img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;

  height: 100%;       
  max-height: 1000px;
  object-fit: cover;
}

.ba-handle {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--pos, 50%);
  width: 2px;
  background: #fff;
  box-shadow: 0 0 0 1px rgba(0,0,0,0.15);
  cursor: ew-resize;
  z-index: 10; /* <--- Ajout conseillé */
}

.ba-handle::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 38px; height: 38px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
}

.ba-handle::after {
  content: '\2194'; /* ↔ */
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -53%);
  font-size: 16px;
  color: #333;
  font-weight: 700;
}

.ba-badge {
  position: absolute;
  top: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(0,0,0,0.55);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  z-index: 20; 
  pointer-events: none; 
}

.ba-badge-before { left: 14px; }
.ba-badge-after { right: 14px; }

@media (max-width: 768px) {
  .ba-media { padding-top: 66.66%; }
  .ba-handle::before { width: 34px; height: 34px; }
}

/* ============================= */
/* MODAL RÉALISATION */
/* ============================= */
.project-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.0);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 1rem;
}

.project-modal.show { 
  display: flex; 
  animation: modalFade .25s ease forwards;
}

.project-modal .modal-content {
  width: min(1300px, 98vw);
  max-height: 98vh;
  overflow: auto;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  transform: scale(0.82);
  opacity: 0;
  will-change: transform, opacity;
}

.project-modal.show .modal-content:not(.from-rect):not(.stable) { 
  animation: modalZoom .28s cubic-bezier(.2,.7,.3,1) forwards;
}

.project-modal .modal-content.from-rect {
  transition: transform .35s cubic-bezier(.2,.7,.3,1), opacity .2s ease;
  opacity: 1; /* contrôlé par JS */
}

.project-modal .modal-content.stable {
  opacity: 1;
  transform: none;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid #eee;
}

.modal-title {
  font-size: 1.2rem;
  font-weight: 800;
}

.modal-close {
  background: transparent;
  border: none;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
  color: #666;
}

.modal-body { padding: 1.5rem 1.75rem 2rem; }

.project-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  color: var(--text-light);
  margin: .75rem 0 1rem;
}

.project-description { margin: .5rem 0 1.25rem; }

.project-gallery { margin-top: 1rem; }

.project-hero {
  width: 100%;
  height: auto;       /* La hauteur s'adapte à l'image */
  min-height: 200px;  /* Minimum pour ne pas être trop petit */
  max-height: 70vh;   /* Maximum 70% de la hauteur de l'écran */
  
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
  
  /* Centre l'image et met un fond propre */
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #f8f9fa; 
}

.project-hero img {
  width: auto;        /* Largeur naturelle */
  max-width: 100%;    /* Ne dépasse pas la largeur de la boîte */
  height: auto;       /* Hauteur naturelle */
  max-height: 70vh;   /* Ne dépasse pas la hauteur max */
  
  object-fit: contain; /* MAGIQUE : Affiche l'image entière sans couper */
  display: block;
}

@media (max-width: 768px) {
  .modal-body { padding: .75rem; }
}

@keyframes modalZoom {
  0%   { transform: scale(.75) translateY(30px); opacity: 0; }
  60%  { transform: scale(1.02) translateY(-4px); opacity: 1; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

@keyframes modalFade {
  from { background: rgba(0,0,0,0.0); }
  to   { background: rgba(0,0,0,0.6); }
}

@keyframes modalSlideIn {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes cardPulse {
  0%   { transform: scale(1); }
  40%  { transform: scale(0.95); }
  100% { transform: scale(1); }
}

/* Animation cascade du contenu modal */
.modal-body > * {
  animation: modalSlideIn .35s ease both;
}
.modal-body > *:nth-child(1) { animation-delay: .08s; }
.modal-body > *:nth-child(2) { animation-delay: .16s; }
.modal-body > *:nth-child(3) { animation-delay: .22s; }

/* Portfolio cards */
.portfolio-item {
  transition: transform .25s cubic-bezier(.2,.8,.3,1), box-shadow .25s ease;
}
.portfolio-item:hover {
  transform: translateY(-6px) scale(1.015);
  box-shadow: 0 16px 40px rgba(0,0,0,.14);
}
.portfolio-item:active {
  animation: cardPulse .3s ease forwards;
}

/* Phase tab transition */
.phase-gallery {
  animation: modalSlideIn .25s ease both;
}

/* Modal overlay animation */
.project-modal.show {
  animation: modalFade .25s ease forwards;
}

/* Empêche le scroll de la page quand le modal est ouvert */
body.modal-open {
  overflow: hidden;
  height: 100vh;
}

/* ============================= */
/* OUTILS UPLOAD SIMPLIFIÉS */
/* ============================= */
.upload-tools-wrapper {
    background: #eef2f5;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border: 1px solid #dee2e6;
}

.upload-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.btn-upload-popup {
    background: #1977f2; /* Couleur PostImages */
    color: white;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

.btn-upload-popup:hover {
    background: #1465d1;
    transform: translateY(-2px);
}

.input-with-action {
    display: flex;
    gap: 0.5rem;
}

.input-with-action input {
    flex: 1;
}

.btn-paste {
    background: var(--text);
    color: white;
    border: none;
    padding: 0 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    white-space: nowrap;
    transition: var(--transition);
}

.btn-paste:hover {
    background: #000;
}

.upload-instruction {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* ============================= */
/* PAGE AVIS CLIENTS */
/* ============================= */
.reviews-page-body .reviews-page-main {
    padding-top: 90px;
}

.reviews-hero {
    background: linear-gradient(180deg, var(--bg-alt) 0%, var(--bg) 100%);
}

.reviews-page-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 1rem;
}

.reviews-summary {
    text-align: center;
    margin-top: 1.5rem;
}

.reviews-summary-text {
    display: inline-block;
    background: var(--bg);
    padding: 1rem 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    color: var(--text);
    margin: 0;
}

.reviews-avg-stars {
    letter-spacing: 0.05em;
    color: #c9a227;
}

.reviews-list-section {
    padding-bottom: 2rem;
}

.reviews-grid {
    display: grid;
    gap: 1.25rem;
    grid-template-columns: 1fr;
}

@media (min-width: 768px) {
    .reviews-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.reviews-empty {
    text-align: center;
    color: var(--text-light);
    padding: 2rem;
    background: var(--bg-alt);
    border-radius: var(--radius);
}

.review-card {
    background: var(--bg);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    border: 1px solid rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.review-card-header {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.review-card-stars {
    color: #c9a227;
    letter-spacing: 0.08em;
    font-size: 1.1rem;
}

.review-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 1rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

.review-card-author {
    font-style: normal;
    font-weight: 700;
    color: var(--text);
}

.review-card-city {
    font-size: 0.85rem;
}

.review-card-text {
    margin: 0;
    color: var(--text);
    line-height: 1.65;
    font-size: 1rem;
}

.reviews-form-section {
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-alt) 35%, var(--bg-alt) 100%);
    padding-top: 3rem;
    padding-bottom: 4rem;
}

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

.reviews-form-wrap .section-title {
    text-align: center;
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    margin-bottom: 0.5rem;
}

.reviews-form-wrap .section-subtitle {
    text-align: center;
    color: var(--text-light);
    font-size: 1.05rem;
    max-width: 28rem;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 2rem;
    line-height: 1.55;
}

.reviews-form--card {
    margin: 0;
}

.reviews-form-card {
    background: var(--bg);
    border-radius: calc(var(--radius) + 4px);
    padding: clamp(1.5rem, 4vw, 2.25rem);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.07), 0 1px 0 rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.form-row-reviews {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 600px) {
    .form-row-reviews {
        grid-template-columns: 1fr 1fr;
        gap: 1.25rem 1.5rem;
    }
}

.reviews-form-card .form-group {
    margin-bottom: 1.35rem;
}

.reviews-form-card .form-group:last-of-type {
    margin-bottom: 0;
}

.reviews-form-card label {
    display: block;
    font-weight: 600;
    font-size: 0.92rem;
    color: var(--text);
    margin-bottom: 0.45rem;
}

.reviews-form-card .req {
    color: var(--primary);
    text-decoration: none;
    font-weight: 700;
}

.reviews-form-card .optional {
    font-weight: 500;
    color: var(--text-light);
    font-size: 0.88em;
}

.form-hint-review {
    margin: 0.4rem 0 0;
    font-size: 0.82rem;
    color: var(--text-light);
    line-height: 1.45;
}

.reviews-form-card input[type="text"],
.reviews-form-card textarea {
    width: 100%;
    padding: 0.85rem 1rem;
    font-size: 1rem;
    font-family: inherit;
    border: 2px solid #e8eaed;
    border-radius: 10px;
    background: #fafbfc;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.reviews-form-card input[type="text"]::placeholder,
.reviews-form-card textarea::placeholder {
    color: #adb5bd;
}

.reviews-form-card input[type="text"]:hover,
.reviews-form-card textarea:hover {
    border-color: #dde1e6;
    background: var(--bg);
}

.reviews-form-card input[type="text"]:focus,
.reviews-form-card textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--bg);
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.15);
}

.reviews-form-card textarea {
    min-height: 140px;
    resize: vertical;
    line-height: 1.55;
}

.form-group-rating {
    text-align: center;
    padding: 1.25rem 0 0.5rem;
    margin-bottom: 1.5rem !important;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    margin-top: 0.25rem;
}

.label-rating {
    display: block;
    font-weight: 600;
    font-size: 0.92rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}

.star-rating-widget {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.2rem;
    flex-wrap: wrap;
}

.star-rating-btn {
    font-size: clamp(2rem, 6vw, 2.75rem);
    line-height: 1;
    padding: 0.2rem 0.15rem;
    margin: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    color: #e0e4e8;
    transition: color 0.15s ease, transform 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}

.star-rating-btn:hover {
    transform: scale(1.08);
}

.star-rating-btn:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 4px;
    border-radius: 4px;
}

.star-rating-btn--active {
    color: #e5b80c;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
}

.rating-caption {
    margin: 0.85rem 0 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: 0.02em;
}

.reviews-form-submit {
    width: 100%;
    margin-top: 1.75rem;
    padding: 1rem 1.5rem;
    font-size: 1.05rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(230, 57, 70, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.reviews-form-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(230, 57, 70, 0.4);
}

.reviews-form-submit-icon {
    font-size: 1.15rem;
    opacity: 0.95;
}

.reviews-form-card .form-message {
    margin-top: 1.25rem;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    font-size: 0.95rem;
}

.reviews-form-card .form-message-success {
    background: rgba(27, 122, 61, 0.08);
    color: #1b7a3d;
}

.reviews-form-card .form-message-error {
    background: rgba(230, 57, 70, 0.08);
}

.form-message {
    margin-top: 1rem;
    font-size: 0.95rem;
}

.form-message-success {
    color: #1b7a3d;
    font-weight: 600;
}

.form-message-error {
    color: var(--primary);
    font-weight: 600;
}