/* Store cart and checkout upgrade */
.store-page-heading{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:16px;
    flex-wrap:wrap;
    margin:0 0 18px;
    padding:0 0 10px;
    border-bottom:2px solid #2563eb;
}

.store-page-heading h1{
    margin:0;
    font-size:22px;
    line-height:1.25;
    font-weight:700;
    color:#111827;
}

.store-page-heading a{
    color:#2563eb;
    text-decoration:none;
    font-weight:700;
}

.store-cart-layout,
.store-checkout-layout{
    display:grid;
    grid-template-columns:minmax(0,1fr) 340px;
    gap:22px;
    align-items:start;
}

.store-cart-items{
    display:grid;
    gap:14px;
}

.store-cart-item{
    display:grid;
    grid-template-columns:96px minmax(0,1fr) auto;
    gap:16px;
    align-items:center;
    padding:16px;
    border:1px solid #dbe3ed;
    border-radius:18px;
    background:#fff;
    box-shadow:0 2px 10px rgba(15,23,42,.04);
}

.store-cart-item-image{
    width:96px;
    height:96px;
    border:1px solid #e5edf5;
    border-radius:14px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#f8fafc;
    overflow:hidden;
}

.store-cart-item-image img{
    max-width:100%;
    max-height:100%;
    object-fit:contain;
}

.store-cart-item-info h2{
    margin:0 0 8px;
    font-size:17px;
    line-height:1.3;
}

.store-cart-item-info h2 a{
    color:#111827;
    text-decoration:none;
}

.store-cart-item-info h2 a:hover{
    color:#c2410c;
}

.store-cart-item-meta{
    display:flex;
    gap:12px;
    flex-wrap:wrap;
    color:#64748b;
    font-size:14px;
}

.cart-stock-warning{
    margin-top:8px;
    color:#dc2626;
    font-weight:700;
    font-size:13px;
}

.store-cart-item-actions{
    display:grid;
    justify-items:end;
    gap:10px;
}

.store-cart-qty{
    display:inline-flex;
    align-items:center;
    border:1px solid #dbe3ed;
    border-radius:12px;
    overflow:hidden;
    background:#fff;
}

.store-cart-qty form{
    margin:0;
}

.store-cart-qty button{
    width:34px;
    height:34px;
    border:0;
    background:#f8fafc;
    cursor:pointer;
    font-size:18px;
    font-weight:800;
}

.store-cart-qty button:disabled{
    opacity:.45;
    cursor:not-allowed;
}

.store-cart-qty span{
    min-width:38px;
    text-align:center;
    font-weight:800;
}

.store-cart-line-total{
    font-size:17px;
    color:#111827;
}

.store-cart-remove{
    border:0;
    background:transparent;
    color:#dc2626;
    font-weight:800;
    cursor:default;
}

.checkout-step-tab[hidden]{
    display:none !important;
}

.store-cart-summary,
.store-checkout-summary{
    position:sticky;
    top:18px;
    padding:18px;
    border:1px solid #dbe3ed;
    border-radius:18px;
    background:#fff;
    box-shadow:0 2px 10px rgba(15,23,42,.04);
}

.store-cart-summary h2,
.store-checkout-summary h2,
.checkout-form h2{
    margin:0 0 14px;
    font-size:18px;
    line-height:1.3;
}

.summary-line,
.checkout-summary-total{
    display:flex;
    justify-content:space-between;
    gap:16px;
    padding:10px 0;
    border-bottom:1px solid #eef2f7;
}

.summary-note{
    margin:14px 0;
    padding:12px;
    border-radius:12px;
    background:#f8fafc;
    color:#475569;
    font-size:14px;
    line-height:1.45;
}

.store-cart-checkout-btn,
.store-checkout-submit-btn{
    width:100%;
    text-align:center;
    justify-content:center;
}

.empty-cart-card{
    text-align:center;
    padding:34px;
}

.checkout-form-card{
    padding:22px;
}

.checkout-info-box{
    display:grid;
    gap:4px;
    margin:0 0 18px;
    padding:14px 16px;
    border:1px solid #dbe3ed;
    border-radius:14px;
    background:#f8fafc;
    color:#334155;
}

.checkout-info-box strong{
    color:#0f172a;
}

.checkout-form{
    display:grid;
    gap:14px;
}

.checkout-form .form-row{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:14px;
}

.checkout-form label{
    display:block;
    margin:0 0 7px;
    font-weight:700;
    color:#111827;
}

.checkout-form input,
.checkout-form textarea{
    width:100%;
    box-sizing:border-box;
}

.checkout-form h2{
    margin-top:10px;
    padding-top:10px;
    border-top:1px solid #eef2f7;
}

.checkout-form h2:first-of-type{
    margin-top:0;
    padding-top:0;
    border-top:0;
}

.checkout-summary-product{
    display:flex;
    justify-content:space-between;
    gap:14px;
    padding:12px 0;
    border-bottom:1px solid #eef2f7;
}

.checkout-summary-product div{
    display:grid;
    gap:4px;
}

.checkout-summary-product span{
    color:#64748b;
    font-size:13px;
}

.checkout-summary-total{
    font-size:18px;
    font-weight:800;
    border-bottom:0;
}

.checkout-submit-mobile{
    display:none !important;
}

