/* ==========================================================================
   MLB LOYAL FAN v3 — CART + CHECKOUT + THANK YOU
   ========================================================================== */

/* Shared container helpers (in case not present in core) */
.mlb-v3 .mlb-v3-container { max-width: var(--mlb-container); margin: 0 auto; padding: 0 24px; }
.mlb-v3 .mlb-v3-grid { display: grid; gap: 24px; }
.mlb-v3 .mlb-v3-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Breadcrumb (shared w/ other pages) */
.mlb-v3-breadcrumb {
    display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
    font-size: 13px; color: var(--mlb-gray-500);
    margin-bottom: 12px;
}
.mlb-v3-breadcrumb a { color: var(--mlb-gray-600); }
.mlb-v3-breadcrumb a:hover { color: var(--mlb-red); }
.mlb-v3-breadcrumb .mlb-v3-sep { color: var(--mlb-gray-300); }
.mlb-v3-breadcrumb .mlb-v3-current { color: var(--mlb-navy); font-weight: 600; }

/* Section title shared */
.mlb-v3-section-title {
    font-family: var(--mlb-font-display);
    font-size: clamp(22px, 3vw, 30px);
    color: var(--mlb-navy);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 8px;
}
.mlb-v3-section-sub { color: var(--mlb-gray-500); margin: 0; }

/* ==========================================================================
   1. CART PAGE
   ========================================================================== */
.mlb-v3-cart-page {
    padding: 40px 0 80px;
    background: linear-gradient(180deg, var(--mlb-gray-50) 0%, var(--mlb-white) 240px);
    min-height: 60vh;
}

.mlb-v3-cart-header { margin-bottom: 24px; }
.mlb-v3-cart-title {
    font-family: var(--mlb-font-display);
    font-size: clamp(32px, 4.5vw, 46px);
    color: var(--mlb-navy);
    text-transform: uppercase;
    margin: 0 0 6px;
    display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap;
}
.mlb-v3-cart-count {
    font-family: var(--mlb-font-body);
    font-size: 14px; font-weight: 600;
    color: var(--mlb-white);
    background: var(--mlb-navy);
    padding: 4px 12px;
    border-radius: var(--mlb-radius-pill);
    letter-spacing: 0.5px;
}
.mlb-v3-cart-sub { color: var(--mlb-gray-500); margin: 0 0 24px; max-width: 640px; }

/* Free-ship progress */
.mlb-v3-ship-progress {
    background: linear-gradient(135deg, var(--mlb-navy) 0%, var(--mlb-navy-light) 100%);
    color: var(--mlb-white);
    border-radius: var(--mlb-radius-lg);
    padding: 18px 22px;
    margin-bottom: 28px;
    box-shadow: var(--mlb-shadow-md);
    position: relative;
    overflow: hidden;
}
.mlb-v3-ship-progress::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(600px circle at 100% 0%, rgba(225, 29, 46, 0.35), transparent 50%);
    pointer-events: none;
}
.mlb-v3-ship-progress__head {
    display: flex; align-items: center; gap: 10px;
    margin-bottom: 12px; font-size: 15px;
    position: relative;
}
.mlb-v3-ship-progress__icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 32px; height: 32px; border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
}
.mlb-v3-ship-progress__head strong { font-weight: 700; }
.mlb-v3-ship-progress__bar {
    height: 8px; background: rgba(255, 255, 255, 0.15);
    border-radius: var(--mlb-radius-pill);
    overflow: hidden;
    position: relative;
}
.mlb-v3-ship-progress__fill {
    height: 100%;
    background: linear-gradient(90deg, var(--mlb-red) 0%, var(--mlb-red-light) 100%);
    border-radius: var(--mlb-radius-pill);
    transition: width 0.6s var(--mlb-ease);
    box-shadow: 0 0 12px rgba(225, 29, 46, 0.6);
}
.mlb-v3-ship-progress.is-reached .mlb-v3-ship-progress__fill {
    background: linear-gradient(90deg, var(--mlb-success) 0%, #22c55e 100%);
    box-shadow: 0 0 12px rgba(22, 163, 74, 0.6);
}

/* Grid */
.mlb-v3-cart-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 380px;
    gap: 32px;
    align-items: start;
}

/* Cart items */
.mlb-v3-cart-items {
    background: var(--mlb-white);
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-lg);
    overflow: hidden;
}
.mlb-v3-cart-thead {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 100px 140px 100px 40px;
    gap: 16px;
    padding: 14px 20px;
    background: var(--mlb-gray-50);
    font-size: 11px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 1px; color: var(--mlb-gray-500);
    border-bottom: 1px solid var(--mlb-gray-200);
}
.mlb-v3-cart-thead .c-price,
.mlb-v3-cart-thead .c-qty,
.mlb-v3-cart-thead .c-total { text-align: right; }
.mlb-v3-cart-thead .c-qty { text-align: center; }

.mlb-v3-cart-list { margin: 0; padding: 0; list-style: none; }
.mlb-v3-cart-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 100px 140px 100px 40px;
    gap: 16px;
    padding: 20px;
    border-bottom: 1px solid var(--mlb-gray-200);
    align-items: center;
    transition: background var(--mlb-t);
}
.mlb-v3-cart-item:last-child { border-bottom: 0; }
.mlb-v3-cart-item:hover { background: var(--mlb-gray-50); }

.mlb-v3-cart-item__product { display: flex; gap: 16px; align-items: flex-start; }
.mlb-v3-cart-item__thumb {
    flex: 0 0 92px; width: 92px; height: 92px;
    border-radius: var(--mlb-radius-md);
    overflow: hidden;
    background: var(--mlb-gray-100);
}
.mlb-v3-cart-item__thumb img { width: 100%; height: 100%; object-fit: cover; }

