@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,500;0,600;0,700;1,500;1,600;1,700&display=swap');

/* ========================================================================== 
   SISTEMA DE DISEÑO: PREMIUM // TERCIPELO, VINO Y ORO
   Tema visual aislado. No modifica cálculos ni comportamiento del cotizador.
   ========================================================================== */

[data-theme="premium"] {
  --premium-black: #110e12;
  --premium-obsidian: #191419;
  --premium-wine: #4b1b2e;
  --premium-wine-light: #60273c;
  --premium-wine-deep: #29131e;
  --premium-gold: #c5a365;
  --premium-gold-light: #dfc58d;
  --premium-ivory: #f2eadc;
  --premium-muted: #c3b5ad;
  --premium-line: rgba(197, 163, 101, 0.34);
  --premium-line-soft: rgba(197, 163, 101, 0.2);
  --premium-surface: rgba(25, 20, 25, 0.96);
  --premium-surface-raised: rgba(39, 27, 35, 0.98);
  --premium-input: #171217;
  --premium-danger: #d88e91;
  --premium-success: #92b5a2;
  --premium-warning: #d7b873;

  --font-premium-heading: 'Cormorant Garamond', 'Georgia', serif;
  --font-premium-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-premium-data: 'JetBrains Mono', 'SF Mono', monospace;

  --background: transparent !important;
  --foreground: var(--premium-ivory) !important;
  --card: var(--premium-surface) !important;
  --card-foreground: var(--premium-ivory) !important;
  --muted: rgba(75, 27, 46, 0.42) !important;
  --muted-foreground: var(--premium-muted) !important;
  --border: var(--premium-line) !important;
  --input: rgba(197, 163, 101, 0.42) !important;
  --ring: var(--premium-gold) !important;
  --primary: var(--premium-gold) !important;
  --primary-hover: var(--premium-gold-light) !important;
  --primary-foreground: var(--premium-black) !important;
  --secondary: var(--premium-wine) !important;
  --secondary-foreground: var(--premium-ivory) !important;
  --destructive: var(--premium-danger) !important;
  --destructive-hover: #bd737a !important;
  --success: var(--premium-success) !important;

  --radius-sm: 5px !important;
  --radius-md: 8px 7px 9px 7px !important;
  --radius-lg: 11px 9px 12px 9px !important;
  --shadow-premium: 0 10px 28px rgba(0, 0, 0, 0.3) !important;
  --shadow-premium-soft: 0 4px 14px rgba(0, 0, 0, 0.22) !important;
  --premium-curtain:
    radial-gradient(ellipse at 50% 0%, rgba(205, 160, 99, 0.13), transparent 42%),
    linear-gradient(90deg,
      rgba(91, 35, 58, 0.68) 0%,
      rgba(32, 18, 25, 0.34) 8%,
      rgba(13, 11, 14, 0.62) 17%,
      rgba(79, 29, 49, 0.2) 27%,
      rgba(15, 12, 15, 0.68) 38%,
      rgba(12, 10, 12, 0.78) 50%,
      rgba(77, 28, 47, 0.2) 63%,
      rgba(14, 11, 14, 0.66) 76%,
      rgba(88, 32, 54, 0.48) 91%,
      rgba(15, 11, 14, 0.82) 100%),
    linear-gradient(180deg, #21141b 0%, #110e12 58%, #171015 100%);
}

/* Cortina de terciopelo sugerida con pliegues y luz ambiental en CSS. */
[data-theme="premium"] body,
[data-theme="premium"] .app-content {
  background-color: var(--premium-black) !important;
  background-image: var(--premium-curtain) !important;
  background-size: cover, cover, cover !important;
  background-position: center top !important;
  background-attachment: fixed !important;
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-body) !important;
  min-height: 100vh;
}

[data-theme="premium"] .main-content,
[data-theme="premium"] #cotizador-view,
[data-theme="premium"] #exclusividades-view,
[data-theme="premium"] .content-section {
  background: transparent !important;
}

[data-theme="premium"] .main-content {
  width: calc(100% - 44px) !important;
  max-width: 1680px !important;
  padding: 22px 16px !important;
  margin: 0 auto !important;
}

/* Encabezado tipo marquesina, con oro reservado para las acciones clave. */
/* Encabezado tipo marquesina de alta joyería: doble filete de oro y terciopelo suntuoso */
[data-theme="premium"] .app-header {
  background: linear-gradient(180deg, rgba(22, 17, 22, 0.97) 0%, rgba(14, 11, 14, 0.98) 100%) !important;
  border-top: 1px solid rgba(212, 175, 55, 0.35) !important;
  border-bottom: 3px double rgba(212, 175, 55, 0.65) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 235, 170, 0.2) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  padding: 10px 24px !important;
  gap: 12px !important;
  z-index: 1000;
  position: sticky;
  top: 0;
}

[data-theme="premium"] .header-left h1,
[data-theme="premium"] h1 {
  color: var(--premium-gold-light) !important;
  -webkit-text-fill-color: var(--premium-gold-light) !important;
  background: none !important;
  font-family: var(--font-premium-heading) !important;
  font-size: 2.05rem !important;
  font-style: italic !important;
  font-weight: 600 !important;
  letter-spacing: 0.02em !important;
  line-height: 1 !important;
  text-shadow: 0 2px 14px rgba(197, 163, 101, 0.22) !important;
  text-transform: none !important;
}

[data-theme="premium"] .header-left h1::after {
  content: 'EDICIÓN PRIVADA';
  display: inline-flex;
  align-items: center;
  margin-left: 12px;
  padding: 3px 9px;
  border: 1px solid rgba(212, 175, 55, 0.65);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(88, 28, 50, 0.45), rgba(45, 14, 25, 0.6));
  color: #f7e7be;
  font-family: var(--font-premium-body);
  font-size: 0.55rem;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 2px 6px rgba(0, 0, 0, 0.35);
  vertical-align: middle;
}

/* Conmutador de Modo: Broche Joya Oval de Alta Relojería */
[data-theme="premium"] .header-mode-switch {
  background: radial-gradient(ellipse at center, rgba(32, 22, 28, 0.95), rgba(12, 10, 13, 0.98)) !important;
  border: 1.5px solid rgba(212, 175, 55, 0.5) !important;
  border-radius: 999px !important;
  padding: 3px 4px !important;
  gap: 4px !important;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.7), 0 3px 10px rgba(0, 0, 0, 0.35) !important;
}

[data-theme="premium"] .mode-btn {
  color: var(--premium-muted) !important;
  border: 1px solid transparent !important;
  border-radius: 999px !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.80rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.02em !important;
  padding: 6px 16px !important;
  text-transform: none !important;
  transition: all 0.22s ease !important;
}

