/**
 * Connect Security Go - Styles pour la page Historique
 * Ce fichier contient les styles spécifiques à la page historique
 */

/* Styles généraux pour les sections */
.section-subtitle {
    max-width: 800px;
    margin: 0 auto 30px;
    text-align: center;
    color: #666;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Styles pour la section chronologie */
.timeline-section {
    padding: 100px 0;
}

.timeline {
    position: relative;
    max-width: 1200px;
    margin: 50px auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 6px;
    background-color: var(--primary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -3px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
    margin-bottom: 50px;
}

.timeline-item:nth-child(odd) {
    left: 0;
}

.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 25px;
    right: -13px;
    background-color: var(--secondary-color);
    border: 4px solid var(--primary-color);
    top: 15px;
    border-radius: 50%;
    z-index: 1;
}

.timeline-item:nth-child(even)::after {
    left: -13px;
}

.timeline-content {
    padding: 30px;
    background-color: white;
    position: relative;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.timeline-content:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.timeline-date {
    display: inline-block;
    padding: 8px 15px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 5px;
    font-weight: 600;
    margin-bottom: 15px;
}

.timeline-content h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.timeline-content p {
    margin-bottom: 15px;
    color: #666;
}

.timeline-icon {
    position: absolute;
    bottom: 20px;
    right: 20px;
    color: var(--secondary-color);
    font-size: 1.5rem;
    opacity: 0.5;
    transition: var(--transition);
}

.timeline-content:hover .timeline-icon {
    opacity: 1;
    transform: scale(1.2);
}

/* Centre le texte sous “Notre Histoire” */
.timeline-section .section-description {
  text-align: center;        /* centre horizontalement */
  max-width: 600px;          /* limite la largeur pour une ligne agréable */
  margin: 0 auto 40px;       /* centre et ajoute un espace sous le paragraphe */
}


.values-section {
    padding: 80px 0;
    background-color: #f9f9f9;
}

.values-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}

.value-card {
    background-color: white;
    border-radius: 10px;
    padding: 40px 30px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.value-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(157, 131, 95, 0.05) 0%, rgba(22, 31, 59, 0.05) 100%);
    z-index: -1;
    transform: translateY(100%);
    transition: transform 0.5s ease;
}

.value-card:hover::before {
    transform: translateY(0);
}

.value-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.value-icon {
    width: 80px;
    height: 80px;
    background-color: rgba(157, 131, 95, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 2rem;
    color: #9D835F;
}

.value-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #161F3B;
}

.value-card p {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.6;
}

