
/* Impedisce la selezione del testo */
body {
  user-select: none; /* Proprietà CSS moderna */
  -webkit-user-select: none; /* Per compatibilità con browser basati su WebKit */
  -moz-user-select: none; /* Per Firefox */
  -ms-user-select: none; /* Per vecchie versioni di IE */
}

/* Impedisce il trascinamento delle immagini */
img {
  pointer-events: none; /* Disabilita le interazioni con il puntatore */
  -webkit-user-drag: none; /* Proprietà specifica di WebKit per il trascinamento */
}

body {
  font-family: Arial, sans-serif !important;
  background-color: #f4f4f4;
  margin: 0;
  padding: 0;
}

button {
  padding: 10px;
  font-size: 16px;
  background-color: #007BFF;
  border: none;
  color: white;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 10px;
}
button:hover {
  background-color: #0056b3;
}

/*
.error {
  color: red;
  text-align: center;
  margin-bottom: 10px;
}*/

.error {
  border: 1px solid #d9534f;
  background-color: #f2dede;
  color: #a94442;
  margin-bottom: 10px;
}
input, select {
  margin: 0px 0px 10px;
  padding: 10px;
  font-size: 16px;
  border-radius: 4px;
  border: 1px solid #ccc;
  width: 100%; /* per via di manutenzione ordinaria modificato da 100% a 5%, al limite si modifica di nuovo*/
  box-sizing: border-box;
}

/* Header e container */
header {
  background-color: #007BFF;
  color: #ecf0f1;
  padding: 20px;
  margin: auto;
  text-align: center;
  
}
.btn-container {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
}
.btn-container a {
  text-decoration: none;
  padding: 10px 15px;
  color: white;
  background-color: #28a745;
  border-radius: 5px;
}

.btn-container a:hover {
  background-color: #218838;
}

.container {
  width: 90%;
  max-width: 1000px;
  margin: 20px auto;
  background-color: #fff;
  padding: 20px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}
.container h2 {
  text-align: center;
}

.dropdown {
  position: relative;
  display: inline-block;
}
.dropdown-btn {
  background-color: #007BFF;
  color: white;
  padding: 15px 25px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}
.dropdown-content {
  display: none;
  position: absolute;
  background-color: white;
  min-width: 160px;
  box-shadow: 0px 2px 5px rgba(0,0,0,0.2);
  border-radius: 5px;
  z-index: 1000;
}
.dropdown-content a {
  color: black;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
}
.dropdown-content a:hover {
  background-color: #f1f1f1;
}
.dropdown:hover .dropdown-content {
  display: block;
}
.dropdown.active {
  order: -1;
}


.export-buttons {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 20px;
}

.export-buttons button {
  padding: 10px 15px;
  font-size: 16px;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

.export-buttons button[name="export"][value="pdf"] {
  background-color: #d9534f; /* Rosso */
}

.export-buttons button[name="export"][value="csv"] {
  background-color: #5bc0de; /* Azzurro */
}

.export-buttons button[name="export"][value="odt"] {
  background-color: #5cb85c; /* Verde */
}

.export-buttons button[name="send_email"] {
  background-color: #f0ad4e; /* Arancione */
}

.export-buttons button:hover {
  opacity: 0.8;
}

.filter-form {
  display: block;
  flex-wrap: wrap;
  gap: 15px;
}
.filter-form > * {
  flex: 1 1 200px; /* Minimo 200px, ma si espande */
}

/*
form {
  display: block;
  flex-direction: column;
  gap: 10px;
}
*/


form {
  display: flex;
  flex-direction: column;
  gap: 10px; 
}


/*manutenzione ordinaria necessita che sia azzerato, altre pagine non so: label, textarea, input /* Adatta la larghezza degli elementi al contenitore */

label, textarea, input {
  width: 100%;  
  margin-bottom: 5px; 
}

  
#cship {
  display: flex;
  flex-direction: column;
}

