/* Estilos generales */
.bodyWrapper {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Segoe UI', Roboto, sans-serif;
    color: #333;
}

/* Hero del producto */
.productHeroD {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.productGallery {
    display: flex;
    gap: 20px;
}

.mainImage {
    flex: 1; 
    border-radius: 8px;
    overflow: hidden;
}

.mainImage img {
    width: 100%;
    height: auto;
    display: block;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.thumbnailContainer {
    width: 80px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.thumbnail {
    width: 100%;
    aspect-ratio: 1/1.5;
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
}

.thumbnail.active {
    border-color: #e52922;
}

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

/* Información del producto */
.productInfo {
    padding: 20px 0;
}

.breadcrumbs {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
}

.breadcrumbs a {
    color: #e52922;
    text-decoration: none;
}

.productTitle {
    font-size: 32px;
    font-weight: 700;
    margin: 0 0 15px;
    color: #222;
}

.productMeta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.productCode {
    font-size: 14px;
    color: #666;
}

.rating {
    display: flex;
    align-items: center;
    gap: 5px;
}

.stars {
    color: #ffc107;
    font-size: 18px;
}

.star.filled {
    color: #ffc107;
}

.star:not(.filled) {
    color: #ddd;
}

.reviewCount {
    font-size: 14px;
    color: #666;
}

.productDescription {
    margin-bottom: 30px;
}

.productDescription h3 {
    font-size: 18px;
    margin-bottom: 10px;
}

.productDescription p {
    line-height: 1.6;
    color: #555;
}

/* Acciones del producto */
.productActions {
    background: #f9f9f9;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.priceContainer {
    margin-bottom: 20px;
}

.price {
    font-size: 28px;
    font-weight: 700;
    color: #e52922;
}

.oldPrice {
    font-size: 18px;
    color: #999;
    text-decoration: line-through;
    margin-left: 10px;
}

.quantitySelector {
    margin-bottom: 20px;
}

.quantitySelector label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.quantityInput {
    display: flex;
    align-items: center;
    gap: 10px;
}

.qtyBtn {
    width: 36px;
    height: 36px;
    border: 1px solid #ddd;
    background: #fff;
    font-size: 16px;
    cursor: pointer;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qtyBtn:hover {
    background: #f0f0f0;
}

#txtQuantity {
    width: 60px;
    height: 36px;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.addToCartBtn {
    width: 100%;
    padding: 12px;
    background: #e52922;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
    transition: background 0.2s;
}

.addToCartBtn:hover {
    background: #c0211c;
}

.cartIcon {
    width: 20px;
    height: 20px;
    fill: white;
}

.wishlistBtn {
display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    padding: 10px;
    background: #000;
    border: 0;
    border-radius: 3px;
}
.modalD{
    display: none;
    position: fixed;
    background: #0000006e;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    z-index: 999999;
}
.modalContent{
    display: block;
}
.heartIcon {
    width: 18px;
    height: 18px;
        fill: #fff;
}

.wishlistBtn:hover {
    color: #fff;
}

.wishlistBtn:hover .heartIcon {
    fill: #ff6b6b;
}

/* Detalles del producto */
.productDetails {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 30px;
}

.detailItem {
    padding: 15px;
    background: #f9f9f9;
    border-radius: 6px;
}

.detailItem h4 {
    font-size: 14px;
    margin: 0 0 5px;
    color: #666;
    font-weight: 500;
}

.detailItem p {
    margin: 0;
    font-size: 16px;
}

/* Tabs */
.productTabs {
    margin-bottom: 60px;
}

.tabsHeader {
    display: flex;
    border-bottom: 1px solid #ddd;
    margin-bottom: 20px;
}

.tabBtn {
    padding: 12px 20px;
    background: none;
    border: none;
    font-size: 16px;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    position: relative;
}

.tabBtn.active {
    color: #e52922;
}

.tabBtn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e52922;
}

.tabPane {
    display: none;
    padding: 20px;
    line-height: 1.6;
}

.tabPane.active {
    display: block;
}

.detailsGrid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.detailRow {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.detailLabel {
    font-weight: 500;
    color: #666;
}

.detailValue {
    color: #333;
}

/* Productos relacionados */
.relatedSection {
    margin-bottom: 60px;
}

.sectionTitle {
    font-size: 24px;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.relatedGrid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 25px;
}

.relatedItem {
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
}

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

.relatedImage {
    position: relative;
    aspect-ratio: 1/1.5;
    background: #f8f8f8;
    overflow: hidden;
}

.relatedImage img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.relatedItem:hover .relatedImage img {
    transform: scale(1.03);
}

.quickView {
    position: absolute;
    bottom: -40px;
    left: 0;
    right: 0;
    background: rgba(0,0,0,0.7);
    color: white;
    text-align: center;
    padding: 8px;
    font-size: 14px;
    transition: bottom 0.2s;
}

.relatedItem:hover .quickView {
    bottom: 0;
}

.relatedInfo {
    padding: 15px;
    text-align: center;
}

.relatedTitle {
    font-size: 16px;
    margin: 0 0 10px;
    font-weight: 600;
    color: #333;
}

.relatedPrice {
    font-size: 18px;
    font-weight: 700;
    color: #e52922;
    margin-bottom: 10px;
}

.relatedLink {
    display: inline-block;
    color: #e52922;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
}

.relatedLink:hover {
    text-decoration: underline;
    color: #bd201a;
}
 

.modalContent {
    background: white;
    border-radius: 8px;
    width: 100%;
    max-width: 500px;
    overflow: hidden;
    animation: modalFadeIn 0.3s;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

.closeModal {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    color: #666;
    cursor: pointer;
}

.closeModal:hover {
    color: #333;
}

.modalHeader {
    padding: 20px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

.modalIcon {
    width: 50px;
    height: 50px;
    margin-bottom: 15px;
}

.modalIcon.success {
    fill: #4CAF50;
}

.modalBody {
    padding: 20px;
    text-align: center;
}

.modalBody h2 {
    margin: 0 0 10px;
}

.modalBody p {
    color: #666;
    margin-bottom: 20px;
}

.modalFooter {
    display: flex;
    padding: 15px;
    border-top: 1px solid #eee;
    gap: 10px;
}

.modalBtn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    background: #e52922;
    color: white;
    text-align: center;
}

.modalBtn.outline {
    background: white;
    border: 1px solid #e52922;
    color: #e52922;
}

.modalBtn:hover {
    opacity: 0.9;
}

/* Carrito modal */
.cartModal {
    max-width: 600px;
}

.cartProduct {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 20px;
}

.cartProductImage {
    width: 80px;
    height: 120px;
    background: #f8f8f8;
    border-radius: 4px;
    overflow: hidden;
}

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

.cartProductInfo {
    flex: 1;
}

.cartProductInfo h3 {
    margin: 0 0 10px;
    font-size: 18px;
}

.cartProductMeta {
    display: flex;
    gap: 20px;
}

.cartProductQty, .cartProductPrice {
   font-size: 22px;
    font-weight: bold;
}

.cartProductQty span:first-child, 
.cartProductPrice span:first-child {
    color: #666;
    margin-right: 5px;
}

/* Responsive */
@media (max-width: 768px) {
    .productHeroD {
        grid-template-columns: 1fr;
    }
    
    .productGallery {
        flex-direction: column-reverse;
    }
    
    .thumbnailContainer {
        width: 100%;
        flex-direction: row;
        order: 1;
    }
    
    .thumbnail {
        width: 60px;
        height: 90px;
    }
    
    .detailsGrid {
        grid-template-columns: 1fr;
    }
    
    .productDetails {
        grid-template-columns: 1fr;
    }
    
    .modalFooter {
        flex-direction: column;
    }
}