/*
Theme Name: Joyeria Ellye
Theme URI: https://joyeriaellye.cl
Author: Antigravity
Description: Tema Premium Oficial. Version 2.0 (Escudo Blanco + Portada)
*/

/* Globals & Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-primary: #8a0c16;
    /* Dark red from buttons */
    --color-primary-hover: #b01826;
    --color-gold: #c6a052;
    /* Gold borders/details */
    --color-text-dark: #1f1f1f;
    --color-text-medium: #555555;
    --color-bg-light: #faf9f8;
    /* Very subtle warm off-white */
    --color-bg-alt: #f1ebe7;
    /* Light beige for services section */
    --color-white: #ffffff;
    --color-footer-bg: #291a18;
    /* Dark brown/black */
    --color-footer-text: #a89a96;

    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;

    --transition: all 0.3s ease;
}

body {
    font-family: var(--font-body);
    color: var(--color-text-medium);
    background-color: var(--color-bg-light);
    line-height: 1.6;
    overflow-x: hidden;
    max-width: 100%;
}

html {
    overflow-x: hidden;
    max-width: 100%;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    color: var(--color-text-dark);
    font-weight: 600;
}

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

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

/* --- HEADER --- */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 5%;
    background: var(--color-white);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-collapse {
    display: contents; /* Se comporta de forma invisible preservando a sus hijos en el flex de .navbar */
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-primary);
    letter-spacing: 1px;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    color: var(--color-text-medium);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding-bottom: 0.4rem;
    border-bottom: 2px solid transparent;
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links .current-menu-item > a {
    color: var(--color-primary);
    border-bottom-color: var(--color-gold);
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.search-bar {
    display: flex;
    align-items: center;
    background: var(--color-bg-light);
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    gap: 0.5rem;
    color: var(--color-text-medium);
}

.search-bar input {
    border: none;
    background: transparent;
    outline: none;
    font-family: var(--font-body);
    font-size: 0.85rem;
    width: 180px;
}

.nav-icons {
    display: flex;
    gap: 1.2rem;
    color: var(--color-primary);
}

.nav-icons a:hover {
    color: var(--color-gold);
}

/* --- HERO SECTION --- */
.hero {
    display: flex;
    min-height: 80vh;
    background: var(--color-white);
}

.hero-image {
    flex: 0 0 50%;
    width: 50%;
}

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

.hero-content {
    flex: 0 0 50%;
    width: 50%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem 6rem;
}

.hero-content h1 {
    font-size: 3.5rem;
    line-height: 1.15;
    margin-bottom: 1.5rem;
}

.hero-content p {
    font-size: 1rem;
    margin-bottom: 2.5rem;
    border-left: 3px solid var(--color-gold);
    padding-left: 1.5rem;
    max-width: 400px;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
}

.btn {
    padding: 0.8rem 2.2rem;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
    border-radius: 2px;
}

.btn-primary {
    background: var(--color-primary);
    color: var(--color-white);
    border: 2px solid var(--color-primary);
}

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

.btn-secondary {
    background: transparent;
    color: var(--color-gold);
    border: 2px solid var(--color-gold);
}

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

/* --- CATEGORIES --- */
.categories {
    padding: 5rem 5%;
    text-align: center;
    background: var(--color-white);
}

.categories h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.divider {
    width: 60px;
    height: 2px;
    background: var(--color-gold);
    margin: 0 auto 4rem;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 2rem;
}

.category-card {
    cursor: pointer;
    background: var(--color-bg-light);
    padding-bottom: 1rem;
    transition: transform 0.3s ease, box-shadow 0.3s;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.category-card img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    margin-bottom: 1rem;
}

.category-card p {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--color-text-dark);
}

/* --- SERVICES --- */
.services {
    display: flex;
    background: var(--color-white);
}

.services-content {
    flex: 1.1;
    padding: 6rem 5%;
    background: var(--color-bg-alt);
}

.section-subtitle {
    color: var(--color-primary);
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 2px;
    margin-bottom: 1rem;
}

.services-content h2 {
    font-size: 2.8rem;
    margin-bottom: 1.5rem;
}

.services-desc {
    margin-bottom: 3.5rem;
    max-width: 500px;
    font-size: 1.05rem;
}

.services-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
}

