:root {
    --color-primary: #124B5F;
    --color-secondary: #F26B4F;
    --color-bg: #F7F9FA;
    --color-border: #E7ECEF;
    --color-text: #252B30;
    --color-white: #FFFFFF;
    
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
    
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-xxl: 5rem;
    
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-pill: 50px;
    
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    --shadow-float: 0 8px 30px rgba(0,0,0,0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease, background-color 0.2s ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

ul {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

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

h1 { font-size: 2.5rem; letter-spacing: -0.02em; }
h2 { font-size: 2rem; letter-spacing: -0.01em; }
h3 { font-size: 1.5rem; }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--radius-pill);
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

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

.btn-primary:hover {
    background-color: #e05a3f;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(242, 107, 79, 0.3);
}

.btn-outline {
    background-color: transparent;
    color: var(--color-primary);
    border: 1.5px solid var(--color-primary);
}

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

.btn-block {
    width: 100%;
}

/* Header & Navigation */
.logo-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 90;
    pointer-events: none;
}

.relative-container {
    position: relative;
}

.absolute-logo {
    position: absolute;
    top: 15px;
    left: var(--spacing-md);
    pointer-events: auto;
}

.absolute-logo img {
    width: 150px;
    height: 150px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.absolute-logo:hover img {
    transform: scale(1.05);
}

.site-header {
    background-color: transparent;
    position: sticky;
    top: 15px;
    z-index: 100;
    padding: 0;
    pointer-events: none; /* Permite clicks en el área vacía hacia el logo/hero */
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.header-right {
    pointer-events: auto; /* Reactiva clicks para el menú/acciones */
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-pill);
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

/* Clase dinámica agregada por JS al hacer scroll */
.site-header.scrolled .header-right {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    border: 1px solid rgba(231, 236, 239, 0.5);
    padding: 0.5rem 1.5rem;
}

.main-nav ul {
    display: flex;
    gap: var(--spacing-lg);
}

.main-nav a {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--color-text);
    position: relative;
    padding-bottom: 4px;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-secondary);
    transition: width 0.3s ease;
}

.main-nav a:hover {
    color: var(--color-primary);
}

.main-nav a:hover::after {
    width: 100%;
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #888;
}

.search-input {
    border: none;
    outline: none;
    font-family: inherit;
    font-size: 0.9rem;
    width: 120px;
    transition: width 0.3s ease;
    background: transparent;
}

.search-input:focus {
    width: 200px;
}

.nav-divider {
    width: 1px;
    height: 24px;
    background-color: var(--color-border);
}

.action-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    transition: all 0.2s ease;
    position: relative;
}

.action-btn:hover {
    background-color: var(--color-bg);
    color: var(--color-secondary);
}

.cart-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background-color: var(--color-secondary);
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid var(--color-white);
}

/* User Dropdown */
.user-menu-wrapper {
    position: relative;
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 15px);
    right: -10px;
    background: var(--color-white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    width: 240px;
    padding: var(--spacing-md);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 100;
    border: 1px solid var(--color-border);
}

.user-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown .user-info {
    padding-bottom: var(--spacing-sm);
    border-bottom: 1px solid var(--color-border);
    margin-bottom: var(--spacing-sm);
}

.user-dropdown .user-info strong {
    display: block;
    color: var(--color-primary);
    font-size: 1.05rem;
}

.user-dropdown .user-info span {
    font-size: 0.85rem;
    color: #888;
}

.user-dropdown ul {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-bottom: var(--spacing-md);
}

.user-dropdown ul a {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--color-text);
    font-size: 0.95rem;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: background 0.2s;
    border-bottom: none; /* Override possible global rules */
}

.user-dropdown ul a:hover {
    background: var(--color-bg);
    color: var(--color-secondary);
}

.user-dropdown ul a i {
    width: 18px;
    height: 18px;
}

/* Cart Sidebar */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(18, 75, 95, 0.4);
    backdrop-filter: blur(3px);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.cart-overlay.active {
    opacity: 1;
    visibility: visible;
}

