/* ==========================================================================
   Generador de listas de equipaje inteligente y peso para vuelos
   fijate.com - Estándares canónicos y diseño responsive
   ========================================================================== */

:root {
  /* Paleta base en modo oscuro */
  --bg-body: #0d1117;
  --bg-surface: #161b22;
  --bg-surface-elevated: #21262d;
  --bg-surface-hover: #30363d;
  --text-main: #f0f6fc;
  --text-muted: #8b949e;
  --border-subtle: #30363d;
  --border-highlight: #484f58;

  /* Colores funcionales y de estado */
  --accent-primary: #388bfd;
  --accent-hover: #58a6ff;
  --accent-green: #2ea043;
  --accent-green-bg: rgba(46, 160, 67, 0.15);
  --accent-orange: #d29922;
  --accent-orange-bg: rgba(210, 153, 34, 0.15);
  --accent-red: #f85149;
  --accent-red-bg: rgba(248, 81, 73, 0.15);
  --accent-cyan: #39c5bb;
  --accent-purple: #a371f7;

  /* Badges temáticas */
  --badge-ropa: #388bfd;
  --badge-aseo: #39c5bb;
  --badge-electronica: #a371f7;
  --badge-documentos: #e3b341;
  --badge-botiquin: #f85149;
  --badge-accesorios: #56d364;

  /* Radio de curvatura y sombras */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --shadow-card: 0 4px 16px rgba(0, 0, 0, 0.35);
  --shadow-modal: 0 16px 48px rgba(0, 0, 0, 0.65);
}

[data-theme="light"] {
  --bg-body: #f6f8fa;
  --bg-surface: #ffffff;
  --bg-surface-elevated: #f3f4f6;
  --bg-surface-hover: #e5e7eb;
  --text-main: #1f2328;
  --text-muted: #656d76;
  --border-subtle: #d0d7de;
  --border-highlight: #afb8c1;

  --accent-primary: #0969da;
  --accent-hover: #0854ad;
  --accent-green: #1a7f37;
  --accent-green-bg: rgba(26, 127, 55, 0.1);
  --accent-orange: #9a6700;
  --accent-orange-bg: rgba(154, 103, 0, 0.1);
  --accent-red: #cf222e;
  --accent-red-bg: rgba(207, 34, 46, 0.1);
  --accent-cyan: #057a70;
  --accent-purple: #8250df;

  --shadow-card: 0 2px 10px rgba(0, 0, 0, 0.08);
  --shadow-modal: 0 12px 36px rgba(0, 0, 0, 0.18);
}

/* Reset y base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-body);
  color: var(--text-main);
  line-height: 1.5;
  overflow-x: clip;
  width: 100%;
  max-width: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.25;
}

.mono-num {
  font-family: 'JetBrains Mono', monospace;
}

/* Contenedor principal de la herramienta */
.tool-layout {
  max-width: 1200px;
  margin: 1.5rem auto 3rem;
  padding: 0 1rem;
  width: 100%;
}

.tool-with-sidebar {
  display: flex;
  gap: 1.75rem;
  align-items: flex-start;
}

.tool-main-content {
  flex: 1 1 0%;
  min-width: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Tarjeta principal contenedora */
.card-main {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
}

@media (max-width: 640px) {
  .card-main {
    padding: 1rem;
    border-radius: var(--radius-md);
  }
  .tool-layout {
    margin: 1rem auto 2rem;
    padding: 0 0.75rem;
  }
}

/* ==========================================================================
   Sección 1: Cuestionario rápido del viaje (Wizard compacto)
   ========================================================================== */
.trip-setup-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.setup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
}

.setup-title {
  font-size: 1.15rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.setup-title svg {
  color: var(--accent-primary);
}

.btn-toggle-setup {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.75rem;
  font-size: 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.2s ease;
  min-height: 36px;
}

.btn-toggle-setup:hover {
  background: var(--bg-surface-hover);
  color: var(--text-main);
  border-color: var(--border-highlight);
}

.setup-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}

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

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.form-label span.label-sub {
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--accent-primary);
}

.input-slider-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.range-slider {
  flex: 1 1 0%;
  min-width: 0;
  height: 8px;
  border-radius: 4px;
  background: var(--bg-surface-hover);
  outline: none;
  cursor: pointer;
  accent-color: var(--accent-primary);
}

.days-counter-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1rem;
  font-weight: 700;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--accent-primary);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  min-width: 75px;
  text-align: center;
}

