/*
 Theme Name:   neovanne child
 Description:  neovanne child Theme
 Author:       XTemos
 Author URI:   http://xtemos.com
 Template:     neovanne
 Version:      1.0.0
 Text Domain:  neovanne
*/

/* ========================================
   VARIABLES CSS - SYSTÈME DE COULEURS NEOVANNE
   ======================================== */

:root {
    --neovanne-primary: #007BC4;
    --neovanne-primary-dark: #005A94;
    --neovanne-secondary: #00507C;
    --neovanne-dark: #003366;
    --neovanne-success: #2E7D32;
    --neovanne-warning: #FF8F00;
    --neovanne-danger: #C41E3A;
    --neovanne-neutral: #2c3e50;
    --neovanne-light: #f8f9fa;
    --neovanne-lighter: #f7f7f7;
}

/* ========================================
   WOOCOMMERCE - DESCRIPTIONS PRODUITS
   ======================================== */

/* Styles pour la description des produits */
.woocommerce-product-details__short-description,
.woocommerce-Tabs-panel--description {
    font-size: 18px;
    line-height: 1.7;
    color: #222;
}

/* Titre principal */
.woocommerce-product-details__short-description h1,
.woocommerce-Tabs-panel--description h1 {
    color: #222;
    font-size: 36px;
    border-bottom: 3px solid var(--neovanne-primary);
    padding-bottom: 15px;
    margin-bottom: 30px;
}

/* Sous-titres */
.woocommerce-product-details__short-description h2,
.woocommerce-Tabs-panel--description h2 {
    color: var(--neovanne-primary);
    font-size: 26px;
    margin-bottom: 20px;
}

.woocommerce-product-details__short-description h3,
.woocommerce-Tabs-panel--description h3 {
    color: var(--neovanne-primary);
    font-size: 20px;
    margin-bottom: 15px;
}

/* Liens */
.woocommerce-product-details__short-description a,
.woocommerce-Tabs-panel--description a {
    color: var(--neovanne-primary);
    text-decoration: none;
}

.woocommerce-product-details__short-description a:hover,
.woocommerce-Tabs-panel--description a:hover {
    text-decoration: underline;
}

/* Boîtes d'information */
.woocommerce-product-details__short-description .info-box,
.woocommerce-Tabs-panel--description .info-box {
    background-color: var(--neovanne-lighter);
    padding: 20px;
    border-radius: 4px;
    margin-bottom: 30px;
}

/* Tableaux */
.woocommerce-product-details__short-description table,
.woocommerce-Tabs-panel--description table {
    width: 100%;
    border-collapse: collapse;
    font-size: 16px;
    margin-bottom: 40px;
}

.woocommerce-product-details__short-description th,
.woocommerce-Tabs-panel--description th {
    background-color: var(--neovanne-primary);
    color: white;
    padding: 15px;
    font-size: 17px;
}

.woocommerce-product-details__short-description td,
.woocommerce-Tabs-panel--description td {
    padding: 15px;
    border-bottom: 1px solid #e5e5e5;
}

.woocommerce-product-details__short-description tr:nth-child(even),
.woocommerce-Tabs-panel--description tr:nth-child(even) {
    background-color: var(--neovanne-lighter);
}

/* Section guide d'installation */
.woocommerce-product-details__short-description .installation-guide,
.woocommerce-Tabs-panel--description .installation-guide {
    background-color: var(--neovanne-primary);
    color: white;
    padding: 25px;
    border-radius: 4px;
    margin-bottom: 30px;
}

.woocommerce-product-details__short-description .installation-guide h2,
.woocommerce-Tabs-panel--description .installation-guide h2 {
    color: white;
    font-size: 22px;
    margin-bottom: 15px;
}

.woocommerce-product-details__short-description .installation-guide ul,
.woocommerce-Tabs-panel--description .installation-guide ul {
    font-size: 16px;
}

/* Détails interactifs */
.woocommerce-product-details__short-description details {
    margin-bottom: 18px;
}

.woocommerce-product-details__short-description details[open] summary {
    color: var(--neovanne-primary);
}

.woocommerce-product-details__short-description summary {
    cursor: pointer;
    font-size: 18px;
    margin-bottom: 7px;
    font-weight: 500;
}

