/* ========================================================================
   KRONOS DESIGN TOKENS v1.0
   Fuente: KA_IC_BRD_26_002 (UIKit) + KA_IC_DSH_26_002 (Dashboard Pro)
   Usar en: index.html, portal.html, dashboard.html
   ======================================================================== */

:root {
  /* ---------- Marca (Tiger Flame family) ---------- */
  --tiger:  #fc5b1a;
  --coral:  #fa7a47;
  --tang:   #fc9a72;
  --peach:  #fcb591;

  /* ---------- Neutros oscuros ---------- */
  --jet:    #252d3c;
  --indigo: #313e59;
  --olive:  #708581;
  --steel:  #8c9faa;
  --slate:  #b2b5bb;
  --white:  #fefefe;

  /* ---------- Superficies dark ---------- */
  --bg-0:   #12161f;  /* base más oscura */
  --bg-1:   #181e2a;  /* sidebar / elevaciones suaves */
  --bg-2:   #1c2333;  /* cards */
  --bg-pure: #000000; /* hero / orbs */

  /* ---------- Bordes y líneas ---------- */
  --border:       rgba(140, 159, 170, 0.12);
  --border-soft:  rgba(140, 159, 170, 0.08);
  --border-hot:   rgba(252, 91, 26, 0.35);

  /* ---------- Estados ---------- */
  --success: #4caf7d;
  --warning: #f0a500;
  --error:   #e05555;

  /* ---------- Sombras y glows ---------- */
  --shadow-sm:  0 4px 16px rgba(0, 0, 0, 0.25);
  --shadow-md:  0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-lg:  0 20px 50px rgba(0, 0, 0, 0.45);
  --glow-tiger: 0 0 20px rgba(252, 91, 26, 0.20);
  --glow-hot:   0 14px 30px -8px rgba(252, 91, 26, 0.55);

  /* ---------- Radios ---------- */
  --r-sm:  8px;
  --r-md:  12px;
  --r-lg:  14px;
  --r-xl:  18px;
  --r-pill: 999px;

  /* ---------- Transiciones ---------- */
  --t-fast:   0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --t-mid:    0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --t-slow:   0.35s cubic-bezier(0.4, 0, 0.2, 1);

  /* ---------- Layout ---------- */
  --sidebar-w: 240px;
  --topbar-h:  64px;
}

/* ========================================================================
   RESET Y TIPOGRAFÍA BASE
   ======================================================================== */

* {
  font-family: 'Leelawadee', 'Segoe UI', 'Inter', system-ui, sans-serif;
}

html, body {
  background: var(--bg-pure);
  color: var(--white);
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}

/* ---------- Tipografía display ---------- */
.display-text {
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 0.95;
}

.mono-label {
  font-family: 'Consolas', 'Monaco', monospace;
  letter-spacing: 0.25em;
  font-size: 10px;
  text-transform: uppercase;
}

/* Título de sección: versión grande y bold del mono-label */
.section-title {
  font-family: 'Consolas', 'Monaco', monospace;
  letter-spacing: 0.22em;
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
}

.login-title {
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 0.5px;
  color: var(--white);
}

.clock-digits {
  font-family: 'Leelawadee', 'Consolas', 'Monaco', monospace;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.06em;
  font-weight: 900;
}

/* ========================================================================
   DECORACIÓN DE FONDO
   ======================================================================== */

.grid-bg {
  background-image:
    linear-gradient(rgba(252, 91, 26, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(252, 91, 26, 0.035) 1px, transparent 1px);
  background-size: 60px 60px;
}

.glow-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
  z-index: 0;
}
.orb-tl { width: 500px; height: 500px; background: rgba(252, 91, 26, 0.16); top: -150px; left: -150px; }
.orb-tr { width: 500px; height: 500px; background: rgba(252, 91, 26, 0.14); top: -150px; right: -150px; }
.orb-br { width: 450px; height: 450px; background: rgba(252, 91, 26, 0.10); bottom: -150px; right: -150px; }
.orb-bl { width: 450px; height: 450px; background: rgba(252, 91, 26, 0.10); bottom: -150px; left: -150px; }
.orb-main {
  width: 600px; height: 600px; background: rgba(252, 91, 26, 0.20);
  top: -200px; left: -200px; position: absolute;
}

