/* ═══════════════════════════════════════════════════════════
   Deck Features — Storm Theme Stylesheet
   ═══════════════════════════════════════════════════════════ */

/* ── Deck Title Icon ── */
.deck-title-icon {
  width: 28px;
  height: 28px;
  vertical-align: middle;
}

/* ── Deck Breadcrumb (match category-page style) ── */
.deck-page .storm-breadcrumb {
  background: rgba(255,255,255,0.75);
  border: 1px solid rgba(98,0,234,0.14);
  border-radius: 14px 4px 14px 4px;
  padding: 8px 12px;
  margin-bottom: 14px !important;
  position: relative;
  backdrop-filter: blur(2px);
}
.deck-page .storm-breadcrumb::after {
  content: '';
  position: absolute;
  left: 10px; right: 10px; bottom: -1px;
  height: 1px;
  background: rgba(98,0,234,0.16);
  border-radius: 1px;
}
.deck-page .storm-breadcrumb > li {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-tech);
  font-size: 14px;
  color: #55627a;
}
.deck-page .storm-breadcrumb > li > a {
  color: #5d38b4;
  font-weight: 600;
}
.deck-page .storm-breadcrumb > li + li:before {
  content: '\203A';
  color: #9b86d8;
  padding: 0 8px;
  font-weight: 700;
}

/* ── Tighter gap between filter form and grid ── */
.deck-page .storm-card.mb-4 {
  margin-bottom: 0.5rem !important;
}
.deck-page .cyber-frame-horizontal {
  margin-top: 40px !important;
}

/* ── Deck Grid (6 columns on desktop) ── */
.deck-products-grid {
  grid-template-columns: repeat(2, 1fr) !important;
}
@media (min-width: 768px) {
  .deck-products-grid { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (min-width: 992px) {
  .deck-products-grid { grid-template-columns: repeat(4, 1fr) !important; }
}
@media (min-width: 1200px) {
  .deck-products-grid { grid-template-columns: repeat(6, minmax(0, 1fr)) !important; }
}

/* ── Deck Thumb (listing page — matches product-thumb) ── */
.deck-thumb .image {
  background: #1a1a2e;
}

.deck-thumb .image img {
  object-fit: cover;
  object-position: center 30%;
}

.deck-thumb-placeholder {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1a1a2e 0%, #2d1b69 100%);
  color: #fff;
}

/* Overlay on top of image: mana pips + badges */
.deck-thumb-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 10px 12px;
  background: linear-gradient(transparent 0%, rgba(0,0,0,0.85) 100%);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  z-index: 2;
}

.deck-thumb-mana {
  display: flex;
  gap: 5px;
  align-items: center;
}

.deck-thumb-mana .deck-mana-pip {
  background: none;
  width: auto;
  height: auto;
}

.deck-thumb-mana .mana-svg-pip {
  width: 22px !important;
  height: 22px !important;
  position: static !important;
  object-fit: contain !important;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.6));
}

.deck-thumb-badges {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.deck-thumb-badges .badge-format,
.deck-thumb-badges .badge-archetype {
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.4);
}

.deck-thumb-stats {
  display: flex;
  gap: 10px;
  color: #888;
}

.deck-thumb-stats span {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

/* ── Mana Pips (shared) ── */
.deck-mana-pip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
}

.deck-mana-pip-lg {
  width: 32px;
  height: 32px;
  background: rgba(98, 0, 234, 0.12);
}

/* SVG mana icons */
.mana-svg-pip {
  width: 18px;
  height: 18px;
  /* SVGs are natively white — no filter needed on dark backgrounds */
}

.mana-svg-pip-lg {
  width: 22px;
  height: 22px;
  filter: brightness(0) saturate(100%); /* dark on light backgrounds */
}

.mana-svg-icon {
  width: 16px;
  height: 16px;
  opacity: 0.85;
  filter: brightness(0); /* fallback dark */
  transition: opacity 0.15s, filter 0.15s;
}

/* Per-color mana tints (white SVGs → brightness(0) to black → invert+sepia+saturate+hue-rotate to target color) */
.mana-w .mana-svg-icon { filter: brightness(0) invert(78%) sepia(100%) saturate(400%) hue-rotate(338deg); }     /* gold #FFD735 */
.mana-u .mana-svg-icon { filter: brightness(0) invert(35%) sepia(100%) saturate(2000%) hue-rotate(185deg); }    /* blue #008DF3 */
.mana-b .mana-svg-icon { filter: brightness(0); }                                                                /* black */
.mana-r .mana-svg-icon { filter: brightness(0) invert(50%) sepia(100%) saturate(10000%) hue-rotate(350deg); }   /* red #FF0024 */
.mana-g .mana-svg-icon { filter: brightness(0) invert(30%) sepia(100%) saturate(1500%) hue-rotate(80deg); }     /* green #1A9500 */

.deck-color-toggle.active .mana-svg-icon {
  opacity: 1;
  filter: none; /* white icons when toggle is active (dark bg) */
}

/* ── Badges ── */
.badge-format {
  background: rgba(98, 0, 234, 0.12);
  color: var(--accent-primary, #6200ea);
  font-weight: 500;
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 4px;
}

.badge-archetype {
  background: rgba(0, 150, 136, 0.12);
  color: #00796b;
  font-weight: 500;
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 4px;
}

.badge-tier {
  background: rgba(255, 152, 0, 0.12);
  color: #e65100;
  font-weight: 500;
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 4px;
}

/* ── Color filter toggles ── */
.deck-color-toggle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid #ddd;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s;
  padding: 0;
}

