/* ═══════════════════════════════════════════════════
   Merge Caudales — Estilos Modernos Dark Mode
   ═══════════════════════════════════════════════════ */

/* ── Variables ──────────────────────────────────── */
:root {
  --bg-base:        hsl(222, 24%, 7%);
  --bg-surface:     hsl(222, 20%, 10%);
  --bg-raised:      hsl(222, 18%, 13%);
  --bg-card:        hsl(222, 16%, 16%);
  --bg-card-hover:  hsl(222, 16%, 20%);

  --accent-primary: hsl(198, 92%, 52%);
  --accent-hover:   hsl(198, 92%, 62%);
  --accent-glow:    hsla(198, 92%, 52%, 0.28);

  --color-green:    hsl(152, 68%, 46%);
  --color-green-glow: hsla(152, 68%, 46%, 0.25);
  --color-amber:    hsl(38, 92%, 54%);
  --color-amber-glow: hsla(38, 92%, 54%, 0.25);
  --color-red:      hsl(4, 82%, 58%);
  --color-purple:   hsl(268, 75%, 68%);
  --color-cyan:     hsl(186, 85%, 48%);
  --color-gold:     hsl(42, 95%, 55%);

  --text-primary:   hsl(215, 30%, 94%);
  --text-secondary: hsl(215, 18%, 70%);
  --text-muted:     hsl(215, 12%, 48%);

  --border:         hsl(222, 18%, 20%);
  --border-light:   hsl(222, 18%, 26%);
  --border-focus:   hsl(198, 92%, 52%);

  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;

  --shadow-sm:   0 2px 8px rgba(0, 0, 0, 0.35);
  --shadow-md:   0 6px 20px rgba(0, 0, 0, 0.45);
  --shadow-lg:   0 12px 40px rgba(0, 0, 0, 0.55);
  --shadow-glow: 0 0 35px var(--accent-glow);

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --transition: 200ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Reset & Base ───────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-base);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.6;
  background-image:
    radial-gradient(ellipse 90% 60% at 50% -10%, hsla(198, 92%, 40%, 0.12), transparent),
    radial-gradient(ellipse 60% 50% at 85% 100%, hsla(268, 75%, 50%, 0.08), transparent);
  background-attachment: fixed;
}

/* ── Header ─────────────────────────────────────── */
.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: hsla(222, 24%, 7%, 0.88);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.header-content {
  max-width: 1160px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 14px;
}

.logo-icon {
  font-size: 2.2rem;
  filter: drop-shadow(0 0 14px hsla(198, 92%, 52%, 0.65));
  animation: float 4s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-4px); }
}

.logo-text h1 {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, #ffffff 40%, var(--accent-primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.2;
}

.logo-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-green);
  box-shadow: 0 0 8px var(--color-green);
  animation: pulse-dot 2s ease-in-out infinite;
}

.badge-dot.loading {
  background: var(--color-amber);
  box-shadow: 0 0 8px var(--color-amber);
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.4; transform: scale(0.85); }
}

/* ── Main Layout ────────────────────────────────── */
.app-main {
  max-width: 1160px;
  margin: 0 auto;
  padding: 36px 24px 80px;
}

.section {
  animation: fadeIn 350ms ease;
}

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

.section.active { display: block; }

.section-header-block {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 28px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 16px;
}

.section-num {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent-primary), hsl(210, 90%, 40%));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 0 20px var(--accent-glow);
}

.section-title h2 {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
}

.section-subtitle {
  font-size: 0.86rem;
  color: var(--text-secondary);
  margin-top: 2px;
}

/* ── Sample Loader Banner ───────────────────────── */
.sample-loader-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  border-radius: 100px;
  padding: 6px 8px 6px 16px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.sample-icon { font-size: 1rem; }

.btn-sample {
  background: hsla(198, 92%, 52%, 0.15);
  color: var(--accent-primary);
  border: 1px solid var(--accent-primary);
  border-radius: 100px;
  padding: 6px 14px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-sample:hover {
  background: var(--accent-primary);
  color: #000;
  box-shadow: 0 0 16px var(--accent-glow);
}

/* ── Upload Grid ────────────────────────────────── */
.upload-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 24px;
  align-items: center;
  margin-bottom: 32px;
}

.upload-card {
  position: relative;
  background: var(--bg-surface);
  border: 2px dashed var(--border-light);
  border-radius: var(--radius-xl);
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
  transition: all var(--transition);
  cursor: pointer;
  min-height: 260px;
  justify-content: center;
}

