/* ═══════════════════════════════════════════════════════════
   VEHICLES.CSS — NEW LAW v2.0 (DARK/LIGHT)
   Sistema cromático institucional RUTH (DARK por defecto)
   Basado en manual de marca 2026 · WCAG 2.1 AA/AAA
   ═══════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════
   MODO OSCURO (por defecto)
   ═══════════════════════════════════════════════════════════ */
:root {
  --bg: #0C0E0F;
  --bg-rgb: 12,14,15;
  --bg-2: #17191C;
  --bg-3: #22262A;
  --footer-bg: #07080A;

  --text-1: #FFFFFF;
  --text-1-rgb: 255,255,255;
  --text-2: rgba(255,255,255,.80);
  --text-3: rgba(255,255,255,.56);

  --border: rgba(255,255,255,.09);
  --border-strong: rgba(255,255,255,.16);

  --gold: #FFEDA8;
  --gold-bright: #FFF6D9;
  --gold-ink: #FFF6D9;
  --gold-border: transparent;
  --gold-rgb: 255,237,168;

  --menta: #A9F5C8;
  --cielo: #B3D4FF;
  --lila: #CFC0FF;
  --coral: #FFB3A7;

  --magenta: #C42A8E;
  --magenta-deep: #8E1C66;
  --magenta-soft: #F9AEDC;

  --accent: var(--magenta);
  --accent-rgb: 196,42,142;

  --success: var(--menta);
  --danger: #DC3545;
  --warning: var(--coral);
  --info: var(--cielo);

  --f-body: 'Manrope', 'Archivo', system-ui, sans-serif;
  --f-display: 'Manrope', 'Archivo', system-ui, sans-serif;

  --bg-card: var(--bg-2);
  --bg-card2: var(--bg-3);
  --muted: var(--text-3);
  --step-inactive: var(--text-3);
  --step-active: var(--magenta);
  --step-done: var(--menta);
}

/* ═══════════════════════════════════════════════════════════
   MODO CLARO
   ═══════════════════════════════════════════════════════════ */
:root[data-theme="light"] {
  --bg: #FFFFFF;
  --bg-rgb: 255,255,255;
  --bg-2: #F7F5EF;
  --bg-3: #EFEBE1;
  --footer-bg: #EFEAE0;

  --text-1: #14171A;
  --text-1-rgb: 20,23,26;
  --text-2: rgba(20,23,26,.80);
  --text-3: rgba(20,23,26,.58);

  --border: rgba(20,23,26,.10);
  --border-strong: rgba(20,23,26,.18);

  --gold: #FFEDA8;
  --gold-bright: #FFF6D9;
  --gold-ink: #8A6B1F;
  --gold-border: #B8860B;
  --gold-rgb: 255,237,168;

  --menta: #A9F5C8;
  --cielo: #B3D4FF;
  --lila: #CFC0FF;
  --coral: #FFB3A7;

  --magenta: #C42A8E;
  --magenta-deep: #8E1C66;
  --magenta-soft: #F9AEDC;

  --accent: var(--magenta);
  --accent-rgb: 196,42,142;

  --success: var(--menta);
  --danger: #DC3545;
  --warning: var(--coral);
  --info: var(--cielo);

  --bg-card: var(--bg-2);
  --bg-card2: var(--bg-3);
  --muted: var(--text-3);
  --step-inactive: var(--text-3);
  --step-active: var(--magenta);
  --step-done: var(--menta);
}

/* ========================================
   RESET Y BASE
   ======================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--f-body);
  background: var(--bg);
  color: var(--text-1);
  overflow: hidden;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

/* ═══════════════════════════════════
   NAVBAR RUTH (con logo dual, toggle y dropdown)
═══════════════════════════════════ */

