/* ==========================================================================
   REPTARDOCS - ESTILOS OFICIALES Y REFINADOS (TEMA ROJO PROFESIONAL)
   ========================================================================== */

/* 1. VARIABLES DE COLOR Y SOMBRAS LIMPIAS (SIN GLOW EXAGERADO) */
:root,
[data-theme="light"] {
  --primary: #6b1022 !important;
  --primary-dark: #500b19 !important;
  --primary-hover: #82142a !important;
  --primary-gradient: linear-gradient(135deg, #82142a 0%, #6b1022 100%) !important;
  --primary-glow: rgba(107, 16, 34, 0.15) !important;
  --primary-light: rgba(107, 16, 34, 0.06) !important;
  --border-highlight: rgba(107, 16, 34, 0.35) !important;
  --accent-green: #10b981;
  --accent-green-bg: rgba(16, 185, 129, 0.08);
}



/* 2. LOGO Y NAVBAR */
.brand-logo {
  display: flex !important;
  align-items: center !important;
  gap: 0.65rem !important;
  font-weight: 800 !important;
  font-size: 1.35rem !important;
  color: var(--text) !important;
  text-decoration: none !important;
}

.brand-logo .logo-img {
  width: 38px !important;
  height: 38px !important;
  object-fit: contain !important;
  image-rendering: -webkit-optimize-contrast !important;
}

.brand-logo .logo-text {
  font-weight: 800 !important;
  letter-spacing: -0.5px !important;
  font-size: 1.35rem !important;
  color: var(--text) !important;
}

.brand-logo .logo-accent {
  color: var(--primary) !important;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--primary) !important;
}

.nav-donate-link {
  color: var(--primary) !important;
  border: 1px solid rgba(107, 16, 34, 0.3) !important;
  background: rgba(107, 16, 34, 0.05) !important;
  border-radius: 9999px !important;
  padding: 5px 14px !important;
  transition: all 0.2s ease !important;
}

.nav-donate-link:hover {
  background: var(--primary) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(107, 16, 34, 0.2) !important;
}

.nav-dropdown-btn {
  background: var(--bg-card) !important;
  border: 1px solid var(--border) !important;
  color: var(--text) !important;
  font-size: 0.88rem !important;
  font-weight: 700 !important;
  padding: 7px 14px !important;
  border-radius: 9999px !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04) !important;
  transition: all 0.2s ease !important;
}

.nav-dropdown-btn:hover,
.nav-dropdown.open .nav-dropdown-btn {
  background: var(--primary) !important;
  color: #ffffff !important;
  border-color: var(--primary) !important;
  box-shadow: 0 2px 8px rgba(107, 16, 34, 0.2) !important;
}

.dropdown-item:hover {
  background: rgba(107, 16, 34, 0.06) !important;
  border-color: rgba(107, 16, 34, 0.25) !important;
}

.theme-btn:hover {
  border-color: var(--primary) !important;
  color: var(--primary) !important;
}

/* 3. BOTONES (SOMBRAS SUTILES, SIN BRILLO ARTIFICIAL) */
.btn-primary,
.btn.btn-primary {
  background: var(--primary) !important;
  border: 1px solid var(--primary-dark) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(107, 16, 34, 0.2) !important;
  transition: transform 0.15s ease, background 0.15s ease !important;
}

.btn-primary:hover,
.btn.btn-primary:hover {
  background: var(--primary-hover) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(107, 16, 34, 0.25) !important;
}

.btn-secondary.btn-outline,
.btn.btn-outline {
  border: 1.5px solid var(--primary) !important;
  color: var(--primary) !important;
  background: transparent !important;
  transition: all 0.15s ease !important;
}

.btn-secondary.btn-outline:hover,
.btn.btn-outline:hover {
  background: var(--primary) !important;
  color: #ffffff !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 2px 8px rgba(107, 16, 34, 0.15) !important;
}

/* 4. HERO SECTION */
.hero-brand-presentation {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
}

