/* ============================================================
   WP Cafe — One Page Checkout Sidebar
   All rules scoped to .wpc-one-page-checkout-sidebar.
   Dynamic colours from inline PHP vars:
     --wpc-filter-primary / --wpc-filter-secondary
   ============================================================ */

/* ── Sidebar card ────────────────────────────────────────────── */
.wpc-one-page-checkout-sidebar {
    position: sticky;
    top: 20px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.09);
    padding: 22px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
    color: #1a1a1a;
}

/* ── Header ──────────────────────────────────────────────────── */
.wpc-opc-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 16px;
    margin-bottom: 4px;
    border-bottom: 1px solid #e5e7eb;
}

.wpc-opc-sidebar-header h4 {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    padding: 0;
    line-height: 1;
}

/* Badge — HTML uses .wpc-mini-cart-count */
.wpc-one-page-checkout-sidebar .wpc-mini-cart-count,
.wpc-one-page-checkout-sidebar .wpc-opc-item-count {
    background: var(--wpc-filter-primary, #e7272d);
    color: #fff;
    border-radius: 50%;
    width: 26px;
    height: 26px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
    line-height: 1;
}

/* ── Cart UL ─────────────────────────────────────────────────── */
.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 480px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #d1d5db transparent;
}

.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart::-webkit-scrollbar {
    width: 4px;
}

.wpc-one-page-checkout-sidebar
    .wpc-woocommerce-mini-cart::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 4px;
}

.wpc-one-page-checkout-sidebar
    .wpc-woocommerce-mini-cart::-webkit-scrollbar-track {
    background: transparent;
}

/* ── Cart item <li> ───── */
.wpc-one-page-checkout-sidebar
    ul.product_list_widget
    li.wpc-woocommerce-mini-cart-item,
.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item {
    display: flex;
    flex-direction: column;
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
    position: relative;
    min-height: 0;
    margin: 0;
}