.mlb-v3-cart-item__info { min-width: 0; }
.mlb-v3-cart-item__type {
    display: inline-block;
    font-family: var(--mlb-font-display);
    font-size: 10px; font-weight: 700; letter-spacing: 1px;
    padding: 3px 8px; border-radius: var(--mlb-radius-sm);
    margin-bottom: 6px; text-transform: uppercase;
}
.mlb-v3-cart-item__type.mlb-v3-type-rug { background: #fef3c7; color: #92400e; }
.mlb-v3-cart-item__type.mlb-v3-type-wallet { background: #e0f2fe; color: #075985; }

.mlb-v3-cart-item__name {
    font-family: var(--mlb-font-body);
    font-size: 15px; font-weight: 600;
    color: var(--mlb-navy);
    margin: 0 0 6px;
    line-height: 1.3;
}
.mlb-v3-cart-item__name a { color: inherit; }
.mlb-v3-cart-item__name a:hover { color: var(--mlb-red); }

.mlb-v3-cart-item__meta {
    font-size: 12px; color: var(--mlb-gray-500); margin: 0 0 6px;
}
.mlb-v3-cart-item__meta dt { display: inline; font-weight: 500; }
.mlb-v3-cart-item__meta dd { display: inline; margin-left: 4px; }
.mlb-v3-cart-item__meta dd + dt::before { content: ' • '; color: var(--mlb-gray-300); }

.mlb-v3-cart-item__stock {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 12px; font-weight: 600;
    margin-right: 8px;
}
.mlb-v3-cart-item__stock.is-in { color: var(--mlb-success); }
.mlb-v3-cart-item__stock.is-out { color: var(--mlb-danger); }

.mlb-v3-cart-item__save {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 12px; color: var(--mlb-gray-500);
    border: 0; background: none; padding: 0;
    cursor: pointer;
    transition: color var(--mlb-t);
}
.mlb-v3-cart-item__save:hover { color: var(--mlb-red); }
.mlb-v3-cart-item__save.is-saved { color: var(--mlb-red); }
.mlb-v3-cart-item__save.is-saved .mlb-v3-icon { fill: var(--mlb-red); }

.mlb-v3-cart-item__price,
.mlb-v3-cart-item__total {
    font-weight: 600;
    text-align: right;
    color: var(--mlb-navy);
}
.mlb-v3-cart-item__total { font-size: 16px; font-weight: 700; }
.mlb-v3-cart-item__price { color: var(--mlb-gray-600); }
.mlb-v3-cart-item__price del { color: var(--mlb-gray-400); margin-right: 4px; }

/* Qty control */
.mlb-v3-cart-item__qty { display: flex; justify-content: center; }
.mlb-v3-cart-item__qty .quantity,
.mlb-v3-cart-item__qty .mlb-v3-qty {
    display: inline-flex !important; align-items: center;
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-md);
    overflow: hidden;
    background: var(--mlb-white);
}
.mlb-v3-cart-item__qty .mlb-v3-qty-btn {
    width: 36px; height: 40px; display: inline-flex;
    align-items: center; justify-content: center;
    background: transparent; border: 0; cursor: pointer;
    color: var(--mlb-gray-600);
    transition: background var(--mlb-t), color var(--mlb-t);
}
.mlb-v3-cart-item__qty .mlb-v3-qty-btn:hover { background: var(--mlb-gray-100); color: var(--mlb-red); }
.mlb-v3-cart-item__qty input.qty,
.mlb-v3-cart-item__qty input[type="number"] {
    width: 48px; height: 40px; border: 0;
    text-align: center; background: transparent;
    font-size: 15px; font-weight: 600; color: var(--mlb-navy);
    -moz-appearance: textfield;
}
.mlb-v3-cart-item__qty input[type="number"]::-webkit-outer-spin-button,
.mlb-v3-cart-item__qty input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* Remove */
.mlb-v3-cart-remove {
    display: inline-flex; align-items: center; justify-content: center;
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--mlb-gray-100);
    color: var(--mlb-gray-500);
    font-size: 20px; line-height: 1;
    text-decoration: none;
    transition: background var(--mlb-t), color var(--mlb-t);
}
.mlb-v3-cart-remove:hover { background: var(--mlb-red); color: var(--mlb-white); }

/* Cart actions row */
.mlb-v3-cart-actions {
    display: flex; align-items: center; justify-content: space-between;
    gap: 16px; padding: 18px 20px; background: var(--mlb-gray-50);
    border-top: 1px solid var(--mlb-gray-200);
    flex-wrap: wrap;
}
.mlb-v3-coupon { display: flex; gap: 8px; }
.mlb-v3-coupon__input {
    height: 42px; padding: 0 14px;
    border: 1px solid var(--mlb-gray-300);
    border-radius: var(--mlb-radius-md);
    font-size: 14px; min-width: 180px;
    background: var(--mlb-white);
    color: var(--mlb-navy);
    transition: border-color var(--mlb-t), box-shadow var(--mlb-t);
}
.mlb-v3-coupon__input:focus {
    outline: none;
    border-color: var(--mlb-navy);
    box-shadow: 0 0 0 3px rgba(12, 24, 41, 0.1);
}
.mlb-v3-coupon__btn {
    height: 42px; padding: 0 18px;
    background: var(--mlb-navy); color: var(--mlb-white);
    border-radius: var(--mlb-radius-md); border: 0;
    font-weight: 700; letter-spacing: 0.5px; font-size: 13px;
    text-transform: uppercase; cursor: pointer;
    transition: background var(--mlb-t);
}
.mlb-v3-coupon__btn:hover { background: var(--mlb-navy-dark); }

