/**
 * BC WooCommerce Print Plugin - Cart & Checkout Styles
 * Enhanced styling for customization attributes display
 */

/* Cart item meta wrapper */
.woocommerce-cart .cart_item dl.variation,
.woocommerce-checkout .cart_item dl.variation {
    margin: 10px 0;
    padding: 0;
}

/* Labels - Clean and modern */
.bc-cart-label {
    display: inline-block;
    font-weight: 600;
    color: #2c3e50;
    font-size: 13px;
    margin-bottom: 2px;
}

.bc-cart-label-type::before {
    content: "🎨 ";
    margin-right: 4px;
}

.bc-cart-label-custom::before {
    content: "✨ ";
    margin-right: 4px;
}

.bc-cart-label-logo-opt::before {
    content: "📤 ";
    margin-right: 4px;
}

.bc-cart-label-text::before {
    content: "✏️ ";
    margin-right: 4px;
}

.bc-cart-label-file::before {
    content: "📁 ";
    margin-right: 4px;
}

/* Values - Clear and readable */
.bc-cart-value {
    display: inline-block;
    color: #555;
    font-size: 14px;
    font-weight: 400;
}

/* Text box - Special styling for custom text */
.bc-cart-text-box {
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-left: 3px solid #4a90e2;
    padding: 10px 12px;
    margin-top: 5px;
    border-radius: 3px;
    font-family: 'Times New Roman', serif;
    font-size: 14px;
    color: #333;
    line-height: 1.5;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* File box - Special styling for logo file */
.bc-cart-file-box {
    background: #f0f8ff;
    border: 1px solid #d0e8ff;
    border-left: 3px solid #4a90e2;
    padding: 10px 12px;
    margin-top: 5px;
    border-radius: 3px;
    font-size: 13px;
}

.bc-file-icon {
    font-size: 18px;
    vertical-align: middle;
}

.bc-file-name {
    color: #2c3e50;
    font-weight: 500;
}

.bc-file-size {
    color: #777;
    font-size: 12px;
}

.bc-file-link {
    display: inline-block;
    margin-top: 8px;
    padding: 6px 12px;
    background: #4a90e2;
    color: white !important;
    text-decoration: none !important;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 500;
    transition: background 0.3s ease;
}

.bc-file-link:hover {
    background: #357abd;
    color: white !important;
}

/* Cart table - Improve spacing */
.woocommerce-cart-form .cart_item .product-name dl.variation dd,
.woocommerce-checkout .cart_item .product-name dl.variation dd {
    margin-bottom: 8px;
}

.woocommerce-cart-form .cart_item .product-name dl.variation dt,
.woocommerce-checkout .cart_item .product-name dl.variation dt {
    margin-bottom: 3px;
}

/* Remove colon from labels (we have icons now) */
dl.variation dt:after {
    content: "";
}

/* Better alignment */
dl.variation dt {
    float: none;
    margin-right: 0;
    width: 100%;
}

dl.variation dd {
    margin-left: 0;
    width: 100%;
}

/* Compact view for mini cart */
.widget_shopping_cart .bc-cart-text-box,
.widget_shopping_cart .bc-cart-file-box {
    padding: 6px 8px;
    font-size: 12px;
}

.widget_shopping_cart .bc-file-link {
    padding: 4px 8px;
    font-size: 11px;
}

/* Order review (checkout) */
.woocommerce-checkout-review-order .bc-cart-text-box,
.woocommerce-checkout-review-order .bc-cart-file-box {
    margin-top: 8px;
}

/* Print-friendly styles */
@media print {
    .bc-file-link {
        display: none;
    }
    
    .bc-cart-text-box,
    .bc-cart-file-box {
        border-color: #000;
        background: none;
    }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
    .bc-cart-label {
        font-size: 12px;
    }
    
    .bc-cart-value {
        font-size: 13px;
    }
    
    .bc-cart-text-box {
        font-size: 13px;
        padding: 8px 10px;
    }
    
    .bc-cart-file-box {
        font-size: 12px;
        padding: 8px 10px;
    }
    
    .bc-file-link {
        display: block;
        text-align: center;
        margin-top: 6px;
    }
}

/* Optional: Group customization data in a box */
.woocommerce-cart-form .cart_item dl.variation,
.woocommerce-checkout .cart_item dl.variation {
    background: #fafafa;
    padding: 12px;
    border-radius: 4px;
    border: 1px solid #e8e8e8;
}

/* Highlight important data */
.bc-cart-text-box::before {
    content: "📝 ";
    font-size: 16px;
    margin-right: 6px;
}

/* Add subtle animation on hover for file links */
.bc-file-link {
    position: relative;
    overflow: hidden;
}

.bc-file-link::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: left 0.3s ease;
}

.bc-file-link:hover::after {
    left: 100%;
}

.woocommerce-cart-form .cart_item .product-name dl.variation dt, .woocommerce-checkout .cart_item .product-name dl.variation dt {
    font-weight: bold;
}
