/* Design tokens — shared by .vmt-sell and body-mounted checkout modals */
.vmt-sell,
.vmt-checkout-modal,
.vmt-checkout-dob-modal {
    --color-text-primary: #000000;
    --color-text-secondary: #4D4D4D;
    --color-text-placeholder: #CBCBCB;
    --color-primary: #6F8D6B;
    --color-secondary: #B6C5B4;
    --color-success: #8CC63E;
    --color-error: #b42318;
    --color-white: #FFFFFF;
    --color-border: #E9E9E9;
    --color-background-primary: #F9F9F9;
    --color-background-secondary: #E2E8E1;
    --color-badge: #E1B62B;
    --color-badge-background: #F4E5B5;
    --color-overlay: rgba(0, 0, 0, 0.5);
}

.vmt-sell {
    box-sizing: border-box;
    width: 100%;
    max-width: 1200px !important;
    max-height: 1250px;
    margin-block: 16px;
    margin-inline: auto;
    overflow: hidden;
    background: var(--color-white);
    color: var(--color-text-primary);
    border: 1px solid var(--color-border);
    border-radius: 24px;
    box-shadow:
        0 2px 6px rgba(0, 0, 0, 0.02),
        0 12px 32px rgba(0, 0, 0, 0.04);
    font-family: inherit;
}

/* Inner scroller keeps radius on the shell (scrollbar no longer squares corners). */
.vmt-sell-scroll {
    max-height: inherit;
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--color-secondary) transparent;
}

.vmt-sell-scroll::-webkit-scrollbar {
    width: 5px;
}

.vmt-sell-scroll::-webkit-scrollbar-track {
    background: transparent;
    margin-block: 22px;
}

.vmt-sell-scroll::-webkit-scrollbar-thumb {
    background-color: var(--color-secondary);
    border-radius: 999px;
    border: 1px solid transparent;
    background-clip: padding-box;
    min-height: 40px;
}

.vmt-sell-scroll::-webkit-scrollbar-thumb:hover {
    background-color: var(--color-primary);
}

.vmt-sell-scroll::-webkit-scrollbar-corner,
.vmt-sell-scroll::-webkit-scrollbar-button {
    display: none;
    width: 0;
    height: 0;
    background: transparent;
}

.vmt-sell *,
.vmt-sell *::before,
.vmt-sell *::after {
    box-sizing: border-box;
}

.vmt-sell-header,
.vmt-sell-footer {
    position: sticky;
    z-index: 2;
    background: var(--color-white);
}

.vmt-sell-header {
    top: 0;
    padding: 20px;
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
}

.vmt-sell-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.vmt-sell-header-row-col {
    display: flex;
    align-items: center;
    gap: 14px;
}

.vmt-sell-back,
.vmt-sell-cart {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    background: var(--color-white);
    color: var(--color-text-primary);
    cursor: pointer;
}

.vmt-sell-back[hidden] {
    display: none !important;
}

.vmt-sell-back .bi,
.vmt-sell-cart .bi {
    font-size: 18px;
    line-height: 1;
}

.vmt-sell-title {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.2;
    /* white-space: nowrap; */
}

.vmt-sell-promo {
    margin: 0;
    text-align: right;
    font-size: 14px;
    line-height: 1.35;
    color: var(--color-primary);
}

.vmt-sell-promo :where(p, span, strong, em, a) {
    margin: 0;
}

.vmt-sell-cart {
    position: relative;
}

.vmt-sell-cart-count {
    position: absolute;
    top: -6px;
    right: -6px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 999px;
    background: var(--color-primary);
    color: var(--color-white);
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}

.vmt-sell-cart.is-home .vmt-sell-cart-count,
.vmt-sell-cart-count[hidden] {
    display: none !important;
}

#vmt-sell:has(.vmt-sell-step[data-step="checkout"]:not([hidden])) {
    max-height: none;
    overflow: visible;
}

#vmt-sell:has(.vmt-sell-step[data-step="checkout"]:not([hidden])) .vmt-sell-scroll {
    max-height: none;
    overflow: visible;
}

#vmt-sell:has(.vmt-sell-step[data-step="checkout"]:not([hidden])) .vmt-sell-promo,
#vmt-sell:has(.vmt-sell-step[data-step="checkout"]:not([hidden])) .vmt-sell-cart {
    display: none !important;
}

#vmt-sell:has(.vmt-sell-step[data-step="checkout"]:not([hidden])) .vmt-sell-footer {
    position: static;
    bottom: auto;
    z-index: auto;
}

.vmt-sell-progress {
    height: 10px;
    margin: 24px 0 0;
    border-radius: 999px;
    background: var(--color-background-secondary);
    overflow: hidden;
}

.vmt-sell-progress-fill {
    display: block;
    width: 12%;
    height: 100%;
    border-radius: inherit;
    background: var(--color-primary);
    transition: width 360ms ease-out;
}

@media (prefers-reduced-motion: reduce) {
    .vmt-sell-progress-fill {
        transition: none;
    }
}

