/*
Theme Name: TuApp
Theme URI: https://tuapp.local
Author: TuApp Team
Author URI: https://tuapp.local
Description: Tema moderno de alto rendimiento para WooCommerce con CJ Dropshipping. Optimizado para SEO, rendimiento, y experiencia de compra moderna con carrito AJAX, lazyload inteligente, y semántica HTML5. Construido con estándares modernos priorizando Core Web Vitals.
Version: 1.0.0
Requires at least: 6.2
Tested up to: 6.6
Requires PHP: 8.0
License: Proprietary
License URI: https://tuapp.local/license
Text Domain: tuapp
Domain Path: /languages
Tags: e-commerce, woocommerce, high-performance, seo-optimized, ajax-cart, lazy-loading, semantic-html, accessible-ready

WooCommerce

Este tema está diseñado exclusivamente para WooCommerce + CJ Dropshipping.
Prioriza velocidad, semántica HTML5, y experiencia de compra moderna.
*/

/* ==========================================================================
   CSS Custom Properties (Design Tokens)
   ========================================================================== */
:root {
    /* ── Colores de Marca Premium ── */
    --color-primary: #0a0a0f;
    --color-primary-light: #1a1a2e;
    --color-primary-rgb: 10, 10, 15;
    --color-accent: #dc2626;
    --color-accent-hover: #b91c1c;
    --color-accent-rgb: 220, 38, 38;
    --color-accent-secondary: #7c3aed;
    --color-accent-secondary-rgb: 124, 58, 237;
    --color-gold: #d4af37;
    --color-gold-light: #f4d03f;

    /* ── Gradientes Premium ── */
    --gradient-primary: linear-gradient(135deg, #0a0a0f 0%, #1a1a2e 100%);
    --gradient-accent: linear-gradient(135deg, #dc2626 0%, #7c3aed 100%);
    --gradient-gold: linear-gradient(135deg, #d4af37 0%, #f4d03f 100%);
    --gradient-sunset: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-ocean: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);

    /* ── Superficies y Texto ── */
    --color-surface: #ffffff;
    --color-surface-alt: #fafafa;
    --color-surface-dark: #0a0a0f;
    --color-surface-elevated: #ffffff;
    --color-text: #0a0a0f;
    --color-text-light: #374151;
    --color-text-muted: #6b7280;
    --color-text-inverse: #ffffff;
    --color-text-on-accent: #ffffff;
    --color-border: #e5e7eb;
    --color-border-light: #f3f4f6;
    --color-border-dark: #374151;

    /* ── Glassmorphism ── */
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-bg-dark: rgba(10, 10, 15, 0.7);
    --glass-border: rgba(255, 255, 255, 0.18);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);

    /* ── Estados ── */
    --color-success: #10b981;
    --color-success-light: #d1fae5;
    --color-success-rgb: 16, 185, 129;
    --color-warning: #f59e0b;
    --color-warning-light: #fef3c7;
    --color-warning-rgb: 245, 158, 11;
    --color-error: #ef4444;
    --color-error-light: #fee2e2;
    --color-error-rgb: 239, 68, 68;
    --color-info: #3b82f6;
    --color-info-light: #dbeafe;

    /* ── Tipografía Premium ── */
    --font-sans:
        "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", sans-serif;
    --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
    --font-mono: "JetBrains Mono", "Fira Code", monospace;

    /* ── Escala Tipográfica Modular (1.25 Major Third) ── */
    --text-xs: clamp(0.75rem, 0.5vw + 0.5rem, 0.875rem);
    --text-sm: clamp(0.875rem, 0.5vw + 0.625rem, 1rem);
    --text-base: clamp(1rem, 0.5vw + 0.75rem, 1.125rem);
    --text-md: clamp(1.125rem, 0.75vw + 0.875rem, 1.25rem);
    --text-lg: clamp(1.25rem, 1vw + 1rem, 1.5rem);
    --text-xl: clamp(1.5rem, 1.25vw + 1.25rem, 1.875rem);
    --text-2xl: clamp(1.875rem, 1.5vw + 1.5rem, 2.25rem);
    --text-3xl: clamp(2.25rem, 2vw + 1.75rem, 3rem);
    --text-4xl: clamp(2.5rem, 2.5vw + 2rem, 3.75rem);
    --text-5xl: clamp(3rem, 3vw + 2.5rem, 4.5rem);

    /* ── Espaciado ── */
    --space-3xs: 0.25rem;
    --space-2xs: 0.5rem;
    --space-xs: 0.75rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 4rem;
    --space-3xl: 6rem;
    --space-4xl: 8rem;
    --space-5xl: 12rem;

    /* ── Bordes Premium ── */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-3xl: 2rem;
    --radius-full: 9999px;

    /* ── Sombras Premium (Elevación) ── */
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-sm:
        0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --shadow-md:
        0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg:
        0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-xl:
        0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --shadow-inner: inset 0 2px 4px 0 rgba(0, 0, 0, 0.05);
    --shadow-glow: 0 0 40px rgba(220, 38, 38, 0.3);
    --shadow-glow-gold: 0 0 40px rgba(212, 175, 55, 0.3);

    /* ── Layout ── */
    --max-width: 1536px;
    --max-width-content: 1280px;
    --max-width-narrow: 720px;
    --max-width-wide: 1920px;
    --header-height: 80px;
    --header-height-scrolled: 64px;
    --container-padding: 1.5rem;
    --container-padding-lg: 2rem;

    /* ── Z-Index Layering ── */
    --z-base: 0;
    --z-content: 10;
    --z-dropdown: 20;
    --z-sticky: 30;
    --z-header: 100;
    --z-overlay: 150;
    --z-modal: 200;
    --z-popover: 250;
    --z-tooltip: 300;
    --z-toast: 400;

    /* ── Transiciones Premium ── */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 500ms cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --transition-smooth: 400ms cubic-bezier(0.16, 1, 0.3, 1);

    /* ── Animaciones ── */
    --animate-fade-in: fade-in 0.3s ease-out;
    --animate-slide-up: slide-up 0.4s ease-out;
    --animate-scale-in: scale-in 0.2s ease-out;
}

/* ==========================================================================
   Reset y Normalización Moderna
   ========================================================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-surface);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ==========================================================================
   A11y Mejorado
   ========================================================================== */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: var(--color-surface);
    clip: auto !important;
    clip-path: none;
    color: var(--color-text);
    display: block;
    font-size: var(--text-base);
    height: auto;
    left: var(--space-xs);
    line-height: normal;
    padding: var(--space-sm) var(--space-md);
    text-decoration: none;
    top: var(--space-xs);
    width: auto;
    z-index: 100000;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
}

