/* ==================== RESET & BASE ==================== */

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

body {
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: #1a2a3a;
    background: #f8fafc;
}

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

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ==================== BOUTONS ==================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    border-radius: 9999px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    border: none;
    gap: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, #e55353, #c53a3a);
    color: white;
    box-shadow: 0 4px 14px rgba(229, 83, 83, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(229, 83, 83, 0.4);
}

.btn-portal {
    background: linear-gradient(135deg, #2e7d32, #1b5e20);
    color: white;
}

.btn-whatsapp {
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: white;
}

/* ==================== TITRES DE SECTION ==================== */

.section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #1e4a6b, #2c7da0);
    border-radius: 2px;
}

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

/* ==================== HEADER ==================== */

.header {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.logo-img-small {
    height: 60px;
    width: auto;
    border-radius: 8px;
}

.logo-text {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e4a6b;
}

.logo-text span {
    color: #2c7da0;
}

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

.nav a {
    text-decoration: none;
    color: #1e4a6b;
    font-weight: 500;
    transition: color 0.2s;
}

.nav a:hover,
.nav a.active {
    color: #2c7da0;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #1e4a6b;
}

/* ==================== HERO & DIAPORAMA ==================== */

.hero {
    color: white;
    padding: 6rem 1rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.slide.active {
    opacity: 1;
}

.slide-1  { background-image: url('imgA1.jpeg'); }
.slide-2  { background-image: url('imgA2.jpeg'); }
.slide-3  { background-image: url('imgA3.jpeg'); }
.slide-4  { background-image: url('imgA4.jpeg'); }
.slide-5  { background-image: url('imgA5.jpeg'); }
.slide-6  { background-image: url('imgA6.jpeg'); }
.slide-7  { background-image: url('imgA7.jpeg'); }
.slide-8  { background-image: url('imgA8.jpeg'); }
.slide-9  { background-image: url('imgA9.jpeg'); }
.slide-10 { background-image: url('imgA10.jpeg'); }

.slideshow-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 15px;
}

.slideshow-controls button {
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.slideshow-controls button:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.05);
}

.slideshow-dots {
    display: flex;
    gap: 10px;
    align-items: center;
}