.navbar-ruth {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 48px;
  background: rgba(var(--bg-rgb), 0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 32px rgba(0, 0, 0, 0.04);
  z-index: 1000;
}

.nav-left {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.nav-logo {
  display: block;
  height: 34px;
  width: auto;
}
.nav-logo img {
  height: 100%;
  width: auto;
  display: block;
}
.logo-dark { display: block; }
.logo-light { display: none; }
:root[data-theme="dark"] .logo-dark { display: block; }
:root[data-theme="dark"] .logo-light { display: none; }
:root[data-theme="light"] .logo-dark { display: none; }
:root[data-theme="light"] .logo-light { display: block; }

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: nowrap;
}

/* ─── Toggle de tema ─── */
.theme-toggle {
  position: relative;
  width: 52px;
  height: 28px;
  border-radius: 100px;
  border: 1px solid var(--border-strong);
  background: var(--bg-3);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px;
  flex-shrink: 0;
  transition: .2s;
}
.theme-toggle:hover { border-color: var(--gold-ink); }
.theme-toggle i { font-size: 13px; position: relative; z-index: 1; transition: .2s; }
.theme-toggle .tt-sun { color: var(--text-3); }
.theme-toggle .tt-moon { color: var(--gold-ink); }
.theme-toggle .tt-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), var(--gold-bright));
  transition: transform .3s cubic-bezier(.2,.8,.2,1);
}
.theme-toggle.is-light .tt-thumb { transform: translateX(24px); }
.theme-toggle.is-light .tt-sun { color: var(--gold-ink); }
.theme-toggle.is-light .tt-moon { color: var(--text-3); }

/* ─── Botón dropdown ─── */
.nav-btn.dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-body);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-2);
  text-decoration: none;
  padding: 10px 18px;
  border: 1px solid var(--border-strong);
  background: transparent;
  transition: all 0.25s ease;
  border-radius: 4px;
  background: var(--bg-2);
  cursor: pointer;
}
.nav-btn.dropdown-toggle:hover {
  border-color: var(--magenta);
  color: var(--magenta);
  transform: translateY(-1px);
  background: rgba(196, 42, 142, 0.04);
}
.nav-btn.dropdown-toggle i {
  font-size: 1rem;
}
.nav-btn.dropdown-toggle::after {
  margin-left: 6px;
  vertical-align: middle;
}

/* ─── Dropdown menu ─── */
.dropdown-menu {
  background: var(--bg-2);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  padding: 8px 0;
  min-width: 210px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
:root[data-theme="dark"] .dropdown-menu {
  background: rgba(23, 25, 28, 0.95);
}
:root[data-theme="light"] .dropdown-menu {
  background: rgba(255, 255, 255, 0.95);
}
.dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 20px;
  font-family: var(--f-body);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-1);
  transition: all 0.2s ease;
}
.dropdown-item i {
  font-size: 1.1rem;
  width: 22px;
  text-align: center;
  color: var(--text-3);
  transition: color 0.2s;
}
.dropdown-item:hover {
  background: rgba(var(--accent-rgb), 0.06);
  color: var(--magenta);
}
.dropdown-item:hover i {
  color: var(--magenta);
}
.dropdown-divider {
  border-top: 1px solid var(--border);
  margin: 6px 0;
}

/* ─── Responsive navbar ─── */
@media (max-width: 768px) {
  .navbar-ruth {
    padding: 0 20px;
    height: 60px;
  }
  .nav-logo { height: 26px; }
  .nav-btn.dropdown-toggle {
    padding: 8px 14px;
    font-size: 0.65rem;
  }
  .nav-btn.dropdown-toggle .nav-btn-text {
    display: none;
  }
  .theme-toggle {
    width: 44px;
    height: 24px;
    padding: 0 4px;
  }
  .theme-toggle i { font-size: 11px; }
  .theme-toggle .tt-thumb { width: 18px; height: 18px; top: 2px; left: 2px; }
  .theme-toggle.is-light .tt-thumb { transform: translateX(20px); }
}
@media (max-width: 480px) {
  .nav-btn.dropdown-toggle {
    padding: 8px;
    gap: 0;
    width: 34px;
    height: 34px;
    justify-content: center;
    border-radius: 50%;
  }
  .nav-btn.dropdown-toggle i { font-size: 1rem; }
  .dropdown-menu { min-width: 180px; }
}

