:root {
    --lp-primary: #1c2c3a;
    /* Dark Blue-Grey */
    --lp-secondary: #197071;
    /* Teal */
    --lp-text: #333;
    --lp-text-light: #666;
    --lp-bg: #f5f7fa;
    --lp-white: #ffffff;
    --lp-border: #e0e0e0;
    --lp-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    --lp-radius: 8px;
    --lp-font: 'Roboto', 'Segoe UI', Helvetica, Arial, sans-serif;
}

#lalpath-booking-app,
#lalpath-booking-app * {
    box-sizing: border-box;
}

#lalpath-booking-app {
    font-family: var(--lp-font);
    background-color: var(--lp-bg);
    color: var(--lp-text);
    padding-bottom: 40px;
}

.lp-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Header */
.lp-header {
    background: var(--lp-white);
    padding: 15px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    margin-bottom: 20px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.lp-header .lp-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.lp-search-bar {
    display: flex;
    flex: 1;
    max-width: 600px;
    margin: 0 20px;
}

#lp-search-input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius) 0 0 var(--lp-radius);
    outline: none;
    font-size: 16px;
}

#lp-search-btn {
    padding: 10px 20px;
    background: var(--lp-secondary);
    border: none;
    border-radius: 0 var(--lp-radius) var(--lp-radius) 0;
    cursor: pointer;
    font-weight: bold;
    color: #000;
}

.lp-cart-icon {
    position: relative;
    cursor: pointer;
    padding: 5px;
    color: inherit;
    text-decoration: none;
}

.lp-cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--lp-primary);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

/* Layout */
.lp-main-layout {
    display: flex;
    gap: 30px;
}

/* Sidebar */
.lp-sidebar {
    width: 250px;
    flex-shrink: 0;
    background: var(--lp-white);
    padding: 20px;
    border-radius: var(--lp-radius);
    height: fit-content;
    box-shadow: var(--lp-shadow);
}

.lp-sidebar h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 18px;
    border-bottom: 1px solid var(--lp-border);
    padding-bottom: 10px;
}

#lp-category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

#lp-category-list li {
    padding: 10px;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s;
    color: var(--lp-text-light);
}

#lp-category-list li:hover,
#lp-category-list li.active {
    background: #e6f0fa;
    color: var(--lp-primary);
    font-weight: 500;
}

/* Product Grid */
.lp-product-list {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.lp-card {
    background: var(--lp-white);
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius);
    padding: 20px;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.lp-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--lp-shadow);
    border-color: var(--lp-primary);
}

.lp-card-header {
    margin-bottom: 15px;
}

.lp-card-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--lp-primary);
    margin: 0 0 5px 0;
    line-height: 1.4;
}

.lp-card-desc {
    font-size: 13px;
    color: var(--lp-text-light);
    margin: 0;
}

.lp-card-body {
    flex: 1;
    margin-bottom: 15px;
}

.lp-parameters {
    font-size: 12px;
    color: #888;
    background: #f9f9f9;
    padding: 8px;
    border-radius: 4px;
    margin-top: 10px;
}

.lp-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #eee;
    padding-top: 15px;
}

.lp-price {
    font-size: 18px;
    font-weight: bold;
    color: var(--lp-text);
}

.lp-btn {
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
}

.lp-btn-add {
    background: var(--lp-secondary);
    color: #fff;
}

.lp-btn-add:hover {
    background: #145a5b;
}

.lp-btn-remove {
    background: transparent;
    border-color: #ff4d4f;
    color: #ff4d4f;
}

.lp-btn-remove:hover {
    background: #fff1f0;
}

/* Responsive */
@media (max-width: 768px) {
    .lp-main-layout {
        flex-direction: column;
    }

    .lp-sidebar {
        width: 100%;
    }

    .lp-header .lp-container {
        flex-wrap: wrap;
        gap: 10px;
    }

    .lp-search-bar {
        order: 2;
        width: 100%;
        margin: 0;
        max-width: none;
    }
}

/* --- MATERIAL UI BOOKING --- */
.lp-booking-section {
    background: #fff;
    padding: 0;
    margin-top: 20px;
}

.lp-booking-header {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 25px;
    color: #444;
}

