.product-materials-popup {
    position: fixed;
    z-index: 120;
    top: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    width: 59.25rem;
    height: 100dvh;
    padding: 3.75rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    background-color: var(--color-white);
    visibility: hidden;
    pointer-events: none;
    transform: translateX(100%);
    transition:
            visibility 0.4s ease,
            transform 0.5s ease;
}

.product-materials-popup::-webkit-scrollbar {
    width: 0.125rem;
}

.product-materials-popup::-webkit-scrollbar-track {
    margin-block: 2.5rem;
    border-radius: 0.625rem;
    background-color: var(--color-black-20);
}

.product-materials-popup::-webkit-scrollbar-thumb {
    min-height: 3.75rem;
    border-radius: 0.625rem;
    background-color: var(--color-black-light);
}

@supports not selector(::-webkit-scrollbar) {
    .product-materials-popup {
        scrollbar-width: thin;
        scrollbar-color:
                var(--color-black-light)
                var(--color-black-20);
    }
}

.product-materials-popup.is-open {
    visibility: visible;
    pointer-events: auto;
    transform: translateX(0);
}

.product-materials-popup__close {
    position: absolute;
    z-index: 2;
    top: 1.25rem;
    right: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.125rem;
    height: 3.125rem;
    border-radius: 50%;
    background-color: var(--color-black-light);
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.product-materials-popup__close svg {
    width: 1.5rem;
    height: 1.5rem;
}

.product-materials-popup__title {
    max-width: 32.5rem;
    margin-bottom: 3.75rem;
}

.product-materials-popup__form {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
}

.product-materials-popup__fields {
    display: flex;
    flex-direction: column;
    width: 100%;
    row-gap: 1.25rem;
}

.product-materials-popup__field {
    width: 100%;
}

.product-materials-popup__input,
.product-materials-popup__textarea {
    display: block;
    width: 100%;
    border: 1px solid var(--color-black-20);
    border-radius: 0.625rem;
    outline: none;
    background-color: var(--color-white);
    transition: border-color 0.3s ease;
}

.product-materials-popup__input {
    height: 4.375rem;
    padding-inline: 1.5625rem;
}

.product-materials-popup__textarea {
    height: 12.5rem;
    padding: 1.5625rem;
    resize: none;
}

.product-materials-popup__input::placeholder,
.product-materials-popup__textarea::placeholder {
    color: var(--color-black-50);
}

.product-materials-popup__input:focus,
.product-materials-popup__textarea:focus {
    border-color: var(--color-black-light);
}

.product-materials-popup__field.is-error
.product-materials-popup__input {
    border-color: #d63638;
}

.product-materials-popup__error {
    min-height: 1rem;
    margin-top: 0.35rem;
    color: #d63638;
}

.product-materials-popup__policy {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.6875rem;
    margin-top: 1.25rem;
}

.product-materials-popup__policy-input {
    flex-shrink: 0;
    appearance: none;
    width: 1.25rem;
    height: 1.25rem;
    margin: 0;
    border: 1px solid var(--color-black-light);
    cursor: pointer;
    transition:
            background-color 0.3s ease,
            border-color 0.3s ease;
}

.product-materials-popup__policy.is-error
.product-materials-popup__policy-input {
    border-color: #d63638;
}

.product-materials-popup__policy-input:checked {
    background-color: var(--color-black-light);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='11' height='9' viewBox='0 0 11 9' fill='none'%3E%3Cpath d='M0.75 4.06579L3.85345 7.75L9.75 0.75' stroke='white' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 0.5625rem 0.4375rem;
}

.product-materials-popup__policy-label {
    max-width: 42rem;
    color: var(--color-black-50);
    cursor: pointer;
    user-select: none;
}

.product-materials-popup__policy-label a {
    color: var(--color-black-light);
    transition: color 0.3s ease;
}

@media (hover: hover) {
    .product-materials-popup__policy-label a:hover {
        color: var(--color-green-light);
    }
}

.product-materials-popup__policy-label a:active {
    color: var(--color-green-light);
}

.product-materials-popup__submit {
    margin-top: 3.125rem;
}

.product-materials-popup__submit:disabled {
    pointer-events: none;
    opacity: 0.6;
}

@media (max-width: 1024px) {
    .product-materials-popup {
        width: 31.875rem;
        padding: 3.75rem 1.25rem;
    }

    .product-materials-popup__close {
        width: 2.5rem;
        height: 2.5rem;
    }

    .product-materials-popup__title {
        max-width: 100%;
        margin-bottom: 2.5rem;
    }

    .product-materials-popup__fields {
        row-gap: 0.9375rem;
    }

    .product-materials-popup__input {
        height: 3.75rem;
        padding-inline: 1.25rem;
    }

    .product-materials-popup__textarea {
        height: 8.75rem;
        padding: 1.5625rem 1.25rem;
    }

    .product-materials-popup__policy {
        align-items: start;
        gap: 0.8125rem;
        margin-top: 1.875rem;
    }

    .product-materials-popup__policy-input {
        width: 1rem;
        height: 1rem;
        margin-top: 0.25rem;
    }

    .product-materials-popup__policy-input:checked {
        background-size: 0.5rem 0.375rem;
    }

    .product-materials-popup__policy-label {
        max-width: 100%;
    }

    .product-materials-popup__submit {
        margin-top: 1.25rem;
    }
}

@media (max-width: 768px) {
    .product-materials-popup {
        width: 100%;
        padding: 3.75rem 0.9375rem;
    }

    .product-materials-popup__close {
        top: 0.9375rem;
        right: 0.9375rem;
    }

    .product-materials-popup__title {
        max-width: 18.75rem;
    }
}