/* ============================================================
   exchange-theme.css — Pixel / Warfare Exchange
   Overrides .exchange-* / .market-card / .berry-card classes
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

/* ─── Hero ─── */
.exchange-hero-cinematic {
  position: relative;
  background: rgba(0, 0, 0, 0.6);
  border: calc(var(--px) * 1) solid var(--border);
  padding: calc(var(--px) * 4);
  margin-bottom: calc(var(--px) * 3);
  overflow: hidden;
}
.exchange-hero-cinematic::before {
  content: '';
  position: absolute;
  inset: calc(var(--px) * -1);
  border: calc(var(--px) * 1) solid rgba(255, 255, 255, 0.03);
  pointer-events: none;
}
.exchange-hero-inner {
  display: flex;
  align-items: center;
  gap: calc(var(--px) * 4);
  position: relative;
  z-index: 2;
}
.exchange-hero-text { flex: 1; }
.exchange-live-pill {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--px) * 1);
  font-family: 'Press Start 2P', monospace;
  font-size: 6px;
  color: #4ade80;
  background: rgba(74, 222, 128, 0.1);
  border: calc(var(--px) * 1) solid rgba(74, 222, 128, 0.3);
  padding: calc(var(--px) * 1) calc(var(--px) * 2);
  margin-bottom: calc(var(--px) * 2);
  text-transform: uppercase;
}
.exchange-live-dot {
  width: calc(var(--px) * 2);
  height: calc(var(--px) * 2);
  background: #4ade80;
}
.exchange-hero-kicker {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: #94a3b8;
  margin-bottom: calc(var(--px) * 1);
}
.exchange-hero-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 14px;
  color: #f1f5f9;
  margin: 0 0 calc(var(--px) * 2) 0;
  line-height: 1.4;
}
.exchange-hero-title-accent { color: #facc15; }
.exchange-hero-desc {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: #94a3b8;
  line-height: 1.6;
  margin-bottom: calc(var(--px) * 3);
}
.exchange-hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--px) * 1);
}
.exchange-hero-chip {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  padding: calc(var(--px) * 1) calc(var(--px) * 2);
  background: rgba(255, 255, 255, 0.05);
  border: calc(var(--px) * 1) solid rgba(255, 255, 255, 0.1);
  color: #cbd5e1;
  display: inline-flex;
  align-items: center;
  gap: calc(var(--px) * 1);
}
.exchange-hero-chip .pxi svg {
  width: 12px;
  height: 12px;
  display: block;
}
.exchange-hero-chip--gold {
  background: rgba(250, 204, 21, 0.1);
  border-color: rgba(250, 204, 21, 0.3);
  color: #facc15;
}
.exchange-hero-chip--sky {
  background: rgba(56, 189, 248, 0.1);
  border-color: rgba(56, 189, 248, 0.3);
  color: #7dd3fc;
}

/* ─── Hero Strip ─── */
.exchange-hero-strip {
  margin-top: calc(var(--px) * 3);
  padding-top: calc(var(--px) * 2);
  border-top: calc(var(--px) * 1) solid rgba(255, 255, 255, 0.05);
  font-family: 'Press Start 2P', monospace;
  font-size: 6px;
  color: #64748b;
  display: flex;
  align-items: center;
  gap: calc(var(--px) * 2);
  flex-wrap: wrap;
}
.exchange-hero-strip .pxi svg {
  width: 10px;
  height: 10px;
  display: block;
}
.exchange-hero-strip-divider {
  width: calc(var(--px) * 1);
  height: calc(var(--px) * 4);
  background: rgba(255, 255, 255, 0.1);
}

