/* Stiluri generale */
body {
    font-family: Arial, sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    height: 100vh;
    margin: 0;
    background-color: #000000;
    padding: 10px;
}

h2 {
    text-align: center;
    margin-bottom: 15px;
    color: white;
    display: inline-block;
    padding: 8px;
    background-color: #8C1864;
    border-radius: 5px;
    font-size: 20px;
}

/* Container pentru cele două secțiuni */
.container-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    width: 95%;
    max-width: 1100px;
    gap: 30px;
}

/* Secțiunea de produse (cart) */
#cartItems {
    background-color: #F229AC;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* Fiecare produs din coș */
.cart-item {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 8px;
    background-color: #fff;
    border-radius: 5px;
    margin-bottom: 10px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    gap: 10px;
}

/* Detalii produs și cantitate pe aceeași linie */
.cart-item-details {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    width: 100%;
    font-size: 16px;
    gap: 8px;
}

/* Butoane de modificare cantitate */
.quantity-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 5px 8px;
    cursor: pointer;
    border-radius: 4px;
    font-size: 14px;
    margin-left: 3px;
    margin-right: 3px;
    margin-top: 0;
}

.quantity-btn:hover {
    background-color: #218838;
}

/* Buton de eliminare produs */
.remove-btn {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
    border-radius: 4px;
    font-size: 14px;
    margin-top: 0;
}

.remove-btn:hover {
    background-color: darkred;
}

/* Formular de comenzi */
form {
    width: 48%;
    background: #F229AC;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    margin-top: 20px;
}

/* Etichete pentru formular */
label {
    margin-top: 6px;
    font-weight: bold;
    color: #fff;
    font-size: 14px;
}

/* Input-uri formular */
input {
    padding: 6px;
    margin-top: 4px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
}

/* Butonul de trimitere */
button {
    margin-top: 10px;
    padding: 8px;
    background-color: #633D73;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #0056b3;
}

/* Imagini fixate (background) */
.top-image, .bottom-image {
    position: fixed;
    left: 0;
    width: 100%;
    height: auto;
    z-index: -1;
}

.top-image {
    top: 0;
}

.bottom-image {
    bottom: 0;
}

/* Logo */
.logo {
    z-index: 11;
    width: 100px;
    height: auto;
    display: block;
    margin: 0 auto;
    padding-bottom: 10px;
}

/* Opțiuni livrare și plată */
.delivery-options, .payment-options {
    display: flex;
    justify-content: space-evenly;
    gap: 12px;
    margin-bottom: 12px;
}

/* Etichete opțiuni livrare și plată */
.delivery-label, .payment-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-weight: bold;
    font-size: 14px;
    color: #fff;
}

/* Personalizare radio pentru opțiuni livrare și plată */
.delivery-label input, .payment-label input {
    display: none;
}

.custom-radio {
    width: 16px;
    height: 16px;
    border: 2px solid #007bff;
    border-radius: 50%;
    display: inline-block;
    position: relative;
}

.delivery-label input:checked + .custom-radio,
.payment-label input:checked + .custom-radio {
    background-color: #007bff;
}

.delivery-label input:checked + .custom-radio::after,
.payment-label input:checked + .custom-radio::after {
    content: "";
    width: 7px;
    height: 7px;
    background: white;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Total comanda */
.total {
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    color: #fff;
    background-color: #8C1864;
    padding: 12px;
    border-radius: 8px;
    margin-top: 20px;
}

/* Opțiuni sector */
.sector-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 10px 0;
}

.sector-options label {
    background: #8C1864;
    padding: 10px;
    border-radius: 5px;
    cursor: pointer;
}

.sector-options input[type="radio"] {
    display: none;
}

.sector-options label:hover {
    background: #ddd;
}

.sector-options input[type="radio"]:checked + label {
    background: #4CAF50;
    color: white;
}

#deliveryFields {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px;
    display: flex;
    flex-direction: column;
}

/* Media Queries */
@media (max-width: 768px) {
    .container-wrapper {
        flex-direction: column;
        width: 100%;
        gap: 20px;
        align-items: center;
    }

    #cartItems {
        width: 100%;
        max-width: 400px;
        overflow: hidden;
        padding: 15px;
        box-sizing: border-box;
        position: relative;
    }

    #cartItems h3 {
        text-align: center;
    }

    #cartItems strong {
        margin-top: auto;
        font-weight: bold;

    }

    form {
        width: 100%;
        max-width: 400px;
        padding: 15px;
        box-sizing: border-box;
    }

    .cart-item {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 10px;
        width: 90%;
        max-width: 400px;
        margin: 0 auto;
    }

    .quantity-btn {
        padding: 10px;
        font-size: 15px;
        width: 30px;
        margin-top: 0;
    }

    .remove-btn {
        width: 100px;
        padding: 10px;
        font-size: 15px;
        margin-top: 0;
    }

    label {
        font-size: 12px;
        margin-top: 10px;
        color: #fff;
    }

    input {
        width: 100%;
        padding: 10px;
        margin: 8px 0;
        font-size: 14px;
        border-radius: 5px;
        border: 1px solid #ccc;
    }

    #nume, #telefon, #adresa, #bloc, #apartament, #etaj, #interfon, #email {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 10px;
    }

    button {
        width: 100%;
        padding: 12px;
        font-size: 16px;
        background-color: #633D73;
        color: white;
        border: none;
        border-radius: 4px;
        cursor: pointer;
        transition: background-color 0.3s ease;
    }

    button:hover {
        background-color: #0056b3;
    }

    .delivery-options, .payment-options {
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }

    .total {
        font-size: 20px;
        padding: 15px;
        text-align: center;
    }
    
    
    
}


/* Stilizare pentru modalul de personalizare */
#product-customization {
    display: none; /* Inițial ascuns */
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    width: 300px;
    max-width: 90%;
}

/* Fundalul care acoperă restul paginii când modalul este deschis */
#modal-overlay {
    display: none; /* Inițial ascuns */
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

/* Butoanele din modal */
#add-to-cart-with-customization, #close-customization-modal {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    margin-top: 10px;
    cursor: pointer;
    border-radius: 5px;
}

#close-customization-modal {
    background-color: #f44336;
}

#add-to-cart-with-customization:hover, #close-customization-modal:hover {
    opacity: 0.8;
}

/* Titluri și etichete pentru personalizare */
#product-customization h2 {
    text-align: center;
    margin-bottom: 20px;
}

#product-customization label {
    display: block;
    margin-bottom: 10px;
}
   



/* Stilizare pentru modalul de personalizare */
#product-customization {
    display: none; /* Inițial ascuns */
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    width: 300px;
    max-width: 90%;
}

/* Fundalul care acoperă restul paginii când modalul este deschis */
#modal-overlay {
    display: none; /* Inițial ascuns */
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

/* Butoanele din modal */
#add-to-cart-with-customization, #close-customization-modal {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    margin-top: 10px;
    cursor: pointer;
    border-radius: 5px;
}

#close-customization-modal {
    background-color: #f44336;
}

#add-to-cart-with-customization:hover, #close-customization-modal:hover {
    opacity: 0.8;
}

/* Titluri și etichete pentru personalizare */
#product-customization h2 {
    text-align: center;
    margin-bottom: 20px;
}

#product-customization label {
    display: block;
    margin-bottom: 10px;
}
