:root {
    --shadow: 0px 4px 16px 0px #00000040;
    --green-Color: #A8D060;
    --purple-Color: #8860D0;
    --black-color: #333333;
    --second-white: #F5F5F7;
    --second-purole: #C1C8E4;
}

/* product side section */

.product-side-section {
    display: flex;
    flex-direction: column;
}

.product-side-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    /* background-color: var(--second-purole); */
    border-radius: 12px;
    margin: 0 0 2rem 0;
    font-size: 1.3rem;

}

.product-side-header h2 {
    font-size: 1.5rem;
}

select#sort {
    border-radius: 5px;
    font-size: 16px;
    padding: 5px;

}


.products-container {
    display: flex;
    gap: 4rem;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    flex-direction: column;
}

#add-new-product {
    color: #fff;
    background-color: var(--primary-Color);
    padding: 0.7rem 2rem;
    border-radius: 27px;
    border: none;
    /* font-size: 20px; */
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
}

/* products-section */
.products-section {
    width: 95%;
    margin: 0 0 10rem 4%;
    position: relative;
}

.products-section-product-container::-webkit-scrollbar {
    display: none;
}

.products-section-header h2 {
    font-size: 2rem;
    color: var(--black-color);
    margin: 0 0 2rem 1%;
}

.products-section-product {
    width: 15rem;
    padding: 1rem;
    box-shadow: var(--shadow);
    cursor: pointer;
    background-color: var(--second-white);
    display: flex;
    flex-direction: column;
    gap: 0rem;
    height: fit-content;

}

.products-section-product:hover {
    transform: scale(1.05);
    transition: all .5s ease;
}

.products-section-product-container {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    position: relative;
    padding: 2% 1%;
}

#previous-button,
#next-button {
    position: absolute;
    z-index: 10;
    top: 50%;
}

#next-button {
    right: 0;
}


.products-section-products-photo,
.model-section-model-photo {
    position: relative;
    text-align: center;
    padding: 1rem;
    width: 13rem;
    height: 12rem;
}

.products-section-product:hover .products-section-products-photo img {
    transform: scale(1.15);
    transition: transform 0.5s ease;
}


.products-section-products-photo img,
.model-section-model-photo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.like-product-button {
    position: absolute;
    top: 0;
    right: 10px;
    border: none;
    cursor: pointer;
    display: none;
}

.products-section-products-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

.products-section-products-details-name,
.model-details {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 1rem;
}

#product-name,
#model-name {
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.products-section-products-details h4 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--purple-Color);
}

.products-section-products-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1rem 0 0 0;
}

#product-price {
    font-size: 1.5rem;
}

.product-controles {
    display: flex;
    gap: 2rem;
    flex-direction: column;
}

a.add-model {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: silver;
    padding: .4rem 0rem;
    border-radius: 12px;
}

.product-controls-buttons,
.model-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1rem 0 0 0;
}

.edit-product {
}

.edit-product,
.delete-product,
.edit-model,
.delete-model {
    display: flex;
    align-items: flex-end;
    gap: 7px;
    font-size: 1.2rem;
    cursor: pointer;
}

.delete-product {
    color: #ff0000;
}

/* products-section */
/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgb(0, 0, 0);
    background-color: rgba(0, 0, 0, 0.4);
    padding-top: 60px;
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    text-align: center;
    border-radius: 12px;
}

.modal-content h2 {
    margin: 0 0 1rem 0;
    font-size: 1.3rem;
}

.close-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close-button:hover,
.close-button:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.confirm-delete {
    background-color: red;
    color: white;
    padding: .7rem 3rem;
    margin: 10px;
    border: none;
    cursor: pointer;
    border-radius: 25px;
}

.cancel-delete {
    background-color: gray;
    color: white;
    padding: .7rem 3rem;
    margin: 10px;
    border: none;
    cursor: pointer;
    border-radius: 25px;
}

.product-model-group {
    display: grid;
    gap: 4rem 2rem;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    background-color: #F2F2FF;
    padding: 20px;
    justify-items: center;
}

.product-name-header{
    font-size: 28px;
    color: var(--primary-Color);
    font-weight: 600;
}