@media(max-width:960px){
    .store-cart-layout,
    .store-checkout-layout{
        grid-template-columns:1fr;
    }

    .store-cart-summary,
    .store-checkout-summary{
        position:static;
    }

    .store-checkout-submit-btn{
        display:none !important;
    }

    .checkout-submit-mobile{
        display:inline-flex !important;
        justify-content:center;
    }
}

@media(max-width:680px){
    .store-cart-item{
        grid-template-columns:80px minmax(0,1fr);
    }

    .store-cart-item-actions{
        grid-column:1 / -1;
        justify-items:start;
        display:flex;
        align-items:center;
        justify-content:space-between;
        width:100%;
        flex-wrap:wrap;
    }

    .store-cart-item-image{
        width:80px;
        height:80px;
    }

    .checkout-form .form-row{
        grid-template-columns:1fr;
    }
}

/* Cart page final restore override */
.store-cart-page{
    width:100% !important;
    box-sizing:border-box !important;
}

.store-cart-layout{
    display:grid !important;
    grid-template-columns:minmax(0,1fr) 340px !important;
    gap:22px !important;
    align-items:start !important;
}

.store-cart-items{
    display:grid !important;
    gap:14px !important;
}

.store-cart-item{
    display:grid !important;
    grid-template-columns:96px minmax(0,1fr) auto !important;
    gap:16px !important;
    align-items:center !important;
    padding:16px !important;
    border:1px solid #dbe3ed !important;
    border-radius:18px !important;
    background:#fff !important;
    box-shadow:0 2px 10px rgba(15,23,42,.04) !important;
}

.store-cart-summary{
    position:sticky !important;
    top:18px !important;
    padding:18px !important;
    border:1px solid #dbe3ed !important;
    border-radius:18px !important;
    background:#fff !important;
    box-shadow:0 2px 10px rgba(15,23,42,.04) !important;
}

@media(max-width:960px){
    .store-cart-layout{
        grid-template-columns:1fr !important;
    }

    .store-cart-summary{
        position:static !important;
    }
}

@media(max-width:680px){
    .store-cart-item{
        grid-template-columns:80px minmax(0,1fr) !important;
    }

    .store-cart-item-actions{
        grid-column:1 / -1 !important;
        justify-items:start !important;
        display:flex !important;
        align-items:center !important;
        justify-content:space-between !important;
        width:100% !important;
        flex-wrap:wrap !important;
    }
}

/* Cart quantity input wider and minimum-one visual */
.store-cart-qty span{
    min-width:50px !important;
    width:50px !important;
    text-align:center !important;
    font-weight:800 !important;
}

.store-cart-qty button{
    width:36px !important;
    min-width:36px !important;
}


/* Keep the separator between product total and checkout button visible after removing the notice. */
.store-cart-summary .summary-divider{
    height:1px;
    margin:0 0 14px;
    background:#eef2f7;
}

.store-cart-summary .summary-line{
    border-bottom:0;
    padding-bottom:10px;
}

/* Checkout alignment fix: keep the form card aligned with the order summary. */
.store-checkout-layout > .checkout-form-card{
    margin:0 !important;
    max-width:none !important;
    width:100% !important;
    align-self:start !important;
}

.store-checkout-layout > .store-checkout-summary{
    align-self:start !important;
}


/* Checkout width balance: make customer form slightly narrower and order summary slightly wider. */
.store-checkout-layout{
    grid-template-columns:minmax(0, 1fr) 390px !important;
    gap:22px !important;
}

.store-checkout-summary{
    width:100% !important;
    box-sizing:border-box !important;
}

@media(max-width:960px){
    .store-checkout-layout{
        grid-template-columns:1fr !important;
    }
}

/* Checkout width balance: make customer form a little narrower and order summary wider. */
.store-checkout-layout{
    grid-template-columns:minmax(0,1fr) 390px !important;
    gap:22px !important;
    align-items:start !important;
}

.store-checkout-summary{
    width:100% !important;
    box-sizing:border-box !important;
}

@media(max-width:960px){
    .store-checkout-layout{
        grid-template-columns:1fr !important;
    }
}

/* Checkout shipping / billing / payment flow */
.checkout-address-section {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid #e6e8ef;
}

.checkout-address-section h2 {
    margin: 0 0 14px;
    font-size: 18px;
}

.checkout-address-fields {
    margin-top: 12px;
}

.checkout-checkbox-line,
.checkout-radio-line {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 12px 0;
    cursor: pointer;
}

.checkout-checkbox-line input,
.checkout-radio-line input {
    margin-top: 4px;
}

.checkout-billing-toggle {
    padding: 12px;
    background: #f7f8fb;
    border: 1px solid #e4e6ee;
    border-radius: 10px;
}

.checkout-payment-method {
    padding: 14px;
    background: #f7f8fb;
    border: 1px solid #e4e6ee;
    border-radius: 10px;
}

