/* ============================================================
   GABE CARDS · "TEN OUT OF TEN" · Build Spec v2
   Design: KIMI K3 · CSS: GLM 5.2
   ============================================================ */

/* ---------- Grid ---------- */
.gcard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
  padding: 32px 24px 64px;
  max-width: 1480px;
  margin: 0 auto;
  perspective: 1400px;
}
@media (max-width: 640px) {
  .gcard-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 18px;
    padding: 20px 14px 48px;
  }
}

/* ---------- Tilt wrapper ---------- */
.gcard-tilt {
  position: relative;
  perspective: 1200px;
  width: 100%;
  min-height: 512px;
  border-radius: 18px;
  cursor: pointer;
  outline: none;
  transform: rotateX(calc((var(--my, 50) - 50) * -0.28deg))
             rotateY(calc((var(--mx, 50) - 50) * 0.28deg));
  box-shadow:
    calc((var(--mx, 50) - 50) * -0.35px)
    calc((var(--my, 50) - 50) * 0.35px)
    32px -8px rgba(0,0,0,0.55),
    calc((var(--mx, 50) - 50) * -0.15px)
    calc((var(--my, 50) - 50) * 0.15px)
    12px -4px rgba(0,0,0,0.35);
  will-change: transform;
}
.gcard-tilt:hover {
  z-index: 5;
}
.gcard-tilt:focus-visible {
  outline: 2px solid var(--gcard-accent, #4f7cff);
  outline-offset: 4px;
  border-radius: 18px;
}

/* ---------- Card (flip container) ---------- */
.gcard {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 512px;
  transform-style: preserve-3d;
  transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 18px;
}
.gcard.is-flipped {
  transform: rotateY(180deg);
}

/* ---------- Accent tokens per rarity ---------- */
.gcard--legendary { --gcard-accent: #f5d061; --gcard-accent-soft: rgba(245,208,97,0.35); }
.gcard--epic      { --gcard-accent: #38d4ff; --gcard-accent-soft: rgba(56,212,255,0.30); }
.gcard--rare      { --gcard-accent: #4f7cff; --gcard-accent-soft: rgba(79,124,255,0.25); }
.gcard--common    { --gcard-accent: #F3EFE6; --gcard-accent-soft: rgba(243,239,230,0.10); }

/* ---------- Face base ---------- */
.gcard__front,
.gcard__back {
  position: absolute;
  inset: 0;
  border-radius: 18px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  overflow: hidden;
}

.gcard__front {
  background: linear-gradient(165deg, #0a1628 0%, #06101F 60%, #040a14 100%);
  border: 1px solid rgba(255,255,255,0.06);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}

.gcard--legendary .gcard__front { box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 0 24px rgba(245,208,97,0.35); }
.gcard--epic .gcard__front      { box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 0 20px rgba(56,212,255,0.30); }
.gcard--rare .gcard__front      { box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 0 16px rgba(79,124,255,0.25); }
.gcard--common .gcard__front    { box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 0 8px  rgba(243,239,230,0.10); }

.gcard__back {
  transform: rotateY(180deg);
  background: #06101F;
}

/* elements with backdrop-filter create their own compositing layer that can
   escape the front's backface culling on flip — force them to cull too. */
.gcard__flip,
.gcard__crest,
.gcard__emblem,
.gcard__sport,
.gcard__rarity,
.gcard__top5,
.gcard__foil,
.gcard__sheen {
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
/* guarantee no front overlay control bleeds onto the back after flip */
.gcard.is-flipped .gcard__front .gcard__flip,
.gcard.is-flipped .gcard__crest,
.gcard.is-flipped .gcard__emblem,
.gcard.is-flipped .gcard__sport,
.gcard.is-flipped .gcard__rarity,
.gcard.is-flipped .gcard__top5 { display: none; }

/* ---------- Portrait (NO translateZ ever) ---------- */
.gcard__portrait {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  border-radius: 18px 18px 0 0;
  transform: translate(
    calc((var(--mx, 50) - 50) * 0.12px),
    calc((var(--my, 50) - 50) * 0.12px)
  );
}
.gcard__portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(1.05) contrast(1.05);
}
.gcard__portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
    rgba(6,16,31,0.0) 30%,
    rgba(6,16,31,0.55) 70%,
    rgba(6,16,31,0.95) 100%);
  pointer-events: none;
}

/* Portrait meta chips */
.gcard__sport,
.gcard__rarity,
.gcard__top5 {
  position: absolute;
  display: inline-flex;
  align-items: center;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 4px;
  background: rgba(6,16,31,0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: #F3EFE6;
  z-index: 3;
}
.gcard__sport  { top: 13px; left: 50px; }
.gcard__rarity { top: 74px; right: 14px; color: var(--gcard-accent); border: 1px solid var(--gcard-accent-soft); }
.gcard--legendary .gcard__rarity { color: #f5d061; border-color: rgba(245,208,97,0.5); background: rgba(6,16,31,0.82); }
.gcard__top5   { top: 46px; left: 12px; color: #fff2b8; border: 1px solid rgba(255,242,184,0.35); }
.gcard__top5 svg { margin-right: 4px; }

/* ---------- Emblem medallion ---------- */
.gcard__emblem {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  z-index: 3;
  transform: translate(
    calc((var(--mx, 50) - 50) * 0.22px),
    calc((var(--my, 50) - 50) * 0.22px)
  );
  display: grid;
  place-items: center;
  transition: transform 220ms ease-out;
}
.gcard__emblem svg { width: 100%; height: 100%; display: block; }

.gcard--legendary .gcard__emblem {
  background: linear-gradient(135deg,
    #6b4f0e 0%, #a67c1a 10%, #d4af37 22%, #f5d061 35%, #fff2b8 44%,
    #f5d061 54%, #d4af37 68%, #a67c1a 82%, #6b4f0e 100%);
  box-shadow: inset 0 1px 0 rgba(255,242,184,0.6),
              inset 0 -1px 0 rgba(107,79,14,0.8),
              0 4px 12px rgba(0,0,0,0.5);
}
.gcard--epic .gcard__emblem {
  background: conic-gradient(from 180deg, #38d4ff, #8b5cf6, #38d4ff);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.4), 0 4px 12px rgba(0,0,0,0.5);
}
.gcard--rare .gcard__emblem {
  background: conic-gradient(from 180deg, #4f7cff, #38d4ff, #4f7cff);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.4), 0 4px 12px rgba(0,0,0,0.5);
}
.gcard--common .gcard__emblem {
  background: #06101F;
  border: 1.5px solid rgba(243,239,230,0.6);
  box-shadow: 0 4px 10px rgba(0,0,0,0.4);
}
.gcard-tilt:hover .gcard__emblem { transform: translate(
    calc((var(--mx, 50) - 50) * 0.22px),
    calc((var(--my, 50) - 50) * 0.22px)
  ) scale(1.04); }

/* ---------- Info block ---------- */
.gcard__info {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 2;
  padding: 18px 16px 28px;
  background: linear-gradient(180deg,
    rgba(6,16,31,0) 0%,
    rgba(6,16,31,0.78) 22%,
    rgba(6,16,31,0.96) 60%,
    #06101F 100%);
  transform: translate(
    calc((var(--mx, 50) - 50) * 0.14px),
    calc((var(--my, 50) - 50) * 0.14px)
  );
}

.gcard__name {
  margin: 0 0 4px;
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 800;
  font-size: 22px;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: #ffffff;
  position: relative;
  display: inline-block;
}
.gcard--legendary .gcard__name::after,
.gcard--epic .gcard__name::after,
.gcard--rare .gcard__name::after {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg,
    transparent 30%,
    var(--gcard-sheen-c1, #fff2b8) 45%,
    var(--gcard-sheen-c2, #f5d061) 50%,
    var(--gcard-sheen-c1, #fff2b8) 55%,
    transparent 70%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0.55;
  mix-blend-mode: screen;
  pointer-events: none;
}
.gcard--legendary { --gcard-sheen-c1: #fff2b8; --gcard-sheen-c2: #f5d061; }
.gcard--epic      { --gcard-sheen-c1: #bfeeff; --gcard-sheen-c2: #38d4ff; }
.gcard--rare      { --gcard-sheen-c1: #cfd9ff; --gcard-sheen-c2: #4f7cff; }

.gcard__pos,
.gcard__club {
  margin: 0;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(243,239,230,0.7);
}
.gcard__pos { color: var(--gcard-accent); }
.gcard__club { margin-top: 2px; }
.gcard__club-inline { color: rgba(243,239,230,0.55); letter-spacing: 0.12em; }

.gcard__moves {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.gcard__move {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 7px;
  border-radius: 3px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  color: #F3EFE6;
}

.gcard__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.gcard__stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.gcard__stat-v {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 800;
  font-size: 22px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.gcard--legendary .gcard__stat-v {
  background: linear-gradient(180deg,
    #ffffff 0%, #ffffff 40%, #fff2b8 47%, #f5d061 53%,
    #d4af37 72%, #a67c1a 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.gcard--epic .gcard__stat-v {
  background: linear-gradient(180deg, #ffffff 0%, #ffffff 40%, #38d4ff 55%, #4f7cff 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.gcard--rare .gcard__stat-v {
  background: linear-gradient(180deg, #ffffff 0%, #ffffff 40%, #4f7cff 55%, #4f7cff 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.gcard--common .gcard__stat-v { color: #F3EFE6; }
.gcard__stat-l {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(243,239,230,0.55);
  margin-top: 3px;
}

/* Prediction */
.gcard__prediction {
  margin-top: 12px;
  padding: 10px 10px 8px;
  border-radius: 8px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
}
.gcard__pred-eyebrow {
  display: block;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gcard-accent);
  margin-bottom: 4px;
}
.gcard__pred-head {
  margin: 0;
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: 13px;
  line-height: 1.2;
  color: #fff;
}
.gcard__pred-detail {
  margin: 4px 0 0;
  font-size: 11px;
  line-height: 1.35;
  color: rgba(243,239,230,0.7);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Call / segments */
.gcard__call { margin-top: 10px; }
.gcard__call-label {
  display: block;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(243,239,230,0.5);
  margin-bottom: 6px;
}
.gcard__segs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 5px;
  padding: 4px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 9px;
  background: rgba(0,0,0,0.28);
}
.gcard__seg {
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.05);
  min-height: 32px;
  border-radius: 6px;
  cursor: pointer;
  padding: 6px 4px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(243,239,230,0.72);
  transition: background 160ms ease, color 160ms ease, border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}
.gcard__seg:hover:not(:disabled) { background: rgba(255,255,255,0.12); color: #fff; transform: translateY(-1px); }
.gcard__seg:active:not(:disabled) { transform: scale(0.96); }
.gcard__seg.is-picked {
  background: var(--gcard-accent);
  color: #06101F;
  border-color: var(--gcard-accent);
  box-shadow: 0 0 16px var(--gcard-accent-soft);
}
.gcard--legendary .gcard__seg.is-picked { color: #241a02; }
.gcard__seg:disabled { opacity: 0.42; cursor: not-allowed; }

.gcard__called,
.gcard__resolved {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 6px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: center;
}
.gcard__called {
  background: rgba(245,208,97,0.10);
  border: 1px solid rgba(245,208,97,0.30);
  color: #f5d061;
}
.gcard__resolved {
  background: rgba(56,212,255,0.10);
  border: 1px solid rgba(56,212,255,0.30);
  color: #38d4ff;
}

/* ---------- Flip button (front corner) ---------- */
.gcard__flip {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 4;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(6,16,31,0.92);
  border: 1px solid rgba(255,255,255,0.16);
  color: #F3EFE6;
  cursor: pointer;
  -webkit-
  transition: background 180ms ease, transform 180ms ease, color 180ms ease;
}
.gcard__flip:hover { background: rgba(6,16,31,0.92); color: var(--gcard-accent); transform: rotate(180deg); }
.gcard__flip svg { width: 14px; height: 14px; }

/* ---------- Compact GST crest (front) ---------- */
.gcard__crest {
  position: absolute;
  bottom: 10px;
  right: 10px;
  z-index: 4;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(6,16,31,0.92);
  border: 1.5px solid var(--gcard-accent);
  box-shadow: inset 0 0 4px rgba(0,0,0,0.6);
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 800;
  font-size: 12px;
  color: var(--gcard-accent);
  transform: translate(
    calc((var(--mx, 50) - 50) * 0.08px),
    calc((var(--my, 50) - 50) * 0.08px)
  );
  transition: transform 200ms ease-out, box-shadow 200ms ease-out;
}
.gcard--common .gcard__crest { border-color: rgba(243,239,230,0.6); color: rgba(243,239,230,0.85); }
.gcard-tilt:hover .gcard__crest {
  transform: translate(
    calc((var(--mx, 50) - 50) * 0.08px),
    calc((var(--my, 50) - 50) * 0.08px)
  ) scale(1.15);
  box-shadow: inset 0 0 4px rgba(0,0,0,0.6), 0 0 8px var(--gcard-accent);
}

/* ---------- Foil layer ---------- */
.gcard__foil {
  position: absolute;
  inset: 0;
  z-index: 5;
  border-radius: 18px;
  pointer-events: none;
  mix-blend-mode: screen;
  transform: translate(
    calc((var(--mx, 50) - 50) * 0.35px),
    calc((var(--my, 50) - 50) * 0.35px)
  );
}

.gcard--legendary .gcard__foil {
  background:
    linear-gradient(calc(90deg + var(--mx, 50) * 1.8deg),
      transparent 35%,
      rgba(255,242,184,0.25) 50%,
      transparent 65%),
    conic-gradient(
      from calc(var(--mx, 50) * 3.6deg)
      at calc(var(--mx, 50) * 1%) calc(var(--my, 50) * 1%),
      #4f7cff 0deg, #38d4ff 60deg, #8b5cf6 120deg,
      #4f7cff 180deg, #38d4ff 240deg, #8b5cf6 300deg, #4f7cff 360deg);
  opacity: 0.5;
  mix-blend-mode: screen;
}
.gcard--legendary .gcard__foil {
  /* layered: gold shimmer overlay sits on top via stacking */
}

.gcard--epic .gcard__foil {
  background: conic-gradient(
    from calc(var(--mx, 50) * 3.6deg)
    at calc(var(--mx, 50) * 1%) calc(var(--my, 50) * 1%),
    #38d4ff 0deg, #8b5cf6 180deg, #38d4ff 360deg);
  opacity: 0.3;
  mix-blend-mode: screen;
}
.gcard--rare .gcard__foil {
  background: conic-gradient(
    from calc(var(--mx, 50) * 3.6deg)
    at calc(var(--mx, 50) * 1%) calc(var(--my, 50) * 1%),
    #4f7cff 0deg, #38d4ff 180deg, #4f7cff 360deg);
  opacity: 0.25;
  mix-blend-mode: screen;
}
.gcard--common .gcard__foil { display: none; }

/* ---------- Sheen streak ---------- */
.gcard__sheen {
  position: absolute;
  inset: 0;
  z-index: 6;
  border-radius: 18px;
  pointer-events: none;
  mix-blend-mode: overlay;
  opacity: 0.7;
  background: linear-gradient(125deg,
    transparent 30%,
    rgba(255,255,255,0.12) 45%,
    rgba(255,255,255,0.28) 50%,
    rgba(255,255,255,0.12) 55%,
    transparent 70%);
  background-size: 250% 250%;
  background-position: calc(var(--mx, 50) * 1.5%) calc(var(--my, 50) * 1.5%);
  transform: translate(
    calc((var(--mx, 50) - 50) * 0.50px),
    calc((var(--my, 50) - 50) * 0.50px)
  );
}

/* ---------- Living-card video ---------- */
.gcard__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 400ms ease-out;
  z-index: 2;
  background: transparent;
}
.gcard__video.is-live { opacity: 1; }

/* ---------- Card back (stat dossier + certificate) ---------- */
.gcard__back {
  background:
    repeating-radial-gradient(circle at 30% 30%,
      transparent 0, transparent 15px,
      rgba(79,124,255,0.045) 15px, rgba(79,124,255,0.045) 16px),
    repeating-conic-gradient(from 0deg at 50% 42%,
      transparent 0deg, transparent 12deg,
      rgba(139,92,246,0.025) 12deg, rgba(139,92,246,0.025) 13deg),
    #06101F;
  border: 1px solid var(--gcard-accent-soft);
  box-shadow: inset 0 0 40px rgba(0,0,0,0.4);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 26px 18px 30px;
  gap: 9px;
}

.gcard__back-band {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 8px;
  background: linear-gradient(90deg, #6b4f0e, #d4af37, #f5d061, #d4af37, #6b4f0e);
}
.gcard--legendary .gcard__back-band {
  background: linear-gradient(135deg,
    #6b4f0e 0%, #a67c1a 10%, #d4af37 22%, #f5d061 35%, #fff2b8 44%,
    #f5d061 54%, #d4af37 68%, #a67c1a 82%, #6b4f0e 100%);
  box-shadow: inset 0 1px 0 rgba(255,242,184,0.6), inset 0 -1px 0 rgba(107,79,14,0.8);
}
.gcard--epic .gcard__back-band   { background: linear-gradient(90deg, #1a6e8e, #38d4ff, #1a6e8e); }
.gcard--rare .gcard__back-band   { background: linear-gradient(90deg, #2a4a8e, #4f7cff, #2a4a8e); }
.gcard--common .gcard__back-band { background: linear-gradient(90deg, #6e6a60, #F3EFE6, #6e6a60); }

.gcard__back-head {
  width: 100%;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: 4px;
  padding: 0 34px;
}
.gcard__back-edition {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gcard-accent);
}
.gcard--common .gcard__back-edition { color: rgba(243,239,230,0.75); }
.gcard__back-serial {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  color: var(--gcard-accent);
}
.gcard--common .gcard__back-serial { color: #F3EFE6; }

.gcard__back-crest {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin-top: 2px;
  background: #06101F;
  box-shadow: inset 0 0 14px rgba(0,0,0,0.7);
}
.gcard--legendary .gcard__back-crest {
  border: 2px solid transparent;
  background:
    linear-gradient(#06101F, #06101F) padding-box,
    linear-gradient(135deg,
      #6b4f0e 0%, #a67c1a 10%, #d4af37 22%, #f5d061 35%, #fff2b8 44%,
      #f5d061 54%, #d4af37 68%, #a67c1a 82%, #6b4f0e 100%) border-box;
}
.gcard--epic .gcard__back-crest   { border: 2px solid #38d4ff; }
.gcard--rare .gcard__back-crest   { border: 2px solid #4f7cff; }
.gcard--common .gcard__back-crest { border: 2px solid rgba(243,239,230,0.6); }
.gcard__back-crest svg { width: 92%; height: 92%; }

.gcard__back-name {
  text-align: center;
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #ffffff;
  line-height: 1.1;
}

.gcard__back-stats {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-top: 2px;
  padding: 8px 4px;
  border-top: 1px solid rgba(255,255,255,0.08);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.gcard__back-stat {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}
.gcard__back-stat-l {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(243,239,230,0.5);
  flex: 0 0 auto;
  max-width: 42%;
  text-align: left;
}
.gcard__back-stat-v {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  text-align: right;
  color: #fff;
}
.gcard--legendary .gcard__back-stat-v {
  background: linear-gradient(180deg, #fff2b8 0%, #f5d061 55%, #d4af37 100%);
  background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.gcard--epic .gcard__back-stat-v { color: #bfeeff; }
.gcard--rare .gcard__back-stat-v { color: #cfd9ff; }

.gcard__back-moves {
  list-style: none;
  margin: 2px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
}

.gcard__back-tag {
  margin-top: auto;
  text-align: center;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gcard-accent);
  opacity: 0.85;
}

.gcard__flip--back {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(6,16,31,0.92);
  border: 1px solid rgba(255,255,255,0.16);
  color: #F3EFE6;
  cursor: pointer;
  -webkit-
  transition: background 180ms ease, transform 180ms ease, color 180ms ease;
  z-index: 5;
}
.gcard__flip--back:hover { background: rgba(6,16,31,0.92); color: var(--gcard-accent); transform: rotate(180deg); }
.gcard__flip--back svg { width: 14px; height: 14px; }

/* ---------- Flagship modifier ---------- */
.gcard--flagship {
  box-shadow: 0 0 0 1px var(--gcard-accent-soft);
}
.gcard--flagship.gcard--legendary {
  box-shadow: 0 0 0 1px rgba(245,208,97,0.45), 0 0 32px rgba(245,208,97,0.20);
}

/* ---------- Featured (mobile spotlight) ---------- */
.gcard-tilt.is-featured {
  z-index: 8;
}
.gcard-tilt.is-featured .gcard__video { opacity: 1; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .gcard-tilt {
    transform: rotateX(0) rotateY(0) !important;
    box-shadow: 0 18px 36px -8px rgba(0,0,0,0.5);
  }
  .gcard {
    transition: transform 0.3s ease-out;
  }
  .gcard__portrait,
  .gcard__info,
  .gcard__emblem,
  .gcard__crest,
  .gcard__foil,
  .gcard__sheen {
    transform: none !important;
  }
  .gcard__info   { transform: none !important; }
  .gcard__emblem { transform: none !important; }
  .gcard__crest  { transform: none !important; }
  .gcard__foil   { transform: none !important; }
  .gcard__sheen  { transform: none !important; }

  .gcard--legendary .gcard__foil {
    background: conic-gradient(from 45deg at 50% 50%,
      #4f7cff 0deg, #38d4ff 60deg, #8b5cf6 120deg,
      #4f7cff 180deg, #38d4ff 240deg, #8b5cf6 300deg, #4f7cff 360deg);
    opacity: 0.35;
  }
  .gcard--epic .gcard__foil {
    background: conic-gradient(from 45deg at 50% 50%,
      #38d4ff 0deg, #8b5cf6 180deg, #38d4ff 360deg);
    opacity: 0.3;
  }
  .gcard--rare .gcard__foil {
    background: conic-gradient(from 45deg at 50% 50%,
      #4f7cff 0deg, #38d4ff 180deg, #4f7cff 360deg);
    opacity: 0.25;
  }
  .gcard__sheen {
    background-position: 50% 50% !important;
  }
  .gcard__video { display: none !important; }
  .gcard-tilt:hover .gcard__emblem,
  .gcard-tilt:hover .gcard__crest {
    transform: none !important;
  }
  .gcard-tilt:hover .gcard__crest { transform: none !important; }
}

/* ---------- Touch / no-hover ---------- */
@media (hover: none) {
  .gcard-tilt {
    transform: rotateX(0) rotateY(0);
  }
  .gcard__portrait,
  .gcard__info,
  .gcard__emblem,
  .gcard__crest,
  .gcard__foil,
  .gcard__sheen {
    transform: none;
  }
  .gcard__info   { transform: none; }
  .gcard__emblem { transform: none; }
  .gcard__crest  { transform: none; }
  .gcard__foil   { transform: none; }
  .gcard__sheen  { transform: none; }
}

/* ---------- Filter tabs (preserved) ---------- */
[data-sport-filter] {
  appearance: none;
  -webkit-appearance: none;
  background: rgba(6,16,31,0.6);
  border: 1px solid rgba(255,255,255,0.10);
  color: #F3EFE6;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 9px 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease;
}
[data-sport-filter]:hover {
  background: rgba(6,16,31,0.9);
  border-color: rgba(255,255,255,0.22);
}
[data-sport-filter].is-active {
  background: #F3EFE6;
  color: #06101F;
  border-color: #F3EFE6;
}

/* ---------- My Picks ledger (preserved from Wave 3/4) ---------- */
.ledger__empty {
  width: 100%;
  padding: 28px 18px;
  text-align: center;
  color: rgba(255,255,255,0.52);
  font-family: "Inter", sans-serif;
  font-size: 14px;
  line-height: 1.45;
  border: 1px dashed rgba(56,212,255,.28);
  border-radius: 16px;
  background: rgba(56,212,255,.03);
}
.ledger__empty::before { content:"◆"; display:block; color:#38d4ff; font-size:15px; margin-bottom:8px; opacity:.8; }
.ledger__row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(150px, 1.2fr) minmax(180px, 1.5fr) minmax(110px, 0.8fr) minmax(90px, auto);
  gap: 14px;
  align-items: center;
  padding: 14px 14px 14px 17px;
  border: 1px solid rgba(255,255,255,0.09);
  border-left: 3px solid #38d4ff;
  border-radius: 14px;
  background: linear-gradient(90deg, rgba(56,212,255,0.08), transparent 34%), rgba(255,255,255,0.03);
  box-shadow: 0 14px 34px rgba(0,0,0,0.26), inset 0 1px 0 rgba(255,255,255,0.045);
}
.ledger__row--won {
  border-left-color: #f5d061;
  background: linear-gradient(90deg, rgba(245,208,97,0.14), rgba(56,212,255,0.06), rgba(139,92,246,0.08)), rgba(255,255,255,0.035);
  box-shadow: 0 0 30px rgba(245,208,97,0.10), 0 14px 34px rgba(0,0,0,0.28), inset 0 1px 0 rgba(255,255,255,0.06);
}
.ledger__row--open { border-left-color: #4f7cff; }
.ledger__row--missed { border-left-color: rgba(255,255,255,0.18); opacity: 0.58; filter: saturate(0.72); }
.ledger__player { color:#fff; font-family:"Space Grotesk",sans-serif; font-size:15px; font-weight:700; letter-spacing:-0.025em; line-height:1.15; }
.ledger__sport { display:inline-flex; vertical-align:middle; margin-left:7px; border:1px solid rgba(56,212,255,0.2); border-radius:999px; padding:4px 6px; background:rgba(56,212,255,0.06); color:rgba(255,255,255,0.64); font-family:"JetBrains Mono",monospace; font-size:9px; font-weight:900; letter-spacing:0.11em; line-height:1; text-transform:uppercase; }
.ledger__pred { color:rgba(255,255,255,0.58); font-family:"Inter",sans-serif; font-size:13px; line-height:1.35; }
.ledger__your { color:rgba(255,255,255,0.72); font-family:"Inter",sans-serif; font-size:13px; line-height:1.3; }
.ledger__status { justify-self:end; color:rgba(255,255,255,0.48); font-family:"JetBrains Mono",monospace; font-size:10px; font-weight:900; letter-spacing:0.13em; line-height:1; text-transform:uppercase; }
.ledger__row--won .ledger__status { color:#f5d061; text-shadow:0 0 14px rgba(245,208,97,0.36); }
.ledger__row--open .ledger__status { color:rgba(79,124,255,0.95); }
@media (max-width: 720px) {
  .ledger__row { grid-template-columns: 1fr; gap: 8px; padding: 15px 15px 15px 17px; }
  .ledger__status { justify-self: start; }
}

/* ---------- Legal fine-print (preserved) ---------- */
.gcards-legal { margin:40px auto 0; max-width:80ch; color:rgba(255,255,255,.52); font-size:12px; line-height:1.6; border-top:1px solid rgba(255,255,255,.10); padding-top:20px; }
.gcards-legal b { color:rgba(255,255,255,.72); font-weight:700; }
/* ---------- WAVE 4.5 gold-read elevation (Legendary only — gold = value) ---------- */
/* A crisp engraved gold hairline frames every Legendary card so gold reads against the blue. */
.gcard--legendary .gcard__front::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 13px;
  pointer-events: none;
  z-index: 4;
  border: 1px solid transparent;
  background:
    linear-gradient(#0000, #0000) padding-box,
    linear-gradient(135deg, #a67c1a, #f5d061 30%, #fff2b8 48%, #d4af37 70%, #a67c1a) border-box;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0.75;
}
/* stronger gold sheen sweep on the Legendary name */
.gcard--legendary .gcard__name::after { opacity: 0.85; }
.gcard--legendary .gcard__name { text-shadow: 0 0 18px rgba(245,208,97,0.22); }
/* Legendary prediction eyebrow + a thin gold rule = value cue */
.gcard--legendary .gcard__pred-eyebrow { color: #f5d061; }
.gcard--legendary .gcard__prediction { border-top: 1px solid rgba(245,208,97,0.28); }
/* Legendary foil gains a hotter gold shimmer band so metal catches light */
.gcard--legendary .gcard__foil::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(calc(74deg + var(--mx, 50) * 2.2deg),
    transparent 38%, rgba(255,242,184,0.42) 49%, rgba(245,208,97,0.30) 52%, transparent 64%);
  mix-blend-mode: overlay;
  opacity: 0.9;
}
/* the compact crest gets a gold ring glow on Legendary so the authenticity mark reads as premium */
.gcard--legendary .gcard__crest { box-shadow: inset 0 0 4px rgba(0,0,0,0.6), 0 0 10px rgba(245,208,97,0.4); }