.woocommerce-product-details__short-description hr {
    border: none;
    border-top: 1px solid #e2e8f0;
    margin: 18px 0;
}

/* ========================================
   MEGA MENU - COMPATIBLE WOODMART
   ======================================== */

/* Ciblage spécifique des méga menus Woodmart */
.wd-navigation .elementor-widget-wd_extra_menu_list .elementor-widget-wrap.elementor-element-populated,
.wd-navigation div[data-widget_type="wd_extra_menu_list.default"] .elementor-widget-wrap.elementor-element-populated {
    padding: 8px 10px;
    color: var(--neovanne-secondary);
    font-size: 15px;
    font-weight: 400;
}

/* Structure principale pour les méga menus - z-index réduit */
.wd-navigation .elementor-inner-section.wd-negative-gap:has(.elementor-widget-wd_extra_menu_list) {
    z-index: 100; /* Réduit de 1000 à 100 */
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    overflow: hidden;
    border-top: 3px solid #0073aa;
    background: linear-gradient(to bottom, #ffffff, #f5f9fc);
}

/* Titres des catégories dans les méga menus */
.wd-navigation .elementor-widget-wd_extra_menu_list h4,
.wd-navigation .elementor-widget-wd_extra_menu_list h3 {
    color: var(--neovanne-dark);
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e5e5e5;
}

/* Liens dans les méga menus */
.wd-navigation .elementor-widget-wd_extra_menu_list a {
    color: var(--neovanne-secondary);
    font-size: 15px;
    font-weight: 400;
    padding: 8px 10px;
    margin: 3px 0;
    transition: all 0.25s ease;
    display: block;
    border-radius: 4px;
    position: relative;
    padding-left: 20px;
}

/* Flèche devant les liens */
.wd-navigation .elementor-widget-wd_extra_menu_list a:before {
    content: '›';
    position: absolute;
    left: 8px;
    color: #0073aa;
    font-weight: bold;
    transition: transform 0.2s ease;
}

.wd-navigation .elementor-widget-wd_extra_menu_list a:hover {
    background-color: rgba(0, 123, 196, 0.1);
    color: var(--neovanne-primary-dark);
    transform: translateX(3px);
}

.wd-navigation .elementor-widget-wd_extra_menu_list a:hover:before {
    transform: translateX(2px);
}

/* ========================================
   DESCRIPTIONS DE CATÉGORIES
   ======================================== */

/* Titres des catégories - ciblage spécifique */
.woocommerce-page .term-description .wd-entities-title,
.tax-product_cat .wd-entities-title,
.product-category .wd-entities-title {
    color: #333333;
    font-size: 32px;
    border-bottom: 2px solid var(--neovanne-primary);
    padding-bottom: 15px;
    margin-bottom: 30px;
}

/* Titres secondaires des catégories */
.woocommerce-page .term-description .wd-entities-title.secondary,
.tax-product_cat .wd-entities-title.secondary,
.product-category .wd-entities-title.secondary {
    color: var(--neovanne-primary);
    font-size: 24px;
    margin-bottom: 20px;
    border-bottom: none;
}

/* Boîte d'informations produit */
.product-info-box {
    background-color: var(--neovanne-lighter);
    padding: 20px;
    border-radius: 4px;
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.product-info-box p {
    margin-bottom: 10px;
    font-size: 16px;
    font-weight: 600;
    color: #333333;
}

/* Introduction produit */
.product-intro {
    font-size: 16px;
    line-height: 1.6;
    color: #333333;
    margin-bottom: 30px;
}

.product-intro a {
    color: var(--neovanne-primary);
    text-decoration: none;
}

.product-intro a:hover {
    text-decoration: underline;
}

/* Wrapper pour les tableaux de catégories */
.wd-table-wrapper {
    margin-bottom: 40px;
    overflow-x: auto;
}

/* Tableaux de spécifications - responsive amélioré */
.wd-table-wrapper .table {
    width: 100%;
    border-collapse: collapse;
    font-size: 15px;
    background: white;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    /* Suppression du min-width forcé */
}

.wd-table-wrapper .table thead tr {
    background-color: var(--neovanne-primary);
    color: white;
}

.wd-table-wrapper .table th,
.wd-table-wrapper .table td {
    padding: 15px;
    border: 1px solid #e5e5e5;
    text-align: left;
}

.wd-table-wrapper .table tbody tr:nth-child(odd) {
    background-color: var(--neovanne-lighter);
}

.wd-table-wrapper .table tbody tr:nth-child(even) {
    background-color: white;
}

.wd-table-wrapper .table tbody tr:hover {
    background-color: var(--neovanne-light);
}

.wd-table-wrapper .table td a {
    color: var(--neovanne-primary);
    text-decoration: none;
    font-weight: 500;
}

.wd-table-wrapper .table td a:hover {
    text-decoration: underline;
}

/* Section spécifications techniques */
.technical-specs {
    margin-bottom: 30px;
}

.technical-specs h2 {
    color: #333333;
    font-size: 24px;
    margin-bottom: 20px;
}

.technical-specs h3 {
    color: var(--neovanne-primary);
    margin-bottom: 15px;
    font-size: 18px;
}

.tech-specs-box {
    background-color: var(--neovanne-lighter);
    padding: 25px;
    border-radius: 4px;
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
}

.tech-specs-content {
    font-size: 15px;
    line-height: 1.6;
}

.tech-specs-content ul {
    margin-bottom: 20px;
    padding-left: 20px;
}

.tech-specs-content li {
    margin-bottom: 8px;
}

.tech-specs-content li strong {
    color: #333333;
}

/* Section guide d'installation pour catégories */
.category-installation-guide {
    background-color: var(--neovanne-primary);
    color: white;
    padding: 25px;
    border-radius: 4px;
    margin-bottom: 30px;
}

.category-installation-guide h2 {
    color: white;
    font-size: 20px;
    margin-bottom: 15px;
}

.category-installation-guide p {
    margin-bottom: 15px;
    font-size: 16px;
}

.category-installation-guide ul {
    font-size: 15px;
    padding-left: 20px;
}

.category-installation-guide li {
    margin-bottom: 8px;
}

/* ========================================
   ARTICLES DE BLOG
   ======================================== */

/* Section hero - spécifique aux articles */
.single-post .hero-section,
.blog .hero-section {
    background: white;
    color: #333;
    padding: 2.5rem 2rem;
    border-radius: 6px;
    text-align: center;
    margin-bottom: 2rem;
    border: 2px solid var(--neovanne-primary);
    box-shadow: 0 4px 15px rgba(0, 123, 196, 0.1);
}

.single-post .hero-section h2,
.blog .hero-section h2 {
    color: var(--neovanne-primary) !important;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    border: none !important;
    font-weight: 600;
}

/* Bannière d'urgence */
.single-post .urgency-banner,
.blog .urgency-banner {
    background: var(--neovanne-danger);
    color: white;
    padding: 1rem;
    text-align: center;
    font-weight: 600;
    margin-bottom: 2rem;
    border-radius: 4px;
    border-left: 4px solid #A01729;
}

/* Statistiques clés */
.single-post .key-stats,
.blog .key-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.single-post .stat-card,
.blog .stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 6px;
    text-align: center;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
    border-left: 4px solid var(--neovanne-primary);
    border: 1px solid #e9ecef;
}

.single-post .stat-number,
.blog .stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--neovanne-primary);
    display: block;
    margin-bottom: 0.5rem;
}

