/*
 * Empora: cart page, slide cart, single-page checkout, country sheet, Kondura's notification boxes and the quick-add
 * sheet with its toast. Kondura's short GCC flow (same views, scripts and classes: .kc-*, #flyout-cart, #country-sheet,
 * #billing-form...) drawn in the reference's language: plum .btn buttons, ghost secondary buttons, square fields with
 * --line borders, Cormorant titles, Barlow (Plex in Arabic) text.
 *
 * Loaded after empora.css (Head.cshtml) and uses its tokens. Same rules: colours only through the tokens, breakpoints
 * only 768px and 1280px, logical properties on the inline axis ([dir=rtl] only for transforms, at the end).
 *
 * Sections:
 *   1. shared parts     title row, country picker, .kc-page, buttons, fields (also the account/content pages' nop forms:
 *                        .page-content .inputs), items, totals, codes, free delivery
 *   2. cart page        .kc-cart (summary column from 768px, total + checkout fixed to the bottom on phones)
 *   3. checkout         .kc-checkout-page (delivering-to banner, sections, phone box, payment cards, pay button,
 *                        Apple Pay buttons, saved addresses popup)
 *   4. slide cart       #flyout-cart.kc-flyout, opened by Minimal.js with .activeState (phones: below the header;
 *                        from 768px: a 440px panel at the inline end with a backdrop)
 *   5. country sheet    #country-sheet (bottom sheet on phones, dialog from 768px)
 *   6. notification boxes .modal-popup, shown by body.cartmodalopen / wishlistmodalopen / notifymodalopen
 *   7. quick add        size sheet and "added" toast (quick-add.js)
 *
 * No [dir=rtl] rules: the slide cart moves on inset-inline-end and the sheets on the block axis.
 */

/* ==========================================================================
   1. Shared parts
   ========================================================================== */

/* ---- the cart and checkout pages ---- */
.kc-page {
    max-width: 1180px;
    margin-inline: auto;
    padding: 0 var(--m) 48px;
    color: var(--ink);
    text-align: start;
}

/* title at the start, the delivery country picker at the end */
.kc-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 28px 0 8px;
}

.kc-page .kc-title-row h1 {
    min-width: 0;
    margin: 0;
    font-size: 34px;
    line-height: 1.05;
}

/* ---- country picker: flag + "KW" (the country's name is the button's accessible name) ---- */
.country-switch {
    flex: none;
    min-width: 0;
}

.country-switch-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    max-width: 100%;
    padding: 0 12px;
    border: 1px solid var(--stone);
    border-radius: 0;
    background: transparent;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 500;
    line-height: 1;
    letter-spacing: calc(.08em * var(--tracking));
    cursor: pointer;
    transition: border-color .2s;
}

.country-switch-button:hover {
    border-color: var(--plum);
}

.country-switch-flag {
    flex: none;
    width: 22px;
    height: 15px;
    object-fit: cover;
    box-shadow: 0 0 0 1px var(--line);
}

.country-switch-caret {
    flex: none;
    width: 6px;
    height: 6px;
    margin-block-start: -3px;
    border: solid currentColor;
    border-width: 0 1.25px 1.25px 0;
    transform: rotate(45deg);
}

/* ---- buttons: the primary is the reference's .btn, the secondary its .btn.ghost, links its .lnk ---- */
.kc-primary-button,
.kc-page .button-1.kc-primary-button,
.flyout-cart.kc-flyout .buttons .button-1.kc-primary-button,
.kc-page .checkout-buttons #nextApplePay.payment-method-next-step-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 62px;
    margin: 0;
    padding: 19px 28px;
    border: 0;
    border-radius: 0;
    background: var(--plum);
    color: var(--ivory);
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: calc(.08em * var(--tracking));
    text-transform: uppercase;
    text-align: center;
    cursor: pointer;
    transition: background-color .2s;
}

.kc-primary-button:hover,
.kc-page .checkout-buttons #nextApplePay.payment-method-next-step-button:hover {
    background: var(--plumdk);
}

.kc-primary-button:disabled {
    opacity: .5;
    cursor: default;
}

.kc-code-row .button-2,
.address_selection_popup .new-address a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
    min-height: 48px;
    margin: 0;
    padding: 0 20px;
    border: 1px solid var(--plum);
    border-radius: 0;
    background: transparent;
    color: var(--plum);
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: calc(.08em * var(--tracking));
    text-transform: uppercase;
    cursor: pointer;
    transition: background-color .2s, color .2s;
}

.kc-code-row .button-2:hover,
.address_selection_popup .new-address a:hover {
    background: var(--plum);
    color: var(--ivory);
}

.kc-link-button {
    display: inline-block;
    padding: 12px 0;
    border: 0;
    background: none;
    color: var(--plum);
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 4px;
    cursor: pointer;
}