.cart-sidebar {
    position: fixed;
    top: 0;
    right: -450px;
    width: 100%;
    max-width: 450px;
    height: 100vh;
    background-color: var(--color-white);
    z-index: 1000;
    box-shadow: -10px 0 30px rgba(0,0,0,0.1);
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.cart-sidebar.active {
    right: 0;
}

.cart-header {
    padding: var(--spacing-md);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.cart-header h3 {
    font-size: 1.2rem;
    margin: 0;
}

.close-cart {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #888;
    transition: color 0.2s ease;
    display: flex;
}

.close-cart:hover {
    color: var(--color-secondary);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: var(--spacing-md);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.cart-item {
    display: flex;
    gap: var(--spacing-sm);
    padding-bottom: var(--spacing-sm);
    border-bottom: 1px solid var(--color-border);
    position: relative;
}

.cart-item img {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-md);
    background-color: var(--color-bg);
}

.item-details h4 {
    font-size: 0.95rem;
    margin-bottom: 0.2rem;
    color: var(--color-text);
}

.item-price {
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
}

.item-qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.item-qty button {
    background: var(--color-bg);
    border: none;
    width: 28px;
    height: 28px;
    cursor: pointer;
    font-weight: 600;
    color: var(--color-text);
}

.item-qty button:hover {
    background: #e0e0e0;
}

.item-qty span {
    width: 30px;
    text-align: center;
    font-size: 0.9rem;
    font-weight: 500;
}

.remove-item {
    position: absolute;
    top: 0;
    right: 0;
    background: transparent;
    border: none;
    color: #aaa;
    cursor: pointer;
}

.remove-item:hover {
    color: var(--color-secondary);
}

.cart-footer {
    padding: var(--spacing-md);
    border-top: 1px solid var(--color-border);
    background-color: var(--color-bg);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-md);
    font-size: 1.2rem;
}

.cart-total strong {
    color: var(--color-primary);
    font-size: 1.4rem;
}

/* ==========================================================================
   NUEVAS SECCIONES HOME (PRO)
   ========================================================================== */

/* Hero Section 2 Columnas */
.hero-pro {
    padding: 140px 0 var(--spacing-xl) 0; /* Increased top padding to give the logo more breathing room */
    position: relative;
    z-index: 1; /* Asegura que quede por debajo del header */
}

.hero-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: var(--spacing-md);
    min-height: 450px;
}

.hero-categories {
    background: var(--color-white);
    border-radius: var(--radius-lg);
    padding: var(--spacing-xs) 0;
}

.hero-categories ul {
    display: flex;
    flex-direction: column;
}

.hero-categories li a {
    display: flex;
    align-items: center;
    padding: 1.2rem var(--spacing-md);
    text-decoration: none;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid rgba(231, 236, 239, 0.5);
}

.hero-categories li:last-child a {
    border-bottom: none;
}

.hero-categories li a:hover {
    background-color: var(--color-bg);
}

.cat-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1.2rem;
    flex-shrink: 0;
}

.cat-icon-box svg {
    width: 24px;
    height: 24px;
    stroke-width: 1.5px;
}

/* Colores suaves para los fondos de iconos */
.bg-soft-blue { background-color: #EBF4F9; color: #124B5F; }
.bg-soft-coral { background-color: #FDEDE9; color: #F26B4F; }
.bg-soft-purple { background-color: #F4EFFF; color: #6B21A8; }
.bg-soft-green { background-color: #EAF4EC; color: #166534; }
.bg-soft-yellow { background-color: #FEF6E1; color: #B45309; }
.bg-soft-gray { background-color: #F1F5F9; color: #475569; }

.cat-text {
    display: flex;
    flex-direction: column;
}

.cat-text strong {
    font-size: 1.05rem;
    color: var(--color-text);
    font-weight: 600;
    line-height: 1.2;
}

.cat-text span {
    font-size: 0.85rem;
    color: #7A848D;
    margin-top: 4px;
}

.hero-slider {
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-md);
}

.slider-container {
    width: 100%;
    height: 100%;
}

.slide {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    padding: var(--spacing-xxl);
    position: relative;
}

.slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(18, 75, 95, 0.8) 0%, rgba(18, 75, 95, 0.1) 100%);
}

.slide-content {
    position: relative;
    z-index: 2;
    color: var(--color-white);
    max-width: 500px;
}

.slide-content .badge {
    display: inline-block;
    background: var(--color-secondary);
    color: var(--color-white);
    padding: 0.3rem 0.8rem;
    border-radius: var(--radius-pill);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: var(--spacing-sm);
}

.slide-content h2 {
    font-size: 3.5rem;
    color: var(--color-white);
    margin-bottom: var(--spacing-lg);
    line-height: 1.1;
}

/* Product Section Header */
.section-header-pro {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: var(--spacing-lg);
    border-bottom: 2px solid var(--color-border);
    padding-bottom: var(--spacing-sm);
}

.section-header-pro h2 {
    font-size: 1.8rem;
    margin: 0;
}

.view-all {
    font-weight: 600;
    color: var(--color-secondary);
}

.view-all:hover {
    text-decoration: underline;
}

/* Product Carousel & Grid */
.product-carousel-section, .product-grid-section {
    padding: var(--spacing-xl) 0;
}

.carousel-container {
    display: flex;
    gap: var(--spacing-md);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: var(--spacing-md);
    /* Ocultar scrollbar visualmente */
    scrollbar-width: none;
}

.carousel-container::-webkit-scrollbar {
    display: none;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--spacing-md);
}

/* Product Card */
.product-card {
    background: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.3s ease;
    flex: 0 0 280px; /* Para el carrusel */
    scroll-snap-align: start;
    position: relative;
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
    border-color: rgba(242, 107, 79, 0.3);
}

.product-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    background-color: #F8F8F8;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.08);
}

.add-to-cart-btn {
    position: absolute;
    bottom: var(--spacing-sm);
    right: var(--spacing-sm);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--color-white);
    border: none;
    box-shadow: var(--shadow-md);
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 2;
}