/* Table des matières */
.single-post .interactive-toc,
.blog .interactive-toc {
    background: var(--neovanne-light);
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid var(--neovanne-primary);
    margin: 2rem 0;
    border: 1px solid #e9ecef;
}

.single-post .interactive-toc h3,
.blog .interactive-toc h3 {
    color: var(--neovanne-primary);
    margin-bottom: 1rem;
    font-weight: 600;
}

.single-post .interactive-toc a,
.blog .interactive-toc a {
    display: block;
    padding: 0.75rem 0;
    color: var(--neovanne-primary);
    text-decoration: none;
    border-bottom: 1px solid #e9ecef;
    transition: color 0.2s ease;
}

.single-post .interactive-toc a:hover,
.blog .interactive-toc a:hover {
    color: var(--neovanne-primary-dark);
    padding-left: 0.5rem;
}

/* Checklist */
.single-post .checklist,
.blog .checklist {
    background: #E8F4E8;
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid var(--neovanne-success);
    margin: 2rem 0;
    border: 1px solid #C8E6C9;
}

.single-post .checklist h3,
.blog .checklist h3 {
    color: var(--neovanne-success);
    margin-bottom: 1rem;
    font-weight: 600;
}

.single-post .checklist ul,
.blog .checklist ul {
    list-style: none;
    padding-left: 0;
}