/* ---- fields: 48px, square, --line borders, plum focus ring; 16px text so phones don't zoom ---- */
.kc-page .kc-field input[type="text"],
.kc-page .kc-field input[type="email"],
.kc-page .kc-field input[type="tel"],
.kc-page .kc-field select,
.kc-page .kc-field textarea,
.kc-code-row input[type="text"],
.page-content .inputs input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):not([type="file"]):not([type="submit"]),
.page-content .inputs textarea,
.wishlist-page .qty-input,
.manufacturer-list-page .brand-search-box-text,
.page-content .inputs select,
.kc-phone-box {
    display: block;
    width: 100%;
    min-height: 48px;
    margin: 0;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 0;
    background: var(--white);
    box-shadow: none;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 400;
    text-align: start;
    transition: border-color .2s, box-shadow .2s;
}

/* native selects (their arrow follows the direction); Minimal.js leaves them unwrapped here */
.kc-page .kc-field select,
.page-content .inputs select {
    padding-inline-end: 10px;
    accent-color: var(--plum);
}

.kc-page .kc-field textarea,
.page-content .inputs textarea {
    min-height: 88px;
    padding-block: 12px;
    resize: vertical;
}

.kc-page .kc-field input::placeholder,
.kc-page .kc-field textarea::placeholder,
.kc-code-row input::placeholder,
.page-content .inputs input::placeholder,
.page-content .inputs textarea::placeholder {
    color: var(--muted2);
    opacity: 1;
}

.kc-page .kc-field input:focus,
.kc-page .kc-field select:focus,
.kc-page .kc-field textarea:focus,
.kc-code-row input[type="text"]:focus,
.page-content .inputs input:focus,
.page-content .inputs select:focus,
.page-content .inputs textarea:focus,
.wishlist-page .qty-input:focus,
.manufacturer-list-page .brand-search-box-text:focus,
.kc-phone-box:focus-within {
    border-color: var(--plum);
    outline: none;
    box-shadow: 0 0 0 1px var(--plum);
}

/* the reference's field labels (.fl): small, muted, above the field */
.kc-code-label,
.kc-options legend {
    display: block;
    margin: 0 0 6px;
    padding: 0;
    color: var(--muted2);
    font-size: 12px;
    font-weight: 500;
}

/* ---- items: picture | name, size, quantity | remove (top) and price (bottom) ---- */
.kc-order-summary,
.kc-order-summary .cart-colums,
.kc-order-summary .cart-frames {
    margin: 0;
    padding: 0;
}

.kc-items {
    margin: 0;
    padding: 0;
    list-style: none;
}

.kc-item {
    display: grid;
    grid-template-columns: 84px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: stretch;
    padding: 18px 0;
    border-block-end: 1px solid var(--line);
}

.kc-item-picture {
    display: block;
    align-self: start;
}

.kc-item-picture img {
    display: block;
    width: 84px;
    height: 112px;
    object-fit: cover;
    background: var(--sand);
}

.kc-item-details {
    min-width: 0;
}

/* long names wrap and stop after three lines (two in the slide cart) instead of pushing the price */
.kc-item-name {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    overflow-wrap: anywhere;
    color: var(--ink);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
}

.kc-item-name:hover {
    color: var(--plum);
}

.kc-item-attributes,
.kc-item .recurring-info,
.kc-item .rental-info,
.kc-item .vendor {
    margin-block-start: 4px;
    color: var(--muted2);
    font-size: 12px;
    font-weight: 400;
    line-height: 1.5;
}

.kc-item .message-error {
    margin-block-start: 6px;
    color: var(--plum);
    font-size: 12px;
}

.kc-item .message-error ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.kc-item-price {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 2px;
    color: var(--ink);
    font-size: 14px;
    font-weight: 500;
    text-align: end;
    white-space: nowrap;
}

.kc-item-price .old-product-subtotal {
    color: var(--muted2);
    font-size: 12px;
    font-weight: 400;
    text-decoration: line-through;
}

.kc-item-price .discount,
.kc-item-price .discount-additional-info {
    color: var(--bronze);
    font-size: 12px;
    font-weight: 400;
    white-space: normal;
}

/* the bin at the top of the price column */
.kc-item-remove {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin-block: -10px auto;
    margin-inline: 0 -10px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--muted2);
    cursor: pointer;
}

.kc-item-remove:hover {
    color: var(--plum);
}

.kc-stepper {
    display: inline-flex;
    align-items: center;
    height: 36px;
    margin-block-start: 10px;
    border: 1px solid var(--stone);
}

.kc-stepper-button {
    width: 36px;
    height: 34px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--plum);
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
}

.kc-stepper-button:disabled {
    color: var(--stone);
    cursor: default;
}

.kc-stepper .qty-label {
    min-width: 24px;
    font-size: 13px;
    text-align: center;
}

.kc-qty-select {
    height: 36px;
    margin-block-start: 10px;
    padding: 0 8px;
    border: 1px solid var(--stone);
    border-radius: 0;
    background: transparent;
}

.kc-item-qty {
    display: inline-block;
    margin-block-start: 4px;
    color: var(--muted2);
    font-size: 12px;
}

/* ---- total beside the checkout button (cart page and slide cart) ---- */
.kc-total-line {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 12px;
    color: var(--ink);
}

.kc-total-label {
    font-size: 12px;
    font-weight: 500;
    letter-spacing: calc(.12em * var(--tracking));
    text-transform: uppercase;
}