.upload-card:hover,
.upload-card.drag-over {
  border-color: var(--accent-primary);
  background: hsla(198, 92%, 52%, 0.04);
  box-shadow: 0 0 0 4px var(--accent-glow), var(--shadow-md);
  transform: translateY(-2px);
}

.upload-card.has-file {
  border-style: solid;
  border-color: var(--color-green);
  background: hsla(152, 68%, 46%, 0.05);
  box-shadow: 0 0 0 2px var(--color-green-glow);
}

.upload-badge-tag {
  position: absolute;
  top: 14px;
  left: 18px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: 100px;
}

.tag-file1 {
  background: hsla(268, 75%, 68%, 0.15);
  color: var(--color-purple);
  border: 1px solid hsla(268, 75%, 68%, 0.3);
}

.tag-file2 {
  background: hsla(198, 92%, 52%, 0.15);
  color: var(--accent-primary);
  border: 1px solid hsla(198, 92%, 52%, 0.3);
}

.upload-icon {
  font-size: 2.8rem;
  filter: drop-shadow(0 4px 10px rgba(0,0,0,0.3));
}

.upload-label strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

.upload-hint {
  display: block;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.file-info {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.85rem;
  color: var(--color-green);
  max-width: 100%;
  width: 100%;
  animation: fadeIn 200ms ease;
}

.file-icon { flex-shrink: 0; }

.file-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.8rem;
}

.btn-clear {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 2px 6px;
  border-radius: var(--radius-xs);
  transition: all var(--transition);
  flex-shrink: 0;
}
.btn-clear:hover {
  color: var(--color-red);
  background: hsla(4, 82%, 58%, 0.15);
}

.upload-separator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.separator-line {
  width: 2px;
  height: 60px;
  background: linear-gradient(to bottom, transparent, var(--border-light), transparent);
}

.separator-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
}

.separator-icon { font-size: 1.2rem; }

.upload-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 10px;
}

/* ── Buttons ────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  white-space: nowrap;
  user-select: none;
  text-decoration: none;
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.82rem;
  border-radius: var(--radius-sm);
}

.btn-large {
  padding: 15px 36px;
  font-size: 1.05rem;
  border-radius: var(--radius-lg);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-primary), hsl(210, 90%, 42%));
  color: #ffffff;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-hover), hsl(210, 90%, 50%));
  box-shadow: 0 4px 20px var(--accent-glow);
  transform: translateY(-1px);
}

.btn-glow {
  box-shadow: 0 0 25px var(--accent-glow);
}
.btn-glow:hover {
  box-shadow: 0 0 35px hsla(198, 92%, 52%, 0.45);
}

.btn-secondary {
  background: var(--bg-raised);
  color: var(--text-primary);
  border: 1px solid var(--border-light);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-focus);
  color: #fff;
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--accent-primary);
  border: 1px solid var(--accent-primary);
}

.btn-outline:hover {
  background: hsla(198, 92%, 52%, 0.12);
  border-color: var(--accent-hover);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-light);
}

.btn-ghost:hover {
  background: var(--bg-raised);
  color: var(--text-primary);
  border-color: var(--border);
}

.btn-icon { font-size: 1.1em; }

/* ── Loading ────────────────────────────────────── */
.loading-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 90px 24px;
  gap: 22px;
}

.loading-wave {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 52px;
}

.wave-bar {
  width: 9px;
  border-radius: 6px;
  background: var(--accent-primary);
  animation: wave 1.2s ease-in-out infinite;
}

.wave-bar:nth-child(1) { animation-delay: 0s;    height: 22px; }
.wave-bar:nth-child(2) { animation-delay: 0.15s; height: 34px; }
.wave-bar:nth-child(3) { animation-delay: 0.3s;  height: 50px; }
.wave-bar:nth-child(4) { animation-delay: 0.45s; height: 34px; }
.wave-bar:nth-child(5) { animation-delay: 0.6s;  height: 22px; }

@keyframes wave {
  0%, 100% { transform: scaleY(0.4); opacity: 0.4; }
  50%       { transform: scaleY(1);   opacity: 1;   }
}

.loading-text {
  font-size: 1.2rem;
  font-weight: 600;
  color: #fff;
}

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

/* ── Results Top Header ─────────────────────────── */
.results-top-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 20px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 12px 20px;
}

.files-summary-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.file-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  border-radius: 100px;
  padding: 5px 12px 5px 6px;
  font-size: 0.8rem;
}

.file-chip-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 100px;
  text-transform: uppercase;
}

.chip-file1 .file-chip-badge {
  background: hsla(268, 75%, 68%, 0.2);
  color: var(--color-purple);
}