.skip-link {
    position: fixed;
    top: var(--space-xs);
    left: var(--space-xs);
    z-index: 99999;
    background: var(--color-accent);
    color: #fff;
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-sm);
    font-weight: 600;
    text-decoration: none;
    transform: translateY(-150%);
    transition: transform var(--transition-base);
}

.skip-link:focus {
    transform: translateY(0);
}

/* ==========================================================================
   Tipografía
   ========================================================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
    color: var(--color-text);
}

h1 {
    font-size: var(--text-3xl);
}
h2 {
    font-size: var(--text-2xl);
}
h3 {
    font-size: var(--text-xl);
}
h4 {
    font-size: var(--text-lg);
}
h5 {
    font-size: var(--text-md);
}
h6 {
    font-size: var(--text-base);
}

p {
    margin-bottom: var(--space-sm);
}

a {
    color: var(--color-accent);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--color-accent-hover);
}

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

/* ==========================================================================
   Layout Principal
   ========================================================================== */
.site-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.site-main {
    flex: 1;
    padding-top: var(--header-height);
}

.container {
    width: 100%;
    max-width: var(--max-width-content);
    margin-inline: auto;
    padding-inline: var(--space-md);
}

.container--narrow {
    max-width: var(--max-width-narrow);
}

.container--wide {
    max-width: var(--max-width);
}

/* Grid para listings de productos */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-md);
}

.products-grid--3-cols {
    grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .products-grid--3-cols {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-sm);
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-xs);
        padding-inline: var(--space-xs);
    }
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-header);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--color-border);
    transition: all var(--transition-base);
    height: var(--header-height);
}

.site-header--scrolled {
    height: var(--header-height-scrolled);
    box-shadow: var(--shadow-md);
    background: rgba(255, 255, 255, 0.96);
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    gap: var(--space-md);
}

.header__logo {
    flex-shrink: 0;
}

.header__logo img {
    height: clamp(28px, 3vw, 36px);
    width: auto;
}

.header__nav {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
}

.header__search {
    flex: 1;
    max-width: 480px;
}

.header__actions {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

/* ==========================================================================
   Botones
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2xs);
    padding: 0.65em 1.5em;
    border: 2px solid transparent;
    border-radius: var(--radius-md);
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: var(--text-sm);
    line-height: 1;
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
    user-select: none;
    text-decoration: none;
}

.btn:focus-visible {
    outline: 3px solid var(--color-accent);
    outline-offset: 3px;
}

.btn--primary {
    background-color: var(--color-accent);
    color: #ffffff;
}

.btn--primary:hover {
    background-color: var(--color-accent-hover);
    color: #ffffff;
}

.btn--secondary {
    background-color: transparent;
    border-color: var(--color-border);
    color: var(--color-text);
}

.btn--secondary:hover {
    background-color: var(--color-surface-alt);
    border-color: var(--color-text-muted);
}

.btn--ghost {
    background-color: transparent;
    border-color: transparent;
    color: var(--color-text);
}

.btn--ghost:hover {
    background-color: var(--color-surface-alt);
}

.btn--icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: var(--radius-full);
}

.btn--lg {
    padding: 0.85em 2em;
    font-size: var(--text-base);
}

.btn--sm {
    padding: 0.4em 1em;
    font-size: var(--text-xs);
}

.btn--full {
    width: 100%;
}

.btn--loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
}

.btn--loading::after {
    content: "";
    position: absolute;
    width: 1.25em;
    height: 1.25em;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    color: #ffffff;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================================================
   Tarjetas de Producto
   ========================================================================== */
.product-card {
    position: relative;
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border-light);
    overflow: hidden;
    transition: all var(--transition-base);
    container-type: inline-size;
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.product-card__image {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--color-surface-alt);
}