/* Chips y píldoras interactivas */
.chips-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.chip-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  font-size: 0.82rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.15s ease;
  min-height: 38px;
  user-select: none;
}

.chip-btn:hover {
  background: var(--bg-surface-hover);
  border-color: var(--border-highlight);
}

.chip-btn.active {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: #ffffff;
  font-weight: 600;
}

/* Desplegable estándar canónico */
.select-custom {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: 42px;
  min-height: 40px;
  background-color: var(--bg-surface);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0 40px 0 0.85rem;
  font-size: 0.9rem;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
  appearance: none;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%238b949e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

[data-theme="light"] .select-custom {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23656d76' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
}

.select-custom:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(56, 139, 253, 0.25);
}

.select-custom option,
.select-custom optgroup {
  background-color: var(--bg-surface);
  color: var(--text-main);
}

/* Input numérico o texto */
.form-input {
  width: 100%;
  min-height: 40px;
  background: var(--bg-surface);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.85rem;
  font-size: 0.9rem;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(56, 139, 253, 0.25);
}

.setup-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn-primary {
  background: var(--accent-primary);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.65rem 1.25rem;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 40px;
  transition: background 0.15s ease, transform 0.1s ease;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.65rem 1.15rem;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 40px;
  transition: all 0.15s ease;
}

.btn-secondary:hover {
  background: var(--bg-surface-hover);
  border-color: var(--border-highlight);
}

@media (max-width: 640px) {
  .btn-primary, .btn-secondary {
    width: 100%;
  }
}

/* ==========================================================================
   Sección 2: Báscula virtual y Telemetría de peso en cabina
   ========================================================================== */
.weight-dashboard-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: relative;
  overflow: hidden;
}

.weight-dashboard-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-cyan));
}

.weight-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.weight-header-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.1rem;
}

.spec-badge {
  font-size: 0.8rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-sm);
  font-family: 'JetBrains Mono', monospace;
}

/* Medidores visuales */
.weight-metrics-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  align-items: center;
}

.metric-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.metric-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  font-weight: 600;
}

.metric-value-wrapper {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
}

.metric-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1;
}

.metric-unit {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 500;
}

.metric-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Barra de progreso de peso */
.weight-bar-container {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.weight-bar-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.weight-bar-track {
  width: 100%;
  height: 14px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.weight-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--accent-green);
  border-radius: 999px;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.3s ease;
}

.weight-bar-fill.status-warning {
  background: var(--accent-orange);
}

.weight-bar-fill.status-danger {
  background: var(--accent-red);
  animation: pulse-danger 1.5s infinite;
}

@keyframes pulse-danger {
  0% { opacity: 1; }
  50% { opacity: 0.65; }
  100% { opacity: 1; }
}

/* Alerta de sobrepeso o normativa */
.weight-alert-box {
  display: none;
  background: var(--accent-red-bg);
  border: 1px solid var(--accent-red);
  color: var(--text-main);
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  align-items: flex-start;
  gap: 0.75rem;
}

.weight-alert-box.active {
  display: flex;
}

.weight-alert-icon {
  color: var(--accent-red);
  flex-shrink: 0;
  margin-top: 2px;
}

/* Alerta de líquidos < 100 ml */
.liquids-info-strip {
  background: rgba(57, 197, 187, 0.1);
  border: 1px solid var(--accent-cyan);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.85rem;
}

.liquids-info-left {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.liquids-info-left svg {
  color: var(--accent-cyan);
  flex-shrink: 0;
}

.liquids-gauge {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  color: var(--accent-cyan);
}

/* ==========================================================================
   Sección 3: Barra de control y filtros del checklist
   ========================================================================== */
.checklist-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0;
}