/* ═══════════════════════════════════
   LAYOUT — PANEL UNICO (FULL WIDTH)
═══════════════════════════════════ */

.workspace {
  display: grid;
  grid-template-columns: 1fr;
  padding:
    clamp(78px, 6vh, 95px)
    clamp(12px, 1.2vw, 24px)
    clamp(12px, 1.2vw, 24px);
  height: 100vh;
  background: var(--bg);
}

.chat-panel.full-width {
  display: flex;
  flex-direction: column;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: clamp(14px, 1vw, 20px);
  overflow: hidden;
  height: calc(100vh - clamp(92px, 9vh, 115px));
  max-width: 860px;
  margin: 0 auto;
  width: 100%;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.05);
}

@media (max-width: 950px) {
  .workspace {
    height: auto;
    overflow-y: auto;
  }
  .chat-panel.full-width {
    height: calc(100vh - clamp(92px, 9vh, 115px));
    min-height: 650px;
  }
}

@media (max-width: 480px) {
  .workspace {
    padding-left: 0;
    padding-right: 0;
  }
  .chat-panel.full-width {
    min-height: 520px;
    border-radius: 0;
    border-left: none;
    border-right: none;
  }
}

/* ═══════════════════════════════════
   PANEL DE CHAT
═══════════════════════════════════ */

.chat-header {
  padding:
    clamp(16px, 1vw, 24px)
    clamp(20px, 1.3vw, 28px);
  border-bottom: 1px solid var(--border);
  background:
    linear-gradient(180deg,
      rgba(var(--text-1-rgb), 0.04),
      transparent);
  flex-shrink: 0;
}

.chat-header h2 {
  margin: 0;
  font-size: 1.35rem;
  color: var(--text-1);
  font-weight: 700;
}

.chat-header p {
  margin-top: 4px;
  font-size: clamp(0.75rem, 0.85vw, 0.9rem);
  letter-spacing: 0.08em;
  color: var(--text-3);
  text-transform: uppercase;
}

/* ═══════════════════════════════════
   MIGAS DE PAN (PROGRESO)
═══════════════════════════════════ */

.breadcrumb-progress {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  gap: 0;
  border-bottom: 1px solid var(--border);
  background: rgba(var(--text-1-rgb), 0.02);
  flex-shrink: 0;
  flex-wrap: nowrap;
}

.step {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-3);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  transition: all 0.4s ease;
  white-space: nowrap;
}

.step .step-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--border-strong);
  color: var(--text-3);
  font-size: 1rem;
  transition: all 0.4s ease;
  flex-shrink: 0;
}

.step .step-label {
  transition: all 0.4s ease;
  font-weight: 600;
}

.step-connector {
  width: 28px;
  height: 2px;
  background: var(--border-strong);
  margin: 0 4px;
  transition: all 0.4s ease;
  flex-shrink: 0;
}

/* Estados de los pasos */
.step.active .step-icon {
  background: var(--magenta);
  color: var(--bg);
  box-shadow: 0 0 25px rgba(196, 42, 142, 0.3);
}
.step.active {
  color: var(--magenta);
}
.step.done .step-icon {
  background: var(--menta);
  color: var(--bg);
  box-shadow: 0 0 20px rgba(169, 245, 200, 0.3);
}
.step.done {
  color: var(--menta);
}
.step-connector.done {
  background: var(--menta);
}

/* Responsive de migas */
@media (max-width: 768px) {
  .breadcrumb-progress {
    padding: 10px 12px;
    gap: 0;
    overflow-x: auto;
    justify-content: flex-start;
    flex-wrap: nowrap;
  }
  .step .step-label {
    display: none;
  }
  .step .step-icon {
    width: 30px;
    height: 30px;
    font-size: 0.85rem;
  }
  .step-connector {
    width: 16px;
  }
  .step {
    gap: 0;
  }
}