.checkout-radio-line span {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.checkout-radio-line small,
.checkout-summary-payment-note,
.checkout-success-payment-note {
    color: #667085;
    line-height: 1.5;
}

.checkout-summary-payment-note {
    margin-top: 14px;
    padding: 12px;
    background: #f7f8fb;
    border: 1px solid #e4e6ee;
    border-radius: 10px;
    font-size: 13px;
}


/* Checkout form visual polish - live storefront */
.store-checkout-page{
    width:100%;
    box-sizing:border-box;
}

.store-checkout-layout{
    grid-template-columns:minmax(0, 1fr) 380px !important;
    gap:26px !important;
    align-items:start !important;
}

.store-checkout-layout > .checkout-form-card,
.store-checkout-layout > .store-checkout-summary{
    border-radius:20px !important;
    border:1px solid #e2e8f0 !important;
    box-shadow:0 8px 26px rgba(15,23,42,.06) !important;
}

.checkout-form-card{
    padding:26px !important;
    background:#fff !important;
}

.checkout-form{
    display:grid !important;
    gap:0 !important;
}

.checkout-form > h2{
    margin:0 0 18px !important;
    padding:0 !important;
    border:0 !important;
    font-size:20px !important;
    line-height:1.25 !important;
    color:#0f172a !important;
}

.checkout-form > label,
.checkout-address-fields > label,
.checkout-billing-wrapper > label,
.checkout-payment-section > label{
    margin-top:14px !important;
}

.checkout-form .form-row{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    gap:18px !important;
    margin:0 !important;
}

.checkout-form .form-row > div{
    min-width:0 !important;
}

.checkout-form label{
    margin:0 0 8px !important;
    font-size:13px !important;
    line-height:1.35 !important;
    font-weight:700 !important;
    color:#334155 !important;
}

.checkout-form input,
.checkout-form select,
.checkout-form textarea{
    width:100% !important;
    box-sizing:border-box !important;
    border:1px solid #cbd5e1 !important;
    border-radius:12px !important;
    background:#fff !important;
    color:#0f172a !important;
    font-size:15px !important;
    line-height:1.4 !important;
    outline:none !important;
    transition:border-color .15s ease, box-shadow .15s ease, background-color .15s ease !important;
}

.checkout-form input,
.checkout-form select{
    min-height:46px !important;
    padding:10px 13px !important;
}

.checkout-form textarea{
    min-height:98px !important;
    padding:12px 13px !important;
    resize:vertical !important;
}

.checkout-form input:focus,
.checkout-form select:focus,
.checkout-form textarea:focus{
    border-color:#2563eb !important;
    box-shadow:0 0 0 3px rgba(37,99,235,.12) !important;
}

.checkout-form input::placeholder,
.checkout-form textarea::placeholder{
    color:#94a3b8 !important;
}

.checkout-info-box{
    margin:0 0 24px !important;
    padding:16px 18px !important;
    border-radius:16px !important;
    border:1px solid #dbeafe !important;
    background:#eff6ff !important;
}

.checkout-info-box strong{
    font-size:15px !important;
    color:#1e3a8a !important;
}

.checkout-info-box span{
    font-size:14px !important;
    line-height:1.5 !important;
    color:#334155 !important;
}

.checkout-address-section{
    margin-top:28px !important;
    padding:22px !important;
    border:1px solid #e2e8f0 !important;
    border-radius:18px !important;
    background:#f8fafc !important;
}

.checkout-address-section h2{
    margin:0 0 18px !important;
    font-size:19px !important;
    line-height:1.25 !important;
    color:#0f172a !important;
}

.checkout-address-fields{
    margin-top:16px !important;
    display:grid !important;
    gap:14px !important;
}

.checkout-address-fields .form-row{
    margin:0 !important;
}

.checkout-billing-wrapper{
    margin-top:16px !important;
    padding-top:4px !important;
}

.checkout-billing-toggle{
    margin:0 !important;
    padding:14px 16px !important;
    border-radius:14px !important;
    border:1px solid #cbd5e1 !important;
    background:#fff !important;
}

.checkout-checkbox-line,
.checkout-radio-line{
    display:flex !important;
    align-items:flex-start !important;
    gap:12px !important;
    margin:0 !important;
    font-weight:600 !important;
    color:#334155 !important;
}

.checkout-checkbox-line input,
.checkout-radio-line input{
    width:auto !important;
    min-height:0 !important;
    margin:3px 0 0 !important;
    padding:0 !important;
    flex:0 0 auto !important;
}

.checkout-payment-section{
    background:#fff7ed !important;
    border-color:#fed7aa !important;
}

.checkout-payment-method{
    padding:16px !important;
    border:1px solid #fdba74 !important;
    border-radius:16px !important;
    background:#fff !important;
}

.checkout-radio-line strong{
    color:#111827 !important;
    font-size:15px !important;
}

.checkout-radio-line small{
    margin-top:3px !important;
    color:#64748b !important;
    font-size:13px !important;
    line-height:1.5 !important;
}

.checkout-submit-mobile{
    margin-top:22px !important;
    min-height:48px !important;
    border-radius:12px !important;
}

.store-checkout-summary{
    padding:22px !important;
    border-radius:20px !important;
}

.store-checkout-summary h2{
    margin:0 0 16px !important;
    font-size:20px !important;
    color:#0f172a !important;
}

.checkout-summary-product{
    padding:14px 0 !important;
    gap:16px !important;
}

.checkout-summary-product strong{
    line-height:1.35 !important;
}

.checkout-summary-product span{
    margin-top:3px !important;
    color:#64748b !important;
}

.checkout-summary-total{
    margin-top:8px !important;
    padding-top:16px !important;
    border-top:1px solid #e2e8f0 !important;
    font-size:19px !important;
}

.store-checkout-submit-btn{
    margin-top:18px !important;
    min-height:48px !important;
    border-radius:12px !important;
    font-size:15px !important;
    font-weight:800 !important;
}

@media(max-width:960px){
    .store-checkout-layout{
        grid-template-columns:1fr !important;
        gap:20px !important;
    }

    .checkout-form-card{
        padding:20px !important;
    }

    .store-checkout-summary{
        padding:20px !important;
    }
}

@media(max-width:680px){
    .store-page-heading{
        gap:8px !important;
    }

    .store-page-heading h1{
        font-size:20px !important;
    }

    .checkout-form-card{
        padding:16px !important;
        border-radius:16px !important;
    }

    .checkout-form .form-row{
        grid-template-columns:1fr !important;
        gap:14px !important;
    }

    .checkout-address-section{
        margin-top:20px !important;
        padding:16px !important;
        border-radius:16px !important;
    }

    .checkout-form input,
    .checkout-form select{
        min-height:44px !important;
    }

    .checkout-form textarea{
        min-height:90px !important;
    }
}


/* Checkout e-mail label spacing fix */
.checkout-form .form-row{
    row-gap:20px !important;
}

.checkout-form .form-row + .form-row{
    margin-top:4px !important;
}

.checkout-form .form-row label{
    display:block !important;
    margin-top:4px !important;
    margin-bottom:8px !important;
}

.checkout-form .form-row > div{
    padding-top:2px !important;
}


/* Checkout form structural standardization */
.checkout-form{
    display:flex !important;
    flex-direction:column !important;
    gap:20px !important;
}

.checkout-form > h2,
.checkout-form > label,
.checkout-form > input,
.checkout-form > textarea,
.checkout-form > select{
    margin:0 !important;
}

.checkout-section-card{
    display:flex !important;
    flex-direction:column !important;
    gap:18px !important;
    margin:0 !important;
    padding:22px !important;
    border:1px solid #e2e8f0 !important;
    border-radius:18px !important;
    background:#f8fafc !important;
}

.checkout-section-card-flat{
    background:#fff !important;
    border-color:#eef2f7 !important;
    padding:0 !important;
}

.checkout-section-title{
    display:flex !important;
    align-items:center !important;
    justify-content:space-between !important;
    gap:12px !important;
    margin:0 !important;
    padding:0 0 2px !important;
}

.checkout-section-title.nested{
    padding-top:4px !important;
}

.checkout-section-title h2,
.checkout-form .checkout-section-title h2{
    margin:0 !important;
    padding:0 !important;
    border:0 !important;
    font-size:19px !important;
    line-height:1.25 !important;
    font-weight:800 !important;
    color:#0f172a !important;
}

.checkout-field-grid{
    display:grid !important;
    gap:18px !important;
    margin:0 !important;
}

.checkout-field-grid.two{
    grid-template-columns:minmax(0, 1fr) minmax(0, 1fr) !important;
}

.checkout-field{
    display:flex !important;
    flex-direction:column !important;
    gap:8px !important;
    min-width:0 !important;
    margin:0 !important;
    padding:0 !important;
}

.checkout-field label,
.checkout-form .checkout-field label,
.checkout-address-fields .checkout-field label,
.checkout-billing-wrapper .checkout-field label,
.checkout-payment-section .checkout-field label{
    display:block !important;
    margin:0 !important;
    padding:0 !important;
    font-size:13px !important;
    line-height:1.35 !important;
    font-weight:800 !important;
    color:#334155 !important;
}

.checkout-field input,
.checkout-field select,
.checkout-field textarea,
.checkout-form .checkout-field input,
.checkout-form .checkout-field select,
.checkout-form .checkout-field textarea{
    width:100% !important;
    box-sizing:border-box !important;
    margin:0 !important;
    border:1px solid #cbd5e1 !important;
    border-radius:12px !important;
    background:#fff !important;
    color:#0f172a !important;
    font-size:15px !important;
    line-height:1.4 !important;
    outline:none !important;
    transition:border-color .15s ease, box-shadow .15s ease, background-color .15s ease !important;
}

.checkout-field input,
.checkout-field select{
    min-height:46px !important;
    padding:10px 13px !important;
}

.checkout-field textarea{
    min-height:98px !important;
    padding:12px 13px !important;
    resize:vertical !important;
}

.checkout-field input:focus,
.checkout-field select:focus,
.checkout-field textarea:focus{
    border-color:#2563eb !important;
    box-shadow:0 0 0 3px rgba(37,99,235,.12) !important;
}

.checkout-address-section{
    margin:0 !important;
    padding:0 !important;
    border:0 !important;
    border-radius:0 !important;
    background:transparent !important;
}

.checkout-address-fields{
    display:flex !important;
    flex-direction:column !important;
    gap:18px !important;
    margin:0 !important;
    padding:0 !important;
}

.checkout-billing-section{
    gap:18px !important;
}

.checkout-billing-wrapper{
    display:flex;
    flex-direction:column;
    gap:18px;
    margin:0 !important;
    padding:0 !important;
}

.checkout-billing-toggle{
    margin:0 !important;
    padding:15px 16px !important;
    border-radius:14px !important;
    border:1px solid #cbd5e1 !important;
    background:#fff !important;
}

.checkout-checkbox-line,
.checkout-radio-line,
.checkout-option-line{
    display:flex !important;
    align-items:flex-start !important;
    gap:12px !important;
    margin:0 !important;
    padding:0 !important;
    line-height:1.45 !important;
    font-weight:700 !important;
    color:#334155 !important;
}

.checkout-checkbox-line input,
.checkout-radio-line input,
.checkout-option-line input{
    width:auto !important;
    min-height:0 !important;
    margin:3px 0 0 !important;
    padding:0 !important;
    flex:0 0 auto !important;
}

.checkout-payment-section{
    background:#fff7ed !important;
    border-color:#fed7aa !important;
}

.checkout-payment-method{
    margin:0 !important;
    padding:16px !important;
    border:1px solid #fdba74 !important;
    border-radius:16px !important;
    background:#fff !important;
}

.checkout-note-section{
    padding-top:2px !important;
}

.checkout-submit-mobile{
    margin-top:2px !important;
}

@media(max-width:680px){
    .checkout-section-card{
        padding:16px !important;
        border-radius:16px !important;
        gap:16px !important;
    }

    .checkout-section-card-flat{
        padding:0 !important;
    }

    .checkout-field-grid.two{
        grid-template-columns:1fr !important;
        gap:16px !important;
    }

    .checkout-address-fields{
        gap:16px !important;
    }

    .checkout-field input,
    .checkout-field select{
        min-height:44px !important;
    }
}


/* Checkout final uniform form layout fix */
.store-checkout-page{
    background:transparent !important;
}

.checkout-form-card{
    padding:24px !important;
    border-radius:20px !important;
}

.checkout-form{
    display:block !important;
}

.checkout-form > h2,
.checkout-form > .checkout-section-title{
    margin:0 0 16px !important;
    font-size:20px !important;
    line-height:1.25 !important;
    font-weight:900 !important;
    color:#0f172a !important;
}

/* Make every main form section use the same card language */
.checkout-section-card,
.checkout-address-section{
    margin:0 0 22px !important;
    padding:22px !important;
    border:1px solid #dbe3ef !important;
    border-radius:18px !important;
    background:#f8fafc !important;
    box-shadow:none !important;
}

/* First customer info block was visually different; normalize it */
.checkout-form > h2:first-of-type{
    margin-top:0 !important;
}

.checkout-form > h2:first-of-type,
.checkout-address-section h2,
.checkout-section-card h2,
.checkout-billing-wrapper h2{
    display:block !important;
    margin:0 0 18px !important;
    padding:0 !important;
    border:0 !important;
    font-size:20px !important;
    line-height:1.25 !important;
    font-weight:900 !important;
    color:#0f172a !important;
}

/* If customer info fields are direct children after first h2, visually group them */
.checkout-form > h2:first-of-type + .form-row,
.checkout-form > h2:first-of-type + .checkout-field-grid{
    margin-top:0 !important;
}

/* Field system */
.checkout-field,
.checkout-form > label,
.checkout-address-fields > label{
    display:block !important;
    margin:0 0 8px !important;
}

.checkout-field-grid,
.checkout-form .form-row{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    column-gap:18px !important;
    row-gap:18px !important;
    margin:0 0 18px !important;
}

.checkout-field-grid.full,
.checkout-field.full{
    grid-column:1 / -1 !important;
}

.checkout-field label,
.checkout-form label:not(.checkout-checkbox-line):not(.checkout-radio-line),
.checkout-address-fields label:not(.checkout-checkbox-line):not(.checkout-radio-line){
    display:block !important;
    margin:0 0 8px !important;
    padding:0 !important;
    font-size:13px !important;
    line-height:1.35 !important;
    font-weight:800 !important;
    color:#233451 !important;
}

/* direct labels must get consistent spacing too */
.checkout-form > label:not(.checkout-checkbox-line):not(.checkout-radio-line),
.checkout-address-fields > label:not(.checkout-checkbox-line):not(.checkout-radio-line){
    margin-top:0 !important;
    margin-bottom:8px !important;
}

/* All inputs same visual size */
.checkout-form input,
.checkout-form select,
.checkout-form textarea{
    width:100% !important;
    box-sizing:border-box !important;
    border:1px solid #c7d3e3 !important;
    border-radius:12px !important;
    background:#fff !important;
    color:#0f172a !important;
    font-size:15px !important;
    line-height:1.4 !important;
    outline:none !important;
}

.checkout-form input,
.checkout-form select{
    height:46px !important;
    min-height:46px !important;
    padding:10px 13px !important;
}

.checkout-form textarea{
    min-height:96px !important;
    padding:12px 13px !important;
    resize:vertical !important;
}

.checkout-form input:focus,
.checkout-form select:focus,
.checkout-form textarea:focus{
    border-color:#2563eb !important;
    box-shadow:0 0 0 3px rgba(37,99,235,.12) !important;
}

.checkout-form input::placeholder,
.checkout-form textarea::placeholder{
    color:#94a3b8 !important;
}

/* Direct label+input pairs inside address fields: force equal spacing */
.checkout-address-fields{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:0 !important;
    margin-top:0 !important;
}

.checkout-address-fields > input,
.checkout-address-fields > select,
.checkout-address-fields > textarea{
    margin:0 0 18px !important;
}

.checkout-address-fields > .form-row{
    margin:0 0 18px !important;
}

/* Direct customer e-mail field after first row */
.checkout-form > input[name="customer_email"]{
    margin:0 0 22px !important;
}

/* Same style for info box */
.checkout-info-box{
    margin:0 0 22px !important;
    padding:18px 20px !important;
    border-radius:16px !important;
    border:1px solid #cfe1ff !important;
    background:#eff6ff !important;
}

/* Billing toggle inside its own card should not look alien */
.checkout-billing-toggle{
    margin:0 !important;
    padding:14px 16px !important;
    border-radius:14px !important;
    border:1px solid #cbd5e1 !important;
    background:#fff !important;
}

.checkout-billing-wrapper{
    margin-top:20px !important;
    padding-top:0 !important;
}

.checkout-payment-section{
    background:#fff7ed !important;
    border-color:#fed7aa !important;
}

.checkout-payment-method{
    padding:16px !important;
    border:1px solid #fdba74 !important;
    border-radius:16px !important;
    background:#fff !important;
}

.checkout-checkbox-line,
.checkout-radio-line{
    display:flex !important;
    align-items:flex-start !important;
    gap:12px !important;
    margin:0 !important;
    font-weight:700 !important;
}

.checkout-checkbox-line input,
.checkout-radio-line input{
    width:auto !important;
    height:auto !important;
    min-height:0 !important;
    margin:3px 0 0 !important;
    padding:0 !important;
    flex:0 0 auto !important;
}

.checkout-submit-mobile{
    margin-top:4px !important;
    height:50px !important;
    border-radius:12px !important;
}

@media(max-width:680px){
    .checkout-form-card{
        padding:16px !important;
    }

    .checkout-section-card,
    .checkout-address-section{
        padding:16px !important;
        border-radius:16px !important;
        margin-bottom:18px !important;
    }

    .checkout-field-grid,
    .checkout-form .form-row{
        grid-template-columns:1fr !important;
        gap:14px !important;
        margin-bottom:16px !important;
    }
}


/* FINAL CHECKOUT VERTICAL RHYTHM FIX
   All checkout sections use the same vertical spacing:
   section title -> fields: 18px
   label -> input: 8px
   row -> next row: 18px
*/

.checkout-form-card{
    padding:24px !important;
}

.checkout-section-card,
.checkout-address-section{
    padding:22px !important;
    margin:0 0 22px !important;
    border:1px solid #dbe3ef !important;
    border-radius:18px !important;
    background:#f8fafc !important;
}

/* Section title spacing */
.checkout-section-title,
.checkout-address-section > h2,
.checkout-billing-wrapper > h2,
.checkout-payment-section > h2{
    margin:0 0 18px !important;
    padding:0 !important;
}

.checkout-section-title h2,
.checkout-address-section > h2,
.checkout-billing-wrapper > h2,
.checkout-payment-section > h2{
    margin:0 !important;
    padding:0 !important;
    border:0 !important;
    font-size:20px !important;
    line-height:1.25 !important;
    font-weight:900 !important;
    color:#0f172a !important;
}

/* Field containers */
.checkout-field{
    margin:0 0 18px !important;
    padding:0 !important;
}

.checkout-field:last-child{
    margin-bottom:0 !important;
}

.checkout-field-grid,
.checkout-field-grid.two,
.checkout-form .form-row{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    column-gap:18px !important;
    row-gap:18px !important;
    margin:0 0 18px !important;
    padding:0 !important;
}

.checkout-field-grid:last-child,
.checkout-form .form-row:last-child{
    margin-bottom:0 !important;
}

.checkout-field-grid > .checkout-field,
.checkout-form .form-row > div{
    margin:0 !important;
    padding:0 !important;
}

/* Label rhythm */
.checkout-field label,
.checkout-form .form-row label,
.checkout-address-fields label,
.checkout-form > label:not(.checkout-checkbox-line):not(.checkout-radio-line){
    display:block !important;
    margin:0 0 8px !important;
    padding:0 !important;
    font-size:13px !important;
    line-height:1.35 !important;
    font-weight:800 !important;
    color:#233451 !important;
}

/* Input rhythm */
.checkout-form input,
.checkout-form select{
    height:46px !important;
    min-height:46px !important;
    margin:0 !important;
    padding:10px 13px !important;
    box-sizing:border-box !important;
    border:1px solid #c7d3e3 !important;
    border-radius:12px !important;
    background:#fff !important;
    font-size:15px !important;
    line-height:1.4 !important;
}

.checkout-form textarea{
    min-height:96px !important;
    margin:0 !important;
    padding:12px 13px !important;
    box-sizing:border-box !important;
    border:1px solid #c7d3e3 !important;
    border-radius:12px !important;
    background:#fff !important;
    font-size:15px !important;
    line-height:1.4 !important;
}

/* Normalize older direct label + input blocks inside address fields */
.checkout-address-fields{
    display:block !important;
    margin:0 !important;
    padding:0 !important;
}

.checkout-address-fields > label:not(.checkout-checkbox-line):not(.checkout-radio-line){
    margin:0 0 8px !important;
}

.checkout-address-fields > input,
.checkout-address-fields > select,
.checkout-address-fields > textarea{
    margin:0 0 18px !important;
}

.checkout-address-fields > .form-row{
    margin:0 0 18px !important;
}

/* Direct customer e-mail field, if any old markup remains */
.checkout-form > input[name="customer_email"]{
    margin:0 0 18px !important;
}

/* Billing toggle and payment areas */
.checkout-billing-toggle{
    margin:0 !important;
}

.checkout-billing-wrapper{
    margin:20px 0 0 !important;
    padding:0 !important;
}

.checkout-payment-method{
    margin:0 !important;
    padding:16px !important;
}

.checkout-checkbox-line,
.checkout-radio-line{
    margin:0 !important;
    padding:0 !important;
}

/* Keep mobile clean */
@media(max-width:680px){
    .checkout-form-card{
        padding:16px !important;
    }

    .checkout-section-card,
    .checkout-address-section{
        padding:16px !important;
        margin-bottom:18px !important;
        border-radius:16px !important;
    }

    .checkout-field-grid,
    .checkout-field-grid.two,
    .checkout-form .form-row{
        grid-template-columns:1fr !important;
        row-gap:18px !important;
        margin-bottom:18px !important;
    }
}


/* FINAL billing checkbox alignment fix */
.checkout-billing-toggle{
    display:flex !important;
    align-items:center !important;
    gap:12px !important;
    min-height:48px !important;
    padding:12px 16px !important;
    box-sizing:border-box !important;
}

.checkout-billing-toggle input[type="checkbox"]{
    width:16px !important;
    height:16px !important;
    min-width:16px !important;
    min-height:16px !important;
    margin:0 !important;
    padding:0 !important;
    flex:0 0 16px !important;
    position:relative !important;
    top:0 !important;
}

.checkout-billing-toggle span{
    display:block !important;
    margin:0 !important;
    padding:0 !important;
    line-height:1.35 !important;
    font-size:13px !important;
    font-weight:800 !important;
    color:#233451 !important;
}

.checkout-checkbox-line.checkout-billing-toggle{
    align-items:center !important;
}


/* Active credit-card checkout design */
.checkout-payment-method-active{
    border:1px solid #cbd5e1 !important;
    border-radius:12px !important;
    background:#f8fafc !important;
    padding:14px !important;
}

.checkout-credit-card-choice{
    display:flex !important;
    align-items:center !important;
    gap:12px !important;
}

.checkout-credit-card-icon{
    width:42px !important;
    height:42px !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    border-radius:10px !important;
    background:#0b69c7 !important;
    color:#fff !important;
    font-size:22px !important;
}

.checkout-credit-card-choice strong{
    display:block !important;
    color:#0f172a !important;
    font-size:16px !important;
    line-height:1.2 !important;
}

.checkout-submit-mobile,
.store-checkout-submit-btn{
    font-size:15px !important;
    font-weight:900 !important;
}


/* Guest checkout email inside guest info box */
.checkout-guest-email-box{
    gap:10px !important;
}

.checkout-guest-email-field{
    margin-top:8px !important;
}

.checkout-guest-email-field label{
    margin-bottom:6px !important;
}

.checkout-guest-email-field input{
    width:100% !important;
}


/* Checkout layout repair: restore clean cards, bold headings and stable field grids */
.checkout-form-card,
.checkout-section-card,
.store-checkout-summary{
    border:1px solid #e2e8f0 !important;
    border-radius:16px !important;
    background:#fff !important;
}

.checkout-section-card{
    padding:18px !important;
    margin-bottom:16px !important;
}

.checkout-section-title{
    margin:0 0 14px !important;
    padding:0 0 10px !important;
    border-bottom:1px solid #e2e8f0 !important;
}

.checkout-section-title h2{
    margin:0 !important;
    color:#0f172a !important;
    font-size:18px !important;
    font-weight:900 !important;
    line-height:1.2 !important;
}

.checkout-section-title.nested{
    margin-top:12px !important;
}

.checkout-address-fields{
    display:block !important;
}

.checkout-field-grid.two{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    gap:14px !important;
    align-items:start !important;
    margin-bottom:14px !important;
}

.checkout-field{
    margin-bottom:14px !important;
}

.checkout-field label{
    display:block !important;
    margin:0 0 6px !important;
    color:#334155 !important;
    font-size:13px !important;
    font-weight:800 !important;
}

.checkout-field input,
.checkout-field textarea,
.checkout-field select{
    width:100% !important;
    box-sizing:border-box !important;
    border:1px solid #cbd5e1 !important;
    border-radius:10px !important;
    background:#fff !important;
    color:#0f172a !important;
    min-height:42px !important;
    padding:9px 11px !important;
    font-size:14px !important;
}

.checkout-field textarea{
    min-height:92px !important;
    resize:vertical !important;
}

.checkout-billing-toggle{
    display:flex !important;
    align-items:center !important;
    gap:9px !important;
    font-weight:800 !important;
    color:#0f172a !important;
}

@media(max-width:720px){
    .checkout-field-grid.two{
        grid-template-columns:1fr !important;
    }
}


/* Force checkout textareas to fixed size */
.checkout-fixed-textarea,
.checkout-form textarea,
.checkout-field textarea,
#shipping_address,
#billing_address,
#checkout_note{
    resize:none !important;
    min-height:92px !important;
    max-height:92px !important;
    height:92px !important;
}


