/* Intestazioni fisse per le tabelle */
.table thead th {
  position: sticky;
  top: 0;
  background-color: #fff;
  z-index: 2;
  border-bottom: 2px solid #dee2e6;
  color: black;
}

/* Nessuno scroll interno */
.arrivals,
.done {
  max-height: none;
  overflow-y: visible;
}

.table {
  margin-bottom: 0;
  border-radius: 8px;
  overflow: hidden;
}

#arrivals-box {
  background-color: rgba(92, 136, 218, 0.1); /* Azzurrino tenue */
  border-radius: 12px;
  padding: 20px;
}

#done-box {
  background-color: rgba(84, 84, 84, 0.4);
  color: #ffffff;
  border-radius: 12px;
  padding: 20px;
}

#done-box .table th,
#done-box .table td {
  color: black;
}

/* Pulsanti azione uniformati */
.btn-action {
  padding: 4px 10px;
  font-size: 0.85rem;
  border-radius: 6px;
  line-height: 1.25;
  min-width: 90px;
  margin-right: 4px;
  margin-left: 0;
  text-align: center;
  white-space: nowrap;
}

/* Pulsante Aggiungi elegante */
#addEntry button[type="submit"] {
  background-color: #5c88da;
  color: white;
  font-weight: 600;
  border: none;
  border-radius: 10px;
  padding: 8px 20px;
  margin-top: 6px;
}

/* Riga urgente evidenziata */
.urgent-row td {
  background-color: #fff3cd !important;
  color: #0a0a0a !important;
  font-weight: bold;
}

/* Badge note */
.badge.bg-info {
  background-color: #17a2b8;
  color: #fff;
  margin-left: 5px;
}

/* Messaggio di conferma */
button.yes {
  margin-right: 10px;
}

/* Sezione Aggiungi arrivo evidenziata */
#addEntry {
  background-color: rgba(92, 136, 218, 0.2); /* Azzurro leggermente più scuro */
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.05);
}

.restore.btn-action {
  margin-left: 16px; /* o 16px per più spazio */
  background-color: #5c88da;
  color: white;
  font-weight: 600;
  border: none;
}

/* Spaziatura tra le colonne senza rompere il layout */
#arrivals-box {
  padding-right: 8px; /* Spazio interno a destra */
}

#done-box {
  padding-left: 8px; /* Spazio interno a sinistra */
}

.urgent-badge {
  background-color: #ffff00; /* giallo chiaro */
  color: black;
  font-weight: bold;
  padding: 4px 8px;
  border-radius: 6px;
  text-transform: uppercase;
  font-size: 0.75rem;
}

/* Meteo widget (header) */
.meteo-widget {
  display: inline-block;
  margin-top: 6px;
  padding: 8px 10px;
  border: 1px solid #e6e6e6;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
  min-width: 220px;
}

.meteo-top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.meteo-icon {
  font-size: 26px;
  width: 34px;
  text-align: center;
}

.meteo-desc {
  font-weight: 700;
  line-height: 1.1;
}

.meteo-sub {
  font-size: 0.85em;
  opacity: 0.9;
  margin-top: 2px;
}

.meteo-temp {
  font-weight: 800;
}

.meteo-deg {
  margin-left: 2px;
}

.meteo-dot {
  margin: 0 6px;
  opacity: 0.6;
}

/* Top navigation */
.top-nav {
  margin-top: 12px;
  display: flex;
  gap: 16px;
}

.nav-link {
  text-decoration: none;
  font-weight: 600;
  color: #555;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
}

.nav-link:hover {
  color: #000;
}

.nav-link.active {
  color: #000;
  border-bottom: 2px solid #000;
}

/* Placeholder box */
.placeholder-box {
  margin-top: 24px;
  padding: 24px;
  border: 2px dashed #ccc;
  border-radius: 12px;
  background: #fafafa;
}
/* Orders page (namespaced) */
.orders-page .orders-card {
  background: #fff;
  border: 1px solid #e6e6e6;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.05);
}

