/* ============================================================
   InteliBPO Visitor Platform — Corporate Brand Identity
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

:root {
  /* ——— Brand Color Palette ——— */
  
  /* Blues */
  --brand-blue-100: #2d5d9f;
  --brand-blue-80:  #577db2;
  --brand-blue-60:  #819ec6;
  --brand-blue-40:  #aabbd9;
  --brand-blue-20:  #d5deec;
  --brand-blue-10:  #eaeff6;

  /* Teals */
  --brand-teal-100: #009ba2;
  --brand-teal-80:  #33afb5;
  --brand-teal-60:  #66c3c7;
  --brand-teal-40:  #99d7da;
  --brand-teal-20:  #ccebec;
  --brand-teal-10:  #e5f5f6;

  /* Grays */
  --brand-gray-100: #2e2d2c;
  --brand-gray-80:  #585756;
  --brand-gray-60:  #828180;
  --brand-gray-40:  #ababad;
  --brand-gray-20:  #d5d5d5;
  --brand-gray-10:  #eaeaea;

  /* ——— Semantic Assignments ——— */
  --bg-depth-0: var(--brand-blue-10);   /* Fondo suave tintado de azul */
  --bg-depth-1: #ffffff;                /* Superficies limpias */
  --bg-depth-2: var(--brand-gray-10);   /* Cards alternas */
  --bg-depth-3: #ffffff;
  
  --text-primary: var(--brand-gray-100);
  --text-secondary: var(--brand-gray-80);
  --text-tertiary: var(--brand-gray-60);
  --text-inverse: #ffffff;

  --border-subtle: var(--brand-gray-20);
  --border-active: var(--brand-blue-60);

  /* Semantic UI */
  --success: var(--brand-teal-100);
  --danger: #ef4444; /* Keep a standard red for destructive actions */
  
  /* ——— Typography ——— */
  --font-display: 'Montserrat', sans-serif;
  --font-body: 'Montserrat', sans-serif;

  /* ——— Effects & Shadows ——— */
  --transition-fast: all 0.15s ease;
  --transition-base: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);

  --shadow-sm: 0 1px 2px 0 rgba(46, 45, 44, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(46, 45, 44, 0.05), 0 2px 4px -1px rgba(46, 45, 44, 0.03);
  --shadow-lg: 0 10px 15px -3px rgba(46, 45, 44, 0.08), 0 4px 6px -2px rgba(46, 45, 44, 0.04);
  --shadow-brand: 0 4px 14px 0 rgba(45, 93, 159, 0.25);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  
  --gradient-brand: linear-gradient(135deg, var(--brand-blue-100) 0%, var(--brand-teal-100) 100%);
}

/* ——————————————————————————————————————
   RESET & BASE
—————————————————————————————————————— */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background-color: var(--bg-depth-0);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* ——————————————————————————————————————
   LAYOUT
—————————————————————————————————————— */
#app-container {
  display: flex;
  flex: 1;
  min-height: calc(100vh - 70px);
  position: relative;
  z-index: 1;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
}

/* ——————————————————————————————————————
   HEADER — Barra de Navegación Corporativa
—————————————————————————————————————— */
header.main-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 2.5rem;
  height: 70px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 200;
  width: 100%;
  box-shadow: var(--shadow-sm);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.875rem;
}

.brand-logo {
  width: 40px;
  height: 40px;
  background: var(--gradient-brand);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-family: var(--font-display);
  color: #fff;
  font-size: 1.25rem;
  box-shadow: var(--shadow-brand);
}

.brand-text h1 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--brand-blue-100);
}

.brand-text span {
  font-size: 0.65rem;
  color: var(--brand-gray-60);
  display: block;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: -2px;
}

.system-nav {
  display: flex;
  gap: 0.35rem;
  background: var(--brand-gray-10);
  padding: 0.25rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--brand-gray-20);
}

.nav-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  padding: 0.45rem 1.1rem;
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: var(--transition-base);
}

.nav-btn svg {
  opacity: 0.8;
  transition: var(--transition-fast);
}

.nav-btn:hover {
  color: var(--brand-blue-100);
  background: var(--brand-blue-10);
}