/* Corner marks */
.corner-mark {
  position: fixed;
  width: 26px; height: 26px;
  border: 1.5px solid var(--tiger);
  pointer-events: none;
  z-index: 5;
}
.corner-tl { top: 24px; left: 24px; border-right: none; border-bottom: none; }
.corner-tr { top: 24px; right: 24px; border-left: none; border-bottom: none; }
.corner-bl { bottom: 24px; left: 24px; border-right: none; border-top: none; }
.corner-br { bottom: 24px; right: 24px; border-left: none; border-top: none; }

/* ========================================================================
   ACENTOS Y DIVIDERS
   ======================================================================== */

.accent-bar {
  width: 56px; height: 3px;
  background: var(--tiger);
  border-radius: 2px;
}
.accent-vertical {
  width: 3px; height: 56px;
  background: linear-gradient(180deg, var(--tiger), transparent);
  border-radius: 2px;
}

.divider-orange {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(252, 91, 26, 0.4), transparent);
}

.divider-vert {
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(252, 91, 26, 0.35), transparent);
}

/* ========================================================================
   CARDS
   ======================================================================== */

.card-vanguard {
  position: relative;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* KPI card (Dashboard Pro) */
.kpi-card {
  position: relative;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 18px;
  overflow: hidden;
  transition: transform var(--t-mid), border-color var(--t-mid), box-shadow var(--t-mid);
}
.kpi-card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: var(--tiger);
  opacity: 0;
  transition: opacity var(--t-mid);
}
.kpi-card:hover {
  transform: translateY(-2px);
  border-color: rgba(252, 91, 26, 0.4);
  box-shadow: var(--glow-tiger);
}
.kpi-card:hover::before { opacity: 1; }

.kpi-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.kpi-icon {
  width: 36px; height: 36px;
  border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  background: rgba(252, 91, 26, 0.12);
  color: var(--tiger);
  border: 1px solid rgba(252, 91, 26, 0.25);
}
.kpi-val {
  font-size: 28px; font-weight: 900;
  color: var(--tiger);
  line-height: 1;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
.kpi-lbl {
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--steel);
  margin-top: 6px;
}
.kpi-sub {
  font-size: 11px;
  color: var(--olive);
  margin-top: 4px;
}

/* Status banner */
.status-banner {
  position: relative;
  background: linear-gradient(90deg, rgba(252, 91, 26, 0.10), rgba(252, 91, 26, 0.02) 70%);
  border: 1px solid var(--border-hot);
  border-left: 3px solid var(--tiger);
  border-radius: var(--r-md);
  padding: 16px 20px;
}

/* ========================================================================
   STATUS PILLS Y BADGES
   ======================================================================== */

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(252, 91, 26, 0.08);
  border: 1px solid rgba(252, 91, 26, 0.3);
  padding: 3px 10px;
  border-radius: var(--r-pill);
}
.status-pill.muted {
  background: rgba(140, 159, 170, 0.08);
  border-color: rgba(140, 159, 170, 0.25);
}
.status-pill.success {
  background: rgba(76, 175, 125, 0.10);
  border-color: rgba(76, 175, 125, 0.35);
  color: var(--success);
}
.status-pill.warning {
  background: rgba(240, 165, 0, 0.10);
  border-color: rgba(240, 165, 0, 0.35);
  color: var(--warning);
}
.status-pill.error {
  background: rgba(224, 85, 85, 0.10);
  border-color: rgba(224, 85, 85, 0.35);
  color: var(--error);
}