.deck-color-toggle:hover {
  border-color: var(--accent-primary, #6200ea);
}

.deck-color-toggle.active {
  border-color: var(--accent-primary, #6200ea);
  background: var(--accent-primary, #6200ea);
  color: #fff;
}

/* ── Detail page ── */
.deck-detail-title {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 1.8rem;
  font-weight: 700;
  margin: 0 0 8px;
  text-transform: uppercase;
}

.deck-detail-badges {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}

.deck-detail-author {
  font-size: 0.9rem;
  color: #666;
}

.deck-detail-description {
  font-size: 0.9rem;
  color: #444;
  line-height: 1.5;
}

/* Stats panel (original — used on listing) */
.deck-stats-panel {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.deck-stat {
  background: #f8f8fa;
  border-radius: 8px;
  padding: 10px;
  text-align: center;
}

.deck-stat-value {
  display: block;
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent-primary, #6200ea);
  line-height: 1;
}

.deck-stat-label {
  display: block;
  font-size: 0.7rem;
  color: #999;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 2px;
}

/* Stats compact (detail right sidebar) */
.deck-stats-compact {
  display: flex;
  gap: 4px;
  margin-bottom: 8px;
}

.deck-stat-inline {
  flex: 1;
  background: #f8f8fa;
  border-radius: 6px;
  padding: 6px 4px;
  text-align: center;
}

.deck-stat-value-sm {
  display: block;
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent-primary, #6200ea);
  line-height: 1;
}

.deck-stat-label-sm {
  display: block;
  font-size: 0.6rem;
  color: #999;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-top: 1px;
}

/* Mana curve + types side by side */
.deck-curve-types-row {
  display: flex;
  gap: 8px;
}

.deck-mana-curve-sm {
  flex: 1;
  padding: 6px !important;
}

.deck-mana-curve-sm .deck-mana-curve-bars {
  height: 50px;
}

.deck-type-dist-sm {
  flex: 1;
  padding: 6px !important;
}

/* ── Mana Curve ── */
.deck-mana-curve {
  background: #f8f8fa;
  border-radius: 8px;
  padding: 10px;
}

.deck-mana-curve-label,
.deck-type-dist-label {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 0.75rem;
  text-transform: uppercase;
  color: #999;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.deck-mana-curve-bars {
  display: flex;
  gap: 4px;
  align-items: flex-end;
  height: 80px;
}

.deck-curve-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  justify-content: flex-end;
}

.deck-curve-bar {
  width: 100%;
  background: linear-gradient(180deg, var(--accent-primary, #6200ea), var(--accent-secondary, #aa00ff));
  border-radius: 3px 3px 0 0;
  min-height: 4px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  transition: height 0.3s ease;
}

.deck-curve-count {
  font-size: 0.6rem;
  color: #fff;
  font-weight: 700;
  margin-top: 2px;
}

.deck-curve-cmc {
  font-size: 0.65rem;
  color: #999;
  margin-top: 2px;
}

/* ── Type Distribution ── */
.deck-type-dist {
  background: #f8f8fa;
  border-radius: 8px;
  padding: 10px;
}

.deck-type-row {
  display: flex;
  justify-content: space-between;
  padding: 2px 0;
  font-size: 0.8rem;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}

.deck-type-row:last-child {
  border-bottom: none;
}

.deck-type-name {
  color: #555;
}

.deck-type-count {
  font-weight: 600;
  color: var(--accent-primary, #6200ea);
}

/* ── Card List (decklist) ── */
.deck-type-group-header {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--accent-primary, #6200ea);
  padding: 8px 8px 2px;
  margin-top: 6px;
  border-bottom: 1px solid rgba(98, 0, 234, 0.1);
}

.deck-type-group-header:first-child {
  margin-top: 0;
}

.deck-card-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.deck-list-row {
  display: flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 4px;
  transition: background 0.1s;
  cursor: default;
  gap: 8px;
}

.deck-list-row:hover {
  background: rgba(98, 0, 234, 0.04);
}

.deck-list-qty {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent-primary, #6200ea);
  min-width: 28px;
  text-align: right;
}

.deck-list-name {
  flex: 1;
  font-size: 0.88rem;
  color: #333;
}
a.deck-card-link {
  color: #e6e2f0; /* [qa-fix D2] claro sobre dark */
  text-decoration: none;
  border-bottom: 1px dotted rgba(98,0,234,0.3);
  transition: color 0.15s, border-color 0.15s;
}
a.deck-card-link:hover {
  color: #b794f6;
  border-bottom-color: #b794f6;
  text-decoration: none;
}

.deck-list-info {
  display: flex;
  gap: 6px;
  align-items: center;
  font-size: 0.75rem;
  color: #888;
}

.deck-list-mana {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 0.78rem;
  opacity: 0.7;
}

/* ── Card Preview Panel ── */
.deck-card-preview {
  min-height: 200px;
}

.deck-card-preview .deck-preview-img {
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

/* ── Card Tooltip (mobile) ── */
.deck-card-tooltip {
  display: none;
  position: fixed;
  z-index: 9999;
  pointer-events: none;
}

.deck-card-tooltip img {
  width: 250px;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.deck-card-tooltip.visible {
  display: block;
}

/* ═══════════════════════════════════════════════════════════
   Homepage Carousel Module
   ═══════════════════════════════════════════════════════════ */

/* Single-row grid matching product-thumb sizing */
.deck-homepage-grid {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important;
  /* [A9-02] gap espelha a escada do grid de cartas (featured_card_singles.css)
     e o recuo lateral saiu: com padding horizontal o card de deck ficava ~20px
     mais estreito que o card de carta no celular. Vertical preservado. */
  gap: 24px !important;
  padding: 16px 0;
}

@media (max-width: 991px) { .deck-homepage-grid { gap: 15px !important; } }
@media (max-width: 768px) { .deck-homepage-grid { gap: 12px !important; } }
@media (max-width: 480px) { .deck-homepage-grid { gap: 8px !important; } }

@media (min-width: 768px) {
  .deck-homepage-grid { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (min-width: 992px) {
  .deck-homepage-grid { grid-template-columns: repeat(4, 1fr) !important; }
}
@media (min-width: 1200px) {
  .deck-homepage-grid { grid-template-columns: repeat(5, minmax(0, 1fr)) !important; }
}

/* ═══════════════════════════════════════════════════════════
   Product Page — Cross-sell "Esta carta aparece em X decks"
   ═══════════════════════════════════════════════════════════ */

.deck-crosssell-grid {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important;
  gap: 16px !important;
  padding: 16px;
}
@media (min-width: 768px) {
  .deck-crosssell-grid { grid-template-columns: repeat(4, 1fr) !important; }
}

/* ═══════════════════════════════════════════════════════════
   Account — My Decks & Deck Builder
   ═══════════════════════════════════════════════════════════ */

/* ── Account Deck Grid ── */
.deck-account-grid {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important;
  gap: 16px !important;
}
@media (min-width: 768px) {
  .deck-account-grid { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (min-width: 1200px) {
  .deck-account-grid { grid-template-columns: repeat(4, 1fr) !important; }
}

.deck-account-actions .btn {
  font-size: 0.72rem;
  padding: 2px 6px;
}

/* ── Tag Checkboxes ── */
.deck-tag-check {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.82rem;
  padding: 2px 8px;
  border: 1px solid #ddd;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.15s;
}
.deck-tag-check:has(input:checked) {
  border-color: var(--accent-primary, #6200ea);
  background: rgba(98,0,234,0.06);
}
.deck-tag-check input { display: none; }

/* ── Card Search Dropdown ── */
.deck-card-search-wrapper {
  position: relative;
}

/* [SPX QA16-L2 A6-01] a caixa de sugestoes nascia BRANCA e o nome da carta herda
   o texto claro do tema: 1,10:1 - o unico caminho para montar um deck no celular
   ficava ilegivel. Passa a usar a superficie escura do tema (fallback = claro). */
.deck-search-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--surface, #fff);
  border: 1px solid var(--line, #ddd);
  border-top: none;
  border-radius: 0 0 8px 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  max-height: 320px;
  overflow-y: auto;
  z-index: 1050;
}

.deck-search-item {
  padding: 8px 12px;
  cursor: pointer;
  border-bottom: 1px solid var(--line-soft, #f0f0f0);  /* [SPX QA16-L2 A6-01] */
  transition: background 0.1s;
}
.deck-search-item:hover {
  background: var(--surface-2, rgba(98,0,234,0.04));
}
.deck-search-item:last-child {
  border-bottom: none;
}
.deck-search-mana img {
  width: 14px !important;
  height: 14px !important;
}

/* ── Builder Card Table ── */
.deck-builder-table {
  font-size: 0.85rem;
}
.deck-builder-table th {
  font-size: 0.72rem;
  text-transform: uppercase;
  color: #999;
  font-weight: 600;
  border-bottom: 2px solid #eee;
}
.deck-builder-table .btn-xs {
  padding: 0 5px;
  font-size: 0.72rem;
  line-height: 1.5;
}

.deck-type-header td {
  padding: 4px 8px !important;
  font-size: 0.75rem;
}

.deck-card-row.deck-card-unresolved {
  background: rgba(255,152,0,0.06);
}

/* ── Board Tabs ── */
.deck-board-tabs .nav-link {
  font-size: 0.82rem;
  padding: 6px 12px;
  color: #666;
}
.deck-board-tabs .nav-link.active {
  color: var(--accent-primary, #6200ea);
  border-bottom-color: var(--accent-primary, #6200ea);
}

/* ── Import textarea ── */
.deck-import-textarea {
  font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 0.82rem;
  line-height: 1.5;
  background: #f8f8fa;
}

/* ── Form sidebar sticky ── */
.deck-form-sidebar {
  position: sticky;
  top: 80px;
}

/* ── Mana curve mini (builder stats) ── */
.deck-mana-curve-mini {
  gap: 2px;
}
.deck-mana-curve-mini .deck-curve-bar {
  transition: height 0.3s ease;
}

/* ═══════════════════════════════════════════════════════════
   Product Page — "Add to Deck" Flyout
   ═══════════════════════════════════════════════════════════ */

.deck-flyout {
  display: none;
}
.deck-flyout.open {
  display: block;
}

.deck-flyout-backdrop {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.4);
  z-index: 1040;
  animation: fadeIn 0.2s ease;
}

.deck-flyout-panel {
  position: fixed;
  right: 0; top: 0; bottom: 0;
  width: 380px;
  max-width: 90vw;
  background: #fff;
  z-index: 1050;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 24px rgba(0,0,0,0.15);
  animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.deck-flyout-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  border-bottom: 1px solid #eee;
}

.deck-flyout-body {
  flex: 1;
  overflow-y: auto;
  padding: 0;
}

.deck-flyout-item {
  padding: 12px 16px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  transition: background 0.15s;
}
.deck-flyout-item:hover {
  background: rgba(98,0,234,0.04);
}
.deck-flyout-item:active {
  background: rgba(98,0,234,0.08);
}

.deck-flyout-footer {
  padding: 12px 16px;
  border-top: 1px solid #eee;
}

.deck-flyout-toast {
  position: absolute;
  bottom: 70px;
  left: 16px;
  right: 16px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 10px 14px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
  font-size: 0.85rem;
  animation: fadeIn 0.2s ease;
}

/* Mobile: bottom sheet */
@media (max-width: 767px) {
  .deck-flyout-panel {
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100%;
    max-height: 85vh;
    border-radius: 16px 16px 0 0;
    animation: slideInUp 0.3s ease;
  }
  @keyframes slideInUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
  }
}

/* ── Responsive ── */
@media (max-width: 767px) {
  .deck-detail-title {
    font-size: 1.3rem;
  }

  .deck-stats-panel {
    grid-template-columns: repeat(4, 1fr);
  }

  .deck-stat {
    padding: 6px;
  }

  .deck-stat-value {
    font-size: 1.1rem;
  }
}

/* ═══════════════════════════════════════════════════════════
   DETAIL — Reskin Arcane dark (2026-06-12)
   Páginas deck/deck/detail (MTG + PKM), escopo #deck-detail.
   O plugin nasceu no tema claro; estas regras alinham o detalhe
   ao spellbox-arcane.css (este arquivo carrega DEPOIS do arcane
   no <head> da página → vence por ordem, sem !important).
   ═══════════════════════════════════════════════════════════ */

/* ── Container da lista: superfície glass (a grade do body não vaza mais) ── */
#deck-list .cyber-frame-horizontal,
#deck-detail .cyber-frame-horizontal {
  background: oklch(0.235 0.035 285 / 0.55);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  border-left: 1px solid oklch(0.640 0.205 295 / 0.55);
  border-right: 1px solid oklch(0.640 0.205 295 / 0.55);
  border-bottom: 1px solid oklch(0.5 0.06 285 / 0.35);
  border-radius: 22px 4px 22px 22px;
  padding: 28px 18px 18px;
}
#deck-list .cyber-frame-label,
#deck-detail .cyber-frame-label {
  background: var(--bg, #1b1b41);
  border: 1px solid oklch(0.5 0.06 285 / 0.5);
  border-radius: 8px;
  color: var(--arcane-hi, #c084fc);
}
#deck-detail .deck-right-sidebar .cyber-frame-horizontal {
  margin-top: 18px !important;
}

/* ── Linhas da decklist ── */
#deck-detail .deck-card-list {
  gap: 0;
}
#deck-detail .deck-list-row {
  padding: 4px 8px;
  gap: 8px;
}
#deck-detail .deck-list-row:nth-child(even) {
  background: rgba(255, 255, 255, 0.025);
}
#deck-detail .deck-list-row:hover {
  background: oklch(0.55 0.08 290 / 0.12);
}
#deck-detail .deck-list-qty {
  min-width: 26px;
  text-align: center;
  background: oklch(0.290 0.034 285);
  color: var(--arcane-hi, #c084fc);
  border-radius: 4px;
  font-size: 0.8rem;
  padding: 1px 4px;
}
#deck-detail .deck-list-name {
  color: var(--ink, #f1f0f7);
}
#deck-detail a.deck-card-link {
  color: var(--ink, #e6e2f0);
  border-bottom-color: oklch(0.640 0.205 295 / 0.35);
}
#deck-detail a.deck-card-link:hover {
  color: var(--arcane-hi, #c084fc);
  border-bottom-color: var(--arcane-hi, #c084fc);
}
#deck-detail .deck-type-group-header {
  color: var(--arcane-hi, #c084fc);
  border-bottom: 1px solid oklch(0.640 0.205 295 / 0.25);
  padding: 10px 8px 3px;
}
#deck-detail .deck-list-info {
  color: var(--ink-3, #8f8da8);
}

/* Ponto verde "em estoque" (substitui o badge repetido por linha) */
.deck-stock-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #34c98a;
  box-shadow: 0 0 6px rgba(52, 201, 138, 0.55);
  flex: none;
  display: inline-block;
}
.deck-stock-dot-off {
  background: transparent;
  box-shadow: none;
}

/* ── Pips de custo de mana (discos = cores da ficha técnica da PDP) ── */
.deck-mana-cost {
  display: inline-flex;
  gap: 3px;
  align-items: center;
}
.deck-pip {
  width: 17px;
  height: 17px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}
.deck-pip img {
  width: 100%;
  height: 100%;
  display: block;
}
/* glifo dos SVGs de mana é BRANCO — invisível nos discos claros (W creme #f8f5e6,
   C cinza #cdc7bb): escurece o glifo nesses casos (match pelo bg inline) */
.deck-pip[style*="f8f5e6"] img,
.deck-pip[style*="cdc7bb"] img {
  filter: brightness(0) opacity(0.72);
}
.deck-pip-num {
  background: oklch(0.82 0.012 285);
  color: #241f2e;
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-weight: 700;
  font-size: 0.7rem;
  line-height: 1;
}
.deck-pip-txt {
  font-size: 0.55rem;
  letter-spacing: -0.02em;
}

/* ── Chips por linha (PKM): set·número e HP ── */
.deck-list-set {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  color: var(--ink-3, #8f8da8);
  background: oklch(0.290 0.034 285);
  border-radius: 4px;
  padding: 1px 6px;
  white-space: nowrap;
}
.deck-hp-badge {
  font-size: 0.65rem;
  font-weight: 600;
  white-space: nowrap;
  color: #ff8a76;
  background: rgba(227, 53, 13, 0.18);
  border-radius: 4px;
  padding: 1px 6px;
}

/* ── Cabeçalho do deck ── */
#deck-detail .deck-detail-author {
  color: var(--ink-2, #c4c2d8);
}
#deck-detail .deck-detail-description {
  color: var(--ink-2, #c4c2d8);
}
#deck-detail .badge-format {
  background: rgba(168, 85, 247, 0.18);
  color: var(--arcane-hi, #c084fc);
}
#deck-detail .badge-archetype {
  background: rgba(45, 212, 191, 0.14);
  color: #5eead4;
}
#deck-detail .badge-tier {
  background: rgba(233, 185, 73, 0.16);
  color: var(--gold, #e9b949);
}
#deck-detail .deck-detail-tags .badge {
  color: var(--ink-2, #c4c2d8) !important;
}
#deck-detail .deck-mana-pip-lg {
  background: oklch(0.290 0.034 285);
}
#deck-detail .mana-svg-pip-lg {
  filter: none; /* svg nativamente branco sobre disco escuro */
}
.deck-game-badge {
  background: #FFCB05;
  color: #333;
  font-size: 0.75rem;
}
#deck-detail .badge-format--pkm {
  background: rgba(255, 203, 5, 0.16);
  color: #ffd84d;
}

/* ── Buy box (conversão na primeira dobra) ── */
.deck-buybox {
  background: var(--surface, #232345);
  border: 1.5px solid var(--line, #45457a);
  border-radius: 14px 4px 14px 14px;
  padding: 14px 16px;
  box-shadow: 0 12px 34px -14px rgba(0, 0, 0, 0.8),
              inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
.deck-buybox-label {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-3, #8f8da8);
}
.deck-buybox-price {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-size: 1.9rem;
  font-weight: 700;
  line-height: 1.15;
  color: var(--gold, #e9b949);
}
.deck-buybox-price-na {
  font-size: 1.1rem;
  color: var(--ink-3, #8f8da8);
  padding: 8px 0;
}
.deck-buybox-avail {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--ink-2, #c4c2d8);
  margin-top: 8px;
}
.deck-buybox-avail-n.is-full { color: #34c98a; }
.deck-buybox-avail-n.is-mid  { color: var(--gold, #e9b949); }
.deck-buybox-avail-n.is-low  { color: #ff8a76; }
.deck-buybox-bar {
  height: 5px;
  background: oklch(0.290 0.034 285);
  border-radius: 3px;
  margin-top: 4px;
  overflow: hidden;
}
.deck-buybox-bar-fill {
  height: 100%;
  border-radius: 3px;
}
.deck-buybox-bar-fill.is-full { background: #34c98a; }
.deck-buybox-bar-fill.is-mid  { background: var(--gold, #e9b949); }
.deck-buybox-bar-fill.is-low  { background: #e0573f; }
.deck-buybox .btn {
  margin-top: 10px;
}
.deck-buybox .btn + .btn {
  margin-top: 6px;
}
.deck-buybox-updated {
  font-size: 0.7rem;
  color: var(--ink-3, #8f8da8);
  margin-top: 8px;
}

/* ── Stats do sidebar: tiles e caixas escuras (eram #f8f8fa claras) ── */
#deck-detail .deck-stat-inline {
  background: oklch(0.255 0.032 285 / 0.7);
  border: 1px solid oklch(0.5 0.06 285 / 0.28);
}
#deck-detail .deck-stat-value-sm {
  color: var(--ink, #f1f0f7);
  font-size: 1.2rem;
}
#deck-detail .deck-stat-label-sm {
  color: var(--ink-3, #8f8da8);
}
#deck-detail .deck-mana-curve,
#deck-detail .deck-type-dist {
  background: oklch(0.255 0.032 285 / 0.7);
  border: 1px solid oklch(0.5 0.06 285 / 0.28);
}
#deck-detail .deck-mana-curve-label,
#deck-detail .deck-type-dist-label {
  color: var(--ink-3, #8f8da8);
}
#deck-detail .deck-mana-curve-sm .deck-mana-curve-bars {
  height: 64px;
}
#deck-detail .deck-curve-bar {
  background: linear-gradient(180deg, oklch(0.55 0.16 295), oklch(0.45 0.13 292));
  opacity: 0.75;
}
#deck-detail .deck-curve-bar-max {
  opacity: 1;
  background: linear-gradient(180deg, var(--arcane-hi, #c084fc), var(--arcane, #a855f7));
  box-shadow: 0 0 10px oklch(0.640 0.205 295 / 0.5);
}
#deck-detail .deck-curve-cmc {
  color: var(--ink-3, #8f8da8);
}
#deck-detail .deck-curve-count {
  color: var(--ink-2, #c4c2d8);
  margin: 0 0 2px;
  font-size: 0.62rem;
}
#deck-detail .deck-curve-count-max {
  color: var(--arcane-hi, #c084fc);
}
#deck-detail.deck-page--pkm .deck-curve-count-max {
  color: #ff8a76;
}

/* Composição com mini-barras proporcionais */
#deck-detail .deck-type-item {
  margin-bottom: 7px;
}
#deck-detail .deck-type-item:last-child {
  margin-bottom: 0;
}
#deck-detail .deck-type-row {
  border-bottom: none;
  padding: 0;
}
#deck-detail .deck-type-name {
  color: var(--ink-2, #c4c2d8);
}
#deck-detail .deck-type-count {
  color: var(--arcane-hi, #c084fc);
}
.deck-type-bar {
  height: 4px;
  background: oklch(0.290 0.034 285);
  border-radius: 2px;
  margin-top: 3px;
  overflow: hidden;
}
.deck-type-bar > div {
  height: 100%;
  border-radius: 2px;
  background: oklch(0.640 0.205 295 / 0.65);
}

/* Chips de tipo de energia (PKM) */
.deck-energy-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: oklch(0.290 0.034 285);
  border: 1px solid oklch(0.5 0.06 285 / 0.4);
  color: var(--ink-2, #c4c2d8);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.75rem;
}
.deck-energy-chip img {
  width: 15px;
  height: 15px;
  border-radius: 50%;
}

/* Barras de HP (PKM) na paleta fire */
#deck-detail .deck-curve-bar--hp {
  background: linear-gradient(180deg, #ff5a36, #c52f10);
  opacity: 0.8;
}
#deck-detail .deck-curve-bar--hp.deck-curve-bar-max {
  opacity: 1;
  background: linear-gradient(180deg, #ff7a55, #E3350D);
  box-shadow: 0 0 10px rgba(227, 53, 13, 0.5);
}
.deck-curve-cmc--hp {
  font-size: 0.55rem;
}

/* ── Acentos PKM no frame (amarelo Pokémon no lugar do arcano) ── */
#deck-list.deck-page--pkm .cyber-frame-horizontal,
#deck-detail.deck-page--pkm .cyber-frame-horizontal {
  border-left-color: rgba(255, 203, 5, 0.45);
  border-right-color: rgba(255, 203, 5, 0.45);
}
#deck-list.deck-page--pkm .cyber-frame-horizontal::before,
#deck-detail.deck-page--pkm .cyber-frame-horizontal::before {
  background: linear-gradient(90deg, transparent 0%, rgba(255, 203, 5, 0.8) 20%, rgba(255, 203, 5, 0.8) 80%, transparent 100%);
}
#deck-list.deck-page--pkm .cyber-frame-label,
#deck-detail.deck-page--pkm .cyber-frame-label {
  color: #ffd84d;
}
#deck-detail.deck-page--pkm .deck-type-group-header {
  color: #ffd84d;
  border-bottom-color: rgba(255, 203, 5, 0.25);
}
#deck-detail.deck-page--pkm .deck-list-qty {
  color: #ffd84d;
}
#deck-detail.deck-page--pkm .deck-type-bar > div {
  background: rgba(255, 203, 5, 0.55);
}
#deck-detail.deck-page--pkm .deck-type-count {
  color: #ffd84d;
}

/* ── Decklist em 2 colunas no desktop (Commander cabe na tela) ── */
@media (min-width: 992px) {
  #deck-detail .deck-card-list {
    display: block;
    column-count: 2;
    column-gap: 26px;
  }
  #deck-detail .deck-list-row,
  #deck-detail .deck-type-group-header {
    break-inside: avoid;
    -webkit-column-break-inside: avoid;
  }
  #deck-detail .deck-list-row {
    margin-bottom: 1px;
  }
}

/* ── Cards minimizáveis do sidebar (buy box + stats) ──
   Colapsar encolhe o card pra faixa de título → o preview da carta sobe.
   Estado lembrado em localStorage (JS initCollapsibles). */
.deck-collapse-head {
  display: flex;
  align-items: center;
  gap: 8px;
}
.deck-collapse-mini {
  display: none;
  margin-left: auto;
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--gold, #e9b949);
}
.deck-buybox.is-collapsed .deck-collapse-mini {
  display: inline;
}
.deck-collapse-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--ink-3, #8f8da8);
  padding: 0 2px;
  margin-left: auto;
  line-height: 1;
  flex: none;
}
.deck-collapse-mini + .deck-collapse-btn {
  margin-left: 0;
}
.deck-collapse-btn:hover {
  color: var(--arcane-hi, #c084fc);
}
.deck-collapse-btn i {
  display: inline-block;
  transition: transform 0.25s ease;
}
.is-collapsed .deck-collapse-btn i {
  transform: rotate(180deg);
}
.deck-collapse-btn--frame {
  position: absolute;
  top: -12px;
  right: 14px;
  width: 26px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg, #1b1b41);
  border: 1px solid oklch(0.5 0.06 285 / 0.5);
  border-radius: 8px;
  color: var(--arcane-hi, #c084fc);
  margin-left: 0;
}
#deck-detail.deck-page--pkm .deck-collapse-btn--frame {
  color: #ffd84d;
}
.deck-collapse-body {
  overflow: hidden;
  max-height: 800px;
}
.deck-collapse-anim .deck-collapse-body {
  transition: max-height 0.25s ease;
}
.is-collapsed .deck-collapse-body {
  max-height: 0;
}
.deck-buybox.is-collapsed {
  padding-bottom: 12px;
}
#deck-detail .deck-stats-frame.is-collapsed {
  padding-top: 14px;
  padding-bottom: 2px;
}

/* ── Ajustes mobile do detail ── */
@media (max-width: 767px) {
  #deck-detail .cyber-frame-horizontal {
    padding: 24px 10px 12px;
  }
  .deck-buybox-price {
    font-size: 1.6rem;
  }
}

/* ═══════════════════════════════════════════════════════════
   LISTAGEM — Reskin Arcane dark (2026-06-12), escopo #deck-list
   Toggles de cor/energia escuros, preço/autor/disponibilidade
   nos cards, fileira de energia (PKM).
   ═══════════════════════════════════════════════════════════ */

/* Toggles de cor (eram discos brancos do tema claro) */
#deck-list .deck-color-toggle {
  width: 28px;
  height: 28px;
  padding: 0;
  background: oklch(0.290 0.034 285);
  border-color: oklch(0.5 0.06 285 / 0.45);
}
#deck-list .deck-color-toggle:hover {
  border-color: var(--arcane, #a855f7);
}
#deck-list .deck-color-toggle.active {
  background: var(--arcane, #a855f7);
  border-color: var(--arcane-hi, #c084fc);
  box-shadow: 0 0 9px oklch(0.64 0.205 295 / 0.55);
}
/* glifo B era brightness(0) = preto → invisível no disco escuro */
#deck-list .mana-b .mana-svg-icon {
  filter: brightness(0) invert(72%);
}
#deck-list .deck-color-toggle.active .mana-svg-icon {
  filter: none;
}
/* PKM: ícones de tipo são discos coloridos próprios */
#deck-list.deck-page--pkm .deck-color-toggle img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
}
#deck-list.deck-page--pkm .deck-color-toggle.active {
  background: rgba(255, 203, 5, 0.25);
  border-color: #FFCB05;
  box-shadow: 0 0 9px rgba(255, 203, 5, 0.5);
}