.hero-main-logo {
  width: 320px !important;
  height: 320px !important;
  max-width: 90vw !important;
  object-fit: contain !important;
  image-rendering: -webkit-optimize-contrast !important;
  filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.12)) !important;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

.hero-main-logo:hover {
  transform: scale(1.05) translateY(-4px) !important;
}

.hero-badge {
  border: 1px solid rgba(107, 16, 34, 0.3) !important;
  background: rgba(107, 16, 34, 0.06) !important;
}

.hero-badge span {
  color: var(--primary) !important;
  font-weight: 700 !important;
}

.hero-stats .stat-num {
  color: var(--primary) !important;
}

.hero-donate-banner {
  border-left: 3px solid var(--primary) !important;
  background: rgba(107, 16, 34, 0.04) !important;
  border-radius: 8px !important;
}

.hero-donate-icon {
  color: var(--primary) !important;
}

.btn-hero-donate {
  background: var(--primary) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(107, 16, 34, 0.2) !important;
}

.btn-hero-donate:hover {
  background: var(--primary-hover) !important;
  transform: translateY(-1px) !important;
}

/* 5. SELECTOR DE NIVELES (NÍTIDO Y LIMPIO, SIN NEÓN) */
.level-selector-section {
  margin: 20px auto 26px auto;
  width: 100%;
}

.level-selector-title {
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 14px;
}

.level-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

@media (max-width: 992px) {
  .level-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 520px) {
  .level-grid {
    grid-template-columns: 1fr;
  }
}

.level-card {
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 14px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.level-card:hover {
  border-color: rgba(107, 16, 34, 0.45) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
}

.level-card.active {
  border: 2px solid var(--primary) !important;
  background: rgba(107, 16, 34, 0.04) !important;
  box-shadow: 0 4px 18px rgba(107, 16, 34, 0.12) !important;
}

.docs-size-badge {
  background: rgba(16, 185, 129, 0.1);
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  padding: 8px 16px;
  border-radius: 12px;
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  min-width: 170px;
  transition: all 0.2s ease;
}

.level-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.level-name {
  font-weight: 800;
  font-size: 1rem;
  color: var(--text);
}

.level-badge {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  text-transform: uppercase;
}

.level-badge.rec {
  background: var(--primary) !important;
  color: #fff !important;
}

.level-badge.ext {
  background: #f59e0b;
  color: #000;
}

.level-badge.low {
  background: var(--accent-green);
  color: #fff;
}

.level-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* 6. DROPZONE (LIMPIO Y ELEGANTE) */
.dropzone-container {
  width: 100%;
  margin: 0 auto 28px auto;
}

.dropzone {
  border: 2px dashed rgba(107, 16, 34, 0.35) !important;
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 48px 24px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.dropzone.has-files {
  padding: 22px 24px 24px 24px !important;
  cursor: default !important;
  text-align: left !important;
  background: var(--bg-card) !important;
  border: 2px dashed rgba(107, 16, 34, 0.45) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04) !important;
}

.dropzone.has-files:hover {
  border-color: var(--primary) !important;
}

.dropzone.has-files .staged-section {
  display: block !important;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

.staged-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-add-more-files {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(107, 16, 34, 0.08);
  color: var(--primary);
  border: 1px solid rgba(107, 16, 34, 0.28);
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-add-more-files:hover {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  transform: translateY(-1px);
}

.dropzone:hover,
.dropzone.dragover {
  border-color: var(--primary) !important;
  background: rgba(107, 16, 34, 0.03) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05) !important;
}

.dropzone-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px auto;
  border-radius: 16px;
  background: rgba(107, 16, 34, 0.08) !important;
  color: var(--primary) !important;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
}

.dropzone:hover .dropzone-icon {
  transform: translateY(-2px);
}

.dropzone-title {
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 6px;
  color: var(--text);
}

.dropzone-subtitle {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-bottom: 18px;
}

.dropzone-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary) !important;
  color: #fff !important;
  padding: 12px 26px;
  border-radius: 9999px;
  font-weight: 800;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(107, 16, 34, 0.25) !important;
  transition: transform 0.15s ease, background 0.15s ease;
}

