/* ═══════════════════════════════════════════════════════════
   Mi KIT PYME Mx — Estilos compartidos
   Design tokens consistentes con apps existentes
   (mx-liquidacion, mx-costo-empleado)
═══════════════════════════════════════════════════════════ */

:root {
  /* Colores base */
  --bg: #080e18;
  --bg2: #0d1625;
  --card: #111d2e;
  --card2: #162035;
  --border: #1e2f47;
  --border2: #253a58;
  --text: #e0dbd2;
  --muted: #6a84a0;
  --muted2: #8fa5be;

  /* Acentos */
  --amber: #f6a830;
  --amber-dim: rgba(246,168,48,.12);
  --amber-dim2: rgba(246,168,48,.22);
  --green: #3ecf8e;
  --blue: #4a9cf5;
  --purple: #9b7cf4;
  --red: #f5385f;
  --coral: #f5704a;

  /* Tipografía */
  --mono: 'DM Mono', ui-monospace, monospace;
  --sans: 'DM Sans', system-ui, sans-serif;
  --serif: 'Fraunces', Georgia, serif;
}

/* ═══════════════════════════════════════════════════════════
   KIT NAV — barra superior compartida
═══════════════════════════════════════════════════════════ */

.kit-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
  gap: 16px;
}

.kit-nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 400;
  color: var(--text);
  letter-spacing: -.01em;
  white-space: nowrap;
  text-decoration: none;
  flex-shrink: 0;
}
.kit-nav-brand em {
  font-style: italic;
  color: var(--amber);
}
.kit-nav-brand-icon {
  width: 18px;
  height: 18px;
  color: var(--amber);
  flex-shrink: 0;
}

.kit-nav-menu {
  display: flex;
  gap: 4px;
  flex: 1;
  justify-content: center;
  overflow-x: auto;
  scrollbar-width: none;
}
.kit-nav-menu::-webkit-scrollbar { display: none; }

.kit-nav-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  font-size: 12px;
  font-family: var(--mono);
  color: var(--muted2);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  text-decoration: none;
  transition: all .15s ease;
  white-space: nowrap;
}
.kit-nav-item:hover {
  color: var(--amber);
  background: var(--amber-dim);
  border-color: var(--amber-dim2);
}
.kit-nav-item[aria-current="page"] {
  color: var(--amber);
  background: var(--amber-dim);
  border-color: var(--amber-dim2);
}
.kit-nav-item[data-status="soon"] {
  color: var(--muted);
  opacity: .65;
}
.kit-nav-item[data-status="soon"]:hover {
  color: var(--muted2);
  background: transparent;
  border-color: var(--border);
  opacity: 1;
}
.kit-nav-item-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}
.kit-nav-item-badge {
  font-size: 9px;
  padding: 1px 5px;
  border-radius: 3px;
  background: var(--border);
  color: var(--muted);
  letter-spacing: .08em;
}

.kit-nav-link-out {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
  transition: color .15s ease;
  flex-shrink: 0;
}
.kit-nav-link-out:hover { color: var(--amber); }
.kit-nav-link-out svg {
  width: 12px;
  height: 12px;
}

/* Hamburger mobile */
.kit-nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border2);
  border-radius: 6px;
  padding: 6px;
  cursor: pointer;
  color: var(--muted2);
}
.kit-nav-toggle svg { width: 18px; height: 18px; }
.kit-nav-toggle:hover { color: var(--amber); border-color: var(--amber-dim2); }

@media (max-width: 768px) {
  .kit-nav { padding: 10px 16px; }
  .kit-nav-toggle { display: flex; }
  .kit-nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 8px;
    gap: 2px;
  }
  .kit-nav-menu.open { display: flex; }
  .kit-nav-menu .kit-nav-item {
    justify-content: flex-start;
    width: 100%;
    padding: 10px 14px;
  }
  .kit-nav-link-out { display: none; }
}

/* ═══════════════════════════════════════════════════════════
   ROL TOGGLE — Dueño vs Empleado
═══════════════════════════════════════════════════════════ */

