/* =========================================================
   MODERN CHECKOUT EXPERIENCE - DESIGN SYSTEM
   Theme: Fresh Organic / Gourmet Trust (#629d23)
========================================================= */

:root {
    --checkout-primary: #629d23;
    --checkout-primary-hover: #53871c;
    --checkout-primary-light: #f4f9ed;
    --checkout-primary-border: #d4e7c2;
    --checkout-dark: #1e2d1a;
    --checkout-text: #2c3c28;
    --checkout-text-muted: #73806f;
    --checkout-bg: #fafbf9;
    --checkout-card-bg: #ffffff;
    --checkout-border: #e6ebe0;
    --checkout-radius-lg: 20px;
    --checkout-radius-md: 14px;
    --checkout-radius-sm: 10px;
    --checkout-shadow: 0 10px 40px rgba(35, 55, 25, 0.06);
    --checkout-shadow-sm: 0 4px 15px rgba(35, 55, 25, 0.04);
}

/* =========================================================
   CHECKOUT PROGRESS STEPPER
========================================================= */
.checkout-stepper {
    background: #ffffff;
    border-radius: var(--checkout-radius-md);
    padding: 18px 24px;
    margin-bottom: 25px;
    border: 1px solid var(--checkout-border);
    box-shadow: var(--checkout-shadow-sm);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.checkout-step-item {
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 2;
    flex: 1;
}

.checkout-step-item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 2px;
    background: #e2e8de;
}

.checkout-step-num {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    background: #eef2e9;
    color: var(--checkout-text-muted);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.checkout-step-item.active .checkout-step-num {
    background: linear-gradient(135deg, var(--checkout-primary), var(--checkout-primary-hover));
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(98, 157, 35, 0.3);
}

.checkout-step-content {
    display: flex;
    flex-direction: column;
}

.checkout-step-title {
    font-size: 13.5px;
    font-weight: 700;
    color: var(--checkout-dark);
    margin: 0;
    line-height: 1.25;
}

.checkout-step-desc {
    font-size: 11.5px;
    color: var(--checkout-text-muted);
    margin: 0;
}

/* =========================================================
   CHECKOUT BILLING CARD
========================================================= */
.checkout-billing-card {
    background: var(--checkout-card-bg);
    border-radius: var(--checkout-radius-lg);
    padding: 35px 32px;
    border: 1px solid var(--checkout-border);
    box-shadow: var(--checkout-shadow);
}

/* Header */
.checkout-section-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding-bottom: 24px;
    margin-bottom: 28px;
    border-bottom: 1px solid var(--checkout-border);
}

.checkout-section-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f0f7e8 0%, #e5f2d6 100%);
    color: var(--checkout-primary);
    font-size: 22px;
    box-shadow: 0 4px 14px rgba(98, 157, 35, 0.12);
    flex-shrink: 0;
}

.checkout-section-header h3 {
    margin: 0 0 4px;
    font-size: 22px;
    font-weight: 700;
    color: var(--checkout-dark);
}

.checkout-section-header p {
    margin: 0;
    color: var(--checkout-text-muted);
    font-size: 13.5px;
}

/* Form Section */
.checkout-form-section {
    padding: 28px 0;
    border-bottom: 1px solid var(--checkout-border);
}

.checkout-form-section:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.checkout-form-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
}

.checkout-form-title > span {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f8ee;
    border-radius: 10px;
    color: var(--checkout-primary);
    font-size: 17px;
    flex-shrink: 0;
    border: 1px solid var(--checkout-primary-border);
}

.checkout-form-title h5 {
    margin: 0 0 2px;
    font-size: 16px;
    font-weight: 700;
    color: var(--checkout-dark);
}

.checkout-form-title small {
    color: var(--checkout-text-muted);
    font-size: 12px;
}

/* =========================================================
   SAVED ADDRESS CARDS
========================================================= */
.saved-address-card-item {
    border: 1.5px solid #e5ebe0;
    border-radius: 14px;
    padding: 16px 18px;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    background: #ffffff;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.saved-address-card-item:hover {
    border-color: var(--checkout-primary);
    background: #fbfdf9;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(98, 157, 35, 0.08);
}