.slideshow-dots div {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.slideshow-dots div:hover,
.slideshow-dots div.active-dot {
    background: white;
    transform: scale(1.2);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
    padding: 2.5rem;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(8px);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    animation: fadeInUp 0.8s ease;
}

.hero h1 {
    font-size: clamp(1.8rem, 5vw, 3rem);
    margin-bottom: 1rem;
    color: white;
}

.hero-subtitle {
    font-size: clamp(1rem, 3vw, 1.3rem);
    margin-bottom: 2rem;
    opacity: 0.95;
}

.hero-subtitle strong {
    color: #ffd966;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ==================== VALEURS ==================== */

.valeurs-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin: 4rem auto;
    padding: 0 1rem;
    max-width: 1280px;
}

.valeur-card {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.3s;
    text-align: center;
    border: 1px solid #eef2f6;
}

.valeur-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.valeur-icon {
    font-size: 3rem;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1e4a6b, #2c7da0);
    border-radius: 50%;
    margin: 0 auto 1rem;
    color: white;
}

.valeur-title {
    color: #1e4a6b;
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.valeur-description {
    color: #4a5568;
    margin-bottom: 1rem;
}

.valeur-footer {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.valeur-tag {
    background: #eef2f6;
    color: #1e4a6b;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* ==================== SPÉCIALITÉS ==================== */

.specialites {
    padding: 4rem 0;
    background: linear-gradient(135deg, #1e4a6b, #2c7da0);
}

.specialites .section-title {
    color: white;
}

.specialites .section-title::after {
    background: #ffd966;
}

.section-intro {
    text-align: center;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 800px;
    margin: 0 auto 2rem;
}

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

.specialite-card {
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    transition: all 0.3s;
}

.specialite-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.specialite-card h3 {
    color: #1e4a6b;
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
}

.specialite-card p {
    color: #4a5568;
    font-size: 0.95rem;
}

/* ==================== URGENCES ==================== */

.urgences {
    padding: 4rem 0;
    background: linear-gradient(135deg, #fff5f5, #ffe0e0);
}

.urgences-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: center;
}

.urgences-card {
    background: white;
    padding: 2rem;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.urgence-number {
    display: inline-block;
    background: #e55353;
    color: white;
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-size: 1.3rem;
    font-weight: bold;
    margin: 1rem 0;
    transition: transform 0.3s;
}

.urgence-number:hover {
    transform: scale(1.05);
}

/* ==================== FORMULAIRE DE RÉSERVATION ==================== */

.reservation {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f0f9ff, #e6f4ff);
}

.reservation-form-container {
    max-width: 700px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #1e4a6b;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.875rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.2s;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #2c7da0;
    box-shadow: 0 0 0 3px rgba(44, 125, 160, 0.1);
}

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

.btn-submit {
    width: 100%;
    background: linear-gradient(135deg, #1e4a6b, #2c7da0);
    color: white;
    padding: 1rem;
    border-radius: 9999px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
}

.btn-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(30, 74, 107, 0.3);
}

.btn-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.alert {
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    display: none;
    animation: fadeInUp 0.3s ease;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ==================== PORTAIL PATIENT ==================== */

.portail-patient {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f0f9f0, #e8f5e9);
}

.portail-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    background: white;
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.portail-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.feature {
    padding: 1.5rem;
    background: #f9fdf9;
    border-radius: 16px;
    border: 1px solid #e8f5e8;
}

.feature h4 {
    color: #2e7d32;
    margin-bottom: 0.5rem;
}

/* ==================== CONTACT ==================== */

.contact {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f8fafc, #eef2f6);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.contact-info {
    background: white;
    padding: 2rem;
    border-radius: 24px;
}

.contact-phone {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: linear-gradient(135deg, #1e4a6b, #2c7da0);
    color: white;
    border-radius: 12px;
    text-decoration: none;
    margin: 1rem 0;
    transition: transform 0.2s;
}

.contact-phone:hover {
    transform: translateX(5px);
}

.contact-whatsapp {
    background: linear-gradient(135deg, #25D366, #128C7E);
}

.horaires {
    margin-top: 1.5rem;
    padding: 1rem;
    background: #f8fafc;
    border-radius: 12px;
}

.contact-map {
    border-radius: 24px;
    overflow: hidden;
    height: 400px;
}

.contact-map iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

.map-link {
    text-align: center;
    margin-top: 0.5rem;
}

/* ==================== BACK TO TOP ==================== */

.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
    background: #1e4a6b;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transition: all 0.3s;
    z-index: 99;
}

.back-to-top:hover {
    transform: translateY(-3px);
    background: #2c7da0;
}

.back-to-top.visible {
    display: flex;
}

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

.footer {
    background: linear-gradient(135deg, #0a2a3a, #1a3a4a);
    color: white;
    padding: 3rem 0 1.5rem;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-links h4 {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

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

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-social {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.footer-social a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.2s;
}

.footer-social a:hover {
    background: #2c7da0;
    transform: translateY(-3px);
}

.footer-copyright {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.6);
}

/* ==================== COOKIE BANNER ==================== */

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1e4a6b;
    color: white;
    padding: 1rem;
    text-align: center;
    z-index: 1000;
    display: none;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: center;
}

.cookie-banner button {
    background: #ffd966;
    color: #1e4a6b;
    border: none;
    padding: 0.5rem 1.5rem;
    border-radius: 9999px;
    cursor: pointer;
    font-weight: 600;
}

.cookie-banner .btn-refuse {
    background: transparent;
    color: white;
    border: 1px solid white;
}

/* ==================== RESPONSIVE ==================== */

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }
    .nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        padding: 1rem;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    }
    .nav.active ul {
        display: flex;
    }
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .contact-grid {
        grid-template-columns: 1fr;
    }
    .urgences-grid {
        grid-template-columns: 1fr;
    }
    .hero-buttons .btn {
        width: 100%;
        max-width: 280px;
    }
    .slideshow-controls button {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* ==================== ACCESSIBILITÉ ==================== */

a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 3px solid #2c7da0;
    outline-offset: 2px;
}