@media (max-width: 480px) {
  .step .step-icon {
    width: 26px;
    height: 26px;
    font-size: 0.75rem;
  }
  .step-connector {
    width: 10px;
  }
}

/* ═══════════════════════════════════
   CHAT WRAPPER (SCROLL)
═══════════════════════════════════ */

.chat-wrapper {
  flex: 1;
  overflow-y: auto;
  padding: clamp(16px, 1.2vw, 28px);
}

.chat-wrapper::-webkit-scrollbar {
  width: 8px;
}
.chat-wrapper::-webkit-scrollbar-track {
  background: transparent;
}
.chat-wrapper::-webkit-scrollbar-thumb {
  background: rgba(196, 42, 142, 0.25);
  border-radius: 20px;
}
.chat-wrapper::-webkit-scrollbar-thumb:hover {
  background: rgba(196, 42, 142, 0.45);
}

/* ═══════════════════════════════════
   MENSAJES MEJORADOS
═══════════════════════════════════ */

.bot-message,
.user-message {
  margin: 14px 0;
  display: flex;
  animation: slideUp 0.35s ease-in-out;
}

.bot-message {
  justify-content: flex-start;
}

.user-message {
  justify-content: flex-end;
}

.bubble {
  padding:
    clamp(12px, 0.9vw, 16px)
    clamp(16px, 1.1vw, 22px);
  border-radius: 14px;
  max-width: 85%;
  word-break: break-word;
  font-size: clamp(0.95rem, 1vw, 1.05rem);
  line-height: 1.6;
}

