* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: #f4f3ee;
  color: #1a1a1a;
  font-size: 16px;
  -webkit-tap-highlight-color: transparent;
}

/* --- Login --- */
.pagina-login { display: flex; align-items: center; justify-content: center; min-height: 100vh; background: #11163a; }
.card-login {
  background: #fff; border-radius: 14px; padding: 28px 24px; width: 320px;
  display: flex; flex-direction: column; gap: 10px;
  color: #1a1a1a;
}
.card-login .logo-login { display: block; max-width: 130px; margin: 0 auto 6px; }
.card-login h1 { font-size: 20px; margin: 0 0 8px; text-align: center; color: #1f24a8; }
.card-login label { font-size: 14px; font-weight: 600; margin-top: 6px; color: #1a1a1a; }
.card-login input { height: 48px; font-size: 17px; padding: 0 12px; border: 2px solid #ccc; border-radius: 8px; color: #1a1a1a; background: #fff; }
.card-login .btn-primar { background: #f3ae13; color: #1a1300; }
.eroare { color: #b3261e; font-size: 14px; margin: 0; }

/* --- Butoane --- */
button, .btn-primar, .btn-secundar, .btn-icon {
  font-size: 16px; border-radius: 10px; border: none; cursor: pointer;
}
.btn-primar { background: #1f6e45; color: #fff; height: 50px; font-weight: 700; }
.btn-secundar {
  background: #fff; border: 2px solid #1f6e45; color: #1f6e45; font-weight: 700; height: 48px;
}
.btn-full { width: 100%; margin-top: 10px; }
.btn-icon {
  width: 48px; height: 48px; background: #fff; border: 2px solid #ccc; font-size: 26px;
  display: flex; align-items: center; justify-content: center; color: #1a1a1a;
}

/* --- Antet --- */
.antet { background: #fff; padding: 12px 14px; border-bottom: 1px solid #ddd; }
.antet-rand { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.antet-data { text-align: center; flex: 1; font-size: 18px; }
.antet-data .text-secundar { display: block; font-size: 13px; color: #666; margin-top: 2px; }
.select-santier-form select {
  font-size: 14px; margin-top: 4px; padding: 6px; border-radius: 6px; border: 1px solid #ccc; max-width: 220px;
}

/* --- Cautare --- */
.cautare-zona { padding: 12px 14px 4px; background: #fff; border-bottom: 1px solid #ddd; }
#cautare { width: 100%; height: 48px; font-size: 16px; padding: 0 14px; border: 2px solid #ccc; border-radius: 10px; }
.rezultate-cautare { margin-top: 6px; }
.rezultat-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 10px; border-bottom: 1px solid #eee; font-size: 15px;
}
.rezultat-item button { background: #1f6e45; color: #fff; height: 38px; padding: 0 14px; font-weight: 700; }
.chips-frecvente { display: flex; gap: 8px; overflow-x: auto; padding: 10px 0 6px; }
.chip {
  flex-shrink: 0; height: 42px; padding: 0 14px; font-weight: 700; font-size: 14px;
  background: #eef3ee; border: 2px solid #cfe0d3; border-radius: 20px; color: #1f6e45;
}
.chip.adaugat { background: #1f6e45; color: #fff; border-color: #1f6e45; }

/* --- Lista utilaje --- */
.lista-utilaje { padding: 10px 14px 90px; display: flex; flex-direction: column; gap: 10px; }
.rand-utilaj {
  background: #fff; border: 1px solid #ddd; border-radius: 12px;
  padding: 10px 12px; display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.rand-utilaj .nume { font-weight: 700; font-size: 15px; }
.rand-utilaj .descriere { font-weight: 400; color: #555; font-size: 13px; display: block; }
.stepper { display: flex; align-items: center; gap: 6px; }
.stepper button {
  width: 42px; height: 42px; background: #f0f0f0; border: 2px solid #ccc; font-size: 22px; font-weight: 700;
}
.stepper .ore { font-size: 18px; font-weight: 700; min-width: 36px; text-align: center; }
.btn-sterge {
  width: 36px; height: 36px; background: none; border: none; color: #999; font-size: 20px;
}
.sync-icon { font-size: 14px; color: #1f6e45; width: 18px; text-align: center; }
.sync-icon.in-asteptare { color: #c08a1e; }

/* --- Subsol / bara de jos --- */
.subsol {
  position: sticky; bottom: 44px; background: #fff; border-top: 1px solid #ddd;
  padding: 10px 14px; display: flex; justify-content: space-between; font-size: 13px; color: #555;
}
.status-sync { color: #1f6e45; font-weight: 700; }
.bara-jos {
  display: flex; justify-content: space-between; padding: 10px 14px; font-size: 13px; background: #f4f3ee;
}
.link-discret { color: #666; text-decoration: underline; }

@media (prefers-color-scheme: dark) {
  body { background: #14181a; color: #f0f0f0; }
  .antet, .cautare-zona, .rand-utilaj, .subsol { background: #1f2628; border-color: #333; }
  #cautare, .btn-icon { background: #1f2628; color: #f0f0f0; border-color: #444; }
  .rand-utilaj .descriere { color: #aaa; }
  .stepper button { background: #2a3234; border-color: #444; color: #f0f0f0; }
  .bara-jos { background: #14181a; }
}

/* --- Conexiune / mesaje --- */
.banner-conexiune {
  position: sticky; top: 0; z-index: 20; background: #b3261e; color: #fff;
  font-weight: 700; font-size: 14px; text-align: center; padding: 10px 14px;
}
.toast {
  position: fixed; left: 14px; right: 14px; bottom: 60px; z-index: 30;
  background: #1a1a1a; color: #fff; font-size: 14px; font-weight: 600;
  padding: 12px 16px; border-radius: 10px; text-align: center;
}
.mesaj-eroare { color: #b3261e; font-weight: 600; padding: 16px 14px; text-align: center; }
.mesaj-info { color: #666; padding: 16px 14px; text-align: center; }
