/* Contact Page Styles */

body{
    background-color: var(--bg);
    overflow-x: hidden; /* Empêche le scroll horizontal */
}

html {
    overflow-x: hidden; /* Empêche le scroll horizontal au niveau HTML aussi */
}
header {
  position: relative;
  top: 10px;
  z-index: 1000;
}
#contact-section {
    /* background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%); */
    min-height: 80vh;
    padding: 80px 0;
    display: flex;
    align-items: center;
}

.contact-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%; /* Force la largeur à 100% */
    box-sizing: border-box; /* Inclut padding dans la largeur */
}

.contact-content {
    background: white;
    border-radius: 20px;
    padding: 60px;
    box-shadow: 0 20px 60px rgba(0, 35, 77, 0.1);
    border: 3px solid var(--primary);
    width: 100%; /* Force la largeur à 100% */
    max-width: 100%; /* Empêche le débordement */
    box-sizing: border-box; /* Inclut padding et border dans la largeur */
}

/* Intro Section */
.contact-intro {
    text-align: center;
    margin-bottom: 60px;
}

.contact-intro h1 {
    font-family: "Josefin Sans", sans-serif;
    font-size: 48px;
    color: var(--primary);
    margin-bottom: 20px;
    font-weight: 700;
}

.contact-description {
    font-size: 20px;
    color: #6c757d;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

/* Layout principal */
.contact-main {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 60px;
    align-items: start;
}

/* Section formulaire */
.contact-form-section {
    background: #f8f9fa;
    padding: 40px;
    border-radius: 15px;
    border: 2px solid #e9ecef;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-family: "Archivo Narrow", sans-serif;
    font-weight: 600;
    font-size: 16px;
    color: var(--primary);
    margin-bottom: 5px;
}

.form-group input,
.form-group textarea {
    padding: 15px 20px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-family: "Work Sans", sans-serif;
    font-size: 16px;
    background: white;
    transition: all 0.3s ease;
    resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(132, 184, 255, 0.1);
    transform: translateY(-2px);
}

.form-group textarea {
    min-height: 120px;
    line-height: 1.6;
}

.error-message {
    color: var(--accent);
    font-size: 14px;
    font-weight: 500;
    margin-top: 5px;
    display: none;
}

.contact-submit-btn {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 18px 40px;
    border: none;
    border-radius: 50px;
    font-family: "Archivo Narrow", sans-serif;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

.contact-submit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 35, 77, 0.2);
}

.contact-submit-btn i {
    font-size: 16px;
}

/* Section informations */
.contact-info-section {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.contact-info h3 {
    font-family: "Josefin Sans", sans-serif;
    font-size: 28px;
    color: var(--primary);
    margin-bottom: 30px;
    font-weight: 600;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 12px;
    border-left: 4px solid var(--secondary);
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.contact-item:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(132, 184, 255, 0.1);
}

.contact-item i {
    font-size: 20px;
    color: var(--secondary);
    margin-top: 2px;
    min-width: 20px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.contact-label {
    font-family: "Archivo Narrow", sans-serif;
    font-weight: 600;
    font-size: 14px;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.contact-link {
    color: var(--secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.contact-link:hover {
    color: var(--primary);
    text-decoration: underline;
}

.contact-text {
    color: #6c757d;
    font-weight: 500;
}

/* Section réseaux sociaux */
.social-section {
    background: var(--primary);
    padding: 30px;
    border-radius: 15px;
    color: white;
}

.social-section h4 {
    font-family: "Josefin Sans", sans-serif;
    font-size: 20px;
    margin-bottom: 20px;
    color: var(--secondary);
}

.social-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.social-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.social-link:hover {
    background: rgba(132, 184, 255, 0.2);
    border-color: var(--secondary);
    transform: translateX(5px);
}

.social-link i {
    font-size: 18px;
    min-width: 18px;
}

.social-link span {
    font-family: "Archivo Narrow", sans-serif;
    font-weight: 500;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    #contact-section {
        padding: 40px 0;
        overflow-x: hidden; /* Empêche le débordement horizontal */
    }
    
    .contact-container {
        padding: 0 15px; /* Réduit le padding sur mobile */
    }
    
    .contact-content {
        padding: 30px 15px; /* Réduit le padding interne */
        margin: 0 5px; /* Réduit les marges latérales */
        border-radius: 15px; /* Réduit le border-radius */
        width: calc(100% - 10px); /* Assure qu'il n'y a pas de débordement */
    }
    
    .contact-intro h1 {
        font-size: 36px;
    }
    
    .contact-description {
        font-size: 18px;
    }
    
    .contact-main {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .contact-form-section {
        padding: 25px;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 12px 16px;
        font-size: 16px;
    }
    
    .contact-submit-btn {
        padding: 15px 30px;
        font-size: 16px;
    }
    
    .contact-info h3 {
        font-size: 24px;
    }
    
    .contact-item {
        padding: 15px;
    }
    
    .social-section {
        padding: 25px;
    }
    
    .social-links {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .social-link {
        flex: 1;
        min-width: 120px;
        justify-content: center;
    }
}

@media screen and (max-width: 480px) {
    .contact-container {
        padding: 0 10px; /* Padding réduit pour iPhone */
    }
    
    .contact-content {
        padding: 20px 10px; /* Padding très réduit */
        margin: 0 2px; /* Marges minimales */
        border-radius: 10px; /* Border-radius réduit */
        width: calc(100% - 4px); /* Largeur calculée pour éviter débordement */
        border-width: 2px; /* Border plus fine */
    }
    
    .contact-intro h1 {
        font-size: 28px;
        line-height: 1.2;
    }
    
    .contact-description {
        font-size: 16px;
    }
    
    .contact-main {
        gap: 30px;
    }
    
    .contact-form-section {
        padding: 20px;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 10px 14px;
    }
    
    .contact-submit-btn {
        padding: 12px 25px;
        font-size: 15px;
    }
    
    .social-links {
        flex-direction: column;
    }
    
    .social-link {
        justify-content: flex-start;
    }
}

/* Animation d'entrée */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.contact-content {
    animation: fadeInUp 0.8s ease-out;
}

/* États de validation */
.form-group.error input,
.form-group.error textarea {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(239, 62, 54, 0.1);
}

.form-group.error .error-message {
    display: block;
}

.form-group.success input,
.form-group.success textarea {
    border-color: #28a745;
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1);
}

/* Loading state pour le bouton */
.contact-submit-btn.loading {
    opacity: 0.7;
    cursor: not-allowed;
}

.contact-submit-btn.loading i {
    animation: spin 1s linear infinite;
}

.social-section i{
    margin-left: 20px;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