.nav-btn.active {
  color: var(--brand-blue-100);
  background: #ffffff;
  border-color: var(--border-subtle);
  box-shadow: var(--shadow-sm);
}

/* Botón de Acceso Discreta */
.nav-btn-discrete {
  color: var(--brand-gray-60);
  border-style: dashed;
  border-color: var(--brand-gray-40);
  font-size: 0.78rem;
  padding: 0.4rem 0.9rem;
}

.nav-btn-discrete:hover {
  color: var(--brand-teal-100);
  border-color: var(--brand-teal-60);
  background: var(--brand-teal-10);
}

/* ——————————————————————————————————————
   PANELES Y VISTAS
—————————————————————————————————————— */
.view-panel {
  display: none;
  flex: 1;
  padding: 2.5rem;
  width: 100%;
  animation: fadeSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  position: relative;
  z-index: 1;
}

.view-panel.active {
  display: block;
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ——————————————————————————————————————
   GLASS CARDS — Tarjetas Premium
—————————————————————————————————————— */
.glass-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  padding: 2.5rem;
  margin-bottom: 2rem;
  position: relative;
  transition: var(--transition-base);
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--gradient-brand);
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

/* ——————————————————————————————————————
   KIOSCO — Pantalla de Bienvenida
—————————————————————————————————————— */
.kiosk-welcome {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  max-width: 800px;
  margin: 3.5rem auto;
  padding: 4rem 3rem;
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.kiosk-welcome::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 5px;
  background: var(--gradient-brand);
}

.kiosk-welcome h2 {
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 800;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
  color: var(--brand-gray-100);
}

.kiosk-welcome p {
  color: var(--brand-gray-80);
  font-size: 1.15rem;
  font-weight: 400;
  max-width: 560px;
  margin-bottom: 2.5rem;
  line-height: 1.6;
}

.kiosk-clock {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--brand-teal-100);
  margin-bottom: 3rem;
  background: var(--brand-teal-10);
  padding: 0.6rem 2rem;
  border-radius: 30px;
  border: 1px solid var(--brand-teal-40);
}

.kiosk-actions {
  display: flex;
  gap: 1.25rem;
  width: 100%;
  max-width: 520px;
}

/* ——————————————————————————————————————
   STEPPER — Indicador de Pasos
—————————————————————————————————————— */
.step-indicator {
  display: flex;
  justify-content: space-between;
  margin-bottom: 3rem;
  position: relative;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.step-indicator::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--border-subtle);
  z-index: 1;
  transform: translateY(-50%);
}

.step-indicator-bar {
  position: absolute;
  top: 50%;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--brand-blue-100);
  z-index: 1;
  transform: translateY(-50%);
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.step-dot {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--brand-gray-60);
  position: relative;
  z-index: 2;
  transition: var(--transition-spring);
}

.step-dot.active {
  border-color: var(--brand-blue-100);
  color: var(--brand-blue-100);
  background: var(--brand-blue-10);
  box-shadow: 0 0 0 4px var(--brand-blue-20);
}

.step-dot.completed {
  background: var(--brand-blue-100);
  border-color: var(--brand-blue-100);
  color: #fff;
}

/* ——————————————————————————————————————
   FORMULARIOS
—————————————————————————————————————— */
.form-step {
  display: none;
  animation: slideInRight 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.form-step.active { display: block; }

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(14px); }
  to { opacity: 1; transform: translateX(0); }
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.form-group-full { grid-column: span 2; }

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

label {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

input, select, textarea {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 0.8rem 1rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 500;
  transition: var(--transition-base);
  width: 100%;
}

input::placeholder, textarea::placeholder {
  color: var(--brand-gray-40);
  font-weight: 400;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--brand-blue-80);
  box-shadow: 0 0 0 3px var(--brand-blue-20);
}

/* Quitar flechas del number */
input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type=number] { -moz-appearance: textfield; }

/* Form nav */
.form-nav-buttons {
  display: flex;
  justify-content: space-between;
  margin-top: 2.5rem;
  gap: 1rem;
}

/* ——————————————————————————————————————
   BOTONES CORPORATIVOS
—————————————————————————————————————— */
.btn {
  padding: 0.8rem 1.75rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: var(--transition-base);
  border: 1px solid transparent;
  text-decoration: none;
}