.saved-address-card-item.active {
    border-color: var(--checkout-primary);
    background: #f7faf3;
    box-shadow: 0 6px 20px rgba(98, 157, 35, 0.12);
}

.saved-address-card-item .address-select-radio {
    accent-color: var(--checkout-primary);
    width: 18px;
    height: 18px;
    margin-top: 2px;
}

.saved-address-card-item .address-badge-default {
    background: linear-gradient(135deg, #629d23, #4f8219);
    color: #fff;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 6px;
    font-weight: 600;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

/* =========================================================
   INPUTS & LABELS
========================================================= */
.checkout-input-group label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--checkout-dark);
}

.checkout-input-group label span.req {
    color: #e53935;
    margin-left: 2px;
}

.checkout-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.checkout-input-wrapper > i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #8c9a84;
    font-size: 16px;
    z-index: 2;
    transition: color 0.2s ease;
    pointer-events: none;
}

.checkout-input-wrapper input {
    width: 100%;
    height: 52px;
    border: 1.5px solid #e3e8de;
    border-radius: 12px;
    background: #fafbf9;
    padding: 0 16px 0 46px;
    font-size: 14px;
    color: var(--checkout-text);
    font-weight: 500;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.checkout-input-wrapper input:focus {
    outline: none;
    border-color: var(--checkout-primary);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(98, 157, 35, 0.12);
}

.checkout-input-wrapper input:focus + i,
.checkout-input-wrapper:focus-within > i {
    color: var(--checkout-primary);
}

.checkout-input-wrapper input::placeholder {
    color: #aab2a5;
    font-weight: 400;
}

/* Pincode Auto-detect Badge */
.pincode-helper-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: var(--checkout-primary);
    background: #f1f7ea;
    padding: 2px 8px;
    border-radius: 6px;
    font-weight: 600;
}

/* Save Address Checkbox */
.checkout-save-address-box {
    background: #f8faf6;
    border: 1px solid #e8ede3;
    border-radius: 10px;
    padding: 12px 16px;
    transition: all 0.2s ease;
}

.checkout-save-address-box:hover {
    border-color: var(--checkout-primary-border);
    background: #f4f8f0;
}

/* =========================================================
   PAYMENT METHOD CARDS
========================================================= */
.payment-method-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.payment-method-card {
    position: relative;
    cursor: pointer;
    margin: 0;
}

.payment-method-card input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.payment-method-content {
    min-height: 100px;
    border: 1.5px solid #e3e8de;
    border-radius: 14px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 14px;
    position: relative;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    background: #ffffff;
}

.payment-method-card:hover .payment-method-content {
    border-color: var(--checkout-primary);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(98, 157, 35, 0.08);
}

.payment-method-card input:checked ~ .payment-method-content {
    border-color: var(--checkout-primary);
    background: linear-gradient(135deg, #f7faf3 0%, #f1f7e9 100%);
    box-shadow: 0 6px 20px rgba(98, 157, 35, 0.12);
}

.payment-icon {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    color: var(--checkout-primary);
    border-radius: 12px;
    font-size: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    border: 1px solid #e7ede2;
}

.payment-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding-right: 20px;
}

.payment-info strong {
    color: var(--checkout-dark);
    font-size: 13.5px;
    font-weight: 700;
}

.payment-info small {
    color: var(--checkout-text-muted);
    font-size: 11.5px;
    line-height: 1.35;
}

.payment-check {
    position: absolute;
    right: 12px;
    top: 12px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1.5px solid #d4dbce;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 10px;
    transition: all 0.2s ease;
    background: #fff;
}

.payment-method-card input:checked ~ .payment-method-content .payment-check {
    background: var(--checkout-primary);
    border-color: var(--checkout-primary);
    box-shadow: 0 2px 8px rgba(98, 157, 35, 0.35);
}