[data-theme="premium"] .mode-btn:hover {
  background: rgba(197, 163, 101, 0.12) !important;
  color: var(--premium-ivory) !important;
}

[data-theme="premium"] .mode-btn.active {
  background: linear-gradient(135deg, #6c223a 0%, #451424 100%) !important;
  border: 1px solid rgba(226, 201, 143, 0.7) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 2px 8px rgba(108, 34, 58, 0.5) !important;
  color: #fff6db !important;
  font-weight: 700 !important;
}

[data-theme="premium"] .mode-btn.active svg {
  stroke: #fff6db !important;
}

[data-theme="premium"] .header-right {
  gap: 10px !important;
}

[data-theme="premium"] .header-separator {
  background: linear-gradient(180deg, transparent, rgba(212, 175, 55, 0.55), transparent) !important;
  width: 1px !important;
  height: 26px !important;
}

/* Botones: Silueta de Lingote de Oro y Biseles de Luz */
[data-theme="premium"] .btn-primary,
[data-theme="premium"] #btn-guardar {
  background: linear-gradient(180deg, #f2dc9b 0%, #d4af37 42%, #aa8222 100%) !important;
  border: 1px solid #ffe8aa !important;
  border-radius: 6px !important;
  box-shadow: inset 0 1px 0 #ffffff, 0 4px 14px rgba(170, 130, 34, 0.4) !important;
  color: #1a1204 !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.84rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.03em !important;
  text-transform: none !important;
  min-height: 38px;
  padding: 8px 18px !important;
  transition: all 0.2s ease !important;
}

[data-theme="premium"] .btn-primary:hover,
[data-theme="premium"] #btn-guardar:hover {
  background: linear-gradient(180deg, #fff0bc 0%, #e5c353 42%, #bf942c 100%) !important;
  border-color: #ffffff !important;
  box-shadow: inset 0 1px 0 #ffffff, 0 6px 18px rgba(212, 175, 55, 0.55) !important;
  transform: translateY(-1px) !important;
}

[data-theme="premium"] .btn-primary svg,
[data-theme="premium"] #btn-guardar svg {
  stroke: #1a1204 !important;
  stroke-width: 2.2px !important;
}

[data-theme="premium"] .btn-add-card,
[data-theme="premium"] .btn-webhook-action {
  background: linear-gradient(180deg, rgba(82, 28, 50, 0.72) 0%, rgba(52, 17, 31, 0.85) 100%) !important;
  border: 1px solid rgba(212, 175, 55, 0.45) !important;
  border-radius: 6px !important;
  box-shadow: inset 0 1px 0 rgba(255, 215, 0, 0.22), 0 3px 8px rgba(0, 0, 0, 0.3) !important;
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-body) !important;
  font-weight: 600 !important;
  text-transform: none !important;
  min-height: 38px;
  padding: 8px 16px !important;
  transition: all 0.2s ease !important;
}

[data-theme="premium"] .btn-add-card:hover,
[data-theme="premium"] .btn-webhook-action:hover {
  background: linear-gradient(180deg, rgba(105, 38, 65, 0.85) 0%, rgba(68, 23, 41, 0.95) 100%) !important;
  border-color: var(--premium-gold) !important;
  box-shadow: inset 0 1px 0 rgba(255, 235, 170, 0.35), 0 5px 14px rgba(0, 0, 0, 0.4) !important;
  color: #fff9ea !important;
  transform: translateY(-1px) !important;
}

[data-theme="premium"] .btn-webhook-action.status-success {
  background: rgba(146, 181, 162, 0.14) !important;
  border-color: rgba(146, 181, 162, 0.55) !important;
  box-shadow: none !important;
  color: var(--premium-success) !important;
}

[data-theme="premium"] .btn-webhook-action.status-error {
  background: rgba(216, 142, 145, 0.14) !important;
  border-color: rgba(216, 142, 145, 0.55) !important;
  box-shadow: none !important;
  color: var(--premium-danger) !important;
}

/* Toolbar de Joyería: Estuche oval */
[data-theme="premium"] .header-toolbar {
  background: rgba(14, 11, 14, 0.85) !important;
  border: 1px solid rgba(212, 175, 55, 0.35) !important;
  border-radius: 999px !important;
  padding: 3px 5px !important;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5) !important;
}

[data-theme="premium"] .btn-ghost,
[data-theme="premium"] .btn-outline,
[data-theme="premium"] .toolbar-btn {
  background: transparent !important;
  border: 1px solid transparent !important;
  border-radius: 999px !important;
  box-shadow: none !important;
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.82rem !important;
  font-weight: 500 !important;
  padding: 5px 14px !important;
  text-transform: none !important;
  transition: all 0.18s ease !important;
}

[data-theme="premium"] .btn-ghost:hover,
[data-theme="premium"] .btn-outline:hover,
[data-theme="premium"] .toolbar-btn:hover {
  background: rgba(75, 27, 46, 0.55) !important;
  border-color: rgba(197, 163, 101, 0.5) !important;
  color: var(--premium-gold-light) !important;
}

/* Selector de Tema Joyel */
[data-theme="premium"] .theme-selector-box {
  background: linear-gradient(180deg, rgba(28, 22, 28, 0.9), rgba(15, 12, 15, 0.95)) !important;
  border: 1.5px solid rgba(212, 175, 55, 0.45) !important;
  border-radius: 999px !important;
  padding: 4px 14px !important;
  box-shadow: inset 0 1px 0 rgba(255, 235, 170, 0.2), 0 3px 8px rgba(0, 0, 0, 0.3) !important;
}

[data-theme="premium"] .theme-selector-box:hover {
  border-color: var(--premium-gold) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 0 12px rgba(212, 175, 55, 0.3) !important;
}

[data-theme="premium"] .theme-selector-box .theme-icon,
[data-theme="premium"] .theme-selector-box .theme-chevron {
  color: var(--premium-gold) !important;
}

[data-theme="premium"] .theme-select-native,
[data-theme="premium"] .theme-select-native option {
  background: var(--premium-obsidian) !important;
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-body) !important;
}

/* Datos del proyecto como placa de entrada, con filete dorado discreto. */
[data-theme="premium"] .project-info-bar {
  position: relative !important;
  background: linear-gradient(115deg, rgba(75, 27, 46, 0.88), rgba(25, 20, 25, 0.96)) !important;
  border: 1px solid var(--premium-line) !important;
  border-radius: 9px 7px 10px 7px !important;
  box-shadow: var(--shadow-premium-soft) !important;
  padding: 14px 18px !important;
  margin-bottom: 20px !important;
  overflow: visible !important;
}

[data-theme="premium"] .project-info-bar::before {
  display: none !important;
}