.mlb-v3-cart-update { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.mlb-v3-link-continue { color: var(--mlb-gray-600); font-size: 14px; font-weight: 500; }
.mlb-v3-link-continue:hover { color: var(--mlb-red); }
.mlb-v3-btn-update {
    height: 42px; padding: 0 20px;
    background: var(--mlb-white);
    color: var(--mlb-navy);
    border: 1px solid var(--mlb-gray-300);
    border-radius: var(--mlb-radius-md);
    font-size: 13px; font-weight: 700; letter-spacing: 0.5px;
    text-transform: uppercase; cursor: pointer;
    transition: all var(--mlb-t);
}
.mlb-v3-btn-update:not(:disabled):hover { background: var(--mlb-navy); color: var(--mlb-white); border-color: var(--mlb-navy); }
.mlb-v3-btn-update:disabled { opacity: 0.5; cursor: not-allowed; }

/* Cart summary (sticky right) */
.mlb-v3-cart-summary { position: sticky; top: 112px; }
.mlb-v3-cart-summary__inner {
    background: var(--mlb-white);
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-lg);
    padding: 24px;
    box-shadow: var(--mlb-shadow-sm);
}
.mlb-v3-cart-summary__title {
    font-family: var(--mlb-font-display);
    font-size: 22px; text-transform: uppercase;
    color: var(--mlb-navy); margin: 0 0 16px;
    letter-spacing: 0.5px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--mlb-gray-200);
}

/* Totals */
.mlb-v3-cart-totals,
.mlb-v3-cart-summary__rows { display: flex; flex-direction: column; gap: 10px; }
.mlb-v3-total-row {
    display: flex; justify-content: space-between; align-items: baseline;
    padding: 6px 0;
    font-size: 14px;
    color: var(--mlb-gray-700);
}
.mlb-v3-total-row.order-total,
.mlb-v3-total-row.is-grand {
    padding-top: 14px; margin-top: 6px;
    border-top: 2px solid var(--mlb-gray-200);
    font-family: var(--mlb-font-display);
    font-size: 22px; text-transform: uppercase;
    color: var(--mlb-navy); font-weight: 700;
    letter-spacing: 0.5px;
}
.mlb-v3-total-label { color: var(--mlb-gray-600); }
.mlb-v3-total-value { color: var(--mlb-navy); font-weight: 600; text-align: right; }
.mlb-v3-total-row.order-total .mlb-v3-total-value { font-size: 26px; color: var(--mlb-red); }
.mlb-v3-total-row.cart-discount .mlb-v3-total-value { color: var(--mlb-success); }

/* Shipping inputs in summary */
.mlb-v3-total-row.shipping { flex-direction: column; gap: 6px; padding: 10px 0; }
.mlb-v3-total-row.shipping .woocommerce-shipping-calculator,
.mlb-v3-total-row.shipping ul {
    font-size: 13px; color: var(--mlb-gray-600);
    margin: 0; padding: 0; list-style: none;
}
.mlb-v3-total-row.shipping li { padding: 4px 0; }

/* Proceed button */
.mlb-v3-cart-totals__proceed { margin-top: 18px; }
.mlb-v3-cart-totals__proceed .checkout-button,
.mlb-v3-cart-totals__proceed .button {
    display: block !important;
    width: 100%;
    padding: 16px 24px !important;
    background: var(--mlb-red) !important;
    color: var(--mlb-white) !important;
    border: 0 !important;
    border-radius: var(--mlb-radius-md) !important;
    font-family: var(--mlb-font-display) !important;
    font-size: 16px !important; font-weight: 700 !important;
    letter-spacing: 1px !important;
    text-transform: uppercase !important;
    text-align: center !important;
    cursor: pointer !important;
    transition: background var(--mlb-t), transform var(--mlb-t), box-shadow var(--mlb-t) !important;
    box-shadow: 0 6px 20px rgba(225, 29, 46, 0.35) !important;
}
.mlb-v3-cart-totals__proceed .checkout-button:hover,
.mlb-v3-cart-totals__proceed .button:hover {
    background: var(--mlb-red-dark) !important;
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(225, 29, 46, 0.45) !important;
}

/* Trust block */
.mlb-v3-cart-summary__trust {
    margin-top: 22px; padding-top: 18px;
    border-top: 1px solid var(--mlb-gray-200);
    display: flex; flex-direction: column; gap: 12px;
}
.mlb-v3-trust-row {
    display: flex; gap: 10px; align-items: center;
    font-size: 13px; color: var(--mlb-gray-700);
}
.mlb-v3-trust-row .mlb-v3-icon { flex: 0 0 auto; color: var(--mlb-red); }
.mlb-v3-trust-row strong { display: block; color: var(--mlb-navy); font-weight: 700; }
.mlb-v3-trust-row small { display: block; color: var(--mlb-gray-500); font-size: 12px; }

/* Payment methods fallback */
.mlb-v3-cart-summary__pay {
    margin-top: 18px; padding-top: 14px;
    border-top: 1px solid var(--mlb-gray-200);
    text-align: center;
}
.mlb-v3-cart-summary__pay img { max-width: 260px; margin: 0 auto; }
.mlb-v3-pay-fallback {
    display: block;
    font-size: 11px; font-weight: 600;
    letter-spacing: 1px;
    color: var(--mlb-gray-500);
}