.dropzone-btn:hover {
  background: var(--primary-hover) !important;
  transform: translateY(-1px);
}

.dropzone-tags {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.format-tag {
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-muted);
}

/* 7. BARRA DE ESTADÍSTICAS */
.stats-summary-bar {
  width: 100%;
  margin: 0 auto 24px auto;
  background: var(--bg-card) !important;
  border: 1.5px solid rgba(107, 16, 34, 0.3) !important;
  border-radius: var(--radius);
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.stats-info {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
}

.stat-val {
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--text);
}

.stat-val.saving-highlight {
  color: var(--accent-green);
}

.btn-download-all {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-green);
  color: #fff;
  padding: 11px 22px;
  border-radius: 8px;
  font-weight: 800;
  font-size: 0.92rem;
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
  transition: transform 0.15s ease, background 0.15s ease;
}

.btn-download-all:hover {
  background: #059669;
  transform: translateY(-1px);
}

/* ETAPA 1: ARCHIVOS EN ESPERA (STAGED) */
.staged-section {
  width: 100%;
  margin: 0 auto 28px auto;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04);
}

.staged-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.staged-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.staged-title-wrap h3 {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text);
}

.btn-text-action {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
}

.btn-text-action:hover {
  color: var(--primary);
  background: rgba(107, 16, 34, 0.05);
}

.staged-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 22px;
}

.staged-item-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
  gap: 12px;
  transition: border-color 0.15s ease;
}

.staged-item-card:hover {
  border-color: rgba(107, 16, 34, 0.3);
}

.staged-item-info {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}

.staged-item-name {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.staged-item-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.staged-badge-ready {
  background: rgba(107, 16, 34, 0.08);
  color: var(--primary);
  border: 1px solid rgba(107, 16, 34, 0.25);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 700;
}

.staged-cta-wrap {
  display: flex;
  justify-content: center;
}

.btn-generate-compress {
  width: 100%;
  max-width: 440px;
  padding: 14px 28px !important;
  font-size: 1.05rem !important;
  font-weight: 800 !important;
  border-radius: 12px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  box-shadow: 0 4px 14px rgba(107, 16, 34, 0.25) !important;
  cursor: pointer !important;
}

.btn-generate-compress:disabled {
  opacity: 0.6;
  cursor: not-allowed !important;
  transform: none !important;
}

/* ETAPA 2: RESULTADOS */
.results-section {
  width: 100%;
  margin: 0 auto 36px auto;
}

.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.results-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text);
}

/* 8. LISTA DE ARCHIVOS */
.files-list-section {
  width: 100%;
  margin: 0 auto 36px auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.file-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all 0.15s ease;
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
  width: 100%;
}

.file-card:hover {
  border-color: rgba(107, 16, 34, 0.3);
}

.file-card.completed {
  border-color: rgba(16, 185, 129, 0.35);
}

.file-card-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  flex-wrap: wrap;
  box-sizing: border-box;
}

.file-main-info {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1 1 240px;
  min-width: 200px;
  max-width: 100%;
  box-sizing: border-box;
}

.file-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.78rem;
  text-transform: uppercase;
  flex-shrink: 0;
}

.file-icon-box.pdf {
  background: rgba(107, 16, 34, 0.1);
  color: #6b1022;
  border: 1px solid rgba(107, 16, 34, 0.25);
}

.file-icon-box.image {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.25);
}

.file-meta {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.file-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 3px;
  display: block;
  max-width: 100%;
}

