/* Manșe: segmented control (taburi) + switch de deblocare.
   Foloseste tokenele de culoare din app.css (--brand/--accent/--gold/--surface...).
   Fisier scris de mana (NU generat de Tailwind), deci nu se pierde la rebuild. */

/* ---------- Bara de taburi (segmented control) ---------- */
.mansa-nav {
  display: flex;
  justify-content: center;
  margin: 0 0 1.25rem;
}

.mansa-tabs {
  display: inline-flex;
  gap: 0.25rem;
  padding: 0.3rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: var(--shadow);
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.mansa-tabs::-webkit-scrollbar { display: none; }

.mansa-tab {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.05rem;
  white-space: nowrap;
  min-height: 2.9rem;
  padding: 0.3rem 1.1rem;
  border-radius: 999px;
  border: 1px solid transparent;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.9rem;
  line-height: 1.15;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.mansa-tab:hover {
  color: var(--ink);
  background: var(--surface);
}

/* Manșă care nu e în ziua curentă: o vezi, dar n-o poți deschide (doar adminul). */
.mansa-tab.is-locked {
  opacity: 0.55;
  cursor: not-allowed;
}
.mansa-tab.is-locked:hover {
  color: var(--muted);
  background: transparent;
}

.mansa-tab__label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.mansa-tab__date {
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

.mansa-tab.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong));
  box-shadow: 0 6px 16px var(--brand-soft);
}
.mansa-tab.is-active .mansa-tab__date { color: rgba(255, 255, 255, 0.85); }

/* Punctul „azi" — manșa zilei curente (unde se pot adăuga bucăți). */
.mansa-tab__today {
  position: relative;
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  flex: 0 0 auto;
}
.mansa-tab__today,
.mansa-tab__today::after {
  background: var(--accent);
  border-radius: 999px;
}
.mansa-tab.is-active .mansa-tab__today,
.mansa-tab.is-active .mansa-tab__today::after { background: #fff; }
.mansa-tab__today::after {
  content: "";
  position: absolute;
  inset: 0;
  animation: mansa-ping 1.8s cubic-bezier(0, 0, 0.2, 1) infinite;
}
@keyframes mansa-ping {
  0% { opacity: 0.6; transform: scale(1); }
  75%, 100% { opacity: 0; transform: scale(2.6); }
}

/* ---------- Switch de deblocare (admin) ---------- */
.unlock {
  display: inline-flex;
  align-items: center;
}
.unlock__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.3rem 0.7rem 0.3rem 0.55rem;
  min-height: 2.25rem;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  transition: color 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
}
.unlock__track {
  position: relative;
  width: 2.35rem;
  height: 1.3rem;
  border-radius: 999px;
  background: var(--border);
  transition: background-color 0.18s ease;
  flex: 0 0 auto;
}
.unlock__knob {
  position: absolute;
  top: 0.15rem;
  left: 0.15rem;
  width: 1rem;
  height: 1rem;
  border-radius: 999px;
  background: var(--surface);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.28);
  transition: transform 0.18s ease;
}
.unlock__btn.is-on {
  color: var(--gold);
  background: var(--gold-soft);
  border-color: transparent;
}
.unlock__btn.is-on .unlock__track { background: var(--gold); }
.unlock__btn.is-on .unlock__knob { transform: translateX(1.05rem); }

/* ---------- Fâșii de stare (banner) ---------- */
.state-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.7rem;
  padding: 0.5rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}
.state-strip--unlocked {
  background: var(--gold-soft);
  color: var(--gold);
}
.state-strip--locked {
  background: var(--surface-2);
  color: var(--muted);
  border: 1px solid var(--border);
}

/* ---------- Pagina de eroare (centrat; fără stiluri inline blocate de CSP) ---------- */
.error-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.error-card {
  max-width: 30rem;
  width: 100%;
  text-align: center;
}
.error-card .title { margin-top: 0.5rem; }
.error-card .subtitle { margin-top: 0.4rem; }
.error-code {
  font-size: 4rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--brand);
}
.error-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

/* ---------- Antet sector (tablou cu toate sectoarele) ---------- */
.sector-head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 0.85rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}
.sector-head__name {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
  transition: color 0.15s ease;
}
.sector-head__name:hover { color: var(--brand); }
.sector-head__count {
  margin-left: auto;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.15rem 0.65rem;
  white-space: nowrap;
}