.tag-principal {
  background: var(--tiger);
  color: #fff;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.tag-secundario {
  background: rgba(140, 159, 170, 0.15);
  color: var(--slate);
  border: 1px solid rgba(140, 159, 170, 0.35);
  padding: 3px 10px;
  border-radius: var(--r-pill);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* ========================================================================
   BOTONES
   ======================================================================== */

.btn-vanguard {
  position: relative;
  background: var(--tiger);
  color: #fff;
  overflow: hidden;
  border-radius: var(--r-lg);
  transition: all var(--t-mid);
  border: 1px solid var(--tiger);
  font-weight: 800;
  cursor: pointer;
}
.btn-vanguard::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--tiger);
  opacity: 1;
  border-radius: inherit;
  transition: opacity var(--t-mid);
}
.btn-vanguard::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: var(--tiger);
  z-index: -1;
  opacity: 0;
  filter: blur(14px);
  transition: opacity var(--t-slow);
}
.btn-vanguard:hover::after { opacity: 0.9; }
.btn-vanguard:hover { transform: translateY(-2px); }
.btn-vanguard:active { transform: translateY(0); }
.btn-vanguard:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.btn-vanguard > * { position: relative; z-index: 1; }

.btn-ghost {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(252, 91, 26, 0.35);
  color: var(--peach);
  border-radius: var(--r-lg);
  transition: all var(--t-mid);
  cursor: pointer;
}
.btn-ghost:hover {
  background: rgba(252, 91, 26, 0.08);
  border-color: var(--tiger);
  color: var(--tiger);
  transform: translateY(-2px);
}
.btn-ghost:active { transform: translateY(0); }

.btn-soft {
  background: rgba(252, 91, 26, 0.08);
  color: var(--tang);
  border: 1px solid rgba(252, 91, 26, 0.25);
  border-radius: var(--r-md);
  transition: all var(--t-mid);
  cursor: pointer;
}
.btn-soft:hover {
  background: rgba(252, 91, 26, 0.15);
  color: var(--peach);
  border-color: var(--tiger);
  transform: translateY(-1px);
}

.link-ghost {
  color: var(--slate);
  transition: color var(--t-fast);
  background: transparent;
  border: none;
  cursor: pointer;
}
.link-ghost:hover { color: var(--tiger); }

/* ========================================================================
   INPUTS
   ======================================================================== */

.input-vanguard {
  background: rgba(255, 255, 255, 0.03);
  border: 1.5px solid rgba(140, 159, 170, 0.22);
  color: var(--white);
  border-radius: var(--r-md);
  transition: all var(--t-mid);
}
.input-vanguard::placeholder { color: rgba(140, 159, 170, 0.5); }
.input-vanguard:focus {
  outline: none;
  border-color: var(--tiger);
  background: rgba(252, 91, 26, 0.04);
  box-shadow: 0 0 0 3px rgba(252, 91, 26, 0.10);
}
select.input-vanguard {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%23fc5b1a' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  background-size: 1.25rem;
  padding-right: 2.75rem;
  cursor: pointer;
}
select.input-vanguard option { background: var(--bg-1); color: var(--white); }

/* ========================================================================
   LAYOUT ENTERPRISE (sidebar + topbar + content)
   ======================================================================== */

.k-shell {
  display: flex;
  min-height: 100vh;
  position: relative;
}

.k-sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: rgba(18, 22, 31, 0.85);
  border-right: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 15;
}

.k-sidebar-logo {
  padding: 22px 20px 18px;
  border-bottom: 2px solid var(--tiger);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(252, 91, 26, 0.03);
}

/* Texto de marca "KRONOS ONE" bajo el logo del sidebar.
   Se dimensiona al ancho del logo (auto en contenedor flex column). */
.k-brand-text {
  display: block;
  font-family: 'Segoe UI', Arial, Helvetica, sans-serif;
  font-weight: 900;
  color: var(--tiger);
  text-align: center;
  letter-spacing: 0.24em;
  /* Usa font-stretch-like trick: letter-spacing + font-size calculada
     para que el texto tenga aprox el ancho del logo (h-112 ≈ w-180) */
  font-size: 22px;
  line-height: 1;
  /* Asegura que se estire al ancho del logo */
  width: 100%;
  max-width: 190px;
}

.k-sidebar-section {
  padding: 18px 12px 6px;
}
.k-sidebar-section-title {
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--tiger);
  padding: 0 10px 12px;
}