[data-theme="premium"] .project-info-bar > * {
  position: relative;
  z-index: 1;
}

[data-theme="premium"] .project-info-header {
  border-bottom: 1px solid var(--premium-line-soft) !important;
  padding-bottom: 8px !important;
  margin-bottom: 10px !important;
}

[data-theme="premium"] .project-info-pill {
  background: rgba(197, 163, 101, 0.12) !important;
  border: 1px solid rgba(197, 163, 101, 0.4) !important;
  border-radius: 4px !important;
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-body) !important;
  letter-spacing: 0.08em !important;
}

[data-theme="premium"] .project-info-desc {
  color: var(--premium-muted) !important;
  font-family: var(--font-premium-body) !important;
}

[data-theme="premium"] .project-info-grid {
  gap: 12px 14px !important;
}

[data-theme="premium"] .project-info-item label,
[data-theme="premium"] label {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.76rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
}

[data-theme="premium"] .project-info-item label svg,
[data-theme="premium"] label svg {
  color: var(--premium-gold) !important;
  stroke: var(--premium-gold) !important;
}

/* Superficies negras y vino; marcos exteriores selectivos para evitar ruido. */
[data-theme="premium"] .granel-card {
  --premium-card-accent: var(--premium-gold);
  position: relative !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
  background: rgba(25, 20, 25, 0.94) !important;
  border: 1px solid rgba(197, 163, 101, 0.32) !important;
  border-left: 3px solid var(--premium-card-accent) !important;
  border-radius: 9px 7px 10px 7px !important;
  box-shadow: var(--shadow-premium-soft) !important;
  padding: 24px 18px 16px !important;
  margin: 18px 0 !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease !important;
}

[data-theme="premium"] .granel-card.card-purple {
  --premium-card-accent: #c5a365;
}

[data-theme="premium"] .granel-card.card-blue {
  --premium-card-accent: #c58e9d;
}

[data-theme="premium"] .granel-card.card-teal {
  --premium-card-accent: #d0b77c;
}

[data-theme="premium"] .granel-card:hover {
  border-color: rgba(197, 163, 101, 0.56) !important;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.36) !important;
  transform: translateY(-1px) !important;
}

[data-theme="premium"] .granel-label {
  position: absolute !important;
  top: -12px !important;
  left: 22px !important;
  background: var(--premium-wine) !important;
  border: 1px solid var(--premium-card-accent) !important;
  border-radius: 5px !important;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.24) !important;
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.7rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.1em !important;
  padding: 4px 11px !important;
  text-transform: uppercase !important;
  transform: none !important;
}

[data-theme="premium"] .granel-header {
  gap: 10px !important;
  margin-bottom: 12px !important;
}

[data-theme="premium"] .granel-toggle {
  background: rgba(17, 14, 18, 0.84) !important;
  border: 1px solid var(--premium-line-soft) !important;
  border-radius: 6px !important;
  padding: 3px !important;
}

[data-theme="premium"] .granel-toggle-btn {
  color: var(--premium-muted) !important;
  border-radius: 4px !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.8rem !important;
}

[data-theme="premium"] .granel-toggle-btn.active {
  background: var(--premium-wine) !important;
  color: var(--premium-gold-light) !important;
  box-shadow: none !important;
}

[data-theme="premium"] .pt-calc-mode-toggle {
  background: rgba(17, 14, 18, 0.84) !important;
  border: 1px solid var(--premium-line-soft) !important;
  border-radius: 6px !important;
  padding: 2px !important;
}

[data-theme="premium"] .pt-mode-btn {
  color: var(--premium-muted) !important;
  border-radius: 4px !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.78rem !important;
  font-weight: 600 !important;
  padding: 2px 7px !important;
}

[data-theme="premium"] .pt-mode-btn.active {
  background: var(--premium-wine) !important;
  color: var(--premium-gold-light) !important;
  box-shadow: none !important;
}

[data-theme="premium"] .card-header,
[data-theme="premium"] .mo-card-header {
  border-bottom: 1px solid var(--premium-line-soft) !important;
}

[data-theme="premium"] .card-title,
[data-theme="premium"] .summary-title {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-heading) !important;
  font-size: 1.24rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.01em !important;
}

[data-theme="premium"] .section-badge,
[data-theme="premium"] .badge {
  background: rgba(197, 163, 101, 0.12) !important;
  border: 1px solid rgba(197, 163, 101, 0.42) !important;
  border-radius: 4px !important;
  box-shadow: none !important;
  color: var(--premium-gold-light) !important;
}

/* Tabla: lectura clara, tinta cálida y desplazamiento confinado al contenedor. */
[data-theme="premium"] .formulacion-layout,
[data-theme="premium"] .formulacion-layout > div,
[data-theme="premium"] .unified-right-grid,
[data-theme="premium"] .unified-right-grid > * {
  min-width: 0 !important;
}

[data-theme="premium"] .formulacion-layout {
  grid-template-columns: minmax(0, 1.5fr) minmax(380px, 0.9fr) !important;
  align-items: start !important;
  gap: 14px !important;
  width: 100% !important;
}

[data-theme="premium"] .table-container {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  overflow-x: auto !important;
  border: 1px solid var(--premium-line) !important;
  border-radius: 6px !important;
  background: rgba(17, 14, 18, 0.9) !important;
  box-shadow: none !important;
}

[data-theme="premium"] .formulacion-table {
  font-family: var(--font-premium-data) !important;
}

[data-theme="premium"] .formulacion-table th,
[data-theme="premium"] .exc-table th {
  background: linear-gradient(115deg, #4b1b2e, #351521) !important;
  border-bottom: 1px solid var(--premium-gold) !important;
  border-right: 1px solid rgba(197, 163, 101, 0.24) !important;
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.72rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.07em !important;
  padding: 9px 10px !important;
  text-transform: uppercase !important;
}

[data-theme="premium"] .formulacion-table td,
[data-theme="premium"] .exc-table td {
  background: rgba(25, 20, 25, 0.96) !important;
  border-bottom: 1px solid rgba(197, 163, 101, 0.14) !important;
  border-right: 1px solid rgba(197, 163, 101, 0.1) !important;
  color: var(--premium-ivory) !important;
  padding: 6px 8px !important;
}

[data-theme="premium"] .formulacion-table tbody tr:hover > td,
[data-theme="premium"] .exc-table tbody tr:hover > td {
  background: #35212b !important;
  color: #fff7e9 !important;
}

[data-theme="premium"] .formulacion-table tbody tr:hover > td:first-child,
[data-theme="premium"] .exc-table tbody tr:hover > td:first-child {
  box-shadow: inset 2px 0 0 var(--premium-gold) !important;
}

[data-theme="premium"] .formulacion-table input,
[data-theme="premium"] .exc-table input {
  background: transparent !important;
  border: 1px solid transparent !important;
  border-bottom-color: rgba(197, 163, 101, 0.26) !important;
  border-radius: 3px !important;
  box-shadow: none !important;
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-data) !important;
  min-height: 30px !important;
}