/* Material Inputs */
.lp-material-group {
    margin-bottom: 25px;
    position: relative;
}

.lp-material-input {
    width: 100%;
    padding: 10px 0;
    border: none;
    border-bottom: 1px solid #ccc;
    font-size: 16px;
    color: #333;
    outline: none;
    border-radius: 0;
    background: transparent;
    transition: border-color 0.2s;
}

.lp-material-input:focus {
    border-bottom: 2px solid var(--lp-secondary);
}

/* Custom Dark Dropdown */
.lp-dropdown-wrapper {
    position: relative;
    cursor: pointer;
}

.lp-dropdown-trigger {
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid #ccc;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    color: #666;
}

.lp-dropdown-trigger.has-value {
    color: #333;
    font-weight: 500;
    border-bottom: 2px solid var(--lp-secondary);
}

.lp-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #555;
    color: white;
    border-radius: 4px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    max-height: 250px;
    overflow-y: auto;
    display: none;
    margin-top: 5px;
}

.lp-dropdown-menu.show {
    display: block;
}

.lp-dropdown-header {
    padding: 10px 15px;
    font-size: 13px;
    font-weight: bold;
    border-bottom: 1px solid #666;
    background: #444;
}

.lp-dropdown-item {
    padding: 12px 15px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

.lp-dropdown-item:hover {
    background: #666;
}

.lp-dropdown-item.selected {
    background: var(--lp-secondary);
}

/* Status Messages */
.lp-loading-slots,
.lp-no-slots,
.lp-error-slots {
    padding: 15px;
    font-size: 14px;
    color: #888;
}

/* Helper Text */
.lp-helper-text {
    font-size: 12px;
    color: #888;
    margin-top: 5px;
}

/* Sticky Support Button */
.lp-support-btn-fixed {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #25d366;
    color: white;
    padding: 12px 20px;
    border-radius: 30px;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    cursor: pointer;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.lp-support-btn-fixed:hover {
    transform: translateY(-2px);
}

.lp-hidden {
    display: none !important;
}

.lp-booking-wizard {
    font-family: "Poppins", sans-serif;
}

.lp-step {
    border-bottom: 1px solid #eee;
}

.lp-step:last-child {
    border-bottom: none;
}

.lp-step-header {
    background: #fff;
    padding: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
}

.lp-step-number {
    background: #00bfa5;
    color: #fff;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    margin-right: 10px;
}

.lp-step-title {
    font-size: 14px;
    font-weight: 600;
    color: #2f3d47;
}

.lp-step-content {
    padding: 14px;
    border-top: 1px solid #f1f4f7;
}

.lp-step-content.lp-closed {
    display: none;
}

.lp-disabled .lp-step-header {
    opacity: .65;
    cursor: not-allowed;
}

.lp-disabled .lp-step-number {
    background: #c3ccd3;
}

.lp-btn-next {
    width: 100%;
    background: #00bfa5;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 12px;
    font-weight: 600;
}

.lp-pdp-decision-card {
    border: 1px solid #e6edf3;
    background: #fff;
    border-radius: 10px;
    padding: 16px;
    margin-top: 14px;
}

/* --- Cart Page UX Refinement --- */
body.woocommerce-cart .woocommerce-cart-form {
    width: 62%;
    float: left;
    padding-right: 24px;
}

body.woocommerce-cart .woocommerce {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 22px;
    align-items: start;
}

body.woocommerce-cart .woocommerce .woocommerce-cart-form {
    width: 100%;
    float: none;
    padding-right: 0;
    grid-column: 1;
}

body.woocommerce-cart .cart-collaterals {
    width: 100%;
    float: none;
    position: sticky;
    top: 90px;
    grid-column: 2;
}

body.woocommerce-cart .cart-collaterals .cart_totals {
    width: 100%;
    float: none;
    border: 1px solid #e4e8ec;
    border-radius: 14px;
    padding: 20px;
    background: #fff;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.06);
}

body.woocommerce-cart .actions {
    padding: 14px !important;
    background: #f8fafc;
}

body.woocommerce-cart .actions .coupon {
    display: flex;
    gap: 10px;
    align-items: center;
}

body.woocommerce-cart .actions .coupon .input-text {
    min-height: 42px;
    border-radius: 9px;
    border: 1px solid #d4dce5;
    padding: 8px 12px !important;
}

body.woocommerce-cart .actions .coupon button {
    min-height: 42px;
    border-radius: 9px;
}

body.woocommerce-cart table.shop_table {
    border: 1px solid #e5eaf0;
    border-radius: 0 0 14px 14px;
    overflow: hidden;
    background: #fff;
}

body.woocommerce-cart table.shop_table thead th {
    background: #f6f8fb;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #64748b;
}

body.woocommerce-cart table.shop_table td,
body.woocommerce-cart table.shop_table th {
    border-color: #edf1f5;
}

body.woocommerce-cart table.shop_table td.product-name a {
    color: #0f172a;
    font-weight: 600;
}

body.woocommerce-cart table.shop_table td.product-price,
body.woocommerce-cart table.shop_table td.product-subtotal {
    color: #0f172a;
    font-weight: 600;
}

body.woocommerce-cart table.shop_table td.product-quantity .qty {
    min-width: 72px;
    border: 1px solid #d6dde5;
    border-radius: 8px;
    height: 40px;
}

/* Booking card */
#lp-cart-booking-wizard {
    border: 1px solid #e4e8ec !important;
    border-radius: 14px !important;
    background: #fff !important;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.06);
    margin-bottom: 18px !important;
    overflow: hidden;
}

#lp-cart-booking-wizard>h3 {
    margin: 0 !important;
    padding: 18px 20px !important;
    border-bottom: 1px solid #edf2f7 !important;
    font-size: 18px;
    line-height: 1.2;
    font-weight: 700;
    color: #0f172a;
}

