/**
 * zChocolat Theme - Custom CSS
 * Child theme of Hummingbird
 */

/* Override Bootstrap primary color - Replace blue with black */
:root,
[data-bs-theme=light] {
    --bs-blue: #000;
    --bs-primary: #000;
    --bs-primary-rgb: 0, 0, 0;
    --bs-primary-text-emphasis: #000;
    --bs-primary-bg-subtle: #e9ecef;
    --bs-primary-border-subtle: #ced4da;
    --bs-link-color: #000;
    --bs-link-color-rgb: 0, 0, 0;
    --bs-link-hover-color: #333;
    --bs-link-hover-color-rgb: 51, 51, 51;
    
    /* Button primary */
    --bs-btn-bg: #000;
    --bs-btn-border-color: #000;
    --bs-btn-hover-bg: #333;
    --bs-btn-hover-border-color: #333;
    --bs-btn-active-bg: #000;
    --bs-btn-active-border-color: #000;
    --bs-btn-disabled-bg: #000;
    --bs-btn-disabled-border-color: #000;
    
    /* Dropdown active link */
    --bs-dropdown-link-active-bg: #000;
    
    /* Form check (checkboxes, radios) */
    --bs-form-check-input-checked-bg-color: #000;
    --bs-form-check-input-checked-border-color: #000;
}

/* Ensure all primary buttons use black */
.btn-primary {
    --bs-btn-color: #fff;
    --bs-btn-bg: #000;
    --bs-btn-border-color: #000;
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: #333;
    --bs-btn-hover-border-color: #333;
    --bs-btn-focus-shadow-rgb: 0, 0, 0;
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: #000;
    --bs-btn-active-border-color: #000;
    --bs-btn-disabled-color: #fff;
    --bs-btn-disabled-bg: #000;
    --bs-btn-disabled-border-color: #000;
}

/* Outline primary buttons */
.btn-outline-primary {
    --bs-btn-color: #000;
    --bs-btn-border-color: #000;
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: #000;
    --bs-btn-hover-border-color: #000;
    --bs-btn-focus-shadow-rgb: 0, 0, 0;
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: #000;
    --bs-btn-active-border-color: #000;
    --bs-btn-disabled-color: #000;
}

/* Links */
a {
    color: #000;
}

a:hover {
    color: #333;
}

/* Form controls focus */
.form-check-input:focus {
    border-color: #666;
    box-shadow: 0 0 0 0.25rem rgba(0, 0, 0, 0.25);
}

.form-check-input:checked {
    background-color: #000;
    border-color: #000;
}

.form-check-input[type=checkbox]:indeterminate {
    background-color: #000;
    border-color: #000;
}

/* Product page customizations */
.product__description-full {
    font-size: 0.95rem;
    line-height: 1.6;
    padding-right: 0.5rem;
}

.product__description-full::-webkit-scrollbar {
    width: 6px;
}

.product__description-full::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.product__description-full::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.product__description-full::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Quantity + Price row styling */
.product__quantity-price-row {
    border-top: 1px solid #e0e0e0;
    border-bottom: 1px solid #e0e0e0;
    padding: 1rem 0;
}

.product__price-display .current-price-value {
    font-weight: 600;
    color: #000;
}

/* Add to cart button */
.product__add-to-cart-button {
    transition: background-color 0.3s ease;
}

.product__add-to-cart-button:hover:not(:disabled) {
    background-color: #333 !important;
}

.product__add-to-cart-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Availability inline styling */
.product__availability-inline {
    font-size: 0.9rem;
}

.product__availability-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.product__availability-status i {
    font-size: 1.2rem;
}

/* Hide tax info */
.product-price .tax-shipping-delivery-label,
.product-tax,
.tax-label {
    display: none !important;
}

/* Footer customizations */
.footer__main {
    background-color: #000 !important;
    color: #fff !important;
}

.footer__main * {
    color: #fff !important;
}

.footer__main a {
    color: #fff !important;
}

.footer__main a:hover {
    color: #ddd !important;
}

.footer-block__title {
    display: none !important;
}

.footer-block__content {
    display: block !important;
}

.copyright {
    color: #fff !important;
    text-align: center;
    padding: 1rem 0;
    margin-top: 2rem;
    border-top: 1px solid #333;
}

/* Product images gallery customization */
/* Desktop version */
@media (min-width: 768px) {
    .product__images-desktop .product__images-wrapper {
        border: 1px solid #ddd;
    }

    .product__images-desktop .product__main-image {
        position: relative;
        border-bottom: 1px solid #ddd;
        padding: 1rem;
    }

    .product__images-desktop .product__main-image-item {
        display: none;
    }

    .product__images-desktop .product__main-image-item.active {
        display: block;
    }

    .product__images-desktop .product__main-image img {
        width: 100%;
        height: auto;
        display: block;
        cursor: default;
        pointer-events: none;
        border: none;
    }

    .product__thumbnails-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
    }

    .product__thumbnail-grid-item {
        border: none;
        border-right: 1px solid #ddd;
        border-bottom: 1px solid #ddd;
        padding: 1rem;
        background: #fff;
        cursor: pointer;
        transition: background-color 0.2s ease;
        position: relative;
        overflow: hidden;
        outline: none;
    }

    .product__thumbnail-grid-item:nth-child(2n) {
        border-right: none;
    }

    .product__thumbnail-grid-item:nth-last-child(-n+2) {
        border-bottom: none;
    }

    .product__thumbnail-grid-item:hover {
        background-color: #f5f5f5;
    }

    .product__thumbnail-grid-image {
        width: 100%;
        height: auto;
        display: block;
    }

    /* Hide zoom button and modal on desktop */
    .product__zoom,
    #product-modal {
        display: none !important;
    }

    /* Parallax effect */
    .product__left {
        position: sticky;
        top: 1rem;
        align-self: flex-start;
    }
}

/* Mobile version - keep carousel, disable zoom */
@media (max-width: 767.98px) {
    .product__images-mobile .product__carousel {
        pointer-events: none;
    }

    .product__images-mobile .carousel-control-prev,
    .product__images-mobile .carousel-control-next {
        pointer-events: auto;
    }

    .product__images-mobile img {
        cursor: default;
        pointer-events: none;
    }

    /* Hide zoom button on mobile */
    .product__zoom {
        display: none !important;
    }
}

/* Language selector customization */
.ps-languageselector--simple {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.language-link {
    text-decoration: none;
    color: #000;
    font-size: 0.9rem;
    transition: opacity 0.2s ease;
}

.language-link:hover {
    opacity: 0.7;
    text-decoration: none;
}

.language-link--active {
    font-weight: 700;
    color: #000;
    font-size: 0.9rem;
}

.language-separator {
    color: #666;
    font-size: 0.9rem;
}

/* Product page title in uppercase */
.product__name {
    text-transform: uppercase;
}

/* Hide breadcrumb everywhere (keep in DOM for SEO) */
.breadcrumb,
.breadcrumb-wrapper,
nav[aria-label="Breadcrumb"],
#wrapper .breadcrumb {
    display: none !important;
}
