/**
 * RGC Custom Cookies Designer Styles
 * Version: 1.2.0
 * Author: Greyfell Group
 * Supports: Product pages and shortcode embeds
 */

/* Hide the default variation dropdown - ONLY for product 5915 */
#product-5915 .variations,
#product-5915 .variations_form .variations,
#product-5915 table.variations,
#product-5915 .variations_form table.variations,
#product-5915 select#cookie-shape,
.product-5915 .variations,
.product-5915 .variations_form .variations,
.product-5915 table.variations,
body.postid-5915 .variations,
body.postid-5915 .variations_form .variations,
body.postid-5915 table.variations,
#custom-cookie-right-column .variations,
#custom-cookie-right-column .variations_form .variations,
#custom-cookie-right-column table.variations,
#custom-cookie-right-column select#cookie-shape {
    display: none !important;
    visibility: hidden !important;
}

/* Hide reset variations - ONLY for product 5915 */
#product-5915 .reset_variations,
.product-5915 .reset_variations,
body.postid-5915 .reset_variations,
#custom-cookie-right-column .reset_variations {
    display: none !important;
}

/* Hide variation labels - ONLY for product 5915 */
#product-5915 .variations .label,
#product-5915 .variations th.label,
.product-5915 .variations .label,
.product-5915 .variations th.label,
body.postid-5915 .variations .label,
body.postid-5915 .variations th.label,
#custom-cookie-right-column .variations .label,
#custom-cookie-right-column .variations th.label {
    display: none !important;
}

/* Hide stock status - ONLY for product 5915 */
#product-5915 .stock,
.product-5915 .stock,
body.postid-5915 .stock,
#custom-cookie-right-column .stock {
    display: none !important;
}

/* Hide price - ONLY for product 5915 */
#product-5915 .price,
.product-5915 .price,
body.postid-5915 .price,
#custom-cookie-right-column .price {
    display: none !important;
}

/* Hide redundant elements */
#product-5915 .product_title,
#product-5915 .woocommerce-product-details__full-description,
.product-5915 .product_title,
.product-5915 .woocommerce-product-details__full-description {
    display: none !important;
}

/* Container Layout - Let GeneratePress handle widths and spacing */
#custom-cookies-full-container {
    display: flex;
    align-items: flex-start;
    /* No gap, padding, or margin - GeneratePress controls all spacing */
}

#custom-cookie-left-column {
    /* Remove fixed width - let GeneratePress control it */
    flex-shrink: 2; /* Allow left column to shrink more */
    /* No padding or margin - GeneratePress controls spacing */
}

#custom-cookie-center-column {
    /* Remove fixed width - let GeneratePress control it */
    flex-shrink: 0; /* Don't shrink the designer */
    /* No padding or margin - GeneratePress controls spacing */
}

#custom-cookie-right-column {
    /* Remove fixed width - let GeneratePress control it */
    display: flex;
    flex-direction: column;
    flex-shrink: 3; /* Allow this column to shrink more than others */
    text-align: center; /* Center all content in right column */
    /* No gap, padding, or margin - GeneratePress controls spacing */
}

/* Cookie Swatches Wrapper */
.rgc-cookie-swatches-wrapper {
    text-align: center; /* Center everything in left column */
    /* No margin - GeneratePress controls spacing */
}

.rgc-swatches-title {
    font-size: 18px;
    font-weight: 700;
    color: #5B4E9D; /* Purple from your branding */
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center; /* Ensure title is centered */
    /* No margin - GeneratePress controls spacing */
}

/* Cookie Swatches Grid */
.rgc-cookie-swatches {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center; /* Center the swatches themselves */
}

/* Individual Swatch Item */
.rgc-swatch-item {
    display: block;
    padding: 4px 8px; /* Reduced vertical padding from 8px to 4px */
    border: 3px solid #E8E4F3;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
}

.rgc-swatch-item:hover {
    border-color: #FF5733; /* Orange from your branding */
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.rgc-swatch-item.selected {
    border-color: #FF5733;
    background: #FFF5F3;
    box-shadow: 0 4px 12px rgba(255, 87, 51, 0.2);
}

.rgc-swatch-item img {
    width: 150px;
    height: 150px;
    object-fit: contain;
    border-radius: 8px;
    display: block;
}

.rgc-swatch-label {
    display: none; /* Hide the text labels */
}

/* Right Column Elements */
.rgc-right-column-heading {
    font-size: 20px;
    font-weight: 700;
    color: #5B4E9D;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
    margin-top: auto; /* Push to bottom of column */
    margin-bottom: 15px;
}

/* Order Description Text */
.rgc-order-description {
    text-align: center;
    margin-bottom: 20px;
}

.rgc-order-description p {
    color: #282561;
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
}

/* Minimum Order Notice */
.rgc-minimum-order-notice {
    padding: 10px 15px;
    background: #F0EDFF;
    border-left: 3px solid #5B4E9D;
    border-radius: 4px;
    margin: 20px 0; /* 20px spacing above and below */
}

.rgc-minimum-order-notice p {
    margin: 0;
    color: #5B4E9D;
    font-weight: 600;
}

.rgc-minimum-order-notice small {
    font-size: 14px;
}

/* Quantity Selector Styling - COMPLETELY REMOVED */
/* Zero custom styling applied - pure WooCommerce/theme defaults */

/* Special Instructions Field */
.rgc-special-instructions-wrapper {
    margin: 0;
}

.rgc-special-instructions-wrapper label {
    display: block;
    margin-bottom: 10px;
    font-size: 16px;
    color: #333;
}

.rgc-special-instructions-wrapper label strong {
    color: #5B4E9D;
}

.rgc-special-instructions-wrapper .optional {
    font-weight: normal;
    font-size: 14px;
    color: #999;
}

.rgc-special-instructions-wrapper textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #E8E4F3;
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    transition: border-color 0.3s ease;
    resize: vertical;
    min-height: 120px;
}

