.ajmc-wrapper,
.ajmc-wrapper * {
    box-sizing: border-box;
}

.ajmc-wrapper {
    position: relative;
    z-index: 9998;
}

.ajmc-floating-wrapper {
    position: absolute;
}

.ajmc-cart-button {
    border: none;
    width: 44px;
    height: 44px;
    position: relative;
    display: flex;
}
span.sr-only {
    display: none;
}
button.ajmc-stock-alert-close {
    color: #000;
    border: 0;
    padding: 0;
    margin: 0;
    position: absolute;
    right: 20px;
    top: 2px;
    font-size: 30px;
}
.ajmc-button-position-bottom_right {
    right: 0;
    top: calc(100% + 85px);
}

.ajmc-button-position-bottom_left {
    left: 24px;
    bottom: 24px;
}

.ajmc-button-position-top_right {
    right: 24px;
    top: 24px;
}

.ajmc-button-position-top_left {
    left: 24px;
    top: 24px;
}

.ajmc-count {
    position: absolute;
    background: #000;
    width: 20px;
    height: 20px;
    border-radius: 999px;
    color: #fff;
    font-size: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    right: 1px;
    bottom: 6px;
    line-height: 10px;
}
.full-area-cart {
    position: relative;
}
.ajmc-dropdown {
    position: absolute;
    right: 0;
    top: 0;
    max-height: 0;
    background: #fff;
    z-index: 9999;
    padding: 22px;
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 0.18s ease, transform 0.18s ease;
    overflow-y: auto;
    font-family: inherit;
    border: 1px solid #1212121a;
    border-radius: 0;
}

.ajmc-dropdown.is-open {
    opacity: 1;
    max-height: min(78vh, 720px);
    pointer-events: auto;
    transform: translateY(0);
}

.ajmc-button-position-top_right .ajmc-dropdown,
.ajmc-button-position-top_left .ajmc-dropdown {
    top: calc(100% + 12px);
    bottom: auto;
}

.ajmc-button-position-bottom_left .ajmc-dropdown,
.ajmc-button-position-top_left .ajmc-dropdown {
    left: 0;
    right: auto;
}

.ajmc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.ajmc-success-message {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #111;
    font-size: 14px;
}

.ajmc-check {
    font-size: 18px;
    line-height: 1;
}

.ajmc-close {
    background: none;
    border: none;
    font-size: 34px;
    line-height: 1;
    cursor: pointer;
    color: #111;
    font-weight: 300;
    padding: 0;
}

.ajmc-product {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 16px;
    margin-bottom: 20px;
    min-height: 74px;
}

.ajmc-empty-product {
    grid-column: 1 / -1;
    font-size: 14px;
    color: #555;
}

.ajmc-product-image-wrap {
    width: 72px;
    height: 72px;
    border: 1px solid #eee;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
}

.ajmc-product-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.ajmc-product-info {
    min-width: 0;
}

.ajmc-product-brand {
    font-size: 12px;
    color: #999;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.ajmc-product-info h4 {
    margin: 0 0 6px;
    font-size: 17px;
    line-height: 1.1;
    color: #111;
    font-weight: 400;
}

.ajmc-product-attribute, .ajmc-product-quantity, .ajmc-product-price {
    font-size: 14px;
    color: #111;
    line-height: 1.5;
}