.search-input-wrapper {
  position: relative;
  flex: 1 1 240px;
  min-width: 0;
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.search-input {
  width: 100%;
  min-height: 40px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.85rem 0.5rem 2.4rem;
  color: var(--text-main);
  font-size: 0.88rem;
}

.search-input:focus {
  outline: none;
  border-color: var(--accent-primary);
}

.toolbar-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.btn-action-sm {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 40px;
  transition: all 0.15s ease;
}

.btn-action-sm:hover {
  background: var(--bg-surface-hover);
  border-color: var(--border-highlight);
}

/* Pestañas de filtro por estado */
.filter-tabs {
  display: flex;
  gap: 0.35rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
  width: 100%;
}

.filter-tab {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-size: 0.82rem;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.15s ease;
  min-height: 38px;
}

.filter-tab:hover {
  color: var(--text-main);
  border-color: var(--border-highlight);
}

.filter-tab.active {
  background: var(--bg-surface-elevated);
  color: var(--accent-primary);
  border-color: var(--accent-primary);
  font-weight: 600;
}

.tab-badge {
  background: var(--bg-surface-hover);
  color: var(--text-muted);
  font-size: 0.72rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
}

.filter-tab.active .tab-badge {
  background: var(--accent-primary);
  color: #ffffff;
}

/* ==========================================================================
   Sección 4: Categorías y lista reactiva de artículos
   ========================================================================== */
.categories-container {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.category-block {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.category-block:hover {
  border-color: var(--border-highlight);
}

.category-header {
  background: var(--bg-surface-elevated);
  padding: 0.85rem 1.25rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  user-select: none;
  border-bottom: 1px solid var(--border-subtle);
}

.category-title-group {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.category-icon-box {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-surface);
  color: var(--accent-primary);
  border: 1px solid var(--border-subtle);
}

.category-title {
  font-size: 1rem;
  font-weight: 600;
}

.category-progress-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.category-counter {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
}

.category-arrow {
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

.category-block.collapsed .category-arrow {
  transform: rotate(-90deg);
}

.category-block.collapsed .items-list {
  display: none;
}

/* Lista de artículos */
.items-list {
  display: flex;
  flex-direction: column;
  divide-y: 1px solid var(--border-subtle);
}

.item-row {
  display: flex;
  align-items: center;
  padding: 0.85rem 1.25rem;
  gap: 1rem;
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.15s ease;
}

.item-row:last-child {
  border-bottom: none;
}

.item-row:hover {
  background: var(--bg-surface-elevated);
}

.item-row.empaquetado {
  background: rgba(46, 160, 67, 0.04);
}

.item-row.empaquetado .item-name {
  text-decoration: line-through;
  color: var(--text-muted);
}

/* Checkbox accesible grande */
.item-checkbox-wrapper {
  display: flex;
  align-items: center;
  cursor: pointer;
  min-width: 40px;
  min-height: 40px;
  justify-content: center;
}

.item-checkbox {
  appearance: none;
  width: 22px;
  height: 22px;
  border: 2px solid var(--border-highlight);
  border-radius: 6px;
  background: var(--bg-surface);
  cursor: pointer;
  display: grid;
  place-content: center;
  transition: all 0.15s ease;
}

.item-checkbox:hover {
  border-color: var(--accent-primary);
}

.item-checkbox:checked {
  background: var(--accent-green);
  border-color: var(--accent-green);
}

.item-checkbox:checked::before {
  content: "";
  width: 10px;
  height: 6px;
  border-left: 2px solid #ffffff;
  border-bottom: 2px solid #ffffff;
  transform: rotate(-45deg) translate(1px, -1px);
}

.item-content {
  flex: 1 1 0%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.item-title-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.item-name {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-main);
  transition: color 0.15s ease;
}

.badge-pill {
  font-size: 0.7rem;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.badge-pill.pill-liquid {
  background: rgba(57, 197, 187, 0.15);
  color: var(--accent-cyan);
  border: 1px solid rgba(57, 197, 187, 0.3);
}

.badge-pill.pill-warning-iata {
  background: rgba(248, 81, 73, 0.15);
  color: var(--accent-red);
  border: 1px solid rgba(248, 81, 73, 0.3);
}

.badge-pill.pill-puesto {
  background: rgba(56, 139, 253, 0.15);
  color: var(--accent-primary);
  border: 1px solid rgba(56, 139, 253, 0.3);
}

.item-note {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* Controles de cantidad y peso */
.item-meta-controls {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-shrink: 0;
}

.qty-stepper {
  display: flex;
  align-items: center;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.btn-qty {
  background: transparent;
  border: none;
  color: var(--text-muted);
  width: 32px;
  height: 34px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: all 0.1s ease;
}

.btn-qty:hover {
  background: var(--bg-surface-hover);
  color: var(--text-main);
}

.qty-display {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0 0.5rem;
  min-width: 30px;
  text-align: center;
}

.item-weight-display {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  color: var(--text-muted);
  min-width: 65px;
  text-align: right;
}

.item-weight-display.is-worn {
  text-decoration: line-through;
  opacity: 0.6;
}

/* Botón "Llevo puesto" */
.btn-toggle-worn {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-toggle-worn:hover {
  background: var(--bg-surface-hover);
  color: var(--text-main);
}

.btn-toggle-worn.active {
  background: rgba(56, 139, 253, 0.2);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

/* Botón eliminar ítem */
.btn-delete-item {
  background: transparent;
  border: none;
  color: var(--text-muted);
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-delete-item:hover {
  background: var(--accent-red-bg);
  color: var(--accent-red);
}

@media (max-width: 768px) {
  .item-row {
    flex-wrap: wrap;
    padding: 0.75rem;
    gap: 0.6rem;
  }
  .item-content {
    flex: 1 1 calc(100% - 60px);
  }
  .item-meta-controls {
    width: 100%;
    justify-content: space-between;
    padding-left: 48px;
  }
}

/* Estado de lista vacía o sin coincidencias */
.empty-state-box {
  padding: 3rem 1.5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-muted);
}

.empty-state-box svg {
  color: var(--border-highlight);
}

/* ==========================================================================
   Sección 5: Modales nativos (cero alert())
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 1rem;
}

.modal-overlay.active {
  display: flex;
}

.modal-dialog {
  background: var(--bg-surface);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-lg);
  max-width: 500px;
  width: 100%;
  box-shadow: var(--shadow-modal);
  overflow: hidden;
  animation: modal-appear 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

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

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

.modal-title {
  font-size: 1.15rem;
}

.btn-close-modal {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.5rem;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.btn-close-modal:hover {
  background: var(--bg-surface-hover);
  color: var(--text-main);
}

.modal-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.modal-footer {
  padding: 1rem 1.5rem;
  background: var(--bg-surface-elevated);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  flex-wrap: wrap;
}

@media (max-width: 480px) {
  .modal-footer .btn-primary,
  .modal-footer .btn-secondary {
    width: 100%;
  }
}

/* Toast de notificación */
.toast-notice {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--accent-primary);
  color: var(--text-main);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-modal);
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.9rem;
  z-index: 10000;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.toast-notice.show {
  transform: translateY(0);
  opacity: 1;
}

/* ==========================================================================
   Sección 6: Guía didáctica SEO y preguntas frecuentes
   ========================================================================== */
.seo-guide-section {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-top: 1rem;
}

.seo-guide-title {
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: var(--text-main);
}

.seo-guide-lead {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.seo-columns-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.seo-feature-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.seo-feature-title {
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.seo-feature-title svg {
  color: var(--accent-primary);
}

.seo-feature-text {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* Tabla comparativa de aerolíneas */
.seo-table-wrapper {
  overflow-x: auto;
  margin: 1.5rem 0;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}

.seo-airlines-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.88rem;
}

.seo-airlines-table th {
  background: var(--bg-surface-elevated);
  padding: 0.85rem 1rem;
  font-weight: 600;
  color: var(--text-main);
  border-bottom: 1px solid var(--border-subtle);
}

.seo-airlines-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-muted);
}

.seo-airlines-table tr:last-child td {
  border-bottom: none;
}

.seo-airlines-table strong {
  color: var(--text-main);
}

/* Acordeón de FAQs */
.faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.faq-item {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-surface-elevated);
  overflow: hidden;
}

.faq-question {
  padding: 1rem 1.25rem;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  list-style: none;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-icon {
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

.faq-item[open] .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  padding: 0 1.25rem 1.25rem 1.25rem;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ==========================================================================
   Sección 7: Estilos de impresión y exportación PDF (@media print)
   ========================================================================== */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 11pt;
  }

  .app-header,
  .fijate-footer,
  .tool-ad-sidebar,
  .tools-ad-banner-section,
  .checklist-toolbar,
  .btn-toggle-setup,
  .setup-actions,
  .btn-toggle-worn,
  .btn-delete-item,
  .qty-stepper .btn-qty,
  .modal-overlay,
  .toast-notice,
  .seo-guide-section {
    display: none !important;
  }

  .tool-layout {
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .tool-main-content {
    gap: 1rem !important;
  }

  .card-main,
  .trip-setup-card,
  .weight-dashboard-card,
  .category-block {
    border: 1px solid #cccccc !important;
    box-shadow: none !important;
    background: #ffffff !important;
    color: #000000 !important;
  }

  .item-row {
    border-bottom: 1px solid #eeeeee !important;
    page-break-inside: avoid;
    padding: 0.4rem 0.5rem !important;
  }

  .item-checkbox {
    border: 1.5px solid #000000 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .category-header {
    background: #f0f0f0 !important;
    border-bottom: 1px solid #cccccc !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .category-block.collapsed .items-list {
    display: flex !important;
  }
}
