:root {
    --primary-color: #1e3a8a;
    /* Azul marino del logo */
    --secondary-color: #b91c1c;
    /* Rojo intenso del logo */
    --accent-color: #0369a1;
    /* Azul claro complementario */
    --text-dark: #1e293b;
    --text-light: #f1f5f9;
    --text-muted: #64748b;
    --white: #ffffff;
    --gray-light: #f3f4f6;
    --gray-medium: #e5e7eb;
    --border-color: #e2e8f0;
    --transition: all 0.2s ease-in-out;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--white);
    color: var(--text-dark);
    line-height: 1.5;
}

/* --- Global Image Loading Styles --- */
img {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

#pageLoader img {
    opacity: 1 !important;
}

img.loaded {
    opacity: 1;
}

.image-skeleton {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* Responsive container */
@media (max-width: 1280px) {
    .container {
        max-width: 100%;
        padding: 0 20px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }
}

/* --- Top Bar --- */
.top-bar {
    background-color: var(--gray-light);
    color: var(--text-dark);
    font-size: clamp(0.8rem, 2vw, 0.85rem); /* Responsive font-size */
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
}

.top-links a {
    margin-left: 20px;
    font-weight: 600;
    color: var(--primary-color);
}

/* --- Main Header --- */
.main-header {
    background: rgb(229, 231, 235);
    padding: 15px 0;
    color: var(--text-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: relative;
}

.main-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(to right, 
        var(--secondary-color) 0%, 
        var(--secondary-color) 50%, 
        transparent 50%);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
}

.logo h1 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 800;
    letter-spacing: -1px;
    white-space: nowrap;
}

.logo img {
    height: auto;
    max-height: 50px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}

@media (max-width: 768px) {
    .logo img {
        max-height: 40px;
    }
}

@media (max-width: 480px) {
    .logo img {
        max-height: 35px;
    }
}

.logo .highlight {
    color: var(--secondary-color);
    /* Red as highlight */
    background: var(--white);
    padding: 0 5px;
    border-radius: 4px;
}

/* Search Bar */
.search-bar-container {
    position: relative;
    flex-grow: 1;
    max-width: 600px;
    width: 100%;
}

@media (max-width: 768px) {
    .search-bar-container {
        max-width: 100%;
    }
}

.search-form {
    position: relative;
    display: flex;
    background: var(--white);
    border-radius: 4px;
    overflow: visible;
}

.search-form input {
    flex: 1;
    padding: 12px 15px;
    border: none;
    outline: none;
    font-size: 0.95rem;
}

.search-form button {
    background: var(--white);
    border: none;
    padding: 0 20px;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.search-form button:hover {
    color: var(--primary-color);
}

/* Autocomplete Styles */
.autocomplete-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--border-color);
    border-top: none;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    max-height: 450px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    margin-top: 2px;
}

.autocomplete-results.show {
    display: block;
}

.autocomplete-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    cursor: pointer;
    transition: background-color 0.15s ease;
    border-bottom: 1px solid #f0f0f0;
}

.autocomplete-item:last-child {
    border-bottom: none;
}

.autocomplete-item:hover,
.autocomplete-item.active {
    background-color: #f8f9fa;
}

.autocomplete-img-container {
    position: relative;
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    border-radius: 6px;
    overflow: hidden; /* Crítico para ribbon */
    border: 1px solid var(--border-color);
}

.autocomplete-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.no-image-box {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f5f5f5 0%, #e0e0e0 100%);
    color: #999;
    font-size: 0.7rem;
    text-align: center;
    padding: 5px;
    font-weight: 500;
}

.out-of-stock-ribbon {
    position: absolute;
    top: 5px;
    right: -25px;
    background: var(--secondary-color);
    color: white;
    padding: 2px 30px;
    font-size: 0.65rem;
    font-weight: 700;
    transform: rotate(45deg);
    text-transform: uppercase;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    z-index: 10;
}

.autocomplete-info {
    flex: 1;
    min-width: 0;
}

.autocomplete-codigo {
    font-size: 0.75rem;
    color: var(--primary-color);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 3px;
}

.autocomplete-codigo i {
    font-size: 0.7rem;
}

