/* ========================================
   DIGIFLEX - Custom Styles
   ======================================== */

/* ===== VARIABLES CSS ===== */
:root {
    --primary-color: #365ca3;
    --primary-dark: #2aa3b4;
    --secondary-color: #64748b;
    --accent-color: #0ea5e9;
    --success-color: #10b981;
    --warning-color: #ee9726;
    --danger-color: #da4839;
    --light-color: #f8fafc;
    --dark-color: #1e293b;
    --white: #ffffff;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    
    /* Typography */
    --font-primary: 'Poppins', sans-serif;
    --font-secondary: 'Open Sans', sans-serif;
    --font-mono: 'Roboto', sans-serif;
    
    /* Spacing */
    --section-padding: 80px 0;
    --container-padding: 0 15px;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    
    /* Border radius */
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --border-radius-xl: 16px;
    
    /* Transitions */
    --transition: all 0.3s ease;
    --transition-fast: all 0.2s ease;
}

/* ===== RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-secondary);
    font-size: 16px;
    line-height: 1.6;
    color: var(--gray-700);
    background-color: var(--white);
    overflow-x: hidden;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 600;
    line-height: 1.3;
    color: var(--gray-800);
    margin-bottom: 1rem;
    position: relative;
}

.hero-section h1 {
    background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 50%, #ffffff 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: textShine 3s ease-in-out infinite;
    text-shadow: 0 0 30px rgba(37, 99, 235, 0.3);
}

@keyframes textShine {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.display-1, .display-2, .display-3, .display-4, .display-5, .display-6 {
    font-family: var(--font-primary);
    font-weight: 700;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

.lead {
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--gray-600);
}

.text-primary {
    color: var(--primary-color) !important;
}

.text-secondary {
    color: var(--secondary-color) !important;
}

/* ===== NAVIGATION ===== */
.navbar {
    padding: 1rem 0;
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color) !important;
    text-decoration: none;
}

.navbar-nav .nav-link {
    font-weight: 500;
    color: var(--gray-700) !important;
    padding: 0.5rem 1rem !important;
    transition: var(--transition);
    position: relative;
}

.navbar-nav .nav-link:hover {
    color: var(--primary-color) !important;
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition);
    transform: translateX(-50%);
}

.navbar-nav .nav-link:hover::after {
    width: 80%;
}

.navbar-toggler {
    border: 2px solid var(--primary-color);
    padding: 0.5rem;
    border-radius: var(--border-radius);
    background-color: var(--white);
    color: var(--primary-color);
    transition: var(--transition);
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
    border-color: var(--primary-dark);
}

.navbar-toggler:hover {
    background-color: var(--primary-color);
    color: var(--white);
    border-color: var(--primary-color);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%2837, 99, 235, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    width: 1.5em;
    height: 1.5em;
}

