/*
Theme Name: FixeCoreBoot
Theme URI: https://fixecoreboot.fr
Description: Thème enfant Kadence pour FixeCoreBoot.fr — spécialiste français du reconditionné informatique. Design moderne, éco-responsable, optimisé conversion e-commerce.
Author: FixeCoreBoot
Author URI: https://fixecoreboot.fr
Template: kadence
Version: 1.0.0
Text Domain: fixecoreboot
License: GNU General Public License v2 or later
Tags: e-commerce, woocommerce, custom-colors, custom-logo, custom-menu
*/

/* ==========================================================================
   FixeCoreBoot — Design System
   Palette : vert (#10B981) - cyan (#06B6D4) - orange (#F97316) - noir
   ========================================================================== */

:root {
    --fix-green: #10B981;
    --fix-green-dark: #059669;
    --fix-cyan: #06B6D4;
    --fix-cyan-dark: #0891B2;
    --fix-orange: #F97316;
    --fix-orange-dark: #EA580C;
    --fix-black: #0A0A0A;
    --fix-dark: #171717;
    --fix-gray-900: #1F2937;
    --fix-gray-700: #374151;
    --fix-gray-500: #6B7280;
    --fix-gray-300: #D1D5DB;
    --fix-gray-100: #F3F4F6;
    --fix-white: #FFFFFF;
    --fix-radius: 12px;
    --fix-shadow: 0 4px 20px rgba(16, 185, 129, 0.12);
    --fix-shadow-hover: 0 8px 32px rgba(6, 182, 212, 0.18);
    --fix-font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ==========================================================================
   Global
   ========================================================================== */

body {
    font-family: var(--fix-font);
    color: var(--fix-gray-900);
    line-height: 1.65;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--fix-black);
}

a {
    color: var(--fix-cyan-dark);
    transition: color .2s ease;
}
a:hover {
    color: var(--fix-green);
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    background: var(--fix-white);
}

.site-branding img.custom-logo {
    max-height: 60px;
    width: auto;
}

/* ==========================================================================
   Boutons — Primary / Secondary / CTA
   ========================================================================== */

.button,
button,
input[type="submit"],
.wp-block-button__link,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.woocommerce .single_add_to_cart_button {
    background: linear-gradient(135deg, var(--fix-green) 0%, var(--fix-cyan) 100%) !important;
    color: var(--fix-white) !important;
    border: none !important;
    border-radius: 999px !important;
    padding: 14px 32px !important;
    font-weight: 600 !important;
    letter-spacing: 0.01em !important;
    box-shadow: var(--fix-shadow) !important;
    transition: transform .2s ease, box-shadow .2s ease !important;
    text-transform: none !important;
}

.button:hover,
button:hover,
input[type="submit"]:hover,
.wp-block-button__link:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce .single_add_to_cart_button:hover {
    transform: translateY(-2px);
    box-shadow: var(--fix-shadow-hover) !important;
    color: var(--fix-white) !important;
}

.fixeco-btn-orange,
.fixeco-btn-orange a,
.wp-block-button.is-style-orange .wp-block-button__link {
    background: linear-gradient(135deg, var(--fix-orange) 0%, var(--fix-orange-dark) 100%) !important;
    color: var(--fix-white) !important;
    box-shadow: 0 4px 20px rgba(249, 115, 22, 0.25) !important;
}

.fixeco-btn-outline .wp-block-button__link {
    background: transparent !important;
    color: var(--fix-green) !important;
    border: 2px solid var(--fix-green) !important;
    box-shadow: none !important;
}

/* ==========================================================================
   Hero
   ========================================================================== */

.fixeco-hero {
    background: linear-gradient(135deg, var(--fix-black) 0%, var(--fix-gray-900) 100%);
    color: var(--fix-white);
    padding: 100px 20px;
    position: relative;
    overflow: hidden;
}

.fixeco-hero::before {
    content: "";
    position: absolute;
    top: -20%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.fixeco-hero::after {
    content: "";
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.12) 0%, transparent 70%);
    pointer-events: none;
}