/* Cross-sells */
.mlb-v3-cross-sells { margin-top: 64px; }
.mlb-v3-cross-sells__head { text-align: center; margin-bottom: 28px; }

/* ==========================================================================
   2. EMPTY CART
   ========================================================================== */
.mlb-v3-cart-empty { padding: 60px 0 100px; }
.mlb-v3-cart-empty__card {
    background: var(--mlb-white);
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-xl);
    padding: 60px 32px;
    text-align: center;
    max-width: 640px; margin: 0 auto;
    box-shadow: var(--mlb-shadow);
}
.mlb-v3-cart-empty__icon {
    width: 120px; height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--mlb-gray-50) 0%, var(--mlb-gray-100) 100%);
    margin: 0 auto 24px;
    display: flex; align-items: center; justify-content: center;
    color: var(--mlb-gray-400);
}
.mlb-v3-cart-empty__title {
    font-family: var(--mlb-font-display);
    font-size: clamp(28px, 4vw, 40px);
    color: var(--mlb-navy);
    text-transform: uppercase;
    margin: 0 0 10px;
}
.mlb-v3-cart-empty__sub {
    color: var(--mlb-gray-600);
    max-width: 480px; margin: 0 auto 28px;
}
.mlb-v3-cart-empty__ctas {
    display: flex; gap: 12px; justify-content: center;
    flex-wrap: wrap; margin-bottom: 32px;
}
.mlb-v3-cart-empty__trust {
    display: flex; justify-content: center; gap: 24px;
    flex-wrap: wrap; padding-top: 24px;
    border-top: 1px solid var(--mlb-gray-200);
}
.mlb-v3-cart-empty__suggest { margin-top: 60px; }
.mlb-v3-cart-empty__suggest .mlb-v3-section-title { text-align: center; margin-bottom: 28px; }

/* ==========================================================================
   3. STEPPER (shared cart→checkout→thankyou)
   ========================================================================== */
.mlb-v3-stepper {
    display: flex; gap: 0;
    margin: 18px 0 0; padding: 0;
    list-style: none;
    max-width: 540px;
}
.mlb-v3-stepper li {
    flex: 1;
    display: flex; align-items: center; gap: 10px;
    padding: 0;
    font-size: 13px;
    color: var(--mlb-gray-400);
    position: relative;
}
.mlb-v3-stepper li + li::before {
    content: '';
    display: block;
    height: 2px; flex: 0 0 24px; width: 24px;
    background: var(--mlb-gray-200);
    margin-right: 10px;
}
.mlb-v3-stepper .step-num {
    width: 28px; height: 28px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: var(--mlb-gray-200); color: var(--mlb-gray-500);
    font-weight: 700; font-size: 13px;
    flex: 0 0 28px;
    transition: all var(--mlb-t);
}
.mlb-v3-stepper .step-label { font-weight: 600; letter-spacing: 0.3px; }
.mlb-v3-stepper li.is-active { color: var(--mlb-navy); }
.mlb-v3-stepper li.is-active .step-num { background: var(--mlb-red); color: var(--mlb-white); box-shadow: 0 0 0 4px rgba(225, 29, 46, 0.15); }
.mlb-v3-stepper li.is-done { color: var(--mlb-success); }
.mlb-v3-stepper li.is-done .step-num { background: var(--mlb-success); color: var(--mlb-white); }
.mlb-v3-stepper li.is-done + li::before,
.mlb-v3-stepper li.is-active + li::before { background: var(--mlb-success); }

/* ==========================================================================
   4. CHECKOUT
   ========================================================================== */
.mlb-v3-checkout-page {
    padding: 40px 0 80px;
    background: var(--mlb-gray-50);
    min-height: 60vh;
}
.mlb-v3-checkout-header { margin-bottom: 28px; }
.mlb-v3-checkout-title {
    font-family: var(--mlb-font-display);
    font-size: clamp(30px, 4vw, 42px);
    color: var(--mlb-navy);
    text-transform: uppercase;
    margin: 0 0 6px;
}

.mlb-v3-checkout-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 400px;
    gap: 28px;
    align-items: start;
}

/* Section */
.mlb-v3-checkout-section {
    background: var(--mlb-white);
    border-radius: var(--mlb-radius-lg);
    border: 1px solid var(--mlb-gray-200);
    margin-bottom: 20px;
    overflow: hidden;
}
.mlb-v3-checkout-section__head {
    display: flex; gap: 14px; align-items: center;
    padding: 20px 24px;
    background: linear-gradient(180deg, var(--mlb-white) 0%, var(--mlb-gray-50) 100%);
    border-bottom: 1px solid var(--mlb-gray-200);
}
.mlb-v3-section-num {
    width: 32px; height: 32px; border-radius: 50%;
    background: var(--mlb-red); color: var(--mlb-white);
    font-weight: 700; font-size: 15px;
    display: flex; align-items: center; justify-content: center;
    flex: 0 0 32px;
}
.mlb-v3-checkout-section__head h2 {
    font-family: var(--mlb-font-display);
    font-size: 20px; color: var(--mlb-navy);
    text-transform: uppercase;
    margin: 0;
    letter-spacing: 0.5px;
}
.mlb-v3-checkout-section__head p { color: var(--mlb-gray-500); font-size: 13px; margin: 2px 0 0; }
.mlb-v3-checkout-section__body { padding: 24px; }

