/* ============================================================
   X Games (page-only) styles
   Scope: body.case-xgames
   Depends on: css/case-system.css + css/galuhero-split-layout-v3.css
   ============================================================ */

body.case-xgames{
  --ink: #022351;
  --xgames-red: #d61f26;
}

/* ------------------------------------------------------------
   HERO: override the generic green from galuhero-split-layout-v3.css
   ------------------------------------------------------------ */
body.case-xgames .hero-split .hero-left{
  background-color: var(--xgames-red) !important;
}

/* Logos side-by-side */
body.case-xgames .hero-logos__row{
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:14px;
  margin:0 0 12px;
}

body.case-xgames .hero-logo{
  height:72px;
  width:auto;
  display:block;
}

@media (max-width:420px){
  body.case-xgames .hero-logo{ height:58px; }
}

/* ------------------------------------------------------------
   SEE IT IN ACTION
   ------------------------------------------------------------ */
body.case-xgames .video-row{
  width: min(1200px, calc(100% - 2rem));
  margin: 0 auto 3rem;
}

/* grid */
body.case-xgames .video-gallery{
  display:grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  margin-top: 1rem;
}

@media (min-width:900px){
  body.case-xgames .video-gallery{
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
    align-items: start;
  }
}

/* ------------------------------------------------------------
   VIDEO CARD: centered play button
   ------------------------------------------------------------ */
body.case-xgames .video-card{
  -webkit-appearance:none;
  appearance:none;
  border:0;
  padding:0;
  margin:0;
  background:transparent;
  font:inherit;

  position:relative;            /* KEY: anchor ::before/::after */
  display:block;
  width:100%;
  cursor:pointer;

  border-radius:18px;
  overflow:hidden;
  box-shadow: 0 10px 24px rgba(0,0,0,.08);
}

body.case-xgames .video-card:focus-visible{
  outline: 3px solid rgba(2,35,81,.25);
  outline-offset: 4px;
}

body.case-xgames .video-card img{
  display:block;
  width:100%;
  height:auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* If any old SVG play icon exists, hide it */
body.case-xgames .video-card .play-svg,
body.case-xgames .video-card svg{
  display:none !important;
}

/* Circle */
body.case-xgames .video-card::after{
  content:"";
  position:absolute;
  top:50%;
  left:50%;
  width:72px;
  height:72px;
  background: rgba(0,0,0,.78);
  border-radius:50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  pointer-events:none;
}

/* Triangle */
body.case-xgames .video-card::before{
  content:"";
  position:absolute;
  top:50%;
  left:50%;
  width:26px;
  height:26px;
  background:#fff;
  clip-path: polygon(28% 20%, 28% 80%, 82% 50%);
  transform: translate(-50%, -50%);
  z-index: 3;
  pointer-events:none;
}

@media (hover:hover){
  body.case-xgames .video-card:hover img{
    filter: brightness(.9);
    transform: scale(1.01);
    transition: transform .18s ease, filter .18s ease;
  }
}

/* ------------------------------------------------------------
   HARD RESET: kill legacy badge positioning
   ------------------------------------------------------------ */
body.case-xgames .video-card::before,
body.case-xgames .video-card::after{
  margin: 0 !important;
  inset: auto !important;
  right: auto !important;
  bottom: auto !important;
}

/* ============================================================
   XGAMES: Force centered play button (triangle + circle)
   Put this at the VERY BOTTOM of xgames.css
   ============================================================ */

body.case-xgames .video-card{
  position: relative !important; /* anchor pseudo elements */
}

/* Reset any legacy positioning/spacing */
body.case-xgames .video-card::before,
body.case-xgames .video-card::after{
  margin: 0 !important;
  inset: auto !important;
  right: auto !important;
  bottom: auto !important;
  display: block !important;     /* prevents "only triangle" outcomes */
  opacity: 1 !important;
  visibility: visible !important;
}

/* Circle */
body.case-xgames .video-card::after{
  content: "" !important;
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  width: 72px !important;
  height: 72px !important;
  border-radius: 50% !important;
  background: rgba(0,0,0,.78) !important;
  transform: translate(-50%, -50%) !important;
  z-index: 5 !important;
  pointer-events: none !important;
}

/* Triangle */
body.case-xgames .video-card::before{
  content: "" !important;
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  width: 26px !important;
  height: 26px !important;
  background: #fff !important;
  clip-path: polygon(28% 20%, 28% 80%, 82% 50%) !important;
  transform: translate(-50%, -50%) !important;
  z-index: 6 !important;
  pointer-events: none !important;
}