#lp-cart-booking-wizard .lp-step-header {
    padding: 14px 20px;
    background: #fbfcfe;
    border-bottom: 1px solid #edf2f7;
}

#lp-cart-booking-wizard .lp-step-content {
    padding: 16px 20px;
}

#lp-cart-booking-wizard .lp-step.lp-active .lp-step-header {
    background: #f3f8ff;
}

#lp-cart-booking-wizard .lp-step-number {
    width: 28px;
    height: 28px;
    font-size: 12px;
    margin-right: 12px;
}

#lp-cart-booking-wizard .lp-step-title {
    font-size: 16px;
    color: #1f2a37;
}

#lp-cart-booking-wizard .lp-material-input {
    border: 1px solid #d6dde5 !important;
    border-bottom: 1px solid #d6dde5 !important;
    border-radius: 10px !important;
    height: 46px;
    padding: 10px 12px !important;
    font-size: 15px;
    background: #fff;
}

#lp-cart-booking-wizard select.lp-material-input {
    padding-right: 30px !important;
}

#lp-cart-booking-wizard .lp-btn {
    border-radius: 10px;
    min-height: 44px;
    padding: 10px 14px;
    font-weight: 600;
}

#lp-cart-booking-wizard .lp-btn-next {
    background: #14b8a6;
    color: #fff;
}

#lp-cart-booking-wizard .lp-btn-next:hover {
    background: #0f9f90;
}

#lp-cart-booking-wizard #lp-cart-proceed-btn {
    background: #1d3244 !important;
    color: #fff !important;
    font-size: 16px;
}

#lp-cart-booking-wizard #lp-cart-proceed-btn:hover {
    background: #162838 !important;
}

#lp-cart-booking-wizard #lp-family-list label {
    display: block;
    border: 1px solid #e4e9ef !important;
    border-radius: 10px !important;
    background: #fff;
    margin-bottom: 8px !important;
}

#lp-cart-booking-wizard #lp-family-list label:has(input:checked) {
    border-color: #14b8a6 !important;
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.12);
}

#lp-cart-booking-wizard .lp-segmented-control {
    gap: 8px !important;
}

#lp-cart-booking-wizard .lp-segment-btn {
    border-radius: 10px;
    min-height: 44px;
    border: 1px solid #d2d9e2;
    background: #fff;
}

#lp-cart-booking-wizard .lp-segment-btn.lp-selected {
    background: #ecfeff;
    border-color: #14b8a6;
    color: #0f766e;
}