.fixeco-hero h1 {
    color: var(--fix-white);
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1rem;
    position: relative;
    z-index: 2;
}

.fixeco-hero h1 .accent-green { color: var(--fix-green); }
.fixeco-hero h1 .accent-cyan { color: var(--fix-cyan); }
.fixeco-hero h1 .accent-orange { color: var(--fix-orange); }

.fixeco-hero p.lead {
    font-size: 1.25rem;
    color: var(--fix-gray-300);
    max-width: 700px;
    position: relative;
    z-index: 2;
}

/* ==========================================================================
   Cards Feature
   ========================================================================== */

.fixeco-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    margin: 40px 0;
}

.fixeco-feature-card {
    background: var(--fix-white);
    border-radius: var(--fix-radius);
    padding: 32px 24px;
    border: 1px solid var(--fix-gray-100);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: transform .3s ease, box-shadow .3s ease;
    text-align: left;
}

.fixeco-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(16, 185, 129, 0.12);
    border-color: var(--fix-green);
}

.fixeco-feature-card .icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--fix-green) 0%, var(--fix-cyan) 100%);
    color: var(--fix-white);
    font-size: 24px;
    margin-bottom: 16px;
}

.fixeco-feature-card h3 {
    font-size: 1.15rem;
    margin: 0 0 8px;
}

.fixeco-feature-card p {
    color: var(--fix-gray-500);
    margin: 0;
    font-size: 0.95rem;
}

/* ==========================================================================
   Trust badges
   ========================================================================== */

.fixeco-trust {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px 32px;
    padding: 24px 0;
    background: var(--fix-gray-100);
    border-radius: var(--fix-radius);
    margin: 30px 0;
}

.fixeco-trust-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: var(--fix-gray-700);
    font-size: 0.95rem;
}

.fixeco-trust-item .check {
    color: var(--fix-green);
    font-size: 1.2rem;
}

/* ==========================================================================
   WooCommerce customization
   ========================================================================== */

.woocommerce ul.products li.product {
    background: var(--fix-white);
    border-radius: var(--fix-radius);
    padding: 16px;
    border: 1px solid var(--fix-gray-100);
    transition: transform .2s ease, box-shadow .2s ease;
    text-align: center;
}

.woocommerce ul.products li.product:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(6, 182, 212, 0.15);
    border-color: var(--fix-cyan);
}

.woocommerce ul.products li.product .price {
    color: var(--fix-green-dark);
    font-weight: 800;
    font-size: 1.35rem;
}

.woocommerce ul.products li.product .price del {
    color: var(--fix-gray-500);
    font-weight: 500;
    font-size: 0.9rem;
    opacity: 0.7;
}

.woocommerce span.onsale {
    background: var(--fix-orange) !important;
    color: var(--fix-white) !important;
    border-radius: 999px !important;
    font-weight: 700;
    padding: 6px 14px !important;
    min-height: auto !important;
    min-width: auto !important;
    line-height: 1 !important;
}