.autocomplete-name {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 4px;
    font-size: 0.95rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.autocomplete-marca {
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 5px;
}

.autocomplete-marca i {
    font-size: 0.75rem;
}

.autocomplete-loading,
.autocomplete-loading-more {
    padding: 15px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.autocomplete-loading-more {
    padding: 10px;
    background: #f9f9f9;
    border-top: 1px solid var(--border-color);
}

.autocomplete-info-more {
    padding: 10px 15px;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    background: #f5f8ff;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.autocomplete-info-more i {
    font-size: 0.75rem;
}

.autocomplete-no-results {
    padding: 20px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Scrollbar para el autocomplete */
.autocomplete-results::-webkit-scrollbar {
    width: 8px;
}

.autocomplete-results::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 0 0 8px 0;
}

.autocomplete-results::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.autocomplete-results::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Header Actions */
.header-actions {
    display: flex;
    gap: 20px;
}

.action-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-dark);
    font-size: 0.9rem;
    font-weight: 600;
    transition: var(--transition);
}

.action-item i {
    font-size: 1.5rem;
}

.action-item:hover {
    color: var(--primary-color);
}

/* --- Vehicle Bar --- */
.vehicle-bar {
    background-color: #e5e7eb;
    /* Light Gray */
    padding: 12px 0;
    border-bottom: 1px solid #d1d5db;
}

.vehicle-bar-content {
    display: flex;
    align-items: center;
    gap: 15px;
    justify-content: center;
    /* Centered style */
}

.vehicle-bar i {
    font-size: 1.5rem;
    color: var(--text-muted);
}

.btn-add-vehicle {
    background-color: var(--secondary-color);
    color: var(--white);
    border: none;
    padding: 8px 20px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
}

.btn-add-vehicle:hover {
    background-color: #8f0914;
    /* Darker Red */
}

/* --- Category Nav --- */
.category-nav {
    background-color: var(--white);
    border-bottom: 2px solid var(--secondary-color);
    box-shadow: 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.cat-links {
    display: flex;
    gap: 30px;
    padding: 15px 0;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    overflow-x: auto;
}

.cat-links a {
    color: var(--text-dark);
    position: relative;
    padding-bottom: 5px;
}

.cat-links a:hover,
.cat-links a.active {
    color: var(--secondary-color);
}

.cat-links a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--secondary-color);
    border-radius: 2px;
}

/* --- Hero Section --- */
.hero-promo {
    background-color: #f8fafc;
    padding: 2rem 0;
}

.hero-banner {
    background: linear-gradient(to right, rgba(21, 59, 148, 0.9), rgba(21, 59, 148, 0.7)), url('https://source.unsplash.com/random/1200x400/?car,road');
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    padding: 3rem;
    color: var(--white);
    display: flex;
    align-items: center;
    min-height: 300px;
}

.hero-text {
    max-width: 500px;
}

.hero-text h2 {
    font-size: clamp(1.75rem, 5vw, 3rem);
    font-weight: 800;
    color: var(--secondary-color);
    /* Red emphasis */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    margin-bottom: 10px;
    line-height: 1.2;
}

.hero-text p {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    margin-bottom: 20px;
    font-weight: 500;
    line-height: 1.5;
}

/* --- Buttons Global --- */
.btn {
    display: inline-block;
    padding: 10px 25px;
    border-radius: 4px;
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-size: 0.9rem;
}

.btn-primary {
    background-color: var(--secondary-color);
    /* Red for CTA in Hero */
    color: var(--white);
}

.btn-primary:hover {
    background-color: #990a16;
    transform: translateY(-2px);
}

/* --- Products Section --- */
.section-title {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--text-dark);
    border-left: 5px solid var(--secondary-color);
    padding-left: 15px;
    margin-top: 3rem;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 20px;
    margin-bottom: 4rem;
}

@media (max-width: 1024px) {
    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        margin-bottom: 2rem;
    }
}

@media (max-width: 360px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
}

.cat-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
}

.cat-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    transform: translateY(-5px);
}

.cat-card img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-bottom: 10px;
    border-radius: 50%;
    background: #f1f5f9;
    padding: 10px;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.cat-card img.loaded {
    opacity: 1;
}

.cat-card span {
    display: block;
    font-weight: 600;
    color: var(--text-dark);
}

/* --- Feature Section --- */
.feature-section {
    display: flex;
    background-color: var(--primary-color);
    color: var(--white);
    margin-top: 4rem;
}