.kit-role-toggle {
  display: inline-flex;
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: 8px;
  padding: 3px;
  gap: 2px;
}
.kit-role-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  background: transparent;
  border: none;
  border-radius: 5px;
  color: var(--muted2);
  font-family: var(--mono);
  font-size: 11.5px;
  cursor: pointer;
  transition: all .15s ease;
  white-space: nowrap;
}
.kit-role-btn svg {
  width: 14px;
  height: 14px;
}
.kit-role-btn:hover { color: var(--text); }
.kit-role-btn[aria-pressed="true"] {
  background: var(--amber-dim);
  color: var(--amber);
}

/* ═══════════════════════════════════════════════════════════
   FECHA BANNER — para apps con deadlines
═══════════════════════════════════════════════════════════ */

.kit-date-banner {
  background: linear-gradient(135deg, rgba(246,168,48,.08), rgba(245,112,74,.04));
  border: 1px solid var(--amber-dim2);
  border-radius: 8px;
  padding: 14px 18px;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.kit-date-banner-icon {
  width: 28px;
  height: 28px;
  color: var(--amber);
  flex-shrink: 0;
}
.kit-date-banner-content {
  flex: 1;
  min-width: 240px;
}
.kit-date-banner-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--muted);
  margin-bottom: 3px;
}
.kit-date-banner-value {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--text);
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}
.kit-date-banner-value strong {
  color: var(--amber);
  font-weight: 500;
}
.kit-date-banner-days {
  font-size: 11px;
  color: var(--muted2);
  padding: 2px 8px;
  background: var(--card2);
  border-radius: 4px;
  border: 1px solid var(--border);
}
.kit-date-banner-days.urgent {
  color: var(--coral);
  border-color: rgba(245,112,74,.3);
  background: rgba(245,112,74,.08);
}
.kit-date-banner-days.passed {
  color: var(--red);
  border-color: rgba(245,56,95,.3);
  background: rgba(245,56,95,.08);
}

/* ═══════════════════════════════════════════════════════════
   LEY DRAWER — panel lateral con marco legal
═══════════════════════════════════════════════════════════ */

.kit-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8,14,24,.7);
  z-index: 998;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
  backdrop-filter: blur(2px);
}
.kit-drawer-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.kit-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(480px, 100vw);
  background: var(--bg2);
  border-left: 1px solid var(--border2);
  z-index: 999;
  transform: translateX(100%);
  transition: transform .3s cubic-bezier(.2,.8,.2,1);
  display: flex;
  flex-direction: column;
  box-shadow: -20px 0 60px rgba(0,0,0,.4);
}
.kit-drawer.open { transform: translateX(0); }

.kit-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.kit-drawer-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--serif);
  font-size: 16px;
  color: var(--text);
}
.kit-drawer-title-badge {
  font-family: var(--mono);
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--amber-dim);
  color: var(--amber);
  border: 1px solid var(--amber-dim2);
}
.kit-drawer-close {
  background: transparent;
  border: none;
  color: var(--muted2);
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.kit-drawer-close svg { width: 18px; height: 18px; }
.kit-drawer-close:hover { color: var(--amber); background: var(--card); }

.kit-drawer-body {
  padding: 22px;
  overflow-y: auto;
  flex: 1;
}
.kit-drawer-body::-webkit-scrollbar { width: 4px; }
.kit-drawer-body::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 2px; }

.kit-art-title {
  font-family: var(--serif);
  font-size: 19px;
  color: var(--text);
  margin-bottom: 14px;
  line-height: 1.3;
}
.kit-art-text {
  font-size: 13px;
  line-height: 1.7;
  color: var(--muted2);
  margin-bottom: 16px;
}
.kit-art-formula {
  font-family: var(--mono);
  font-size: 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--amber);
  border-radius: 4px;
  padding: 12px 14px;
  color: var(--text);
  white-space: pre-wrap;
  line-height: 1.7;
  margin-bottom: 16px;
  overflow-x: auto;
}
.kit-art-meta {
  display: flex;
  gap: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 11px;
  color: var(--muted);
  flex-wrap: wrap;
}
.kit-art-meta-item strong {
  color: var(--muted2);
  font-family: var(--mono);
  font-weight: 400;
}

/* ═══════════════════════════════════════════════════════════
   LEY BADGES — chips clickeables al lado de inputs
═══════════════════════════════════════════════════════════ */