[data-theme="premium"] .formulacion-table input:focus,
[data-theme="premium"] .exc-table input:focus {
  background: var(--premium-input) !important;
  border-color: var(--premium-gold) !important;
  box-shadow: 0 0 0 2px rgba(197, 163, 101, 0.14) !important;
}

[data-theme="premium"] .formulacion-table .cell-total,
[data-theme="premium"] .formulacion-table .cell-subtotal,
[data-theme="premium"] .formulacion-table .subtotal-val {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-data) !important;
  font-weight: 700 !important;
}

[data-theme="premium"] .granel-card.card-purple .formulacion-table {
  min-width: 1010px !important;
}

[data-theme="premium"] .granel-card.card-blue .formulacion-table,
[data-theme="premium"] .granel-card.card-teal .formulacion-table {
  min-width: 640px !important;
}

/* Campos: carbón mate, texto marfil y foco dorado visible. */
[data-theme="premium"] .info-input,
[data-theme="premium"] .input-field,
[data-theme="premium"] .search-box,
[data-theme="premium"] .exc-search-input,
[data-theme="premium"] .exc-table-search {
  background: var(--premium-input) !important;
  border: 1px solid rgba(197, 163, 101, 0.32) !important;
  border-radius: 5px !important;
  box-shadow: none !important;
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-body) !important;
}

[data-theme="premium"] .input-field::placeholder,
[data-theme="premium"] .info-input::placeholder,
[data-theme="premium"] .search-input::placeholder,
[data-theme="premium"] .exc-search-input::placeholder {
  color: rgba(195, 181, 173, 0.68) !important;
}

[data-theme="premium"] .info-input:focus,
[data-theme="premium"] .input-field:focus,
[data-theme="premium"] .search-box:focus-within,
[data-theme="premium"] .exc-search-input:focus,
[data-theme="premium"] .exc-table-search:focus {
  background: #211820 !important;
  border-color: var(--premium-gold) !important;
  box-shadow: 0 0 0 2px rgba(197, 163, 101, 0.13) !important;
  outline: none !important;
}

[data-theme="premium"] .input-unit-badge {
  background: rgba(197, 163, 101, 0.14) !important;
  border: 1px solid rgba(197, 163, 101, 0.36) !important;
  border-radius: 4px !important;
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .search-input {
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-body) !important;
}

/* Resumen y KPI integrados en una sola pieza con acento dorado. */
[data-theme="premium"] .granel-card .resumen-card,
[data-theme="premium"] .exc-hero-card,
[data-theme="premium"] .exc-summary-card,
[data-theme="premium"] .exc-table-section,
[data-theme="premium"] .summary-section,
[data-theme="premium"] .mo-breakdown,
[data-theme="premium"] .exc-modal-card,
[data-theme="premium"] .modal-card {
  background: var(--premium-surface) !important;
  border: 1px solid var(--premium-line) !important;
  border-radius: 8px !important;
  box-shadow: var(--shadow-premium-soft) !important;
}

[data-theme="premium"] .granel-card .resumen-card {
  position: relative !important;
  top: auto !important;
  height: auto !important;
  align-self: start !important;
  width: 100% !important;
  min-width: 0 !important;
  padding: 12px !important;
}

[data-theme="premium"] .granel-card .resumen-card > .card-content,
[data-theme="premium"] .granel-card .unified-right-grid {
  flex: 0 0 auto !important;
  min-width: 0 !important;
  width: 100% !important;
  align-items: start !important;
}

[data-theme="premium"] .granel-card .unified-right-grid {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  gap: 10px !important;
}

[data-theme="premium"] .granel-card .unified-right-grid > * {
  min-width: 0 !important;
}

[data-theme="premium"] .granel-card .unified-col-summary {
  border-left: 1px solid var(--premium-line-soft) !important;
  padding-left: 10px !important;
}

[data-theme="premium"] .summary-section {
  background: transparent !important;
  border: 0 !important;
  border-bottom: 1px solid var(--premium-line-soft) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding: 0 0 9px !important;
  margin: 0 0 9px !important;
}

[data-theme="premium"] .summary-title {
  border-bottom: 1px solid var(--premium-line-soft) !important;
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-heading) !important;
  font-size: 1.2rem !important;
  font-weight: 600 !important;
  font-style: italic !important;
  letter-spacing: 0.01em !important;
  padding-bottom: 6px !important;
}

[data-theme="premium"] .summary-title::before {
  content: '✦' !important;
  color: var(--premium-gold) !important;
  font-size: 0.78rem !important;
}

[data-theme="premium"] .summary-grid {
  gap: 5px !important;
}

[data-theme="premium"] .summary-item {
  background: transparent !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(197, 163, 101, 0.14) !important;
  border-radius: 0 !important;
  padding: 5px 2px !important;
}

[data-theme="premium"] .summary-label {
  color: var(--premium-muted) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.82rem !important;
}

[data-theme="premium"] .summary-value {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-data) !important;
  font-size: 0.88rem !important;
  padding: 2px 4px !important;
}

[data-theme="premium"] .kpi-highlight {
  display: block !important;
  align-self: stretch !important;
  width: 100% !important;
  min-width: 0 !important;
  box-sizing: border-box !important;
  background: linear-gradient(120deg, rgba(75, 27, 46, 0.98), rgba(37, 22, 30, 0.98)) !important;
  border: 1px solid rgba(197, 163, 101, 0.68) !important;
  border-left: 3px solid var(--premium-gold) !important;
  border-radius: 7px !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.24) !important;
  color: var(--premium-ivory) !important;
  padding: 14px 20px !important;
  margin-top: 10px !important;
  overflow: hidden !important;
}

[data-theme="premium"] .kpi-label {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.75rem !important;
  letter-spacing: 0.1em !important;
}

[data-theme="premium"] .kpi-dual-label {
  color: var(--premium-muted) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.72rem !important;
}

[data-theme="premium"] .kpi-value {
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-data) !important;
  font-size: clamp(1.55rem, 2.1vw, 1.95rem) !important;
  font-weight: 700 !important;
  line-height: 1.15 !important;
  text-shadow: none !important;
  font-variant-numeric: tabular-nums !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

[data-theme="premium"] .kpi-dual-item {
  min-width: 0 !important;
}

[data-theme="premium"] .kpi-dual {
  width: 100% !important;
  justify-content: space-evenly !important;
  gap: 12px !important;
}

