/**
 * Product Single Page Styles
 * BitsyBows Theme – Updated for full-width description
 */

/* ==========================
   Brand Colors
=========================== */
:root {
    --bb-orange: #ff6600;
    --bb-orange-hover: #e65c00;
    --bb-orange-light: #fffaf7;
    --bb-border: #ddd;
    --bb-text: #333;
    --bb-text-light: #666;
}

/* ==========================
   Outer Container
=========================== */
.product-page {
    width: 80%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    box-sizing: border-box;
    font-family: inherit;
}

/* ==========================
   Product Container (Two Columns)
=========================== */
.product-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
    border: 1px solid var(--bb-border);
    padding: 25px;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    box-sizing: border-box;
}

/* ==========================
   Left Column: Product Images
=========================== */
.product-images {
    display: flex;
    flex-direction: column;
}

.main-image {
    width: 100%;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--bb-border);
    padding: 5px;
    margin-bottom: 15px;
    transition: box-shadow 0.3s ease;
}

.main-image:hover {
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
}

.main-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.main-image img:hover {
    transform: scale(1.02);
}

/* Thumbnail Gallery */
.thumbnail-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 5px;
    scrollbar-width: thin;
}

.thumbnail-scroll::-webkit-scrollbar {
    height: 6px;
}

.thumbnail-scroll::-webkit-scrollbar-thumb {
    background: var(--bb-orange-light);
    border-radius: 3px;
}

.thumbnail-scroll img {
    width: 24%;
    max-width: 100px;
    min-width: 60px;
    height: 80px;
    object-fit: cover;
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 4px;
    opacity: 0.75;
    transition: all 0.2s ease;
}

.thumbnail-scroll img:hover,
.thumbnail-scroll img.active {
    opacity: 1;
    border-color: var(--bb-orange);
    transform: scale(1.05);
}

/* ==========================
   Right Column: Product Details
=========================== */
.product-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
    justify-content: flex-start;
}

.product-details h1 {
    font-size: 2.2em;
    margin: 0 0 16px;
    color: var(--bb-text);
    font-weight: 600;
    line-height: 1.2;
}

/* Text Styling */
.product-price,
.product-sku,
.product-stock {
    margin: 0;
    font-size: 1em;
    line-height: 1.6;
}

/* ==========================
   Short Description – Multi-line (3 lines visible)
=========================== */
.product-short {
    display: -webkit-box;
    -webkit-line-clamp: 3;     /* Show up to 3 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;

    font-size: 1em;
    line-height: 1.6;
    color: var(--bb-text-light);
    font-style: italic;
    margin: 0 0 16px;
    padding: 12px 16px;
    background: var(--bb-orange-light);
    border-left: 4px solid var(--bb-orange);
    border-radius: 0 4px 4px 0;
    min-height: 4.8em;         /* 3 lines × 1.6 line-height */
    max-height: 4.8em;
    overflow-y: auto;          /* Scroll if user types more */
    resize: vertical;          /* Optional: let user resize */
}

.product-price {
    font-size: 1.8em;
    font-weight: bold;
    color: var(--bb-orange);
}

.product-sku strong,
.product-stock strong {
    color: var(--bb-text);
}

.product-stock {
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 4px;
    display: inline-block;
    font-size: 0.9em;
}

.product-stock.in-stock {
    background: #d4edda;
    color: #155724;
}

.product-stock.out-of-stock {
    background: #f8d7da;
    color: #721c24;
}

/* Additional Details */
.product-additional-details {
    background: var(--bb-orange-light);
    border-left: 4px solid var(--bb-orange);
    padding: 16px;
    border-radius: 0 4px 4px 0;
    font-size: 0.95em;
    line-height: 1.6;
    margin: 16px 0;
}

/* Purchase Button */
.product-buy {
    margin-top: 20px;
    text-align: center;
}

.purchase-button {
    display: inline-block;
    width: 60%;
    max-width: 240px;
    padding: 14px 20px;
    text-align: center;
    font-size: 1.1em;
    font-weight: 600;
    background: var(--bb-orange);
    color: #fff;
    border: none;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.purchase-button:hover {
    background: var(--bb-orange-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 102, 0, 0.25);
}

.purchase-button:active {
    transform: translateY(0);
}

.purchase-button[disabled],
.purchase-button[style*="opacity"] {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* ==========================
   FULL-WIDTH DESCRIPTION (Below Everything)
=========================== */
.product-full-width-content {
    grid-column: 1 / -1;
    margin-top: 50px;
    padding-top: 30px;
    border-top: 2px solid var(--bb-orange-light);
}

.product-description {
    font-size: 1.05em;
    line-height: 1.8;
    color: var(--bb-text);
}

.product-description h2 {
    font-size: 1.9em;
    margin: 35px 0 18px;
    text-align: center;
    color: var(--bb-text);
    position: relative;
}

.product-description h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--bb-orange);
    margin: 12px auto 0;
    border-radius: 2px;
}

.product-description h3,
.product-description h4 {
    font-size: 1.25em;
    color: var(--bb-orange);
    margin: 28px 0 12px;
    border-left: 5px solid var(--bb-orange);
    padding-left: 16px;
    font-weight: 600;
}

.product-description p {
    margin-bottom: 16px;
}

.product-description p strong {
    color: var(--bb-text);
    font-weight: 600;
}

.product-description ul,
.product-description ol {
    margin: 18px 0;
    padding-left: 32px;
}

.product-description li {
    margin-bottom: 10px;
    line-height: 1.6;
}

.product-description img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 24px 0;
    border: 1px solid var(--bb-border);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

/* Center-aligned thank you */
.product-description p[style*="text-align: center"] {
    text-align: center;
    font-size: 1.25em;
    font-weight: 600;
    color: var(--bb-orange);
    margin: 40px 0;
}