.bot-message .bubble {
  background: var(--bg-3);
  color: var(--text-1);
  border-radius: 16px 16px 16px 4px;
  border-left: 3px solid var(--magenta);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.user-message .bubble {
  background: var(--magenta);
  color: var(--bg);
  border-radius: 16px 16px 4px 16px;
  box-shadow: 0 2px 12px rgba(196, 42, 142, 0.15);
}

/* ═══════════════════════════════════
   ALERTAS MEJORADAS
═══════════════════════════════════ */

.alert-success-custom {
  background: rgba(169, 245, 200, 0.12);
  border: 2px solid var(--menta);
  border-radius: 14px;
  padding: 18px 22px;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 92%;
}
.alert-success-custom i { font-size: 2rem; color: var(--menta); flex-shrink: 0; }
.alert-success-custom .alert-title { font-weight: 700; font-size: 1.15rem; color: var(--menta); display: block; margin-bottom: 3px; }
.alert-success-custom .alert-text { font-size: 0.95rem; }

.alert-warning-custom {
  background: rgba(255, 179, 167, 0.12);
  border: 2px solid var(--coral);
  border-radius: 14px;
  padding: 18px 22px;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 92%;
}
.alert-warning-custom i { font-size: 2rem; color: var(--coral); flex-shrink: 0; }
.alert-warning-custom .alert-title { font-weight: 700; font-size: 1.15rem; color: var(--coral); display: block; margin-bottom: 3px; }
.alert-warning-custom .alert-text { font-size: 0.95rem; }

.alert-danger-custom {
  background: rgba(220, 53, 69, 0.10);
  border: 2px solid var(--danger);
  border-radius: 14px;
  padding: 18px 22px;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 92%;
}
.alert-danger-custom i { font-size: 2rem; color: var(--danger); flex-shrink: 0; }
.alert-danger-custom .alert-title { font-weight: 700; font-size: 1.15rem; color: var(--danger); display: block; margin-bottom: 3px; }
.alert-danger-custom .alert-text { font-size: 0.95rem; }

.alert-info-custom {
  background: rgba(179, 212, 255, 0.12);
  border: 2px solid var(--cielo);
  border-radius: 14px;
  padding: 18px 22px;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 92%;
}
.alert-info-custom i { font-size: 2rem; color: var(--cielo); flex-shrink: 0; }
.alert-info-custom .alert-title { font-weight: 700; font-size: 1.15rem; color: var(--cielo); display: block; margin-bottom: 3px; }
.alert-info-custom .alert-text { font-size: 0.95rem; }

/* ═══════════════════════════════════
   TARJETA DE FINALIZACIÓN
═══════════════════════════════════ */

.completion-card {
  background: linear-gradient(145deg, rgba(169, 245, 200, 0.10), rgba(169, 245, 200, 0.02));
  border: 2px solid var(--menta);
  border-radius: 18px;
  padding: 30px 32px;
  text-align: center;
  max-width: 92%;
}
.completion-card .completion-icon { font-size: 3.8rem; color: var(--menta); display: block; margin-bottom: 14px; }
.completion-card .completion-title { font-size: 1.6rem; font-weight: 800; color: var(--menta); margin-bottom: 8px; }
.completion-card .completion-subtitle { font-size: 1.1rem; color: var(--text-3); margin-bottom: 14px; }
.completion-card .completion-detail { font-size: 1rem; color: var(--text-1); line-height: 1.7; }
.completion-card .completion-divider { border: none; border-top: 2px solid rgba(169, 245, 200, 0.2); margin: 18px 0; }
.completion-card .completion-badge { display: inline-block; background: rgba(169, 245, 200, 0.15); color: var(--menta); padding: 6px 22px; border-radius: 30px; font-size: 0.9rem; font-weight: 600; letter-spacing: 0.06em; margin-top: 10px; }

/* ═══════════════════════════════════
   TARJETA DE DOCUMENTOS / ARCHIVOS
═══════════════════════════════════ */

.file-card {
  background: var(--bg-3);
  border: 1px solid var(--border-strong);
  padding: 18px 22px;
  border-radius: 12px;
  max-width: 92%;
  font-size: 0.95rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}
.file-card h5 { font-size: 1.15rem; font-weight: 700; color: var(--text-1); margin-bottom: 8px; }
.file-card small { display: block; color: var(--text-3); font-size: 0.85rem; }
.file-card i { margin-right: 8px; }
.file-card .btn { font-size: 0.9rem; padding: 10px 20px; border-radius: 10px; margin-bottom: 8px; }
.file-card .btn:last-child { margin-bottom: 0; }

/* ═══════════════════════════════════════════════════════════
   RESUMEN DE DOCUMENTOS — TABLA TIPO FICHA
   ═══════════════════════════════════════════════════════════ */

.resumen-documentos {
  max-width: 95%;
  font-size: 1rem;
  margin: 8px 0;
}
.resumen-documentos table {
  background: var(--bg) !important;
  margin-bottom: 0;
  border-radius: 8px;
  overflow: hidden;
  border-collapse: collapse;
  width: 100%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}
.resumen-documentos th {
  color: var(--magenta);
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 12px 16px 8px 16px;
  border: none;
  border-bottom: 1px solid var(--border-strong);
  background: var(--bg-2) !important;
  text-align: left;
}
.resumen-documentos td {
  border: none;
  border-bottom: 1px solid var(--border-strong);
  font-size: 0.95rem;
  padding: 10px 16px;
  color: var(--text-1);
  background: var(--bg) !important;
}
.resumen-documentos tr:last-child td { border-bottom: none; }
.resumen-documentos td:first-child { color: var(--text-3); font-weight: 500; width: 38%; }
.resumen-documentos td:last-child { color: var(--text-1); font-weight: 600; text-align: right; width: 62%; }
.resumen-documentos tbody tr:nth-child(even) td { background: var(--bg-2) !important; }
.resumen-documentos tbody tr:hover td { background: rgba(196, 42, 142, 0.04) !important; transition: background 0.2s ease; }

/* Responsive tabla */
@media (max-width: 768px) {
  .resumen-documentos td:first-child { width: 42%; font-size: 0.85rem; }
  .resumen-documentos td:last-child { width: 58%; font-size: 0.85rem; }
  .resumen-documentos th { font-size: 0.65rem; padding: 10px 12px 6px 12px; }
  .resumen-documentos td { padding: 8px 12px; font-size: 0.85rem; }
}
@media (max-width: 480px) {
  .resumen-documentos td:first-child { width: 40%; font-size: 0.8rem; }
  .resumen-documentos td:last-child { width: 60%; font-size: 0.8rem; word-break: break-word; }
  .resumen-documentos th { font-size: 0.6rem; padding: 8px 10px 4px 10px; }
  .resumen-documentos td { padding: 6px 10px; font-size: 0.8rem; }
}

/* ═══════════════════════════════════
   BOTONES
═══════════════════════════════════ */

.btn-success-custom {
  background: var(--menta);
  color: var(--bg);
  border: none;
  padding: 12px 24px;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  cursor: pointer;
}
.btn-success-custom:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(169, 245, 200, 0.25);
  background: #8ae0b0;
}