.kc-total-value {
    font-size: 18px;
    font-weight: 600;
    white-space: nowrap;
}

/* ---- totals table: subtotal, discounts, delivery, fees, total ---- */
.kc-totals .cart-total {
    width: 100%;
    margin: 0;
    border-collapse: collapse;
}

.kc-totals .cart-total td {
    padding: 6px 0;
    color: var(--ink);
    font-size: 14px;
    font-weight: 400;
    text-align: start;
    vertical-align: top;
}

/* the amount takes what it needs, the label the rest (the delivery time stays on one line) */
.kc-totals .cart-total td.cart-total-right {
    width: 1%;
    padding-inline-start: 12px;
    text-align: end;
    white-space: nowrap;
}

.kc-totals .cart-total label {
    display: inline;
    margin: 0;
    font: inherit;
}

.kc-totals .value-summary,
.kc-totals .value-summary strong {
    font-weight: 500;
}

.kc-delivery-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.kc-totals .kc-truck {
    flex: none;
    color: var(--plum);
}

.kc-totals .kc-discount td,
.kc-totals .kc-free {
    color: var(--bronze);
}

.kc-totals .kc-free {
    font-weight: 600;
}

.kc-totals .cart-total .order-total td {
    padding-block-start: 12px;
    border-block-start: 1px solid var(--line);
    font-size: 16px;
    font-weight: 600;
}

.kc-totals .cart-total .order-total .value-summary,
.kc-totals .cart-total .order-total .value-summary strong {
    font-weight: 600;
}

.kc-totals .remove-gift-card-button {
    width: 20px;
    height: 20px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--muted2);
    vertical-align: middle;
}

.kc-totals .remove-gift-card-button::before {
    content: "\00d7";
}

.kc-totals .giftcard-remaining {
    display: block;
    color: var(--muted2);
    font-size: 12px;
}

/* ---- discount code and gift card ---- */
.kc-code-box {
    margin: 0 0 16px;
    text-align: start;
}

.kc-code-row {
    display: flex;
    gap: 8px;
}

.kc-code-row input[type="text"] {
    flex: 1;
    min-width: 0;
    width: auto;
}

.kc-code-box .message-success,
.kc-code-box .message-failure {
    margin: 6px 0 0;
    font-size: 12px;
}

.kc-code-box .message-success {
    color: var(--bronze);
}

.kc-code-box .message-failure {
    color: var(--plum);
}

.kc-code-box .current-code {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 8px 0 0;
    font-size: 13px;
}

.kc-code-box .remove-discount-button {
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--muted2);
    font-size: 18px;
    cursor: pointer;
}

.kc-code-box .remove-discount-button::before {
    content: "\00d7";
}

/* ---- free delivery progress (FreeShippingProgress plugin, Themes/Empora view) ---- */
.kc-free-delivery {
    margin: 0 0 18px;
    color: var(--ink);
}

.kc-free-delivery-message {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.45;
}

.kc-free-delivery-message strong {
    color: var(--plum);
    font-weight: 600;
}

.kc-free-delivery .kc-truck {
    flex: none;
    color: var(--plum);
}

.kc-free-delivery .kc-truck circle {
    fill: var(--ivory);
}

.kc-free-delivery-track {
    height: 3px;
    overflow: hidden;
    background: var(--sand);
}

.kc-free-delivery-fill {
    height: 100%;
    min-width: 3px;
    background: var(--plum);
}

.kc-free-delivery-amounts {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-block-start: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 400;
}

/* ==========================================================================
   2. Cart page
   ========================================================================== */
/* as on Kondura: no "Estimate shipping" (the delivery country is the picker beside the title) and no tax row */
.kc-cart .estimate-shipping-button,
.kc-totals .cart-total tr.tax-value {
    display: none;
}

.kc-cart .kc-cart-frames {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
}

.kc-cart .tax-shipping-info {
    margin: 0 0 4px;
    color: var(--muted2);
    font-size: 12px;
}

.kc-cart .kc-cart-summary .cart-footer {
    padding-block-start: 4px;
}

.kc-order-summary .checkout-buttons {
    margin: 0;
}

.kc-order-summary .min-amount-warning,
.kc-order-summary .checkout-disabled {
    margin: 12px 0 0;
    color: var(--plum);
    font-size: 13px;
}

.kc-order-summary .terms-of-service {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 12px 0 0;
    font-size: 13px;
}

.kc-order-summary .terms-of-service input {
    accent-color: var(--plum);
}

.kc-order-summary .terms-of-service .read {
    color: var(--plum);
    text-decoration: underline;
    cursor: pointer;
}

.kc-payments-accepted,
.kc-reassurance {
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 400;
    text-align: center;
}

.kc-order-summary .no-data {
    padding: 48px 0;
    color: var(--muted);
    text-align: center;
}

/* phones: the total and the checkout button stay at the bottom of the screen while the cart scrolls
   (under the header, so the slide cart opened over the page covers it) */