.btn-primary {
  background: var(--brand-blue-100);
  color: #fff;
  box-shadow: var(--shadow-brand);
}

.btn-primary:hover {
  background: #1a4278; /* Un poco más oscuro que 100% */
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(45, 93, 159, 0.3);
}

.btn-secondary {
  background: #ffffff;
  border-color: var(--brand-gray-40);
  color: var(--brand-gray-100);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--brand-gray-10);
  border-color: var(--brand-gray-60);
}

.btn-success {
  background: var(--brand-teal-100);
  color: #fff;
  box-shadow: 0 4px 10px rgba(0, 155, 162, 0.25);
}

.btn-success:hover {
  background: #00797f;
  transform: translateY(-1px);
}

.btn-danger {
  background: var(--danger);
  color: #fff;
  box-shadow: 0 4px 6px rgba(239, 68, 68, 0.2);
}

/* ——————————————————————————————————————
   CÁMARA & FIRMA
—————————————————————————————————————— */
.media-setup-row {
  display: flex;
  gap: 1.5rem;
}

.media-box {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--brand-gray-10);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.5rem;
}

.camera-preview-container {
  width: 100%;
  height: 200px;
  background: var(--brand-gray-100);
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.camera-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--brand-gray-40);
}

.camera-preview {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}

.photo-overlay {
  position: absolute;
  top: 5%; left: 5%;
  width: 90%; height: 90%;
  border: 1.5px dashed rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  pointer-events: none;
  display: none;
}

.blinking-rec {
  position: absolute;
  top: 10px; right: 10px;
  width: 10px; height: 10px;
  background: var(--danger);
  border-radius: 50%;
  animation: blink 1s infinite alternate;
  display: none;
}

@keyframes blink {
  from { opacity: 0.3; }
  to { opacity: 1; }
}

.signature-canvas-container {
  width: 100%; height: 200px;
  background: #ffffff;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--brand-gray-40);
}

.signature-canvas {
  width: 100%; height: 100%;
  cursor: crosshair;
}

.media-actions {
  margin-top: 1.25rem;
  display: flex;
  gap: 0.75rem;
  width: 100%;
}

.media-actions button {
  flex: 1;
  padding: 0.6rem;
  font-size: 0.85rem;
}

/* ——————————————————————————————————————
   GAFETE DIGITAL
—————————————————————————————————————— */
.badge-result-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 1.5rem auto;
  max-width: 440px;
}

.badge-card {
  background: #ffffff;
  color: var(--brand-gray-100);
  border-radius: var(--radius-lg);
  width: 100%;
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--brand-gray-20);
  position: relative;
  overflow: hidden;
}

.badge-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 6px;
  background: var(--brand-blue-100);
}

.badge-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid var(--brand-gray-10);
  padding-bottom: 0.75rem;
  margin-bottom: 1.25rem;
}

.badge-brand-text {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--brand-blue-100);
}

.badge-type {
  font-size: 0.65rem;
  background: var(--brand-blue-10);
  color: var(--brand-blue-100);
  padding: 0.3rem 0.75rem;
  border-radius: 30px;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.badge-body {
  display: flex;
  gap: 1.5rem;
}

.badge-photo-container {
  width: 100px; height: 100px;
  border-radius: var(--radius-sm);
  background: var(--brand-gray-10);
  overflow: hidden;
  border: 1px solid var(--brand-gray-20);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.badge-photo-container img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.badge-photo-container svg {
  width: 40px; height: 40px;
  color: var(--brand-gray-40);
}

.badge-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.badge-visitor-name {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--brand-gray-100);
  line-height: 1.2;
}

.badge-meta {
  font-size: 0.8rem;
  margin-bottom: 0.2rem;
}

.badge-label {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--brand-gray-60);
  text-transform: uppercase;
  font-size: 0.55rem;
  letter-spacing: 0.05em;
  display: block;
}

.badge-value {
  font-size: 0.85rem;
  color: var(--brand-gray-100);
  font-weight: 600;
}

.badge-footer {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--brand-gray-40);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.badge-qr-container {
  width: 65px; height: 65px;
  background: #ffffff;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--brand-gray-20);
}