.product-card:hover .add-to-cart-btn {
    opacity: 1;
    transform: translateY(0);
}

.add-to-cart-btn:hover {
    background: var(--color-secondary);
    color: var(--color-white);
}

.product-info {
    padding: var(--spacing-md);
}

.product-category {
    font-size: 0.8rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
    margin-bottom: 0.3rem;
}

.product-info h3 {
    font-size: 1.1rem;
    color: var(--color-text);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.product-info .price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-primary);
}

/* Promo Banner */
.promo-banner {
    padding: var(--spacing-lg) 0;
}

.banner-wrapper {
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    background-size: cover;
    background-position: center;
    padding: var(--spacing-xxl);
    display: flex;
    align-items: center;
    min-height: 400px;
}

.banner-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, rgba(37, 43, 48, 0.8) 0%, rgba(37, 43, 48, 0) 100%);
}

.banner-content {
    position: relative;
    z-index: 2;
    max-width: 500px;
}

.banner-content h2 {
    color: var(--color-white);
    font-size: 2.5rem;
    margin-bottom: var(--spacing-lg);
}

/* Footer */
.site-footer {
    background-color: var(--color-primary);
    color: var(--color-white);
    padding: var(--spacing-xl) 0 var(--spacing-lg);
    margin-top: var(--spacing-xxl);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-xl);
    margin-bottom: var(--spacing-xl);
}

.footer-col h4 {
    color: var(--color-white);
    margin-bottom: var(--spacing-md);
    font-size: 1.1rem;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.footer-col a {
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

.footer-col a:hover {
    color: var(--color-white);
}

.footer-logo-box {
    background-color: var(--color-white);
    padding: 10px 20px;
    border-radius: var(--radius-md);
    display: inline-block;
    box-shadow: var(--shadow-md);
}

.footer-logo-box img {
    height: 45px;
    filter: invert(0); /* Resets any global filters to ensure it looks original */
}

.footer-bottom {
    text-align: center;
    padding-top: var(--spacing-lg);
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.85rem;
    color: rgba(255,255,255,0.6);
}

/* Category Pages */
.category-banner {
    padding: 140px 0 var(--spacing-xl);
}

.category-banner-wrapper {
    min-height: 350px;
    justify-content: center;
    text-align: center;
}

.category-banner-wrapper .banner-content h1 {
    font-size: 3.5rem;
    color: var(--color-white);
    margin-bottom: var(--spacing-sm);
}

.category-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

/* Custom Select */
.custom-select {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    background: var(--color-white);
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--color-text);
    outline: none;
    cursor: pointer;
}

/* Floating Widgets */
.sticky-social {
    position: fixed;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    z-index: 900;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.social-icon {
    background-color: var(--color-white);
    color: var(--color-primary);
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--color-border);
    border-left: none;
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    position: relative;
    left: -5px; /* Slightly hidden initially */
}

.social-icon:hover {
    background-color: var(--color-secondary);
    color: var(--color-white);
    left: 0;
    width: 55px; /* Expands on hover */
}

.social-icon svg {
    width: 20px;
    height: 20px;
}

/* Floating Chatbot */
.floating-chatbot {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999;
    display: flex;
    align-items: center;
    gap: 15px;
}

.chatbot-tooltip {
    background-color: var(--color-white);
    color: var(--color-text);
    padding: 10px 15px;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    font-weight: 500;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-border);
    position: relative;
    opacity: 0;
    transform: translateX(20px);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Arrow pointing to the button */
.chatbot-tooltip::after {
    content: '';
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
    width: 12px;
    height: 12px;
    background-color: var(--color-white);
    border-top: 1px solid var(--color-border);
    border-right: 1px solid var(--color-border);
}

.floating-chatbot:hover .chatbot-tooltip {
    opacity: 1;
    transform: translateX(0);
}

.chatbot-btn {
    background-color: var(--color-primary);
    color: var(--color-white);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(18, 75, 95, 0.4);
    transition: all 0.3s ease;
}

.chatbot-btn:hover {
    background-color: var(--color-secondary);
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(242, 107, 79, 0.4);
}

/* Responsive Utilities */
@media (max-width: 992px) {
    .main-nav {
        display: none;
    }
    
    .search-input {
        width: 100px;
    }
    
    .search-input:focus {
        width: 140px;
    }
    
    .hero-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-categories {
        display: none; /* En móviles, las categorías se moverían a un off-canvas menu o similar */
    }
    
    .sticky-social {
        display: none; /* Hide sticky social on small screens */
    }
}

@media (max-width: 768px) {
    .slide-content h2 {
        font-size: 2.5rem;
    }
    
    .banner-wrapper {
        min-height: 300px;
        padding: var(--spacing-lg);
    }
    
    .banner-content h2 {
        font-size: 2rem;
    }
}