.kc-cart .kc-checkout-bar {
    position: fixed;
    inset-inline: 0;
    inset-block-end: 0;
    z-index: calc(var(--z-hdr) - 1);
    margin: 0;
    padding: 12px var(--m) calc(12px + env(safe-area-inset-bottom, 0px));
    border-block-start: 1px solid var(--line);
    background: var(--ivory);
}

.kc-cart .kc-checkout-bar .kc-total-line {
    margin-block-end: 10px;
}

/* room at the end of the page, so nothing stays behind the bar */
body:has(.kc-cart .kc-checkout-bar) {
    padding-block-end: calc(132px + env(safe-area-inset-bottom, 0px));
}

/* tablets and up: items | summary column (sticky), the bar closes the summary */
@media (min-width: 768px) {
    .kc-page .kc-title-row h1 {
        font-size: 48px;
    }

    .kc-cart .kc-cart-frames {
        grid-template-columns: minmax(0, 1fr) 320px;
        gap: 32px;
        align-items: start;
    }

    .kc-cart .kc-cart-summary {
        position: sticky;
        inset-block-start: 24px;
    }

    .kc-cart .kc-cart-summary .cart-footer {
        padding: 24px;
        border: 1px solid var(--line);
    }

    .kc-cart .kc-checkout-bar {
        position: static;
        margin-block-start: 8px;
        padding: 14px 0 0;
        background: none;
    }

    body:has(.kc-cart .kc-checkout-bar) {
        padding-block-end: 0;
    }

    .kc-item {
        grid-template-columns: 96px minmax(0, 1fr) auto;
        gap: 18px;
    }

    .kc-item-picture img {
        width: 96px;
        height: 128px;
    }
}

@media (min-width: 1280px) {
    .kc-page .kc-title-row h1 {
        font-size: 56px;
    }

    .kc-cart .kc-cart-frames {
        grid-template-columns: minmax(0, 1fr) 400px;
        gap: 56px;
    }
}

/* ==========================================================================
   3. Checkout
   ========================================================================== */

/* centered title, then where the order goes, with "Change" */
.kc-checkout-header {
    margin: 28px 0 4px;
    text-align: center;
}

.kc-page .kc-checkout-title {
    margin: 0 0 18px;
    font-size: 34px;
    line-height: 1.05;
    text-align: center;
}

.kc-delivering-to {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px;
    background: var(--sand);
    text-align: start;
}

.kc-delivering-to-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.kc-delivering-to-country {
    font-size: 14px;
    font-weight: 400;
}

.kc-delivering-to-country img {
    display: inline-block;
    margin: 0 4px;
    vertical-align: -2px;
    box-shadow: 0 0 0 1px var(--line);
}

.kc-delivering-to-country strong {
    font-weight: 600;
}

.kc-delivering-to-time {
    color: var(--bronze);
    font-size: 13px;
    font-weight: 500;
}

.kc-delivering-to .kc-link-button {
    flex: none;
}

.kc-form-error {
    margin: 14px 0 0;
    padding: 12px 14px;
    border-inline-start: 2px solid var(--plum);
    background: var(--sand);
    color: var(--plum);
    font-size: 14px;
}

.kc-checkout-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
}

.kc-section {
    margin: 28px 0 0;
}

.kc-section-title {
    margin: 0 0 14px;
    font-size: 24px;
    line-height: 28px;
}

.kc-sign-in {
    margin: -6px 0 12px;
    color: var(--muted2);
    font-size: 13px;
}

.kc-sign-in a {
    color: var(--plum);
    text-decoration: underline;
    text-underline-offset: 4px;
}

.kc-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
}

.kc-field {
    min-width: 0;
    margin: 0 0 10px;
}

/* optional fields look lighter */
.kc-page .kc-optional-fields .kc-field input[type="text"],
.kc-page .kc-optional-fields .kc-field textarea {
    border-style: dashed;
    border-color: var(--stone);
}

.kc-page .kc-invalid input[type="text"],
.kc-page .kc-invalid input[type="email"],
.kc-page .kc-invalid select,
.kc-page .kc-invalid textarea,
.kc-page .kc-invalid .kc-phone-box {
    border-color: var(--plum);
    box-shadow: inset 0 -2px 0 var(--plum);
}

.kc-field-error {
    display: block;
    margin-block-start: 4px;
    color: var(--plum);
    font-size: 12px;
    font-weight: 500;
}

.kc-field-error[hidden],
.kc-add-optional[hidden],
.kc-optional-fields[hidden] {
    display: none;
}

/* the dialing code is fixed by the country; numbers always read left to right */
.kc-phone-box {
    display: flex;
    align-items: stretch;
    padding: 0;
    direction: ltr;
}

.kc-phone-code {
    display: flex;
    align-items: center;
    padding: 0 12px;
    border-inline-end: 1px solid var(--line);
    color: var(--muted);
    font-size: 16px;
    font-weight: 400;
}

.kc-page .kc-phone-box input[type="tel"] {
    flex: 1;
    min-width: 0;
    min-height: 46px;
    border: 0;
    box-shadow: none;
    background: transparent;
    text-align: start; /* the box is direction: ltr */
}

.kc-page .kc-phone-box input[type="tel"]:focus {
    box-shadow: none;
}