#lp-cart-booking-wizard #lp-wizard-time-dropdown {
    border: 1px solid #d6dde5 !important;
    border-radius: 10px !important;
    min-height: 46px;
}

#lp-cart-booking-wizard #lp-pincode-msg {
    min-height: 18px;
    font-size: 13px;
    margin-top: 4px;
}

#lp-cart-booking-wizard .lp-login-helper-card {
    border: 1px solid #dbe7f5;
    background: #f8fbff;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 10px;
}

#lp-cart-booking-wizard .lp-login-helper-title {
    margin: 0 0 4px;
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
}

#lp-cart-booking-wizard .lp-login-helper-sub {
    margin: 0 0 12px;
    color: #475569;
    font-size: 13px;
}

#lp-cart-booking-wizard #lp-cart-step1-login-btn {
    background: #1d3244;
    color: #fff;
    min-width: 180px;
}

#lp-cart-booking-wizard #lp-cart-step1-login-btn:hover {
    background: #162838;
}

body.woocommerce-cart .cart-collaterals .cart_totals h2 {
    font-size: 18px;
    margin: 0 0 14px;
    color: #0f172a;
}

body.woocommerce-cart .cart-collaterals .shop_table th,
body.woocommerce-cart .cart-collaterals .shop_table td {
    padding: 10px 0;
    border-color: #edf2f7;
}

/* Mobile */
@media (max-width: 1024px) {
    body.woocommerce-cart .woocommerce {
        display: block;
    }

    body.woocommerce-cart .woocommerce-cart-form,
    body.woocommerce-cart .cart-collaterals {
        width: 100%;
        float: none;
        padding-right: 0;
        position: static;
    }

    body.woocommerce-cart .cart-collaterals {
        margin-top: 16px;
    }
}

/* Mobile cart order: show booking widget above tests table */
@media (max-width: 768px) {
    body.woocommerce-cart .woocommerce {
        display: flex;
        flex-direction: column;
    }

    body.woocommerce-cart .cart-collaterals {
        order: 1;
        margin-top: 0;
        margin-bottom: 14px;
    }

    body.woocommerce-cart .woocommerce-cart-form {
        order: 2;
    }
}

@media (max-width: 768px) {
    #lp-cart-booking-wizard>h3 {
        font-size: 17px;
        padding: 14px 14px !important;
    }

    #lp-cart-booking-wizard .lp-step-header,
    #lp-cart-booking-wizard .lp-step-content {
        padding: 12px 14px;
    }

    #lp-cart-booking-wizard .lp-step-title {
        font-size: 15px;
    }

    #lp-cart-booking-wizard .lp-step-content div[style*="display:flex"] {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    #lp-cart-booking-wizard .lp-btn,
    #lp-cart-booking-wizard .lp-btn-next {
        width: 100%;
    }
}

/* Cart Shell + Progress UI */
body.woocommerce-cart {
    background: #f3f4f6;
}

.lp-cart-shell-header {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    margin: 0 0 18px;
    overflow: hidden;
}

.lp-cart-mobile-top {
    display: none;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px 12px;
    border-bottom: 1px solid #eceff3;
}

.lp-brand-pill {
    background: #ea0000;
    color: #fff;
    border-radius: 12px;
    padding: 10px 16px;
    font-size: 20px;
    line-height: 1;
    font-weight: 700;
}

.lp-mobile-cart-icon {
    color: #334155;
    text-decoration: none;
    font-size: 26px;
    position: relative;
    line-height: 1;
}

.lp-mobile-cart-icon i {
    position: absolute;
    top: -8px;
    right: -10px;
    background: #ea0000;
    color: #fff;
    border-radius: 999px;
    font-size: 12px;
    font-style: normal;
    min-width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
}

.lp-booking-for-row {
    display: flex;
    gap: 8px;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #eceff3;
    color: #475569;
    font-size: 18px;
}

.lp-booking-for-row strong {
    color: #111827;
}

.lp-user-ico {
    color: #64748b;
    font-size: 18px;
}

.lp-progress-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    background: #f8fafc;
    padding: 14px 16px;
}