[data-theme="premium"] .kpi-dual-divider {
  background: var(--premium-line) !important;
}

[data-theme="premium"] .mo-data-card {
  background: rgba(17, 14, 18, 0.66) !important;
  border: 1px solid var(--premium-line-soft) !important;
  border-radius: 6px !important;
  box-shadow: none !important;
  padding: 10px !important;
  margin-bottom: 8px !important;
}

[data-theme="premium"] .mo-card-center {
  background: rgba(75, 27, 46, 0.42) !important;
  border: 1px solid var(--premium-line-soft) !important;
  border-radius: 4px !important;
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .mo-breakdown-title,
[data-theme="premium"] .mo-breakdown-total {
  border-color: var(--premium-line-soft) !important;
}

[data-theme="premium"] .mo-breakdown-total span:last-child {
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .btn-add-mo,
[data-theme="premium"] .btn-add-row {
  background: rgba(75, 27, 46, 0.28) !important;
  border: 1px dashed rgba(197, 163, 101, 0.42) !important;
  border-radius: 5px !important;
  box-shadow: none !important;
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  min-height: 36px;
  padding: 6px 9px !important;
}

[data-theme="premium"] .btn-add-mo:hover,
[data-theme="premium"] .btn-add-row:hover {
  background: rgba(96, 39, 60, 0.5) !important;
  border-color: var(--premium-gold) !important;
  color: var(--premium-ivory) !important;
}

/* Resultados de búsqueda, historial y ventanas. */
[data-theme="premium"] .search-results,
[data-theme="premium"] .ref-autocomplete-list,
[data-theme="premium"] .add-card-menu,
[data-theme="premium"] .drawer-panel {
  background: var(--premium-surface-raised) !important;
  border: 1px solid var(--premium-line) !important;
  border-radius: 7px !important;
  box-shadow: var(--shadow-premium) !important;
}

[data-theme="premium"] .search-result-item,
[data-theme="premium"] .ref-autocomplete-item {
  border-bottom: 1px solid var(--premium-line-soft) !important;
}

[data-theme="premium"] .search-result-item:hover,
[data-theme="premium"] .ref-autocomplete-item:hover {
  background: rgba(96, 39, 60, 0.45) !important;
}

[data-theme="premium"] .search-result-name,
[data-theme="premium"] .drawer-item-title {
  color: var(--premium-ivory) !important;
}

[data-theme="premium"] .search-result-ref,
[data-theme="premium"] .ref-ac-ref,
[data-theme="premium"] .drawer-item-total {
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .drawer-item {
  background: rgba(17, 14, 18, 0.72) !important;
  border: 1px solid var(--premium-line-soft) !important;
  border-radius: 6px !important;
}

[data-theme="premium"] .modal-overlay,
[data-theme="premium"] .exc-modal-overlay,
[data-theme="premium"] .drawer-overlay {
  background: rgba(7, 5, 8, 0.78) !important;
  backdrop-filter: blur(3px) !important;
  -webkit-backdrop-filter: blur(3px) !important;
}

[data-theme="premium"] .modal-card,
[data-theme="premium"] .exc-modal-card {
  background: linear-gradient(145deg, #241820, #151116) !important;
  border: 1px solid rgba(197, 163, 101, 0.48) !important;
  border-radius: 9px !important;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.44) !important;
}

[data-theme="premium"] .modal-header,
[data-theme="premium"] .exc-modal-header,
[data-theme="premium"] .modal-footer,
[data-theme="premium"] .exc-modal-footer {
  background: rgba(75, 27, 46, 0.28) !important;
  border-color: var(--premium-line-soft) !important;
}

[data-theme="premium"] .modal-header h3,
[data-theme="premium"] .exc-modal-header h3 {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-heading) !important;
  font-size: 1.35rem !important;
  font-style: italic !important;
}

[data-theme="premium"] .drawer-header,
[data-theme="premium"] .drawer-search {
  border-color: var(--premium-line-soft) !important;
  background: rgba(17, 14, 18, 0.82) !important;
}

[data-theme="premium"] .drawer-title {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-heading) !important;
  font-size: 1.35rem !important;
  font-style: italic !important;
}

/* Validador: misma paleta y estados semánticos reconocibles. */
[data-theme="premium"] #exclusividades-view,
[data-theme="premium"] .exclusividades-container {
  color: var(--premium-ivory) !important;
  font-family: var(--font-premium-body) !important;
}

[data-theme="premium"] #exclusividades-view h1,
[data-theme="premium"] #exclusividades-view h2,
[data-theme="premium"] #exclusividades-view h3,
[data-theme="premium"] #exclusividades-view h4 {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-heading) !important;
  font-style: italic !important;
}

[data-theme="premium"] .exc-hero-card,
[data-theme="premium"] .exc-table-section,
[data-theme="premium"] .exc-summary-card,
[data-theme="premium"] .exc-empty-state,
[data-theme="premium"] .exc-modal-info-box,
[data-theme="premium"] .exc-modal-stock-card {
  background: var(--premium-surface) !important;
  border-color: var(--premium-line) !important;
  border-radius: 7px !important;
  box-shadow: var(--shadow-premium-soft) !important;
}

[data-theme="premium"] .exc-table-toolbar,
[data-theme="premium"] .exc-search-dropdown,
[data-theme="premium"] .exc-filter-chips,
[data-theme="premium"] .exc-code-tag {
  background: rgba(17, 14, 18, 0.92) !important;
  border-color: var(--premium-line-soft) !important;
  color: var(--premium-muted) !important;
}

[data-theme="premium"] .exc-filter-btn,
[data-theme="premium"] .exc-chip {
  color: var(--premium-muted) !important;
}

[data-theme="premium"] .exc-filter-btn.active,
[data-theme="premium"] .exc-chip.active {
  background: rgba(75, 27, 46, 0.55) !important;
  color: var(--premium-gold-light) !important;
  box-shadow: none !important;
}

[data-theme="premium"] .exc-quick-tag-btn,
[data-theme="premium"] .exc-btn-detail,
[data-theme="premium"] .btn-view-lists {
  background: rgba(75, 27, 46, 0.24) !important;
  border: 1px solid var(--premium-line-soft) !important;
  border-radius: 5px !important;
  color: var(--premium-ivory) !important;
}

[data-theme="premium"] .exc-quick-tag-btn:hover,
[data-theme="premium"] .exc-btn-detail:hover,
[data-theme="premium"] .btn-view-lists:hover {
  background: rgba(96, 39, 60, 0.48) !important;
  border-color: var(--premium-gold) !important;
}

