/* Import Google Font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600&display=swap');

/* RESET BASE */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* BODY - Sfondo chiaro, stile moderno */
body {
    background-color: #f4f4f4;
    color: #333;
    font-size: 16px;
    line-height: 1.6;
}

/* CONTAINER GENERALE */
.dashboard-container {
    width: 90%;
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

/* NAVBAR */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #333;
    padding: 15px 20px;
    color: white;
    font-size: 22px;
    font-weight: 600;
}

/* LOGOUT a destra come pulsante rosso */
.logout-btn {
    background: #dc3545;
    color: white;
    padding: 10px 15px;
    border-radius: 5px;
    text-decoration: none;
    transition: 0.3s;
    font-size: 14px;
}

.logout-btn:hover {
    background: #a71d2a;
}

/* 🔍 BARRA DI RICERCA - Spostata sotto il logout e allineata meglio */
.search-container {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-bottom: 10px;
    padding-right: 20px;
}

.search-container h3 {
    flex-grow: 1;
    margin-left: 10px;
    font-size: 20px;
}

.search-container input {
    padding: 8px;
    width: 250px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    transition: 0.3s ease-in-out;
}

.search-container input:focus {
    border-color: #007bff;
    outline: none;
}

/* 🖼️ TABELLA - Allineamento migliorato */
.table-container {
    width: 100%;
    display: flex;
    justify-content: center;
}

table {
    width: 95%;
    border-collapse: collapse;
    margin: 20px auto;
    font-size: 16px;
    min-width: 600px;
}

table th, table td {
    padding: 12px;
    border-bottom: 1px solid #ddd;
    text-align: center;
}

table th {
    background: #007bff;
    color: white;
    cursor: pointer;
}

table tr:nth-child(even) {
    background: #f9f9f9;
}

table tr:hover {
    background: #e6e6e6;
}

/* 🎯 PULSANTE DI INVIO - Spostato e centrato meglio */
button.btn-primary {
    display: block;
    margin: 20px auto;
    padding: 10px 20px;
    background: #007bff;
    color: white;
    border: none;
    font-size: 16px;
    border-radius: 5px;
    transition: 0.3s;
    cursor: pointer;
}

button.btn-primary:hover {
    background: #0056b3;
}

/* 📌 BOTTONI */
button, .btn {
    display: inline-block;
    padding: 10px 15px;
    font-size: 16px;
    border: none;
    cursor: pointer;
    border-radius: 5px;
    transition: 0.3s ease-in-out;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #a71d2a;
}

/* 📍 MAPPA */
#map {
    height: 500px;
    width: 90%;
    margin: 20px auto;
    border-radius: 8px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}
/* LOGIN PAGE */
.login-container {
    width: 100%;
    height: 100vh; /* Occupa tutta l'altezza dello schermo */
    display: flex;
    justify-content: center;
    align-items: center;
    background: #f4f4f4;
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
    width: 400px;
}

/* LOGO */
.login-box img {
    width: 150px;
    margin-bottom: 20px;
}

/* TESTO */
.login-box h2 {
    margin-bottom: 20px;
    font-size: 22px;
    font-weight: 600;
    color: #333;
}

/* CAMPI INPUT */
.login-box input {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
}

.login-box input:focus {
    border-color: #007bff;
    outline: none;
}

/* PULSANTE LOGIN AZZURRO */
.login-box button {
    width: 100%;
    background: #007bff; /* Blu */
    color: white;
    padding: 12px;
    font-size: 16px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
}

.login-box button:hover {
    background: #0056b3; /* Blu pi첫 scuro al passaggio del mouse */
}
.search-container button {
    margin-left: 10px;
    padding: 5px 10px;
    font-size: 16px;
    background-color: #4CAF50;
    color: white;
    border: none;
    cursor: pointer;
}

.search-container button:hover {
    background-color: #45a049;
}
/* Responsive Design per la visualizzazione su dispositivi mobili */

@media only screen and (max-width: 768px) {
    /* Contenitore principale per centrare tutto */
    .search-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        width: 100%;
        gap: 10px; /* Spazio uniforme tra gli elementi */
    }

    /* Stessa larghezza per il pulsante e la barra di ricerca */
    .search-container button,
    .search-container input {
        width: 90%; /* Entrambi avranno la stessa larghezza */
        max-width: 320px; /* Larghezza massima */
        padding: 12px;
        font-size: 16px;
        text-align: center;
        border-radius: 5px;
        display: block;
    }

    /* Pulsante "Aggiorna Stato" */
    .search-container button {
        background-color: #4CAF50;
        color: white;
        border: none;
        cursor: pointer;
    }

    .search-container button:hover {
        background-color: #45a049;
    }

    /* Barra di ricerca */
    .search-container input {
        border: 1px solid #ccc;
    }

    /* Titolo "Elenco Veicoli" */
    .search-container h3 {
        font-size: 20px;
        font-weight: bold;
        text-align: center;
        width: 100%;
        margin-top: 10px; /* Spazio sopra il titolo */
    }
}
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background-color: #333;
    color: white;
}

.navbar-left h2 {
    margin: 0;
}

.navbar-right {
    display: flex;
    gap: 10px;
}

/*inizio mod.erde per Dashboard */
/* Pulsante Verde per Dashboard */
.btn-home {
    background-color: #4CAF50 !important; /* Verde */
    color: white;
    padding: 10px 15px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    border: none;
    cursor: pointer;
    display: block;
    text-align: center;
}

.btn-home:hover {
    background-color: #45a049 !important;
}

/* Pulsante Arancione per Storico Invii e Cambia Azienda */
.btn-warning {
    background-color: #ff9800 !important; /* Arancione */
}

.btn-warning:hover {
    background-color: #e68900 !important;
}

.btn-blue {
    background-color: #33b5e5 !important; /* Blu chiaro */
}

.btn-blue:hover {
    background-color: #0099cc !important;
}


/* Pulsante Grigio per Gestione Utenti */
.btn-grey {
    background-color: #6c757d !important; /* Grigio */
}

.btn-grey:hover {
    background-color: #5a6268 !important;
}

/* Pulsante Rosso per Logout */
.btn-danger {
    background-color: #d9534f !important; /* Rosso */
}

.btn-danger:hover {
    background-color: #c9302c !important;
}