/* Form fields skin */
.mlb-v3-checkout-form .form-row,
.mlb-v3-checkout-form .woocommerce-form-row,
.mlb-v3-dashboard .form-row,
.woocommerce-EditAccountForm .form-row,
.woocommerce-address-fields .form-row,
.woocommerce-form-login .form-row,
.woocommerce-form-register .form-row {
    display: block; margin: 0 0 14px;
}
.mlb-v3-checkout-form label,
.woocommerce-EditAccountForm label,
.woocommerce-address-fields label,
.woocommerce-form-login label,
.woocommerce-form-register label {
    display: block;
    font-size: 13px; font-weight: 600;
    color: var(--mlb-gray-700);
    margin: 0 0 6px;
}
.mlb-v3-checkout-form input[type="text"],
.mlb-v3-checkout-form input[type="email"],
.mlb-v3-checkout-form input[type="tel"],
.mlb-v3-checkout-form input[type="password"],
.mlb-v3-checkout-form input[type="number"],
.mlb-v3-checkout-form textarea,
.mlb-v3-checkout-form select,
.mlb-v3-checkout-form .select2-selection,
.woocommerce-EditAccountForm input,
.woocommerce-address-fields input,
.woocommerce-address-fields textarea,
.woocommerce-address-fields select,
.woocommerce-form-login input[type="text"],
.woocommerce-form-login input[type="email"],
.woocommerce-form-login input[type="password"],
.woocommerce-form-register input[type="text"],
.woocommerce-form-register input[type="email"],
.woocommerce-form-register input[type="password"],
.woocommerce-ResetPassword input {
    width: 100%;
    height: 46px; padding: 0 14px;
    border: 1px solid var(--mlb-gray-300);
    border-radius: var(--mlb-radius-md);
    background: var(--mlb-white);
    color: var(--mlb-navy);
    font-family: var(--mlb-font-body);
    font-size: 14px;
    transition: border-color var(--mlb-t), box-shadow var(--mlb-t);
}
.mlb-v3-checkout-form textarea,
.woocommerce-address-fields textarea { height: auto; min-height: 90px; padding: 12px 14px; resize: vertical; line-height: 1.5; }
.mlb-v3-checkout-form input:focus,
.mlb-v3-checkout-form textarea:focus,
.mlb-v3-checkout-form select:focus,
.woocommerce-EditAccountForm input:focus,
.woocommerce-address-fields input:focus,
.woocommerce-form-login input:focus,
.woocommerce-form-register input:focus,
.woocommerce-ResetPassword input:focus {
    outline: none;
    border-color: var(--mlb-navy);
    box-shadow: 0 0 0 3px rgba(12, 24, 41, 0.1);
}
.mlb-v3-checkout-form .select2-container--default .select2-selection--single {
    height: 46px !important; border: 1px solid var(--mlb-gray-300);
    border-radius: var(--mlb-radius-md);
}
.mlb-v3-checkout-form .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 44px !important; padding: 0 14px !important; color: var(--mlb-navy);
}
.mlb-v3-checkout-form .select2-container--default .select2-selection--single .select2-selection__arrow { height: 44px !important; right: 8px; }

/* 2-col fields */
.col2-set { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.col2-set .col-1,
.col2-set .col-2 { min-width: 0; }
.mlb-v3-checkout-form .form-row-first,
.mlb-v3-checkout-form .form-row-last,
.woocommerce-address-fields .form-row-first,
.woocommerce-address-fields .form-row-last { width: calc(50% - 6px); display: inline-block; vertical-align: top; }
.mlb-v3-checkout-form .form-row-first,
.woocommerce-address-fields .form-row-first { margin-right: 10px; }
.mlb-v3-checkout-form .form-row-wide,
.woocommerce-address-fields .form-row-wide { width: 100%; }

/* Required */
.mlb-v3-checkout-form abbr.required,
.woocommerce-form-login abbr.required,
.woocommerce-form-register abbr.required { color: var(--mlb-red); border: 0; text-decoration: none; margin-left: 3px; }
.mlb-v3-checkout-form .required,
.woocommerce-form-login .required,
.woocommerce-form-register .required { color: var(--mlb-red); }

/* Checkboxes */
.woocommerce-form__label-for-checkbox {
    display: flex !important; align-items: center; gap: 8px;
    cursor: pointer; user-select: none;
    font-weight: 500 !important;
}
.woocommerce-form__label-for-checkbox input[type="checkbox"] {
    appearance: none; width: 20px; height: 20px;
    border: 2px solid var(--mlb-gray-300); border-radius: 4px;
    cursor: pointer; position: relative;
    flex: 0 0 20px;
    background: var(--mlb-white);
    transition: all var(--mlb-t);
}
.woocommerce-form__label-for-checkbox input[type="checkbox"]:checked {
    background: var(--mlb-red); border-color: var(--mlb-red);
}
.woocommerce-form__label-for-checkbox input[type="checkbox"]:checked::after {
    content: '';
    position: absolute; left: 5px; top: 1px;
    width: 6px; height: 11px;
    border: solid white; border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Aside — sticky order summary */
.mlb-v3-checkout-aside { position: sticky; top: 112px; }
.mlb-v3-checkout-aside__inner {
    background: var(--mlb-white);
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-lg);
    padding: 20px;
    box-shadow: var(--mlb-shadow);
}
.mlb-v3-aside-title {
    font-family: var(--mlb-font-display);
    font-size: 20px; color: var(--mlb-navy);
    text-transform: uppercase; margin: 0 0 14px;
    padding-bottom: 12px; border-bottom: 1px solid var(--mlb-gray-200);
    letter-spacing: 0.5px;
}

.mlb-v3-checkout-items { margin: 0 0 14px; padding: 0; list-style: none; max-height: 360px; overflow-y: auto; }
.mlb-v3-checkout-item {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr) auto;
    gap: 12px; padding: 10px 0;
    border-bottom: 1px dashed var(--mlb-gray-200);
    align-items: center;
}
.mlb-v3-checkout-item:last-child { border-bottom: 0; }
.mlb-v3-checkout-item__thumb {
    position: relative;
    width: 64px; height: 64px;
    border-radius: var(--mlb-radius-md);
    overflow: hidden;
    background: var(--mlb-gray-100);
}
.mlb-v3-checkout-item__thumb img { width: 100%; height: 100%; object-fit: cover; }
.mlb-v3-checkout-item__qty {
    position: absolute; top: -6px; right: -6px;
    min-width: 22px; height: 22px; padding: 0 6px;
    border-radius: var(--mlb-radius-pill);
    background: var(--mlb-navy); color: var(--mlb-white);
    font-size: 11px; font-weight: 700;
    display: inline-flex; align-items: center; justify-content: center;
    box-shadow: var(--mlb-shadow-sm);
}
.mlb-v3-checkout-item__info h4 {
    font-size: 13px; font-weight: 600;
    color: var(--mlb-navy);
    margin: 0 0 4px; line-height: 1.3;
}
.mlb-v3-checkout-item__meta { font-size: 11px; color: var(--mlb-gray-500); margin: 0; }
.mlb-v3-checkout-item__meta dt, .mlb-v3-checkout-item__meta dd { display: inline; }
.mlb-v3-checkout-item__total { font-size: 14px; font-weight: 700; color: var(--mlb-navy); }