.lp-progress-step {
    text-align: center;
    position: relative;
}

.lp-progress-step:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 18px;
    right: -50%;
    width: 100%;
    height: 2px;
    background: #d1d5db;
}

.lp-progress-dot {
    width: 36px;
    height: 36px;
    border-radius: 999px;
    border: 2px solid #cbd5e1;
    background: #fff;
    color: #64748b;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.lp-progress-step.is-active .lp-progress-dot,
.lp-progress-step.is-done .lp-progress-dot {
    background: #334155;
    border-color: #334155;
    color: #fff;
}

.lp-progress-step.is-done:not(:last-child)::after {
    background: #334155;
}

.lp-progress-label {
    display: block;
    margin-top: 8px;
    font-size: 14px;
    color: #475569;
    font-weight: 500;
    line-height: 1.2;
}

.lp-progress-step.is-active .lp-progress-label {
    color: #111827;
    font-weight: 700;
}

/* Tests heading + table polish */
.lp-tests-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-bottom: 0;
    border-radius: 14px 14px 0 0;
    padding: 16px 18px;
}

.lp-tests-heading h2 {
    margin: 0;
    font-size: 18px;
    color: #111827;
}

.lp-add-more-tests {
    color: #ea0000;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
}

body.woocommerce-cart .actions .button {
    background: #1d3244;
    color: #fff;
    border: 0;
}

body.woocommerce-cart .cart-collaterals .order-total th,
body.woocommerce-cart .cart-collaterals .order-total td {
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
}

@media (max-width: 768px) {
    .lp-cart-mobile-top {
        display: flex;
    }

    .lp-progress-strip {
        padding: 12px;
        gap: 8px;
    }

    .lp-progress-step:not(:last-child)::after {
        display: none;
    }

    .lp-progress-label {
        font-size: 12px;
    }

    .lp-tests-heading {
        padding: 14px;
    }

    .lp-tests-heading h2 {
        font-size: 20px;
    }

    .lp-add-more-tests {
        font-size: 14px;
    }

    body.woocommerce-cart table.shop_table thead {
        display: none;
    }

    body.woocommerce-cart table.shop_table tr.cart_item {
        display: block;
        border: 1px solid #e5e7eb;
        border-radius: 12px;
        margin: 10px 10px 14px;
        background: #fff;
        padding: 8px 10px;
    }

    body.woocommerce-cart table.shop_table tr.cart_item td {
        display: block;
        border: 0;
        padding: 6px 4px;
    }

    body.woocommerce-cart table.shop_table tr.cart_item td.product-remove,
    body.woocommerce-cart table.shop_table tr.cart_item td.product-thumbnail {
        display: none;
    }

    body.woocommerce-cart table.shop_table tr.cart_item td.product-price,
    body.woocommerce-cart table.shop_table tr.cart_item td.product-quantity,
    body.woocommerce-cart table.shop_table tr.cart_item td.product-subtotal {
        display: inline-block;
        width: auto;
        padding-right: 10px;
        font-size: 14px;
    }

    body.woocommerce-cart table.shop_table td.product-name a {
        font-size: 18px;
    }
}

