/* ===================================================
   THEME ADMINLTE PROFESSIONAL - Centro Educativo
   Autor: Milton Abrián Nolberto
   Inspirado en AdminLTE + Bootstrap
   Versión: 2.0 - Profesional
   =================================================== */

/* ========== 1) VARIABLES CSS MEJORADAS ========== */
:root {
  /* Paleta de colores profesional */
  --primary-color: #3c8dbc;
  --primary-dark: #2a6fa5;
  --primary-light: #72b3d6;
  --secondary-color: #6c757d;
  --accent-color: #00a65a;
  --accent-dark: #008d4c;
  --danger-color: #dd4b39;
  --danger-dark: #c23321;
  --warning-color: #f39c12;
  --warning-dark: #e08e0b;
  --info-color: #00c0ef;
  --info-dark: #00a7d0;
  
  /* Sidebar mejorado */
  --sidebar-bg: #222d32;
  --sidebar-hover: #1e282c;
  --sidebar-text: #b8c7ce;
  --sidebar-active: var(--primary-color);
  --sidebar-width: 250px;
  --sidebar-collapsed-width: 70px;
  
  /* Header */
  --header-height: 60px;
  --header-bg: #3c8dbc;
  --header-text: #ffffff;
  
  /* Fondos y bordes mejorados */
  --body-bg: #f4f6f9;
  --card-bg: #ffffff;
  --card-header-bg: #f8f9fa;
  --border-color: #dee2e6;
  --text-color: #343a40;
  --text-muted: #6c757d;
  
  /* Sombras más sutiles */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.1), 0 1px 3px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  
  /* Tipografía */
  --font-family-primary: 'Segoe UI', 'Source Sans Pro', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-family-heading: 'Segoe UI', 'Source Sans Pro', Roboto, 'Helvetica Neue', Arial, sans-serif;
  
  /* Bordes redondeados */
  --border-radius: 0.375rem;
  --border-radius-lg: 0.5rem;
  --border-radius-xl: 1rem;
  
  /* Transiciones */
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-fast: all 0.15s ease;
}

/* ========== 2) RESET Y BASE MEJORADOS ========== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  overflow-x: hidden;
}

body {
  font-family: var(--font-family-primary);
  background-color: var(--body-bg);
  color: var(--text-color);
  line-height: 1.6;
  font-weight: 400;
  font-size: 0.95rem;
}

a {
  text-decoration: none;
  color: var(--primary-color);
  transition: var(--transition-fast);
}

a:hover {
  color: var(--primary-dark);
}

/* ========== 3) LAYOUT PRINCIPAL ========== */
.app-wrapper {
  display: flex;
  min-height: 100vh;
}

/* ========== 4) HEADER PROFESIONAL ========== */
.header {
  position: fixed;
  top: 0;
  left: var(--sidebar-width);
  right: 0;
  height: var(--header-height);
  background: var(--header-bg);
  color: var(--header-text);
  z-index: 1020;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  align-items: center;
  padding: 0 1.5rem;
}

.header .logo-mini {
  display: none;
  font-weight: 700;
  font-size: 1.5rem;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.header .navbar-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header .nav-link {
  color: var(--header-text);
  padding: 0.5rem 0.75rem;
  border-radius: var(--border-radius);
  transition: var(--transition-fast);
}

.header .nav-link:hover {
  background: rgba(255, 255, 255, 0.1);
}

.header .nav-link i {
  margin-right: 0.5rem;
}

/* ========== 5) SIDEBAR PROFESIONAL ========== */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 1030;
  transition: var(--transition);
  box-shadow: var(--shadow-md);
}

/* Scrollbar personalizado para el sidebar */
.sidebar::-webkit-scrollbar {
  width: 6px;
}

.sidebar::-webkit-scrollbar-track {
  background: rgba(0,0,0,0.1);
}

.sidebar::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.2);
  border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
  background: rgba(255,255,255,0.3);
}

/* Brand / Logo mejorado */
.sidebar .brand {
  padding: 1.2rem 1rem;
  font-size: 1.3rem;
  font-weight: 700;
  text-align: center;
  background: rgba(0,0,0,0.15);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  color: #ffffff;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  height: var(--header-height);
}

.sidebar .brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1.2rem;
}

/* Info de usuario mejorado */
.user-panel {
  display: flex;
  align-items: center;
  padding: 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 0.5rem;
}