.service-item {
    display: flex;
    gap: 1.2rem;
}

.service-icon {
    color: var(--color-primary);
    background: rgba(138, 12, 22, 0.08);
    padding: 0.8rem;
    border-radius: 50%;
    height: fit-content;
}

.service-text h3 {
    font-size: 1.1rem;
    margin-bottom: 0.4rem;
}

.service-text p {
    font-size: 0.9rem;
}

.services-image {
    flex: 1;
}

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

/* --- PRODUCTS --- */
.products {
    padding: 6rem 5%;
    background: var(--color-bg-light);
}

.products-header {
    text-align: center;
    position: relative;
    margin-bottom: 4rem;
}

.products-header h2 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.view-all {
    position: absolute;
    right: 0;
    bottom: 0;
    color: var(--color-primary);
    font-weight: 600;
    font-size: 0.9rem;
}

.view-all:hover {
    color: var(--color-gold);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--color-white);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.06);
}

.product-image {
    background: var(--color-bg-light);
    aspect-ratio: 1;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 1rem;
    transition: transform 0.6s ease;
}

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

.product-info {
    padding: 1.5rem 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-info h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.product-info p {
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
    flex: 1;
}

.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

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

.cart-btn {
    background: var(--color-primary);
    color: var(--color-white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.cart-btn:hover {
    background: var(--color-primary-hover);
    transform: scale(1.05);
}

/* --- FOOTER --- */
.footer {
    background: var(--color-footer-bg);
    color: var(--color-footer-text);
    padding: 5rem 5% 2rem;
}

.footer-container {
    display: grid;
    grid-template-columns: 2fr 1.5fr 1.5fr 1.5fr;
    gap: 3rem;
    margin-bottom: 4rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--color-white);
    margin-bottom: 1.5rem;
}

.brand-col p {
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

.social-icons {
    display: flex;
    gap: 1rem;
}

.social-icons a {
    color: var(--color-white);
    background: rgba(255, 255, 255, 0.05);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.social-icons a:hover {
    background: var(--color-gold);
}

.footer-col h4 {
    color: var(--color-primary);
    font-family: var(--font-heading);
    font-size: 1rem;
    margin-bottom: 2rem;
    letter-spacing: 1px;
}

.contact-col ul {
    list-style: none;
}

.contact-col li {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.2rem;
    font-size: 0.9rem;
}

.hours-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.hours-row.closed {
    color: var(--color-primary);
}

.action-col p {
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.btn-whatsapp {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #25D366;
    color: var(--color-white);
    padding: 0.9rem 1.5rem;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.9rem;
}

.btn-whatsapp:hover {
    background: #128C7E;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.85rem;
}

/* --- RESPONSIVE --- */
@media (max-width: 1024px) {
    .navbar {
        padding: 1.5rem 5%;
    }

    .hero {
        flex-direction: column-reverse;
    }
    
    .hero-image,
    .hero-content {
        flex: auto;
        width: 100%;
    }

    .hero-content {
        padding: 4rem 5%;
        text-align: center;
        align-items: center;
    }

    .hero-content p {
        border-left: none;
        padding-left: 0;
    }

    .services {
        flex-direction: column;
    }

    .services-content {
        padding: 4rem 5%;
    }

    .footer-container {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {

    .navbar {
        justify-content: center; /* Centrar logo */
        position: relative; 
        padding: 1rem 5%;
    }

    .mobile-menu-toggle {
        display: flex !important;
        background: transparent;
        border: none;
        position: absolute;
        right: 5%;
        top: 50%;
        transform: translateY(-50%);
        cursor: pointer;
        z-index: 101;
    }

    /* Pestaña Desktop Oculta y Animable */
    .navbar-collapse {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--color-white);
        box-shadow: 0 10px 20px rgba(0,0,0,0.1);
        padding: 0 5%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease-in-out, padding 0.4s ease-in-out;
        z-index: 90;
        align-items: center;
    }

    .navbar-collapse.active {
        max-height: 500px;
        padding: 2rem 5%;
    }

    .nav-links {
        flex-direction: column;
        gap: 1.5rem;
        margin-bottom: 2rem;
    }

    .navbar-right {
        flex-direction: row;
        justify-content: center;
        width: 100%;
        gap: 1.5rem;
        padding-top: 1.5rem;
        border-top: 1px solid #eaeaea;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .footer-container {
        grid-template-columns: 1fr;
    }

    .products-header .view-all {
        position: static;
        display: block;
        margin-top: 1rem;
    }
}

/* --- PAGE HEADERS --- */
.page-header {
    background: var(--color-bg-alt);
    padding: 4rem 5% 3rem;
    text-align: center;
}

.page-header h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.breadcrumbs {
    font-size: 0.85rem;
    color: var(--color-text-medium);
}

.breadcrumbs a {
    color: var(--color-primary);
}

/* --- SHOP PAGE --- */
.shop-container {
    display: flex;
    padding: 4rem 5%;
    gap: 3rem;
    background: var(--color-bg-light);
}

.shop-sidebar {
    width: 250px;
    flex-shrink: 0;
}

.sidebar-widget {
    margin-bottom: 2.5rem;
}

.sidebar-widget h3 {
    font-size: 1.1rem;
    margin-bottom: 1.2rem;
    border-bottom: 1px solid var(--color-gold);
    padding-bottom: 0.5rem;
    display: inline-block;
}

.filter-list {
    list-style: none;
}

.filter-list li {
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 0.9rem;
}

.filter-list input[type="checkbox"] {
    accent-color: var(--color-primary);
    width: 16px;
    height: 16px;
}

.price-slider {
    width: 100%;
    margin-bottom: 1rem;
}

.shop-main {
    flex: 1;
}

.shop-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    font-size: 0.9rem;
}

.shop-toolbar select {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: var(--font-body);
}

/* --- SINGLE PRODUCT --- */
.single-product-container {
    padding: 4rem 5%;
    display: flex;
    gap: 4rem;
    background: var(--color-white);
}

.product-gallery {
    flex: 1;
}

.main-image {
    width: 100%;
    aspect-ratio: 1;
    background: var(--color-bg-light);
    object-fit: contain;
    padding: 2rem;
    margin-bottom: 1rem;
}

.thumbnail-images {
    display: flex;
    gap: 1rem;
}

.thumbnail-images img {
    width: 80px;
    height: 80px;
    background: var(--color-bg-light);
    object-fit: cover;
    cursor: pointer;
    border: 2px solid transparent;
}

.thumbnail-images img.active {
    border-color: var(--color-primary);
}

.product-details {
    flex: 1;
}

.product-details h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.product-details .price {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    display: block;
    color: var(--color-primary);
    font-weight: 700;
}

.product-details .desc {
    margin-bottom: 2rem;
}

.product-variants {
    margin-bottom: 2rem;
}

.product-variants label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.product-variants select {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    margin-bottom: 1rem;
}

.add-to-cart-wrapper {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.quantity-input {
    width: 70px;
    padding: 0.8rem;
    text-align: center;
    border: 1px solid #ddd;
}

.btn-add-cart {
    flex: 1;
    background: var(--color-primary);
    color: var(--color-white);
    border: none;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: var(--transition);
}

.btn-add-cart:hover {
    background: var(--color-gold);
}

.product-meta {
    border-top: 1px solid #eee;
    padding-top: 1.5rem;
    font-size: 0.85rem;
    color: var(--color-text-medium);
}

.product-meta span {
    color: var(--color-text-dark);
    font-weight: 600;
}

.product-tabs {
    padding: 0 5% 4rem;
    background: var(--color-white);
}

.tab-headers {
    display: flex;
    gap: 2rem;
    border-bottom: 1px solid #ddd;
    margin-bottom: 2rem;
}

.tab-header {
    padding: 1rem 0;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    color: var(--color-text-medium);
}

.tab-header.active {
    color: var(--color-primary);
}

.tab-header.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--color-primary);
}

/* --- CART PAGE --- */
.cart-container {
    padding: 5rem 5%;
    display: flex;
    gap: 4rem;
    background: var(--color-bg-light);
}

.cart-table-wrapper {
    flex: 2;
}

.cart-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--color-white);
}

.cart-table th {
    text-align: left;
    padding: 1.5rem 1rem;
    background: var(--color-bg-alt);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
}

.cart-table td {
    padding: 1.5rem 1rem;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

.cart-item-info {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.cart-item-info img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    background: #f5f5f5;
    padding: 0.5rem;
}

.cart-remove {
    color: #999;
    cursor: pointer;
    font-size: 1.2rem;
}

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

.cart-summary {
    flex: 1;
    background: var(--color-white);
    padding: 2.5rem;
    height: fit-content;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.04);
}

.cart-summary h3 {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.95rem;
    color: var(--color-text-medium);
}

.summary-total {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 2rem;
}

.btn-checkout {
    display: block;
    width: 100%;
    padding: 1rem;
    text-align: center;
    background: var(--color-primary);
    color: var(--color-white);
    font-weight: 600;
    text-transform: uppercase;
    transition: var(--transition);
}

.btn-checkout:hover {
    background: var(--color-gold);
}

/* --- ABOUT & FORMS --- */
.page-container {
    padding: 4rem 5%;
    max-width: 800px;
    margin: 0 auto;
    background: var(--color-white);
}

.contact-form {
    margin-top: 3rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group.full {
    grid-column: 1 / -1;
}

.contact-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
    font-weight: 600;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #ddd;
    outline: none;
    font-family: var(--font-body);
    transition: border-color 0.3s;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--color-gold);
}

.btn-submit {
    grid-column: 1 / -1;
    padding: 1rem;
    background: var(--color-primary);
    color: white;
    border: none;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-submit:hover {
    background: var(--color-gold);
}

/* Responsive Extensions */
@media (max-width: 1024px) {

    .shop-container,
    .single-product-container,
    .cart-container {
        flex-direction: column;
    }

    .shop-sidebar {
        width: 100%;
    }
}

/* =========================================================
   DISEÑO DEFINITIVO - LA MATEMÁTICA DEL ESCUDO BLANCO
========================================================= */

/* 1. GRID PERFECTO (Aplica en Tienda y en Shortcodes de Portada) */
.woocommerce ul.products {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) !important;
    gap: 30px !important;
}

/* 2. TARJETAS COMPACTAS (430px) */
.woocommerce ul.products li.product {
    width: 100% !important;
    max-width: 100% !important;
    height: 430px !important;
    background: #ffffff !important;
    border-radius: 6px !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06) !important;
    padding: 0 !important;
    margin: 0 !important;
    position: relative !important;
    border: none !important;
    overflow: hidden !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
}