.single-post .checklist li,
.blog .checklist li {
    padding: 0.5rem 0;
    font-size: 1rem;
    color: #1B5E20;
}

/* Boîtes d'avertissement */
.single-post .warning-box,
.blog .warning-box {
    background: #FFF8E1;
    border: 1px solid #FFE082;
    border-left: 4px solid var(--neovanne-warning);
    padding: 1.5rem;
    border-radius: 6px;
    margin: 2rem 0;
}

.single-post .warning-box h4,
.blog .warning-box h4 {
    color: #E65100;
    margin-bottom: 1rem;
    font-weight: 600;
}

/* Sections techniques */
.single-post .technical-requirements,
.blog .technical-requirements {
    background: var(--neovanne-light);
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid var(--neovanne-primary);
    border: 1px solid #e9ecef;
    margin: 2rem 0;
}

/* Preuve sociale */
.single-post .social-proof,
.blog .social-proof {
    background: var(--neovanne-neutral);
    color: white;
    padding: 2rem;
    border-radius: 6px;
    margin: 2rem 0;
    border-left: 4px solid var(--neovanne-primary);
}

.single-post .social-proof h4,
.blog .social-proof h4 {
    color: white;
    margin-bottom: 1rem;
    font-weight: 600;
}

.single-post .social-proof em,
.blog .social-proof em {
    font-size: 1.1rem;
    display: block;
    margin-bottom: 1rem;
    font-style: italic;
    opacity: 0.95;
}

/* Section CTA */
.single-post .cta-section,
.blog .cta-section {
    background: var(--neovanne-primary);
    color: white;
    padding: 3rem 2rem;
    border-radius: 6px;
    text-align: center;
    margin: 3rem 0;
}