.kc-page .kc-invalid .kc-phone-box input[type="tel"] {
    box-shadow: none;
}

.kc-add-optional {
    margin: 0 0 10px;
}

.kc-options {
    margin: 0 0 10px;
    padding: 0;
    border: 0;
}

.kc-options label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 32px;
    margin-inline-end: 16px;
    font-size: 14px;
}

.kc-options input {
    accent-color: var(--plum);
}

/* saved address of a registered customer */
.kc-saved-address {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid var(--line);
    background: var(--white);
}

.kc-saved-address-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    font-size: 14px;
}

.kc-saved-address-text span {
    color: var(--muted2);
    font-weight: 400;
}

.kc-saved-address .kc-link-button {
    flex: none;
    padding-block: 0;
}

/* payment methods as cards */
.kc-payment-methods {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.kc-payment-methods > li {
    margin: 0;
    padding: 0;
}

.kc-payment-method {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 56px;
    margin: 0;
    padding: 8px 14px;
    border: 1px solid var(--line);
    background: var(--white);
    cursor: pointer;
    transition: border-color .2s, box-shadow .2s;
}

.kc-payment-method input[type="radio"] {
    flex: none;
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--plum);
}

.kc-payment-name {
    flex: 1;
    min-width: 0;
    font-size: 14px;
    font-weight: 500;
}

.kc-payment-logo {
    flex: none;
    width: auto;
    max-width: 72px;
    height: 24px;
    object-fit: contain;
}

.kc-payment-method:has(input:checked) {
    border-color: var(--plum);
    box-shadow: inset 0 0 0 1px var(--plum);
}

.kc-payment-method:focus-within {
    outline: 2px solid var(--plum);
    outline-offset: 2px;
}

.kc-checkout-page .message-error {
    color: var(--plum);
    font-size: 14px;
}

/* order summary column: the totals, the pay button and the reassurance line */
.kc-order-review {
    margin-block-start: 20px;
}

.kc-checkout-summary .checkout-buttons {
    margin: 16px 0 0;
    padding: 0;
    text-align: center;
}

/* Apple Pay: the plugins hide the pay button and put theirs in its place (MyFatoorah: "Continue", then its Apple Pay
   button in #checkout; KNET and NBK: the Apple Pay button), in the flow and as wide as the pay button */
.kc-page .checkout-buttons #checkout-two-step-apple-pay {
    position: static;
    width: 100%;
}

.kc-page .checkout-buttons #checkout,
.kc-page .checkout-buttons #checkout-nbk-apple-pay {
    width: 100%;
}

.kc-page .checkout-buttons #checkout-nbk-apple-pay .apple-pay-button {
    width: 100%;
    height: 52px;
}

@media (min-width: 768px) {
    .kc-checkout-header {
        margin-block-start: 40px;
    }

    .kc-page .kc-checkout-title {
        font-size: 48px;
    }

    .kc-checkout-grid {
        grid-template-columns: minmax(0, 1fr) 320px;
        gap: 32px;
        align-items: start;
    }

    .kc-checkout-summary {
        position: sticky;
        inset-block-start: 24px;
        margin-block-start: 28px;
        padding: 4px 24px 24px;
        border: 1px solid var(--line);
    }
}

@media (min-width: 1280px) {
    .kc-page .kc-checkout-title {
        font-size: 56px;
    }

    .kc-checkout-grid {
        grid-template-columns: minmax(0, 1fr) 400px;
        gap: 56px;
    }
}

/* saved addresses (registered customers): "Change" opens this list, .hide keeps it closed */
.address_selection_popup.popup {
    position: fixed;
    inset: 0;
    z-index: var(--z-sheet);
    overflow-y: auto;
    padding: 24px var(--m) 32px;
    background: var(--ivory);
}

.address_selection_popup.popup.hide {
    display: none;
}

.address_selection_popup .single-checkout-page-title h1 {
    margin: 8px 0 24px;
    font-size: 34px;
    text-align: center;
}

.address_selection_popup .popup-close {
    position: absolute;
    inset-block-start: 16px;
    inset-inline-end: var(--m);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--plum);
    cursor: pointer;
}

.address_selection_popup .popup-close svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

.address-list-container {
    display: grid;
    gap: 10px;
    max-width: 640px;
    margin: 0 auto 24px;
}

.address_selection_popup .checkout-step-box {
    position: relative;
    padding: 14px 16px;
    border: 1px solid var(--line);
    background: var(--white);
}

.address_selection_popup .step-title {
    display: block;
    margin-block-end: 6px;
    color: var(--bronze);
    font-size: 11px;
    letter-spacing: calc(.12em * var(--tracking));
}

.address_selection_popup .step-body-box ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.address_selection_popup .list-title {
    display: block;
    font-weight: 600;
}

.address_selection_popup .list-subtitle {
    display: block;
    overflow-wrap: anywhere;
    color: var(--muted2);
    font-size: 13px;
    font-weight: 400;
}

/* the whole card picks the address */
.address_selection_popup .select-address-button a {
    position: absolute;
    inset: 0;
}

.address_selection_popup .checkout-step-box:has(.selected) {
    border-color: var(--plum);
}