.woocommerce ul.products[class*="columns-"] li.product {
    width: 100% !important;
    margin: 0 !important;
}

.woocommerce ul.products li.product:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12) !important;
}

/* ========================================= */
/* EL TRUCO MAGISTRAL: EL ESCUDO BLANCO  */
/* ========================================= */
.woocommerce ul.products li.product::after {
    content: "" !important;
    position: absolute !important;
    top: 280px !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: #ffffff !important;
    z-index: 2 !important;
    pointer-events: none !important;
}

/* 3. LIBERACIÓN DEL ENLACE */
.woocommerce ul.products li.product a.woocommerce-LoopProduct-link {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    background: transparent !important;
    overflow: visible !important;
    position: static !important;
}

/* 4. LA FOTO EDGE-TO-EDGE INAMOVIBLE */
.woocommerce ul.products li.product a.woocommerce-LoopProduct-link img {
    height: 280px !important;
    width: 100% !important;
    object-fit: cover !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    mix-blend-mode: normal !important;
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
    margin: 0 !important;
    background: transparent !important;
    position: relative !important;
    z-index: 1 !important;
}

.woocommerce ul.products li.product:hover a.woocommerce-LoopProduct-link img {
    transform: scale(1.15) !important;
}

/* 5. TÍTULO ASENTADO */
.woocommerce ul.products li.product h2.woocommerce-loop-product__title,
.woocommerce ul.products li.product .woocommerce-loop-product__title {
    position: relative !important;
    font-size: 1.15rem !important;
    font-family: 'Playfair Display', serif !important;
    color: #1a1a1a !important;
    line-height: 1.3 !important;
    padding: 25px 20px 0 20px !important;
    margin: 0 !important;
    text-align: left !important;
    z-index: 5 !important;
    display: block !important;
}