.navbar-toggler:hover .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ===== BUTTONS ===== */
.btn {
    font-family: var(--font-primary);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    font-size: 0.9rem;
    position: relative;
    z-index: 10;
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border: none;
    color: var(--white);
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 4px 15px rgba(37, 99, 235, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 
        0 8px 25px rgba(37, 99, 235, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-outline-primary {
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    background-color: transparent;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-outline-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(37, 99, 235, 0.1), transparent);
    transition: left 0.5s;
}

.btn-outline-primary:hover::before {
    left: 100%;
}

.btn-outline-primary:hover {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-color: var(--primary-color);
    color: var(--white);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 
        0 8px 25px rgba(37, 99, 235, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
}

/* ===== HERO SECTION ===== */
.hero-section {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 25%, #334155 50%, #475569 75%, #64748b 100%);
    padding-top: 120px;
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    z-index: 1;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(37, 99, 235, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(14, 165, 233, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(59, 130, 246, 0.2) 0%, transparent 50%);
    animation: gradientShift 8s ease-in-out infinite;
}

.hero-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="circuit" width="20" height="20" patternUnits="userSpaceOnUse"><path d="M10,0 L10,20 M0,10 L20,10 M5,5 L15,15 M15,5 L5,15" fill="none" stroke="%232563eb" stroke-width="0.5" opacity="0.3"/></pattern></defs><rect width="100" height="100" fill="url(%23circuit)"/></svg>');
    opacity: 0.1;
    animation: circuitFlow 20s linear infinite;
}

@keyframes gradientShift {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

@keyframes circuitFlow {
    0% { transform: translateX(0) translateY(0); }
    100% { transform: translateX(20px) translateY(20px); }
}

.hero-image {
    position: relative;
    z-index: 2;
}

.container {
    position: relative;
    z-index: 2;
}

/* Ensure interactive elements are clickable */
.btn, .nav-link, a, button, input, select, textarea {
    position: relative;
    z-index: 10;
    pointer-events: auto;
}

/* Ensure cards are clickable */
.service-card, .offer-card, .card {
    position: relative;
    z-index: 5;
}

.hero-image img {
    max-width: 100%;
    height: 450px;
    border-radius: var(--border-radius-xl);
    box-shadow: 
        0 20px 40px rgba(37, 99, 235, 0.3),
        0 0 0 1px rgba(37, 99, 235, 0.1),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.hero-image::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: var(--border-radius-xl);
    z-index: -1;
    animation: borderGlow 3s linear infinite;
    background-size: 400% 400%;
}

@keyframes borderGlow {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* ===== SECTIONS ===== */
section {
    padding: var(--section-padding);
    position: relative;
    z-index: 1;
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(37, 99, 235, 0.02) 50%, transparent 100%);
    pointer-events: none;
}

.partners-section {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    position: relative;
    overflow: hidden;
}

.partners-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="dots" width="10" height="10" patternUnits="userSpaceOnUse"><circle cx="5" cy="5" r="1" fill="%23e2e8f0"/></pattern></defs><rect width="100" height="100" fill="url(%23dots)"/></svg>');
    opacity: 0.3;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.partners-section img {
    max-height: 60px;
    filter: grayscale(100%);
    transition: var(--transition);
}

.partners-section img:hover {
    filter: grayscale(0%);
    transform: scale(1.1);
}

.about-section {
    background-color: var(--white);
}

.about-image img {
    max-width: 100%;
    height: 500px;
    border-radius: var(--border-radius-lg);
}

.values-section {
    background-color: var(--gray-100);
}

/* ===== CARDS ===== */
.card {
    border: none;
    border-radius: var(--border-radius-lg);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.card-body {
    padding: 2rem;
}

/* ===== SERVICE CARDS ===== */
.service-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    box-shadow: 
        0 10px 30px rgba(37, 99, 235, 0.1),
        0 0 0 1px rgba(37, 99, 235, 0.05);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    height: 100%;
    text-align: center;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(37, 99, 235, 0.1);
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(37, 99, 235, 0.1), transparent);
    transition: left 0.5s;
}

.service-card:hover::before {
    left: 100%;
}

.service-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 
        0 25px 50px rgba(37, 99, 235, 0.2),
        0 0 0 1px rgba(37, 99, 235, 0.1);
    border-color: rgba(37, 99, 235, 0.2);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 10px 20px rgba(37, 99, 235, 0.3),
        inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.service-icon::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.3), transparent);
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

.service-icon i {
    font-size: 2rem;
    color: var(--white);
    position: relative;
    z-index: 2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.service-card:hover .service-icon {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 
        0 15px 30px rgba(37, 99, 235, 0.4),
        inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.service-card h5 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--gray-600);
    margin-bottom: 1.5rem;
}

.service-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.service-features li {
    padding: 0.5rem 0;
    color: var(--gray-600);
    position: relative;
    padding-left: 1.5rem;
}

.service-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

/* ===== OFFER CARDS ===== */
.offer-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border-radius: var(--border-radius-lg);
    box-shadow: 
        0 15px 35px rgba(37, 99, 235, 0.1),
        0 0 0 1px rgba(37, 99, 235, 0.05);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    height: 100%;
    border: 1px solid rgba(37, 99, 235, 0.1);
}

.offer-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #2563eb, #0ea5e9, #3b82f6, #2563eb);
    background-size: 400% 400%;
    animation: gradientMove 3s ease infinite;
}

@keyframes gradientMove {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.offer-card.featured {
    border: 2px solid var(--primary-color);
    transform: scale(1.05);
    box-shadow: 
        0 20px 40px rgba(37, 99, 235, 0.2),
        0 0 0 1px rgba(37, 99, 235, 0.1);
}

.offer-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 
        0 30px 60px rgba(37, 99, 235, 0.25),
        0 0 0 1px rgba(37, 99, 235, 0.15);
}

.offer-card.featured:hover {
    transform: scale(1.05) translateY(-15px) scale(1.02);
    box-shadow: 
        0 35px 70px rgba(37, 99, 235, 0.3),
        0 0 0 1px rgba(37, 99, 235, 0.2);
}

.offer-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--primary-color);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.offer-header {
    padding: 2rem 2rem 1rem;
    text-align: center;
    background: linear-gradient(135deg, var(--gray-100), var(--white));
}

.offer-header h4 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 0.5rem;
}