/* --- Mobile View (Collapsible Categories & Search Fix) --- */
@media (max-width: 768px) {
    .lp-main-layout {
        flex-direction: column;
        gap: 20px;
    }

    /* Search Bar Fix */
    .lp-search-bar {
        flex-direction: row;
        /* Keep button next to input */
        width: 100%;
        margin-bottom: 10px;
    }

    #lp-search-input {
        width: 100%;
        /* Ensure input takes reliable space */
        min-width: 0;
        /* Prevent flex overflow */
    }

    /* Sidebar / Category Container */
    .lp-sidebar {
        width: 100%;
        padding: 0 15px;
        background: transparent;
        box-shadow: none;
        border: none;
        position: relative;
    }

    .lp-sidebar h3 {
        display: none;
    }

    /* Mobile Toggle Button (Injected via JS) */
    .lp-mobile-cat-toggle {
        display: flex !important;
        /* Visible only on mobile */
        justify-content: space-between;
        align-items: center;
        width: 100%;
        padding: 12px 20px;
        background: #fff;
        border: 1px solid #ddd;
        border-radius: 8px;
        font-weight: 500;
        cursor: pointer;
        margin-bottom: 10px;
    }

    .lp-mobile-cat-toggle:after {
        content: '▼';
        font-size: 12px;
        color: #666;
    }

    /* Category List (Collapsible) */
    #lp-category-list {
        display: none;
        /* Hidden by default */
        flex-direction: row;
        flex-wrap: wrap;
        gap: 8px;
        background: #fff;
        padding: 15px;
        border-radius: 8px;
        border: 1px solid #eee;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    }

    #lp-category-list.show {
        display: flex;
        /* Show when toggled */
    }

    #lp-category-list li {
        flex: 0 0 auto;
        padding: 6px 14px;
        border-radius: 40px;
        background: #f9f9f9;
        color: #444;
        font-size: 13px;
        font-weight: 500;
        text-align: center;
        border: 1px solid #ddd;
        margin-bottom: 0;
    }

    #lp-category-list li.active {
        background: var(--lp-primary);
        color: #fff;
        border-color: var(--lp-primary);
    }

    /* Adjust Grid for Mobile */
    .lp-product-list {
        grid-template-columns: 1fr;
        padding: 0 15px;
        width: 100%;
        /* Ensure container respects parent width */
    }

    /* Fix Header Spacing */
    .lp-header {
        margin-top: 10px;
    }

    /* Fix Card Overflow */
    .lp-card {
        width: 100% !important;
        min-width: 0;
    }

    /* Search Button Text Color */
    #lp-search-btn {
        color: #fff;
    }

    /* Fix Pincode Input Overflow */
    .lp-pincode-input {
        flex-direction: column;
        /* Stack input and button on small mobile */
        align-items: stretch;
    }

    #lp-pincode {
        width: 100%;
        margin-bottom: 8px;
        border-radius: 4px;
    }

    .lp-check-btn {
        width: 100%;
        border-radius: 4px;
    }

    /* Slot Selection fixes */
    .lp-booking-section {
        padding: 10px;
        /* Reduce padding on mobile */
    }
}

/* --- Segmented Control (Address Type) --- */
.lp-segmented-control {
    display: flex;
    width: 100%;
    gap: 10px;
    /* Space between buttons */
    background: transparent;
    border: none;
    border-radius: 0;
}

.lp-segment-btn {
    flex: 1;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 10px;
    font-size: 14px;
    cursor: pointer;
    color: #666;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.lp-segment-btn:last-child {
    border-right: 1px solid #e0e0e0;
    /* Reset */
}

.lp-segment-btn:hover {
    background: #f9f9f9;
    border-color: #ccc;
}

.lp-segment-btn.lp-selected {
    background: #e0f2f1;
    color: #00796b;
    border: 1px solid #00796b;
    font-weight: 600;
}

.lp-segment-btn span {
    font-size: 16px;
}

/* --- Custom Category Card Redesign --- */
.lp-category-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid #eee;
    transition: transform 0.2s;
    font-family: 'Poppins', sans-serif;
}

.lp-category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* Header */
.lp-cat-header {
    background: #197071;
    /* Miduty Green */
    padding: 15px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    min-height: 80px;
}

.lp-cat-title-row {
    flex: 1;
    padding-right: 10px;
}

.lp-cat-title {
    margin: 0;
    font-size: 16px;
    line-height: 1.3;
    font-weight: 600;
}

.lp-cat-title a {
    color: white;
    text-decoration: none;
}

.lp-cat-price-block {
    text-align: right;
    white-space: nowrap;
}

.lp-cat-old-price {
    font-size: 12px;
    text-decoration: line-through;
    opacity: 0.8;
    margin-bottom: 2px;
}

.lp-cat-new-price {
    font-size: 18px;
    font-weight: 700;
}

.lp-cat-discount {
    display: block;
    font-size: 10px;
    background: #FFD700;
    /* Gold */
    color: #333;
    padding: 2px 6px;
    border-radius: 4px;
    margin-top: 4px;
    font-weight: bold;
    text-align: center;
}

/* Body */
.lp-cat-body {
    padding: 15px;
    background: #fff;
    flex: 1;
}

