/* Block 2c — Lucky Pick (3-card flip game)
 * Styles match the markup in class-pcs-block-lucky-pick.php + lucky-pick.js.
 */

/* ── Overlay ──────────────────────────────────────────────────────────────── */
.plp-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.plp-modal.plp-open {
  display: flex;
}

.plp-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

/* ── Container ────────────────────────────────────────────────────────────── */
.plp-container {
  position: relative;
  width: 100%;
  max-width: 60rem;
  max-height: 92vh;
  overflow-y: auto;
  background: linear-gradient(135deg, #171717 0%, #000000 100%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-top: 3px solid #febf00;
  border-radius: 16px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
  padding: 2rem 1rem 2.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: plp-pop 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes plp-pop {
  from { opacity: 0; transform: scale(0.94); }
  to   { opacity: 1; transform: scale(1); }
}

/* ── Close ────────────────────────────────────────────────────────────────── */
.plp-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 5;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s;
}
.plp-close:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* ── Header ───────────────────────────────────────────────────────────────── */
.plp-header {
  text-align: center;
  margin-bottom: 1.5rem;
  padding: 0 2rem;
}
.plp-title {
  color: #fff;
  font-size: 2rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.05;
  margin: 0 0 0.4rem;
}
.plp-sub {
  color: #febf00;
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0;
}

/* ── Cards row ────────────────────────────────────────────────────────────── */
.plp-cards-wrap {
  width: 100%;
}
.plp-cards {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  width: 100%;
  padding: 0.5rem 0;
}

/* ── Card ─────────────────────────────────────────────────────────────────── */
.plp-card {
  position: relative;
  flex: 0 0 auto;
  width: 15rem;
  height: 20rem;
  cursor: pointer;
  perspective: 1000px;
  transition: opacity 0.3s, transform 0.3s, filter 0.3s;
}
.plp-card.plp-dim {
  opacity: 0.45;
  transform: scale(0.92);
  filter: grayscale(60%);
}
.plp-card.plp-active {
  opacity: 1;
  transform: scale(1);
  filter: none;
}
.plp-card.plp-flipped {
  z-index: 5;
}

.plp-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.plp-card.plp-flipped .plp-card-inner {
  transform: rotateY(180deg);
}

/* Faces */
.plp-card-front,
.plp-card-back {
  position: absolute;
  inset: 0;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 14px;
  overflow: hidden;
}
.plp-card-front {
  background: #1a1a1a;
  border: 2px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}
.plp-card-back-img {
  width: 72%;
  height: 72%;
  object-fit: contain;
}
.plp-card-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(255, 255, 255, 0.12) 50%, transparent 60%);
  pointer-events: none;
}

.plp-card-back {
  transform: rotateY(180deg);
  background: #000;
  border: 2px solid #febf00;
}
.plp-card-creator-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}
.plp-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, #000 8%, transparent 55%);
}
.plp-card-info {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1rem;
  text-align: center;
}
.plp-card-name {
  color: #fff;
  font-size: 1.15rem;
  font-weight: 900;
  text-transform: uppercase;
  margin: 0 0 0.4rem;
  line-height: 1;
}
.plp-card-badge {
  display: inline-block;
  background: #febf00;
  color: #000;
  font-size: 0.66rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 3px 9px;
  border-radius: 99px;
  margin-bottom: 0.65rem;
}
.plp-visit-btn {
  display: block;
  width: 100%;
  background: #febf00;
  color: #000;
  border: none;
  border-radius: 9px;
  padding: 0.6rem;
  font-size: 0.85rem;
  font-weight: 900;
  text-transform: uppercase;
  cursor: pointer;
  transition: filter 0.15s;
}
.plp-visit-btn:hover {
  filter: brightness(1.08);
}

/* ── Swipe hint ───────────────────────────────────────────────────────────── */
.plp-swipe-hint {
  text-align: center;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.8rem;
  margin: 1rem 0 0;
}

/* ── Mobile ───────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .plp-container {
    padding: 1.75rem 0 2rem;
    border-radius: 14px;
  }
  .plp-header {
    margin-bottom: 1rem;
    padding: 0 1rem;
  }
  .plp-title {
    font-size: 1.5rem;
  }
  .plp-cards {
    justify-content: flex-start;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 0.5rem calc(50% - 7rem);
    gap: 1rem;
  }
  .plp-cards::-webkit-scrollbar {
    display: none;
  }
  .plp-card {
    width: 14rem;
    height: 18.5rem;
    scroll-snap-align: center;
  }
}