.value-tag {
    display: inline-block;
    padding: 5px 15px;
    background-color: #161F3B;
    color: white;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Styles pour la section équipe */
.team-section {
    padding: 100px 0;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.team-card {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.team-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.team-image {
    height: 250px;
    overflow: hidden;
    position: relative;
}

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

.team-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(157, 131, 95, 0.85);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    text-align: center;
    opacity: 0;
    transition: var(--transition);
}

.team-card:hover .team-overlay {
    opacity: 1;
}

.team-card:hover .team-image img {
    transform: scale(1.1);
}

.team-content {
    padding: 20px;
    text-align: center;
}

.team-content h3 {
    font-size: 1.3rem;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.team-content p {
    color: var(--secondary-color);
    font-weight: 600;
    margin-bottom: 15px;
}

.team-social {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.team-social a {
    width: 35px;
    height: 35px;
    background-color: rgba(22, 31, 59, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    transition: var(--transition);
}

.team-social a:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

/* ===== PAGE GALERIE ===== */
.gallery-section {
    padding: 80px 0;
}

.gallery-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 40px;
    gap: 10px;
}

.filter-btn {
    padding: 10px 20px;
    background-color: #f5f5f5;
    border: none;
    border-radius: 30px;
    color: #666;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.filter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #9D835F;
    z-index: -1;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.4s ease;
}

.filter-btn:hover::before {
    transform: scaleX(1);
    transform-origin: left;
}

.filter-btn:hover,
.filter-btn.active {
    background-color: #9D835F;
    color: white;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 30px;
}

.gallery-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    height: 300px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.gallery-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(157, 131, 95, 0.2), rgba(22, 31, 59, 0.2));
    opacity: 0;
    z-index: 1;
    transition: opacity 0.3s ease;
}

.gallery-item:hover::before {
    opacity: 1;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(22, 31, 59, 0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: all 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay h3 {
    color: white;
    font-size: 1.3rem;
    margin-bottom: 10px;
    text-align: center;
}

.gallery-overlay p {
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.gallery-overlay .date {
    display: inline-block;
    padding: 5px 15px;
    background-color: #9D835F;
    color: white;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.gallery-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 50px;
}

.gallery-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    position: relative;
    max-width: 900px;
    width: 100%;
}

.modal-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #9D835F;
    font-size: 3rem;
    z-index: 5;
    display: none;
}

.modal-loader.active {
    display: block;
    animation: spin 1s infinite linear;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-close:hover {
    color: #9D835F;
}

.modal-content img {
    width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 5px;
    animation: zoomIn 0.3s ease-out;
}

@keyframes zoomIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-caption {
    color: white;
    text-align: center;
    margin-top: 20px;
    font-size: 1.1rem;
}

.error-message {
    color: #ff5252;
    font-size: 0.9rem;
    margin-top: 10px;
    font-style: italic;
}

.modal-nav {
    display: flex;
    justify-content: space-between;
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    transform: translateY(-50%);
    padding: 0 20px;
}

.nav-prev, .nav-next {
    background-color: rgba(157, 131, 95, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.nav-prev:hover, .nav-next:hover {
    background-color: rgba(157, 131, 95, 1);
    transform: scale(1.1);
}

/* ===== PAGE DEVIS ===== */
.devis-section {
    padding-top: 120px;
}

.devis-container {
    /* on passe en flex pour centrer facilement */
    display: flex;                 
    justify-content: center;       /* centre horizontalement */
    align-items: center;           /* centre verticalement si besoin */
    margin: 50px auto 0;           /* décalage haut + centrage container */
    max-width: var(--container-width); /* largeur max (ex : 1200px) */
    width: 100%;                   /* pleine largeur jusqu’à max-width */
}

.devis-form {
    background-color: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
    overflow: hidden;
    transition: all 0.4s ease;
}

.devis-form::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(157, 131, 95, 0.05) 0%, rgba(255, 255, 255, 0) 70%);
    z-index: -1;
    transform: scale(0);
    transition: transform 0.8s ease;
}

.devis-form:hover::before {
    transform: scale(1);
}

.devis-form:hover {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.devis-form h3 {
    font-size: 1.6rem;
    margin-bottom: 30px;
    color: #161F3B;
    position: relative;
    padding-bottom: 15px;
}

.devis-form h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: #9D835F;
}

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

.checkbox-group h4 {
    margin-bottom: 15px;
    color: #161F3B;
    font-weight: 500;
}

.checkbox-item {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.checkbox-item input {
    margin-right: 10px;
}

.checkbox-item label {
    color: #666;
    cursor: pointer;
}

.submit-btn {
    display: inline-block;
    padding: 12px 25px;
    background-color: #9D835F;
    color: white;
    border: none;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.submit-btn:hover {
    background-color: #161F3B;
}

.devis-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.devis-info {
    margin-top: 80px;
    background-color: #f9f9f9;
    padding: 50px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.devis-info::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, #9D835F, #161F3B);
}

.devis-info h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: #161F3B;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

.devis-info h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: #9D835F;
}

.devis-info p {
    color: #666;
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    line-height: 1.8;
    font-size: 1.05rem;
}

.avantages-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, auto);
    gap: 30px;
    margin-bottom: 40px;
}

.avantage-item {
    display: flex;
    align-items: flex-start;
    padding: 20px;
    border-radius: 10px;
    transition: all 0.3s ease;
    background-color: white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

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

.avantage-icon {
    background-color: rgba(157, 131, 95, 0.1);
    color: #9D835F;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-right: 15px;
    position: relative;
    line-height: 0;
    padding: 0;
    flex-shrink: 0;
    transition: all 0.3s ease;
    text-align: center;
    box-sizing: border-box;
}

.avantage-item:hover .avantage-icon {
    background-color: #9D835F;
    color: white;
    transform: scale(1.1);
}

.avantage-icon i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.avantage-content h4 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: #161F3B;
    transition: color 0.3s ease;
}

.avantage-item:hover .avantage-content h4 {
    color: #9D835F;
}

.avantage-content p {
    color: #666;
    text-align: left;
    margin: 0;
    line-height: 1.5;
}

.devis-info-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(22, 31, 59, 0.05);
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 35px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    border-left: 4px solid #9D835F;
    transition: all 0.3s ease;
}

.devis-info-footer:hover {
    background-color: rgba(22, 31, 59, 0.08);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.devis-info-footer i {
    color: #9D835F;
    font-size: 1.8rem;
    margin-right: 20px;
    transition: transform 0.3s ease;
}

.devis-info-footer:hover i {
    transform: scale(1.1);
}

.devis-info-footer p {
    color: #555;
    margin: 0;
    font-size: 1rem;
    line-height: 1.6;
}

.btn-devis-action {
    display: block;
    width: fit-content;
    margin: 0 auto;
    background-color: #9D835F;
    color: white;
    padding: 16px 32px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    text-align: center;
    box-shadow: 0 5px 15px rgba(157, 131, 95, 0.3);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-devis-action::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background-color: #161F3B;
    transition: width 0.4s ease;
    z-index: -1;
}

.btn-devis-action:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(157, 131, 95, 0.4);
}

.btn-devis-action:hover::before {
    width: 100%;
}

.btn-devis-action i {
    margin-left: 8px;
    transition: transform 0.3s ease;
}

.btn-devis-action:hover i {
    transform: translateX(5px);
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 992px) {
    .timeline::before {
        left: 30px;
    }
    
    .timeline-content {
        width: calc(100% - 80px);
        margin-left: 80px !important;
    }
    
    .timeline-item:nth-child(odd) .timeline-icon,
    .timeline-item:nth-child(even) .timeline-icon {
        left: 10px;
    }
    
    .values-container,
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .devis-container {
        grid-template-columns: 1fr;
    }
    
    .avantages-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .timeline-content {
        padding: 20px;
    }
    
    .values-container,
    .team-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-modal {
        padding: 20px;
    }
    
    .avantages-grid {
        grid-template-columns: 1fr;
    }
    
    .devis-info {
        padding: 30px;
    }
}

@media (max-width: 576px) {
    .timeline-content {
        width: calc(100% - 60px);
        margin-left: 60px !important;
    }
    
    .timeline-item:nth-child(odd) .timeline-icon,
    .timeline-item:nth-child(even) .timeline-icon {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }
    
    .filter-btn {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
    
    .devis-form {
        padding: 25px;
    }
    
    .devis-info {
        padding: 25px;
    }
    
    .avantage-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
}

/* ——— Carte Google “Contact” ——— */
.contact-map {
  margin-top: 80px;                               /* espace avant */
  border-radius: 10px;                            /* coins arrondis */
  overflow: hidden;                               /* pour que l’iframe épouse la forme */
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);      /* même ombre que vos cards */
}

/* Ajuste la hauteur : plein largeur, 450px de haut (modifiable) */
.contact-map iframe {
  display: block;
  width: 100%;
  height: 450px;
  border: none;
}

/* ——— Styles pour les messages de formulaire ——— */

/* Message de succès */
.success-message {
  background-color: #e8f5e9;
  border-left: 5px solid var(--primary-color);
  border-radius: 5px;
  padding: 30px;
  text-align: center;
  margin: 20px 0;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  animation: fadeIn 0.5s ease-in-out;
}

.success-message i {
  font-size: 3rem;
  color: var(--primary-color);
  margin-bottom: 15px;
  display: block;
}

.success-message h3 {
  color: #2e7d32;
  margin-bottom: 10px;
  font-weight: 600;
}

.success-message p {
  color: #555;
  font-size: 1.1rem;
  line-height: 1.5;
}

/* Message d'erreur */
.error-message {
  background-color: #ffebee;
  border-left: 5px solid #d32f2f;
  border-radius: 5px;
  padding: 15px 20px;
  margin: 15px 0;
  color: #d32f2f;
  font-size: 0.95rem;
  animation: fadeIn 0.3s ease-in-out;
}

/* Animation pour les messages */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}
