/**
 * Loop Modals Styles
 * Bottom-sheet modals for mobile size selection and add-to-cart confirmation.
 */

/* ==========================================================================
   Loop mobile sizes bottom-sheet modal
   ========================================================================== */

.loop-mobile-sizes-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
}

.loop-mobile-sizes-modal[hidden] {
    display: none;
}

.loop-mobile-sizes-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.2);
    animation: lms-fade-in 0.25s ease;
}

.loop-mobile-sizes-modal__sheet {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    animation: lms-slide-up 0.3s ease;
    overflow: hidden;
}

@keyframes lms-fade-in {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes lms-slide-up {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

.loop-mobile-sizes-modal__label {
    font-size: 14px;
    font-weight: 500;
    padding: 18px 16px;
    margin: 0;
}

.loop-mobile-sizes-modal__buttons {
    display: flex;
    flex-direction: column;
    max-height: 195px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.loop-mobile-sizes-modal__buttons .loop-size-btn {
    position: relative;
    padding: 23px 20px;
    font-weight: 500;
    font-size: 14px;
    line-height: 18px;
    border-top: 1px solid rgba(229, 229, 229, 0.4);
    transition: color 0.15s;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.loop-mobile-sizes-modal__buttons .loop-size-btn:active {
    background-color: #f5f5f5;
}

.loop-mobile-sizes-modal__buttons .loop-size-btn.disabled {
    color: #b6b6b6;
    pointer-events: none;
    cursor: not-allowed;
}

.loop-mobile-sizes-modal__buttons .loop-size-btn.loading {
    color: transparent;
    pointer-events: none;
}

.loop-mobile-sizes-modal__buttons .loop-size-btn.loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 18px;
    height: 18px;
    margin: -9px 0 0 -9px;
    border: 2px solid rgba(0, 0, 0, 0.12);
    border-top-color: #2d2a26;
    border-radius: 50%;
    animation: lms-spin 0.65s linear infinite;
}

@keyframes lms-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.loop-mobile-sizes-modal__buttons .loop-size-btn:last-child {
    border-bottom: 1px solid rgba(229, 229, 229, 0.4);
}

/* ==========================================================================
   Loop: size guide card (inside the sizes bottom sheet)
   ========================================================================== */

.loop-size-guide-card {
    display: flex;
    align-items: center;
    gap: 8px;
    width: calc(100% - 24px);
    background: #f4f5ff;
    border: none;
    border-radius: 6px;
    padding: 12px 16px 12px 4px;
    margin: 25px 12px 17px;
    cursor: pointer;
    text-align: left;
    -webkit-tap-highlight-color: transparent;
}

.loop-size-guide-card__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
}

.loop-size-guide-card__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-width: 0;
}

.loop-size-guide-card__title {
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 4px;
    line-height: 1;
    color: #0b1215;
}

.loop-size-guide-card__subtitle {
    font-size: 11px;
    font-weight: 400;
    line-height: 1;
    color: #0b1215;
}

.loop-size-guide-card__arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 16px;
    height: 16px;
}

/* ==========================================================================
   Loop: added-to-cart confirmation bottom sheet
   ========================================================================== */

.loop-added-modal {
    position: fixed;
    inset: 0;
    z-index: 100002;
    display: flex;
    align-items: flex-end;
}

.loop-added-modal[hidden] {
    display: none !important;
}

.loop-added-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    animation: lms-fade-in 0.25s ease;
}

.loop-added-modal__sheet {
    position: relative;
    width: 100%;
    background: #fff;
    border-radius: 2px;
    padding: 12px 16px;
    animation: lms-slide-up 0.32s ease;
}

.loop-added-modal__content {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 18px;
}

.loop-added-modal__image {
    flex-shrink: 0;
    width: 50px;
    height: 68px;
    overflow: hidden;
}

.loop-added-modal__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: flex;
}

.loop-added-modal__label {
    display: flex;
    align-items: center;
    font-size: 12px;
    font-weight: 600;
    line-height: 22px;
    text-transform: uppercase;
    color: #000000;
    margin: 0;
}

.loop-added-modal__cart-btn.button {
    display: flex;
    text-align: center;
    align-items: center;
    justify-content: center;
    background: #161619;
    border-radius: 0;
    border: none;
    cursor: pointer;
    padding: 0;
    text-decoration: none;
    text-transform: none;
    box-sizing: border-box;
    font-weight: 600;
    font-size: 14px;
    color: #ffffff;
    line-height: 40px;
    letter-spacing: 0%;
    border: 1px solid #161619;
    min-height: 42px;
    max-width: 160px;
    width: 100%;
    margin-left: auto;
}

@media (hover: hover) {
    .loop-added-modal__cart-btn.button:hover {
        background-color: #ff5000;
        border-color: #ff5000;
    }
}

.loop-size-guide-panel .panel p.title {
    margin: 0;
}