.user-panel .image {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 0.75rem;
  background: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
}

.user-panel .info {
  flex: 1;
}

.user-panel .info p {
  margin: 0;
  color: white;
  font-weight: 600;
  font-size: 0.95rem;
}

.user-panel .info a {
  color: var(--sidebar-text);
  font-size: 0.85rem;
  display: block;
  margin-top: 0.25rem;
}

.user-panel .info a:hover {
  color: white;
}

/* Títulos de menú */
.menu-heading {
  padding: 1rem 1rem 0.5rem;
  color: #95a5a6;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 0.5rem;
}

/* Links del menú mejorados */
.sidebar-menu {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-menu > li {
  position: relative;
  margin: 0;
}

.sidebar-menu > li > a {
  display: flex;
  align-items: center;
  padding: 0.75rem 1rem;
  color: var(--sidebar-text);
  transition: var(--transition);
  border-left: 3px solid transparent;
  position: relative;
}

.sidebar-menu > li > a > .fa,
.sidebar-menu > li > a > .fas,
.sidebar-menu > li > a > .far,
.sidebar-menu > li > a > .fab,
.sidebar-menu > li > a > .icon {
  width: 24px;
  text-align: center;
  font-size: 1.1rem;
  margin-right: 0.75rem;
  color: #95a5a6;
  transition: var(--transition);
}

.sidebar-menu > li > a > .pull-right-container {
  margin-left: auto;
}

.sidebar-menu > li > a:hover {
  background: var(--sidebar-hover);
  color: #ffffff;
  border-left-color: var(--primary-color);
  padding-left: 1.2rem;
}

.sidebar-menu > li > a:hover > .fa,
.sidebar-menu > li > a:hover > .fas,
.sidebar-menu > li > a:hover > .far,
.sidebar-menu > li > a:hover > .fab,
.sidebar-menu > li > a:hover > .icon {
  color: var(--primary-color);
  transform: translateX(3px);
}

.sidebar-menu > li.active > a {
  background: var(--sidebar-hover);
  color: #ffffff;
  border-left-color: var(--primary-color);
  font-weight: 600;
}

.sidebar-menu > li.active > a > .fa,
.sidebar-menu > li.active > a > .fas,
.sidebar-menu > li.active > a > .far,
.sidebar-menu > li.active > a > .fab,
.sidebar-menu > li.active > a > .icon {
  color: var(--primary-color);
}

/* Submenús */
.sidebar-menu .treeview-menu {
  list-style: none;
  padding: 0;
  margin: 0;
  background: rgba(0, 0, 0, 0.2);
  display: none;
}

.sidebar-menu .treeview-menu.show {
  display: block;
}

.sidebar-menu .treeview-menu > li > a {
  display: block;
  padding: 0.6rem 1rem 0.6rem 2.5rem;
  color: var(--sidebar-text);
  transition: var(--transition-fast);
  font-size: 0.9rem;
}

.sidebar-menu .treeview-menu > li > a:hover {
  color: white;
  background: rgba(255, 255, 255, 0.05);
}

.sidebar-menu .treeview-menu > li.active > a {
  color: white;
  font-weight: 600;
}

/* ========== 6) CONTENIDO PRINCIPAL MEJORADO ========== */
.content-wrapper {
  margin-left: var(--sidebar-width);
  margin-top: var(--header-height);
  min-height: calc(100vh - var(--header-height));
  background: var(--body-bg);
  padding: 1.5rem;
  width: calc(100% - var(--sidebar-width));
  transition: var(--transition);
}

.content-header {
  margin-bottom: 1.5rem;
}

.content-header h1 {
  font-size: 1.8rem;
  font-weight: 600;
  margin: 0;
  color: var(--text-color);
}

.breadcrumb {
  background: transparent;
  padding: 0;
  margin-top: 0.5rem;
  font-size: 0.9rem;
}

/* ========== 7) COMPONENTES PROFESIONALES ========== */

/* Cards mejoradas */
.card {
  border: none;
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.5rem;
  background: var(--card-bg);
  transition: var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-md);
}

.card-header {
  background: var(--card-header-bg);
  color: var(--text-color);
  padding: 1rem 1.25rem;
  border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0 !important;
  border-bottom: 1px solid var(--border-color);
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-header .card-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 600;
}

