/**
 * E.R.A. FSG — capa visual compartida (web).
 * Colores, profundidad y movimiento. No cambia la geometría de AdminLTE.
 */
:root {
  --era-ink: #0b1220;
  --era-ink-2: #132033;
  --era-cyan: #22d3ee;
  --era-teal: #0e7490;
  --era-blue: #2563eb;
  --era-surface: #f4f7fb;
  --era-card: #ffffff;
  --era-line: rgba(15, 23, 42, 0.08);
  --era-text: #0f172a;
  --era-muted: #64748b;
}

body.hold-transition,
body.login-page,
body.register-page {
  font-family: "Segoe UI", "Source Sans Pro", system-ui, sans-serif;
  color: var(--era-text);
}

::selection {
  background: rgba(34, 211, 238, 0.35);
  color: var(--era-ink);
}

/* Fondo de trabajo con luz suave */
.skin-blue .content-wrapper,
.skin-blue .right-side,
.skin-black .content-wrapper {
  background:
    radial-gradient(1100px 420px at 0% -10%, rgba(34, 211, 238, 0.14), transparent 55%),
    radial-gradient(900px 380px at 100% 0%, rgba(37, 99, 235, 0.1), transparent 50%),
    var(--era-surface) !important;
}

.skin-blue .content-header {
  padding-top: 18px;
}

.content-header > h1 {
  font-weight: 650;
  letter-spacing: -0.03em;
  color: var(--era-ink);
}

.content-header > h1 > small {
  color: var(--era-muted);
  font-weight: 500;
  letter-spacing: 0;
}

.breadcrumb {
  background: transparent;
  color: var(--era-muted);
}

/* Encabezado */
.skin-blue .main-header {
  background: linear-gradient(100deg, #0b1220 0%, #123047 52%, #0e7490 130%);
  box-shadow: 0 10px 28px rgba(8, 15, 30, 0.16);
}

.skin-blue .main-header .logo,
.skin-blue .main-header .navbar {
  background: transparent !important;
}

.skin-blue .main-header .logo {
  font-weight: 700;
  letter-spacing: 0.04em;
  border-right: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.skin-blue .main-header .logo:hover {
  background: rgba(255, 255, 255, 0.05) !important;
}

.skin-blue .main-header .navbar .sidebar-toggle:hover {
  background: rgba(255, 255, 255, 0.08);
}

.skin-blue .main-header .navbar .nav > li > a:hover,
.skin-blue .main-header .navbar .nav > li > a:focus,
.skin-blue .main-header .navbar .nav .open > a {
  background: rgba(255, 255, 255, 0.08);
}

.notifications-menu .label {
  animation: eraPulso 2.2s ease-in-out infinite;
  border-radius: 999px;
  box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.55);
}

@keyframes eraPulso {
  0% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.45); }
  70% { box-shadow: 0 0 0 7px rgba(251, 191, 36, 0); }
  100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); }
}