.address_selection_popup .visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.address_selection_popup .select-address-button a:focus-visible {
    outline-offset: -2px;
}

.address_selection_popup .checkout-buttons {
    max-width: 640px;
    margin: 0 auto;
}

.address_selection_popup .new-address {
    display: block;
}

.address_selection_popup .new-address a {
    width: 100%;
}

/* ==========================================================================
   4. Slide cart
   ========================================================================== */

/* phones: the whole width, from the bottom of the header (the view's script sets the top) to the bottom of the screen,
   closed with the header's bag icon; from 768px: a 440px panel at the inline end with a backdrop and an X */
.flyout-cart.kc-flyout {
    position: fixed;
    inset-block: 52px 0;
    inset-inline-end: -100%;
    z-index: var(--z-drawer);
    display: block;
    width: 100%;
    border-block-start: 1px solid var(--line);
    background: var(--ivory);
    color: var(--ink);
    text-align: start;
    visibility: hidden;
    transition: inset-inline-end .3s ease, visibility 0s linear .3s;
}

.flyout-cart.kc-flyout.activeState {
    inset-inline-end: 0;
    visibility: visible;
    transition-delay: 0s;
}

.flyout-cart.kc-flyout .bg-opacity {
    display: none;
}

/* phones: closed with the bag icon, unless the header has scrolled away (the view's script adds .kc-flyout-detached) */
.flyout-cart.kc-flyout:not(.kc-flyout-detached) .cart-close {
    display: none;
}

/* phones: the page under the open cart stays still, so the header (which scrolls with the page) stays above it */
html:has(.flyout-cart.kc-flyout.activeState) {
    overflow: hidden;
}

/* title row, items (scrolling) and the total with the checkout button, stacked */
.flyout-cart.kc-flyout .fly-cart-frame {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    overscroll-behavior: contain;
}

.flyout-cart.kc-flyout .kc-flyout-header {
    flex: none;
    margin: 0;
    padding: 16px var(--m) 4px;
}

.flyout-cart.kc-flyout .kc-cart-title {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    font-size: 26px;
    line-height: 1.1;
}

.flyout-cart.kc-flyout .kc-cart-title a {
    color: inherit;
}

.flyout-cart.kc-flyout .cart-close {
    position: relative;
    flex: none;
    width: 44px;
    height: 44px;
    margin-inline-end: -10px;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}

.flyout-cart.kc-flyout .cart-close::before,
.flyout-cart.kc-flyout .cart-close::after {
    content: "";
    position: absolute;
    inset-block-start: 50%;
    inset-inline-start: 50%;
    width: 18px;
    height: 1.5px;
    margin-block-start: -.75px;
    margin-inline-start: -9px;
    background: var(--plum);
    transform: rotate(45deg);
}

.flyout-cart.kc-flyout .cart-close::after {
    transform: rotate(-45deg);
}

.flyout-cart.kc-flyout .mini-shopping-cart {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 0 var(--m);
}

/* "You have no items" */
.flyout-cart.kc-flyout .mini-shopping-cart .count {
    margin: 16px 0 0;
    color: var(--muted);
    font-size: 14px;
}

.flyout-cart.kc-flyout .kc-item {
    grid-template-columns: 72px minmax(0, 1fr) auto;
    gap: 12px;
    padding: 16px 0;
}

.flyout-cart.kc-flyout .kc-item-picture img {
    width: 72px;
    height: 96px;
}

.flyout-cart.kc-flyout .kc-item-name {
    -webkit-line-clamp: 2;
}

/* free delivery, the code and the totals scroll with the items */
.flyout-cart.kc-flyout .kc-flyout-details {
    padding: 18px 0;
}

/* the total and the checkout button always stay at the bottom */
.flyout-cart.kc-flyout .kc-flyout-summary {
    flex: none;
    padding: 14px var(--m) calc(14px + env(safe-area-inset-bottom, 0px));
    border-block-start: 1px solid var(--line);
    background: var(--ivory);
}

.flyout-cart.kc-flyout .buttons {
    margin: 0;
}