[data-theme="premium"] .exc-status-badge.is-exclusive,
[data-theme="premium"] .exc-tag-exclusive,
[data-theme="premium"] .badge-exclusive {
  background: rgba(197, 163, 101, 0.12) !important;
  border: 1px solid rgba(197, 163, 101, 0.4) !important;
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .exc-status-badge.is-standard,
[data-theme="premium"] .exc-tag-shared,
[data-theme="premium"] .badge-standard {
  background: rgba(146, 181, 162, 0.1) !important;
  border: 1px solid rgba(146, 181, 162, 0.32) !important;
  color: var(--premium-success) !important;
}

[data-theme="premium"] .exc-stock-delta.is-sobra,
[data-theme="premium"] .exc-stock-pill.sobra,
[data-theme="premium"] .badge-active-granel {
  background: rgba(146, 181, 162, 0.12) !important;
  border-color: rgba(146, 181, 162, 0.34) !important;
  color: var(--premium-success) !important;
}

[data-theme="premium"] .exc-stock-delta.is-falta,
[data-theme="premium"] .exc-stock-pill.falta {
  background: rgba(216, 142, 145, 0.12) !important;
  border-color: rgba(216, 142, 145, 0.36) !important;
  color: var(--premium-danger) !important;
}

[data-theme="premium"] .exc-stock-delta.is-balance,
[data-theme="premium"] .exc-stock-pill.neutro,
[data-theme="premium"] .badge-inactive-granel {
  background: rgba(195, 181, 173, 0.08) !important;
  border-color: var(--premium-line-soft) !important;
  color: var(--premium-muted) !important;
}

[data-theme="premium"] .exc-mp-code,
[data-theme="premium"] .exc-search-item-ref,
[data-theme="premium"] .exc-otros-main.is-active {
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .exc-metric-col.metric-exclusive .exc-metric-num {
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .exc-metric-col.metric-deficit .exc-metric-num {
  color: var(--premium-danger) !important;
}

[data-theme="premium"] #exclusividades-view [style*="#059669"] {
  color: var(--premium-success) !important;
}

[data-theme="premium"] #exclusividades-view [style*="#dc2626"] {
  color: var(--premium-danger) !important;
}

[data-theme="premium"] #exclusividades-view [style*="#7c3aed"],
[data-theme="premium"] #exclusividades-view [style*="#8b5cf6"],
[data-theme="premium"] #exclusividades-view [style*="#6366f1"] {
  color: var(--premium-gold-light) !important;
}

/* Estados de sincronización y avisos. */
[data-theme="premium"] .sync-timer-ring {
  background: rgba(197, 163, 101, 0.08) !important;
  border-color: var(--premium-gold) !important;
  box-shadow: none !important;
}

[data-theme="premium"] #sync-countdown-text {
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .sync-progress-bar {
  background: linear-gradient(90deg, var(--premium-wine), var(--premium-gold)) !important;
}

[data-theme="premium"] .sync-feedback-icon.success {
  background: rgba(146, 181, 162, 0.12) !important;
  border-color: var(--premium-success) !important;
  color: var(--premium-success) !important;
}

[data-theme="premium"] .sync-feedback-icon.warning,
[data-theme="premium"] .sync-alert-banner {
  background: rgba(215, 184, 115, 0.12) !important;
  border-color: rgba(215, 184, 115, 0.4) !important;
  color: var(--premium-warning) !important;
}

[data-theme="premium"] .sync-alert-banner p {
  color: var(--premium-warning) !important;
}

[data-theme="premium"] .sync-feedback-icon.error {
  background: rgba(216, 142, 145, 0.12) !important;
  border-color: var(--premium-danger) !important;
  color: var(--premium-danger) !important;
}

[data-theme="premium"] .toast.success {
  background: var(--premium-success) !important;
  color: var(--premium-black) !important;
}

[data-theme="premium"] .toast.error {
  background: var(--premium-danger) !important;
  color: var(--premium-black) !important;
}

/* Login también adopta el tema si el usuario no inició sesión. */
[data-theme="premium"] .login-overlay {
  background: var(--premium-curtain) !important;
}

[data-theme="premium"] .login-card {
  background: var(--premium-surface) !important;
  border: 1px solid var(--premium-line) !important;
  border-radius: 10px !important;
  box-shadow: var(--shadow-premium) !important;
}

[data-theme="premium"] .login-card h2 {
  color: var(--premium-gold-light) !important;
  font-family: var(--font-premium-heading) !important;
  font-size: 2rem !important;
  font-style: italic !important;
}

[data-theme="premium"] .login-card p {
  color: var(--premium-muted) !important;
}

/* Entrada suave y microinteracciones puntuales; sin movimiento continuo. */
@keyframes premium-arrive {
  from { opacity: 0; transform: translateY(7px); }
  to { opacity: 1; transform: translateY(0); }
}

[data-theme="premium"] .project-info-bar,
[data-theme="premium"] .granel-card,
[data-theme="premium"] .exc-hero-card {
  animation: premium-arrive 220ms ease-out both;
}

[data-theme="premium"] button:focus-visible,
[data-theme="premium"] a:focus-visible,
[data-theme="premium"] input:focus-visible,
[data-theme="premium"] select:focus-visible,
[data-theme="premium"] [tabindex]:focus-visible {
  outline: 2px solid var(--premium-gold-light) !important;
  outline-offset: 2px !important;
}

/* Responsive: apilar antes de que las dos columnas se compriman demasiado. */
@media screen and (max-width: 1400px) {
  [data-theme="premium"] .formulacion-layout {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 12px !important;
  }

  [data-theme="premium"] .unified-right-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: 8px !important;
  }

  [data-theme="premium"] .unified-col-summary {
    border-left: 1px solid var(--premium-line-soft) !important;
    border-top: none !important;
    padding: 0 0 0 9px !important;
  }
}

@media screen and (max-width: 1100px) {
  [data-theme="premium"] .app-header {
    height: auto !important;
    padding: 10px 14px !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 9px !important;
  }

  [data-theme="premium"] .header-left,
  [data-theme="premium"] .header-right {
    width: 100% !important;
    flex-wrap: wrap !important;
  }

  [data-theme="premium"] .header-actions-group {
    flex: 1 1 100% !important;
    flex-wrap: wrap !important;
  }

  [data-theme="premium"] .header-actions-group .btn-add-card,
  [data-theme="premium"] .header-actions-group .btn-webhook-action {
    flex: 1 1 160px !important;
    justify-content: center !important;
  }

  [data-theme="premium"] .header-separator {
    display: none !important;
  }

  [data-theme="premium"] .main-content {
    width: calc(100% - 24px) !important;
    padding: 14px 8px !important;
  }
}