.k-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--r-sm);
  color: var(--slate);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--t-fast);
  text-decoration: none;
  position: relative;
  margin-bottom: 2px;
}
.k-nav-item:hover {
  background: rgba(252, 91, 26, 0.06);
  color: var(--white);
}
.k-nav-item.active {
  background: linear-gradient(90deg, rgba(252, 91, 26, 0.14), rgba(252, 91, 26, 0.02));
  color: var(--white);
  box-shadow: inset 0 0 12px rgba(252, 91, 26, 0.06);
}
.k-nav-item.active::before {
  content: '';
  position: absolute;
  left: 0; top: 6px; bottom: 6px;
  width: 3px;
  background: var(--tiger);
  border-radius: 0 3px 3px 0;
}
.k-nav-item.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.k-nav-item .k-nav-icon {
  width: 18px; height: 18px;
  color: currentColor;
  flex-shrink: 0;
}
.k-nav-item .k-nav-badge {
  margin-left: auto;
  font-size: 9px;
  padding: 2px 7px;
  border-radius: var(--r-pill);
  background: rgba(140, 159, 170, 0.18);
  color: var(--steel);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.k-sidebar-footer {
  margin-top: auto;
  padding: 14px 16px;
  border-top: 1px solid var(--border);
  font-size: 11px;
}

.k-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  position: relative;
}

.k-topbar {
  height: var(--topbar-h);
  background: rgba(0, 0, 0, 0.65);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 12;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
}

.k-topbar-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.k-topbar-btn {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: transparent;
  color: var(--steel);
  display: flex; align-items: center; justify-content: center;
  transition: all var(--t-fast);
  cursor: pointer;
}
.k-topbar-btn:hover {
  border-color: var(--tiger);
  color: var(--tiger);
  box-shadow: var(--glow-tiger);
}

.k-content {
  padding: 24px;
  flex: 1;
}

/* ========================================================================
   ACTIVITY TIMELINE (Dashboard Pro)
   ======================================================================== */

.activity-list {
  display: flex;
  flex-direction: column;
}
.activity-item {
  display: flex;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--border-soft);
  transition: background var(--t-fast);
}
.activity-item:last-child { border-bottom: none; }
.activity-item:hover { background: rgba(252, 91, 26, 0.03); }

.act-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--tiger);
  margin-top: 6px;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(252, 91, 26, 0.15);
}
.act-dot.coral  { background: var(--coral); box-shadow: 0 0 0 3px rgba(250, 122, 71, 0.15); }
.act-dot.steel  { background: var(--steel); box-shadow: 0 0 0 3px rgba(140, 159, 170, 0.15); }
.act-dot.success { background: var(--success); box-shadow: 0 0 0 3px rgba(76, 175, 125, 0.15); }

.live-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
  animation: live-pulse 1.5s infinite;
}
@keyframes live-pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 8px var(--success); }
  50%      { opacity: 0.6; box-shadow: 0 0 14px var(--success); }
}

/* ========================================================================
   TABLA (Dashboard Pro)
   ======================================================================== */

.k-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.k-table thead th {
  text-align: left;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--steel);
  font-weight: 700;
  padding: 10px 14px;
  background: rgba(140, 159, 170, 0.04);
  border-bottom: 1px solid var(--border);
}
.k-table tbody td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-soft);
  color: var(--white);
}
.k-table tbody tr { transition: background var(--t-fast); }
.k-table tbody tr:hover { background: rgba(252, 91, 26, 0.04); }
.k-table tbody tr:last-child td { border-bottom: none; }