.card-body {
  padding: 1.5rem;
}

.card-footer {
  background: var(--card-header-bg);
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--border-color);
  border-radius: 0 0 var(--border-radius-lg) var(--border-radius-lg);
}

/* Botones mejorados */
.btn {
  border-radius: var(--border-radius);
  padding: 0.5rem 1.2rem;
  font-weight: 500;
  transition: var(--transition);
  border: none;
  box-shadow: var(--shadow-sm);
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn:active {
  transform: translateY(0);
}

.btn-sm {
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
}

.btn-lg {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
}

.btn-primary {
  background: var(--primary-color);
  color: white;
}

.btn-primary:hover {
  background: var(--primary-dark);
  color: white;
}

.btn-success {
  background: var(--accent-color);
  color: white;
}

.btn-success:hover {
  background: var(--accent-dark);
  color: white;
}

.btn-danger {
  background: var(--danger-color);
  color: white;
}

.btn-danger:hover {
  background: var(--danger-dark);
  color: white;
}

.btn-warning {
  background: var(--warning-color);
  color: white;
}

.btn-warning:hover {
  background: var(--warning-dark);
  color: white;
}

.btn-info {
  background: var(--info-color);
  color: white;
}

.btn-info:hover {
  background: var(--info-dark);
  color: white;
}

.btn-outline-primary {
  background: transparent;
  color: var(--primary-color);
  border: 1px solid var(--primary-color);
}

.btn-outline-primary:hover {
  background: var(--primary-color);
  color: white;
}

/* Tablas mejoradas */
.table {
  background: white;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  margin-bottom: 0;
}

.table thead th {
  background: var(--primary-color);
  color: white;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  border: none;
  padding: 1rem;
  vertical-align: middle;
}

.table tbody tr {
  transition: var(--transition-fast);
}

.table tbody tr:hover {
  background-color: #f8f9fa;
}

.table td {
  vertical-align: middle;
  padding: 0.9rem;
  border-bottom: 1px solid var(--border-color);
}

.table-striped tbody tr:nth-of-type(odd) {
  background-color: rgba(0, 0, 0, 0.02);
}

/* Formularios mejorados */
.form-control, .form-select {
  border: 1px solid #d1d5db;
  border-radius: var(--border-radius);
  padding: 0.6rem 0.9rem;
  transition: var(--transition);
  font-size: 0.9rem;
}

.form-control:focus, .form-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(60, 141, 188, 0.25);
}

.form-label {
  font-weight: 500;
  color: var(--text-color);
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.input-group-text {
  background-color: #f8f9fa;
  border: 1px solid #d1d5db;
  border-radius: var(--border-radius);
}

/* Alerts mejorados */
.alert {
  border-radius: var(--border-radius);
  border: none;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid;
  padding: 1rem 1.25rem;
}

.alert-success {
  background-color: #d4edda;
  border-left-color: var(--accent-color);
  color: #155724;
}

.alert-danger {
  background-color: #f8d7da;
  border-left-color: var(--danger-color);
  color: #721c24;
}

.alert-warning {
  background-color: #fff3cd;
  border-left-color: var(--warning-color);
  color: #856404;
}

.alert-info {
  background-color: #d1ecf1;
  border-left-color: var(--info-color);
  color: #0c5460;
}

/* Badges mejorados */
.badge {
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  font-weight: 500;
  font-size: 0.8rem;
}

.badge-pill {
  border-radius: 50rem;
}

.badge-primary {
  background-color: var(--primary-color);
}

.badge-success {
  background-color: var(--accent-color);
}

.badge-danger {
  background-color: var(--danger-color);
}

.badge-warning {
  background-color: var(--warning-color);
}

.badge-info {
  background-color: var(--info-color);
}

/* Progress bars */
.progress {
  height: 0.75rem;
  border-radius: 20px;
  background-color: #e9ecef;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.progress-bar {
  background-color: var(--primary-color);
  border-radius: 20px;
  transition: width 0.6s ease;
}

/* ========== 8) BOTÓN TOGGLE MEJORADO ========== */
.toggle-btn {
  position: fixed;
  top: 1rem;
  left: 1rem;
  background: var(--primary-color);
  color: white;
  border: none;
  padding: 0.6rem 0.9rem;
  border-radius: var(--border-radius);
  z-index: 1050;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  display: none;
  transition: var(--transition);
}

.toggle-btn:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-lg);
  background: var(--primary-dark);
}