/* ─── Converter Panel ─── */
.exchange-converter {
  background: rgba(0, 0, 0, 0.65);
  border: calc(var(--px) * 1) solid var(--border);
  padding: calc(var(--px) * 3);
  margin-bottom: calc(var(--px) * 3);
}
.exchange-converter-head {
  display: flex;
  align-items: center;
  gap: calc(var(--px) * 2);
  margin-bottom: calc(var(--px) * 2);
  padding-bottom: calc(var(--px) * 2);
  border-bottom: calc(var(--px) * 1) solid rgba(255, 255, 255, 0.05);
}
.exchange-converter-icon {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(99, 102, 241, 0.15);
  border: calc(var(--px) * 1) solid rgba(99, 102, 241, 0.3);
  flex-shrink: 0;
  color: #818cf8;
}
.exchange-converter-icon .pxi svg {
  width: 18px;
  height: 18px;
  display: block;
}
.exchange-converter-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 9px;
  color: #f1f5f9;
}
.exchange-converter-sub {
  font-family: 'Press Start 2P', monospace;
  font-size: 6px;
  color: #64748b;
  margin-top: calc(var(--px) * 0.5);
}
.exchange-converter-badge {
  font-family: 'Press Start 2P', monospace;
  font-size: 8px;
  padding: calc(var(--px) * 1) calc(var(--px) * 2);
  background: rgba(250, 204, 21, 0.15);
  border: calc(var(--px) * 1) solid rgba(250, 204, 21, 0.3);
  color: #facc15;
  margin-left: auto;
}

/* ─── Converter Body ─── */
.exchange-converter-label {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: #94a3b8;
  display: block;
  margin-bottom: calc(var(--px) * 1);
}
.exchange-converter-input-wrap {
  display: flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.4);
  border: calc(var(--px) * 1) solid var(--border);
  margin-bottom: calc(var(--px) * 1);
}
.exchange-converter-input-icon {
  padding: calc(var(--px) * 2);
  color: #64748b;
}
.exchange-converter-input-icon .pxi svg {
  width: 14px;
  height: 14px;
  display: block;
}
.exchange-converter-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: 'Press Start 2P', monospace;
  font-size: 11px;
  color: #f1f5f9;
  padding: calc(var(--px) * 2) 0;
  min-width: 0;
}
.exchange-converter-input-suffix {
  padding: calc(var(--px) * 2);
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: #64748b;
}

/* ─── Quick Amount Buttons ─── */
.exchange-converter-quick {
  display: flex;
  gap: calc(var(--px) * 1);
  margin-bottom: calc(var(--px) * 2);
}
.exchange-converter-quick-btn {
  flex: 1;
  font-family: 'Press Start 2P', monospace;
  font-size: 6px;
  padding: calc(var(--px) * 1.5) calc(var(--px) * 1);
  background: rgba(255, 255, 255, 0.05);
  border: calc(var(--px) * 1) solid var(--border);
  color: #94a3b8;
  cursor: pointer;
  text-transform: uppercase;
  transition: all 0.15s;
}
.exchange-converter-quick-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #f1f5f9;
}
.exchange-converter-quick-btn--max {
  background: rgba(250, 204, 21, 0.1);
  border-color: rgba(250, 204, 21, 0.3);
  color: #facc15;
}
.exchange-converter-quick-btn--max:hover {
  background: rgba(250, 204, 21, 0.2);
}