.btn-primary-custom {
  background: var(--magenta);
  color: var(--bg);
  border: none;
  padding: 12px 24px;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  cursor: pointer;
}
.btn-primary-custom:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(196, 42, 142, 0.25);
  background: var(--magenta-deep);
}

/* ═══════════════════════════════════
   SUBIDA DE ARCHIVOS
═══════════════════════════════════ */

#fileUploadCard.card {
  background: var(--bg-2) !important;
  border: 1px solid var(--border) !important;
  color: var(--text-1);
  flex-shrink: 0;
  border-radius: 12px;
}
#fileInput {
  background: var(--bg) !important;
  color: var(--text-1);
  border: 1px solid var(--border-strong);
  font-size: 0.95rem;
  padding: 10px;
  border-radius: 8px;
}
#fileInput::file-selector-button {
  background: var(--border-strong);
  color: var(--text-1);
  border: none;
  padding: 10px 16px;
  margin-right: 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background 0.3s ease;
}
#fileInput::file-selector-button:hover {
  background: var(--menta);
  color: var(--bg);
}
#sendBtn {
  background: var(--menta);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 600;
  padding: 12px;
  border-radius: 10px;
  color: var(--bg);
}
#sendBtn:hover {
  background: #8ae0b0;
}

/* ═══════════════════════════════════
   INPUT DE TEXTO
═══════════════════════════════════ */

.input-area {
  display: flex;
  gap: clamp(10px, 0.8vw, 16px);
  padding: clamp(14px, 1vw, 20px);
  border-top: 1px solid var(--border);
  flex-shrink: 0;
  background: var(--bg-2);
  border-radius: 0 0 clamp(14px, 1vw, 20px) clamp(14px, 1vw, 20px);
}
.input-area input {
  flex: 1;
  background: var(--bg) !important;
  color: var(--text-1) !important;
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  padding: 0 18px;
  height: clamp(48px, 5vh, 56px);
  font-size: clamp(0.95rem, 1vw, 1.05rem);
}
.input-area input::placeholder { color: var(--text-3) !important; font-size: 0.95rem; }
.input-area input:focus {
  outline: none !important;
  border-color: var(--magenta) !important;
  box-shadow: 0 0 0 4px rgba(196, 42, 142, 0.12) !important;
}
.input-area input:disabled {
  background: var(--bg-2) !important;
  color: var(--text-3) !important;
  cursor: not-allowed;
}
#sendTextBtn {
  width: clamp(56px, 4.5vw, 66px);
  height: clamp(48px, 5vh, 56px);
  border: none;
  border-radius: clamp(12px, 0.8vw, 16px);
  background: var(--magenta);
  color: var(--bg);
  font-size: 1.2rem;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.35s ease;
  box-shadow: 0 5px 20px rgba(196, 42, 142, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
}
#sendTextBtn i { font-size: 1.3rem; }
#sendTextBtn:hover {
  transform: translateY(-3px);
  background: var(--magenta-deep);
  box-shadow: 0 12px 30px rgba(196, 42, 142, 0.45);
}
#sendTextBtn:active { transform: scale(0.96); }
#sendTextBtn:disabled {
  background: var(--border-strong);
  color: var(--text-3);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ═══════════════════════════════════
   SELECTORES DE FECHA Y HORA