.file-sizes {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.file-saving-badge {
  background: var(--accent-green-bg);
  color: var(--accent-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 4px 8px;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.76rem;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.file-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
  flex: 0 1 auto;
  max-width: 100%;
}

.btn-file-download {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--primary) !important;
  color: #fff !important;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(107, 16, 34, 0.2);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-file-download:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(107, 16, 34, 0.3);
}

.btn-save-recents {
  padding: 8px 14px;
  background: #10b981 !important;
  color: #ffffff !important;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.85rem;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  flex-shrink: 0;
  transition: transform 0.15s ease, background 0.15s ease;
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
}

.btn-save-recents:hover {
  background: #059669 !important;
  transform: translateY(-1px);
}

.btn-file-remove {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-file-remove:hover {
  color: #6b1022;
  border-color: #6b1022;
}

.file-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: var(--primary) !important;
  transition: width 0.2s ease;
  z-index: 2;
}

/* PIPELINE Y FLUJO ENCADENADO DENTRO DE LA TARJETA */
.pipeline-chain-box {
  width: 100%;
  margin-top: 4px;
  padding: 10px 14px;
  background: rgba(16, 185, 129, 0.06);
  border: 1px dashed rgba(16, 185, 129, 0.35);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  box-sizing: border-box;
}

[data-theme="dark"] .pipeline-chain-box,
body.dark-theme .pipeline-chain-box {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.4);
}

.pipeline-chain-title {
  font-size: 0.78rem;
  font-weight: 700;
  color: #10b981;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.pipeline-chain-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.pipeline-chain-btn {
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border, #cbd5e1);
  color: var(--text, #1e293b);
  font-size: 0.76rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 7px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.pipeline-chain-btn:hover {
  border-color: #10b981;
  color: #10b981;
  transform: translateY(-1px);
}

/* 9. FORMATOS COMPATIBLES */
.formats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 24px;
}

.format-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 18px;
  text-align: center;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.format-card:hover {
  transform: translateY(-2px);
  border-color: rgba(107, 16, 34, 0.35) !important;
}

.format-card-icon {
  width: 46px;
  height: 46px;
  margin: 0 auto 12px auto;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 0.85rem;
}

.format-card-icon.pdf-badge {
  background: rgba(107, 16, 34, 0.1);
  color: #6b1022;
  border: 1px solid rgba(107, 16, 34, 0.25);
}

.format-card-icon.jpg-badge {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.25);
}

