/* ═══════════════════════════════════════════════════════
   Banner carousel — split-flap animation
   ═══════════════════════════════════════════════════════ */

.xb-wrap {
  position: relative;
  width: 100%;
  background: var(--x-bg1, #0f1117);
  padding: 8px 16px;
  box-sizing: border-box;
}

/* ── Layout ── */
.xb-inner {
  display: flex;
  align-items: stretch;
  max-width: var(--x-max-w, 1240px);
  margin: 0 auto;
  height: 96px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,.25);
}

.xb-section {
  flex: 1;
  min-width: 0;
  perspective: 700px;
  overflow: hidden;
  position: relative;
  cursor: pointer;
}

/* separator between sections */
.xb-section + .xb-section {
  border-left: 1px solid rgba(255,255,255,.10);
}

/* Mobile: solo 1 sección visible */
@media (max-width: 767px) {
  .xb-inner {
    height: 88px;
  }
  .xb-section:not(:first-child) {
    display: none;
  }
}

/* ── Card ── */
.xb-card {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 10px 16px;
  transform-origin: 50% 50%;
  backface-visibility: hidden;
  will-change: transform;
  text-decoration: none;
}

/* Xchamba card (fondo fluor con gradiente) */
.xb-card--xchamba {
  background: var(--xb-gradient, linear-gradient(135deg, #39FF14 0%, #00c8a0 100%));
}
.xb-card--xchamba .xb-headline {
  font-family: 'Sora', -apple-system, sans-serif;
  font-size: .92rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,.45), 0 0 8px rgba(0,0,0,.3);
  line-height: 1.25;
  margin-bottom: 3px;
  letter-spacing: .1px;
}
.xb-card--xchamba .xb-subtext {
  font-size: .74rem;
  color: rgba(255,255,255,.88);
  text-shadow: 0 1px 3px rgba(0,0,0,.4);
  line-height: 1.35;
}

/* Post card */
.xb-card--post {
  background: var(--x-bg2, #1a1d27);
  flex-direction: row;
  align-items: center;
  gap: 12px;
}
.xb-card--post:hover {
  background: var(--x-bg3, #252830);
}
.xb-post-img {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--x-bg3, #252830);
}
.xb-post-img-placeholder {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  background: var(--x-bg3, #252830);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}
.xb-post-info {
  min-width: 0;
  flex: 1;
}
.xb-post-title {
  font-size: .84rem;
  font-weight: 600;
  color: var(--x-text1, #e4e6eb);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 3px;
}
.xb-post-meta {
  font-size: .75rem;
  color: var(--x-text2, #a0a3ad);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.xb-post-price {
  font-weight: 700;
  color: var(--x-accent, #0b5fff);
  margin-right: 6px;
}

/* ── Split-flap animation ── */
@keyframes xbFlipOut {
  from { transform: rotateX(0deg);    opacity: 1; }
  to   { transform: rotateX(-88deg);  opacity: .2; }
}
@keyframes xbFlipIn {
  from { transform: rotateX(88deg);   opacity: .2; }
  to   { transform: rotateX(0deg);    opacity: 1; }
}

.xb-card.is-flipping-out {
  animation: xbFlipOut .28s cubic-bezier(.4,0,.6,1) forwards;
}
.xb-card.is-flipping-in {
  animation: xbFlipIn  .28s cubic-bezier(.4,0,.2,1) forwards;
}

/* ── Nav buttons (< >) ── */
.xb-nav {
  position: absolute;
  top: 8px;
  bottom: 8px;
  width: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  background: rgba(0,0,0,.0);
  border: none;
  cursor: pointer;
  color: rgba(255,255,255,.35);
  font-size: .9rem;
  transition: color .2s, background .2s;
  padding: 0;
}
.xb-nav:hover {
  color: rgba(255,255,255,.85);
  background: rgba(0,0,0,.25);
}
.xb-nav--prev { left: 0; }
.xb-nav--next { right: 0; }