label {
  font-weight: bold;
  margin-top: 10px;
  }
     
  .link {
    text-align: center;
    margin-top: 10px;
}
  
  .login-box {
    max-width: 400px;
    margin: 40px auto;
    padding: 20px;
    border: 1px solid #ccc;
    border-radius: 5px;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.login-box h2 {
    text-align: center;
    margin-bottom: 20px;
}
.login-box form {
    display: flex;
    flex-direction: column;
}
.login-box input {
    margin-bottom: 15px;
    padding: 10px;
    font-size: 16px;
}
.login-box button {
    padding: 10px;
    font-size: 16px;
    background-color: #007BFF;
    border: none;
    color: #fff;
    border-radius: 3px;
    cursor: pointer;
}
.login-box button:hover {
    background-color: #0056b3;
}
/* Logout link e footer */
.logout-container {
  margin-top: 20px;
  text-align: center;
}
.logout-link {
  font-size: 18px;
  color: #e74c3c;
  text-decoration: none;
}
.logout-link:hover {
  text-decoration: underline;
}
        
nav {
  text-align: center;
  margin-top: 20px;
}
nav a {
  margin: 0 10px;
  text-decoration: none;
  color: #007BFF;
  font-weight: bold;
}
nav a:hover {
  text-decoration: underline;
}

/* Stili base per il form registrazione */
.register-box {
  max-width: 400px;
  margin: 40px auto;
  padding: 20px;
  border: 1px solid #ccc;
  border-radius: 5px;
  background: #fff;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.register-box h2 {
  text-align: center;
  margin-bottom: 20px;
}
.register-box form {
  display: flex;
  flex-direction: column;
}
.register-box input {
  margin-bottom: 15px;
  padding: 10px;
  font-size: 16px;
}
.register-box button {
  padding: 10px;
  font-size: 16px;
  background-color: #007BFF;
  border: none;
  color: #fff;
  border-radius: 3px;
  cursor: pointer;
}
.register-box button:hover {
  background-color: #0056b3;
}

/* Tabbed menu */


.tabs {
  display: flex;
  justify-content: center; /* Centra i tab nel container */
  flex-wrap: nowrap;       /* Forza una sola riga */
  gap: 10px;               /* Spazio uniforme tra i tab */
  margin-top: 20px;
}

.tab {
  flex: 1 1 0;             /* Distribuisce equamente lo spazio disponibile */
  text-align: center;
  padding: 15px 25px;
  white-space: nowrap;     /* Impedisce al testo di andare a capo */
  box-sizing: border-box;
  font-size: 16px;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.tab:hover {
  background-color: #0056b3;
  transform: scale(1.1);
}

.tab.active {
  font-size: 20px;         /* Tab attivo più grande */
  background-color: #2c3e50;
}

/* Se vuoi imporre una larghezza fissa a tutti i tab (ad es. 150px), puoi usare:
.tab {
  flex: 0 0 150px;
  text-align: center;
  padding: 15px 25px;
  white-space: nowrap;
  box-sizing: border-box;
}
*/

textarea {
  max-height: 130px;
  max-width: 500px;
}

/* Badge per notifiche */
.notifications {
  position: relative;
  display: inline-block;
  padding: 15px 52px;
  background-color: #007BFF;
  color: white;
  border-radius: 5px;
  text-decoration: none;
}
.notifications:hover {
  background-color: #0056b3;
}
.badge {
  background-color: red;
  color: white;
  font-size: 14px;
  font-weight: bold;
  padding: 5px 10px;
  border-radius: 50%;
  position: absolute;
  top: 5px;
  right: 5px;
}

footer {
  background-color: #2c3e50;
  color: #ecf0f1;
  text-align: center;
  padding: 10px;
  margin-top: 20px;
}

/* Blocco estratto sidebar-dashboard.php */
/* Layout Principale con Flexbox (Desktop) */
    .marina-manager-layout {
        display: flex;
    }
    .main-content-wrapper {
        flex-grow: 1;
        width: calc(100% - 260px); /* Previene problemi di overflow */
    }

    /* Stili della Sidebar */
    .sidebar { width: 260px; background-color: #1a2c4f; color: #fff; display: flex; flex-direction: column; flex-shrink: 0; height: 100vh; position: sticky; top: 0; }
    .sidebar-header { padding: 20px; text-align: center; border-bottom: 1px solid #2a3f6d; }
    .sidebar-header h1 { margin: 0; font-size: 1.5em; display: flex; align-items: center; justify-content: center; gap: 10px; }
    .sidebar-header h1 .icon { font-size: 1.8rem; }
    .sidebar-nav { flex-grow: 1; list-style: none; padding: 20px 0; margin: 0; overflow-y: auto; }
    .sidebar-nav a { display: flex; align-items: center; gap: 15px; padding: 15px 25px; color: #a9b4d0; text-decoration: none; font-size: 1em; transition: background-color 0.2s, color 0.2s; }
    .sidebar-nav a:hover, .sidebar-nav a.active { background-color: #2a3f6d; color: #fff; border-left: 3px solid #3c82f6; padding-left: 22px; }
    .sidebar-nav .nav-icon { font-size: 1.2em; width: 20px; text-align: center; }
    .sidebar-nav .nav-title { font-weight: 500; }
    .sidebar-footer { padding: 20px; border-top: 1px solid #2a3f6d; margin-top: auto; }
    .sidebar-footer a { display: flex; align-items: center; gap: 15px; padding: 10px; color: #a9b4d0; text-decoration: none; border-radius: 6px; }
    
    /* Stili del menu mobile */
    .mobile-menu-toggle { display: none; }
    @media (max-width: 768px) {
        .marina-manager-layout { display: block; } /* Su mobile, gli elementi tornano in blocco */
        .sidebar { position: fixed; left: -260px; top: 0; z-index: 1000; transition: left 0.3s ease-in-out; box-shadow: 4px 0px 15px rgba(0,0,0,0.2); }
        .sidebar.is-open { left: 0; }
        .mobile-menu-toggle { display: block; position: fixed; top: 15px; left: 15px; z-index: 1001; background: #1a2c4f; color: white; border: 1px solid #3c82f6; border-radius: 5px; width: 40px; height: 40px; font-size: 24px; cursor: pointer; }
        .mobile-menu-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); z-index: 999; }
        .mobile-menu-overlay.is-open { display: block; }
        .main-content-wrapper { width: 100%; padding-top: 60px; } /* Aggiunge spazio per il bottone hamburger */
    }



