/* ===================== */
/* Reset e stili base     */
/* ===================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

body {
    background-color: #f0f2f5; /* nuovo colore di sfondo */
    color: #333;
    line-height: 1.6;
}

a {
    color: #4CAF50;
    text-decoration: none;
    transition: color 0.3s;
}

a:hover {
    color: #388E3C;
}

/* ===================== */
/* Container             */
/* ===================== */
.container {
    max-width: 1100px;
    margin: 20px auto;
    padding: 0 20px;
}

/* ===================== */
/* Header                */
/* ===================== */
header {
    text-align: center;
    padding: 30px 0;
    background-color: #ffffff;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    color: #4CAF50;
}

header p {
    font-size: 1.2em;
    color: #666;
}

/* ===================== */
/* Sezioni Intro & Funzionalità */
/* ===================== */
.intro, .Fun<ionalità>, .link {
    background-color: #ffffff;
    padding: 20px 30px;
    margin-bottom: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.intro h2, .Fun<ionalità> h2, .link h2 {
    color: #333;
    margin-bottom: 15px;
    font-size: 1.8em;
}

.intro p, .Fun<ionalità> p {
    margin-bottom: 10px;
}

/* ===================== */
/* Funzionalità cards     */
/* ===================== */
.lista, .velocita {
    display: inline-block;
    width: calc(50% - 20px);
    vertical-align: top;
    margin: 10px;
    text-align: center;
}

.lista img, .velocita img {
    width: 100px;
    height: 100px;
    object-fit: cover;
    margin-bottom: 10px;
}

.lista h3, .velocita h3 {
    font-size: 1.2em;
    margin-bottom: 5px;
}

/* ===================== */
/* Link & Pulsanti        */
/* ===================== */
.link a {
    display: inline-block;
    margin: 10px 5px;
    padding: 10px 20px;
    background-color: #4CAF50;
    color: #fff;
    border-radius: 8px;
    transition: background-color 0.3s;
}

.link a:hover {
    background-color: #388E3C;
}

/* ===================== */
/* Form                  */
/* ===================== */
form {
    display: flex;
    flex-direction: column;
}

form input[type="email"],
form input[type="password"],
form input[type="text"] {
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 1em;
}

form button,
button,
input[type="submit"] {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 12px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    display: inline-block;
    transition: background-color 0.3s;
}

form button:hover,
button:hover,
input[type="submit"]:hover {
    background-color: #388E3C;
}

/* Pulsanti specifici catalogo */
.btn-add {
    background-color: #4CAF50 !important;
    color: white !important;
}

.btn-remove {
    background-color: #f44336 !important;
    color: white !important;
}

/* ===================== */
/* Catalogo              */
/* ===================== */
.catalogo {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: space-between;
}

.card {
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    padding: 15px;
    width: calc(33.33% - 20px);
    text-align: center;
    transition: transform 0.3s;
}

.card:hover {
    transform: translateY(-5px);
}

.card img {
    max-width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
}

.card h3 {
    font-size: 1.2em;
    margin-bottom: 5px;
}

.card p {
    font-size: 0.95em;
    color: #666;
    margin-bottom: 10px;
}

.card .badge {
    display: inline-block;
    background-color: #FF9800;
    color: #fff;
    padding: 5px 10px;
    border-radius: 12px;
    font-size: 0.85em;
    margin-bottom: 10px;
}

/* ===================== */
/* Carrello              */
/* ===================== */
.prodotto {
    display: flex;
    align-items: center;
    background-color: #fff;
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 15px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.prodotto img {
    border-radius: 8px;
    margin-right: 20px;
    width: 120px;
    height: 120px;
    object-fit: cover;
}

.prodotto h3 {
    flex: 1;
    font-size: 1.2em;
}

.actions form {
    display: inline-block;
}

.actions button {
    background-color: #4CAF50;
    color: white;
    min-width: 40px;
    min-height: 40px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-size: 1em;
    margin-right: 5px;
    transition: background-color 0.3s;
}

.actions form:last-child button {
    background-color: #f44336;
}

.actions button:hover {
    opacity: 0.85;
}

/* ===================== */
/* Responsive di base    */
/* ===================== */
@media (max-width: 900px) {
    .card {
        width: calc(50% - 20px);
    }
    .lista, .velocita {
        width: 100%;
    }
}

@media (max-width: 600px) {
    .card {
        width: 100%;
    }
    .actions button {
        min-width: 35px;
        min-height: 35px;
    }
}