/* ─── Preview ─── */
.exchange-converter-preview {
  background: rgba(0, 0, 0, 0.3);
  border: calc(var(--px) * 1) solid rgba(255, 255, 255, 0.05);
  padding: calc(var(--px) * 2);
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: calc(var(--px) * 2);
}
.exchange-converter-preview-label {
  font-family: 'Press Start 2P', monospace;
  font-size: 6px;
  color: #64748b;
  display: block;
  margin-bottom: calc(var(--px) * 0.5);
}
.exchange-converter-preview-bc {
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  color: #facc15;
}
.exchange-converter-preview-arrow {
  color: #64748b;
}
.exchange-converter-preview-arrow .pxi svg {
  width: 16px;
  height: 16px;
  display: block;
}
.exchange-converter-preview-usdc {
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  color: #4ade80;
}
.exchange-converter-cap,
.exchange-converter-hint {
  font-family: 'Press Start 2P', monospace;
  font-size: 6px;
  color: #64748b;
  margin-bottom: calc(var(--px) * 1);
}
.exchange-converter-btn {
  width: 100%;
  font-family: 'Press Start 2P', monospace;
  font-size: 8px;
  padding: calc(var(--px) * 3);
  background: linear-gradient(180deg, #818cf8, #6366f1);
  color: #000;
  border: calc(var(--px) * 1) solid #818cf8;
  cursor: pointer;
  text-transform: uppercase;
  transition: all 0.15s;
}
.exchange-converter-btn:hover {
  background: linear-gradient(180deg, #a5b4fc, #818cf8);
  transform: translateY(calc(var(--px) * -1));
}
.exchange-converter-btn:active {
  transform: translateY(calc(var(--px) * 1));
}
.exchange-converter-btn[disabled] {
  background: rgba(100, 116, 139, 0.3);
  color: #64748b;
  border-color: #475569;
  cursor: not-allowed;
  pointer-events: none;
}

/* ─── Rates Panel ─── */
.exchange-rates-panel {
  background: rgba(0, 0, 0, 0.65);
  border: calc(var(--px) * 1) solid var(--border);
  padding: 12px;
  margin-bottom: 12px;
}
.exchange-rates-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: #94a3b8;
}
.exchange-rates-title {
  font-family: 'Fredoka', 'Nunito', system-ui, sans-serif !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  color: #f8fafc !important;
  letter-spacing: 0.02em;
}
.exchange-rates-sub {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  color: #94a3b8 !important;
  line-height: 1.35;
  width: 100%;
  margin-left: 0 !important;
}
.exchange-rate-grid {
  display: flex !important;
  flex-direction: column !important;
  gap: 6px !important;
  max-height: 360px;
  overflow-y: auto;
  padding-right: 2px;
}
.exchange-rate-chip {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 8px 10px !important;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  min-width: 0;
}
.exchange-rate-have {
  border-color: rgba(74, 222, 128, 0.35) !important;
  background: rgba(74, 222, 128, 0.07) !important;
}

/* Iconos de planta: tamaño FIJO (antes PNG 1024px se desbordaba ~136px) */
.exchange-rate-icon {
  width: 40px !important;
  height: 40px !important;
  flex: 0 0 40px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  line-height: 0 !important;
}
.exchange-rate-icon .art-img-wrap,
.exchange-rate-icon .art-img-fallback,
.exchange-rate-icon .crop-art-img,
.exchange-rate-icon img,
.exchange-rate-icon svg,
.exchange-rate-icon .berry-svg {
  width: 40px !important;
  height: 40px !important;
  max-width: 40px !important;
  max-height: 40px !important;
  object-fit: contain !important;
  display: block !important;
}

.exchange-rate-info {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  line-height: 1.25;
}
.exchange-rate-name {
  font-family: 'Nunito', 'Fredoka', system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  color: #f1f5f9 !important;
  display: block !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.exchange-rate-price {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  color: #facc15 !important;
  display: block !important;
  margin-top: 2px;
}
.exchange-rate-cur {
  font-size: 10px !important;
  font-weight: 700 !important;
  color: #94a3b8 !important;
}
.exchange-rate-meta {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 10px !important;
  font-weight: 600 !important;
  color: #94a3b8 !important;
  display: block !important;
  margin-top: 2px;
  line-height: 1.3;
  white-space: normal !important;
}
.exchange-rate-stock {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  margin-left: auto;
  flex-shrink: 0;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(74, 222, 128, 0.15);
  border: 1px solid rgba(74, 222, 128, 0.35);
  color: #4ade80 !important;
}

/* ─── Stat Cards ─── */
#exchange-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 14px;
}
.exchange-stat-card {
  background: rgba(0, 0, 0, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px 10px;
  text-align: center;
}
.exchange-stat-icon {
  color: #94a3b8;
  margin-bottom: 4px;
}
.exchange-stat-icon .pxi svg {
  width: 18px;
  height: 18px;
  display: block;
  margin: 0 auto;
}
.exchange-stat-label {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 10px !important;
  font-weight: 800 !important;
  color: #94a3b8 !important;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 2px;
}
.exchange-stat-value {
  font-family: 'Fredoka', 'Nunito', system-ui, sans-serif !important;
  font-size: 22px !important;
  font-weight: 700 !important;
  color: #f8fafc !important;
  line-height: 1.15;
}
.exchange-stat-meta {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 10px !important;
  font-weight: 600 !important;
  color: #94a3b8 !important;
  margin-top: 2px;
}

/* ─── Harvest Cards (Exchange Grid) ─── */
#exchange-grid,
.exchange-harvest-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)) !important;
  gap: 12px !important;
}
.exchange-harvest-card {
  position: relative;
  background: rgba(10, 14, 12, 0.88) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  border-radius: 12px !important;
  padding: 14px !important;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 0;
  color: #e2e8f0;
}
.exchange-harvest-glow {
  position: absolute;
  inset: 0;
  opacity: 0.08;
  pointer-events: none;
}
.exchange-harvest-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  position: relative;
  z-index: 1;
  min-width: 0;
}
.exchange-harvest-icon {
  width: 48px !important;
  height: 48px !important;
  flex: 0 0 48px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  line-height: 0 !important;
  font-size: 0 !important;
}
.exchange-harvest-icon .art-img-wrap,
.exchange-harvest-icon .art-img-fallback,
.exchange-harvest-icon .crop-art-img,
.exchange-harvest-icon img,
.exchange-harvest-icon svg,
.exchange-harvest-icon .berry-svg {
  width: 48px !important;
  height: 48px !important;
  max-width: 48px !important;
  max-height: 48px !important;
  object-fit: contain !important;
  display: block !important;
}
.exchange-harvest-name {
  font-family: 'Nunito', 'Fredoka', system-ui, sans-serif !important;
  font-size: 15px !important;
  font-weight: 800 !important;
  color: #f8fafc !important;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.exchange-harvest-stock {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  color: #cbd5e1 !important;
  margin-top: 2px;
}
.exchange-harvest-stock strong {
  color: #facc15 !important;
  font-weight: 900;
}
.exchange-harvest-tier {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(250, 204, 21, 0.12);
  border: 1px solid rgba(250, 204, 21, 0.35);
  color: #facc15 !important;
  flex-shrink: 0;
}

