/* Single Product Page Styles */

/* Base Layout tweaks */
.woocommerce-product-gallery {
    margin-bottom: 2rem;
}

.product-card.summary {
    display: flex;
    flex-direction: column;
}

/* Title & Typography */
.product_title {
    font-size: 24px;
    font-weight: 300;
    text-transform: uppercase;
    line-height: 1.3;
    margin: 0 0 10px 0;
    color: #111;
}

/* Rating */
.woocommerce-product-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
    font-size: 14px;
    color: #777;
}

/* Price */
.product-card .price {
    font-size: 22px;
    font-weight: 700;
    color: #111;
    margin-bottom: 20px;
}

/* Vendor and SKU Pills */
.vendor-sku {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-bottom: 20px;
}

.product-sku,
.product-vendor {
    margin: 0;
    padding: 6px 14px;
    font-size: 13px;
    color: #555;
    border: 1px solid #e0cde6;
    border-radius: 6px;
    background-color: #fff;
    width: max-content;
}

.product-vendor a {
    color: #b969dd;
    text-decoration: none;
    font-weight: 500;
}
.product-vendor a:hover {
    text-decoration: underline;
}

/* Divider */
.komilfo-product-divider {
    border: 0;
    height: 1px;
    background-color: #eaeaea;
    margin: 20px 0;
    width: 100%;
}

/* Short Description */
.woocommerce-product-details__short-description {
    font-size: 14px;
    line-height: 1.6;
    color: #444;
}

/* Add to Cart Form Layout */
.cart {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 15px;
    margin-top: 25px;
    margin-bottom: 20px;
}

/* Wishlist icon placeholder (assumes plugin wraps in a container) */
.komilfo-wishlist-link {
    /* From components.css */
    flex-shrink: 0;
}
.yith-wcwl-add-to-wishlist {
    margin: 0;
}

/* Quantity input */
.quantity {
    display: flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
    height: 44px;
}

.quantity input[type="number"] {
    width: 50px;
    height: 100%;
    border: none;
    text-align: center;
    font-size: 15px;
    padding: 0;
    appearance: textfield;
}

.quantity input[type="number"]::-webkit-outer-spin-button,
.quantity input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.quantity .qty-btn {
    width: 32px;
    height: 100%;
    background: #f9f9f9;
    border: none;
    cursor: pointer;
    font-size: 16px;
    color: #555;
    transition: background 0.2s;
}

.quantity .qty-btn:hover {
    background: #eee;
}

/* Add to cart Button */
.single_add_to_cart_button {
    flex: 1;
    min-width: 200px;
    background-color: #000;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0 20px;
    height: 44px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.2s;
}

.single_add_to_cart_button:hover {
    background-color: #333;
}

/* Stock Status */
.stock-status {
    width: 100%;
    padding: 12px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 20px;
    box-sizing: border-box;
}

.stock-status.in-stock {
    background-color: #84bd7a;
    color: #fff;
}

.stock-status.out-of-stock {
    background-color: #e57373;
    color: #fff;
}

/* Category & Meta */
.product_meta {
    font-size: 13px;
    color: #666;
}

.product-category a {
    color: #b969dd;
    text-decoration: none;
}
.product-category a:hover {
    text-decoration: underline;
}

@media (max-width: 767px) {
    .cart {
        flex-direction: column;
        align-items: stretch;
    }
    .quantity {
        justify-content: center;
    }
    .single_add_to_cart_button {
        width: 100%;
    }
}

/* ===========================
   Related Products Slider
   =========================== */

/* Hide default WooCommerce related heading (we use our own) */
section.related.products {
    display: none !important;
}

.komilfo-related {
    position: relative;
    margin: 50px 0 30px;
    padding: 0;
    font-family: 'Roboto', Arial, sans-serif;
}

.komilfo-related__title {
    font-size: 18px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #111;
    margin: 0 0 24px;
    text-align: center;
}

.komilfo-related__viewport {
    overflow: hidden;
    margin: 0 -8px;
}

.komilfo-related__track {
    display: flex;
    gap: 16px;
    transition: transform .4s cubic-bezier(.4, 0, .2, 1);
    padding: 4px 8px;
}

.komilfo-related__slide {
    flex: 0 0 calc(25% - 12px);
    min-width: 0;
}

.komilfo-related__slide .komilfo-product-card--archive {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #fff;
    box-shadow: 0 4px 18px rgba(0, 0, 0, .06);
    padding: 1rem 1rem 1.25rem;
}

.komilfo-related__slide .komilfo-product-card__image img {
    width: 100%;
    height: auto;
    display: block;
}

.komilfo-related__slide .komilfo-product-card__title {
    margin: 0 0 .35rem;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.4;
}

.komilfo-related__slide .komilfo-product-card__title a {
    color: #b969dd;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.komilfo-related__slide .komilfo-product-card__title a:hover {
    color: #9a4fc4;
}

.komilfo-related__slide .komilfo-product-card__sku {
    margin: 0 0 .5rem;
    font-size: 12px;
    color: #999;
}

.komilfo-related__slide .komilfo-product-card__price {
    margin: 0 0 1rem;
    font-size: 18px;
    font-weight: 700;
    color: #000;
}

.komilfo-related__slide .komilfo-product-card__price del {
    color: #999;
    font-size: 14px;
    font-weight: 400;
}

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

.komilfo-related__slide .button,
.komilfo-related__slide .add_to_cart_button {
    display: block;
    width: 100%;
    margin: auto 0 0;
    padding: 12px 16px;
    border: 0;
    border-radius: 0;
    background: #000 !important;
    color: #fff !important;
    font-size: 13px;
    font-weight: 500;
    text-align: center;
    text-transform: none;
    letter-spacing: 0;
    line-height: 1.2;
    cursor: pointer;
    text-decoration: none;
}

.komilfo-related__slide .button:hover,
.komilfo-related__slide .add_to_cart_button:hover {
    background: #222 !important;
}

/* Slider arrows */
.komilfo-related__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: #fff;
    color: #333;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
    transition: all .2s ease;
    z-index: 5;
}

.komilfo-related__arrow:hover {
    background: #000;
    color: #fff;
    border-color: #000;
}

.komilfo-related__arrow--prev {
    left: -16px;
}

.komilfo-related__arrow--next {
    right: -16px;
}

.komilfo-related__arrow:disabled {
    opacity: .3;
    cursor: default;
    pointer-events: none;
}

/* Responsive */
@media (max-width: 1024px) {
    .komilfo-related__slide {
        flex: 0 0 calc(33.333% - 11px);
    }
    .komilfo-related__arrow--prev { left: -8px; }
    .komilfo-related__arrow--next { right: -8px; }
}

@media (max-width: 767px) {
    .komilfo-related__slide {
        flex: 0 0 calc(50% - 8px);
    }
    .komilfo-related__arrow {
        width: 34px;
        height: 34px;
        font-size: 12px;
    }
    .komilfo-related__arrow--prev { left: -4px; }
    .komilfo-related__arrow--next { right: -4px; }
}

@media (max-width: 480px) {
    .komilfo-related__slide {
        flex: 0 0 calc(100% - 0px);
    }
}