/* ========================================================================
   ANIMACIONES
   ======================================================================== */

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes slideInRight {
  from { opacity: 0; transform: translateX(20px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes scanline {
  0%, 100% { opacity: 0.3; }
  50%      { opacity: 1; }
}
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(252, 91, 26, 0.7); }
  70%      { box-shadow: 0 0 0 10px rgba(252, 91, 26, 0); }
}

.fade-up    { animation: fadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1); }
.fade-up-d1 { animation: fadeInUp 0.6s 0.1s cubic-bezier(0.4, 0, 0.2, 1) backwards; }
.fade-up-d2 { animation: fadeInUp 0.6s 0.2s cubic-bezier(0.4, 0, 0.2, 1) backwards; }
.fade-up-d3 { animation: fadeInUp 0.6s 0.3s cubic-bezier(0.4, 0, 0.2, 1) backwards; }
.fade-in    { animation: fadeIn 0.35s ease-out; }
.slide-in   { animation: slideInRight 0.8s cubic-bezier(0.4, 0, 0.2, 1); }
.scan-line  { animation: scanline 2.5s ease-in-out infinite; }
.pulse-dot  { animation: pulse-dot 2s infinite; }

/* ========================================================================
   BOTTOM NAV (mobile only)
   ======================================================================== */

.k-bottom-nav {
  display: none; /* se activa en mobile */
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(18, 22, 31, 0.95);
  border-top: 1px solid var(--border-hot);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 30;
  padding-bottom: env(safe-area-inset-bottom, 0);
}

.k-bottom-nav-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 64px;
}

.k-bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: var(--steel);
  transition: color var(--t-fast);
  text-decoration: none;
  padding: 6px 4px;
  position: relative;
  cursor: pointer;
  background: transparent;
  border: none;
  font-family: inherit;
}
.k-bottom-nav-item:hover { color: var(--tiger); }
.k-bottom-nav-item.active { color: var(--tiger); }
.k-bottom-nav-item.active::before {
  content: '';
  position: absolute;
  top: 0;
  left: 30%;
  right: 30%;
  height: 2px;
  background: var(--tiger);
  border-radius: 0 0 2px 2px;
}

.k-bottom-nav-icon { width: 22px; height: 22px; flex-shrink: 0; }

.k-bottom-nav-label {
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
}

/* ========================================================================
   RESPONSIVE (sidebar colapsa en mobile, bottom nav aparece)
   ======================================================================== */

@media (max-width: 900px) {
  .k-shell { flex-direction: column; }
  .k-sidebar {
    width: 100%;
    height: auto;
    position: relative;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .k-sidebar-section { display: none; }
  .k-sidebar-footer { display: none; }
  .k-sidebar-logo { padding: 14px 20px; }
  .corner-mark { display: none; }

  /* Activar bottom nav y reservar espacio al final del contenido */
  .k-bottom-nav { display: block; }
  .k-content { padding-bottom: 88px !important; }
  body { padding-bottom: 0; }
}

/* =========================================================
   TABLA WARM — patrón común usado en admin (Proyectos, Personal,
   Privilegios, Cumpleaños, etc.). Se coloca dentro de un panel
   blanco sobre el fondo oscuro del shell para alto contraste.
   ========================================================= */
.tbl-panel {
  background: #ffffff;
  border: 1px solid #f0ddd0;
  border-radius: var(--r-xl);
  box-shadow: 0 6px 22px rgba(252, 91, 26, 0.10), 0 1px 3px rgba(0, 0, 0, 0.08);
  overflow: hidden;
}
.tbl-panel .tbl-header {
  padding: 16px 22px;
  border-bottom: 1px solid #f0ddd0;
  background: #fdf6f1;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.tbl-panel .panel-title-row {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.tbl-panel .panel-action {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px;
  background: var(--tiger);
  border: 1px solid var(--tiger);
  border-radius: var(--r-md);
  color: #fff; font-weight: 700; font-size: 12px;
  cursor: pointer;
  transition: all var(--t-fast);
  box-shadow: 0 4px 10px -4px rgba(252, 91, 26, 0.55);
}
.tbl-panel .panel-action:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow: 0 8px 16px -6px rgba(252, 91, 26, 0.65);
}