/* Texto legible dentro de tarjetas de cosecha (evita tailwind oscuro/ilegible) */
.exchange-harvest-card .font-extrabold,
.exchange-harvest-card .text-xl,
.exchange-harvest-card .text-lg {
  color: #f8fafc !important;
  font-family: 'Nunito', system-ui, sans-serif !important;
}
.exchange-harvest-card .text-xs,
.exchange-harvest-card .text-sm,
.exchange-harvest-card .text-\[9px\],
.exchange-harvest-card .text-\[10px\] {
  color: #cbd5e1 !important;
  font-family: 'Nunito', system-ui, sans-serif !important;
}
.exchange-harvest-card button {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-weight: 800 !important;
}

/* ─── Market / Berry Card (Locked) ─── */
.market-card {
  background: rgba(0, 0, 0, 0.65) !important;
  border: calc(var(--px) * 1) solid var(--border) !important;
  padding: calc(var(--px) * 3) !important;
  border-radius: 0 !important;
}
.market-card-locked {
  border-style: solid !important;
  border-color: rgba(250, 204, 21, 0.3) !important;
  opacity: 0.9 !important;
}

/* ─── Empty State ─── */
#exchange-empty {
  text-align: center;
  padding: calc(var(--px) * 4);
  background: rgba(0, 0, 0, 0.5);
  border: calc(var(--px) * 1) solid var(--border);
  font-family: 'Press Start 2P', monospace;
  font-size: 8px;
  color: #64748b;
}

/* ─── Locked Banner ─── */
#exchange-locked-banner {
  background: rgba(0, 0, 0, 0.65);
  border: calc(var(--px) * 1) solid rgba(250, 204, 21, 0.3);
  padding: calc(var(--px) * 3);
  margin-bottom: calc(var(--px) * 3);
}
#exchange-locked-banner .font-extrabold {
  font-family: 'Press Start 2P', monospace;
  font-size: 9px;
  color: #facc15 !important;
}
#exchange-locked-banner p {
  font-family: 'Press Start 2P', monospace;
  font-size: 7px;
  color: #a3a3a3 !important;
}