/* Coupon toggle */
.mlb-v3-checkout-coupon { margin: 14px 0; padding: 14px 0; border-top: 1px solid var(--mlb-gray-200); border-bottom: 1px solid var(--mlb-gray-200); }
.mlb-v3-checkout-coupon__toggle {
    width: 100%; padding: 0;
    background: none; border: 0;
    display: flex; justify-content: space-between; align-items: center;
    font-size: 14px; font-weight: 600;
    color: var(--mlb-navy); cursor: pointer;
}
.mlb-v3-checkout-coupon__toggle span { color: var(--mlb-red); font-size: 18px; transition: transform var(--mlb-t); }
.mlb-v3-checkout-coupon.is-open .mlb-v3-checkout-coupon__toggle span { transform: rotate(45deg); }
.mlb-v3-checkout-coupon__panel { margin-top: 10px; }
.mlb-v3-checkout-coupon__panel .mlb-v3-coupon { gap: 6px; }

.mlb-v3-checkout-aside__note {
    display: flex; align-items: center; gap: 8px;
    font-size: 12px; color: var(--mlb-gray-500);
    margin-top: 14px; justify-content: center;
}
.mlb-v3-checkout-aside__note .mlb-v3-icon { color: var(--mlb-success); }

/* Review order totals */
.mlb-v3-review-order { }
.mlb-v3-review-order__totals {
    background: var(--mlb-gray-50);
    border-radius: var(--mlb-radius-md);
    padding: 16px 18px;
    margin-bottom: 20px;
}