.ajmc-free-shipping {
    background: linear-gradient(135deg, #04efe1 0%, #e4b7ff 100%);
    border-radius: 7px;
    padding: 20px 16px;
    margin-bottom: 20px;
    text-align: center;
}

.ajmc-upsell-wrapper {
    position: relative;
}

.ajmc-upsell-viewport {
    overflow: hidden;
}

.ajmc-upsell-track {
    display: flex;
    gap: 10px;
}

.ajmc-upsell-item {
    display: grid;
    grid-template-columns: 54px 1fr auto;
    align-items: center;
    gap: 10px;
    min-width: 0;
    box-sizing: border-box;
    text-align: left;
}

.ajmc-upsell-double .ajmc-upsell-track {
    flex-wrap: wrap;
}

.ajmc-upsell-double .ajmc-upsell-item {
    flex: 0 0 calc(50% - 5px);
    width: calc(50% - 5px);
}

.ajmc-upsell-single .ajmc-upsell-track {
    justify-content: center;
}

.ajmc-upsell-single .ajmc-upsell-item {
    flex: 0 0 550px;
    width: 550px;
    max-width: 100%;
}

.ajmc-upsell-nav {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 10px;
}

.ajmc-upsell-nav button {
    background: none;
    border: none;
    color: #174291;
    cursor: pointer;
    padding: 4px;
    line-height: 0;
}
.ajmc-checkout:hover {
    color: #fff;
}
.ajmc-upsell-image {
    display: block;
    width: 50px;
    height: 50px;
    background: #fff;
    border-radius: 6px;
    overflow: hidden;
}

.ajmc-upsell-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.ajmc-upsell-details {
    min-width: 0;
}

.ajmc-upsell-title {
    display: block;
    color: #174291;
    font-size: 13px;
    line-height: 1.3;
    text-decoration: none;
}

.ajmc-upsell-price {
    display: block;
    color: #174291;
    font-size: 13px;
    line-height: 1.3;
    margin-top: 3px;
}

.ajmc-upsell-button {
    border: 1px solid #174291;
    border-radius: 4px;
    padding: 8px 10px;
    color: #174291;
    background: rgba(255, 255, 255, 0.45);
    text-decoration: none;
    font-size: 12px;
    white-space: nowrap;
}

.ajmc-free-shipping p {
    margin: 0 0 18px;
    color: #00256d;
    font-weight: 700;
    font-size: 15px;
    line-height: 1.5;
}

.ajmc-progress-wrap {
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: #fff;
    margin-bottom: 18px;
    overflow: hidden;
}

.ajmc-progress-bar {
    width: 0%;
    height: 100%;
    background: #174291;
    border-radius: 999px;
    transition: width 0.25s ease;
}

.ajmc-recommendation {
    display: grid;
    grid-template-columns: 24px 1fr auto 24px;
    align-items: center;
    gap: 8px;
}

.ajmc-reco-arrow {
    background: none;
    border: none;
    color: #174291;
    font-size: 28px;
    cursor: pointer;
    padding: 0;
}

.ajmc-reco-product {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    text-align: left;
    text-decoration: none;
}

.ajmc-reco-product img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.ajmc-reco-product strong {
    display: block;
    color: #174291;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 82px;
}

.ajmc-reco-product em {
    display: block;
    color: #174291;
    font-size: 13px;
    font-style: normal;
}
.ajmc-cart-button svg {
    width: 44px;
    height: 44px;
    color: #000;
}
.ajmc-reco-button {
    border: 1px solid #174291;
    border-radius: 4px;
    padding: 9px 14px;
    color: #174291;
    text-decoration: none;
    font-size: 14px;
    white-space: nowrap;
}

.ajmc-view-cart,
.ajmc-checkout {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    border-radius: 999px;
    text-decoration: none;
    font-size: 15px;
    margin-bottom: 12px;
    transition: opacity 0.2s ease;
}

.ajmc-view-cart:hover,
.ajmc-checkout:hover {
    opacity: 0.85;
}
.ajmc-view-cart {
    border: 1px solid #111;
    color: #111;
    background: #fff;
}

.ajmc-checkout {
    border: 1px solid #111;
    color: #fff;
    background: #111;
    font-weight: 600;
}

.ajmc-continue {
    display: block;
    margin: 14px auto 0;
    background: none;
    border: none;
    border-bottom: 1px solid #111;
    color: #111;
    font-size: 14px;
    letter-spacing: 1px;
    cursor: pointer;
    padding: 0 0 2px;
}

.ajmc-loading {
    opacity: 0.6;
    pointer-events: none;
}

@media (max-width: 480px) {
    .ajmc-dropdown {
        width: calc(100vw - 32px) !important;
        padding: 18px;
    }

    .ajmc-button-position-bottom_right {
        right: 16px;
        bottom: 16px;
    }

    .ajmc-button-position-bottom_left {
        left: 16px;
        bottom: 16px;
    }

    .ajmc-button-position-top_right {
        right: 16px;
        top: 16px;
    }

    .ajmc-button-position-top_left {
        left: 16px;
        top: 16px;
    }

    .ajmc-button-position-bottom_right .ajmc-dropdown,
    .ajmc-button-position-top_right .ajmc-dropdown {
        right: 0;
        left: auto;
    }

    .ajmc-button-position-bottom_left .ajmc-dropdown,
    .ajmc-button-position-top_left .ajmc-dropdown {
        left: 0;
        right: auto;
    }

    .ajmc-upsell-item {
        grid-template-columns: 48px 1fr;
    }

    .ajmc-upsell-button {
        grid-column: 2;
        text-align: center;
    }

    .ajmc-recommendation {
        grid-template-columns: 20px 1fr 20px;
    }

    .ajmc-reco-button {
        grid-column: 2;
        margin-top: 8px;
        text-align: center;
    }
}
