/**
 * Danixel Hood - Article Styles (Product Page)
 * Art Gallery Theme
 */

/* Breadcrumb */
.breadcrumb {
    background: var(--color-cream);
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--color-border);
}

.breadcrumb-list {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--color-text-muted);
}

.breadcrumb-list li:not(:last-child)::after {
    content: '/';
    margin-left: 0.5rem;
    color: var(--color-border);
}

.breadcrumb-list a {
    color: var(--color-charcoal);
    transition: color 0.3s;
}

.breadcrumb-list a:hover {
    color: var(--color-gold);
}

/* Product Detail */
.product-detail {
    padding: var(--space-xl) 0;
    background: var(--color-warm-white);
}

.product-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xxl);
    align-items: start;
}

/* Product Images */
.product-images {
    position: sticky;
    top: calc(var(--header-height) + var(--space-lg));
}

.image-gallery {
    position: relative;
    background: var(--color-cream);
    margin-bottom: var(--space-sm);
}

.gallery-slide {
    display: none;
    aspect-ratio: 3/4;
}

.gallery-slide.is-active {
    display: block;
}

.gallery-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.image-thumbs {
    display: flex;
    gap: var(--space-xs);
    justify-content: center;
}

.thumb-btn {
    width: 80px;
    height: 80px;
    border: 2px solid transparent;
    background: var(--color-cream);
    cursor: pointer;
    padding: 0;
    overflow: hidden;
    transition: border-color 0.3s;
}

.thumb-btn.is-active {
    border-color: var(--color-gold);
}

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

/* Product Info */
.product-info {
    padding-top: var(--space-sm);
}

.product-title {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    margin-bottom: var(--space-md);
    color: var(--color-deep-brown);
    line-height: 1.2;
}

.product-price {
    margin-bottom: var(--space-lg);
}

.price-current {
    font-size: 1.75rem;
    font-weight: 500;
    color: var(--color-gold);
}

.price-original {
    font-size: 1.25rem;
    color: var(--color-text-muted);
    text-decoration: line-through;
    margin-right: var(--space-sm);
}

.price-sale {
    color: var(--color-terracotta);
}

.product-description {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--color-text-muted);
    margin-bottom: var(--space-lg);
}

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

/* Product Actions */
.product-actions {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
    padding: var(--space-md) 0;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
}

.quantity-selector {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.quantity-label {
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.quantity-input-wrapper {
    display: flex;
    align-items: center;
    border: 1px solid var(--color-border);
    width: fit-content;
}

.quantity-btn {
    width: 44px;
    height: 44px;
    background: var(--color-cream);
    border: none;
    font-size: 1.25rem;
    cursor: pointer;
    transition: background 0.3s;
}

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

.quantity-input {
    width: 60px;
    height: 44px;
    border: none;
    text-align: center;
    font-family: var(--font-sans);
    font-size: 1rem;
    -moz-appearance: textfield;
}

.quantity-input::-webkit-outer-spin-button,
.quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.btn-add-cart {
    padding: 1.25rem 3rem;
    background: var(--color-gold);
    color: white;
    border: none;
    font-family: var(--font-sans);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: background 0.3s;
}

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

/* Product Meta */
.product-meta {
    margin-bottom: var(--space-lg);
}

.meta-item {
    display: flex;
    gap: var(--space-sm);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.meta-label {
    color: var(--color-text-muted);
}

.meta-value {
    color: var(--color-charcoal);
}

.meta-value.in-stock {
    color: var(--color-sage);
}

.meta-value.out-of-stock {
    color: var(--color-terracotta);
}

/* Trust Badges */
.trust-badges {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.badge {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

.badge-icon {
    color: var(--color-gold);
    font-size: 1rem;
}

/* Tabs Section */
.product-tabs-section {
    background: var(--color-cream);
    padding: var(--space-xl) 0;
}

.tabs {
    max-width: 800px;
    margin: 0 auto;
}

.tab-buttons {
    display: flex;
    border-bottom: 1px solid var(--color-border);
    margin-bottom: var(--space-lg);
}

.tab-btn {
    padding: var(--space-sm) var(--space-md);
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    font-family: var(--font-sans);
    font-size: 0.95rem;
    color: var(--color-text-muted);
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: -1px;
}

.tab-btn.is-active {
    color: var(--color-charcoal);
    border-bottom-color: var(--color-gold);
}

.tab-panel {
    display: none;
    animation: fadeIn 0.3s;
}

.tab-panel.is-active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.tab-panel h3 {
    font-size: 1.25rem;
    margin-bottom: var(--space-md);
    color: var(--color-deep-brown);
}

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

.details-list li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
}

.details-list li:last-child {
    border-bottom: none;
}

.details-list strong {
    color: var(--color-charcoal);
    display: inline-block;
    min-width: 150px;
}

/* Related Section */
.related-section {
    background: var(--color-warm-white);
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-md);
    margin-top: var(--space-xl);
}

.related-card a {
    display: block;
}

.related-image {
    aspect-ratio: 3/4;
    overflow: hidden;
    background: var(--color-cream);
    margin-bottom: var(--space-sm);
}

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

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

.related-title {
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 0.25rem;
    color: var(--color-charcoal);
}

.related-price {
    font-size: 0.95rem;
    color: var(--color-gold);
}

/* Cart Modal */
.cart-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
}

.cart-modal.is-open {
    display: flex;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
}

.modal-content {
    position: relative;
    background: var(--color-warm-white);
    padding: var(--space-xl);
    max-width: 500px;
    width: 90%;
    text-align: center;
    z-index: 1;
}

.modal-close {
    position: absolute;
    top: var(--space-sm);
    right: var(--space-sm);
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--color-text-muted);
}

.modal-icon {
    font-size: 3rem;
    color: var(--color-sage);
    margin-bottom: var(--space-sm);
}

.modal-content h3 {
    font-size: 1.5rem;
    margin-bottom: var(--space-sm);
    color: var(--color-deep-brown);
}

.modal-content p {
    color: var(--color-text-muted);
    margin-bottom: var(--space-lg);
}

.modal-actions {
    display: flex;
    gap: var(--space-sm);
    justify-content: center;
}

/* Responsive */
@media (max-width: 1024px) {
    .product-grid {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }
    
    .product-images {
        position: relative;
        top: 0;
    }
    
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .tab-buttons {
        flex-wrap: wrap;
    }
    
    .tab-btn {
        flex: 1;
        min-width: 100px;
    }
    
    .related-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-actions {
        flex-direction: column;
    }
}
