.wrapper {
    padding: 60px 0;
}
.table {
    display: flex;
    flex-direction: column;
    gap: 80px;
    .promo {
        display: flex;
        flex-direction: column;
        gap: 40px;
        background: var(--light-green);
        box-shadow: var(--shadow-1);
        padding: 40px;
        border-radius: 40px;
        h1 {
            display: flex;
            flex-direction: column;
            gap: 5px;
            max-width: fit-content;
            &::after {
                content: '';
                width: 100%;
                height: 2px;
                background: var(--accent);
            }
        }
        .container {
            table {
                border-radius: 30px;
                overflow: hidden;
                width: 100%;
                table-layout: fixed;
                border-collapse: separate;
                border-spacing: 0;
                border: 1px solid var(--light-text);
                background: var(--light);
                tr {
                    position: relative;
                    td {
                        text-align: center;
                        position: relative;
                        &:not(:last-child)::after {
                            content: "";
                            position: absolute;
                            top: 20%;
                            bottom: 20%;
                            right: 0;
                            width: 1px;
                            background-color: var(--light-green);
                        }
                    }
                    th {
                        text-align: left;
                    }
                    td, th {
                        padding: 10px;
                    }
                    td.name {
                        div {
                            display: grid;
                            grid-template-columns: repeat(2, minmax(0, 1fr));
                            gap: 0 20px;
                            .img-link {
                                grid-row: span 2;
                                align-self: center;
                                justify-self: center;
                                max-width: 120px;
                            }
                            a {
                                font-weight: 700;
                                &:nth-child(2) {
                                    align-self: end;
                                    color: var(--light-text);
                                }
                                &:nth-child(3) {
                                    align-self: start;
                                    font-size: 20px;
                                }
                            }
                        }
                    }
                    &:not(:last-child)::after {
                        content: "";
                        position: absolute;
                        left: 3%;
                        right: 3%;
                        bottom: 0;
                        height: 1px;
                        background-color: var(--light-green);
                    }
                }
                thead {
                    background: var(--light-text);
                    border-radius: 30px 30px 0 0;
                    tr {
                        th {
                            color: var(--light);
                            padding: 20px;
                        }
                    }
                }
                tbody {
                    tr {
                        td {
                            color: var(--light-text);
                            text-align: left;
                            padding: 40px;
                            h3 {
                                color: var(--light-text);
                                text-align: center;
                            }
                            img {
                                border-radius: 10px;
                            }
                            ul li {
                                text-align: left;
                                align-items: center;
                                p {
                                    font-weight: 700;
                                    span {
                                        font-weight: 400;
                                    }
                                }
                                .set-value {
                                    font-size: 16px;
                                    padding: 5px 10px;
                                    border: 1px solid #ccc;     
                                    margin-left: 20px;
                                    gap: 4px;
                                    background: var(--light-green);
                                    color: var(--green);
                                    span {
                                        font-weight: 700;
                                    }
                                }
                                .field {
                                    display: none;
                                    margin-left: 20px;
                                    .action {
                                        display: flex;
                                        button {
                                            padding: 0;
                                            height: 40px;
                                            width: 40px;
                                            &::before {
                                                font-family: icon;
                                                font-size: 16px;
                                                transition: .2s linear;
                                            }
                                            &.save {
                                                background: var(--success-bg);
                                                border-radius: 10px 0 0 10px;
                                                &::before {
                                                    content: '\e914';
                                                    color: var(success);
                                                }
                                            }
                                            &.close {
                                                border-radius: 0 10px 10px 0;
                                                background: var(--error-bg);
                                                &::before {
                                                    content: '\e915';
                                                    color: red;
                                                }
                                            }
                                        }
                                        input {
                                            padding: 5px 10px;
                                            font-size: 16px;
                                            border: 1px solid transparent;
                                            border-radius: 0;
                                            background: var(--light-green);
                                            text-align: center;
                                            -moz-appearance: textfield;
                                            appearance: textfield;
                                            &:focus {
                                                border: 1px solid var(--green);
                                            }
                                            &::-webkit-outer-spin-button, &::-webkit-inner-spin-button {
                                                -webkit-appearance: none;
                                                margin: 0;
                                            }
                                        }
                                    }
                                    span {
                                        font-size: 14px;
                                        color: red;
                                    }
                                }
                                &.set-value {
                                    .set-value {
                                        display: none;
                                    }
                                    .field {
                                        display: block;
                                    }
                                }
                            }
                            &.price {
                                span {
                                    color: var(--accent);
                                }
                            }
                            &.actions {
                                height: 100%;
                                position: relative;
                                padding: 20px;
                                .change {
                                    display: flex;
                                    flex-direction: column;
                                    justify-content: space-between;
                                    gap: 10px;
                                    .amount {
                                        display: flex;
                                        align-items: center;
                                        border-radius: 17px;
                                        border: 1px solid #ccc;
                                        padding: 3px;
                                        gap: 3px;
                                        button {
                                            padding: 10px 15px;
                                            border-radius: 15px;
                                            height: 40px;
                                            width: 40px;
                                        }
                                        input {
                                            width: 100%;
                                            border: none;
                                            text-align: center;
                                            padding: 5px;
                                            background: var(--light-green);
                                            border-radius: 5px;
                                            transition: .3s linear;
                                            -moz-appearance: textfield;
                                            appearance: textfield;
                                            &:focus {
                                                border: 1px solid var(--green);
                                            }
                                            &::-webkit-outer-spin-button, &::-webkit-inner-spin-button {
                                                -webkit-appearance: none;
                                                margin: 0;
                                            }
                                        }
                                    }
                                }
                                .menu {
                                    position: absolute;
                                    display: flex;
                                    top: 20px;
                                    right: 20px;
                                    .show-menu {
                                        display: flex;
                                        flex-direction: column;
                                        gap: 2px;
                                        width: 15px;
                                        height: 20px;
                                        align-items: center;
                                        justify-content: center;
                                        border-radius: 5px;
                                        cursor: pointer;
                                        transition: .2s linear;
                                        span, &::before, &::after {
                                            content: '';
                                            width: 4px;
                                            height: 4px;
                                            background: var(--light-text);
                                            border-radius: 4px;
                                        }
                                    }
                                    .items {
                                        position: absolute;
                                        display: flex;
                                        flex-direction: column;
                                        right: 0;
                                        top: 20px;
                                        padding: 5px;
                                        background: var(--light);
                                        box-shadow: var(--shadow-1);
                                        border-radius: 10px;
                                        visibility: hidden;
                                        opacity: 0;
                                        transition: .2s linear;
                                        button, a {
                                            padding: 2px 10px;
                                            color: var(--light-text);
                                            border-radius: 6px;
                                        }
                                        &.active {
                                            visibility: visible;
                                            opacity: 1;
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                thead th:nth-child(1), tbody td:nth-child(1) {
                    width: 35%;
                }
                thead th:nth-child(2), tbody td:nth-child(2) {
                    width: 33%;
                }
                thead th:nth-child(3), tbody td:nth-child(3) {
                    width: 15%;
                }
                thead th:nth-child(4), tbody td:nth-child(4) {
                    width: 17%;
                }
            }
        }
        .info {
            display: flex;
            gap: 100px;
            button {
                max-width: 200px;
            }
        }
    }
}
.empty {
    padding: 100px 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
    .items {
        max-width: 300px;
        width: 100%;
        display: flex;
        flex-direction: column;
        a {
            padding: 10px;
            color: var(--light-text);
            border-radius: 10px;
        }
    }
}
.cart-items {
    display: none;
}
.cart-form {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 50px;
    position: relative;
    h2 {
        grid-column: span 2;
    }
    .user {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 50px;
        fieldset:last-of-type {
            grid-column: span 2;
            display: flex;
            flex-direction: row;
            gap: 20px;
        }
    }
    fieldset {
        display: flex;
        border: none;
        flex-direction: column;
        gap: 10px;
        textarea {
            min-height: 158px;
            max-height: 400px;
            border-radius: 30px;
            &:focus {
                border: 1px solid var(--green);
                outline: none;
            }
        }
        input {
            padding: 15px 20px;
            border-radius: 30px;
            &:focus {
                border: 1px solid var(--green);
            }
        }
        label {
            color: var(--light-text);
        }
    }
    > button {
        max-width: unset;
    }
}
@media screen and (max-width: 1279px) {
    .table {
        .container {
            overflow-x: auto;
            table {
                min-width: 1100px;
            }
        }
    }
    .cart-form {
        display: flex;
        flex-direction: column;
        gap: 20px;
        .submit {
            flex-direction: column;
            gap: 20px;
            .agreement {
                width: 100%;
            }
        }
        .user {
            gap: 20px;
        }
    }
}
@media screen and (max-width: 767px) {
    .cart-form {
        display: flex;
        flex-direction: column;
        gap: 20px;
        .user {
            display: flex;
            flex-direction: column;
        }
    }
}
@media screen and (hover: hover){
    .table .container table tbody {
        tr {
            td {
                ul li {
                    .set-value:hover {
                        transform: translateY(-2px);
                        box-shadow: var(--shadow-1);
                    }
                    .field {
                        .action button:hover {
                            &::before {
                                transform: scale(1.3);
                            }
                        }
                    }
                }
                    &.actions {
                    .change {
                        .amount {
                            input:hover {
                                box-shadow: var(--shadow-1);
                            }
                            .btn.green:hover {
                                background: var(--light);
                                outline: 1px solid var(--green);
                                color: var(--green);
                            }
                            .decrease:hover {
                                color: red;
                                background: var(--error-bg);
                            }
                            .increase:hover {
                                color: var(--success);
                                background: var(--success-bg);
                            }
                        }
                    }
                    .menu {
                        .show-menu:hover {
                            background: var(--light-green);
                        }
                        .delete:hover {
                            background: var(--error-bg);
                        }
                    }
                }
            }
        }
    }
    .empty {
        .items {
            a:hover {
                box-shadow: var(--shadow-1);
                background: var(--light-green);
                color: var(--dark);
            }
        }
    }
}