.offer-price {
    font-size: 1.2rem;
    color: var(--primary-color);
    font-weight: 600;
}

.offer-body {
    padding: 1rem 2rem 2rem;
}

.offer-description {
    color: var(--gray-600);
    margin-bottom: 1.5rem;
    text-align: center;
}

.offer-features {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem;
}

.offer-features li {
    padding: 0.75rem 0;
    color: var(--gray-700);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.offer-features li i {
    color: var(--success-color);
    font-size: 1.1rem;
}

/* ===== TARGET SECTION ===== */
.target-section {
    background-color: var(--white);
}

.target-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 0;
    font-weight: 500;
    color: var(--gray-700);
    transition: var(--transition);
}

.target-item:hover {
    color: var(--primary-color);
    transform: translateX(5px);
}

/* ===== CONTACT SECTION ===== */
.contact-section {
    background-color: var(--gray-100);
}

.contact-form {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
}

.form-control, .form-select {
    border: 2px solid var(--gray-200);
    border-radius: var(--border-radius);
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.1);
}

.form-label {
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

.contact-info {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    height: fit-content;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.contact-item i {
    font-size: 1.2rem;
    margin-top: 0.25rem;
}

.contact-item div {
    margin-left: 1rem;
}

.social-links {
    margin-top: 2rem;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    text-decoration: none;
    transition: var(--transition);
    font-size: 1.2rem;
}

.social-link:hover {
    background-color: var(--primary-dark);
    color: var(--white);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* ===== FOOTER ===== */
.footer {
    background-color: var(--gray-900);
}

.footer-brand h5 {
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer a {
    color: var(--gray-400);
    text-decoration: none;
    transition: var(--transition);
}

.footer a:hover {
    color: var(--primary-color);
}

/* ===== FLOATING PARTICLES ===== */
.floating-particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(37, 99, 235, 0.6);
    border-radius: 50%;
    animation: floatParticle 20s infinite linear;
}

.particle:nth-child(1) {
    left: 10%;
    animation-delay: 0s;
    animation-duration: 15s;
}

.particle:nth-child(2) {
    left: 20%;
    animation-delay: 2s;
    animation-duration: 18s;
}

.particle:nth-child(3) {
    left: 30%;
    animation-delay: 4s;
    animation-duration: 12s;
}

.particle:nth-child(4) {
    left: 70%;
    animation-delay: 6s;
    animation-duration: 16s;
}

.particle:nth-child(5) {
    left: 80%;
    animation-delay: 8s;
    animation-duration: 14s;
}

.particle:nth-child(6) {
    left: 90%;
    animation-delay: 10s;
    animation-duration: 20s;
}

@keyframes floatParticle {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100px) scale(1);
        opacity: 0;
    }
}

/* ===== WHATSAPP FLOAT ===== */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
}

.whatsapp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background-color: #25d366;
    color: var(--white);
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.2rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    animation: pulse 2s infinite;
}

.whatsapp-btn:hover {
    color: var(--white);
    transform: scale(1.1);
    box-shadow: var(--shadow-xl);
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

/* ===== CHAT MODULE ===== */
.chat-module {
    position: fixed;
    bottom: 30px;
    left: 30px;
    z-index: 1000;
}

.chat-toggle {
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    position: relative;
}

.chat-toggle:hover {
    background-color: var(--primary-dark);
    transform: scale(1.1);
}

.chat-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: var(--danger-color);
    color: var(--white);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
}

.chat-window {
    position: absolute;
    bottom: 80px;
    left: 0;
    width: 350px;
    height: 400px;
    background-color: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-xl);
    display: none;
    flex-direction: column;
}

.chat-window.show {
    display: flex;
}

.chat-header {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 1rem;
    border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.chat-header h6 {
    margin: 0;
    font-weight: 600;
}

.btn-close {
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-body {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
}

.chat-message {
    margin-bottom: 1rem;
}

.chat-message.bot {
    text-align: left;
}

.chat-message.user {
    text-align: right;
}

.chat-message p {
    background-color: var(--gray-100);
    padding: 0.75rem 1rem;
    border-radius: var(--border-radius);
    margin: 0 0 0.25rem;
    display: inline-block;
    max-width: 80%;
}

.chat-message.user p {
    background-color: var(--primary-color);
    color: var(--white);
}

.chat-message small {
    color: var(--gray-500);
    font-size: 0.75rem;
}

.chat-input {
    padding: 1rem;
    border-top: 1px solid var(--gray-200);
    display: flex;
    gap: 0.5rem;
}

.chat-input .form-control {
    flex: 1;
    border: 1px solid var(--gray-300);
    border-radius: var(--border-radius);
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
}

/* ===== PAYMENT SIMULATOR ===== */
.calculation-result {
    background-color: var(--gray-100);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--gray-200);
}

.result-item:last-child {
    border-bottom: none;
}

.result-item.total {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-color);
    border-top: 2px solid var(--primary-color);
    margin-top: 0.5rem;
    padding-top: 1rem;
}