.rgc-special-instructions-wrapper textarea:focus {
    outline: none;
    border-color: #5B4E9D;
}

.rgc-special-instructions-wrapper textarea::placeholder {
    color: #999;
}

/* Order Meta Display */
.rgc-order-special-instructions {
    margin-top: 10px;
    padding: 12px;
    background: #F9F9F9;
    border-left: 3px solid #5B4E9D;
    border-radius: 4px;
}

.rgc-order-special-instructions strong {
    color: #5B4E9D;
}

/* Cart Form Styling - ONLY for product 5915 */
#product-5915 form.cart,
.product-5915 form.cart,
body.postid-5915 form.cart,
#custom-cookie-right-column form.cart {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 100%;
}

/* Variation add to cart wrapper - center everything - ONLY for product 5915 */
#product-5915 .woocommerce-variation-add-to-cart,
.product-5915 .woocommerce-variation-add-to-cart,
body.postid-5915 .woocommerce-variation-add-to-cart,
#custom-cookie-right-column .woocommerce-variation-add-to-cart {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    width: 100%;
}

/* Quantity Selector - Pill Style - ONLY for product 5915 */
#product-5915 .quantity,
.product-5915 .quantity,
body.postid-5915 .quantity,
#custom-cookie-right-column .quantity {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 3px solid #F37053;
    border-radius: 9999px;
    overflow: hidden;
    background: transparent;
    color: #F37053;
    font-weight: 700;
    margin: 0 auto;
}

#product-5915 .quantity input.qty,
.product-5915 .quantity input.qty,
body.postid-5915 .quantity input.qty,
#custom-cookie-right-column .quantity input.qty {
    border: none;
    text-align: center;
    width: 60px;
    padding: 6px;
    font-size: 18px;
    font-weight: 700;
    background: transparent;
    color: #F37053;
    -moz-appearance: textfield;
}

#product-5915 .quantity input.qty::-webkit-outer-spin-button,
#product-5915 .quantity input.qty::-webkit-inner-spin-button,
.product-5915 .quantity input.qty::-webkit-outer-spin-button,
.product-5915 .quantity input.qty::-webkit-inner-spin-button,
body.postid-5915 .quantity input.qty::-webkit-outer-spin-button,
body.postid-5915 .quantity input.qty::-webkit-inner-spin-button,
#custom-cookie-right-column .quantity input.qty::-webkit-outer-spin-button,
#custom-cookie-right-column .quantity input.qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

#product-5915 .quantity .minus,
#product-5915 .quantity .plus,
.product-5915 .quantity .minus,
.product-5915 .quantity .plus,
body.postid-5915 .quantity .minus,
body.postid-5915 .quantity .plus,
#custom-cookie-right-column .quantity .minus,
#custom-cookie-right-column .quantity .plus {
    background: transparent;
    border: none;
    color: #F37053;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    padding: 6px 14px;
    transition: background 0.3s ease;
}

#product-5915 .quantity .minus:hover,
#product-5915 .quantity .plus:hover,
.product-5915 .quantity .minus:hover,
.product-5915 .quantity .plus:hover,
body.postid-5915 .quantity .minus:hover,
body.postid-5915 .quantity .plus:hover,
#custom-cookie-right-column .quantity .minus:hover,
#custom-cookie-right-column .quantity .plus:hover {
    background: rgba(243, 112, 83, 0.1);
}

/* Add to Cart Button - Centered - ONLY for product 5915 */
#product-5915 .single_add_to_cart_button,
.product-5915 .single_add_to_cart_button,
body.postid-5915 .single_add_to_cart_button,
#custom-cookie-right-column .single_add_to_cart_button {
    display: block;
    margin: 0 auto !important;
    width: auto;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    #custom-cookies-full-container {
        flex-direction: column;
    }
    
    #custom-cookie-left-column,
    #custom-cookie-center-column,
    #custom-cookie-right-column {
        flex: 1 1 100%;
        max-width: 100%;
        min-width: 100%;
    }
    
    /* 2x2 Grid for cookie swatches on tablet/mobile */
    .rgc-cookie-swatches {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
        justify-items: center;
    }
    
    .rgc-swatch-item {
        width: 100%;
        max-width: 160px;
    }
    
    .rgc-swatch-item img {
        width: 120px;
        height: 120px;
    }
    
    .rgc-swatches-title {
        font-size: 16px;
    }
}