/* Grade badges custom for reconditioned computers */
.fixeco-grade {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.fixeco-grade-excellent { background: var(--fix-green); color: var(--fix-white); }
.fixeco-grade-tresbon { background: var(--fix-cyan); color: var(--fix-white); }
.fixeco-grade-bon { background: var(--fix-orange); color: var(--fix-white); }

/* ==========================================================================
   Chat flottant (n8n) — même page
   ========================================================================== */

.fixeco-chat-root {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    font-family: Inter, system-ui, sans-serif;
}

.fixeco-chat-launcher {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    background: linear-gradient(135deg, var(--fix-green, #10B981) 0%, var(--fix-cyan, #06B6D4) 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.45);
    transition: transform .25s ease;
    animation: fixeco-pulse 2.5s infinite;
}

.fixeco-chat-launcher:hover {
    transform: scale(1.08);
}

@keyframes fixeco-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.55); }
    70%  { box-shadow: 0 0 0 18px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.fixeco-chat-panel {
    position: absolute;
    bottom: 72px;
    right: 0;
    width: min(380px, calc(100vw - 32px));
    height: min(520px, calc(100vh - 120px));
    background: #0F172A;
    color: #F1F5F9;
    border: 1px solid #334155;
    border-radius: 16px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.fixeco-chat-panel[hidden] {
    display: none !important;
}

.fixeco-chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    background: linear-gradient(135deg, #059669 0%, #0E7490 100%);
    color: #fff;
}

.fixeco-chat-status {
    display: block;
    font-size: 0.75rem;
    opacity: 0.9;
    font-weight: 400;
}

.fixeco-chat-close {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
}

.fixeco-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #0B1220;
}

.fixeco-chat-bubble {
    max-width: 88%;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 0.92rem;
    line-height: 1.45;
    white-space: pre-wrap;
    word-break: break-word;
}

.fixeco-chat-bubble.bot {
    align-self: flex-start;
    background: #1E293B;
    border: 1px solid #334155;
    color: #E2E8F0;
}

.fixeco-chat-bubble.user {
    align-self: flex-end;
    background: #059669;
    color: #fff;
}

.fixeco-chat-typing {
    opacity: 0.75;
    font-style: italic;
}

.fixeco-chat-form {
    display: flex;
    gap: 8px;
    padding: 10px;
    border-top: 1px solid #334155;
    background: #0F172A;
}

.fixeco-chat-form input {
    flex: 1;
    border-radius: 999px;
    border: 1px solid #475569;
    background: #1E293B;
    color: #F8FAFC;
    padding: 10px 14px;
    font-size: 0.95rem;
}

.fixeco-chat-form input:focus {
    outline: 2px solid #10B981;
    outline-offset: 1px;
}

.fixeco-chat-form button {
    border: none;
    border-radius: 999px;
    background: #10B981;
    color: #fff;
    font-weight: 600;
    padding: 10px 14px;
    cursor: pointer;
}

.fixeco-chat-form button:disabled,
.fixeco-chat-form input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.fixeco-chat-footer {
    padding: 8px 12px 10px;
    font-size: 0.78rem;
    text-align: center;
    border-top: 1px solid #1E293B;
    background: #0B1220;
}

.fixeco-chat-footer a {
    color: #34D399;
    text-decoration: none;
    font-weight: 600;
}

.fixeco-chat-footer a:hover {
    text-decoration: underline;
}

.fixeco-chat-warn {
    color: #FCD34D;
}

/* Legacy class keep for compat if used elsewhere */
.fixeco-whatsapp {
    display: none;
}

/* ==========================================================================
   Lead magnet section (Systeme.io)
   ========================================================================== */

.fixeco-lead-magnet {
    background: linear-gradient(135deg, var(--fix-green) 0%, var(--fix-cyan) 100%);
    color: var(--fix-white);
    padding: 60px 30px;
    border-radius: 20px;
    text-align: center;
    margin: 50px auto;
    max-width: 900px;
    position: relative;
    overflow: hidden;
}

.fixeco-lead-magnet h2 {
    color: var(--fix-white);
    font-size: 2rem;
    margin-bottom: 12px;
}

.fixeco-lead-magnet p {
    font-size: 1.1rem;
    opacity: 0.95;
    max-width: 600px;
    margin: 0 auto 24px;
}

.fixeco-lead-magnet input[type="email"],
.fixeco-lead-magnet input[type="text"] {
    padding: 14px 20px;
    border-radius: 999px;
    border: none;
    font-size: 1rem;
    min-width: 260px;
    margin: 6px;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
    background: var(--fix-black) !important;
    color: var(--fix-gray-300) !important;
}

.site-footer a { color: var(--fix-gray-300); }
.site-footer a:hover { color: var(--fix-green); }
.site-footer h1, .site-footer h2, .site-footer h3, .site-footer h4 { color: var(--fix-white); }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 768px) {
    .fixeco-hero { padding: 60px 20px; }
    .fixeco-chat-root { bottom: 18px; right: 18px; }
    .fixeco-chat-launcher { width: 54px; height: 54px; }
    .fixeco-chat-panel { height: min(70vh, 480px); bottom: 66px; }
    .fixeco-lead-magnet { padding: 40px 20px; }
}