.product-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.product-card:hover .product-card__image img {
    transform: scale(1.06);
}

.product-card__badge {
    position: absolute;
    top: var(--space-xs);
    left: var(--space-xs);
    background: var(--color-accent);
    color: #fff;
    font-size: var(--text-xs);
    font-weight: 700;
    padding: 0.25em 0.75em;
    border-radius: var(--radius-full);
    z-index: 2;
}

.product-card__badge--sale {
    background: var(--color-error);
}

.product-card__badge--new {
    background: var(--color-success);
}

.product-card__badge--out-of-stock {
    background: var(--color-text-muted);
}

.product-card__actions {
    position: absolute;
    bottom: var(--space-xs);
    right: var(--space-xs);
    display: flex;
    flex-direction: column;
    gap: var(--space-3xs);
    opacity: 0;
    transform: translateY(8px);
    transition: all var(--transition-base);
    z-index: 2;
}

.product-card:hover .product-card__actions {
    opacity: 1;
    transform: translateY(0);
}

.product-card__body {
    padding: var(--space-sm);
}

.product-card__title {
    font-size: var(--text-sm);
    font-weight: 600;
    margin-bottom: var(--space-2xs);
    line-height: 1.3;
}

.product-card__title a {
    color: var(--color-text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card__title a:hover {
    color: var(--color-accent);
}

.product-card__price {
    display: flex;
    align-items: baseline;
    gap: var(--space-2xs);
    flex-wrap: wrap;
}

.product-card__price .price {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--color-text);
}

.product-card__price ins {
    text-decoration: none;
}

.product-card__price del {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
}

.product-card__rating {
    display: flex;
    align-items: center;
    gap: var(--space-3xs);
    margin-top: var(--space-2xs);
}

/* ==========================================================================
   Carrusel / Hero
   ========================================================================== */
.hero-slider {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    background: var(--color-surface-dark);
    margin-bottom: var(--space-xl);
}

.hero-slide {
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(320px, 45vw, 520px);
    padding: var(--space-2xl) var(--space-md);
}

.hero-slide__content {
    flex: 1;
    max-width: 520px;
    z-index: 2;
}

.hero-slide__title {
    font-size: var(--text-3xl);
    color: var(--color-text-on-dark);
    margin-bottom: var(--space-sm);
}

.hero-slide__text {
    color: rgba(255, 255, 255, 0.8);
    font-size: var(--text-md);
    margin-bottom: var(--space-lg);
}

.hero-slide__image {
    position: absolute;
    right: 0;
    top: 0;
    width: 55%;
    height: 100%;
    object-fit: cover;
    object-position: left center;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
    background: var(--color-primary);
    color: rgba(255, 255, 255, 0.7);
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-lg);
    margin-top: var(--space-2xl);
}

.footer__inner {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: var(--space-xl);
}

.footer__col h4 {
    color: #fff;
    font-size: var(--text-sm);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--space-md);
}

.footer__col ul {
    list-style: none;
}

.footer__col ul li {
    margin-bottom: var(--space-2xs);
}

.footer__col ul a {
    color: rgba(255, 255, 255, 0.6);
    font-size: var(--text-sm);
    transition: color var(--transition-fast);
}

.footer__col ul a:hover {
    color: #fff;
}

.footer__bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: var(--space-xl);
    padding-top: var(--space-md);
    text-align: center;
    font-size: var(--text-xs);
    color: rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
    .footer__inner {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-lg);
    }
}

@media (max-width: 480px) {
    .footer__inner {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Página de Producto Individual
   ========================================================================== */
.single-product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
    align-items: start;
    padding-block: var(--space-xl);
}

.product-gallery {
    position: sticky;
    top: calc(var(--header-height) + var(--space-md));
}

.product-gallery__main {
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--color-surface-alt);
    aspect-ratio: 1;
}

.product-gallery__main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-gallery__thumbs {
    display: flex;
    gap: var(--space-xs);
    margin-top: var(--space-xs);
    overflow-x: auto;
    padding-bottom: var(--space-2xs);
}

.product-gallery__thumb {
    width: 72px;
    height: 72px;
    flex-shrink: 0;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    transition: border-color var(--transition-fast);
}

.product-gallery__thumb.is-active {
    border-color: var(--color-accent);
}

.product-gallery__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-summary__title {
    font-size: var(--text-2xl);
    margin-bottom: var(--space-sm);
}

.product-summary__price {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: var(--space-md);
}

.product-summary__price del {
    font-size: var(--text-base);
    color: var(--color-text-muted);
    margin-left: var(--space-xs);
}

.product-summary__description {
    color: var(--color-text-light);
    margin-bottom: var(--space-lg);
    line-height: 1.7;
}

@media (max-width: 768px) {
    .single-product-layout {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }

    .product-gallery {
        position: static;
    }
}

/* ==========================================================================
   Carrito Drawer Moderno
   ========================================================================== */