@media (min-width: 768px) {
    /* a side panel beside the page: the page keeps its scroll */
    html:has(.flyout-cart.kc-flyout.activeState) {
        overflow: visible;
    }

    .flyout-cart.kc-flyout {
        inset-block-start: 0;
        inset-inline-end: -460px;
        width: 440px;
        border-block-start: 0;
    }

    .flyout-cart.kc-flyout .cart-close,
    .flyout-cart.kc-flyout:not(.kc-flyout-detached) .cart-close {
        display: block;
    }

    /* the page beside the panel, dimmed; a click on it closes the cart (empora.js) */
    .flyout-cart.kc-flyout .bg-opacity {
        position: fixed;
        inset-block: 0;
        inset-inline-start: 0;
        inset-inline-end: 440px;
        display: block;
        background: var(--scrim);
        opacity: 0;
        transition: opacity .3s;
    }

    .flyout-cart.kc-flyout.activeState .bg-opacity {
        opacity: 1;
    }

    .flyout-cart.kc-flyout .kc-flyout-header {
        padding: 22px 24px 6px;
    }

    .flyout-cart.kc-flyout .kc-cart-title {
        font-size: 32px;
    }

    .flyout-cart.kc-flyout .mini-shopping-cart {
        padding: 0 24px;
    }

    .flyout-cart.kc-flyout .kc-flyout-summary {
        padding: 16px 24px 24px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .flyout-cart.kc-flyout,
    .flyout-cart.kc-flyout .bg-opacity {
        transition: none;
    }
}

/* ==========================================================================
   5. Country sheet
   ========================================================================== */
.country-sheet {
    position: fixed;
    inset: 0;
    z-index: var(--z-sheet);
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.country-sheet[hidden] {
    display: none;
}

body.country-sheet-open {
    overflow: hidden;
}

.country-sheet-backdrop {
    position: absolute;
    inset: 0;
    background: var(--scrim);
}

.country-sheet-panel {
    position: relative;
    width: 100%;
    max-height: 85vh;
    max-height: 85dvh;
    overflow-y: auto;
    padding: 8px 0 calc(16px + env(safe-area-inset-bottom, 0px));
    background: var(--ivory);
    color: var(--ink);
}

.country-sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-block: 10px 8px;
    padding-inline: 20px 10px;
    border-block-end: 1px solid var(--line);
}

.country-sheet-title {
    margin: 0;
    font-size: 24px;
    line-height: 28px;
}

.country-sheet-close {
    position: relative;
    flex: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}

.country-sheet-close::before,
.country-sheet-close::after {
    content: "";
    position: absolute;
    inset-block-start: 50%;
    inset-inline-start: 50%;
    width: 18px;
    height: 1.5px;
    margin-block-start: -.75px;
    margin-inline-start: -9px;
    background: var(--plum);
    transform: rotate(45deg);
}

.country-sheet-close::after {
    transform: rotate(-45deg);
}

.country-sheet-list {
    margin: 0;
    padding: 4px 0 0;
    list-style: none;
}

.country-sheet-item {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 52px;
    padding: 0 20px;
    color: var(--ink);
    font-size: 15px;
    font-weight: 400;
}

.country-sheet-item:hover,
.country-sheet-item:focus-visible {
    background: var(--sand);
    outline: none;
}

.country-sheet-item.is-current {
    color: var(--plum);
    font-weight: 600;
}

.country-sheet-flag {
    flex: none;
    width: 26px;
    height: 18px;
    object-fit: cover;
    box-shadow: 0 0 0 1px var(--line);
}

.country-sheet-name {
    flex: 1;
    min-width: 0;
}

.country-sheet-currency {
    color: var(--muted2);
    font-size: 12px;
    letter-spacing: calc(.08em * var(--tracking));
}

.country-sheet-item.is-current::after {
    content: "";
    flex: none;
    width: 5px;
    height: 10px;
    margin-inline-start: 4px;
    border: solid var(--plum);
    border-width: 0 1.5px 1.5px 0;
    transform: rotate(45deg);
}

@media (min-width: 768px) {
    .country-sheet {
        align-items: center;
        padding: 24px;
    }

    .country-sheet-panel {
        max-width: 440px;
        padding-block-end: 12px;
    }
}

/* ==========================================================================
   6. Notification boxes (Kondura's "added to cart / wishlist" and notify-me boxes)
   ========================================================================== */
.modal-popup {
    display: none;
}

body.cartmodalopen .modal-popup.cart,
body.wishlistmodalopen .modal-popup.wishlist,
body.notifymodalopen .modal-popup.notifyMe {
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    inset: 0;
    z-index: var(--z-sheet);
    padding: var(--m);
}

.modal-popup .modal-overlay {
    position: absolute;
    inset: 0;
    background: var(--scrim);
}

.modal-popup .modal-holder {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: min(100%, 420px);
    padding: 24px;
    background: var(--ivory);
}

.modal-popup .modalclose {
    align-self: flex-end;
}

.modal-popup .buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.modal-popup .buttons .btn {
    flex: 1;
    min-height: 49px;
    padding: 12px 20px;
}

/* ==========================================================================
   7. Quick add-to-cart: size sheet (bottom sheet on phone, dialog from 768) and "added" toast; driven by quick-add.js
   ========================================================================== */
html.quick-add-open,
html.quick-add-open body {
    overflow: hidden;
}

.quick-add-sheet {
    position: fixed;
    inset: 0;
    z-index: var(--z-sheet);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    visibility: hidden;
    pointer-events: none;
}

.quick-add-sheet.is-open {
    visibility: visible;
    pointer-events: auto;
}

.quick-add-sheet__overlay {
    position: absolute;
    inset: 0;
    background: var(--scrim);
    opacity: 0;
    transition: opacity .25s;
}

.quick-add-sheet.is-open .quick-add-sheet__overlay {
    opacity: 1;
}

.quick-add-sheet__panel {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-height: 85vh;
    max-height: 85dvh;
    padding: 6px 20px calc(20px + env(safe-area-inset-bottom, 0px));
    background: var(--ivory);
    transform: translateY(100%);
    transition: transform .3s;
}

.quick-add-sheet.is-open .quick-add-sheet__panel {
    transform: none;
}

.quick-add-sheet__panel.is-dragging {
    transition: none;
}

.quick-add-sheet__handle {
    display: flex;
    justify-content: center;
    padding: 8px 0 10px;
    touch-action: none;
}

.quick-add-sheet__handle span {
    width: 44px;
    height: 3px;
    background: var(--stone);
}

.quick-add-sheet__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-block-end: 12px;
}