/* ─── Animations ─── */
@keyframes exchangeSlideUp {
  0% { opacity: 0; transform: translateY(12px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* ─── Responsive ─── */
@media (max-width: 768px) {
  #exchange-summary {
    grid-template-columns: repeat(2, 1fr);
  }
  .exchange-hero-inner {
    flex-direction: column;
  }
  .exchange-hero-title {
    font-size: 11px;
  }
  #exchange-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px) {
  .exchange-converter-quick {
    flex-wrap: wrap;
  }
  .exchange-converter-quick-btn {
    flex: 1 1 40%;
  }
  .exchange-rate-grid {
    grid-template-columns: 1fr;
  }
}

/* ─── Layout principal del tab Intercambio ─── */
#view-exchange .exchange-grid {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 280px) !important;
  gap: 12px !important;
  align-items: start;
}
#view-exchange .exchange-col,
#view-exchange .exchange-side {
  min-width: 0 !important;
  overflow: hidden;
}
#view-exchange .exchange-side {
  max-height: none;
  overflow: visible;
}

/* Converter: tipografía legible */
#view-exchange .exchange-converter-title {
  font-family: 'Fredoka', 'Nunito', system-ui, sans-serif !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  color: #f8fafc !important;
}
#view-exchange .exchange-converter-sub,
#view-exchange .exchange-converter-label,
#view-exchange .exchange-converter-hint,
#view-exchange .exchange-converter-cap,
#view-exchange .exchange-converter-preview-label {
  font-family: 'Nunito', system-ui, sans-serif !important;
  color: #94a3b8 !important;
}
#view-exchange .exchange-converter-sub { font-size: 12px !important; font-weight: 600 !important; }
#view-exchange .exchange-converter-label { font-size: 11px !important; font-weight: 700 !important; }
#view-exchange .exchange-converter-preview-bc,
#view-exchange .exchange-converter-preview-usdc {
  font-family: 'Fredoka', 'Nunito', system-ui, sans-serif !important;
  font-size: 18px !important;
  font-weight: 700 !important;
}
#view-exchange .exchange-converter-btn {
  font-family: 'Nunito', system-ui, sans-serif !important;
  font-weight: 800 !important;
  letter-spacing: 0.04em;
}

@media (max-width: 900px) {
  #view-exchange .exchange-grid {
    grid-template-columns: 1fr !important;
  }
  #view-exchange .exchange-side {
    max-height: none;
  }
}

/* ─── Safety: hide decorative modern elements ─── */
.exchange-hero-bg,
.exchange-hero-overlay,
.exchange-hero-glow,
.exchange-hero-glow--2,
.exchange-hero-sparkle,
.exchange-hero-orbit,
.exchange-hero-orbit-ring,
.exchange-hero-orbit-ring--2,
.exchange-hero-swap,
.exchange-hero-swap-arrow,
.exchange-hero-coin,
.exchange-hero-visual {
  display: none !important;
}

.exchange-hub::before {
  display: none !important;
}

.exchange-converter,
.exchange-stat-card,
.exchange-harvest-card {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.exchange-converter-btn {
  background: var(--accent-green) !important;
  color: #000 !important;
  border: var(--px) solid var(--px-dark) !important;
  box-shadow: var(--px) var(--px) 0 0 var(--px-dark) !important;
}

.exchange-converter-head {
  background: none !important;
}

.exchange-stat-card::before {
  display: none !important;
}

.exchange-harvest-glow {
  display: none !important;
}

/* Kill all modern animations */
.exchange-hero-cinematic,
.exchange-hub,
.exchange-converter,
.exchange-converter-preview-arrow,
.exchange-rate-chip,
.exchange-stat-card,
.exchange-harvest-card,
#exchange-empty {
  animation: none !important;
}

/* ============================================================
   EXCHANGE FARM THEME v3 � mismo look que Staking / Lab / Retiros
   ============================================================ */

#content-exchange {
  position: static !important;
  overflow: visible !important;
  pointer-events: none;
  height: 0 !important;
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
}