.chip-file2 .file-chip-badge {
  background: hsla(198, 92%, 52%, 0.2);
  color: var(--accent-primary);
}

.file-chip-name {
  font-family: var(--font-mono);
  color: var(--text-primary);
  font-size: 0.78rem;
}

.file-chip-vs {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 600;
}

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

.btn-save-quick {
  background: linear-gradient(135deg, var(--accent-primary), hsl(210, 90%, 42%));
  color: #fff;
  box-shadow: 0 0 16px var(--accent-glow);
}

/* ── Stats Bar ──────────────────────────────────── */
.stats-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
}

.stat-chip {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 8px 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.stat-chip .stat-val {
  font-weight: 700;
  font-size: 1rem;
  font-family: var(--font-mono);
}

.stat-chip.green  .stat-val { color: var(--color-green); }
.stat-chip.amber  .stat-val { color: var(--color-amber); }
.stat-chip.red    .stat-val { color: var(--color-red); }
.stat-chip.blue   .stat-val { color: var(--accent-primary); }
.stat-chip.purple .stat-val { color: var(--color-purple); }

/* ── Tabs Container ─────────────────────────────── */
.tabs-container {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.tabs-nav {
  display: flex;
  overflow-x: auto;
  background: var(--bg-raised);
  border-bottom: 1px solid var(--border);
  scrollbar-width: none;
  padding: 0 8px;
  gap: 4px;
}
.tabs-nav::-webkit-scrollbar { display: none; }

.tab-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 20px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.86rem;
  font-family: var(--font-sans);
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: all var(--transition);
}

.tab-btn:hover {
  color: var(--text-primary);
  background: hsla(222, 16%, 20%, 0.4);
}

.tab-btn.active {
  color: #fff;
  border-bottom-color: var(--accent-primary);
  background: hsla(198, 92%, 52%, 0.06);
}

.tab-btn-highlight {
  color: var(--accent-primary);
}

.tab-btn-highlight.active {
  color: #fff;
  border-bottom-color: var(--accent-primary);
  background: hsla(198, 92%, 52%, 0.12);
}

.tab-icon { font-size: 1.1em; }

.tab-badge {
  background: var(--bg-card);
  color: var(--text-muted);
  border-radius: 100px;
  padding: 2px 8px;
  font-size: 0.72rem;
  font-family: var(--font-mono);
  font-weight: 700;
  min-width: 22px;
  text-align: center;
  transition: all var(--transition);
}

.tab-btn.active .tab-badge {
  background: hsla(198, 92%, 52%, 0.2);
  color: var(--accent-primary);
}

.tab-badge.has-items {
  background: hsla(38, 92%, 54%, 0.2);
  color: var(--color-amber);
}

.tab-badge.has-items-red {
  background: hsla(4, 82%, 58%, 0.2);
  color: var(--color-red);
}

/* ── Tab Panels ─────────────────────────────────── */
.tabs-content { padding: 32px; }

.tab-panel { display: none; animation: fadeIn 250ms ease; }
.tab-panel.active { display: block; }

.panel-header { margin-bottom: 24px; }

.panel-header h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 6px;
}

.panel-desc {
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.panel-desc code {
  font-family: var(--font-mono);
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  border-radius: 4px;
  padding: 2px 6px;
  font-size: 0.85em;
  color: var(--color-cyan);
}

/* ── Data Tables ────────────────────────────────── */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--bg-surface);
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

table.data-table thead th {
  background: var(--bg-raised);
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 12px 18px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

table.data-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background var(--transition);
}
table.data-table tbody tr:last-child { border-bottom: none; }
table.data-table tbody tr:hover { background: var(--bg-card-hover); }

table.data-table tbody td {
  padding: 12px 18px;
  color: var(--text-primary);
}

.cell-mono {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--color-cyan);
  font-weight: 500;
}

.badge-file {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.74rem;
  font-weight: 700;
}

.badge-file.file1 {
  background: hsla(268, 75%, 68%, 0.15);
  color: var(--color-purple);
}

.badge-file.file2 {
  background: hsla(198, 92%, 52%, 0.15);
  color: var(--accent-primary);
}

/* ── Empty State ────────────────────────────────── */
.empty-state {
  padding: 48px 24px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.92rem;
}

/* ── Accordion ──────────────────────────────────── */
.accordion-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  overflow: hidden;
  background: var(--bg-surface);
}

.accordion-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: var(--bg-card);
  cursor: pointer;
  transition: background var(--transition);
  user-select: none;
}

.accordion-header:hover { background: var(--bg-card-hover); }

.accordion-title {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.92rem;
  font-weight: 600;
}