/* Menú lateral */
.skin-blue .main-sidebar,
.skin-blue .left-side {
  background: linear-gradient(180deg, #0b1220 0%, #10192c 58%, #0c1830 100%) !important;
}

.skin-blue .user-panel {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.skin-blue .user-panel > .info,
.skin-blue .user-panel > .info > a {
  color: #e2e8f0;
}

.skin-blue .sidebar-menu > li.header {
  color: #67e8f9;
  background: transparent;
  letter-spacing: 0.14em;
  font-size: 11px;
  text-transform: uppercase;
}

.skin-blue .sidebar-menu > li > a {
  color: #d7e3f4;
  border-left: 3px solid transparent;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.skin-blue .sidebar-menu > li:hover > a,
.skin-blue .sidebar-menu > li.active > a,
.skin-blue .sidebar-menu > li.menu-open > a {
  color: #fff;
  background: rgba(34, 211, 238, 0.1);
  border-left-color: var(--era-cyan);
}

.skin-blue .sidebar-menu > li > .treeview-menu {
  background: rgba(0, 0, 0, 0.22);
}

.skin-blue .treeview-menu > li > a {
  color: #b6c6db;
}

.skin-blue .treeview-menu > li.active > a,
.skin-blue .treeview-menu > li > a:hover {
  color: #fff;
  background: rgba(34, 211, 238, 0.08);
}

.skin-blue .sidebar a {
  color: #d7e3f4;
}

/* Tarjetas y cajas */
.box,
.info-box,
.small-box,
.modal-content,
.dropdown-menu,
.nav-tabs-custom,
.box-comments,
.direct-chat-messages {
  border-radius: 16px;
}

.box {
  border: 1px solid var(--era-line);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
  background: var(--era-card);
}

.box-header.with-border {
  border-bottom-color: rgba(15, 23, 42, 0.06);
}

.box-header .box-title {
  font-weight: 650;
  letter-spacing: -0.02em;
}

.small-box,
.info-box {
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.small-box:hover,
.info-box:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.12);
}

.small-box h3,
.info-box-number {
  font-weight: 700;
  letter-spacing: -0.03em;
}

/* Botones */
.btn {
  border-radius: 10px;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, filter 0.15s ease;
}

.btn:active,
.btn.era-press {
  transform: translateY(1px) scale(0.985);
}

.btn-primary {
  background: linear-gradient(180deg, #0891b2 0%, #0e7490 100%);
  border-color: #0e7490;
  box-shadow: 0 6px 16px rgba(14, 116, 144, 0.28);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
.btn-primary.active,
.open > .dropdown-toggle.btn-primary {
  background: linear-gradient(180deg, #06b6d4 0%, #0891b2 100%);
  border-color: #0891b2;
}

.btn-success {
  box-shadow: 0 6px 16px rgba(22, 163, 74, 0.22);
}

.btn-default {
  background: #fff;
  border-color: rgba(15, 23, 42, 0.1);
}

.btn-default:hover {
  background: #f8fafc;
}

/* Formularios */
.form-control {
  border-radius: 10px;
  border-color: rgba(15, 23, 42, 0.12);
  box-shadow: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-control:focus {
  border-color: #22d3ee;
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.22);
}

.select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--multiple {
  border-radius: 10px;
  border-color: rgba(15, 23, 42, 0.12);
}

/* Tablas */
.table > thead > tr > th {
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-bottom: 1px solid #e2e8f0;
}

.table-hover > tbody > tr:hover,
.table > tbody > tr:hover {
  background: rgba(14, 116, 144, 0.05);
}

/* Pestañas, etiquetas, modales */
.nav-tabs > li > a {
  border-radius: 10px 10px 0 0;
}

.nav-tabs > li.active > a,
.nav-tabs > li.active > a:hover,
.nav-tabs > li.active > a:focus {
  color: var(--era-teal);
  font-weight: 650;
}

.label,
.badge {
  border-radius: 999px;
  font-weight: 650;
}

.modal-content {
  border: 0;
  box-shadow: 0 28px 70px rgba(8, 15, 30, 0.32);
  overflow: hidden;
}

.dropdown-menu {
  border: 1px solid var(--era-line);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
  padding: 6px;
}

.dropdown-menu > li > a {
  border-radius: 8px;
}

.dropdown-menu > li > a:hover {
  background: rgba(14, 116, 144, 0.08);
}

.pagination > li > a,
.pagination > li > span {
  border-radius: 8px;
  margin: 0 2px;
}

.alert {
  border-radius: 12px;
  border: 0;
}

.callout {
  border-radius: 12px;
}

.main-footer {
  background: transparent;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
  color: var(--era-muted);
}

/* Inicio */
.ini-hero {
  border-radius: 20px;
  box-shadow: 0 18px 40px rgba(14, 116, 144, 0.22);
}

.ini-hero::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto auto;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.28), transparent 68%);
  animation: eraOrbe 9s ease-in-out infinite;
  pointer-events: none;
}

.ini-card,
.ini-acceso {
  border: 1px solid rgba(15, 23, 42, 0.05);
}

.ini-card:hover,
.ini-acceso:hover {
  box-shadow: 0 16px 34px rgba(14, 116, 144, 0.14);
}

.ini-acceso .fa {
  color: var(--era-teal);
}

/* Login: brillo sobre el panel ya existente */
body.login-page .login-box,
body.register-page .register-box {
  animation: eraEntrar 0.55s ease both;
}

body.login-page .login-box-body,
body.register-page .register-box-body {
  box-shadow:
    0 18px 50px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(34, 211, 238, 0.18) inset;
}

body.login-page .btn-primary,
body.register-page .btn-primary {
  background: linear-gradient(180deg, #06b6d4 0%, #0e7490 100%);
  box-shadow: 0 8px 20px rgba(8, 145, 178, 0.4);
}

/* Entrada de bloques */
.era-rise {
  animation: eraEntrar 0.45s ease both;
}

@keyframes eraEntrar {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

@keyframes eraOrbe {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(-24px, 16px, 0); }
}

@media (max-width: 991px) {
  .skin-blue .main-header {
    background: linear-gradient(100deg, #0b1220 0%, #0e7490 140%) !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .notifications-menu .label,
  .ini-hero::before,
  .era-rise,
  body.login-page .login-box,
  body.register-page .register-box,
  .small-box,
  .info-box,
  .btn {
    animation: none !important;
    transition: none !important;
  }
}

@media print {
  .skin-blue .content-wrapper,
  .skin-blue .right-side {
    background: #fff !important;
  }
  .box,
  .small-box,
  .info-box {
    box-shadow: none;
  }
}