.orders-page .orders-card-title {
  font-weight: 800;
  margin-bottom: 12px;
}

.orders-page .orders-filters {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr;
  gap: 12px;
}

.orders-page .orders-field label {
  display: block;
  font-size: 0.85em;
  opacity: 0.8;
  margin-bottom: 6px;
}

.orders-page .orders-field select,
.orders-page .orders-field input[type="date"] {
  width: 100%;
  padding: 10px 10px;
  border: 1px solid #ddd;
  border-radius: 10px;
}

.orders-page .orders-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 0;
}

.orders-page .orders-btn-row {
  display: flex;
  gap: 10px;
}

.orders-page .orders-btn {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #111;
  background: #111;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.orders-page .orders-btn:hover {
  opacity: 0.92;
}

.orders-page .orders-btn-light {
  background: #fff;
  color: #111;
}

.orders-page .orders-btn-light:hover {
  background: #f3f3f3;
}

.orders-page .orders-table,
.orders-page .lines-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.orders-page .orders-table th,
.orders-page .orders-table td,
.orders-page .lines-table th,
.orders-page .lines-table td {
  border-bottom: 1px solid #eee;
  padding: 10px 8px;
  text-align: left;
  vertical-align: top;
}

.orders-page .order-detail-row td {
  background: #fbfbfb;
}

.orders-page .detail-box {
  padding: 12px;
  border-radius: 10px;
}

.orders-page .detail-title {
  font-weight: 800;
  margin-bottom: 10px;
}

.orders-page .empty-state {
  margin-top: 12px;
  padding: 14px;
  border-radius: 10px;
  background: #fafafa;
  border: 1px dashed #ccc;
  color: #555;
}

/* Badges only for Orders page */
.orders-page .orders-badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 0.75em;
  font-weight: 800;
  vertical-align: middle;
  margin-left: 6px;
}

.orders-page .orders-badge-gray {
  background: #ececec;
  color: #333;
}
.orders-page .orders-badge-blue {
  background: #e6f0ff;
  color: #1246a0;
  border: 1px solid #cfe0ff;
}
.orders-page .orders-badge-amber {
  background: #fff2d8;
  color: #7a4b00;
  border: 1px solid #ffe2ad;
}
.orders-page .orders-badge-red {
  background: #ffe5e5;
  color: #9d0b0b;
  border: 1px solid #ffcdcd;
}

.orders-page .orders-hint-box {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 12px;
  padding: 12px;
  min-width: 260px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.05);
}

.orders-page .orders-hint-title {
  font-weight: 900;
  margin-bottom: 8px;
}
.orders-page .orders-hint-row {
  font-size: 0.85em;
  margin-top: 6px;
  color: #333;
}

/* Navigation cards */
.nav-cards {
  display: flex;
  gap: 12px;
  padding: 12px 16px 4px 16px;
}

.nav-card {
  flex: 0 0 auto;
  width: 220px;
  border-radius: 14px;
  border: 1px solid rgba(92, 136, 218, 0.22);
  background: rgba(92, 136, 218, 0.1);
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
  padding: 12px 14px;
  cursor: pointer;
  transition:
    transform 140ms ease,
    box-shadow 140ms ease,
    background 140ms ease;
  text-decoration: none;
  color: #0a0a0a;
  display: flex;
  gap: 10px;
  align-items: center;
}

.nav-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.1);
  background: rgba(92, 136, 218, 0.14);
  text-decoration: none;
  color: #0a0a0a;
}

.nav-card.active {
  border-color: rgba(92, 136, 218, 0.55);
  background: rgba(92, 136, 218, 0.18);
}

.nav-ic {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.nav-txt .t {
  font-weight: 800;
  line-height: 1.1;
}

.nav-txt .s {
  font-size: 0.85em;
  opacity: 0.75;
  margin-top: 2px;
}