#content-exchange #view-exchange.tab-view {
  position: absolute !important;
  inset: 10px !important;
  width: auto !important;
  height: auto !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  pointer-events: auto !important;
  display: block !important;
  background:
    linear-gradient(165deg, rgba(28, 22, 14, 0.97) 0%, rgba(12, 10, 8, 0.98) 100%) !important;
  border: 2px solid #0a0806 !important;
  box-shadow:
    0 0 0 2px #c49a20,
    0 12px 40px rgba(0, 0, 0, 0.55) !important;
  padding: 14px 16px 20px !important;
  z-index: 20;
  border-radius: 0 !important;
}

#view-exchange .panel-head {
  border-bottom: 1px solid rgba(232, 184, 48, 0.28) !important;
  margin-bottom: 12px !important;
  padding-bottom: 10px !important;
}

#view-exchange .panel-head h2 {
  color: #f0d060 !important;
  font-family: var(--font-game, monospace) !important;
  text-shadow: 2px 2px 0 #000 !important;
}

/* Converter farm */
#view-exchange .exchange-converter {
  background: rgba(0, 0, 0, 0.4) !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  box-shadow: 0 0 0 1px rgba(196, 154, 32, 0.35), 0 3px 0 rgba(0, 0, 0, 0.35) !important;
  padding: 14px !important;
  margin-bottom: 0 !important;
}

#view-exchange .exchange-converter-head {
  border-bottom: 1px solid rgba(232, 184, 48, 0.22) !important;
  margin-bottom: 12px !important;
  padding-bottom: 10px !important;
  gap: 10px !important;
}

#view-exchange .exchange-converter-icon {
  width: 40px !important;
  height: 40px !important;
  background: rgba(232, 184, 48, 0.12) !important;
  border: 2px solid #c49a20 !important;
  color: #f0d060 !important;
  border-radius: 0 !important;
}

#view-exchange .exchange-converter-title {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 15px !important;
  font-weight: 800 !important;
  color: #f8f0e0 !important;
}

#view-exchange .exchange-converter-sub {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  color: #a89a88 !important;
  margin-top: 3px !important;
}

#view-exchange .exchange-converter-badge {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 900 !important;
  padding: 6px 10px !important;
  background: rgba(232, 184, 48, 0.15) !important;
  border: 2px solid #c49a20 !important;
  color: #facc15 !important;
  border-radius: 0 !important;
}

#view-exchange .exchange-converter-label {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #a89a88 !important;
  margin-bottom: 6px !important;
}

#view-exchange .exchange-converter-input-wrap {
  background: rgba(0, 0, 0, 0.45) !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  margin-bottom: 10px !important;
  box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.25);
}

#view-exchange .exchange-converter-input-wrap:focus-within {
  border-color: #c49a20 !important;
  box-shadow: 0 0 0 1px rgba(232, 184, 48, 0.35) !important;
}

#view-exchange .exchange-converter-input {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 16px !important;
  font-weight: 800 !important;
  color: #f8f0e0 !important;
  padding: 10px 4px !important;
}

#view-exchange .exchange-converter-input-suffix {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  color: #facc15 !important;
}

#view-exchange .exchange-converter-input-icon {
  color: #c49a20 !important;
}

#view-exchange .exchange-converter-quick {
  gap: 8px !important;
  margin-bottom: 12px !important;
}

#view-exchange .exchange-converter-quick-btn {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  padding: 8px 6px !important;
  background: rgba(0, 0, 0, 0.4) !important;
  border: 2px solid #0a0806 !important;
  color: #c8b8a0 !important;
  border-radius: 0 !important;
  box-shadow: 0 2px 0 #0a0806;
  transition: background 0.12s, color 0.12s, border-color 0.12s;
}

#view-exchange .exchange-converter-quick-btn:hover {
  background: rgba(232, 184, 48, 0.12) !important;
  color: #f8f0e0 !important;
  border-color: #c49a20 !important;
}

#view-exchange .exchange-converter-quick-btn--max {
  background: linear-gradient(180deg, #f0d060, #c49a20) !important;
  border-color: #0a0806 !important;
  color: #1a1208 !important;
}

#view-exchange .exchange-converter-quick-btn--max:hover {
  filter: brightness(1.06);
  background: linear-gradient(180deg, #f0d060, #c49a20) !important;
  color: #1a1208 !important;
}