.kit-ley {
  font-size: 9.5px;
  font-family: var(--mono);
  padding: 1.5px 7px;
  border-radius: 3px;
  cursor: pointer;
  transition: opacity .15s ease;
  user-select: none;
  border: none;
  letter-spacing: .04em;
}
.kit-ley:hover { opacity: .75; }
.kit-ley-lft { background: #1a3560; color: #5ba3f5; }
.kit-ley-lss { background: #133526; color: #3ecf8e; }
.kit-ley-inf { background: #2d1f0e; color: #f6a830; }
.kit-ley-est { background: #2d1022; color: #d47aee; }
.kit-ley-ptu { background: #2e1610; color: #f5704a; }
.kit-ley-cpe { background: #1e1834; color: #9b7cf4; }

/* ═══════════════════════════════════════════════════════════
   BULK UPLOAD ZONE
═══════════════════════════════════════════════════════════ */

.kit-upload {
  border: 2px dashed var(--border2);
  border-radius: 10px;
  padding: 32px 24px;
  text-align: center;
  background: var(--card);
  transition: all .2s ease;
  cursor: pointer;
}
.kit-upload:hover,
.kit-upload.drag {
  border-color: var(--amber);
  background: var(--amber-dim);
}
.kit-upload-icon {
  width: 36px;
  height: 36px;
  color: var(--amber);
  margin: 0 auto 14px;
  display: block;
}
.kit-upload-title {
  font-family: var(--serif);
  font-size: 16px;
  color: var(--text);
  margin-bottom: 6px;
}
.kit-upload-hint {
  font-size: 12px;
  color: var(--muted2);
  margin-bottom: 14px;
  line-height: 1.6;
}
.kit-upload-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}
.kit-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 6px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 12px;
  cursor: pointer;
  text-decoration: none;
  transition: all .15s ease;
}
.kit-upload-btn:hover {
  border-color: var(--amber);
  color: var(--amber);
}
.kit-upload-btn svg { width: 14px; height: 14px; }
.kit-upload-btn.primary {
  background: var(--amber-dim);
  border-color: var(--amber-dim2);
  color: var(--amber);
}

.kit-upload-privacy {
  margin-top: 14px;
  padding: 10px 14px;
  background: rgba(74,156,245,.07);
  border-left: 2px solid var(--blue);
  border-radius: 0 4px 4px 0;
  font-size: 11px;
  color: var(--muted2);
  text-align: left;
  line-height: 1.6;
}
.kit-upload-privacy strong { color: var(--blue); }

/* ═══════════════════════════════════════════════════════════
   BULK RESULT TABLE
═══════════════════════════════════════════════════════════ */

.kit-bulk-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  margin-top: 18px;
}
.kit-bulk-table th {
  text-align: left;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--muted);
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
}
.kit-bulk-table th.r { text-align: right; }
.kit-bulk-table td {
  padding: 9px 10px;
  border-bottom: 1px solid rgba(30,47,71,.6);
  font-family: var(--mono);
}
.kit-bulk-table td.r { text-align: right; }
.kit-bulk-table td.id { color: var(--muted2); }
.kit-bulk-table tr.na td { opacity: .5; }
.kit-bulk-table tr.na td .na-badge {
  display: inline-block;
  font-size: 9.5px;
  padding: 2px 6px;
  background: rgba(245,56,95,.12);
  color: var(--red);
  border-radius: 3px;
  letter-spacing: .04em;
}
.kit-bulk-table tr.total td {
  border-top: 2px solid var(--amber);
  border-bottom: none;
  color: var(--amber);
  font-weight: 500;
  padding-top: 12px;
}

/* ═══════════════════════════════════════════════════════════
   MOBILE — vista de inputs primero, resultados con CTA
═══════════════════════════════════════════════════════════ */

.kit-mobile-jump {
  display: none;
  position: sticky;
  bottom: 16px;
  margin: 16px auto 0;
  background: var(--amber);
  color: var(--bg);
  border: none;
  padding: 12px 22px;
  border-radius: 30px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(246,168,48,.35);
  z-index: 50;
  align-items: center;
  gap: 8px;
}
.kit-mobile-jump svg { width: 14px; height: 14px; }

@media (max-width: 768px) {
  .kit-mobile-jump { display: inline-flex; }
}

/* ═══════════════════════════════════════════════════════════
   UTILIDADES
═══════════════════════════════════════════════════════════ */

.kit-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}