.feature-content {
    flex: 1;
    padding: 4rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.feature-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.feature-image {
    flex: 1;
}

.feature-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Footer --- */
.footer {
    background-color: #0f172a;
    padding: 4rem 0 0;
    color: var(--text-muted);
}

.footer-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-col h3 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.footer-col p {
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
}

.footer-col a {
    color: var(--text-muted);
    transition: var(--transition);
}

.footer-col a:hover {
    color: var(--white);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    font-size: 1.2rem;
}

.footer-bottom {
    background-color: #020617;
    text-align: center;
    padding: 20px;
    font-size: 0.8rem;
    border-top: 1px solid #1e293b;
}

/* --- Responsive --- */

/* Tablets landscape y escritorios pequeños */
@media (max-width: 1024px) {
    .hero-banner {
        padding: 2.5rem;
        min-height: 280px;
    }
    
    .section-title {
        font-size: 1.6rem;
    }
    
    .autocomplete-results {
        max-height: 400px;
    }
}

/* Tablets portrait */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    /* Top Bar */
    .top-bar {
        font-size: 0.75rem;
        padding: 6px 0;
    }

    .top-bar .container {
        justify-content: center;
    }

    /* Header */
    .main-header {
        padding: 10px 0;
    }

    .header-content {
        flex-direction: column;
        gap: 1rem;
        position: relative;
    }

    .logo {
        order: 1;
        text-align: center;
    }

    .search-bar-container {
        order: 3;
        max-width: 100%;
    }

    /* Autocomplete images responsive */
    .autocomplete-img-container {
        width: 50px;
        height: 50px;
    }

    .search-form input {
        padding: 10px 12px;
        font-size: 0.85rem;
    }

    .search-form button {
        padding: 0 15px;
    }

    .header-actions {
        order: 2;
        width: 100%; /* CAMBIO: quitar position absolute */
        justify-content: center; /* Centrar iconos */
        gap: 15px;
        padding: 0.5rem 0; /* Agregar padding */
    }

    .action-item span {
        display: none;
    }

    .action-item i {
        font-size: 1.3rem;
    }

    /* Asegurar touch target mínimo */
    .action-item {
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Vehicle Bar */
    .vehicle-bar {
        padding: 10px 0;
    }

    .vehicle-bar-content {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .vehicle-bar-content p {
        font-size: 0.85rem;
    }

    .btn-add-vehicle {
        width: 100%;
        max-width: 300px;
        padding: 10px 20px;
    }

    /* Category Nav */
    .cat-links {
        gap: 20px;
        padding: 12px 15px; /* Aumentar padding horizontal */
        font-size: 0.8rem;
        justify-content: flex-start;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
        position: relative; /* Para el gradiente */
    }

    /* Gradiente visual para indicar scroll */
    .cat-links::after {
        content: '';
        position: absolute;
        right: 0;
        top: 0;
        bottom: 0;
        width: 30px;
        background: linear-gradient(to right, transparent, rgba(255,255,255,0.9));
        pointer-events: none;
    }

    .cat-links::-webkit-scrollbar {
        height: 3px;
    }

    .cat-links::-webkit-scrollbar-thumb {
        background: var(--primary-color);
        border-radius: 3px;
    }

    .cat-links a {
        white-space: nowrap;
        flex-shrink: 0;
        padding: 8px 12px; /* Aumentar área clickeable */
    }

    /* Hero Section */
    .hero-banner {
        padding: 2rem 1.5rem;
        min-height: 250px;
    }

    /* Sections */
    .section-title {
        font-size: 1.4rem;
        margin-top: 2rem;
        margin-bottom: 1rem;
    }

    /* Category Grid */
    .category-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
        scroll-behavior: smooth;
        padding: 0.5rem 0;
    }

    .cat-card {
        padding: 1.5rem 1rem;
    }

    .cat-card img {
        width: 70px;
        height: 70px;
    }

    .cat-card span {
        font-size: 0.9rem;
    }

    /* Footer */
    .footer-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .footer-col h3 {
        margin-top: 1rem;
    }

    .footer-col ul {
        text-align: center;
    }

    .social-icons {
        justify-content: center;
    }

    /* Autocomplete */
    .autocomplete-results {
        max-height: 300px;
    }

    .autocomplete-item {
        padding: 10px;
        gap: 10px;
    }

    .autocomplete-item img {
        width: 50px;
        height: 50px;
    }

    .autocomplete-item-info h4 {
        font-size: 0.85rem;
    }

    .autocomplete-item-info p {
        font-size: 0.75rem;
    }
}

/* Móviles pequeños y grandes */
@media (max-width: 480px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    
    .cat-card {
        padding: 1rem;
    }
    
    .cat-card img {
        width: 60px;
        height: 60px;
    }
    
    .cat-card span {
        font-size: 0.85rem;
    }

    .hero-banner {
        padding: 1.5rem 1rem;
        min-height: 200px;
    }

    .btn {
        padding: 8px 20px;
        font-size: 0.85rem;
    }
    
    .section-title {
        font-size: 1.25rem;
        margin-top: 1.5rem;
    }
    
    .autocomplete-results {
        max-height: 250px;
    }
    
    .autocomplete-img-container {
        width: 45px;
        height: 45px;
    }

    .autocomplete-item {
        padding: 8px 10px;
        gap: 8px;
    }

    .autocomplete-name {
        font-size: 0.85rem;
    }

    .autocomplete-marca {
        font-size: 0.75rem;
    }

    .autocomplete-codigo {
        font-size: 0.7rem;
    }

    /* Out of stock ribbon ajuste móvil */
    .out-of-stock-ribbon {
        top: 3px;
        right: -28px;
        padding: 1px 25px;
        font-size: 0.6rem;
    }

    .top-bar {
        font-size: 0.8rem; /* Mínimo 12.8px para legibilidad en iOS */
        padding: 6px 0;
    }
}

/* Móviles muy pequeños */
@media (max-width: 360px) {
    .hero-banner {
        padding: 1rem;
        min-height: 180px;
    }
    
    .cat-card {
        padding: 0.75rem;
    }
    
    .cat-card img {
        width: 50px;
        height: 50px;
    }
    
    .cat-card span {
        font-size: 0.75rem;
    }
    
    .btn {
        padding: 6px 16px;
        font-size: 0.8rem;
    }
}

/* ============================================ */
/* BOTONES FLOTANTES */
/* ============================================ */
.floating-buttons {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9998;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.floating-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    position: relative;
}

.floating-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.floating-btn:active {
    transform: translateY(-1px);
}

/* Botón Scroll to Top - Azul */
.btn-scroll-top {
    background: var(--primary-color);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.btn-scroll-top.show {
    opacity: 1;
    visibility: visible;
}

.btn-scroll-top:hover {
    background: #1e40af;
}

/* Botón WhatsApp - Verde */
.btn-whatsapp {
    background: #25D366;
    animation: whatsappPulse 2s infinite;
}

.btn-whatsapp:hover {
    background: #20BA5A;
    animation: none;
}

@keyframes whatsappPulse {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    }
    50% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.7);
    }
}