.tbl-wrap {
  overflow-x: auto;
  background: #ffffff;
  padding-bottom: 2px;
  scrollbar-width: thin;
  scrollbar-color: #252d3c #f5ede6;
  min-height: 232px;
}
.tbl-wrap::-webkit-scrollbar { height: 12px; background: transparent; }
.tbl-wrap::-webkit-scrollbar-track {
  background: linear-gradient(90deg, #e05555 0%, #e05555 33%, #f0a500 33%, #f0a500 66%, #4caf7d 66%, #4caf7d 100%);
  border-radius: 10px; border: 2px solid #ffffff;
}
.tbl-wrap::-webkit-scrollbar-thumb { background: #252d3c; border-radius: 10px; border: 2px solid #ffffff; }
.tbl-wrap::-webkit-scrollbar-thumb:hover { background: #000; }

table.tbl-warm {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  background: #ffffff;
}
.tbl-warm thead th {
  padding: 12px 14px; text-align: left;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 10px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
  color: #708581; background: #f5ede6;
  border-bottom: 1px solid #f0ddd0;
  white-space: nowrap;
}
.tbl-warm tbody td {
  padding: 13px 14px;
  border-bottom: 1px solid #f0ddd0;
  color: #313e59; vertical-align: middle;
}
.tbl-warm tbody tr { transition: background var(--t-fast); }
.tbl-warm tbody tr:hover td { background: rgba(252, 154, 114, 0.10); }
.tbl-warm tbody tr:last-child td { border-bottom: none; }
.tbl-warm tbody tr.row-manual td { background: rgba(251, 191, 36, 0.10); }
.tbl-warm tbody tr.row-manual:hover td { background: rgba(251, 191, 36, 0.18); }
.tbl-warm tbody tr.row-manual td:first-child { border-left: 3px solid #fbbf24; }

.tbl-warm .cell-title { color: #252d3c; font-weight: 700; font-size: 13px; }
.tbl-warm .cell-code {
  font-family: 'Consolas', 'Monaco', monospace;
  color: var(--tiger); font-weight: 800; font-size: 11px;
  letter-spacing: 0.05em; white-space: nowrap;
}
.tbl-warm td:first-child, .tbl-warm th:first-child { white-space: nowrap; }
.tbl-warm .cell-empresa { white-space: normal; word-wrap: break-word; line-height: 1.35; }
.tbl-warm .cell-num { font-family: 'Consolas', 'Monaco', monospace; color: #252d3c; font-weight: 700; }

.tbl-warm .status-badge {
  display: inline-block; padding: 4px 11px; border-radius: 20px;
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 10px; font-weight: 700; letter-spacing: 0.15em; text-transform: uppercase;
  white-space: nowrap;
}
.tbl-warm .st-verde    { background: rgba(76, 175, 125, 0.22);  color: #1e6b3c; }
.tbl-warm .st-azul     { background: rgba(74, 144, 226, 0.20);  color: #1e5a9e; }
.tbl-warm .st-gris     { background: rgba(140, 159, 170, 0.24); color: #4a5955; }
.tbl-warm .st-amarillo { background: rgba(240, 165, 0, 0.22);   color: #8a5a00; }
.tbl-warm .st-otro     { background: rgba(240, 165, 0, 0.22);   color: #8a5a00; }

.tbl-warm .btn-mini {
  padding: 5px 11px;
  font-size: 10px;
  font-family: 'Consolas', 'Monaco', monospace;
  font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  border-radius: 6px; cursor: pointer;
  background: #ffffff; border: 1.5px solid #f0ddd0; color: #4a5955;
  transition: all var(--t-fast);
}
.tbl-warm .btn-mini:hover { border-color: var(--tiger); color: var(--tiger); }
.tbl-warm .btn-mini.edit { color: var(--tiger); border-color: var(--tiger); }
.tbl-warm .btn-mini.edit:hover { background: rgba(252, 91, 26, 0.10); }
.tbl-warm .btn-mini.danger { color: #b23b3b; border-color: #e05555; }
.tbl-warm .btn-mini.danger:hover { background: rgba(224, 85, 85, 0.10); }
.tbl-warm .btn-mini:disabled { opacity: 0.5; cursor: not-allowed; }

.section-title {
  font-family: 'Consolas', 'Monaco', monospace;
  font-size: 13px; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase;
}
