/**
 * OraTheme WooCommerce Cart Page Styles
 *
 * @package OraTheme
 */

:root {
    --ora-primary: #e8380d;
    --ora-primary-dark: #c42a08;
    --ora-text: #1a1a1a;
    --ora-text-light: #666666;
    --ora-text-muted: #999999;
    --ora-border: #e5e5e5;
    --ora-bg: #f5f5f5;
    --ora-white: #ffffff;
    --ora-radius: 8px;
    --ora-radius-lg: 12px;
    --ora-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* Cart Page */
.ora-cart-page {
    background: var(--ora-bg);
    min-height: 100vh;
    padding-bottom: 60px;
}

.ora-cart-page .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Page Title */
.ora-page-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--ora-text);
    margin: 32px 0;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--ora-primary);
}

/* Notices */
.ora-notice {
    padding: 16px 20px;
    border-radius: var(--ora-radius);
    margin-bottom: 24px;
}

.ora-notice-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.ora-notice-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

/* Cart Layout */
.ora-cart-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 32px;
    align-items: start;
}

@media (max-width: 968px) {
    .ora-cart-layout {
        grid-template-columns: 1fr;
    }
}

/* Cart Items */
.ora-cart-items {
    background: var(--ora-white);
    border-radius: var(--ora-radius-lg);
    padding: 24px;
    box-shadow: var(--ora-shadow);
}

/* Cart Table */
.ora-cart-table {
    width: 100%;
    border-collapse: collapse;
}

.ora-cart-table th {
    text-align: left;
    padding: 12px 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--ora-text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--ora-border);
}

.ora-cart-table td {
    padding: 16px 8px;
    border-bottom: 1px solid var(--ora-border);
    vertical-align: middle;
}

.ora-cart-table .product-remove {
    width: 40px;
    text-align: center;
}

.ora-cart-table .product-thumbnail {
    width: 100px;
}

.ora-cart-table .product-thumbnail img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: var(--ora-radius);
}

.ora-cart-table .product-name {
    font-weight: 500;
    color: var(--ora-text);
}

.ora-cart-table .product-name a {
    color: var(--ora-text);
    text-decoration: none;
}

.ora-cart-table .product-name a:hover {
    color: var(--ora-primary);
}

.ora-cart-table .product-price,
.ora-cart-table .product-subtotal {
    font-weight: 600;
    color: var(--ora-text);
}

/* Remove Button */
.ora-remove-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: var(--ora-text-muted);
    transition: all 0.2s;
}

.ora-remove-btn:hover {
    background: #fef2f2;
    color: #dc2626;
}

/* Quantity Input */
.ora-cart-table .quantity {
    display: flex;
    align-items: center;
    border: 1px solid var(--ora-border);
    border-radius: var(--ora-radius);
    overflow: hidden;
    width: fit-content;
}

.ora-cart-table .qty-btn {
    width: 32px;
    height: 36px;
    border: none;
    background: var(--ora-bg);
    cursor: pointer;
    font-size: 16px;
    color: var(--ora-text);
    transition: background 0.2s;
}

.ora-cart-table .qty-btn:hover {
    background: var(--ora-border);
}

.ora-cart-table .qty-input {
    width: 48px;
    height: 36px;
    border: none;
    border-left: 1px solid var(--ora-border);
    border-right: 1px solid var(--ora-border);
    text-align: center;
    font-size: 14px;
    -moz-appearance: textfield;
}

.ora-cart-table .qty-input::-webkit-outer-spin-button,
.ora-cart-table .qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
}

/* Cart Actions */
.ora-cart-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--ora-border);
}

/* Buttons */
.ora-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--ora-radius);
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    border: none;
}

.ora-btn-primary {
    background: var(--ora-primary);
    color: white;
}

.ora-btn-primary:hover {
    background: var(--ora-primary-dark);
}

.ora-btn-secondary {
    background: var(--ora-bg);
    color: var(--ora-text);
}

.ora-btn-secondary:hover {
    background: var(--ora-border);
}

.ora-btn-outline {
    background: transparent;
    color: var(--ora-text);
    border: 1px solid var(--ora-border);
}

.ora-btn-outline:hover {
    border-color: var(--ora-primary);
    color: var(--ora-primary);
}

.ora-btn-block {
    width: 100%;
}

/* Cart Totals */
.ora-cart-totals {
    background: var(--ora-white);
    border-radius: var(--ora-radius-lg);
    padding: 24px;
    box-shadow: var(--ora-shadow);
    position: sticky;
    top: 24px;
}

.ora-totals-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--ora-text);
    margin: 0 0 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--ora-border);
}

.ora-totals-content {
    margin-bottom: 20px;
}

.ora-totals-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--ora-border);
}

.ora-totals-row:last-child {
    border-bottom: none;
}

.ora-totals-row span:first-child {
    font-size: 14px;
    color: var(--ora-text-light);
}

.ora-totals-row span:last-child {
    font-size: 14px;
    font-weight: 600;
    color: var(--ora-text);
}

.ora-totals-total {
    padding-top: 16px;
}

.ora-totals-total span:first-child {
    font-size: 16px;
    font-weight: 600;
    color: var(--ora-text);
}

.ora-totals-total span:last-child {
    font-size: 20px;
    font-weight: 700;
    color: var(--ora-primary);
}

.ora-totals-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--ora-border);
}

/* Coupon Form */
.ora-coupon-form {
    display: flex;
    gap: 8px;
    margin-top: 16px;
}

.ora-coupon-form input {
    flex: 1;
    padding: 10px 14px;
    border: 1px solid var(--ora-border);
    border-radius: var(--ora-radius);
    font-size: 14px;
}

.ora-coupon-form input:focus {
    outline: none;
    border-color: var(--ora-primary);
}

/* Shipping Calculator */
.woocommerce-shipping-calculator {
    margin-top: 8px;
}

.woocommerce-shipping-calculator p {
    margin: 0 0 8px;
}

.woocommerce-shipping-calculator select,
.woocommerce-shipping-calculator input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--ora-border);
    border-radius: var(--ora-radius);
    font-size: 14px;
    margin-bottom: 8px;
}

.woocommerce-shipping-calculator button {
    width: 100%;
}

/* Cross-sells */
.ora-cross-sells {
    margin-top: 48px;
}

.ora-cross-sells h2 {
    font-size: 24px;
    font-weight: 600;
    color: var(--ora-text);
    margin-bottom: 24px;
}

/* Responsive */
@media (max-width: 768px) {
    .ora-cart-table {
        display: block;
        overflow-x: auto;
    }
    
    .ora-cart-actions {
        flex-direction: column;
        gap: 12px;
    }
    
    .ora-cart-actions .ora-btn {
        width: 100%;
    }
}