.vmt-sell-body {
    min-height: 240px;
    padding: 20px;
}

.vmt-sell-footer {
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 20px;
    background: var(--color-background-primary);
    color: var(--color-text-secondary);
    font-size: 16px;
    border-bottom-left-radius: 24px;
    border-bottom-right-radius: 24px;
}

.vmt-sell-footer img {
    display: block;
    width: 92px;
    height: auto;
}

.vmt-sell-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 16px;
}

.vmt-sell-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: var(--color-white);
    color: var(--color-text-primary);
    cursor: pointer;
    text-align: center;
}

.vmt-sell-card-media {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-secondary);
}

.vmt-sell-card-media img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.vmt-sell-card-label {
    display: block;
    padding: 14px 10px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    text-align: left;
}

#vmt-sell-categories .vmt-sell-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

#vmt-sell-categories .vmt-sell-card-media {
    aspect-ratio: 1 / 0.92;
}

#vmt-sell-categories .vmt-sell-card-media img {
    max-width: 70%;
}

#vmt-sell-categories .vmt-sell-card-label {
    text-align: center;
}

.vmt-sell-chips {
    display: flex;
    gap: 10px;
    margin: 0 0 18px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;

    &::-webkit-scrollbar {
        display: none;
    }
}

.vmt-sell-chip {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px 16px;
    border: 1px solid transparent;
    border-radius: 10px;
    background: var(--color-background-primary);
    cursor: pointer;
    text-align: center;
    white-space: nowrap;
}

.vmt-sell-chip-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--color-text-primary);
}

.vmt-sell-chip-count {
    font-size: 12px;
    color: var(--color-text-secondary);
}

.vmt-sell-chip.is-selected {
    border-color: var(--color-primary);
    background: var(--color-white);
}

.vmt-sell-message {
    margin: 0;
    color: var(--color-text-secondary);
}

/* --- Skeleton loaders --- */
@keyframes vmt-sell-skeleton-shimmer {
    0% {
        background-position: 100% 0;
    }

    100% {
        background-position: -100% 0;
    }
}

.vmt-sell-skeleton-bone {
    display: block;
    border-radius: 8px;
    background: linear-gradient(90deg,
            var(--color-background-primary) 0%,
            var(--color-background-secondary) 45%,
            var(--color-background-primary) 90%);
    background-size: 200% 100%;
    animation: vmt-sell-skeleton-shimmer 1.2s ease-in-out infinite;
}

.vmt-sell-skeleton-grid {
    pointer-events: none;
    user-select: none;
}

.vmt-sell-skeleton-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    background: var(--color-white);
}

.vmt-sell-skeleton-card-media {
    aspect-ratio: 1 / 0.92;
    border-radius: 0;
    background-color: var(--color-background-secondary);
}

.vmt-sell-skeleton-card-label {
    width: 56%;
    height: 14px;
    margin: 16px auto;
}

#vmt-sell-devices .vmt-sell-skeleton-card-media {
    aspect-ratio: 1 / 1;
}

#vmt-sell-devices .vmt-sell-skeleton-card-label {
    width: 70%;
    margin: 16px 10px;
}

.vmt-sell-skeleton-questions {
    pointer-events: none;
    user-select: none;
}

.vmt-sell-skeleton-q-title {
    width: min(280px, 55%);
    height: 22px;
    margin-bottom: 16px;
}

.vmt-sell-skeleton-q-tip {
    width: 100%;
    height: 44px;
    margin-bottom: 20px;
    border-radius: 8px;
}

.vmt-sell-skeleton-q-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.vmt-sell-skeleton-q-option {
    height: 56px;
    border-radius: 12px;
    border: 1px solid var(--color-border);
}

.vmt-sell-skeleton-summary-product {
    display: flex;
    align-items: center;
    gap: 12px;
}

.vmt-sell-skeleton-summary-media {
    flex: 0 0 75px;
    width: 75px;
    height: 75px;
    border-radius: 6px;
}

.vmt-sell-skeleton-summary-title {
    width: 96px;
    height: 16px;
}

@media (prefers-reduced-motion: reduce) {
    .vmt-sell-skeleton-bone {
        animation: none;
        background: var(--color-background-secondary);
    }
}

@media (max-width: 720px) {
    .vmt-sell-skeleton-q-options {
        grid-template-columns: 1fr;
    }
}

.vmt-sell-questions-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 450px);
    gap: 48px;
    align-items: start;
}

.vmt-sell-questions-main {
    min-width: 0;
}

.vmt-sell-summary {
    position: sticky;
    top: 8px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.vmt-sell-summary-product {
    display: flex;
    align-items: center;
    gap: 12px;
}

.vmt-sell-summary-media {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 75px;
    width: 75px;
    height: 75px;
    border-radius: 6px;
    background: var(--color-secondary);
    overflow: hidden;
}

.vmt-sell-summary-media img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.vmt-sell-summary-title {
    font-size: 16px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--color-text-primary);
}

.vmt-sell-summary-tags {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: space-between;
}