═══════════════════════════════════ */

input[type="date"],
input[type="time"] {
  background: var(--bg) !important;
  border: 1px solid var(--border-strong) !important;
  color: var(--text-1) !important;
  border-radius: 10px !important;
  padding: 10px 14px !important;
  width: 100%;
  font-family: var(--f-body);
  font-size: 0.95rem;
  cursor: pointer;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
input[type="date"]:focus,
input[type="time"]:focus {
  border-color: var(--magenta) !important;
  box-shadow: 0 0 0 3px rgba(196, 42, 142, 0.12) !important;
  outline: none !important;
}
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator {
  filter: invert(0.5);
  cursor: pointer;
  padding: 4px;
}
input[type="date"]::-webkit-datetime-edit-text,
input[type="date"]::-webkit-datetime-edit-month-field,
input[type="date"]::-webkit-datetime-edit-day-field,
input[type="date"]::-webkit-datetime-edit-year-field,
input[type="time"]::-webkit-datetime-edit-text,
input[type="time"]::-webkit-datetime-edit-hour-field,
input[type="time"]::-webkit-datetime-edit-minute-field {
  color: var(--text-1);
}
input[type="date"]:disabled,
input[type="time"]:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-confirmar-fecha {
  background: var(--menta) !important;
  color: var(--bg) !important;
  border: none !important;
  padding: 10px 20px !important;
  border-radius: 10px !important;
  font-size: 0.9rem !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  transition: all 0.3s ease !important;
  cursor: pointer !important;
  width: 100% !important;
}
.btn-confirmar-fecha:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(169, 245, 200, 0.3);
  background: #8ae0b0 !important;
}
.btn-confirmar-fecha:active { transform: scale(0.97); }

/* ═══════════════════════════════════
   ESTADOS DESHABILITADOS
═══════════════════════════════════ */

#fileInput:disabled,
.form-control:disabled {
  background: var(--bg-2) !important;
  color: var(--text-3);
  cursor: not-allowed;
  border-color: var(--border) !important;
}
.btn:disabled,
#sendBtn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  background: var(--border-strong);
  color: var(--text-3);
}

/* ═══════════════════════════════════
   CANVAS DE FONDO
═══════════════════════════════════ */

#network-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  display: block;
}

/* ═══════════════════════════════════
   ANIMACIONES
═══════════════════════════════════ */

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pulseSuccess {
  0%, 100% { box-shadow: 0 0 30px rgba(169, 245, 200, 0.1); }
  50% { box-shadow: 0 0 50px rgba(169, 245, 200, 0.2); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
.summary-card, .success-card { animation: fadeIn 0.4s ease-in-out; }

/* ═══════════════════════════════════
   SELECCIÓN Y FOCO
═══════════════════════════════════ */

::selection { background: var(--gold); color: var(--bg); }
::-moz-selection { background: var(--gold); color: var(--bg); }
:focus-visible { outline: 2px solid var(--magenta); outline-offset: 2px; border-radius: 4px; }

button, .btn, .nav-btn, a[class*="btn"] {
  transition: transform .18s cubic-bezier(.22, 1, .36, 1), background .25s ease, color .25s ease, border-color .25s ease, box-shadow .25s ease;
}
button:active, .btn:active, .nav-btn:active, a[class*="btn"]:active {
  transform: translateY(1px) scale(.99);
}