.quick-add-sheet__title {
    margin: 0;
    font-size: 24px;
    line-height: 28px;
}

.quick-add-sheet__close {
    display: flex;
    flex: 0 0 44px;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-inline-end: -10px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--plum);
}

.quick-add-sheet__close svg {
    width: 18px;
    height: 18px;
}

.quick-add-sheet__product {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-block-end: 18px;
}

.quick-add-sheet__thumb {
    flex: 0 0 72px;
    width: 72px;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: var(--sand);
}

.quick-add-sheet__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.quick-add-sheet__info {
    min-width: 0;
    font-size: 13px;
    line-height: 19.5px;
}

.quick-add-sheet__name {
    overflow-wrap: anywhere;
}

.quick-add-sheet__price {
    color: var(--muted);
}

.quick-add-sheet__body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

.quick-add-group + .quick-add-group {
    margin-block-start: 18px;
}

.quick-add-group__label {
    margin: 0 0 8px;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: calc(.12em * var(--tracking));
    color: var(--muted2);
}

.quick-add-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(64px, 1fr));
    gap: 8px;
}

.quick-add-chip {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-height: 48px;
    padding: 0 6px;
    border: 1px solid var(--stone);
    background: transparent;
    color: var(--ink);
    font-size: 14px;
    font-weight: 500;
    transition: background-color .2s, color .2s, border-color .2s;
}

.quick-add-chip:hover,
.quick-add-chip:focus-visible {
    border-color: var(--plum);
}

.quick-add-chip.is-selected {
    border-color: var(--plum);
    background: var(--plum);
    color: var(--ivory);
}

.quick-add-chip[disabled] {
    border-color: var(--line);
    color: var(--pebble);
    text-decoration: line-through;
    cursor: default;
}

.quick-add-chip.is-busy {
    opacity: .6;
    pointer-events: none;
}

.quick-add-chip__adj {
    font-size: 11px;
    color: var(--muted2);
}

.quick-add-chip__swatch {
    width: 18px;
    height: 18px;
    border: 1px solid var(--line);
    border-radius: 50%;
}

.quick-add-chip__img {
    width: 28px;
    height: 28px;
    object-fit: cover;
}

.quick-add-toast {
    position: fixed;
    inset-inline: var(--m);
    inset-block-end: calc(16px + env(safe-area-inset-bottom, 0px));
    z-index: var(--z-toast);
    display: flex;
    align-items: center;
    gap: 14px;
    max-width: 560px;
    margin-inline: auto;
    padding: 14px 18px;
    background: var(--plum);
    color: var(--ivory);
    opacity: 0;
    visibility: hidden;
    transform: translateY(24px);
    transition: opacity .25s, transform .25s, visibility 0s linear .25s;
}

.quick-add-toast.is-visible {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition-delay: 0s;
}

.quick-add-toast.is-error {
    background: var(--ink);
}

.quick-add-toast__icon {
    display: flex;
    flex: 0 0 28px;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 1px solid var(--goldlt);
    border-radius: 50%;
    color: var(--goldlt);
}

.quick-add-toast__icon svg {
    width: 14px;
    height: 14px;
}

.quick-add-toast__icon-error,
.quick-add-toast.is-error .quick-add-toast__icon-success {
    display: none;
}

.quick-add-toast.is-error .quick-add-toast__icon-error {
    display: block;
}

.quick-add-toast__text {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.quick-add-toast__title {
    font-size: 14px;
    font-weight: 500;
}

.quick-add-toast__subtitle {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    font-size: 13px;
    color: var(--goldlt);
}

.quick-add-toast__link {
    flex: 0 0 auto;
    padding: 12px 0;
    color: var(--ivory);
    font-size: 13px;
    text-decoration: underline;
    text-underline-offset: 4px;
    white-space: nowrap;
}

.quick-add-toast.is-error .quick-add-toast__link {
    display: none;
}

@media (min-width: 768px) {
    .quick-add-sheet {
        align-items: center;
        padding: 24px;
    }

    .quick-add-sheet__panel {
        max-width: 480px;
        max-height: 80vh;
        padding: 20px 24px 24px;
        opacity: 0;
        transform: translateY(24px);
        transition: transform .25s, opacity .25s;
    }

    .quick-add-sheet.is-open .quick-add-sheet__panel {
        opacity: 1;
        transform: none;
    }

    .quick-add-sheet__handle {
        display: none;
    }

    .quick-add-toast {
        inset-inline: auto 24px;
        max-width: 440px;
        margin-inline: 0;
        inset-block-end: 24px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .quick-add-sheet__overlay,
    .quick-add-sheet__panel,
    .quick-add-toast,
    .quick-add-chip {
        transition: none;
    }
}