.lp-cat-feature {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    font-size: 13px;
    color: #555;
    font-weight: 500;
}

.lp-cat-icon {
    font-size: 16px;
    width: 20px;
    text-align: center;
    opacity: 0.7;
}

/* Footer (Buttons) */
.lp-cat-footer {
    display: flex;
    padding: 15px;
    gap: 10px;
    border-top: 1px solid #f0f0f0;
    background: #fafafa;
}

.lp-cat-btn {
    flex: 1;
    padding: 10px 0;
    text-align: center;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    display: inline-flex;
    /* Ensure proper centering */
    justify-content: center;
    align-items: center;
}

.lp-btn-view {
    background: white;
    border: 1px solid #197071;
    color: #197071;
}

.lp-btn-view:hover {
    background: #e0f2f1;
}

.lp-btn-cart {
    background: #F39C12;
    /* Orange */
    border: 1px solid #F39C12;
    color: white;
}

.lp-btn-cart:hover {
    background: #d68910;
    border-color: #d68910;
}

.lp-cat-btn-single {
    width: 100%;
    flex: 1 1 100%;
}

/* Remove payment method line from frontend order views */
.woocommerce-order-overview__payment-method,
.order_details .method,
.woocommerce-table__line-item td .wc-item-meta .method {
    display: none !important;
}

/* --- FIX: Hide Standard WooCommerce Elements in Loop --- */
/* The custom card is injected into loop item title. 
   We want to hide siblings that valid hooks might have missed */
.lp-category-card~* {
    display: none !important;
}

/* Ensure the li wrapper doesn't have weird padding/borders from theme */
ul.products li.product {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
}

/* Hide Astra specific loop elements if they persist */
.astra-shop-summary-wrap {
    display: none !important;
}

.ast-woo-product-category {
    display: none !important;
}

/* Cart page: hide WooCommerce "added to cart" success strip + Checkout shortcut */
body.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-message {
    display: none !important;
}

/* --- Consultation Banner --- */
.lp-consultation-bar {
    background: linear-gradient(90deg, #197071 0%, #104e4f 100%);
    color: #fff;
    padding: 12px 0;
    font-size: 15px;
    text-align: center;
    position: relative;
    z-index: 99;
}

.lp-consultation-bar .lp-container {
    display: flex;
    justify-content: center;
    align-items: center;
}

.lp-consult-text {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.lp-phone-link {
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    margin-left: 5px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.6);
    transition: all 0.2s;
}

.lp-phone-link:hover {
    color: #ffd700;
    /* Gold */
    border-bottom-color: #ffd700;
}

.lp-pulse-phone {
    display: inline-block;
    animation: phonePulse 2s infinite;
}

@keyframes phonePulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}

@media (max-width: 768px) {
    .lp-consultation-bar {
        padding: 10px 15px;
        font-size: 13px;
    }

    .lp-consult-text {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    /* Category/Shop mobile: always one card per row */
    .woocommerce ul.products,
    .woocommerce-page ul.products {
        display: block !important;
    }

    .woocommerce ul.products li.product,
    .woocommerce-page ul.products li.product,
    .woocommerce.columns-2 ul.products li.product,
    .woocommerce.columns-3 ul.products li.product,
    .woocommerce.columns-4 ul.products li.product {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 0 16px !important;
        float: none !important;
        clear: both !important;
    }

    /* Astra/Woo category archives: force single-card list on mobile */
    body.tax-product_cat ul.products,
    body.post-type-archive-product ul.products,
    body.archive.woocommerce ul.products,
    ul.products[class*="columns-"] {
        display: block !important;
        grid-template-columns: 1fr !important;
    }

    body.tax-product_cat ul.products li.product,
    body.post-type-archive-product ul.products li.product,
    body.archive.woocommerce ul.products li.product,
    ul.products[class*="columns-"] li.product {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 100% !important;
        margin: 0 0 16px !important;
        float: none !important;
        clear: both !important;
    }

    body.tax-product_cat .lp-category-card,
    body.post-type-archive-product .lp-category-card,
    body.archive.woocommerce .lp-category-card {
        width: 100% !important;
        margin: 0 !important;
    }
}