/* Fileira de energia (PKM — 11 tipos em linha própria) */
.deck-energy-row {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}
.deck-energy-row .form-label {
  margin-right: 6px;
}

/* Caption do card: autor + preço + disponibilidade */
.deck-thumb-author {
  font-size: 0.72rem;
  color: var(--ink-3, #8f8da8);
  margin: -2px 0 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.deck-thumb-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}
.deck-thumb-price {
  font-family: var(--font-tech, 'Rajdhani', sans-serif);
  font-weight: 700;
  font-size: 1rem;
  color: var(--gold, #e9b949);
}
.deck-thumb-meta .deck-thumb-stats {
  margin-left: auto;
}
.deck-stock-dot.is-mid {
  background: var(--gold, #e9b949);
  box-shadow: 0 0 6px rgba(233, 185, 73, 0.5);
}
.deck-stock-dot.is-low {
  background: #e0573f;
  box-shadow: 0 0 6px rgba(224, 87, 63, 0.5);
}

/* ── Pips do overlay nos cards de deck (home + listagens) ──
   O arcane (.product-thumb .image img { width:100%!important; padding:12px... })
   estourava os símbolos do overlay (98–138px). Especificidade maior re-fixa. */
.product-thumb .image .deck-thumb-overlay img {
  width: 22px !important;
  height: 22px !important;
  padding: 0 !important;
  position: static !important;
  object-fit: contain !important;
}

/* ═══════════════════════════════════════════════════════════
   TRI-ESTADO de disponibilidade (Item 12 F3a, 2026-06-12)
   em estoque (verde) / preço de referência (âmbar) / sem preço.
   ═══════════════════════════════════════════════════════════ */
.deck-buybox-subprice {
  font-size: 0.72rem;
  color: var(--ink-3, #8f8da8);
  margin-top: 2px;
}
.deck-buybox-refline {
  font-size: 0.78rem;
  color: var(--ink-2, #c4c2d8);
  margin-top: 6px;
}
.deck-buybox-refline b {
  color: var(--gold, #e9b949);
  font-weight: 600;
}
.deck-buybox-price--ref {
  color: oklch(0.74 0.075 88);
}
.deck-buybox-avail-n .t-stock { color: #34c98a; font-weight: 600; }
.deck-buybox-avail-n .t-ref   { color: var(--gold, #e9b949); font-weight: 600; }
.deck-buybox-avail-n .t-unp   { color: var(--ink-3, #8f8da8); font-weight: 600; }
.deck-buybox-bar--tri {
  display: flex;
}
.deck-buybox-bar--tri .seg-stock {
  height: 100%;
  background: #34c98a;
}
.deck-buybox-bar--tri .seg-ref {
  height: 100%;
  background: var(--gold, #e9b949);
  opacity: 0.75;
}
.deck-stock-dot.is-ref {
  background: var(--gold, #e9b949);
  box-shadow: 0 0 6px rgba(233, 185, 73, 0.5);
}
.deck-thumb-price--ref {
  color: oklch(0.74 0.075 88);
}
.deck-thumb-price--ref small {
  font-size: 0.62rem;
  color: var(--ink-3, #8f8da8);
  font-weight: 400;
}

/* Modo produto do buy box (Item 12 F3b — deck montado/precon) */
.deck-buybox-prodlink {
  color: var(--storm, #62c5ea);
  text-decoration: none;
  border-bottom: 1px dotted rgba(98, 197, 234, 0.4);
}
.deck-buybox-prodlink:hover {
  color: var(--arcane-hi, #c084fc);
}


/* [Deck-produto v2: art preenche o card até a faixa das manas] a capa (art_crop,
   paisagem) vira preenchimento total da área da imagem — sem letterbox */
.deck-thumb .image {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
.deck-thumb .image > a {
  position: absolute;
  inset: 0;
  display: block;
}
.deck-thumb .image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
}


/* [Deck-produto v2] card do produto vinculado no buy box + linha das avulsas */
.deck-buybox-prodcard {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  margin-bottom: 10px;
  border: 1px solid rgba(139, 92, 246, 0.35);
  border-radius: 10px;
  background: rgba(139, 92, 246, 0.08);
  text-decoration: none;
  color: inherit;
  transition: border-color .15s ease, background .15s ease;
}
.deck-buybox-prodcard:hover {
  border-color: rgba(139, 92, 246, 0.7);
  background: rgba(139, 92, 246, 0.14);
  color: inherit;
}
.deck-buybox-prodcard img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  border-radius: 8px;
  background: #14142a;
  flex: 0 0 64px;
}
.deck-buybox-prodcard-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.deck-buybox-prodcard-name {
  font-size: .8rem;
  font-weight: 600;
  line-height: 1.25;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.deck-buybox-prodcard-price {
  font-size: 1.05rem;
  font-weight: 700;
}
.deck-buybox-prodcard small {
  opacity: .7;
  font-size: .7rem;
}
.deck-buybox-singles {
  margin-top: 8px;
  font-size: .78rem;
  opacity: .85;
}
.deck-buybox-singles b {
  font-variant-numeric: tabular-nums;
}

/* o grid de produtos (spx card-meta) forca object-fit: contain nos cards — decks usam a ART e precisam de cover */
.deck-thumb .image img {
  object-fit: cover !important;
  object-position: center 30% !important;
}

/* ============================================================
   [SPX 2026-09-19] pips de mana MTG em GEMA (mesmo desenho do Commander e dos filtros):
   volume por gradiente radial, aro interno, sombra, halo; glifo com sombra; W/C com glifo escuro.
   Cor pelo alt do glifo, entao os tipos de Pokemon (Grass/Fire/...) nao entram aqui.
   ============================================================ */
.deck-mana-pip:has(> img[alt="White"]), .deck-mana-pip:has(> img[alt="Blue"]), .deck-mana-pip:has(> img[alt="Black"]), .deck-mana-pip:has(> img[alt="Red"]), .deck-mana-pip:has(> img[alt="Green"]), .deck-mana-pip:has(> img[alt="Colorless"]){
  --c:#b9b4c4; background:radial-gradient(circle at 32% 28%, color-mix(in oklab, var(--c) 58%, white) 0%, var(--c) 42%, color-mix(in oklab, var(--c) 68%, black) 100%); box-shadow:inset 0 0 0 1px rgba(255,255,255,.22), 0 1px 3px rgba(0,0,0,.55), 0 0 8px color-mix(in srgb, var(--c) 40%, transparent);
}
.deck-mana-pip:has(> img[alt="White"]){ --c:#efe9d0; } .deck-mana-pip:has(> img[alt="Blue"]){ --c:#3b82c4; } .deck-mana-pip:has(> img[alt="Black"]){ --c:#5f5a78; } .deck-mana-pip:has(> img[alt="Red"]){ --c:#e0573f; } .deck-mana-pip:has(> img[alt="Green"]){ --c:#56a268; }
.deck-mana-pip > img[alt="White"], .deck-mana-pip > img[alt="Blue"], .deck-mana-pip > img[alt="Black"], .deck-mana-pip > img[alt="Red"], .deck-mana-pip > img[alt="Green"], .deck-mana-pip > img[alt="Colorless"]{ filter:drop-shadow(0 1px 1px rgba(0,0,0,.5)) !important; }
.deck-mana-pip > img[alt="White"], .deck-mana-pip > img[alt="Colorless"]{ filter:brightness(0) opacity(.78) !important; }
/* sobre a capa do deck (PDP, carrosseis, lista): a gema volta a ter disco (a regra do thumb tirava o fundo) */
.deck-thumb-mana .deck-mana-pip:has(> img[alt="White"]), .deck-thumb-mana .deck-mana-pip:has(> img[alt="Blue"]), .deck-thumb-mana .deck-mana-pip:has(> img[alt="Black"]), .deck-thumb-mana .deck-mana-pip:has(> img[alt="Red"]), .deck-thumb-mana .deck-mana-pip:has(> img[alt="Green"]), .deck-thumb-mana .deck-mana-pip:has(> img[alt="Colorless"]){ width:24px; height:24px; }
.deck-thumb-mana .deck-mana-pip:has(> img[alt="White"]) .mana-svg-pip, .deck-thumb-mana .deck-mana-pip:has(> img[alt="Blue"]) .mana-svg-pip, .deck-thumb-mana .deck-mana-pip:has(> img[alt="Black"]) .mana-svg-pip, .deck-thumb-mana .deck-mana-pip:has(> img[alt="Red"]) .mana-svg-pip, .deck-thumb-mana .deck-mana-pip:has(> img[alt="Green"]) .mana-svg-pip, .deck-thumb-mana .deck-mana-pip:has(> img[alt="Colorless"]) .mana-svg-pip{ width:15px !important; height:15px !important; }
.deck-mana-pip + .deck-mana-pip:has(> img[alt="White"]), .deck-mana-pip + .deck-mana-pip:has(> img[alt="Blue"]), .deck-mana-pip + .deck-mana-pip:has(> img[alt="Black"]), .deck-mana-pip + .deck-mana-pip:has(> img[alt="Red"]), .deck-mana-pip + .deck-mana-pip:has(> img[alt="Green"]){ margin-left:-4px; box-shadow:inset 0 0 0 1px rgba(255,255,255,.22), 0 0 0 2px var(--surface, #1c1930), 0 1px 3px rgba(0,0,0,.55), 0 0 8px color-mix(in srgb, var(--c) 40%, transparent); }
.deck-mana-pip-lg > img.mana-svg-pip-lg[alt="Blue"], .deck-mana-pip-lg > img.mana-svg-pip-lg[alt="Black"], .deck-mana-pip-lg > img.mana-svg-pip-lg[alt="Red"], .deck-mana-pip-lg > img.mana-svg-pip-lg[alt="Green"]{ filter:drop-shadow(0 1px 1px rgba(0,0,0,.5)) !important; }

/* ============================================================
   [SPX 2026-09-19] deck-pip em GEMA — pagina de detalhe do deck:
   cabecalho (.deck-mana-pip-lg, vencendo o fundo por #deck-detail) e custo de mana
   da lista de cartas (.deck-pip, cor inline -> gema via [title] + !important).
   ============================================================ */
#deck-detail .deck-mana-pip-lg:has(> img[alt="White"]), #deck-detail .deck-mana-pip-lg:has(> img[alt="Blue"]), #deck-detail .deck-mana-pip-lg:has(> img[alt="Black"]), #deck-detail .deck-mana-pip-lg:has(> img[alt="Red"]), #deck-detail .deck-mana-pip-lg:has(> img[alt="Green"]), #deck-detail .deck-mana-pip-lg:has(> img[alt="Colorless"]){
  background:radial-gradient(circle at 32% 28%, color-mix(in oklab, var(--c) 58%, white) 0%, var(--c) 42%, color-mix(in oklab, var(--c) 68%, black) 100%); box-shadow:inset 0 0 0 1px rgba(255,255,255,.22), 0 1px 3px rgba(0,0,0,.55), 0 0 10px color-mix(in srgb, var(--c) 45%, transparent);
}
#deck-detail .deck-mana-pip-lg > img[alt="White"], #deck-detail .deck-mana-pip-lg > img[alt="Colorless"]{ filter:brightness(0) opacity(.78) !important; }
.deck-pip[title]{ --c:#b9b4c4; background:radial-gradient(circle at 32% 28%, color-mix(in oklab, var(--c) 58%, white) 0%, var(--c) 42%, color-mix(in oklab, var(--c) 68%, black) 100%) !important; box-shadow:inset 0 0 0 1px rgba(255,255,255,.22), 0 1px 2px rgba(0,0,0,.5); }
.deck-pip[title="White"]{ --c:#efe9d0; } .deck-pip[title="Blue"]{ --c:#3b82c4; } .deck-pip[title="Black"]{ --c:#5f5a78; } .deck-pip[title="Red"]{ --c:#e0573f; } .deck-pip[title="Green"]{ --c:#56a268; } .deck-pip[title="Colorless"]{ --c:#b9b4c4; }
.deck-pip[title] img{ width:64%; height:64%; filter:drop-shadow(0 1px 1px rgba(0,0,0,.5)); }
.deck-pip[title="White"] img, .deck-pip[title="Colorless"] img{ filter:brightness(0) opacity(.78); }

/* ============================================================
   [SPX 2026-09-19] energias POKEMON em GEMA por sobreposicao: o icone oficial fica,
   ganha luz/aro/sombra/halo (cor pelo arquivo do icone). Cabecalho, cards, filtro e chips.
   ============================================================ */
.deck-mana-pip:has(> img[src*="pkm-types/"]){ --c:#828282; position:relative; overflow:visible; background:none; box-shadow:inset 0 0 0 1px rgba(255,255,255,.28), 0 1px 3px rgba(0,0,0,.55), 0 0 10px color-mix(in srgb, var(--c) 45%, transparent); }
.deck-mana-pip:has(> img[src*="pkm-types/"]) > img{ width:100% !important; height:100% !important; border-radius:50%; filter:none !important; }
.deck-mana-pip:has(> img[src*="pkm-types/"])::after{ content:''; position:absolute; inset:0; border-radius:50%; pointer-events:none; background:radial-gradient(circle at 32% 26%, rgba(255,255,255,.58) 0%, rgba(255,255,255,.14) 36%, transparent 50%), linear-gradient(180deg, transparent 56%, rgba(0,0,0,.34) 100%); }
#deck-detail .deck-mana-pip-lg:has(> img[src*="pkm-types/"]){ background:none; }
.deck-thumb-mana .deck-mana-pip:has(> img[src*="pkm-types/"]){ width:24px; height:24px; }
.deck-thumb-mana .deck-mana-pip + .deck-mana-pip:has(> img[src*="pkm-types/"]){ margin-left:-6px; box-shadow:inset 0 0 0 1px rgba(255,255,255,.28), 0 0 0 2px rgba(18,14,36,.9), 0 1px 3px rgba(0,0,0,.55), 0 0 10px color-mix(in srgb, var(--c) 45%, transparent); }
/* filtro de energia da lista de decks (botao com classe pkm-*) */
#deck-list.deck-page--pkm .deck-color-toggle{ --c:#828282; position:relative; overflow:visible; background:none; border:0; padding:0; box-shadow:inset 0 0 0 1px rgba(255,255,255,.28), 0 1px 3px rgba(0,0,0,.55); opacity:.5; transition:opacity .18s, transform .18s, box-shadow .18s; }
#deck-list.deck-page--pkm .deck-color-toggle img{ width:100%; height:100%; border-radius:50%; }
#deck-list.deck-page--pkm .deck-color-toggle::after{ content:''; position:absolute; inset:0; border-radius:50%; pointer-events:none; background:radial-gradient(circle at 32% 26%, rgba(255,255,255,.58) 0%, rgba(255,255,255,.14) 36%, transparent 50%), linear-gradient(180deg, transparent 56%, rgba(0,0,0,.34) 100%); }
#deck-list.deck-page--pkm .deck-color-toggle:hover{ opacity:.85; border-color:transparent; }
#deck-list.deck-page--pkm .deck-color-toggle.active{ opacity:1; transform:scale(1.06); background:none; border-color:transparent; box-shadow:inset 0 0 0 1px rgba(255,255,255,.28), 0 0 0 2px var(--arcane, #a855f7), 0 0 9px oklch(0.64 0.205 295 / 0.55); }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-grass{ --c:#439837; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-fire{ --c:#e4613e; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-water{ --c:#3099e1; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-lightning{ --c:#dfbc28; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-psychic{ --c:#e96c8c; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-fighting{ --c:#e49021; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-darkness{ --c:#4f4747; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-metal{ --c:#74b0cb; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-fairy{ --c:#e18ce1; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-dragon{ --c:#576fbc; }
#deck-list.deck-page--pkm .deck-color-toggle.pkm-colorless{ --c:#828282; }
/* chips Tipos de Energia (detalhe do deck) */
.deck-energy-chip{ padding-left:4px; gap:7px; }
.deck-energy-chip .deck-energy-pip{ --c:#828282; position:relative; width:18px; height:18px; border-radius:50%; display:inline-grid; flex:none; box-shadow:inset 0 0 0 1px rgba(255,255,255,.28), 0 1px 2px rgba(0,0,0,.5), 0 0 8px color-mix(in srgb, var(--c) 40%, transparent); }
.deck-energy-chip .deck-energy-pip img{ width:100%; height:100%; border-radius:50%; display:block; }
.deck-energy-chip .deck-energy-pip::after{ content:''; position:absolute; inset:0; border-radius:50%; pointer-events:none; background:radial-gradient(circle at 32% 26%, rgba(255,255,255,.58) 0%, rgba(255,255,255,.14) 36%, transparent 50%), linear-gradient(180deg, transparent 56%, rgba(0,0,0,.34) 100%); }
.deck-mana-pip:has(> img[src*="pkm-types/grass.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/grass.svg"]){ --c:#439837; }
.deck-mana-pip:has(> img[src*="pkm-types/fire.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/fire.svg"]){ --c:#e4613e; }
.deck-mana-pip:has(> img[src*="pkm-types/water.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/water.svg"]){ --c:#3099e1; }
.deck-mana-pip:has(> img[src*="pkm-types/electric.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/electric.svg"]){ --c:#dfbc28; }
.deck-mana-pip:has(> img[src*="pkm-types/psychic.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/psychic.svg"]){ --c:#e96c8c; }
.deck-mana-pip:has(> img[src*="pkm-types/fighting.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/fighting.svg"]){ --c:#e49021; }
.deck-mana-pip:has(> img[src*="pkm-types/dark.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/dark.svg"]){ --c:#4f4747; }
.deck-mana-pip:has(> img[src*="pkm-types/steel.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/steel.svg"]){ --c:#74b0cb; }
.deck-mana-pip:has(> img[src*="pkm-types/fairy.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/fairy.svg"]){ --c:#e18ce1; }
.deck-mana-pip:has(> img[src*="pkm-types/dragon.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/dragon.svg"]){ --c:#576fbc; }
.deck-mana-pip:has(> img[src*="pkm-types/normal.svg"]), .deck-energy-pip:has(> img[src*="pkm-types/normal.svg"]){ --c:#828282; }

/* [SPX 2026-09-19] p2: cabecalho do deck Pokemon — o icone de tipo nunca leva o filtro escuro da regra MTG por id */
#deck-detail .deck-mana-pip-lg > img[src*="pkm-types/"]{ filter:none !important; width:100% !important; height:100% !important; }