.toggle-btn:focus {
  outline: none;
}

/* ========== 9) TÍTULOS Y ENCABEZADOS MEJORADOS ========== */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-color);
  font-weight: 600;
  margin-bottom: 1rem;
  font-family: var(--font-family-heading);
}

h1 {
  font-size: 2rem;
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5rem;
}

h2 {
  font-size: 1.75rem;
}

h3 {
  font-size: 1.5rem;
  color: var(--primary-dark);
}

h4 {
  font-size: 1.25rem;
}

h5 {
  font-size: 1.1rem;
}

h6 {
  font-size: 1rem;
}

/* ========== 10) UTILIDADES MEJORADAS ========== */
.text-primary { color: var(--primary-color) !important; }
.text-success { color: var(--accent-color) !important; }
.text-danger { color: var(--danger-color) !important; }
.text-warning { color: var(--warning-color) !important; }
.text-info { color: var(--info-color) !important; }
.text-muted { color: var(--text-muted) !important; }

.bg-primary { background-color: var(--primary-color) !important; }
.bg-success { background-color: var(--accent-color) !important; }
.bg-danger { background-color: var(--danger-color) !important; }
.bg-warning { background-color: var(--warning-color) !important; }
.bg-info { background-color: var(--info-color) !important; }

.rounded { border-radius: var(--border-radius) !important; }
.rounded-lg { border-radius: var(--border-radius-lg) !important; }
.rounded-xl { border-radius: var(--border-radius-xl) !important; }

.shadow-sm { box-shadow: var(--shadow-sm) !important; }
.shadow { box-shadow: var(--shadow-md) !important; }
.shadow-lg { box-shadow: var(--shadow-lg) !important; }

/* ========== 11) RESPONSIVO MEJORADO ========== */

/* Tablets */
@media (max-width: 991px) {
  .toggle-btn {
    display: block !important;
  }

  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.show {
    transform: translateX(0) !important;
  }

  .header {
    left: 0;
  }

  .content-wrapper {
    margin-left: 0 !important;
    width: 100% !important;
    padding: 1rem;
  }

  .card-body {
    padding: 1rem;
  }

  .table {
    font-size: 0.9rem;
  }

  h1 {
    font-size: 1.6rem;
  }

  h2 {
    font-size: 1.4rem;
  }

  h3 {
    font-size: 1.3rem;
  }
}

/* Móviles */
@media (max-width: 767px) {
  .header {
    padding: 0 1rem;
  }
  
  .header .navbar-nav .nav-link span {
    display: none;
  }
  
  .header .navbar-nav .nav-link i {
    margin-right: 0;
  }
  
  .content-wrapper {
    padding: 0.75rem;
  }
  
  .card-body {
    padding: 0.75rem;
  }
  
  .btn {
    padding: 0.4rem 0.9rem;
    font-size: 0.85rem;
  }
  
  .table-responsive {
    font-size: 0.85rem;
  }
  
  h1 {
    font-size: 1.4rem;
  }
}

/* Móviles pequeños */
@media (max-width: 575px) {
  .header .logo-mini {
    display: block;
  }
  
  .header .logo-lg {
    display: none;
  }
  
  .user-panel .info {
    display: none;
  }
  
  .user-panel {
    justify-content: center;
    padding: 0.5rem;
  }
  
  .sidebar .brand {
    padding: 0.75rem;
  }
}

/* ========== 12) ESCRITORIO ========== */
@media (min-width: 992px) {
  .sidebar {
    transform: translateX(0) !important;
  }

  .content-wrapper {
    margin-left: var(--sidebar-width) !important;
    width: calc(100% - var(--sidebar-width)) !important;
  }

  .toggle-btn {
    display: none !important;
  }
}