.vmt-sell-summary-tag {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 48%;
    margin: 0;
    padding: 12px 14px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    background: var(--color-background-primary);
    color: var(--color-primary);
    font-size: 14px;
    line-height: 1.3;
    text-align: left;
    cursor: pointer;
    position: relative;
}

.vmt-sell-summary-tag-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 32px;
    width:32px;
    height:32px;
    border-radius: 6px;
    background: var(--color-background-secondary);
    color: var(--color-text-secondary);
    font-size: 18px;
}

.vmt-sell-summary-tag-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    flex: 1 1 auto;
    min-width: 0;
}

.vmt-sell-summary-tag-label {
    color: var(--color-text-secondary);
    font-size: 12px;
    font-weight: 400;
    line-height: 1.25;
}

.vmt-sell-summary-tag-value {
    color: var(--color-text-primary);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.25;
}

.vmt-sell-summary-tag-edit {
    position: absolute;
    right: 8px;
    top: 5px;
    color: var(--color-text-secondary);
    font-size: 14px;
    opacity: 0;
    transition: opacity 160ms ease;
}

.vmt-sell-summary-tag:hover .vmt-sell-summary-tag-edit,
.vmt-sell-summary-tag:focus-visible .vmt-sell-summary-tag-edit {
    opacity: 1;
}

@media (hover: none) {
    .vmt-sell-summary-tag-edit {
        opacity: 1;
    }
}

.vmt-sell-quote {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
}

.vmt-sell-quote[hidden],
#vmt-sell-questionnaire[hidden] {
    display: none !important;
}

.vmt-sell-quote-label {
    font-size: 16px;
    color: var(--color-text-secondary);
}

.vmt-sell-quote-total-wrap {
    display: inline-flex;
    align-items: center;
    margin-top: -8px;
    min-height: 48px;
}

.vmt-sell-quote-total {
    font-size: 40px;
    font-weight: 700;
    line-height: 1;
    color: var(--color-primary);
    letter-spacing: -0.03em;
}

.vmt-sell-quote-error {
    margin: 0;
    font-size: 13px;
    color: var(--color-error);
}

.vmt-sell-quote-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 14px;
    border-radius: 8px;
    background: var(--color-badge-background);
    font-size: 16px;
}

.vmt-sell-quote-badge .bi {
    flex: 0 0 auto;
    color: var(--color-primary);
    font-size: 22px;
    line-height: 1;
}

.vmt-sell-quote-benefits {
    margin: 4px 0 0;
    padding: 0;
    list-style: none;
}

.vmt-sell-quote-benefits li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 10px;
    color: var(--color-text-secondary);
    font-size: 14px;
    line-height: 1.35;
}

.vmt-sell-quote-benefits .bi {
    flex: 0 0 auto;
    margin-top: 1px;
    color: var(--color-primary);
    font-size: 20px;
    line-height: 1;
}

.vmt-sell-quote-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 6px;
    background: var(--color-primary);
    color: var(--color-white);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
}

.vmt-sell-quote-cta .bi {
    font-size: 16px;
    line-height: 1;
}

.vmt-sell-quote-reviews {
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: center;
    width: 100%;
}

.vmt-sell-quote-stars {
    display: inline-flex;
    justify-content: center;
    gap: 4px;
    color: var(--color-badge);
    font-size: 16px;
    line-height: 1;
}

.vmt-sell-quote-reviews p {
    margin: 0;
    color: var(--color-text-secondary);
    font-size: 16px;
    line-height: 1.4;
}

.vmt-sell-quote-reviews p strong {
    color: var(--color-primary);
}

#vmt-sell .vmt-partner-questionnaire {
    width: 100%;
}

#vmt-sell .device-question {
    border: none;
    padding: 0;
    background: transparent;
    box-shadow: none;
}

@media (max-width: 900px) {

    #vmt-sell-categories .vmt-sell-grid,
    .vmt-sell-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .vmt-sell-header,
    .vmt-sell-body {
        padding: 16px;
    }
    #vmt-sell-categories .vmt-sell-grid,
    .vmt-sell-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    #vmt-sell:has(.vmt-sell-step[data-step="checkout"]:not([hidden])) .vmt-sell-header{
        padding-bottom: 5px;
    }

    .vmt-sell-header-row {
        position: relative;
        margin-bottom: 65px;
    }
    #vmt-sell:not(:has(.vmt-sell-promo)) .vmt-sell-header-row,
    #vmt-sell:has(.vmt-sell-step[data-step="checkout"]:not([hidden])) .vmt-sell-header-row{
        margin-bottom: 25px;
    }

    .vmt-sell-title {
        font-size: 20px;
    }

    .vmt-sell-promo {
        text-align: center;
        position: absolute;
        left: 0;
        top: 130%;
    }

    .vmt-sell-questions-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .vmt-sell-summary {
        padding: 12px 0;
        border-top: 1px solid var(--color-border);
    }

    .vmt-sell-summary-tags{
        flex-direction: column;
    }

    .vmt-sell-summary-tag{
        width: 100%;
    }

}