/* 6. PRECIO */
.woocommerce ul.products li.product .price {
    position: absolute !important;
    bottom: 25px !important;
    left: 1.5rem !important;
    font-size: 1.25rem !important;
    color: #6a1a2e !important;
    font-weight: 600 !important;
    padding: 0 !important;
    margin: 0 !important;
    z-index: 5 !important;
}

/* 7. BOTÓN DORADO */
.woocommerce ul.products li.product .add_to_cart_button,
.woocommerce ul.products li.product .ajax_add_to_cart {
    position: absolute !important;
    bottom: 20px !important;
    right: 1.5rem !important;
    width: 45px !important;
    height: 45px !important;
    border-radius: 50% !important;
    background-color: transparent !important;
    border: 2px solid #d4af37 !important;
    color: transparent !important;
    font-size: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    display: block !important;
    transition: all 0.3s ease !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='%23d4af37' stroke-width='2'%3E%3Ccircle cx='9' cy='21' r='1'/%3E%3Ccircle cx='20' cy='21' r='1'/%3E%3Cpath d='M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    z-index: 10 !important;
}

.woocommerce ul.products li.product .add_to_cart_button:hover,
.woocommerce ul.products li.product .ajax_add_to_cart:hover {
    background-color: #d4af37 !important;
    transform: scale(1.1) !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2'%3E%3Ccircle cx='9' cy='21' r='1'/%3E%3Ccircle cx='20' cy='21' r='1'/%3E%3Cpath d='M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6'/%3E%3C/svg%3E") !important;
}