.badge-signature-image {
  max-height: 35px; max-width: 130px;
  object-fit: contain;
}

/* ——————————————————————————————————————
   TOASTS
—————————————————————————————————————— */
.toast-container {
  position: fixed;
  top: 90px; right: 25px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  color: var(--text-primary);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transform: translateX(120%);
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.1);
  min-width: 300px;
  font-size: 0.9rem;
  font-weight: 500;
}

.toast.show { transform: translateX(0); }

.toast-success { border-left: 4px solid var(--brand-teal-100); }
.toast-error { border-left: 4px solid var(--danger); }
.toast-info { border-left: 4px solid var(--brand-blue-100); }

/* ——————————————————————————————————————
   DASHBOARD — Métricas y Gráficos
—————————————————————————————————————— */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.metric-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
}

.metric-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.metric-icon {
  width: 54px; height: 54px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.metric-icon.green { background: var(--brand-teal-10); color: var(--brand-teal-100); }
.metric-icon.orange { background: var(--brand-blue-10); color: var(--brand-blue-100); }
.metric-icon.cyan { background: var(--brand-teal-20); color: var(--brand-teal-100); }
.metric-icon.purple { background: var(--brand-gray-10); color: var(--brand-gray-100); }

.metric-info h3 {
  font-family: var(--font-display);
  font-size: 0.7rem;
  color: var(--brand-gray-60);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
}

.metric-value {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--brand-gray-100);
  margin-top: 0.2rem;
}

/* Gráficos */
.charts-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.chart-container {
  height: 250px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 1rem;
}

/* ——————————————————————————————————————
   TABLAS CORPORATIVAS
—————————————————————————————————————— */
.section-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--brand-gray-100);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.section-title span {
  font-size: 0.75rem;
  background: var(--brand-blue-10);
  padding: 0.25rem 0.75rem;
  border-radius: 30px;
  color: var(--brand-blue-100);
  border: 1px solid var(--brand-blue-20);
  font-weight: 700;
}

.filter-bar {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.filter-input { flex: 1; min-width: 200px; }

.table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

th, td {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--brand-gray-10);
}

th {
  background: var(--brand-gray-10);
  color: var(--brand-gray-80);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  font-family: var(--font-display);
}

tr:last-child td { border-bottom: none; }

tr:hover td {
  background: var(--brand-gray-10);
}

.avatar-cell {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.visitor-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--brand-gray-20);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.visitor-avatar img {
  width: 100%; height: 100%;
  object-fit: cover;
}

/* ——————————————————————————————————————
   STATUS BADGES
—————————————————————————————————————— */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  border-radius: 30px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-family: var(--font-display);
}

.status-badge::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
}

.status-badge.active {
  background: var(--brand-teal-10);
  color: var(--brand-teal-100);
}
.status-badge.active::before { background: var(--brand-teal-80); }

.status-badge.completed {
  background: var(--brand-gray-10);
  color: var(--brand-gray-80);
}
.status-badge.completed::before { background: var(--brand-gray-60); }

.status-badge.preregistered {
  background: var(--brand-blue-10);
  color: var(--brand-blue-100);
}
.status-badge.preregistered::before { background: var(--brand-blue-80); }

/* ——————————————————————————————————————
   MODALES
—————————————————————————————————————— */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(46, 45, 44, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-container {
  background: #ffffff;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  max-width: 540px;
  width: 92%;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  animation: scaleUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.modal-container::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 4px;
  background: var(--brand-blue-100);
}

@keyframes scaleUp {
  from { transform: scale(0.95) translateY(10px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}

.modal-header {
  padding: 1.25rem 1.75rem;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--brand-gray-10);
}

.modal-header h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--brand-gray-100);
}

.close-modal-btn {
  background: transparent;
  border: none;
  color: var(--brand-gray-60);
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  transition: var(--transition-fast);
}

.close-modal-btn:hover {
  color: var(--brand-gray-100);
}

.modal-body { padding: 1.75rem; }

/* ——————————————————————————————————————
   PANEL DE ANFITRIONES
—————————————————————————————————————— */
.hosts-flex { display: flex; gap: 1.5rem; }
.hosts-list-card { flex: 2; }
.add-host-card { flex: 1; }