/* PayPal payment option */
.checkout-payment-options{
    display:grid !important;
    gap:12px !important;
}

.checkout-payment-method{
    display:flex !important;
    align-items:flex-start !important;
    gap:12px !important;
}

.checkout-payment-choice-content{
    display:flex !important;
    align-items:center !important;
    gap:12px !important;
    width:100% !important;
}

.checkout-payment-icon{
    width:42px !important;
    height:42px !important;
    min-width:42px !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    border-radius:10px !important;
    color:#fff !important;
    font-weight:900 !important;
}

.checkout-paypal-icon{
    background:#003087 !important;
    font-size:22px !important;
    font-family:Arial, sans-serif !important;
}

.checkout-payment-method-paypal{
    background:#fff !important;
}

.checkout-payment-method input[type="radio"]{
    margin-top:14px !important;
}

/* Checkout two-step address/shipping/payment flow */
.checkout-step-tabs{
    display:flex;
    gap:10px;
    margin:0 0 16px;
    flex-wrap:wrap;
}

.checkout-step-tab{
    border:1px solid #d9e2ef;
    background:#fff;
    border-radius:12px;
    padding:10px 14px;
    font-weight:700;
    cursor:pointer;
}

.checkout-step-tab.active{
    border-color:#0d6efd;
    box-shadow:0 6px 18px rgba(13,110,253,.12);
}