/* Payment methods */
.mlb-v3-pay-heading {
    font-family: var(--mlb-font-display);
    font-size: 16px; text-transform: uppercase;
    color: var(--mlb-navy); letter-spacing: 0.5px;
    margin: 0 0 14px;
}
.mlb-v3-pay-methods { margin: 0 0 20px; padding: 0; list-style: none; }
.mlb-v3-pay-methods .wc_payment_method,
.mlb-v3-pay-methods > li {
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-md);
    padding: 14px 16px;
    margin-bottom: 10px;
    background: var(--mlb-white);
    transition: border-color var(--mlb-t), background var(--mlb-t);
}
.mlb-v3-pay-methods > li:has(input:checked),
.mlb-v3-pay-methods > li.is-checked {
    border-color: var(--mlb-red);
    background: linear-gradient(180deg, #fef2f3 0%, var(--mlb-white) 100%);
}
.mlb-v3-pay-methods label {
    display: flex !important; align-items: center; gap: 10px;
    font-weight: 600 !important; color: var(--mlb-navy);
    cursor: pointer; margin: 0 !important;
}
.mlb-v3-pay-methods input[type="radio"] {
    appearance: none; width: 20px; height: 20px; border-radius: 50%;
    border: 2px solid var(--mlb-gray-300);
    flex: 0 0 20px; cursor: pointer; position: relative;
    transition: border-color var(--mlb-t);
}
.mlb-v3-pay-methods input[type="radio"]:checked { border-color: var(--mlb-red); }
.mlb-v3-pay-methods input[type="radio"]:checked::after {
    content: ''; position: absolute;
    width: 10px; height: 10px; border-radius: 50%;
    background: var(--mlb-red);
    top: 50%; left: 50%; transform: translate(-50%, -50%);
}
.mlb-v3-pay-methods .payment_box {
    margin-top: 10px; padding: 12px 14px;
    background: var(--mlb-gray-50); border-radius: var(--mlb-radius-md);
    font-size: 13px; color: var(--mlb-gray-700);
}
.mlb-v3-pay-methods .payment_box p:last-child { margin: 0; }

/* Place order */
.mlb-v3-place-order { margin-top: 8px; }
.mlb-v3-btn-xl {
    width: 100%; padding: 18px 24px !important;
    font-size: 17px !important;
    position: relative;
}
.mlb-v3-btn-total {
    display: inline-block; margin-left: 10px;
    padding: 3px 10px;
    background: rgba(255, 255, 255, 0.18);
    border-radius: var(--mlb-radius-sm);
    font-size: 14px; font-weight: 700;
}
.mlb-v3-place-order__trust {
    display: flex; align-items: center; gap: 6px; justify-content: center;
    font-size: 12px; color: var(--mlb-gray-500);
    margin: 12px 0 0;
}
.mlb-v3-place-order__trust .mlb-v3-icon { color: var(--mlb-success); }

/* Login/coupon link top of checkout */
.woocommerce-info,
.woocommerce-message,
.woocommerce-error {
    padding: 14px 18px !important;
    background: #fef9e7 !important;
    border: 1px solid #f5e5a0 !important;
    border-radius: var(--mlb-radius-md) !important;
    color: #6b5b00 !important;
    font-size: 14px;
    margin: 0 0 18px !important;
    list-style: none;
}
.woocommerce-message { background: #ecfdf5 !important; border-color: #bbf7d0 !important; color: #166534 !important; }
.woocommerce-error { background: #fef2f2 !important; border-color: #fecaca !important; color: #991b1b !important; }

/* ==========================================================================
   5. THANK YOU
   ========================================================================== */
.mlb-v3-thankyou { padding: 40px 0 80px; background: var(--mlb-gray-50); min-height: 70vh; }

/* Hero */
.mlb-v3-thankyou__hero {
    position: relative;
    background: linear-gradient(135deg, var(--mlb-navy) 0%, var(--mlb-navy-light) 100%);
    color: var(--mlb-white);
    border-radius: var(--mlb-radius-xl);
    padding: 56px 32px;
    text-align: center;
    margin-bottom: 32px;
    overflow: hidden;
    box-shadow: var(--mlb-shadow-lg);
}
.mlb-v3-thankyou__hero::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(600px circle at 50% 0%, rgba(225, 29, 46, 0.4), transparent 60%);
    pointer-events: none;
}

.mlb-v3-thankyou__check {
    width: 92px; height: 92px; border-radius: 50%;
    background: var(--mlb-success);
    color: var(--mlb-white);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 18px;
    box-shadow: 0 10px 30px rgba(22, 163, 74, 0.4);
    animation: thankyouPop 0.6s var(--mlb-ease);
    position: relative;
}
@keyframes thankyouPop {
    0% { transform: scale(0); opacity: 0; }
    60% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

.mlb-v3-thankyou__title {
    font-family: var(--mlb-font-display);
    font-size: clamp(32px, 5vw, 54px);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0 0 8px;
    color: var(--mlb-white);
    position: relative;
}
.mlb-v3-thankyou__sub { font-size: 16px; opacity: 0.92; margin: 0 0 6px; position: relative; }
.mlb-v3-thankyou__email { font-size: 14px; opacity: 0.75; margin: 0 0 18px; position: relative; }
.mlb-v3-thankyou__hero .mlb-v3-stepper { justify-content: center; margin: 18px auto 0; color: var(--mlb-white); position: relative; }
.mlb-v3-thankyou__hero .mlb-v3-stepper li { color: rgba(255, 255, 255, 0.5); }
.mlb-v3-thankyou__hero .mlb-v3-stepper li.is-active,
.mlb-v3-thankyou__hero .mlb-v3-stepper li.is-done { color: var(--mlb-white); }
.mlb-v3-thankyou__hero .mlb-v3-stepper li + li::before { background: rgba(255, 255, 255, 0.2); }
.mlb-v3-thankyou__hero .mlb-v3-stepper li.is-done + li::before,
.mlb-v3-thankyou__hero .mlb-v3-stepper li.is-active + li::before { background: rgba(255, 255, 255, 0.6); }

/* Confetti */
.mlb-v3-thankyou__confetti { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.mlb-v3-thankyou__confetti span {
    position: absolute;
    width: 10px; height: 10px;
    background: var(--mlb-red);
    opacity: 0.8;
    animation: confettiFall 2.4s linear infinite;
}
.mlb-v3-thankyou__confetti span:nth-child(1) { left: 10%; animation-delay: 0s; background: var(--mlb-red); }
.mlb-v3-thankyou__confetti span:nth-child(2) { left: 25%; animation-delay: 0.4s; background: #facc15; }
.mlb-v3-thankyou__confetti span:nth-child(3) { left: 45%; animation-delay: 0.8s; background: #fff; }
.mlb-v3-thankyou__confetti span:nth-child(4) { left: 60%; animation-delay: 1.2s; background: #3b82f6; }
.mlb-v3-thankyou__confetti span:nth-child(5) { left: 75%; animation-delay: 0.6s; background: var(--mlb-red); }
.mlb-v3-thankyou__confetti span:nth-child(6) { left: 90%; animation-delay: 1.0s; background: #facc15; }
@keyframes confettiFall {
    0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
    100% { transform: translateY(440px) rotate(720deg); opacity: 0; }
}

/* Cards */
.mlb-v3-thankyou__cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    margin-bottom: 28px;
}
.mlb-v3-thankyou__card {
    background: var(--mlb-white);
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-lg);
    padding: 16px 18px;
}
.mlb-v3-thankyou__card-label {
    display: block;
    font-size: 11px; font-weight: 700; letter-spacing: 1px;
    text-transform: uppercase; color: var(--mlb-gray-500);
    margin-bottom: 4px;
}
.mlb-v3-thankyou__card strong { font-size: 15px; color: var(--mlb-navy); font-weight: 700; }

/* Details */
.mlb-v3-thankyou__details {
    background: var(--mlb-white);
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-lg);
    padding: 24px;
    margin-bottom: 32px;
}
.mlb-v3-thankyou__details .woocommerce-order-details,
.mlb-v3-thankyou__details .woocommerce-customer-details {
    margin: 0 0 24px;
}
.mlb-v3-thankyou__details h2 {
    font-family: var(--mlb-font-display);
    font-size: 18px; text-transform: uppercase;
    color: var(--mlb-navy); margin: 0 0 14px;
    padding-bottom: 10px; border-bottom: 1px solid var(--mlb-gray-200);
    letter-spacing: 0.5px;
}
.mlb-v3-thankyou__details table.shop_table {
    width: 100%; border-collapse: collapse;
}
.mlb-v3-thankyou__details table.shop_table th,
.mlb-v3-thankyou__details table.shop_table td {
    padding: 12px 0; text-align: left;
    border-bottom: 1px solid var(--mlb-gray-200);
    font-size: 14px;
}
.mlb-v3-thankyou__details table.shop_table tfoot th,
.mlb-v3-thankyou__details table.shop_table tfoot td { font-weight: 700; color: var(--mlb-navy); }
.mlb-v3-thankyou__details table.shop_table tfoot tr:last-child th,
.mlb-v3-thankyou__details table.shop_table tfoot tr:last-child td {
    font-size: 18px; color: var(--mlb-red);
    border-bottom: 0; padding-top: 16px;
    font-family: var(--mlb-font-display); letter-spacing: 0.5px;
}

/* Next */
.mlb-v3-thankyou__next h2 {
    font-family: var(--mlb-font-display);
    font-size: 24px; text-transform: uppercase;
    color: var(--mlb-navy); text-align: center;
    margin: 0 0 18px;
}
.mlb-v3-thankyou__next-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}
.mlb-v3-thankyou__next-card {
    background: var(--mlb-white);
    border: 1px solid var(--mlb-gray-200);
    border-radius: var(--mlb-radius-lg);
    padding: 22px;
    text-align: center;
    transition: transform var(--mlb-t), box-shadow var(--mlb-t);
}
.mlb-v3-thankyou__next-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--mlb-shadow-md);
}
.mlb-v3-thankyou__next-card .mlb-v3-icon {
    color: var(--mlb-red); margin: 0 auto 10px;
    display: block;
}
.mlb-v3-thankyou__next-card h3 {
    font-family: var(--mlb-font-display);
    font-size: 16px; text-transform: uppercase;
    color: var(--mlb-navy); letter-spacing: 0.5px;
    margin: 0 0 6px;
}
.mlb-v3-thankyou__next-card p { color: var(--mlb-gray-600); font-size: 13px; margin: 0 0 10px; }

/* Failed */
.mlb-v3-thankyou__failed {
    text-align: center; padding: 40px 20px;
    background: #fef2f2; border: 1px solid #fecaca;
    border-radius: var(--mlb-radius-lg);
}
.mlb-v3-thankyou__failed h1 { color: var(--mlb-danger); margin: 0 0 10px; }
.mlb-v3-thankyou__ctas { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }

/* ==========================================================================
   6. RESPONSIVE
   ========================================================================== */
@media (max-width: 1024px) {
    .mlb-v3-cart-grid,
    .mlb-v3-checkout-grid { grid-template-columns: 1fr; }
    .mlb-v3-cart-summary,
    .mlb-v3-checkout-aside { position: static; }
}

@media (max-width: 768px) {
    .mlb-v3-cart-thead { display: none; }
    .mlb-v3-cart-item {
        grid-template-columns: 80px 1fr;
        grid-template-areas:
            "thumb name"
            "thumb meta"
            "price qty"
            "total remove";
        gap: 10px 14px; padding: 16px;
    }
    .mlb-v3-cart-item__product { grid-column: 1 / span 2; display: grid; grid-template-columns: 80px 1fr; gap: 14px; }
    .mlb-v3-cart-item__thumb { flex: 0 0 80px; width: 80px; height: 80px; }
    .mlb-v3-cart-item__price { grid-column: 1 / span 2; text-align: left; font-size: 14px; }
    .mlb-v3-cart-item__price::before,
    .mlb-v3-cart-item__qty::before,
    .mlb-v3-cart-item__total::before {
        content: attr(data-label) ": ";
        color: var(--mlb-gray-500); font-weight: 500;
        font-size: 12px; margin-right: 6px;
    }
    .mlb-v3-cart-item__qty { grid-column: 1 / span 2; justify-content: flex-start; }
    .mlb-v3-cart-item__total { grid-column: 1; text-align: left; font-size: 18px; }
    .mlb-v3-cart-item__remove { grid-column: 2; justify-self: end; }

    .mlb-v3-cart-actions { flex-direction: column; align-items: stretch; }
    .col2-set { grid-template-columns: 1fr; }

    .mlb-v3-thankyou__hero { padding: 40px 20px; }

    .mlb-v3-stepper { flex-wrap: wrap; gap: 10px; }
    .mlb-v3-stepper li + li::before { display: none; }
}

@media (max-width: 480px) {
    .mlb-v3-cart-title { font-size: 30px; }
    .mlb-v3-cart-item { grid-template-columns: 64px 1fr; }
    .mlb-v3-cart-item__product { grid-template-columns: 64px 1fr; }
    .mlb-v3-cart-item__thumb { flex: 0 0 64px; width: 64px; height: 64px; }
    .mlb-v3-checkout-section__body { padding: 16px; }
    .mlb-v3-checkout-section__head { padding: 14px 16px; }
    .mlb-v3-thankyou__title { font-size: 30px; }
}
