/* ═══════════════════════════════════════
   MOSCÚ ADMIN — style.css
═══════════════════════════════════════ */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --negro: #0D0D0D;
  --carbon: #1A1A1A;
  --acero: #2A2A2A;
  --gris: #444;
  --gris-lt: #888;
  --dorado: #C9A84C;
  --dorado-lt: #E8C96A;
  --crema: #F5F0E8;
  --rojo: #B33636;

  --font-display: 'Oswald', 'Arial Narrow', sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --radius: 10px;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--negro);
  color: var(--crema);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
}

input,
select,
textarea {
  font-family: inherit;
}

/* ─── ANIMACIONES ─── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulseDot {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.18); }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ─── LOGIN ─── */
.login-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.login-card {
  width: 100%;
  max-width: 380px;
  text-align: center;
  animation: fadeInUp .4s ease both;
}

.login-logo {
  width: 120px;
  margin: 0 auto 24px;
}

.login-title {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .03em;
  margin-bottom: 4px;
}

.login-sub {
  font-size: 11px;
  letter-spacing: 4px;
  color: var(--dorado);
  margin-bottom: 40px;
}

.login-input {
  width: 100%;
  background: var(--carbon);
  border: 1px solid var(--acero);
  border-radius: var(--radius);
  padding: 14px 16px;
  color: var(--crema);
  font-size: 14px;
  margin-bottom: 14px;
  transition: border-color .2s ease;
}

.login-input:focus {
  outline: none;
  border-color: var(--dorado);
}

.login-error {
  color: var(--rojo);
  font-size: 13px;
  margin-bottom: 14px;
  min-height: 18px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  border: 2px solid transparent;
  transition: background .2s ease, color .2s ease, border-color .2s ease, transform .15s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn--gold {
  background: var(--dorado);
  color: var(--negro);
  border-color: var(--dorado);
}

.btn--full {
  width: 100%;
}

.btn--gold:hover {
  background: var(--dorado-lt);
}

.btn--gold:disabled {
  opacity: .5;
  cursor: not-allowed;
  transform: none;
}

.btn--outline {
  background: transparent;
  color: var(--crema);
  border-color: var(--acero);
}

.btn--outline:hover {
  border-color: var(--dorado);
  color: var(--dorado);
}

.btn--rojo {
  background: transparent;
  color: var(--rojo);
  border-color: var(--rojo);
}

.btn--rojo:hover {
  background: var(--rojo);
  color: white;
}

.btn--sm {
  padding: 8px 14px;
  font-size: 12px;
}

/* ─── LAYOUT PRINCIPAL ─── */
.app-shell {
  display: flex;
  min-height: 100vh;
}

.desktop-topbar { display: none; }

.sidebar {
  width: 220px;
  background: var(--carbon);
  border-right: 1px solid var(--acero);
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  height: 100vh;
  position: relative;
  overflow-y: auto;
}

@media (min-width: 861px) {
  .sidebar {
    position: sticky;
    top: 0;
  }
}

.sidebar-logo {
  width: 56px;
  margin: 0 auto 18px;
  display: block;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius);
  color: var(--gris-lt);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 2px;
  transition: all .15s;
}

.nav-item:hover {
  background: rgba(255,255,255,.04);
  color: var(--crema);
}

.nav-item.active {
  background: rgba(201,168,76,.12);
  color: var(--dorado);
}

.nav-item svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.sidebar-user {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--acero);
  display: flex;
  align-items: center;
  gap: 10px;
}
.sidebar-user .avatar {
  flex-shrink: 0;
}
#nombreDesktop {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--crema);
}
#puestoDesktop {
  font-size: 11px;
  color: var(--dorado);
}

.main-content {
  flex: 1;
  min-width: 0;
  padding: 28px 32px;
  overflow-y: auto;
  max-height: 100vh;
  animation: fadeInUp .35s ease both;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 28px;
  flex-wrap: wrap;
  gap: 16px;
}

.page-title {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .03em;
}

.avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #3D3580;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}

.card {
  background: var(--carbon);
  border: 1px solid var(--acero);
  border-radius: 14px;
  padding: 20px;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.card:hover {
  transform: translateY(-2px);
  border-color: rgba(201,168,76,.35);
  box-shadow: 0 10px 26px rgba(0,0,0,.35);
}

/* Campana de notificaciones: pulso suave cuando hay algo nuevo */
[class^="notif-badge-"] {
  animation: pulseDot 1.6s ease-in-out infinite;
}

/* ─── MOBILE ─── */
.mobile-topbar { display: none; }
.bottom-nav { display: none; }

@media (max-width: 860px) {
  .sidebar { display: none !important; }

  .app-shell { flex-direction: column; }

  .mobile-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--carbon);
    border-bottom: 1px solid var(--acero);
    position: sticky;
    top: 0;
    z-index: 100;
  }

  .main-content {
    padding: 16px 12px 24px;
    max-height: none;
  }

  #notifContainerDesktop { display: none !important; }
}

/* Ocultar Catálogo y Equipo por defecto */
#navCatalogo, #navEquipo { display: none; }

/* Calendario */
.hoy-col-barbero { min-width: 200px; flex: 1; }

.cita-bloque {
  position: absolute;
  left: 4px;
  right: 4px;
  overflow: hidden;
  transition: filter .15s ease;
}

.cita-bloque:hover {
  filter: brightness(1.12);
}

@media (max-width: 860px) {
  .hoy-col-barbero { width: calc(100vw - 70px); }
  .hoy-col-horas { width: 52px; }
}