.checkout-payment-options{
    display:grid;
    gap:12px;
}

.checkout-payment-option{
    display:flex;
    gap:12px;
    align-items:flex-start;
    border:1px solid #d9e2ef;
    border-radius:14px;
    padding:14px;
    background:#fff;
    cursor:pointer;
}

.checkout-payment-option.active{
    border-color:#0d6efd;
    box-shadow:0 8px 22px rgba(13,110,253,.12);
}

.checkout-payment-option input{
    margin-top:4px;
}

.checkout-payment-option strong{
    display:block;
    margin-bottom:4px;
}

.checkout-payment-option small{
    display:block;
    line-height:1.45;
    color:#5c6b7a;
}

.checkout-payment-detail{
    margin-top:14px;
    border:1px solid #d9e2ef;
    border-radius:14px;
    padding:14px;
    background:#f8fbff;
    color:#2f3c4a;
    line-height:1.55;
}

.checkout-payment-actions{
    display:flex;
    gap:12px;
    justify-content:space-between;
    flex-wrap:wrap;
    margin-top:16px;
}

.btn.secondary{
    background:#eef3f8;
    color:#1f2d3d;
    border:1px solid #d9e2ef;
}

@media (max-width: 768px){
    .checkout-step-tabs{
        display:grid;
        grid-template-columns:1fr;
    }

    .checkout-step-tab{
        width:100%;
        text-align:left;
    }

    .checkout-payment-actions .btn,
    .checkout-payment-actions button{
        width:100%;
    }
}