/* Sidebar colapsado */
@media (min-width: 992px) {
  .sidebar-collapse .sidebar {
    width: var(--sidebar-collapsed-width);
  }
  
  .sidebar-collapse .sidebar .brand span,
  .sidebar-collapse .sidebar .menu-heading,
  .sidebar-collapse .sidebar .user-panel .info,
  .sidebar-collapse .sidebar .pull-right-container {
    display: none;
  }
  
  .sidebar-collapse .sidebar .sidebar-menu > li > a {
    padding: 0.75rem 0.5rem;
    text-align: center;
    justify-content: center;
  }
  
  .sidebar-collapse .sidebar .sidebar-menu > li > a > .fa,
  .sidebar-collapse .sidebar .sidebar-menu > li > a > .fas,
  .sidebar-collapse .sidebar .sidebar-menu > li > a > .far,
  .sidebar-collapse .sidebar .sidebar-menu > li > a > .fab,
  .sidebar-collapse .sidebar .sidebar-menu > li > a > .icon {
    margin-right: 0;
    font-size: 1.25rem;
  }
  
  .sidebar-collapse .sidebar .sidebar-menu > li > a > span {
    display: none;
  }
  
  .sidebar-collapse .content-wrapper,
  .sidebar-collapse .header {
    margin-left: var(--sidebar-collapsed-width) !important;
    width: calc(100% - var(--sidebar-collapsed-width)) !important;
  }
}

/* ========== 13) ANIMACIONES MEJORADAS ========== */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideInLeft {
  from { opacity: 0; transform: translateX(-20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.card, .alert {
  animation: fadeIn 0.3s ease-in-out;
}

.sidebar-menu > li {
  animation: slideInLeft 0.3s ease-in-out;
}

.btn:hover {
  animation: pulse 0.5s ease-in-out;
}

/* ========== 14) LOADING SPINNER MEJORADO ========== */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid #f3f3f3;
  border-radius: 50%;
  border-top: 3px solid var(--primary-color);
  animation: spin 1s linear infinite;
}

.loading-lg {
  width: 40px;
  height: 40px;
  border-width: 4px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ========== 15) ESTADOS Y INDICADORES ========== */
.status-indicator {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 0.5rem;
}

.status-online {
  background-color: var(--accent-color);
}

.status-offline {
  background-color: var(--secondary-color);
}

.status-busy {
  background-color: var(--danger-color);
}

.status-away {
  background-color: var(--warning-color);
}

/* ========== 16) MODALES PERSONALIZADOS ========== */
.modal-content {
  border: none;
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-lg);
}

.modal-header {
  background: var(--card-header-bg);
  border-bottom: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
}

.modal-footer {
  border-top: 1px solid var(--border-color);
  border-radius: 0 0 var(--border-radius-lg) var(--border-radius-lg);
}

/* ========== 17) ICONOS Y FAVICON ========== */
/* Incluir Font Awesome para iconos profesionales */
/* <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css"> */

.fa, .fas, .far, .fab {
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
}

/* Favicon personalizado */
.favicon {
  display: inline-block;
  width: 16px;
  height: 16px;
  background: var(--primary-color);
  border-radius: 2px;
  margin-right: 0.5rem;
}

/* ========== HEADER MEJORADO ========== */
.header {
  position: fixed;
  top: 0;
  left: var(--sidebar-width);
  right: 0;
  height: var(--header-height);
  background: var(--header-bg);
  color: var(--header-text);
  z-index: 1020;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  align-items: center;
  padding: 0 1.5rem;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header-right {
  display: flex;
  align-items: center;
}

.logo-mini {
  font-weight: 700;
  font-size: 1.5rem;
  display: none;
}

.header-info {
  display: flex;
  flex-direction: column;
}

.welcome-text {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.9);
}

.role-badge {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
}

.current-time {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.9);
}

.current-time i {
  margin-right: 0.5rem;
}

/* ========== RESPONSIVO HEADER ========== */
@media (max-width: 991px) {
  .header {
    left: 0;
  }
  
  .welcome-text {
    display: none;
  }
  
  .header-info {
    flex-direction: row;
    gap: 0.5rem;
    align-items: center;
  }
}

@media (max-width: 767px) {
  .header {
    padding: 0 1rem;
  }
  
  .current-time {
    font-size: 0.8rem;
  }
  
  .role-badge {
    font-size: 0.7rem;
    padding: 0.15rem 0.5rem;
  }
}

@media (max-width: 575px) {
  .logo-mini {
    display: block;
  }
  
  .header-info .welcome-text {
    display: none;
  }
  
  .current-time {
    display: none;
  }
}

/* Sidebar colapsado - ajuste header */
.sidebar-collapse .header {
  left: var(--sidebar-collapsed-width);
}