@media screen and (max-width: 600px) {
  [data-theme="premium"] .app-header {
    position: relative !important;
    padding: 9px 10px !important;
  }

  [data-theme="premium"] .header-left h1::after {
    display: none !important;
  }

  [data-theme="premium"] .header-mode-switch {
    width: 100% !important;
    justify-content: center !important;
    margin: 0 !important;
  }

  [data-theme="premium"] .header-right {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 7px !important;
  }

  [data-theme="premium"] .header-actions-group,
  [data-theme="premium"] .header-toolbar,
  [data-theme="premium"] #btn-guardar,
  [data-theme="premium"] .theme-selector-box {
    grid-column: 1 / -1 !important;
    width: 100% !important;
  }

  [data-theme="premium"] .header-actions-group {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 7px !important;
  }

  [data-theme="premium"] .header-toolbar {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  [data-theme="premium"] .main-content {
    width: calc(100% - 16px) !important;
    padding: 10px 4px !important;
  }

  [data-theme="premium"] .project-info-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 9px !important;
  }

  [data-theme="premium"] .granel-card {
    padding: 24px 11px 12px !important;
  }

  [data-theme="premium"] .unified-right-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  [data-theme="premium"] .unified-col-summary {
    border-left: none !important;
    border-top: 1px solid var(--premium-line-soft) !important;
    padding: 9px 0 0 !important;
  }

  [data-theme="premium"] body {
    background-attachment: scroll !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  [data-theme="premium"] *,
  [data-theme="premium"] *::before,
  [data-theme="premium"] *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* Badges generados dinámicamente y acciones destructivas. */
[data-theme="premium"] .granel-card .formulacion-table td:nth-child(5) span {
  background: rgba(197, 163, 101, 0.12) !important;
  border: 1px solid rgba(197, 163, 101, 0.34) !important;
  border-radius: 4px !important;
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .granel-card span[title*="EXCLUSIVA"],
[data-theme="premium"] .granel-card span[title*="Exclusiva"] {
  background: rgba(197, 163, 101, 0.12) !important;
  border: 1px solid rgba(197, 163, 101, 0.4) !important;
  border-radius: 4px !important;
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .granel-card span[title*="COMPARTIDA"],
[data-theme="premium"] .granel-card span[title*="Compartida"] {
  background: rgba(146, 181, 162, 0.1) !important;
  border: 1px solid rgba(146, 181, 162, 0.32) !important;
  border-radius: 4px !important;
  color: var(--premium-success) !important;
}

[data-theme="premium"] .granel-card span[title*="cotización"] {
  background: rgba(216, 142, 145, 0.12) !important;
  border: 1px solid rgba(216, 142, 145, 0.4) !important;
  border-radius: 4px !important;
  color: var(--premium-danger) !important;
}

[data-theme="premium"] .btn-remove-row,
[data-theme="premium"] .btn-remove-card,
[data-theme="premium"] .mo-card-remove {
  background: transparent !important;
  border: 1px solid transparent !important;
  border-radius: 4px !important;
  box-shadow: none !important;
  color: var(--premium-muted) !important;
  transform: none !important;
}

[data-theme="premium"] .btn-remove-row:hover,
[data-theme="premium"] .btn-remove-card:hover,
[data-theme="premium"] .mo-card-remove:hover {
  background: rgba(216, 142, 145, 0.12) !important;
  border-color: rgba(216, 142, 145, 0.45) !important;
  color: var(--premium-danger) !important;
}

[data-theme="premium"] .exc-empty-icon {
  background: rgba(75, 27, 46, 0.38) !important;
  color: var(--premium-gold-light) !important;
}

[data-theme="premium"] .exc-hero-title-group h2 svg,
[data-theme="premium"] .exc-hero-title-group h2 i {
  color: var(--premium-gold) !important;
}

[data-theme="premium"] .exc-dot-deficit {
  background: var(--premium-danger) !important;
}

[data-theme="premium"] .exc-dot-surplus {
  background: var(--premium-success) !important;
}

[data-theme="premium"] input:-webkit-autofill,
[data-theme="premium"] input:-webkit-autofill:hover,
[data-theme="premium"] input:-webkit-autofill:focus,
[data-theme="premium"] input:-webkit-autofill:active {
  -webkit-text-fill-color: var(--premium-ivory) !important;
  -webkit-box-shadow: 0 0 0 1000px var(--premium-input) inset !important;
  box-shadow: 0 0 0 1000px var(--premium-input) inset !important;
  caret-color: var(--premium-ivory) !important;
  transition: background-color 99999s ease-out 0s;
}

[data-theme="premium"] input:autofill {
  color: var(--premium-ivory) !important;
  background: var(--premium-input) !important;
}

[data-theme="premium"] .quote-status {
  border-radius: 4px !important;
  font-family: var(--font-premium-body) !important;
  font-size: 0.72rem !important;
  font-weight: 700 !important;
}

[data-theme="premium"] .quote-status--unquoted {
  background: rgba(216, 142, 145, 0.16) !important;
  border-color: rgba(216, 142, 145, 0.56) !important;
  color: #f0b4b4 !important;
}

[data-theme="premium"] .quote-status--quoting {
  background: rgba(242, 234, 220, 0.08) !important;
  border-color: rgba(242, 234, 220, 0.42) !important;
  color: #eadfe5 !important;
}

/* Esta columna lleva otros badges dorados: forzar contraste para los estados. */
[data-theme="premium"] .granel-card .formulacion-table td:nth-child(5) .quote-status--unquoted {
  background: rgba(216, 142, 145, 0.2) !important;
  border-color: #d88e91 !important;
  box-shadow: inset 2px 0 0 #d88e91 !important;
  color: #ffd1d1 !important;
  font-size: 0.75rem !important;
  padding: 3px 8px !important;
  text-transform: uppercase !important;
}

[data-theme="premium"] .granel-card .formulacion-table td:nth-child(5) .quote-status--quoting {
  background: rgba(242, 234, 220, 0.1) !important;
  border-color: rgba(242, 234, 220, 0.55) !important;
  color: #f3e9e4 !important;
  font-size: 0.75rem !important;
  padding: 3px 8px !important;
}

/* Filetes vegetales dorados en las esquinas del valor total. */
[data-theme="premium"] .kpi-highlight {
  isolation: isolate !important;
  --premium-kpi-flourish: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 160 100' fill='none' stroke='%23C5A365' stroke-opacity='.78' stroke-width='1.25' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M158 4 C129 11 141 29 115 36 C91 42 103 61 75 68 C48 74 53 91 5 98'/%3E%3Cpath d='M132 15 C121 5 110 8 113 21 C124 24 132 21 132 15Z'/%3E%3Cpath d='M116 36 C128 27 139 32 135 43 C124 47 116 44 116 36Z'/%3E%3Cpath d='M91 48 C81 38 70 42 73 54 C84 58 91 56 91 48Z'/%3E%3Cpath d='M74 69 C84 60 95 64 92 75 C81 79 74 77 74 69Z'/%3E%3Cpath d='M48 74 C43 67 34 69 36 77 C29 74 23 80 29 85 C23 91 29 97 36 92 C38 100 46 98 47 91 C53 96 60 91 55 85 C61 80 56 75 50 78 C52 71 46 69 48 74Z'/%3E%3Ccircle cx='5' cy='98' r='1.8' fill='%23C5A365'/%3E%3C/svg%3E");
  position: relative !important;
  overflow: hidden !important;
}

/* Adornos decorativos de esquinas ocultos para garantizar cero sobreposición en números y etiquetas */
[data-theme="premium"] .kpi-highlight::before,
[data-theme="premium"] .kpi-highlight::after {
  display: none !important;
}

[data-theme="premium"] .side-panel-section {
  background: transparent !important;
  border: none !important;
  border-bottom: 1px solid var(--premium-line-soft) !important;
  border-radius: 0 !important;
  padding: 0 0 14px 0 !important;
  box-shadow: none !important;
}

[data-theme="premium"] .side-panel-section:last-of-type,
[data-theme="premium"] .side-panel-section.side-panel-financial {
  border-bottom: none !important;
  padding-bottom: 0 !important;
}

[data-theme="premium"] .fin-margen-box {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 4px 0 0 0 !important;
  box-shadow: none !important;
}

[data-theme="premium"] .fin-input-badge-wrap input,
[data-theme="premium"] .fin-num-input {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

/* Barra de Navegación Rápida (Quick-Nav) en Terciopelo Pro - Diseño sobrio y sin sobrecarga */
[data-theme="premium"] .quick-nav-bar {
  background: rgba(25, 20, 25, 0.94) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(197, 163, 101, 0.35) !important;
  border-radius: 8px !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 16px rgba(75, 27, 46, 0.35) !important;
}

[data-theme="premium"] .quick-nav-label {
  color: #dfc58d !important;
}

[data-theme="premium"] .quick-nav-label svg {
  color: #c5a365 !important;
}

[data-theme="premium"] .quick-nav-pill {
  background: rgba(39, 27, 35, 0.95) !important;
  border: 1.5px solid rgba(197, 163, 101, 0.3) !important;
  border-radius: 6px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
}

[data-theme="premium"] .quick-nav-pill:hover {
  border-color: #dfc58d !important;
  box-shadow: 0 4px 14px rgba(197, 163, 101, 0.3) !important;
}

[data-theme="premium"] .pill-purple .quick-nav-pill-dot {
  background: #c084fc !important;
  box-shadow: 0 0 6px rgba(192, 132, 252, 0.6) !important;
}
[data-theme="premium"] .pill-blue .quick-nav-pill-dot {
  background: #38bdf8 !important;
  box-shadow: 0 0 6px rgba(56, 189, 248, 0.6) !important;
}
[data-theme="premium"] .pill-teal .quick-nav-pill-dot {
  background: #dfc58d !important;
  box-shadow: 0 0 6px rgba(223, 197, 141, 0.6) !important;
}

[data-theme="premium"] .quick-nav-pill-title {
  color: #f2eadc !important;
}

[data-theme="premium"] .quick-nav-pill-val {
  background: rgba(75, 27, 46, 0.7) !important;
  color: #dfc58d !important;
  border: 1px solid rgba(197, 163, 101, 0.3) !important;
}

[data-theme="premium"] .quick-nav-add-btn {
  background: rgba(39, 27, 35, 0.85) !important;
  border: 1.5px dashed rgba(197, 163, 101, 0.45) !important;
  border-radius: 6px !important;
  color: #dfc58d !important;
}

[data-theme="premium"] .quick-nav-add-btn:hover {
  background: rgba(75, 27, 46, 0.8) !important;
  border-color: #dfc58d !important;
  color: #f2eadc !important;
}

/* Botones de Mano de Obra (MOD) en Terciopelo Pro */
[data-theme="premium"] .btn-mo-action {
  background: rgba(39, 27, 35, 0.95) !important;
  border: 1.5px solid rgba(197, 163, 101, 0.35) !important;
  color: #f2eadc !important;
  border-radius: 6px !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25) !important;
}

[data-theme="premium"] .btn-mo-action:hover {
  background: rgba(75, 27, 46, 0.85) !important;
  border-color: #dfc58d !important;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(197, 163, 101, 0.25) !important;
}

[data-theme="premium"] .btn-mo-predict {
  background: rgba(75, 27, 46, 0.75) !important;
  border: 1.5px solid rgba(197, 163, 101, 0.45) !important;
  color: #dfc58d !important;
  border-radius: 6px !important;
}

[data-theme="premium"] .btn-mo-predict:hover {
  background: rgba(91, 35, 58, 0.95) !important;
  border-color: #dfc58d !important;
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(197, 163, 101, 0.3) !important;
}

[data-theme="premium"] .btn-mo-escalera {
  background: rgba(25, 20, 25, 0.9) !important;
  border: 1.5px solid rgba(197, 163, 101, 0.45) !important;
  color: #c5a365 !important;
  border-radius: 6px !important;
}

[data-theme="premium"] .btn-mo-escalera:hover {
  background: rgba(75, 27, 46, 0.75) !important;
  border-color: #dfc58d !important;
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(197, 163, 101, 0.3) !important;
}

/* Resultados de Búsqueda MOD en Terciopelo Pro */
[data-theme="premium"] .search-results {
  background: rgba(30, 22, 28, 0.98) !important;
  border: 1px solid rgba(197, 163, 101, 0.45) !important;
  border-radius: 8px !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.75), 0 0 15px rgba(75, 27, 46, 0.35) !important;
}

[data-theme="premium"] .search-result-item {
  border-bottom: 1px solid rgba(197, 163, 101, 0.15) !important;
}

[data-theme="premium"] .search-result-item:hover {
  background: rgba(75, 27, 46, 0.7) !important;
  border-left: 3px solid #dfc58d !important;
}

[data-theme="premium"] .search-result-name {
  color: #f2eadc !important;
}

[data-theme="premium"] .search-result-ref {
  color: #dfc58d !important;
}

[data-theme="premium"] .search-no-results {
  color: #c5a365 !important;
}

[data-theme="premium"] .mo-search-badge {
  background: rgba(75, 27, 46, 0.85) !important;
  color: #dfc58d !important;
  border: 1px solid rgba(197, 163, 101, 0.35) !important;
}

[data-theme="premium"] .mo-search-dur,
[data-theme="premium"] .mo-search-emp {
  color: #c5a365 !important;
  opacity: 0.9 !important;
}