#view-exchange .exchange-converter-preview {
  background: rgba(232, 184, 48, 0.07) !important;
  border: 1px solid rgba(232, 184, 48, 0.3) !important;
  border-radius: 0 !important;
  padding: 12px !important;
  margin-bottom: 10px !important;
}

#view-exchange .exchange-converter-preview-label {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 11px !important;
  font-weight: 800 !important;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #a89a88 !important;
}

#view-exchange .exchange-converter-preview-bc {
  font-family: "Fredoka", "Nunito", system-ui, sans-serif !important;
  font-size: 18px !important;
  font-weight: 700 !important;
  color: #facc15 !important;
}

#view-exchange .exchange-converter-preview-usdc {
  font-family: "Fredoka", "Nunito", system-ui, sans-serif !important;
  font-size: 18px !important;
  font-weight: 700 !important;
  color: #6ee7b7 !important;
}

#view-exchange .exchange-converter-preview-arrow {
  color: #c49a20 !important;
}

#view-exchange .exchange-converter-cap,
#view-exchange .exchange-converter-hint {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  color: #a89a88 !important;
  margin-bottom: 8px !important;
  line-height: 1.4 !important;
}

#view-exchange .exchange-converter-btn {
  width: 100% !important;
  min-height: 48px !important;
  font-family: var(--font-game, monospace) !important;
  font-size: 11px !important;
  letter-spacing: 0.06em !important;
  padding: 12px 16px !important;
  background: linear-gradient(180deg, #f0d060, #c49a20) !important;
  color: #1a1208 !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  box-shadow: 0 3px 0 #0a0806 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  text-transform: uppercase !important;
}

#view-exchange .exchange-converter-btn:hover:not(:disabled) {
  filter: brightness(1.06);
  transform: translateY(-1px);
  background: linear-gradient(180deg, #f0d060, #c49a20) !important;
}

#view-exchange .exchange-converter-btn:disabled {
  opacity: 0.45 !important;
  background: rgba(80, 70, 50, 0.4) !important;
  color: #8a7a68 !important;
  border-color: #0a0806 !important;
  box-shadow: none !important;
  transform: none !important;
}

/* Side rates + sell all */
#view-exchange .exchange-side {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: visible !important;
  max-height: none !important;
}

#view-exchange .exchange-col {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}

#view-exchange .exchange-rates-panel {
  background: rgba(0, 0, 0, 0.4) !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  box-shadow: 0 0 0 1px rgba(196, 154, 32, 0.3) !important;
  padding: 12px !important;
  margin-bottom: 0 !important;
}

#view-exchange .exchange-rates-title {
  color: #f0d060 !important;
}

#view-exchange .exchange-rates-sub {
  color: #8a7a68 !important;
}

#view-exchange .exchange-rate-chip {
  background: rgba(0, 0, 0, 0.35) !important;
  border: 1px solid rgba(255, 255, 255, 0.06) !important;
  border-radius: 0 !important;
}

#view-exchange .exchange-rate-have {
  border-color: rgba(110, 231, 183, 0.4) !important;
  background: rgba(16, 80, 40, 0.15) !important;
}

#view-exchange .exchange-rate-name {
  color: #f8f0e0 !important;
}

#view-exchange .exchange-rate-price {
  color: #facc15 !important;
}

#view-exchange .exchange-rate-meta {
  color: #8a7a68 !important;
}

/* Botón “Intercambiar todas las cosechas” — texto completo, sin recortes */
#view-exchange .exchange-side > .pixel-btn.big,
#view-exchange .exchange-sell-all-btn {
  width: 100% !important;
  max-width: 100% !important;
  min-height: 56px !important;
  height: auto !important;
  box-sizing: border-box !important;
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  padding: 12px 14px !important;
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
  letter-spacing: 0.01em !important;
  text-align: left !important;
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  color: #0d1f0d !important;
  background: linear-gradient(180deg, #86efac, #22c55e) !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  box-shadow: 0 3px 0 #0a0806 !important;
}