/* Lista de Vendedores */
.vendedores-list {
    position: fixed;
    bottom: 100px;
    right: 20px;
    width: 320px;
    max-height: 500px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    overflow: hidden;
    animation: slideInUp 0.3s ease;
}

@keyframes slideInUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.vendedores-header {
    background: #25D366;
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.vendedores-header h4 {
    margin: 0;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.vendedores-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.8rem;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s;
}

.vendedores-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.vendedores-body {
    max-height: 400px;
    overflow-y: auto;
}

.vendedor-item {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    gap: 12px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.3s;
    text-decoration: none;
    color: inherit;
}

.vendedor-item:hover {
    background: #f8f9fa;
}

.vendedor-item:last-child {
    border-bottom: none;
}

.vendedor-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), #3b82f6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    flex-shrink: 0;
    overflow: hidden;
}

.vendedor-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.vendedor-info {
    flex: 1;
}

.vendedor-nombre {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 3px;
}

.vendedor-cargo {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 3px;
}

.vendedor-telefono {
    font-size: 0.85rem;
    color: #9ca3af;
}

.vendedor-icon {
    font-size: 1.8rem;
    color: #25D366;
    flex-shrink: 0;
}

/* Responsive para botones flotantes */
@media (max-width: 1024px) {
    .floating-buttons {
        bottom: 18px;
        right: 18px;
    }
}