/* Remove button (absolute top-right) */
.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item > a.remove {
    position: absolute;
    top: 16px;
    right: 0;
    line-height: 1;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item > a.remove {
    opacity: 1;
}

.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item > a.remove svg {
    width: 18px;
    height: 18px;
    opacity: 1;
    transition: opacity 0.2s ease;
}

.wpc-one-page-checkout-sidebar
    .wpc-woocommerce-mini-cart-item
    > a.remove:hover
    svg {
    opacity: 0.55;
}

/* Product link — specificity bumped to beat Astra ul.cart_list li a (0,2,3) */
.wpc-one-page-checkout-sidebar ul.product_list_widget li > a:not(.remove),
.wpc-one-page-checkout-sidebar
    .wpc-woocommerce-mini-cart-item
    > a:not(.remove) {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    text-decoration: none;
    line-height: 1.35;
    padding-right: 28px;
    padding-left: 0;
    margin-bottom: 0;
    transition: color 0.2s ease;
}

.wpc-one-page-checkout-sidebar
    .wpc-woocommerce-mini-cart-item
    > a:not(.remove):hover {
    color: var(--wpc-filter-primary, #e7272d);
}

.wpc-one-page-checkout-sidebar ul.product_list_widget li > a:not(.remove) img,
.wpc-one-page-checkout-sidebar
    .wpc-woocommerce-mini-cart-item
    > a:not(.remove)
    img {
    width: 62px;
    height: 62px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    display: block;
    position: static;
    float: none;
    transform: none;
    margin: 0;
}

/* Variation dl — override Astra border-left + padding-left */
.wpc-one-page-checkout-sidebar ul.product_list_widget li dl.variation,
.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item dl.variation {
    margin: 6px 0 0 6px;
    padding: 0;
    padding-left: 0;
    border-left: none;
    font-size: 12px;
    color: #6b7280;
    line-height: 1.6;
}

.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item dl.variation dt {
    display: inline;
    margin: 0;
    font-weight: 600;
}

.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item dl.variation dd {
    display: inline;
    margin: 0;
}

.wpc-one-page-checkout-sidebar
    .wpc-woocommerce-mini-cart-item
    dl.variation
    dd::after {
    content: "\A";
    white-space: pre;
}

.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item dl.variation p {
    display: inline;
    margin: 0;
}

/* Qty + price row — same indent */
.wpc-one-page-checkout-sidebar .mini-cart-quantity-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    margin-left: 6px;
}

/* Push subtotal to far right */
.wpc-one-page-checkout-sidebar
    .mini-cart-quantity-wrapper
    .single-subtotal-item {
    margin-left: auto;
    white-space: nowrap;
}

/* Qty pill */
.wpc-one-page-checkout-sidebar .quantity {
    display: flex;
    align-items: center;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    overflow: hidden;
    height: 30px;
    background: #fff;
    flex-shrink: 0;
}

.wpc-one-page-checkout-sidebar .quantity .minus,
.wpc-one-page-checkout-sidebar .quantity .plus {
    width: 28px;
    height: 30px;
    background: none;
    border: none;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    color: #555;
    display: flex;
    align-items: center;
    justify-content: center;
    transition:
        background 0.15s ease,
        color 0.15s ease;
    flex-shrink: 0;
    padding: 0;
    box-shadow: none;
}

.wpc-one-page-checkout-sidebar .quantity .minus:hover,
.wpc-one-page-checkout-sidebar .quantity .plus:hover {
    background: var(--wpc-filter-primary, #e7272d);
    color: #fff;
}

.wpc-one-page-checkout-sidebar .quantity input.qty {
    width: 32px;
    border: none;
    border-left: 1px solid #e5e7eb;
    border-right: 1px solid #e5e7eb;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: #1a1a1a;
    background: transparent;
    height: 30px;
    padding: 0;
    outline: none;
    -moz-appearance: textfield;
    box-sizing: border-box;
}

.wpc-one-page-checkout-sidebar .quantity input.qty::-webkit-inner-spin-button,
.wpc-one-page-checkout-sidebar .quantity input.qty::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Unit price (between qty and subtotal) */
.wpc-one-page-checkout-sidebar
    .mini-cart-quantity-wrapper
    > .woocommerce-Price-amount {
    font-size: 13px;
    color: #6b7280;
    white-space: nowrap;
}

/* Item subtotal */
.wpc-one-page-checkout-sidebar .single-subtotal-item {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    white-space: nowrap;
}

/* ── Subtotal wrap (below items) ─────────────────────────────── */
.wpc-one-page-checkout-sidebar .wpc-subtotal-wrap {
    margin-top: 4px;
}

/* ── Coupon ──────────────────────────────────────────────────── */
.wpc-one-page-checkout-sidebar .wpc-coupon-wrapper {
    padding: 16px 0 0;
}

.wpc-one-page-checkout-sidebar .wpc-minicart-copoun-label {
    display: block;
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 8px;
    cursor: pointer;
}

.wpc-one-page-checkout-sidebar .coupon_from {
    display: flex;
    gap: 8px;
    align-items: stretch;
    margin: 0;
    padding: 0;
}

.wpc-one-page-checkout-sidebar .wpc-minicart-coupon-field {
    flex: 1;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 13px;
    color: #1a1a1a;
    outline: none;
    background: #fff;
    min-width: 0;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
}

.wpc-one-page-checkout-sidebar .wpc-minicart-coupon-field:focus {
    border-color: var(--wpc-filter-primary, #e7272d);
}

.wpc-one-page-checkout-sidebar .wpc-cupon-btn {
    background: var(--wpc-filter-primary, #e7272d);
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s ease;
    flex-shrink: 0;
    line-height: 1;
    box-shadow: none;
}

.wpc-one-page-checkout-sidebar .wpc-cupon-btn:hover {
    background: var(--wpc-filter-secondary, #cf4c1f);
}

/* ── Subtotal row ────────────────────────────────────────────── */
.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart__total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0 6px;
    margin: 8px 0 0;
    border-top: 1px solid #e5e7eb;
    font-size: 14px;
    color: #374151;
}

.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart__total strong {
    font-weight: 600;
}

/* ── Total row ───────────────────────────────────────────────── */
.wpc-one-page-checkout-sidebar .wpc-minicart-extra-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0 14px;
    border-top: 2px solid #e5e7eb;
    margin-top: 4px;
    font-size: 17px;
    font-weight: 700;
    color: #1a1a1a;
}

.wpc-one-page-checkout-sidebar .wpc-extra-text {
    display: block;
    font-size: 11px;
    font-weight: 400;
    color: #9ca3af;
    margin-top: 2px;
}

.wpc-one-page-checkout-sidebar .wpc-minicart-total {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    color: #1a1a1a;
    white-space: nowrap;
}

/* ── Order type toggle (Delivery / Pickup) — Step 1 cart panel ── */
.wpc-one-page-checkout-wrapper .wpc_pro_order_time {
    padding: 14px 0;
    margin-top: 4px;
}

.wpc-one-page-checkout-wrapper .minicart-condition-parent {
    display: flex;
    gap: 8px;
}

.wpc-one-page-checkout-wrapper .wpc-field-wrap {
    flex: 1;
}

.wpc-one-page-checkout-wrapper .wpc-field-wrap label {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 9px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    white-space: nowrap;
    gap: 0;
}

.wpc-one-page-checkout-wrapper .wpc-field-wrap label:hover {
    border-color: var(--wpc-filter-primary, #e7272d);
    color: var(--wpc-filter-primary, #e7272d);
}

/* Hide native radio, drive active state via JS-added class or :checked */
.wpc-one-page-checkout-wrapper .wpc-minicart-condition-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

.wpc-one-page-checkout-wrapper .wpc-minicart-condition-input:checked + * {
    background: var(--wpc-filter-primary, #e7272d);
    border-color: var(--wpc-filter-primary, #e7272d);
    color: #fff;
    font-weight: 600;
}

.wpc-one-page-checkout-wrapper .wpc-field-wrap .dot-shadow {
    display: none;
}

/* ── Hide base plugin's View cart / Checkout links ───────────── */
.wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart__buttons {
    display: none !important;
}

/* ── Cart footer ─────────────────────────────────────────────── */
.wpc-one-page-checkout-wrapper .wpc-opc-cart-footer {
    margin-top: 16px;
}

.wpc-one-page-checkout-wrapper .wpc-opc-hidden {
    display: none !important;
}

.wpc-one-page-checkout-wrapper .wpc-opc-min-order-msg {
    font-size: 12px;
    color: #dc2626;
    margin: 0;
    padding: 4px 0 0;
    text-align: center;
}

/* Proceed pill button */
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-btn {
    width: 100%;
    background: var(--wpc-filter-primary, #e7272d);
    color: #fff !important;
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    text-decoration: none !important;
    cursor: pointer;
    transition:
        background 0.2s ease,
        transform 0.1s ease;
    box-sizing: border-box;
    line-height: 1;
    box-shadow: none;
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-btn:hover {
    background: var(--wpc-filter-secondary, #cf4c1f);
    color: #fff !important;
    transform: translateY(-1px);
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-btn:active {
    transform: translateY(0);
}

/* ── Checkout panel ──────────────────────────────────────────── */
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel {
    font-size: 14px;
}

.wpc-one-page-checkout-wrapper .wpc-opc-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    color: var(--wpc-filter-primary, #e7272d);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 4px;
    transition: opacity 0.2s ease;
    box-shadow: none;
    margin-bottom: 12px;
}

.wpc-one-page-checkout-wrapper .wpc-opc-back-btn:hover {
    opacity: 0.75;
    background: none !important;
    color: var(--wpc-filter-primary, #e7272d);
}

.wpc-one-page-checkout-wrapper .wpc-opc-section-title {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 20px 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid #e5e7eb;
    clear: both;
}

/* WC billing fields */
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .form-row {
    margin: 0 0 10px 0;
    padding: 0;
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .form-row label {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    display: block;
    margin-bottom: 4px;
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .form-row
    .woocommerce-input-wrapper {
    display: block;
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .form-row
    input[type="text"],
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .form-row
    input[type="email"],
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .form-row
    input[type="tel"],
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .form-row textarea,
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .form-row select {
    width: 100%;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 8px 10px;
    font-size: 13px;
    color: #1a1a1a;
    background: #fff;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
    -webkit-appearance: none;
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .form-row input:focus,
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .form-row textarea:focus,
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .form-row select:focus {
    border-color: var(--wpc-filter-primary, #e7272d);
    box-shadow: 0 0 0 3px rgba(231, 39, 45, 0.08);
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel textarea {
    resize: vertical;
    min-height: 72px;
}

/* Place Order button — override WP/Astra wp-element-button defaults */
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel #place_order {
    width: 100%;
    background: var(--wpc-filter-primary, #e7272d) !important;
    color: #fff !important;
    border: none;
    border-radius: 8px !important;
    padding: 12px 24px !important;
    font-size: 13px !important;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition:
        background 0.2s ease,
        transform 0.1s ease;
    line-height: 1;
    margin-top: 8px;
    box-shadow: none;
    text-transform: capitalize !important;
    float: none;
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel #place_order:hover {
    background: var(--wpc-filter-secondary, #cf4c1f) !important;
    transform: translateY(-1px);
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel #place_order:active {
    transform: translateY(0);
}

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 1100px) {
    .wpc-one-page-checkout-sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    .wpc-one-page-checkout-sidebar {
        position: static;
        padding: 16px;
    }

    .wpc-one-page-checkout-sidebar
        .wpc-woocommerce-mini-cart-item
        > a:not(.remove)
        img {
        width: 50px;
        height: 50px;
    }

    .wpc-one-page-checkout-sidebar .wpc-woocommerce-mini-cart-item dl.variation,
    .wpc-one-page-checkout-sidebar .mini-cart-quantity-wrapper {
        margin-left: 62px;
    }
}

@media (max-width: 480px) {
    .wpc-opc-sidebar-header h4 {
        font-size: 18px;
    }

    .wpc-one-page-checkout-wrapper .wpc-opc-checkout-btn,
    .wpc-one-page-checkout-wrapper .wpc-opc-place-order-btn {
        padding: 14px 16px !important;
    }
}

/* ============================================================
   Pickup / Delivery form fields — Checkout panel (Step 2)
   Overrides wpc-public-pro.css defaults for compact sidebar
   ============================================================ */

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings {
    background: none;
    padding: 0;
    margin-bottom: 16px;
    display: block;
    width: 100%;
}

/* Order type radio toggles */
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .form-row {
    margin-bottom: 12px;
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .woocommerce-input-wrapper {
    display: flex;
    gap: 12px;
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .input-radio {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid #d1d5db;
    border-radius: 50%;
    outline: none;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    background: #fff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
    margin: 0;
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .input-radio:hover {
    border-color: var(--wpc-filter-primary, #e7272d);
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .input-radio:checked {
    border-color: var(--wpc-filter-primary, #e7272d);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(231, 39, 45, 0.1);
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .input-radio:checked::after {
    content: "";
    position: absolute;
    top: 7px;
    left: 7px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--wpc-filter-primary, #e7272d);
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    label.radio {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    margin: 0;
    transition: color 0.2s ease;
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    label.radio:hover {
    color: var(--wpc-filter-primary, #e7272d);
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .input-radio:checked
    + label.radio {
    color: var(--wpc-filter-primary, #e7272d);
    font-weight: 600;
}

/* Delivery / Pickup sections — stacked for narrow sidebar */
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_delivery_section,
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .wpc_pro_pickup_section {
    display: block;
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .wpc_pro_pickup,
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .wpc_pro_delivery {
    display: block;
    grid-template-columns: none;
}

.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .wpc_pro_date_section,
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .wpc_pro_time_section {
    flex: none;
    width: 100%;
    padding: 0;
    margin-bottom: 10px;
}

/* Date and time inputs — match checkout panel input styles */
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    input.input-text,
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    input.flatpickr-input,
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    input.ui-timepicker-input {
    width: 100%;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 8px 10px;
    font-size: 13px;
    color: #1a1a1a;
    background: #fff;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
    height: auto;
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    input.input-text:focus,
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    input.flatpickr-input:focus,
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    input.ui-timepicker-input:focus {
    border-color: var(--wpc-filter-primary, #e7272d);
    box-shadow: 0 0 0 3px rgba(231, 39, 45, 0.08);
}

.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    label {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    display: block;
    margin-bottom: 4px;
}

/* Pickup / delivery messages */
.wpc-one-page-checkout-wrapper .wpc-opc-checkout-panel .wpc_pro_pickup_message,
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_delivary_message {
    font-size: 12px;
    color: #dc2626;
    margin: 4px 0 8px;
}

.wpc-one-page-checkout-wrapper .wpc-subtotal-wrap .wpc_pro_order_time {
    display: none;
}

/* ============================================================
   Tipping form override — compact sidebar
   ============================================================ */

.wpc-one-page-checkout-wrapper .wpc_pro_order_tip_wrapper > div {
    display: block;
}
.wpc-one-page-checkout-wrapper .wpc_pro_order_tip_wrapper .wpc_tip_remove_wrap {
    text-align: left;
}
.wpc-one-page-checkout-wrapper
    .wpc_pro_order_tip_wrapper
    .wpc_tip_remove_wrap
    .wpc_pro_remove_tip {
    padding: 8px 10px;
}

.wpc-one-page-checkout-wrapper .wpc_tip_preset_buttons {
    grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
    gap: 8px;
    margin-bottom: 0;
}

.wpc-one-page-checkout-wrapper .wpc-tip-btn {
    padding: 8px 10px;
    font-size: 13px;
    min-height: 36px;
}

.wpc-one-page-checkout-wrapper .wpc-custom-tip-input-group {
    padding: 3px;
}

.wpc-one-page-checkout-wrapper .wpc-currency-symbol {
    padding: 0 8px;
    font-size: 13px;
}

.wpc-one-page-checkout-wrapper .wpc_pro_custom_tip_amount {
    font-size: 13px;
    padding: 6px 8px;
}

.wpc-product-filter-wrapper .list_template_list .wpc-food-menu-item {
    height: 90%;
}
.wpc-one-page-checkout-wrapper
    .wpc-opc-checkout-panel
    .wpc_pro_order_time_settings
    .input-radio:checked::after {
    top: 3px !important;
    left: 3px !important;
}

.wpc-one-page-checkout-wrapper .wpc-food-menu-item .wpc-add-to-cart a {
    background-color: var(--wpc-filter-primary);
}

.wpc-product-filter-wrapper
    .list_template_list
    .wpc-food-menu-item
    .product-content
    h3
    a:hover {
    color: var(--wpc-filter-primary);
}

/* ==========================================================================
   Style 2 — top filter bar + horizontal category pills + 9/3 products+cart
   ========================================================================== */

.wpc-opc-style-1 .wpc-opc-top-filter-bar {
    position: relative;
    z-index: 100;
}

.wpc-opc-style-1 .wpc-opc-top-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: #fff;
    border: 1px solid #ececec;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    margin-bottom: 14px;
}

.wpc-opc-style-1 .wpc-opc-top-bar .widget {
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
}

/* Search */
.wpc-opc-style-1 .wpc-opc-search-widget {
    flex: 1 1 240px;
    position: relative;
    min-width: 200px;
}

.wpc-opc-style-1 .wpc-opc-search-widget .widget-content {
    position: relative;
    display: flex;
    align-items: center;
}

.wpc-opc-style-1 .wpc-opc-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    color: #888;
    pointer-events: none;
    z-index: 1;
}

.wpc-opc-style-1 .wpc-opc-search-widget .product-filter-search {
    width: 100%;
    height: 40px;
    padding: 0 14px 0 36px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #fafafa;
    font-size: 14px;
    transition:
        border-color 0.15s,
        background 0.15s;
}

.wpc-opc-style-1 .wpc-opc-search-widget .product-filter-search:focus {
    background: #fff;
    border-color: var(--wpc-filter-primary);
    outline: none;
}

.wpc-opc-style-1 .wpc-opc-search-widget .search {
    display: none !important;
}

/* Segmented pickup/delivery */
.wpc-opc-style-1 .wpc-opc-segmented {
    display: inline-flex;
    align-items: stretch;
    background: #f4f4f5;
    border-radius: 8px;
    padding: 3px;
    flex-wrap: nowrap;
    height: 40px;
    position: relative;
}

.wpc-opc-style-1 .wpc-opc-segmented input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
    width: 0;
    height: 0;
}

.wpc-opc-style-1 .wpc-opc-segmented label {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 0 14px;
    margin: 0;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: #555;
    transition:
        background 0.15s,
        color 0.15s,
        box-shadow 0.15s;
    white-space: nowrap;
    line-height: 34px;
}

.wpc-opc-style-1 .wpc-opc-segmented label svg {
    flex-shrink: 0;
}

.wpc-opc-style-1 .wpc-opc-segmented input[type="radio"]:checked + label {
    background: #fff;
    color: var(--wpc-filter-primary);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* Location dropdown */
.wpc-opc-style-1 .wpc-opc-location-widget {
    position: relative;
    display: flex;
    align-items: center;
    flex: 0 1 auto;
    gap: 0;
    border-top: 0;
}

.wpc-opc-style-1 .wpc-opc-location-widget .wpc-opc-input-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #888;
    display: flex;
    pointer-events: none;
    z-index: 1;
}

.wpc-opc-style-1 .wpc-opc-location-widget select {
    height: 40px;
    padding: 0 30px 0 32px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background-color: #fafafa;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
    background-repeat: no-repeat;
    background-position: right 10px center;
    min-width: 160px;
    margin: 0;
}

/* Show per-page */
.wpc-opc-style-1 .wpc-opc-perpage-widget {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fafafa;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 0 10px;
    height: 40px;
    flex: 0 1 auto;
    border-top: 0;
}

.wpc-opc-style-1 .wpc-opc-perpage-widget label {
    margin: 0;
    color: #6b7280;
    font-size: 13px;
    white-space: nowrap;
}

.wpc-opc-style-1 .wpc-opc-perpage-widget select.products-per-page {
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #1a1a1a !important;
    cursor: pointer !important;
    padding: 0 18px 0 4px !important;
    min-width: auto !important;
    height: 100% !important;
    outline: none !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>") !important;
    background-repeat: no-repeat !important;
    background-position: right 2px center !important;
    flex: 0 0 auto !important;
}

.wpc-opc-style-1 .wpc-opc-perpage-widget select.products-per-page:focus {
    box-shadow: none !important;
    border: 0 !important;
}

/* Price trigger button + popover */
.wpc-opc-style-1 .wpc-opc-price-trigger-wrap {
    position: relative;
    margin-left: auto;
    z-index: 9999;
    isolation: isolate;
}

.wpc-opc-style-1 .wpc-opc-price-trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 40px;
    padding: 0 14px;
    background: #fafafa;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    transition:
        border-color 0.15s,
        background 0.15s,
        color 0.15s;
}

.wpc-opc-style-1 .wpc-opc-price-trigger:hover,
.wpc-opc-style-1 .wpc-opc-price-trigger.is-active {
    border-color: var(--wpc-filter-primary);
    color: var(--wpc-filter-primary);
    background: #fff;
}

.wpc-opc-style-1 .wpc-opc-price-popover.wpc-opc-price-popover {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    z-index: 9999;
    width: 280px;
    background: #ffffff !important;
    background-color: #ffffff !important;
    border: 1px solid #ececec;
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
    padding: 18px 20px;
    margin: 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition:
        opacity 0.15s ease,
        transform 0.15s ease,
        visibility 0.15s;
    pointer-events: none;
}

.wpc-opc-style-1 .wpc-opc-price-popover.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.wpc-opc-style-1 .wpc-opc-price-popover .range-slider {
    margin-bottom: 8px;
}

.wpc-opc-style-1 .wpc-opc-price-popover .price-range-container,
.wpc-opc-style-1 .wpc-opc-price-popover .range-slider {
    position: relative;
    width: 100%;
}

.wpc-opc-style-1 .wpc-opc-price-popover .wpc-dual-range-slider {
    position: relative;
    width: 100%;
    max-width: 100%;
    height: 6px;
    margin: 24px 0 18px;
}

.wpc-opc-style-1 .wpc-opc-price-popover .wpc-slider-track {
    position: absolute;
    left: 0;
    right: 0;
    width: 100%;
    height: 6px;
    background-color: #e5e5e5;
    border-radius: 3px;
}

.wpc-opc-style-1 .wpc-opc-price-popover .wpc-slider-range {
    position: absolute;
    height: 100%;
    background-color: var(--wpc-filter-primary, #e7272d);
    border-radius: 3px;
}

.wpc-opc-style-1 .wpc-opc-price-popover .wpc-slider-thumb {
    position: absolute;
    width: 18px;
    height: 18px;
    background-color: var(--wpc-filter-primary, #e7272d);
    border: 3px solid #fff;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    top: 50%;
    transform: translateY(-50%);
    margin-left: -9px;
}

.wpc-opc-style-1 .wpc-opc-price-popover .wpc-price-and-reset {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 14px;
}

.wpc-opc-style-1 .wpc-opc-cat-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 24px;
    align-items: center;
    padding: 0 4px 12px;
    border-bottom: 1px solid #eee;
    margin-bottom: 20px;
    overflow-x: auto;
    overflow-y: hidden;
}

.wpc-opc-style-1 .wpc-opc-cat-pill {
    background: transparent;
    border: 0;
    padding: 8px 2px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 600;
    color: #555;
    position: relative;
    white-space: nowrap;
    font-size: 13px;
    box-shadow: none;
}

.wpc-opc-style-1 .wpc-opc-cat-pill:hover {
    color: var(--wpc-filter-primary);
}

.wpc-opc-style-1 .wpc-opc-cat-pill.is-active {
    color: var(--wpc-filter-primary);
}

.wpc-opc-style-1 .wpc-opc-cat-pill.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -13px;
    height: 2px;
    background: var(--wpc-filter-primary);
}

.wpc-opc-style-1 .wpc-opc-cat-input {
    display: none !important;
}

.wpc-opc-style-1 .wpc-opc-products-col {
    width: 66.6667% !important;
    flex: 0 0 66.6667% !important;
    max-width: 66.6667% !important;
}

.wpc-opc-style-1 .wpc-opc-cart-col {
    width: 33.3333% !important;
    flex: 0 0 33.3333% !important;
    max-width: 33.3333% !important;
}

.wpc-opc-style-1 .wpc-price-and-reset .wpc-min-price-display,
.wpc-max-price-display {
    color: var(--wpc-filter-primary);
}
.wpc-opc-style-1 .btn.reset_btn_price_filter {
    color: var(--wpc-filter-primary);
    border-color: var(--wpc-filter-primary);
}

@media (max-width: 991px) {
    .wpc-opc-style-1 .wpc-opc-products-col,
    .wpc-opc-style-1 .wpc-opc-cart-col {
        width: 100% !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }
    .wpc-opc-style-1 .wpc-opc-cart-col {
        margin-top: 20px;
    }
    .wpc-opc-style-1 .wpc-one-page-checkout-sidebar {
        position: static;
    }
    .wpc-opc-style-1 .wpc-opc-top-bar {
        gap: 10px;
    }
}
