/* ===================================
   BorneElec44 - Custom Stylesheet
   Inspiré de cortexa.africa
   =================================== */

/* --- CSS Variables (Charte graphique) --- */
:root {
    --primary: #1B2A4A;
    --primary-light: #2C3E6B;
    --primary-dark: #0F1A33;
    --secondary: #00B4D8;
    --secondary-light: #48CAE4;
    --secondary-dark: #0096B7;
    --accent: #F7A600;
    --accent-light: #FFB833;
    --accent-dark: #CC8800;
    --success: #2DC653;
    --light-bg: #F5F7FA;
    --white: #FFFFFF;
    --text-dark: #1B2A4A;
    --text-muted: #5A6B8A;
    --text-light: #8896AB;
    --border-color: #E2E8F0;
    --shadow-sm: 0 1px 3px rgba(27, 42, 74, 0.08);
    --shadow-md: 0 4px 14px rgba(27, 42, 74, 0.1);
    --shadow-lg: 0 10px 30px rgba(27, 42, 74, 0.12);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* --- Reset & Base --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    color: var(--text-dark);
    background-color: var(--white);
    line-height: 1.7;
    padding-top: 76px;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
    color: var(--primary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }

@media (max-width: 768px) {
    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }
}

a {
    color: var(--secondary);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--secondary-dark);
}

/* --- Navbar --- */
.navbar {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%) !important;
    box-shadow: var(--shadow-md);
    padding: 0.8rem 0;
}

.navbar-brand {
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.navbar .nav-link {
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 1rem !important;
    transition: opacity 0.2s;
}

.navbar .nav-link:hover {
    opacity: 0.85;
}

.navbar .btn-warning {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--primary);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    padding: 0.5rem 1.2rem;
    transition: all 0.2s;
}

.navbar .btn-warning:hover {
    background: var(--accent-light);
    border-color: var(--accent-light);
    transform: translateY(-1px);
}

.dropdown-menu {
    border: none;
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-md);
    padding: 0.5rem;
}

.dropdown-item {
    border-radius: var(--radius-sm);
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.dropdown-item:hover {
    background-color: var(--light-bg);
    color: var(--secondary);
}

/* --- Hero Section --- */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 50%, var(--secondary-dark) 100%);
    color: white;
    padding: 5rem 0 4rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 60%;
    height: 200%;
    background: radial-gradient(ellipse, rgba(0, 180, 216, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.hero h1 {
    color: white;
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.2rem;
}

.hero .lead {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.15rem;
    max-width: 600px;
}

.hero .badge {
    font-size: 0.85rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
}

@media (max-width: 768px) {
    .hero {
        padding: 3rem 0 2rem;
    }
    .hero h1 {
        font-size: 1.8rem;
    }
}

/* --- Lead Form Card (Hero) --- */
.hero-form-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 2rem;
    position: relative;
    z-index: 2;
}

.hero-form-card .form-label {
    color: var(--text-dark);
    font-weight: 600;
    font-size: 0.85rem;
    margin-bottom: 0.3rem;
}

.hero-form-card .form-control,
.hero-form-card .form-select {
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 0.6rem 0.9rem;
    font-size: 0.9rem;
    transition: border-color 0.2s;
}

.hero-form-card .form-control:focus,
.hero-form-card .form-select:focus {
    border-color: var(--secondary);
    box-shadow: 0 0 0 3px rgba(0, 180, 216, 0.15);
}

.hero-form-card .form-text {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* --- Buttons --- */
.btn-primary {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%);
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
    text-transform: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--secondary-light) 0%, var(--secondary) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 180, 216, 0.35);
}

.btn-warning {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--primary);
    font-weight: 600;
    border-radius: var(--radius-sm);
}

.btn-warning:hover {
    background: var(--accent-light);
    border-color: var(--accent-light);
    color: var(--primary);
    transform: translateY(-1px);
}

.btn-outline-primary {
    border: 2px solid var(--secondary);
    color: var(--secondary);
    border-radius: var(--radius-sm);
    font-weight: 600;
}

.btn-outline-primary:hover {
    background: var(--secondary);
    border-color: var(--secondary);
    color: white;
}

/* --- Trust Badges --- */
.trust-badges {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}

.trust-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    font-weight: 500;
}

.trust-badge i {
    font-size: 1.3rem;
    color: var(--accent);
}

/* --- Stats Section --- */
.stats-section {
    background: var(--light-bg);
    padding: 3rem 0;
}

.stat-card {
    text-align: center;
    padding: 1.5rem;
}

.stat-card .stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--secondary);
    line-height: 1;
}

.stat-card .stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    font-weight: 500;
}

/* --- Section Styling --- */
.section {
    padding: 5rem 0;
}

.section-alt {
    background-color: var(--light-bg);
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title h2 {
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--secondary);
    border-radius: 2px;
    margin: 0.75rem auto 0;
}

.section-title p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto;
}

/* --- Service Cards --- */
.service-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    height: auto;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.row > [class*="col"] > .service-card:only-child {
    height: 100%;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--secondary);
}

/* Image dans les service cards */
.service-card-img {
    width: calc(100% + 4rem);
    margin: -2rem -2rem 1.5rem -2rem;
    height: 200px;
    object-fit: cover;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

/* Image hero des pages villes */
.city-hero-img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    box-shadow: var(--shadow-md);
}