/* =========================================================
   MOBILE OTP VERIFICATION (Trust Security Box)
========================================================= */
.checkout-otp-box {
    background: linear-gradient(135deg, #ffffff 0%, #f8fbf4 100%);
    border: 1.5px solid var(--checkout-primary-border);
    border-radius: 16px;
    padding: 24px;
    margin-top: 28px;
    margin-bottom: 22px;
    box-shadow: 0 6px 20px rgba(98, 157, 35, 0.06);
    position: relative;
}

.checkout-otp-box::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--checkout-primary), var(--checkout-primary-hover));
    border-radius: 16px 0 0 16px;
}

.phone-target-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #eef5e6;
    border: 1px solid var(--checkout-primary-border);
    padding: 3px 12px;
    border-radius: 20px;
    color: var(--checkout-dark);
    font-weight: 700;
    font-size: 13px;
}

/* Terms */
.checkout-terms {
    margin-top: 25px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.checkout-terms input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: var(--checkout-primary);
    cursor: pointer;
}

.checkout-terms label {
    font-size: 13px;
    color: #555;
    line-height: 1.5;
    cursor: pointer;
}

.checkout-terms a {
    color: var(--checkout-primary);
    font-weight: 600;
    text-decoration: underline;
}

/* Place Order CTA Button */
.checkout-place-order {
    width: 100%;
    min-height: 56px;
    margin-top: 24px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--checkout-primary) 0%, #4e8019 100%);
    border: none;
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(98, 157, 35, 0.28);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.checkout-place-order:hover {
    background: linear-gradient(135deg, #578c1f 0%, #447214 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(98, 157, 35, 0.36);
    color: #ffffff;
}

/* Trust Badges Bar */
.checkout-trust-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px dashed #e3e8de;
    flex-wrap: wrap;
}

.checkout-trust-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--checkout-text-muted);
    font-weight: 600;
}

.checkout-trust-item i {
    color: var(--checkout-primary);
    font-size: 14px;
}

/* =========================================================
   RIGHT SIDEBAR - ORDER SUMMARY (Sticky & Modern)
========================================================= */
.right-card-sidebar-checkout {
    background: #ffffff;
    border-radius: var(--checkout-radius-lg);
    border: 1px solid var(--checkout-border);
    box-shadow: var(--checkout-shadow);
    padding: 26px 24px;
    position: sticky;
    top: 90px;
}

.right-card-sidebar-checkout .top-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 15px;
    border-bottom: 1.5px solid var(--checkout-border);
    margin-bottom: 15px;
    font-weight: 700;
    font-size: 13.5px;
    color: var(--checkout-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.single-shop-list {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #f0f4ec;
}

.single-shop-list .left-area {
    display: flex;
    align-items: center;
    gap: 12px;
}

.single-shop-list .thumbnail {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    overflow: hidden;
    background: #f8faf6;
    border: 1px solid #e8ede3;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.single-shop-list .thumbnail img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.single-shop-list .title {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--checkout-dark);
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.single-shop-list .title:hover {
    color: var(--checkout-primary);
}

.single-shop-list .price {
    font-weight: 700;
    font-size: 14px;
    color: var(--checkout-dark);
    white-space: nowrap;
}

/* Total Price Highlight Box */
.checkout-total-box {
    background: linear-gradient(135deg, #f7faf2 0%, #edf5e6 100%);
    border-radius: 12px;
    padding: 14px 18px;
    margin-top: 15px;
    border: 1px solid var(--checkout-primary-border);
}

/* =========================================================
   RESPONSIVE MEDIA QUERIES
========================================================= */
@media (max-width: 991px) {
    .payment-method-grid {
        grid-template-columns: 1fr;
    }
    .right-card-sidebar-checkout {
        position: static;
        margin-bottom: 30px;
    }
    .checkout-stepper {
        padding: 14px 16px;
    }
    .checkout-step-item:not(:last-child)::after {
        display: none;
    }
}

@media (max-width: 767px) {
    .checkout-billing-card {
        padding: 22px 16px;
        border-radius: 16px;
    }
    .checkout-stepper {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
    .checkout-step-item {
        width: 100%;
    }
    .checkout-section-header {
        align-items: flex-start;
        gap: 12px;
    }
    .checkout-section-icon {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }
}