.accordion-date {
  font-family: var(--font-mono);
  color: var(--accent-primary);
  font-size: 0.86rem;
}

.accordion-diff-count {
  background: hsla(4, 82%, 58%, 0.15);
  color: var(--color-red);
  border-radius: 100px;
  padding: 3px 12px;
  font-size: 0.76rem;
  font-weight: 700;
  font-family: var(--font-mono);
}

.accordion-chevron {
  color: var(--text-muted);
  transition: transform var(--transition);
  font-size: 0.8rem;
}

.accordion-item.open .accordion-chevron { transform: rotate(180deg); }

.accordion-body {
  display: none;
  padding: 20px;
  border-top: 1px solid var(--border);
}

.accordion-item.open .accordion-body { display: block; }

/* ── Summary Diff ───────────────────────────────── */
.summary-status-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.summary-file-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 18px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  border: 1px solid var(--border);
}

.summary-file-row .status-icon { font-size: 1.2rem; }

/* ── Metrics Grid ── */
.summary-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.summary-metric-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 14px 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  text-align: center;
  transition: transform 0.15s ease;
}

.summary-metric-card:hover {
  transform: translateY(-2px);
}

.summary-metric-card .metric-num {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}

.summary-metric-card .metric-label {
  font-size: 0.76rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 4px;
}

.summary-metric-card.metric-amber .metric-num { color: var(--color-amber); }
.summary-metric-card.metric-green .metric-num { color: var(--color-green); }
.summary-metric-card.metric-purple .metric-num { color: var(--color-purple); }

/* ── Columns Scheme Banner ── */
.summary-cols-banner {
  background: var(--bg-card);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-bottom: 24px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.05) 0%, rgba(245, 158, 11, 0.01) 100%);
}

.summary-cols-header {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-amber);
  margin-bottom: 10px;
}

.summary-cols-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.86rem;
}

.col-badge-label {
  color: var(--text-muted);
  font-weight: 500;
  margin-right: 6px;
}

.col-pill {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 9999px;
  font-size: 0.78rem;
  font-weight: 600;
  margin: 2px;
}

.col-pill-warn {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.col-pill-new {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* ── Resumen Sections & Cards ── */
.resumen-section {
  margin-bottom: 32px;
}

.resumen-section-header {
  margin-bottom: 14px;
}

.resumen-section-header h4 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.resumen-diff-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.resumen-diff-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border);
}

.resumen-diff-date {
  display: flex;
  align-items: center;
  gap: 10px;
}

.time-badge {
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 500;
}

.resumen-table th {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  background: rgba(0, 0, 0, 0.1);
}

.diff-val-old {
  background: rgba(239, 68, 68, 0.08);
  color: #ef4444;
  font-weight: 600;
  font-family: var(--font-mono, monospace);
}

.diff-val-new {
  background: rgba(16, 185, 129, 0.08);
  color: #10b981;
  font-weight: 600;
  font-family: var(--font-mono, monospace);
}

/* ═══════════════════════════════════════════════════
   EXPORT TAB — OVERHAULED & PREMIUM STYLES
   ═══════════════════════════════════════════════════ */

/* ── Hero Banner ────────────────────────────────── */
.export-hero-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  background: linear-gradient(135deg, hsla(198, 92%, 52%, 0.08), hsla(268, 75%, 68%, 0.05));
  border: 1px solid hsla(198, 92%, 52%, 0.25);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin-bottom: 28px;
  position: relative;
  overflow: hidden;
}

.export-hero-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-primary), var(--color-purple));
}

.export-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--accent-primary);
  text-transform: uppercase;
  margin-bottom: 6px;
}

.badge-pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-primary);
  box-shadow: 0 0 8px var(--accent-primary);
}

.export-hero-content h3 {
  font-size: 1.35rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 4px;
}

.export-hero-content p {
  font-size: 0.86rem;
  color: var(--text-secondary);
}

.export-hero-stats {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero-stat-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px 20px;
  text-align: center;
  min-width: 110px;
}

.hero-stat-num {
  display: block;
  font-size: 1.4rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--accent-primary);
  line-height: 1.1;
}

.hero-stat-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-top: 2px;
}

/* ── Conflict Strategy Section ──────────────────── */
.conflict-strategy-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin-bottom: 32px;
}

.strategy-header {
  margin-bottom: 20px;
}

