/* ==========================================================================
   WP Catalog - Single Product Styles
   ========================================================================== */

/* ---------- Force Full Width (Override theme sidebar) ---------- */
.wpc-single-product {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 16px 60px;
}

/* Hide theme sidebar and page headers on single product */
body.single-wpc_product .widget-area,
body.single-wpc_product #secondary,
body.single-wpc_product .sidebar,
body.single-wpc_product .page-header,
body.single-wpc_product .entry-header,
body.single-wpc_product .page-title-area,
body.single-wpc_product .site-breadcrumbs {
    display: none !important;
}

body.single-wpc_product #primary,
body.single-wpc_product .content-area,
body.single-wpc_product .site-main {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* ---------- Product Layout (2:1 ratio - Gallery:Info) ---------- */
.wpc-product-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    align-items: start;
    margin-top: 20px;
}

/* ---------- Gallery Column ---------- */
.wpc-gallery-column {
    position: sticky;
    top: 20px;
}

.wpc-main-image {
    width: 100%;
    border-radius: 8px;
    overflow: hidden;
    background: #f5f5f5;
    margin-bottom: 12px;
}

.wpc-main-image img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
    transition: opacity 0.3s ease;
}

/* ---------- Thumbnails ---------- */
.wpc-thumbnails {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 4px 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #ccc transparent;
}

.wpc-thumbnails::-webkit-scrollbar {
    height: 4px;
}

.wpc-thumbnails::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 2px;
}

.wpc-thumb {
    flex-shrink: 0;
    width: 72px;
    height: 72px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.2s ease, opacity 0.2s ease;
    opacity: 0.6;
}

.wpc-thumb:hover {
    opacity: 0.85;
}

.wpc-thumb.active {
    border-color: #222;
    opacity: 1;
}

.wpc-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ---------- Info Column ---------- */
.wpc-info-column {
    padding-top: 4px;
}

.wpc-product-name {
    font-size: 24px;
    font-weight: 700;
    color: #111;
    margin: 0 0 12px;
    line-height: 1.3;
    letter-spacing: -0.3px;
}

.wpc-product-price-single {
    font-size: 22px;
    font-weight: 800;
    color: var(--wpc-price-color, #e74c3c);
    margin-bottom: 20px;
    letter-spacing: -0.2px;
}

/* ---------- Description ---------- */
.wpc-product-description {
    font-size: 14px;
    line-height: 1.7;
    color: #444;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #eee;
}

.wpc-product-description p {
    margin-bottom: 12px;
}

.wpc-product-description p:last-child {
    margin-bottom: 0;
}

/* ---------- Specs Table ---------- */
.wpc-specs-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
    font-size: 14px;
}

.wpc-specs-table th,
.wpc-specs-table td {
    padding: 10px 14px;
    text-align: left;
    border-bottom: 1px solid #f0f0f0;
}

.wpc-specs-table th {
    font-weight: 600;
    color: #333;
    width: 35%;
    background: #fafafa;
    border-radius: 4px 0 0 4px;
}

.wpc-specs-table td {
    color: #555;
}

.wpc-specs-table tr:last-child th,
.wpc-specs-table tr:last-child td {
    border-bottom: none;
}

/* ---------- Single Product Checkout Button ---------- */
.wpc-checkout-btn-single {
    display: flex;
    width: 100%;
    padding: 14px 20px;
    margin-top: 8px;
    font-size: 15px;
    border-radius: 8px;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    .wpc-product-layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .wpc-gallery-column {
        position: static;
    }

    .wpc-product-name {
        font-size: 20px;
    }

    .wpc-product-price-single {
        font-size: 18px;
    }

    .wpc-thumb {
        width: 56px;
        height: 56px;
    }

    .wpc-specs-table th,
    .wpc-specs-table td {
        padding: 8px 10px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .wpc-single-product {
        padding: 12px 8px 40px;
    }

    .wpc-product-layout {
        gap: 16px;
    }

    .wpc-thumb {
        width: 48px;
        height: 48px;
    }
}