/* FIX ESPACIOS FANTASMAS WOOCOMMERCE */
.woocommerce ul.products::before,
.woocommerce ul.products::after {
    display: none !important;
}

/* FIX ICONOS DE SERVICIO (Perfectamente Redondos y Centrados) */
.service-icon {
    width: 60px !important;
    height: 60px !important;
    padding: 0 !important;
    border-radius: 50% !important;
    flex-shrink: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* PUNTAS REDONDAS PARA LAS CATEGORIAS */
.category-card {
    border-radius: 12px !important;
    overflow: hidden !important;
}

/* ========================================= */
/* CARRUSEL DINÁMICO EN PORTADA (OVERRIDE GRID) */
/* ========================================= */
.slider-carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    min-width: 0;
}

.dynamic-home-shop > .woocommerce {
    width: 100%;
    min-width: 0;
}

.dynamic-home-shop .woocommerce ul.products {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory;
    gap: 2rem !important;
    padding: 1rem 0 2rem !important;
    margin: 0 !important;
    position: relative;
    -webkit-overflow-scrolling: touch; /* Suavidad en iOS */
    
    /* Ocultar Barra de Desplazamiento por Estética */
    scrollbar-width: none;
    -ms-overflow-style: none; /* IE/Edge */
}

/* Chrome/Safari/Edge Scrollbar Invisible */
.dynamic-home-shop .woocommerce ul.products::-webkit-scrollbar {
    display: none; 
}

.dynamic-home-shop .woocommerce ul.products li.product {
    flex: 0 0 calc(25% - 1.5rem) !important;
    width: calc(25% - 1.5rem) !important;
    max-width: 250px !important; /* Igual que el desplazamiento JS */
    scroll-snap-align: start;
}

/* Botones laterales del carrusel */
.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: var(--color-white);
    border: 1px solid var(--color-gold);
    color: var(--color-gold);
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.slider-arrow:hover {
    background: var(--color-gold);
    color: var(--color-white);
    transform: translateY(-50%) scale(1.1);
}

.slider-prev {
    left: -22px;
}

.slider-next {
    right: -22px;
}

/* Media Queries Carrusel */
@media (max-width: 1024px) {
    .dynamic-home-shop .woocommerce ul.products li.product {
        flex: 0 0 calc(33.333% - 1.5rem) !important;
        width: calc(33.333% - 1.5rem) !important;
    }
}
@media (max-width: 768px) {
    .dynamic-home-shop .woocommerce ul.products li.product {
        flex: 0 0 calc(50% - 1.5rem) !important;
        width: calc(50% - 1.5rem) !important;
    }
    .slider-arrow {
        display: none !important; /* Swipe táctil en móviles */
    }
    .dynamic-home-shop .woocommerce ul.products {
        padding: 1rem 5% 2rem !important;
    }
}
@media (max-width: 480px) {
    .dynamic-home-shop .woocommerce ul.products li.product {
        flex: 0 0 calc(85% - 1.5rem) !important;
        width: calc(85% - 1.5rem) !important;
    }
}