#view-exchange .exchange-sell-all-ic {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(0, 0, 0, 0.25);
}

#view-exchange .exchange-sell-all-ic svg {
  display: block;
  stroke: #0d1f0d;
}

#view-exchange .exchange-sell-all-txt {
  flex: 1 1 auto;
  min-width: 0;
  display: block;
  text-align: left;
  white-space: normal !important;
  overflow: visible !important;
  word-break: normal;
  hyphens: none;
}

#view-exchange .exchange-side {
  /* rates scroll; botón siempre visible debajo */
  max-height: none !important;
}

#view-exchange .exchange-rates-panel {
  max-height: min(52vh, 420px);
  overflow-y: auto;
}

/* Stats */
#view-exchange #exchange-summary,
#view-exchange .exchange-stats-row {
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 10px !important;
  margin: 12px 0 !important;
}

@media (max-width: 900px) {
  #view-exchange #exchange-summary,
  #view-exchange .exchange-stats-row {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

#view-exchange .exchange-stat-card {
  background: rgba(0, 0, 0, 0.4) !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  padding: 12px 10px !important;
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.35) !important;
  text-align: center;
}

#view-exchange .exchange-stat-label {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 10px !important;
  font-weight: 800 !important;
  color: #a89a88 !important;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

#view-exchange .exchange-stat-value {
  font-family: "Fredoka", "Nunito", system-ui, sans-serif !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  color: #f8f0e0 !important;
}

#view-exchange .exchange-stat-card--inv .exchange-stat-value { color: #f87171 !important; }
#view-exchange .exchange-stat-card--value .exchange-stat-value { color: #6ee7b7 !important; }
#view-exchange .exchange-stat-card--sold .exchange-stat-value { color: #facc15 !important; }
#view-exchange .exchange-stat-card--bonus .exchange-stat-value { color: #7dd3fc !important; }

#view-exchange .exchange-stat-meta {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  color: #8a7a68 !important;
}

/* Harvest cards */
#view-exchange .exchange-harvest-card,
#view-exchange .berry-card {
  background: rgba(0, 0, 0, 0.4) !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  box-shadow: 0 0 0 1px rgba(196, 154, 32, 0.22) !important;
  backdrop-filter: none !important;
}

#view-exchange .exchange-harvest-name {
  color: #f8f0e0 !important;
}

#view-exchange .exchange-harvest-stock {
  color: #c8b8a0 !important;
}

#view-exchange .exchange-harvest-tier {
  background: rgba(232, 184, 48, 0.12) !important;
  border: 1px solid rgba(232, 184, 48, 0.4) !important;
  color: #facc15 !important;
}

#view-exchange .exchange-harvest-card .shine-btn,
#view-exchange .exchange-harvest-card button {
  border-radius: 0 !important;
  border: 2px solid #0a0806 !important;
  box-shadow: 0 2px 0 #0a0806 !important;
  font-family: "Nunito", system-ui, sans-serif !important;
  font-weight: 800 !important;
}

/* Empty */
#view-exchange #exchange-empty,
#view-exchange .empty-box {
  background: rgba(0, 0, 0, 0.35) !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  box-shadow: 0 0 0 1px rgba(196, 154, 32, 0.25) !important;
  font-family: "Nunito", system-ui, sans-serif !important;
  color: #c8b8a0 !important;
  padding: 24px 16px !important;
}

#view-exchange .empty-title {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-size: 16px !important;
  font-weight: 800 !important;
  color: #f0d060 !important;
}

#view-exchange #exchange-empty .pixel-btn,
#view-exchange .empty-box .pixel-btn {
  font-family: "Nunito", system-ui, sans-serif !important;
  font-weight: 800 !important;
  background: linear-gradient(180deg, #f0d060, #c49a20) !important;
  color: #1a1208 !important;
  border: 2px solid #0a0806 !important;
  border-radius: 0 !important;
  box-shadow: 0 3px 0 #0a0806 !important;
}

/* Grid spacing */
#view-exchange .exchange-grid {
  gap: 12px !important;
  margin-bottom: 4px;
}

#view-exchange .exchange-harvest-grid {
  gap: 12px !important;
}