@media (max-width: 768px) {
    .floating-buttons {
        bottom: 15px;
        right: 15px;
        gap: 12px;
    }
    
    .floating-btn {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
    
    .vendedores-list {
        right: 15px;
        bottom: 85px;
        width: calc(100vw - 30px);
        max-width: 320px;
    }
    
    .vendedores-body {
        max-height: 350px;
    }
}

@media (max-width: 480px) {
    .floating-buttons {
        bottom: 12px;
        right: 12px;
        gap: 10px;
    }
    
    .floating-btn {
        width: 46px;
        height: 46px;
        font-size: 1.2rem;
    }
    
    .vendedores-list {
        right: 12px;
        bottom: 75px;
        width: calc(100vw - 24px);
        max-width: 100%;
    }
    
    .vendedor-item {
        padding: 12px 15px;
    }
    
    .vendedor-avatar {
        width: 45px;
        height: 45px;
        font-size: 1.5rem;
    }
    
    .vendedor-nombre {
        font-size: 0.9rem;
    }
    
    .vendedor-cargo,
    .vendedor-telefono {
        font-size: 0.8rem;
    }
}

@media (max-width: 360px) {
    .floating-buttons {
        bottom: 10px;
        right: 10px;
    }
    
    .floating-btn {
        width: 44px;
        height: 44px;
        font-size: 1.1rem;
    }
    
    .vendedores-list {
        bottom: 70px;
    }
}

/* ============================================ */
/* PAGE LOADER */
/* ============================================ */
/* #pageLoader positioning is handled by inline styles in HTML
   to ensure centering works before CSS loads */

.loader-container {
    position: relative;
    width: 100%;
    max-width: 600px;
    height: 150px;
    overflow: hidden;
}

@media (max-width: 768px) {
    .loader-container {
        max-width: 90%;
        height: 120px;
    }
}

@media (max-width: 480px) {
    .loader-container {
        max-width: 95%;
        height: 100px;
    }
}

#truckLoader {
    position: absolute;
    bottom: 20px;
    left: -150px;
    animation: driveTruck 3s ease-in-out infinite;
}

#truckLoader img {
    width: 120px;
    height: auto;
}

@media (max-width: 768px) {
    #truckLoader img {
        width: 100px;
    }
}

@media (max-width: 480px) {
    #truckLoader {
        bottom: 15px;
        left: -100px;
    }
    
    #truckLoader img {
        width: 70px;
    }
}

.loader-smoke {
    position: absolute;
    bottom: 30px;
    left: -150px;
}

.loader-smoke i {
    color: #d1d5db;
    opacity: 0;
}

#smoke1,
#smoke2,
#smoke3 {
    animation: driveTruck 3s ease-in-out infinite, smoke 3s ease-in-out infinite;
}

#smoke1 {
    animation-delay: 0s;
}

#smoke1 i {
    font-size: 1.5rem;
}

#smoke2 {
    animation-delay: 0.3s;
}

#smoke2 i {
    font-size: 1.2rem;
}

#smoke3 {
    animation-delay: 0.6s;
}

#smoke3 i {
    font-size: 1rem;
}

@media (max-width: 480px) {
    #smoke1 i {
        font-size: 1.2rem;
    }
    
    #smoke2 i {
        font-size: 1rem;
    }
    
    #smoke3 i {
        font-size: 0.8rem;
    }
    
    .loader-smoke {
        bottom: 20px;
        left: -100px;
    }
}

.loader-text {
    margin-top: 1rem;
    color: #1e3a8a;
    font-size: 1.2rem;
    font-weight: 600;
    text-align: center;
    width: 100%;
}

@media (max-width: 480px) {
    .loader-text {
        font-size: 1rem;
        margin-top: 0.75rem;
    }
}

@keyframes driveTruck {
    0% {
        left: -150px;
    }
    100% {
        left: calc(100% + 150px);
    }
}

@keyframes smoke {
    0% {
        opacity: 0;
        transform: translateY(0) scale(0.8);
    }
    20% {
        opacity: 0.6;
    }
    100% {
        opacity: 0;
        transform: translateY(-30px) scale(1.2);
    }
}

/* ===== Utilidades de estados de carga y error ===== */
.loading-center,
.loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    min-height: 200px;
    text-align: center;
    color: #6b7280;
    width: 100%;
    box-sizing: border-box;
}

.loading-spinner {
    font-size: 2.5rem;
    color: #3b82f6;
    margin-bottom: 1rem;
    display: block;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    color: #6b7280;
    margin-top: 0.5rem;
    font-size: 1rem;
}

.error-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    text-align: center;
    color: #ef4444;
}

.logo-img {
    height: 50px;
    width: auto;
    max-width: 100%;
}

@media (max-width: 480px) {
    .logo-img {
        height: 40px;
    }
}

@media (max-width: 360px) {
    .logo-img {
        height: 35px;
    }
}