.host-grid-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.host-item-card {
  background: var(--brand-gray-10);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  position: relative;
  transition: var(--transition-base);
}

.host-item-card:hover {
  border-color: var(--brand-gray-40);
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

.host-item-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-primary);
}

.host-item-role {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.host-item-tag {
  align-self: flex-start;
  font-size: 0.65rem;
  background: var(--brand-blue-10);
  color: var(--brand-blue-100);
  padding: 0.2rem 0.6rem;
  border-radius: 30px;
  margin-top: 0.35rem;
  font-weight: 700;
  border: 1px solid var(--brand-blue-20);
}

.host-delete-btn {
  position: absolute;
  top: 10px; right: 10px;
  background: transparent;
  border: none;
  color: #fca5a5;
  cursor: pointer;
  font-size: 1rem;
  transition: var(--transition-fast);
}

.host-delete-btn:hover { color: var(--danger); }

/* ——————————————————————————————————————
   EQUIPOS — Radio Buttons Premium
—————————————————————————————————————— */
.radio-group {
  display: flex;
  gap: 1rem;
}

.radio-btn-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.25rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: var(--brand-gray-10);
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-base);
}

.radio-btn-label:has(input:checked) {
  background: var(--brand-blue-10);
  border-color: var(--brand-blue-60);
  color: var(--brand-blue-100);
}

.radio-btn-label input[type="radio"] {
  width: 16px; height: 16px;
  accent-color: var(--brand-blue-100);
}

/* ——————————————————————————————————————
   IMPRESIÓN DE GAFETE
—————————————————————————————————————— */
@media print {
  body * { visibility: hidden; }
  .badge-card, .badge-card * { visibility: visible; }
  .badge-card {
    position: absolute;
    left: 0; top: 0;
    width: 90mm;
    box-shadow: none;
    border: 1.5px solid #000;
  }
  .btn { display: none !important; }
}

/* ——————————————————————————————————————
   RESPONSIVE
—————————————————————————————————————— */
@media (max-width: 1024px) {
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
  .hosts-flex { flex-direction: column-reverse; }
}

@media (max-width: 768px) {
  header.main-header {
    padding: 1rem 1.25rem;
    height: auto;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
  
  .system-nav {
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.25rem;
  }

  .nav-btn {
    flex: 1 1 auto;
    justify-content: center;
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
  }

  .view-panel { padding: 1.5rem 1rem; }
  .form-grid { grid-template-columns: 1fr; }
  .form-group-full { grid-column: span 1; }
  .media-setup-row { flex-direction: column; }
  .charts-row { grid-template-columns: 1fr; }
  .kiosk-actions { flex-direction: column; max-width: 100%; }
  .kiosk-welcome h2 { font-size: 2.2rem; }
  .host-grid-list { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .dashboard-grid { grid-template-columns: 1fr; gap: 1rem; }
  
  .metric-card {
    padding: 1rem 1.25rem;
    gap: 1rem;
  }
  
  .metric-icon {
    width: 44px;
    height: 44px;
    font-size: 1.25rem;
  }

  .metric-value {
    font-size: 1.5rem;
  }

  .kiosk-welcome {
    padding: 2.5rem 1.25rem;
    margin: 1.5rem auto;
  }

  .kiosk-welcome h2 {
    font-size: 1.75rem;
  }

  .kiosk-welcome p {
    font-size: 0.95rem;
    margin-bottom: 2rem;
  }

  .badge-card {
    padding: 1.25rem;
  }

  .badge-body {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
  }

  .badge-details {
    align-items: center;
  }

  .badge-photo-container {
    width: 90px;
    height: 90px;
  }

  .badge-footer {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
  }

  .badge-qr-container {
    width: 80px;
    height: 80px;
  }
  
  .modal-container {
    border-radius: var(--radius-lg);
  }

  .modal-header {
    padding: 1rem 1.25rem;
  }

  .modal-body {
    padding: 1.25rem;
  }

  .btn {
    padding: 0.75rem 1.25rem;
    font-size: 0.85rem;
  }
}
