/* --- Variables & Reset --- */
:root {
    --primary-blue: #1c3d5a;
    --primary-red: #e63946;
    --primary-green: #2a9d8f;
    --text-color: #333;
    --bg-light: #f4f7f6;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Lato', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-light);
}

h1, h2, h3 { font-family: 'Montserrat', sans-serif; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.text-center { text-align: center; }

/* --- Header & Nav --- */
.main-header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 15px 0;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img { max-height: 60px; }

.main-nav ul { list-style: none; display: flex; gap: 20px; }
.main-nav a { text-decoration: none; color: var(--primary-blue); font-weight: bold; transition: 0.3s; }
.main-nav a:hover { color: var(--primary-red); }

/* --- Hero Section avec Image de Fond --- */
.hero {
    position: relative;
    background:
                url('../images/hero-bg.jpg') no-repeat center center / cover;
    color: white;
    padding: 120px 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.hero h1 { 
    font-size: 3rem; 
    margin-bottom: 15px; 
    font-weight: 700;
}

.hero .subtitle { 
    font-size: 1.4rem; 
    margin-bottom: 35px; 
    font-weight: 300;
}

/* --- Boutons --- */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-red);
    color: white;
}

.btn-primary:hover { 
    background-color: #c5303c; 
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(230, 57, 70, 0.4);
}

/* --- SECTION À PROPOS & SERVICES (INDEX) --- */
.about-section {
    padding: 100px 0;
    background-color: #fff;
}

.about-text h2 {
    font-size: 2.5rem;
    color: var(--primary-blue);
    margin-bottom: 20px;
}

.lead-text {
    max-width: 800px;
    margin: 0 auto 50px;
    font-size: 1.1rem;
    color: #666;
    line-height: 1.8;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.service-card {
    background: var(--bg-light);
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    transition: all 0.4s ease;
    border: 1px solid #eee;
}

.service-card:hover {
    transform: translateY(-10px);
    background: #fff;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    border-color: var(--primary-red);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--primary-red);
    margin-bottom: 20px;
}

.service-card h3 {
    color: var(--primary-blue);
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.service-card p {
    font-size: 0.95rem;
    color: #777;
}

.btn-outline {
    border: 2px solid var(--primary-blue);
    color: var(--primary-blue);
    margin-top: 30px;
}

.btn-outline:hover {
    background: var(--primary-blue);
    color: #fff;
}

.mt-40 { margin-top: 40px; }

/* --- Footer --- */
.main-footer { background: #222; color: #fff; padding: 40px 0 10px; margin-top: 40px;}
.footer-content { display: flex; justify-content: space-between; flex-wrap: wrap; }
.qualibat-logo { max-height: 80px; margin-bottom: 10px; }
.footer-bottom { text-align: center; border-top: 1px solid #444; margin-top: 20px; padding-top: 10px; font-size: 0.9em; }

/* --- Galerie Grille --- */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 40px;
    padding-bottom: 60px;
}

.gallery-item {
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    height: 250px;
}

.gallery-item a {
    display: block;
    width: 100%;
    height: 100%;
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease, filter 0.4s ease;
    display: block;
    cursor: pointer;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.05);
    filter: brightness(80%);
}

/* --- REFONTE PAGE CONTACT MODERNE --- */
.contact-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.top-subtitle {
    display: block;
    color: var(--primary-red);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.custom-underline {
    width: 60px;
    height: 4px;
    background: var(--primary-blue);
    margin: 20px auto;
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 40px;
    margin-top: 50px;
}

.info-card {
    display: flex;
    align-items: center;
    background: #fff;
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.info-card:hover { transform: translateX(10px); }

.icon-box {
    width: 50px;
    height: 50px;
    background: var(--primary-blue);
    color: #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-right: 20px;
}

.info-text h3 { font-size: 1rem; margin-bottom: 5px; color: var(--primary-blue); }
.info-text p { font-size: 0.95rem; color: #666; margin: 0; }

.contact-form-box {
    background: #fff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.input-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.contact-form-box .form-group { margin-bottom: 25px; }
.contact-form-box label { font-weight: 600; color: var(--primary-blue); margin-bottom: 8px; display: block; }

.contact-form-box input, 
.contact-form-box textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #edf2f7;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s;
    background: #f8fafc;
}

.contact-form-box input:focus, 
.contact-form-box textarea:focus {
    border-color: var(--primary-blue);
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 4px rgba(28, 61, 90, 0.1);
}

.btn-modern {
    background: var(--primary-blue);
    color: white;
    border: none;
    padding: 18px 35px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: 0.3s;
    width: 100%;
    justify-content: center;
}

.btn-modern:hover {
    background: var(--primary-red);
    transform: translateY(-3px);
}

/* --- FLÈCHES DE NAVIGATION (SimpleLightbox) --- */
.sl-wrapper .sl-navigation button {
    display: block !important;
    color: #fff !important;
    background: rgba(0, 0, 0, 0.5) !important;
    width: 60px !important;
    height: 60px !important;
    border-radius: 50% !important;
    font-size: 3rem !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    transition: background 0.3s !important;
}

.sl-wrapper .sl-navigation button:hover {
    background: var(--primary-red) !important;
}

.sl-wrapper .sl-navigation button.sl-prev { left: 20px !important; }
.sl-wrapper .sl-navigation button.sl-next { right: 20px !important; }

/* Responsive */
@media (max-width: 992px) {
    .contact-wrapper { grid-template-columns: 1fr; }
    .input-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .about-text h2 { font-size: 1.8rem; }
    .about-section { padding: 60px 0; }
    .sl-wrapper .sl-navigation button { width: 45px !important; height: 45px !important; font-size: 2rem !important; }
}