.single-post .cta-section h3,
.blog .cta-section h3 {
    color: white !important;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.single-post .cta-section h4,
.blog .cta-section h4 {
    color: #FFE082;
    margin-bottom: 1rem;
    font-weight: 600;
}

/* Titres d'articles */
.single-post .container h2,
.blog .container h2 {
    color: #222;
    font-size: 28px;
    border-bottom: 2px solid var(--neovanne-primary);
    padding-bottom: 12px;
    margin-bottom: 25px;
    font-weight: 600;
}

.single-post .container h3,
.blog .container h3 {
    color: var(--neovanne-primary);
    font-size: 22px;
    margin-bottom: 18px;
    font-weight: 600;
}

/* Liens produits dans les articles */
.single-post .container a[href*="neovanne.com"],
.blog .container a[href*="neovanne.com"] {
    color: var(--neovanne-primary);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

.single-post .container a[href*="neovanne.com"]:hover,
.blog .container a[href*="neovanne.com"]:hover {
    border-bottom-color: var(--neovanne-primary);
}

/* ========================================
   HEADER ET BREADCRUMBS - WOODMART
   ======================================== */

/* Titre du header - respecter Woodmart */
.wd-page-title .entry-title.title {
    color: white;
}

/* Breadcrumbs du header - pas ceux de WooCommerce */
.wd-page-title .wd-breadcrumbs:not(.woocommerce-breadcrumb) {
    color: white;
    margin-top: 1rem;
    margin-bottom: 0;
}

.wd-page-title .wd-breadcrumbs:not(.woocommerce-breadcrumb) a,
.wd-page-title .wd-breadcrumbs:not(.woocommerce-breadcrumb) span {
    color: white;
}

.wd-page-title .wd-breadcrumbs:not(.woocommerce-breadcrumb) a:hover {
    color: rgba(255, 255, 255, 0.8);
}

.wd-page-title .entry-title.title a {
    color: white;
    text-decoration: none;
}

/* Badges de catégories - améliorer contraste */
.wd-post-cat.wd-style-with-bg,
.wd-post-cat.wd-style-with-bg a {
    color: white;
    text-decoration: none;
}

.wd-post-cat.wd-style-with-bg a:hover {
    color: rgba(255, 255, 255, 0.9);
}

/* Breadcrumbs WooCommerce - garder style original */
.woocommerce-breadcrumb {
    display: inline-block;
    background-color: var(--neovanne-light);
    padding: 10px 15px;
    border-radius: 5px;
    font-size: 14px;
    border: 1px solid #e9ecef;
}

.woocommerce-breadcrumb a {
    color: #007bff;
}

.woocommerce-breadcrumb span.separator {
    color: #999;
    margin: 0 5px;
    font-weight: bold;
}

/* ========================================
   FORMULAIRES - COMPATIBLE WOODMART
   ======================================== */

/* Footer form - ajustements minimes */
.wd-footer .row.g-2 > .col-6, 
.wd-footer .row.g-2 > .col-12 {
    padding-left: 5px;
    padding-right: 5px;
}

.wd-footer .form-control {
    height: 35px;
    font-size: 14px;
}

.wd-footer .wpcf7-form-control.wpcf7-textarea.form-control {
    min-height: 50px;
    resize: vertical;
}

.wd-footer .btn-color-black {
    padding: 5px 15px;
    font-size: 14px;
}

/* ========================================
   UTILITAIRES GÉNÉRAUX
   ======================================== */

/* Images centrées */
.aligncenter {
    display: block;
    margin: 2rem auto;
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
}

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

@media (max-width: 768px) {
    /* Images responsives optimisées */
    .wp-caption.alignleft {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto 1rem auto !important;
        text-align: center;
        float: none !important;
    }
    
    .wp-caption.alignleft img {
        display: block;
        margin: 0 auto;
        max-width: 100%; /* Optimisé : utilise tout l'espace */
        height: auto;
    }
    
    .wp-caption.alignleft .wp-caption-text {
        text-align: center;
        margin-top: 10px;
    }

    /* Header mobile - respecter Woodmart */
    .wd-page-wrapper.website-wrapper {
        margin-top: 0;
        padding-top: 0;
    }
    
    .site-logo {
        margin-top: -10px;
        padding-top: 0;
    }
    
    .wd-header {
        padding-top: 5px;
        padding-bottom: 5px;
    }
    
    .wd-page-title.page-title.page-title-default.title-size-default {
        margin-top: -10px;
        padding-top: 10px;
    }

    /* Responsive pour catégories */
    .woocommerce-page .term-description .wd-entities-title,
    .tax-product_cat .wd-entities-title,
    .product-category .wd-entities-title {
        font-size: 28px;
    }
    
    .woocommerce-page .term-description .wd-entities-title.secondary,
    .tax-product_cat .wd-entities-title.secondary,
    .product-category .wd-entities-title.secondary {
        font-size: 20px;
    }
    
    .product-info-box,
    .tech-specs-box,
    .category-installation-guide {
        padding: 15px;
    }
    
    /* Tableaux responsives optimisés */
    .wd-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch; /* Améliore le scroll sur iOS */
    }
    
    .wd-table-wrapper .table {
        font-size: 14px;
        min-width: 300px; /* Plus raisonnable que 600px */
    }
    
    .wd-table-wrapper .table th,
    .wd-table-wrapper .table td {
        padding: 8px 10px; /* Padding réduit pour mobile */
        font-size: 13px;
    }

    /* Responsive pour articles */
    .single-post .hero-section h2,
    .blog .hero-section h2 {
        font-size: 1.8rem;
    }
    
    .single-post .key-stats,
    .blog .key-stats {
        grid-template-columns: 1fr;
    }
    
    .single-post .stat-number,
    .blog .stat-number {
        font-size: 2rem;
    }
    
    .single-post .cta-section,
    .blog .cta-section {
        padding: 2rem 1rem;
    }
    
    .single-post .cta-section h3,
    .blog .cta-section h3 {
        font-size: 1.5rem;
    }
    
    .single-post .container h2,
    .blog .container h2 {
        font-size: 24px;
    }
    
    .single-post .container h3,
    .blog .container h3 {
        font-size: 20px;
    }
}