.cart-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: var(--z-cart-drawer);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.cart-drawer-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(100vw, 420px);
    background: #fff;
    z-index: calc(var(--z-cart-drawer) + 1);
    transform: translateX(100%);
    transition: transform var(--transition-base);
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-xl);
}

.cart-drawer.is-open {
    transform: translateX(0);
}

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

.cart-drawer__title {
    font-size: var(--text-md);
    font-weight: 700;
}

.cart-drawer__count {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
}

.cart-drawer__body {
    flex: 1;
    overflow-y: auto;
    padding: var(--space-md);
    overscroll-behavior: contain;
}

.cart-drawer__footer {
    padding: var(--space-md);
    border-top: 1px solid var(--color-border);
}

.cart-drawer__total {
    display: flex;
    justify-content: space-between;
    font-weight: 700;
    margin-bottom: var(--space-md);
    font-size: var(--text-md);
}

.cart-drawer__item {
    display: flex;
    gap: var(--space-sm);
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--color-border-light);
}

.cart-drawer__item-image {
    width: 72px;
    height: 72px;
    flex-shrink: 0;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--color-surface-alt);
}

.cart-drawer__item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-drawer__item-info {
    flex: 1;
    min-width: 0;
}

.cart-drawer__item-title {
    font-size: var(--text-sm);
    font-weight: 600;
    margin-bottom: var(--space-3xs);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.cart-drawer__item-price {
    font-size: var(--text-sm);
    color: var(--color-text-muted);
}

.cart-drawer__item-qty {
    display: flex;
    align-items: center;
    gap: var(--space-2xs);
    margin-top: var(--space-2xs);
}

.cart-drawer__item-qty button {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--color-border);
    background: var(--color-surface-alt);
    font-size: var(--text-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-drawer__item-remove {
    color: var(--color-text-muted);
    cursor: pointer;
    padding: var(--space-3xs);
    align-self: flex-start;
    background: none;
    border: none;
}

.cart-drawer__item-remove:hover {
    color: var(--color-error);
}

/* ==========================================================================
   Notificaciones Toast
   ========================================================================== */
.toast-container {
    position: fixed;
    bottom: var(--space-md);
    right: var(--space-md);
    z-index: var(--z-toast);
    display: flex;
    flex-direction: column-reverse;
    gap: var(--space-xs);
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-sm) var(--space-md);
    background: var(--color-primary);
    color: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    font-size: var(--text-sm);
    font-weight: 500;
    pointer-events: all;
    animation: toast-in var(--transition-base) forwards;
}

.toast--success {
    background: var(--color-success);
}

.toast--error {
    background: var(--color-error);
}

.toast--removing {
    animation: toast-out var(--transition-fast) forwards;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes toast-out {
    to {
        opacity: 0;
        transform: translateY(10px) scale(0.95);
    }
}

/* ==========================================================================
   Animaciones Premium Tipo Framer Motion
   ========================================================================== */

/* Fade In */
@keyframes fade-in {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Fade In Up */
@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Fade In Down */
@keyframes fade-in-down {
    from {
        opacity: 0;
        transform: translateY(-40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Fade In Left */
@keyframes fade-in-left {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Fade In Right */
@keyframes fade-in-right {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Scale In */
@keyframes scale-in {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Scale In Center */
@keyframes scale-in-center {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Slide Up */
@keyframes slide-up {
    from {
        opacity: 0;
        transform: translateY(60px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Slide Down */
@keyframes slide-down {
    from {
        opacity: 0;
        transform: translateY(-60px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Slide In Left */
@keyframes slide-in-left {
    from {
        opacity: 0;
        transform: translateX(-100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Slide In Right */
@keyframes slide-in-right {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Bounce In */
@keyframes bounce-in {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        transform: scale(1);
    }
}

/* Pulse */
@keyframes pulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Ping */
@keyframes ping {
    75%,
    100% {
        transform: scale(2);
        opacity: 0;
    }
}

/* Spin Slow */
@keyframes spin-slow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Float */
@keyframes float {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Shimmer */
@keyframes shimmer {
    from {
        background-position: 0 0;
    }
    to {
        background-position: -200% 0;
    }
}

/* Glow */
@keyframes glow {
    0%,
    100% {
        box-shadow: 0 0 20px rgba(220, 38, 38, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(220, 38, 38, 0.6);
    }
}

/* Gradient Shift */
@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* ==========================================================================
   Clases de Utilidad para Animaciones
   ========================================================================== */

.animate-fade-in {
    animation: fade-in var(--transition-base) ease-out;
}

.animate-fade-in-up {
    animation: fade-in-up 0.6s ease-out;
}

.animate-fade-in-down {
    animation: fade-in-down 0.6s ease-out;
}

.animate-fade-in-left {
    animation: fade-in-left 0.6s ease-out;
}

.animate-fade-in-right {
    animation: fade-in-right 0.6s ease-out;
}

.animate-scale-in {
    animation: scale-in 0.3s ease-out;
}

.animate-scale-in-center {
    animation: scale-in-center 0.4s ease-out;
}

.animate-slide-up {
    animation: slide-up 0.6s ease-out;
}

.animate-slide-down {
    animation: slide-down 0.6s ease-out;
}

.animate-slide-in-left {
    animation: slide-in-left 0.6s ease-out;
}

.animate-slide-in-right {
    animation: slide-in-right 0.6s ease-out;
}

.animate-bounce-in {
    animation: bounce-in 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.animate-ping {
    animation: ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
}

.animate-spin-slow {
    animation: spin-slow 3s linear infinite;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-shimmer {
    animation: shimmer 2s linear infinite;
}

.animate-glow {
    animation: glow 2s ease-in-out infinite;
}

.animate-gradient {
    background-size: 200% 200%;
    animation: gradient-shift 3s ease infinite;
}

/* Delay utilities */
.delay-100 {
    animation-delay: 100ms;
}
.delay-200 {
    animation-delay: 200ms;
}
.delay-300 {
    animation-delay: 300ms;
}
.delay-400 {
    animation-delay: 400ms;
}
.delay-500 {
    animation-delay: 500ms;
}
.delay-700 {
    animation-delay: 700ms;
}
.delay-1000 {
    animation-delay: 1000ms;
}

/* Duration utilities */
.duration-fast {
    animation-duration: 150ms;
}
.duration-base {
    animation-duration: 300ms;
}
.duration-slow {
    animation-duration: 500ms;
}
.duration-slower {
    animation-duration: 700ms;
}
.duration-slowest {
    animation-duration: 1000ms;
}

/* ==========================================================================
   Utilidades
   ========================================================================== */
.skeleton {
    background: linear-gradient(
        90deg,
        var(--color-surface-alt) 25%,
        var(--color-border-light) 50%,
        var(--color-surface-alt) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-shimmer {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.no-scroll {
    overflow: hidden;
    padding-right: var(--scrollbar-width, 0px);
}

/* ==========================================================================
   Lazy Load - Placeholder
   ========================================================================== */
img[data-src] {
    opacity: 0;
    transition: opacity var(--transition-base);
}

img[data-src].loaded {
    opacity: 1;
}

/* ==========================================================================
   Animaciones de Entrada (para Intersection Observer)
   ========================================================================== */
.fade-up {
    opacity: 0;
    transform: translateY(24px);
    transition:
        opacity 0.6s ease-out,
        transform 0.6s ease-out;
}

.fade-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Media Queries Globales
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

@media (prefers-color-scheme: dark) {
    /* El tema ya está optimizado para modo claro.
       Para dark mode completo se necesitaría un toggle.
       Aquí se respeta la preferencia base del sistema. */
}
```
</think>```css
/*
Theme Name: TuApp
Theme URI: https://tuapp.local
Author: TuApp Team
Author URI: https://tuapp.local
Description: Tema moderno de alto rendimiento para WooCommerce con CJ Dropshipping. Optimizado para SEO, rendimiento, y experiencia de compra moderna con carrito AJAX, lazyload inteligente, y semántica HTML5. Construido con estándares modernos priorizando Core Web Vitals.
Version: 1.0.0
Requires at least: 6.2
Tested up to: 6.6
Requires PHP: 8.0
License: Proprietary
License URI: https://tuapp.local/license
Text Domain: tuapp
Domain Path: /languages
Tags: e-commerce, woocommerce, high-performance, seo-optimized, ajax-cart, lazy-loading, semantic-html, accessible-ready

WooCommerce

Este tema está diseñado exclusivamente para WooCommerce + CJ Dropshipping.
Prioriza velocidad, semántica HTML5, y experiencia de compra moderna.
*/

/* ==========================================================================
   CSS Custom Properties (Design Tokens)
   ========================================================================== */
:root {
    /* ── Colores de Marca ── */
    --color-primary: #1a1a2e;
    --color-primary-light: #2d2d4a;
    --color-primary-rgb: 26, 26, 46;
    --color-accent: #e94560;
    --color-accent-hover: #d63852;
    --color-accent-rgb: 233, 69, 96;
    --color-accent-secondary: #0f3460;
    --color-accent-secondary-rgb: 15, 52, 96;

    /* ── Superficies y Texto ── */
    --color-surface: #ffffff;
    --color-surface-alt: #f8f9fa;
    --color-surface-dark: #16213e;
    --color-text: #1a1a2e;
    --color-text-light: #495057;
    --color-text-muted: #6c757d;
    --color-text-on-dark: #ffffff;
    --color-border: #e9ecef;
    --color-border-light: #f1f3f5;

    /* ── Estados ── */
    --color-success: #2dce89;
    --color-success-rgb: 45, 206, 137;
    --color-warning: #fb6340;
    --color-warning-rgb: 251, 99, 64;
    --color-error: #f5365c;
    --color-error-rgb: 245, 54, 92;

    /* ── Tipografía ── */
    --font-sans:
        "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        sans-serif;
    --font-display:
        "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        sans-serif;
    --font-mono: "JetBrains Mono", "Fira Code", "Consolas", monospace;

    /* ── Escala Tipográfica (1.25 Major Third) ── */
    --text-xs: clamp(0.64rem, 0.05vw + 0.63rem, 0.67rem);
    --text-sm: clamp(0.8rem, 0.15vw + 1.3rem, 0.9rem);
    --text-base: clamp(1rem, 0.34vw + 0.91rem, 1.1rem);
    --text-md: clamp(1.2rem, 0.28vw + 1.13rem, 1.35rem);
    --text-lg: clamp(1.44rem, 0.37vw + 1.35rem, 1.7rem);
    --text-xl: clamp(1.73rem, 0.51vw + 1.6rem, 2.1rem);
    --text-2xl: clamp(2.07rem, 0.72vw + 1.89rem, 2.6rem);
    --text-3xl: clamp(2.49rem, 1.01vw + 2.24rem, 3.3rem);

    /* ── Espaciado ── */
    --space-3xs: clamp(0.25rem, 0.13vw + 0.22rem, 0.31rem);
    --space-2xs: clamp(0.5rem, 0.25vw + 0.44rem, 0.63rem);
    --space-xs: clamp(0.75rem, 0.38vw + 0.66rem, 0.94rem);
    --space-sm: clamp(1rem, 0.5vw + 0.88rem, 1.25rem);
    --space-md: clamp(1.5rem, 0.75vw + 1.31rem, 1.88rem);
    --space-lg: clamp(2rem, 1vw + 1.75rem, 2.5rem);
    --space-xl: clamp(3rem, 1.5vw + 2.63rem, 3.75rem);
    --space-2xl: clamp(4rem, 2vw + 3.5rem, 5rem);
    --space-3xl: clamp(6rem, 3vw + 5.25rem, 7.5rem);

    /* ── Bordes y Sombras ── */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-full: 9999px;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md:
        0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg:
        0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
    --shadow-xl:
        0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.04);

    /* ── Layout ── */
    --max-width: 1440px;
    --max-width-content: 1260px;
    --max-width-narrow: 780px;
    --header-height: 72px;
    --header-height-scrolled: 60px;
    --z-header: 100;
    --z-modal: 200;
    --z-cart-drawer: 300;
    --z-toast: 400;

    /* ── Transiciones ── */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   Reset y Normalización Moderna
   ========================================================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-surface);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ==========================================================================
   A11y Mejorado
   ========================================================================== */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: var(--color-surface);
    clip: auto !important;
    clip-path: none;
    color: var(--color-text);
    display: block;
    font-size: var(--text-base);
    height: auto;
    left: var(--space-xs);
    line-height: normal;
    padding: var(--space-sm) var(--space-md);
    text-decoration: none;
    top: var(--space-xs);
    width: auto;
    z-index: 100000;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
}

.skip-link {
    position: fixed;
    top: var(--space-xs);
    left: var(--space-xs);
    z-index: 99999;
    background: var(--color-accent);
    color: #fff;
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-sm);
    font-weight: 600;
    text-decoration: none;
    transform: translateY(-150%);
    transition: transform var(--transition-base);
}

.skip-link:focus {
    transform: translateY(0);
}

/* ==========================================================================
   Tipografía
   ========================================================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
    color: var(--color-text);
}

h1 {
    font-size: var(--text-3xl);
}
h2 {
    font-size: var(--text-2xl);
}
h3 {
    font-size: var(--text-xl);
}
h4 {
    font-size: var(--text-lg);
}
h5 {
    font-size: var(--text-md);
}
h6 {
    font-size: var(--text-base);
}

p {
    margin-bottom: var(--space-sm);
}

a {
    color: var(--color-accent);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--color-accent-hover);
}

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

/* ==========================================================================
   Layout Principal
   ========================================================================== */
.site-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.site-main {
    flex: 1;
    padding-top: var(--header-height);
}

.container {
    width: 100%;
    max-width: var(--max-width-content);
    margin-inline: auto;
    padding-inline: var(--space-md);
}

.container--narrow {
    max-width: var(--max-width-narrow);
}

.container--wide {
    max-width: var(--max-width);
}

/* Grid para listings de productos */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-md);
}

.products-grid--3-cols {
    grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .products-grid--3-cols {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-sm);
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-xs);
        padding-inline: var(--space-xs);
    }
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-header);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--color-border);
    transition: all var(--transition-base);
    height: var(--header-height);
}

.site-header--scrolled {
    height: var(--header-height-scrolled);
    box-shadow: var(--shadow-md);
    background: rgba(255, 255, 255, 0.96);
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    gap: var(--space-md);
}

.header__logo {
    flex-shrink: 0;
}

.header__logo img {
    height: clamp(28px, 3vw, 36px);
    width: auto;
}

.header__nav {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
}

.header__search {
    flex: 1;
    max-width: 480px;
}

.header__actions {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

/* ==========================================================================
   Botones
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2xs);
    padding: 0.65em 1.5em;
    border: 2px solid transparent;
    border-radius: var(--radius-md);
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: var(--text-sm);
    line-height: 1;
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
    user-select: none;
    text-decoration: none;
}

.btn:focus-visible {
    outline: 3px solid var(--color-accent);
    outline-offset: 3px;
}

.btn--primary {
    background-color: var(--color-accent);
    color: #ffffff;
}

.btn--primary:hover {
    background-color: var(--color-accent-hover);
    color: #ffffff;
}

.btn--secondary {
    background-color: transparent;
    border-color: var(--color-border);
    color: var(--color-text);
}

.btn--secondary:hover {
    background-color: var(--color-surface-alt);
    border-color: var(--color-text-muted);
}

.btn--ghost {
    background-color: transparent;
    border-color: transparent;
    color: var(--color-text);
}

.btn--ghost:hover {
    background-color: var(--color-surface-alt);
}

.btn--icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: var(--radius-full);
}

.btn--lg {
    padding: 0.85em 2em;
    font-size: var(--text-base);
}

.btn--sm {
    padding: 0.4em 1em;
    font-size: var(--text-xs);
}

.btn--full {
    width: 100%;
}

.btn--loading {
    position: relative;
    color: transparent !important;
    pointer-events: none;
}

.btn--loading::after {
    content: "";
    position: absolute;
    width: 1.25em;
    height: 1.25em;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    color: #ffffff;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================================================
   Tarjetas de Producto
   ========================================================================== */
.product-card {
    position: relative;
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border-light);
    overflow: hidden;
    transition: all var(--transition-base);
    container-type: inline-size;
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.product-card__image {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--color-surface-alt);
}

.product-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.product-card:hover .product-card__image img {
    transform: scale(1.06);
}

.product-card__badge {
    position: absolute;
    top: var(--space-xs);
    left: var(--space-xs);
    background: var(--color-accent);
    color: #fff;
    font-size: var(--text-xs);
    font-weight: 700;
    padding: 0.25em 0.75em;
    border-radius: var(--radius-full);
    z-index: 2;
}

.product-card__badge--sale {
    background: var(--color-error);
}

.product-card__badge--new {
    background: var(--color-success);
}

.product-card__badge--out-of-stock {
    background: var(--color-text-muted);
}

.product-card__actions {
    position: absolute;
    bottom: var(--space-xs);
    right: var(--space-xs);
    display: flex;
    flex-direction: column;
    gap: var(--space-3xs);
    opacity: 0;
    transform: translateY(8px);
    transition: all var(--transition-base);
    z-index: 2;
}

.product-card:hover .product-card__actions {
    opacity: 1;
    transform: translateY(0);
}

.product-card__body {
    padding: var(--space-sm);
}

.product-card__title {
    font-size: var(--text-sm);
    font-weight: 600;
    margin-bottom: var(--space-2xs);
    line-height: 1.3;
}

.product-card__title a {
    color: var(--color-text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card__title a:hover {
    color: var(--color-accent);
}

.product-card__price {
    display: flex;
    align-items: baseline;
    gap: var(--space-2xs);
    flex-wrap: wrap;
}

.product-card__price .price {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--color-text);
}

.product-card__price ins {
    text-decoration: none;
}

.product-card__price del {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
}

.product-card__rating {
    display: flex;
    align-items: center;
    gap: var(--space-3xs);
    margin-top: var(--space-2xs);
}

/* ==========================================================================
   Carrusel / Hero
   ========================================================================== */
.hero-slider {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    background: var(--color-surface-dark);
    margin-bottom: var(--space-xl);
}

.hero-slide {
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(320px, 45vw, 520px);
    padding: var(--space-2xl) var(--space-md);
}

.hero-slide__content {
    flex: 1;
    max-width: 520px;
    z-index: 2;
}

.hero-slide__title {
    font-size: var(--text-3xl);
    color: var(--color-text-on-dark);
    margin-bottom: var(--space-sm);
}

.hero-slide__text {
    color: rgba(255, 255, 255, 0.8);
    font-size: var(--text-md);
    margin-bottom: var(--space-lg);
}

.hero-slide__image {
    position: absolute;
    right: 0;
    top: 0;
    width: 55%;
    height: 100%;
    object-fit: cover;
    object-position: left center;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
    background: var(--color-primary);
    color: rgba(255, 255, 255, 0.7);
    padding-top: var(--space-2xl);
    padding-bottom: var(--space-lg);
    margin-top: var(--space-2xl);
}

.footer__inner {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: var(--space-xl);
}

.footer__col h4 {
    color: #fff;
    font-size: var(--text-sm);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--space-md);
}

.footer__col ul {
    list-style: none;
}

.footer__col ul li {
    margin-bottom: var(--space-2xs);
}

.footer__col ul a {
    color: rgba(255, 255, 255, 0.6);
    font-size: var(--text-sm);
    transition: color var(--transition-fast);
}

.footer__col ul a:hover {
    color: #fff;
}

.footer__bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: var(--space-xl);
    padding-top: var(--space-md);
    text-align: center;
    font-size: var(--text-xs);
    color: rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
    .footer__inner {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-lg);
    }
}

@media (max-width: 480px) {
    .footer__inner {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Página de Producto Individual
   ========================================================================== */
.single-product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
    align-items: start;
    padding-block: var(--space-xl);
}

.product-gallery {
    position: sticky;
    top: calc(var(--header-height) + var(--space-md));
}

.product-gallery__main {
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--color-surface-alt);
    aspect-ratio: 1;
}

.product-gallery__main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-gallery__thumbs {
    display: flex;
    gap: var(--space-xs);
    margin-top: var(--space-xs);
    overflow-x: auto;
    padding-bottom: var(--space-2xs);
}

.product-gallery__thumb {
    width: 72px;
    height: 72px;
    flex-shrink: 0;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    transition: border-color var(--transition-fast);
}

.product-gallery__thumb.is-active {
    border-color: var(--color-accent);
}

.product-gallery__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-summary__title {
    font-size: var(--text-2xl);
    margin-bottom: var(--space-sm);
}

.product-summary__price {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: var(--space-md);
}

.product-summary__price del {
    font-size: var(--text-base);
    color: var(--color-text-muted);
    margin-left: var(--space-xs);
}

.product-summary__description {
    color: var(--color-text-light);
    margin-bottom: var(--space-lg);
    line-height: 1.7;
}

@media (max-width: 768px) {
    .single-product-layout {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }

    .product-gallery {
        position: static;
    }
}

/* ==========================================================================
   Carrito Drawer Moderno
   ========================================================================== */
.cart-drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: var(--z-cart-drawer);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.cart-drawer-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(100vw, 420px);
    background: #fff;
    z-index: calc(var(--z-cart-drawer) + 1);
    transform: translateX(100%);
    transition: transform var(--transition-base);
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-xl);
}

.cart-drawer.is-open {
    transform: translateX(0);
}

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

.cart-drawer__title {
    font-size: var(--text-md);
    font-weight: 700;
}

.cart-drawer__count {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
}

.cart-drawer__body {
    flex: 1;
    overflow-y: auto;
    padding: var(--space-md);
    overscroll-behavior: contain;
}

.cart-drawer__footer {
    padding: var(--space-md);
    border-top: 1px solid var(--color-border);
}

.cart-drawer__total {
    display: flex;
    justify-content: space-between;
    font-weight: 700;
    margin-bottom: var(--space-md);
    font-size: var(--text-md);
}

.cart-drawer__item {
    display: flex;
    gap: var(--space-sm);
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--color-border-light);
}

.cart-drawer__item-image {
    width: 72px;
    height: 72px;
    flex-shrink: 0;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--color-surface-alt);
}

.cart-drawer__item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-drawer__item-info {
    flex: 1;
    min-width: 0;
}

.cart-drawer__item-title {
    font-size: var(--text-sm);
    font-weight: 600;
    margin-bottom: var(--space-3xs);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.cart-drawer__item-price {
    font-size: var(--text-sm);
    color: var(--color-text-muted);
}

.cart-drawer__item-qty {
    display: flex;
    align-items: center;
    gap: var(--space-2xs);
    margin-top: var(--space-2xs);
}

.cart-drawer__item-qty button {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--color-border);
    background: var(--color-surface-alt);
    font-size: var(--text-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-drawer__item-remove {
    color: var(--color-text-muted);
    cursor: pointer;
    padding: var(--space-3xs);
    align-self: flex-start;
    background: none;
    border: none;
}

.cart-drawer__item-remove:hover {
    color: var(--color-error);
}

/* ==========================================================================
   Notificaciones Toast
   ========================================================================== */
.toast-container {
    position: fixed;
    bottom: var(--space-md);
    right: var(--space-md);
    z-index: var(--z-toast);
    display: flex;
    flex-direction: column-reverse;
    gap: var(--space-xs);
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-sm) var(--space-md);
    background: var(--color-primary);
    color: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    font-size: var(--text-sm);
    font-weight: 500;
    pointer-events: all;
    animation: toast-in var(--transition-base) forwards;
}

.toast--success {
    background: var(--color-success);
}

.toast--error {
    background: var(--color-error);
}

.toast--removing {
    animation: toast-out var(--transition-fast) forwards;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes toast-out {
    to {
        opacity: 0;
        transform: translateY(10px) scale(0.95);
    }
}

/* ==========================================================================
   Utilidades
   ========================================================================== */
.skeleton {
    background: linear-gradient(
        90deg,
        var(--color-surface-alt) 25%,
        var(--color-border-light) 50%,
        var(--color-surface-alt) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-shimmer {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.no-scroll {
    overflow: hidden;
    padding-right: var(--scrollbar-width, 0px);
}

/* ==========================================================================
   Lazy Load - Placeholder
   ========================================================================== */
img[data-src] {
    opacity: 0;
    transition: opacity var(--transition-base);
}

img[data-src].loaded {
    opacity: 1;
}

/* ==========================================================================
   Animaciones de Entrada (para Intersection Observer)
   ========================================================================== */
.fade-up {
    opacity: 0;
    transform: translateY(24px);
    transition:
        opacity 0.6s ease-out,
        transform 0.6s ease-out;
}

.fade-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Media Queries Globales
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

@media (prefers-color-scheme: dark) {
    /* El tema ya está optimizado para modo claro.
       Para dark mode completo se necesitaría un toggle.
       Aquí se respeta la preferencia base del sistema. */
}