.strategy-title-group {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.strategy-icon-badge {
  font-size: 1.4rem;
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.strategy-title-group h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}

.strategy-title-group p {
  font-size: 0.84rem;
  color: var(--text-secondary);
}

.strategy-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.strategy-option {
  cursor: pointer;
}

.strategy-option input { display: none; }

.strategy-card {
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 18px 20px;
  background: var(--bg-surface);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  transition: all var(--transition);
  position: relative;
}

.strategy-card:hover {
  border-color: var(--border-light);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}

.strategy-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.strategy-card-icon { font-size: 1.5rem; }

.strategy-radio-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
  color: transparent;
  transition: all var(--transition);
}

.strategy-option input:checked + .strategy-card {
  border-color: var(--accent-primary);
  background: hsla(198, 92%, 52%, 0.08);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.strategy-option input:checked + .strategy-card .strategy-radio-check {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: #000;
}

.strategy-name {
  font-size: 0.94rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 6px;
}

.strategy-card .strategy-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.strategy-card .strategy-desc code {
  font-family: var(--font-mono);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 1px 4px;
  color: var(--accent-primary);
}

/* ── Export Cards Grid ──────────────────────────── */
.export-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.export-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  transition: all var(--transition);
}

.export-card:hover {
  border-color: var(--border-light);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

/* Featured Card */
.export-card-featured {
  background: linear-gradient(180deg, hsla(42, 95%, 55%, 0.06), var(--bg-card) 40%);
  border: 2px solid hsla(42, 95%, 55%, 0.45);
  box-shadow: 0 4px 30px hsla(42, 95%, 55%, 0.15);
}

.export-card-featured:hover {
  border-color: var(--color-gold);
  box-shadow: 0 8px 40px hsla(42, 95%, 55%, 0.25);
}

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

.export-pill {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 4px 10px;
  border-radius: 100px;
  text-transform: uppercase;
}

.pill-cyan {
  background: hsla(186, 85%, 48%, 0.15);
  color: var(--color-cyan);
  border: 1px solid hsla(186, 85%, 48%, 0.3);
}

.pill-purple {
  background: hsla(268, 75%, 68%, 0.15);
  color: var(--color-purple);
  border: 1px solid hsla(268, 75%, 68%, 0.3);
}

.pill-emerald {
  background: hsla(158, 70%, 45%, 0.15);
  color: hsl(158, 70%, 48%);
  border: 1px solid hsla(158, 70%, 45%, 0.35);
}

.pill-highlight {
  background: linear-gradient(135deg, hsl(42, 95%, 55%), hsl(30, 95%, 50%));
  color: #000;
  font-weight: 800;
  box-shadow: 0 0 14px hsla(42, 95%, 55%, 0.4);
}

.export-card-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.icon-cyan {
  background: hsla(186, 85%, 48%, 0.12);
}

.icon-emerald {
  background: hsla(158, 70%, 45%, 0.12);
}

.icon-purple {
  background: hsla(268, 75%, 68%, 0.12);
}

.icon-gold {
  background: hsla(42, 95%, 55%, 0.15);
}

.export-card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.export-card-body h4 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}

.export-card-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 16px;
}

.export-feature-list {
  list-style: none;
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.export-feature-list li {
  font-size: 0.78rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

.check-icon {
  color: var(--color-green);
  font-weight: 800;
  font-size: 0.85rem;
}

.export-card-footer {
  margin-top: auto;
}

.btn-export-action {
  width: 100%;
  padding: 13px 20px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.btn-download-icon { font-size: 1.1rem; }

/* ── Export Info Note ───────────────────────────── */
.export-info-note {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  font-size: 0.84rem;
  color: var(--text-secondary);
}

.note-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
}

.note-text strong {
  color: var(--text-primary);
}

/* ── Toast Notifications ────────────────────────── */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 1000;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  font-size: 0.88rem;
  color: var(--text-primary);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 300px;
  animation: slideInRight 300ms ease;
}

.toast.success { border-left: 4px solid var(--color-green); }
.toast.error   { border-left: 4px solid var(--color-red); }
.toast.info    { border-left: 4px solid var(--accent-primary); }

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

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

/* ── Scrollbar ──────────────────────────────────── */
::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ── Responsive ─────────────────────────────────── */
@media (max-width: 992px) {
  .export-cards-grid {
    grid-template-columns: 1fr;
  }

  .strategy-options {
    grid-template-columns: 1fr;
  }
}

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

  .upload-separator {
    flex-direction: row;
  }

  .separator-line {
    width: 60px;
    height: 2px;
  }

  .tabs-nav {
    padding: 0;
  }

  .tab-btn {
    padding: 12px 14px;
    font-size: 0.8rem;
  }

  .tab-label {
    display: none;
  }

  .results-top-header {
    flex-direction: column;
    align-items: flex-start;
  }
}