.result-item.highlight {
    background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
    border-radius: var(--border-radius);
    padding: 1rem;
    margin-top: 1rem;
    text-align: center;
    border: 2px solid var(--success-color);
    animation: pulse-success 2s infinite;
}

@keyframes pulse-success {
    0% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

/* Badge temps réel */
.badge.bg-success {
    animation: pulse-badge 1.5s infinite;
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
}

@keyframes pulse-badge {
    0% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
    100% {
        opacity: 1;
    }
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1199.98px) {
    .section-title {
        font-size: 2.25rem;
    }
    
    .offer-card.featured {
        transform: none;
    }
    
    .offer-card.featured:hover {
        transform: translateY(-10px);
    }
}

@media (max-width: 991.98px) {
    .hero-section {
        padding-top: 100px;
        text-align: center;
    }
    
    .hero-section::before {
        display: none;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .navbar-nav {
        text-align: center;
        padding-top: 1rem;
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem !important;
    }
    
    .navbar-toggler {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: relative;
        z-index: 1050;
    }
    
    .navbar-toggler-icon {
        display: block !important;
    }
}

@media (max-width: 767.98px) {
    :root {
        --section-padding: 60px 0;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .hero-section {
        padding-top: 80px;
    }
    
    .display-4 {
        font-size: 2.5rem;
    }
    
    .btn-lg {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }
    
    .service-card,
    .contact-form,
    .contact-info {
        padding: 1.5rem;
    }
    
    .offer-card .offer-header,
    .offer-card .offer-body {
        padding: 1.5rem;
    }
    
    .chat-window {
        width: 300px;
        height: 350px;
    }
    
    .whatsapp-float,
    .chat-module {
        bottom: 20px;
    }
    
    .whatsapp-float {
        right: 20px;
    }
    
    .chat-module {
        left: 20px;
    }
    
    .whatsapp-btn,
    .chat-toggle {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .navbar-toggler {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        border: 2px solid var(--primary-color);
        background-color: var(--white);
        padding: 0.4rem 0.6rem;
        margin-left: auto;
    }
}

@media (max-width: 575.98px) {
    .section-title {
        font-size: 1.5rem;
    }
    
    .display-4 {
        font-size: 2rem;
    }
    
    .lead {
        font-size: 1.1rem;
    }
    
    .hero-image {
        margin-top: 2rem;
    }
    
    .d-flex.gap-3 {
        flex-direction: column;
        gap: 1rem !important;
    }
    
    .d-flex.gap-3 .btn {
        width: 100%;
    }
    
    .chat-window {
        width: calc(100vw - 40px);
        left: -20px;
    }
    
    .navbar-toggler {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        border: 2px solid var(--primary-color);
        background-color: var(--white);
        padding: 0.3rem 0.5rem;
        margin-left: auto;
        min-width: 44px;
        min-height: 44px;
    }
    
    .navbar-toggler-icon {
        width: 1.2em;
        height: 1.2em;
    }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease-out;
}

.animate-fadeInLeft {
    animation: fadeInLeft 0.6s ease-out;
}

.animate-fadeInRight {
    animation: fadeInRight 0.6s ease-out;
}

/* ===== UTILITIES ===== */
.opacity-75 {
    opacity: 0.75 !important;
}

.text-decoration-none {
    text-decoration: none !important;
}

.cursor-pointer {
    cursor: pointer;
}

.shadow-sm {
    box-shadow: var(--shadow-sm) !important;
}

.shadow {
    box-shadow: var(--shadow) !important;
}

.shadow-lg {
    box-shadow: var(--shadow-lg) !important;
}

.shadow-xl {
    box-shadow: var(--shadow-xl) !important;
}

/* ===== LOADING STATES ===== */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--gray-300);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== ACCESSIBILITY ===== */
.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;
}

/* Focus styles for better accessibility */
.btn:focus,
.form-control:focus,
.form-select:focus,
.nav-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* ===== PRINT STYLES ===== */
@media print {
    .navbar,
    .whatsapp-float,
    .chat-module,
    .btn {
        display: none !important;
    }
    
    .hero-section {
        padding-top: 0;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.4;
    }
    
    .section-title {
        font-size: 18pt;
    }
}