.format-card-icon.png-badge {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.format-card-icon.webp-badge {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.format-card h3 {
  font-size: 1.05rem;
  font-weight: 800;
  margin-bottom: 6px;
  color: var(--text);
}

.format-card p {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* 10. SEGURIDAD Y PRIVACIDAD */
.security-banner-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 24px 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

.security-icon-circle {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(107, 16, 34, 0.08) !important;
  color: var(--primary) !important;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid rgba(107, 16, 34, 0.2);
}

/* 11. FAQ ACCORDIONS (LIMPIO, SIN NEÓN) */
.faq-container {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.faq-item {
  padding: 1.25rem 1.4rem !important;
  cursor: pointer;
  border: 1px solid var(--border) !important;
  background: var(--bg-card) !important;
  border-radius: var(--radius) !important;
  transition: all 0.25s ease !important;
}

.faq-item:hover {
  border-color: var(--primary) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05) !important;
}

.faq-item.open {
  border-color: rgba(107, 16, 34, 0.35) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
}

.faq-question {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  font-weight: 700 !important;
  font-size: 1.02rem !important;
  color: var(--text) !important;
  gap: 12px !important;
  user-select: none !important;
}

.faq-question:hover {
  color: var(--primary) !important;
}

.faq-arrow {
  font-size: 0.8rem !important;
  color: var(--text-muted) !important;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), color 0.2s ease !important;
  flex-shrink: 0 !important;
}

.faq-item.open .faq-arrow {
  transform: rotate(180deg) !important;
  color: var(--primary) !important;
}

.faq-answer {
  max-height: 0 !important;
  overflow: hidden !important;
  opacity: 0 !important;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.25s ease, margin-top 0.25s ease !important;
  color: var(--text-muted) !important;
  font-size: 0.92rem !important;
  line-height: 1.65 !important;
  margin-top: 0 !important;
}

.faq-item.open .faq-answer {
  max-height: 800px !important;
  opacity: 1 !important;
  margin-top: 0.85rem !important;
  padding-top: 0.5rem !important;
  border-top: 1px dashed var(--border) !important;
}

/* 12. SECCIÓN DE DONACIONES PAYPAL (ESTILO LIMPIO Y CENTRADO) */
.donate-badge {
  background: rgba(107, 16, 34, 0.08) !important;
  color: var(--primary) !important;
  border: 1px solid rgba(107, 16, 34, 0.25) !important;
}

.donate-chip.active {
  background: var(--primary) !important;
  border-color: var(--primary) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 6px rgba(107, 16, 34, 0.2) !important;
}

.donate-chip:hover {
  border-color: var(--primary) !important;
  color: var(--primary) !important;
}

.donate-custom-input-wrap:focus-within {
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px rgba(107, 16, 34, 0.15) !important;
}

.currency-prefix,
.currency-suffix {
  color: var(--primary) !important;
}

/* 13. PUBLICIDAD */
.ad-label {
  color: var(--primary) !important;
}

.ad-placeholder:hover {
  border-color: rgba(107, 16, 34, 0.25) !important;
}

.ad-anchor-close:hover {
  color: var(--primary) !important;
}

/* 14. MODAL INTERSTICIAL Y COOKIES */
.ad-popup-container {
  border-color: var(--border-highlight) !important;
}

.cookie-banner {
  border-top: 1px solid var(--border-highlight) !important;
}

#cookie-accept-btn {
  background: var(--primary) !important;
  box-shadow: 0 2px 8px rgba(107, 16, 34, 0.2) !important;
}

/* 15. BOTÓN FLOTANTE DE CONTACTO */
.floating-contact-btn {
  background: var(--primary) !important;
  box-shadow: 0 4px 14px rgba(107, 16, 34, 0.3) !important;
}

.floating-contact-btn:hover {
  background: var(--primary-hover) !important;
  box-shadow: 0 6px 18px rgba(107, 16, 34, 0.35) !important;
}

.floating-contact-card {
  border-color: var(--border-highlight) !important;
}

.btn-copy-email:hover {
  color: var(--primary) !important;
}

.contact-mailto-btn {
  background: var(--primary) !important;
}

/* 16. FOOTER */
.footer-logo-img {
  width: 28px !important;
  height: 28px !important;
  object-fit: contain !important;
}

.footer-links a:hover {
  color: var(--primary) !important;
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .formats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .level-grid {
    grid-template-columns: 1fr;
  }
  .formats-grid {
    grid-template-columns: 1fr;
  }
  .dropzone {
    padding: 34px 16px;
  }
  .stats-summary-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .btn-download-all {
    justify-content: center;
  }
  .file-card {
    padding: 14px 14px;
    gap: 10px;
  }
  .file-card-main {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .file-main-info {
    width: 100%;
    min-width: 0;
  }
  .file-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 8px;
  }
  .pipeline-chain-box {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .pipeline-chain-actions {
    width: 100%;
    justify-content: flex-start;
  }
  .security-banner-box {
    flex-direction: column;
    text-align: center;
  }
}

/* ==========================================================================
   CARACTERÍSTICAS PREMIUM: MINIATURAS, COMPARADOR, HISTORIAL Y PURGA RAM
   ========================================================================== */

/* 1. MINIATURAS REALES EN LAS LISTAS */
.file-thumbnail-wrap {
  width: 46px;
  height: 46px;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.file-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.file-thumb-badge {
  position: absolute;
  bottom: 2px;
  right: 2px;
  font-size: 0.62rem;
  font-weight: 900;
  padding: 1px 4px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.75);
  color: #fff;
  line-height: 1.1;
  text-transform: uppercase;
}

/* 2. BOTONES DE ACCIÓN EN TARJETA Y COMPARADOR */
.btn-compare-action {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: transparent !important;
  color: var(--primary) !important;
  border: 1.5px solid var(--primary) !important;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-compare-action:hover {
  background: var(--primary) !important;
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px var(--primary-glow) !important;
}

.btn-file-copy {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(107, 16, 34, 0.08) !important;
  color: var(--primary) !important;
  border: 1.5px solid rgba(107, 16, 34, 0.3) !important;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-file-copy:hover {
  background: var(--primary) !important;
  color: #ffffff !important;
  border-color: var(--primary) !important;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px var(--primary-glow) !important;
}

.dropzone-paste-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.dropzone-paste-hint kbd {
  background: var(--bg-card);
  border: 1px solid var(--border);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  padding: 1px 6px;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text);
}

/* 3. MODAL COMPARADOR VISUAL ANTES VS DESPUÉS (SPLIT-SLIDER) */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: modalFadeIn 0.2s ease;
}

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

.compare-modal-content {
  width: 100%;
  max-width: 900px;
  max-height: 92vh;
  background: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  position: relative;
}

.compare-modal-header {
  padding: 16px 22px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.compare-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 600px;
}

.compare-meta-badges {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.compare-meta-badges .tag-meta {
  font-weight: 700;
}

.compare-meta-badges .tag-comp {
  color: var(--text);
}

.compare-meta-badges .tag-saving {
  background: var(--accent-green-bg);
  color: var(--accent-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 1px 7px;
  border-radius: 4px;
  font-weight: 800;
  font-size: 0.74rem;
}

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

.modal-close-btn:hover {
  background: rgba(107, 16, 34, 0.08);
  color: var(--primary);
}

/* VISOR INTERACTIVO DEL SLIDER */
.compare-viewport-wrap {
  flex: 1;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #090d13;
  padding: 16px;
  min-height: 320px;
  max-height: 65vh;
}

.compare-viewport {
  position: relative;
  max-width: 100%;
  max-height: 60vh;
  user-select: none;
  -webkit-user-select: none;
  cursor: col-resize;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  line-height: 0;
}

.compare-layer {
  display: block;
  max-width: 100%;
  max-height: 60vh;
  object-fit: contain;
  pointer-events: none;
}

.compare-before-clip {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%);
  will-change: clip-path;
}

.compare-before-clip .compare-layer {
  width: 100%;
  height: 100%;
}

.compare-floating-label {
  position: absolute;
  top: 12px;
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  z-index: 5;
  pointer-events: none;
}

.compare-floating-label.label-left {
  left: 12px;
}

.compare-floating-label.label-right {
  right: 12px;
}

/* LÍNEA Y MANIJA CENTRAL DEL COMPARADOR */
.compare-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 4px;
  margin-left: -2px;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.handle-line {
  flex: 1;
  width: 2px;
  background: #ffffff;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.6);
}

.handle-pill {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--primary);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  border: 2px solid #ffffff;
  flex-shrink: 0;
}

.compare-modal-footer {
  padding: 14px 22px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--bg);
}

.compare-instructions {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0;
}

/* 4. HISTORIAL ACUMULATIVO DE AHORRO (LOCALSTORAGE) */
.historical-stats-card {
  width: 100%;
  background: var(--bg-card);
  border: 1px dashed rgba(16, 185, 129, 0.4);
  border-radius: var(--radius);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

.historical-stats-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.historical-icon {
  font-size: 1.5rem;
}

.historical-text {
  font-size: 0.9rem;
  color: var(--text);
  line-height: 1.4;
}

.hist-number {
  color: var(--accent-green);
  font-weight: 800;
}

.btn-reset-hist {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-reset-hist:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* 5. PURGA DE MEMORIA RAM */
.stats-actions-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-purge-ram {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent !important;
  color: var(--text-muted) !important;
  border: 1px solid var(--border) !important;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-purge-ram:hover {
  border-color: var(--primary) !important;
  color: var(--primary) !important;
  background: rgba(107, 16, 34, 0.04) !important;
}

.btn-purge-ram-sec {
  margin-top: 14px;
}

@media (max-width: 768px) {
  .nav-links.active,
  .nav-links.open {
    display: flex !important;
  }
}