.checkout-success-bank-box{
    margin:18px 0;
    border:1px solid #d9e2ef;
    border-radius:14px;
    padding:16px;
    background:#f8fbff;
    line-height:1.7;
}

.checkout-success-bank-box h2{
    margin:0 0 10px;
    font-size:18px;
}

/* Improved checkout payment card selector */
.checkout-payment-card-grid{
    display:grid !important;
    grid-template-columns:1fr;
    gap:14px !important;
    margin-top:6px;
}

.checkout-payment-card{
    position:relative;
    display:block !important;
    min-height:auto;
    border:1px solid #dbe5f1 !important;
    border-radius:18px !important;
    padding:18px !important;
    background:#fff !important;
    box-shadow:0 10px 28px rgba(31,45,61,.06);
    transition:border-color .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
    overflow:hidden;
}

.checkout-payment-card:hover{
    border-color:#9fc5ff !important;
    box-shadow:0 14px 34px rgba(13,110,253,.11);
    transform:translateY(-1px);
}

.checkout-payment-card.active{
    border-color:#0d6efd !important;
    background:linear-gradient(180deg, #f5f9ff 0%, #ffffff 100%) !important;
    box-shadow:0 16px 38px rgba(13,110,253,.16) !important;
}

.checkout-payment-radio{
    position:absolute !important;
    opacity:0 !important;
    pointer-events:none !important;
    width:1px !important;
    height:1px !important;
    margin:0 !important;
}

.checkout-payment-card-head{
    display:flex;
    align-items:flex-start;
    gap:12px;
    width:100%;
}

.checkout-payment-card-icon{
    flex:0 0 44px;
    width:44px;
    height:44px;
    border-radius:14px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    background:#eef5ff;
    color:#0d6efd;
    font-size:22px;
    font-weight:800;
}

.checkout-payment-card-icon-text{
    font-size:15px;
    letter-spacing:.4px;
}

.checkout-payment-card-title{
    min-width:0;
    flex:1 1 auto;
    padding-right:22px;
}

.checkout-payment-card-title strong,
.checkout-payment-card strong{
    display:block;
    margin:0 0 6px !important;
    color:#152238;
    font-size:15px;
    line-height:1.25;
}

.checkout-payment-card-title small,
.checkout-payment-card small{
    display:block;
    color:#637083 !important;
    font-size:13px;
    line-height:1.45 !important;
}

.checkout-payment-card-check{
    position:absolute;
    right:14px;
    top:14px;
    width:24px;
    height:24px;
    border-radius:50%;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    background:#dfe8f3;
    color:#fff;
    font-size:14px;
    font-weight:900;
    transform:scale(.92);
}

.checkout-payment-card.active .checkout-payment-card-check{
    background:#0d6efd;
    transform:scale(1);
}

.checkout-payment-detail{
    margin-top:16px !important;
    border-color:#dbe5f1 !important;
    border-radius:18px !important;
    padding:16px 18px !important;
    background:#f7faff !important;
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.65);
}

@media (max-width: 900px){
    .checkout-payment-card-grid{
        grid-template-columns:1fr !important;
    }

    .checkout-payment-card{
        min-height:auto;
        padding:16px !important;
    }
}