.service-card .icon-box {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, rgba(0, 180, 216, 0.1) 0%, rgba(0, 180, 216, 0.05) 100%);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.2rem;
}

.service-card .icon-box i {
    font-size: 1.8rem;
    color: var(--secondary);
}

.service-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.8rem;
}

.service-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.service-card .card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-weight: 600;
    font-size: 0.9rem;
    margin-top: 1rem;
}

/* --- Process Steps --- */
.process-step {
    text-align: center;
    padding: 1.5rem;
    position: relative;
}

.process-step .step-number {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: white;
    font-size: 1.3rem;
    font-weight: 800;
}

.process-step h4 {
    font-size: 1.05rem;
    margin-bottom: 0.5rem;
}

.process-step p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* --- Testimonials --- */
.testimonial-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.8rem;
    height: 100%;
    transition: box-shadow 0.3s;
}

.testimonial-card:hover {
    box-shadow: var(--shadow-md);
}

.testimonial-card .stars {
    margin-bottom: 0.8rem;
}

.testimonial-card blockquote {
    font-style: italic;
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.testimonial-card .author {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-dark);
}

.testimonial-card .location {
    font-size: 0.8rem;
    color: var(--text-light);
}

/* --- City Cards --- */
.city-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    display: block;
    color: var(--text-dark);
    text-decoration: none;
}

.city-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--secondary);
    color: var(--text-dark);
}

.city-card i {
    font-size: 1.5rem;
    color: var(--secondary);
    margin-bottom: 0.5rem;
    display: block;
}

.city-card .city-name {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.city-card .city-cp {
    font-size: 0.8rem;
    color: var(--text-light);
}

/* --- FAQ Section --- */
.accordion-button {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-dark);
    border-radius: var(--radius-sm) !important;
}

.accordion-button:not(.collapsed) {
    background-color: rgba(0, 180, 216, 0.08);
    color: var(--secondary-dark);
}

.accordion-button:focus {
    box-shadow: 0 0 0 3px rgba(0, 180, 216, 0.15);
}

.accordion-item {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm) !important;
    margin-bottom: 0.5rem;
}

/* --- CTA Section --- */
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 50%, var(--secondary-dark) 100%);
    position: relative;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 50%, rgba(0, 180, 216, 0.2) 0%, transparent 50%);
}

/* --- Footer --- */
.footer {
    background: var(--primary-dark);
    color: var(--white);
}

.footer h5, .footer h6 {
    color: var(--white);
}

.footer a:hover {
    color: var(--secondary-light) !important;
}

/* --- Breadcrumb --- */
.breadcrumb {
    background: transparent;
    padding: 0;
    margin: 1.5rem 0;
    font-size: 0.85rem;
}

.breadcrumb-item a {
    color: var(--secondary);
}

.breadcrumb-item.active {
    color: var(--text-muted);
}

/* --- City/Quartier Page --- */
.page-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
    padding: 4rem 0 3rem;
    margin-bottom: 0;
}

.page-header h1 {
    color: white;
    font-weight: 800;
}

.page-header .lead {
    color: rgba(255, 255, 255, 0.8);
}

/* --- Sidebar Sticky --- */
.content-section,
.content-section .container,
.content-section .row,
.section,
.section .container,
.section .row {
    overflow: visible;
}

.sidebar-sticky .hero-form-card {
    position: -webkit-sticky;
    position: sticky;
    top: 100px;
    z-index: 10;
}

/* --- Content Sections --- */
.content-section {
    padding: 3rem 0;
}

.content-section h2 {
    margin-bottom: 1.2rem;
}

.content-section p {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 1rem;
}

/* --- Info Box --- */
.info-box {
    background: var(--light-bg);
    border-left: 4px solid var(--secondary);
    border-radius: var(--radius-sm);
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.info-box h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: var(--secondary-dark);
}

.info-box p {
    margin-bottom: 0;
    font-size: 0.95rem;
}

/* --- Price Table --- */
.price-card {
    background: var(--white);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    text-align: center;
    transition: all 0.3s;
}

.price-card.featured {
    border-color: var(--secondary);
    transform: scale(1.03);
    box-shadow: var(--shadow-lg);
}

.price-card .price {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--secondary);
}

.price-card .price small {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
}

/* --- Alert Success (Form) --- */
#form-success {
    border-radius: var(--radius-md);
    border: none;
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
}

/* --- Form Validation --- */
.form-control.is-invalid,
.form-select.is-invalid {
    border-color: #dc3545;
}

.form-control.is-valid,
.form-select.is-valid {
    border-color: var(--success);
}

/* --- Loading spinner --- */
.spinner-border-sm {
    width: 1rem;
    height: 1rem;
    border-width: 0.15em;
}

/* --- Utility --- */
.text-secondary-custom {
    color: var(--secondary) !important;
}

.bg-light-custom {
    background-color: var(--light-bg) !important;
}

/* --- Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* --- Responsive --- */
@media (max-width: 992px) {
    .hero {
        text-align: center;
    }

    .hero .lead {
        margin: 0 auto 1.5rem;
    }

    .trust-badges {
        justify-content: center;
    }

    .hero-form-card {
        margin-top: 2rem;
    }
}

@media (max-width: 576px) {
    .section {
        padding: 3rem 0;
    }

    .stat-card .stat-number {
        font-size: 2rem;
    }
}
