/* OUR CARDS — built on the ProvidusUnity Bank design system
   (gold #fdb813 · dark #212529 · Montserrat + Inter) */

/* Hero card stack
   Same hero split as the card detail pages (cd-hero-grid, text left,
   visual right) and the same card "layout" (reuses the cd-face-*
   content classes from card-detail.css — chip, number, holder,
   expiry, network) but every card is shown at once, fanned into a
   stack instead of one card alone. Deliberately its own class (not
   .cd-face) so js/pages/card-tilt.js — which drives the mouse-tilt
   on detail pages — doesn't grab these and fight the fan transform. */
.cd-stack-wrap {
  position: relative;
  height: 460px;
  margin: 20px auto 0;
}

.cd-stack-card {
  --i: 0;
  position: absolute;
  left: 50%;
  top: 50%;
  width: 380px;
  aspect-ratio: 1.586;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 7px 20px rgba(0, 0, 0, 0.09), 0 1px 6px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  z-index: calc(var(--i) + 1);
  cursor: pointer;
  transform: translate(-50%, -50%) rotate(calc(-13deg + var(--i) * 3deg))
    translateY(calc(var(--i) * -3px)) scale(1);
  transition: transform 0.78s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.6s ease;
  will-change: transform;
  backface-visibility: hidden;
}

.cd-stack-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* auto-cycled by js/pages/card-stack-cycle.js — the "front" slot
   rotates between cards. Transform/z-index only, never opacity, so
   every card stays fully visible the whole time (no fade/ghosting) */
.cd-stack-card.is-active {
  z-index: 30;
  box-shadow: 0 8px 21px rgba(0, 0, 0, 0.09), 0 2px 7px rgba(0, 0, 0, 0.04);
  transform: translate(-50%, -58%) rotate(0deg) translateY(0) scale(1.05);
}

.cd-stack-card.is-leaving {
  z-index: 20;
}

.cd-stack-card:hover {
  z-index: 40;
  box-shadow: 0 9px 24px rgba(0, 0, 0, 0.1), 0 2px 7px rgba(0, 0, 0, 0.04);
  transform: translate(-50%, -62%) rotate(0deg) translateY(0) scale(1.06);
}

.cd-stack-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 18px 18px;
}

.cd-stack-card::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: linear-gradient(
    115deg,
    transparent 30%,
    rgba(255, 255, 255, 0.14) 45%,
    rgba(255, 255, 255, 0.22) 50%,
    rgba(255, 255, 255, 0.14) 55%,
    transparent 70%
  );
  pointer-events: none;
}

.page-sec.flush-top.is-first {
  padding-top: 88px;
}

/* Filter pills */
.pc-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.pc-pill {
  padding: 10px 24px;
  border-radius: 30px;
  background: #fff;
  border: 1.5px solid rgba(0, 0, 0, 0.09);
  font-family: "Inter", sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: #3a3a35;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.pc-pill:hover {
  border-color: rgba(253, 184, 19, 0.6);
}

.pc-pill.is-active {
  background: var(--gold);
  border-color: var(--gold);
  color: #1a1200;
}

/* Card grid */
.pc-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.pc-card-tile {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 18px;
  overflow: hidden;
  text-decoration: none;
  transition:
    transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.45s,
    border-color 0.3s;
}

.pc-card-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 13px 31px rgba(0, 0, 0, 0.06);
  border-color: rgba(253, 184, 19, 0.4);
}

.pc-card-tile.is-hidden {
  display: none;
}

/* Mini card face visual */
.pc-card-tile {
  perspective: 900px;
}

.pc-face {
  position: relative;
  margin: 20px 16px 0;
  aspect-ratio: 1.586;
  border-radius: 12px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #fff;
  overflow: hidden;
  box-shadow:
    0 9px 21px rgba(0, 0, 0, 0.12),
    0 1px 0 rgba(255, 255, 255, 0.08) inset;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transform: perspective(900px) rotateX(0deg) rotateY(0deg) scale(1);
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.pc-card-tile:hover .pc-face {
  transform: perspective(900px) translateY(-3px) scale(1.03);
}

.pc-face::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 14px 14px;
  pointer-events: none;
}

/* real card photo instead of the drawn mockup (pages that have one) */
.pc-face-photo {
  padding: 0;
}

.pc-face-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pc-face::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: linear-gradient(
    115deg,
    transparent 30%,
    rgba(255, 255, 255, 0.12) 45%,
    rgba(255, 255, 255, 0.2) 50%,
    rgba(255, 255, 255, 0.12) 55%,
    transparent 70%
  );
  pointer-events: none;
}

.pc-face-glare {
  position: absolute;
  inset: 0;
  z-index: 3;
  background: radial-gradient(
    circle at var(--glare-x, 50%) var(--glare-y, 50%),
    rgba(255, 255, 255, var(--glare-o, 0)) 0%,
    transparent 60%
  );
  mix-blend-mode: overlay;
  pointer-events: none;
}

.pc-face-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  font-family: "Inter", sans-serif;
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.02em;
  position: relative;
  z-index: 1;
}

.pc-chip {
  position: relative;
  width: 26px;
  height: 19px;
  border-radius: 4px;
  background: linear-gradient(135deg, #f4e5b8 0%, #d8b96a 45%, #f4e5b8 100%);
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
  overflow: hidden;
}

.pc-chip::before {
  content: "";
  position: absolute;
  inset: 2px;
  border: 1px solid rgba(26, 18, 0, 0.35);
  border-radius: 2px;
  background:
    linear-gradient(rgba(26, 18, 0, 0.25) 1px, transparent 1px) 0 0 / 100% 33%,
    linear-gradient(90deg, rgba(26, 18, 0, 0.25) 1px, transparent 1px) 0 0 / 50% 100%;
}

.pc-face-num {
  font-family: "Inter", monospace;
  font-size: 13px;
  letter-spacing: 0.06em;
  position: relative;
  z-index: 1;
}

.pc-face-bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.85;
  position: relative;
  z-index: 1;
}

.pc-net {
  font-family: "Inter", sans-serif;
  font-style: italic;
  font-weight: 800;
  font-size: 13px;
  text-transform: lowercase;
  letter-spacing: 0;
}

.pc-net-mc {
  position: relative;
  width: 32px;
  height: 18px;
}

.pc-net-mc::before,
.pc-net-mc::after {
  content: "";
  position: absolute;
  top: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
}

.pc-net-mc::before {
  left: 0;
  background: #eb5a2c;
  opacity: 0.9;
}

.pc-net-mc::after {
  left: 12px;
  background: #f2b100;
  opacity: 0.9;
  mix-blend-mode: multiply;
}

/* card face color tiers */
.pc-face-gold-verve { background: linear-gradient(135deg, #fdb813 0%, #b9860a 100%); color: #1a1200; }
.pc-face-gold-verve .pc-chip { background: linear-gradient(135deg, #3a2c08 0%, #1a1200 100%); }
.pc-face-gold-verve .pc-chip::before { border-color: rgba(255, 255, 255, 0.25); background: linear-gradient(rgba(255, 255, 255, 0.22) 1px, transparent 1px) 0 0 / 100% 33%, linear-gradient(90deg, rgba(255, 255, 255, 0.22) 1px, transparent 1px) 0 0 / 50% 100%; }
.pc-face-black-verve { background: linear-gradient(135deg, #262626 0%, #000 100%); }
.pc-face-platinum-verve { background: linear-gradient(135deg, #d4d8dd 0%, #9298a2 100%); color: #1a1a1a; }
.pc-face-platinum-verve .pc-chip { background: linear-gradient(135deg, #3a3f47 0%, #1a1d22 100%); }
.pc-face-platinum-verve .pc-chip::before { border-color: rgba(255, 255, 255, 0.25); background: linear-gradient(rgba(255, 255, 255, 0.22) 1px, transparent 1px) 0 0 / 100% 33%, linear-gradient(90deg, rgba(255, 255, 255, 0.22) 1px, transparent 1px) 0 0 / 50% 100%; }
.pc-face-classic-mc { background: linear-gradient(135deg, #2b3844 0%, #12181e 100%); }
.pc-face-platinum-mc { background: linear-gradient(135deg, #2e2e2e 0%, #000 100%); border: 1px solid rgba(253, 184, 19, 0.25); }
.pc-face-world-mc { background: linear-gradient(135deg, #43434a 0%, #131316 100%); }
.pc-face-world-elite-mc { background: linear-gradient(135deg, #14110a 0%, #000 100%); border: 1px solid rgba(253, 184, 19, 0.4); }
.pc-face-amphi { background: linear-gradient(135deg, #135353 0%, #061f1f 100%); }
.pc-face-credit { background: linear-gradient(135deg, #1c2c56 0%, #0a1229 100%); }
.pc-face-eco { background: linear-gradient(135deg, #206b42 0%, #0c2c1a 100%); }
.pc-face-business-mc { background: linear-gradient(135deg, #2f5d8f 0%, #0b1725 100%); }
.pc-face-world-exclusive-mc { background: linear-gradient(135deg, #1c0d13 0%, #000 100%); border: 1px solid rgba(200, 138, 158, 0.45); }

/* Tile body */
.pc-tile-body {
  padding: 18px 16px 24px;
}

.pc-tile-badge {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 8px;
}

.pc-tile-body h3 {
  font-family: "Inter", sans-serif;
  font-weight: 700;
  font-size: 17px;
  color: #1a1a1a;
  margin-bottom: 8px;
}

.pc-tile-body p {
  font-size: 12.5px;
  line-height: 1.6;
  color: #76766f;
  margin-bottom: 16px;
}

.pc-tile-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--gold);
}

.pc-tile-link svg {
  width: 12px;
  height: 12px;
  transition: transform 0.25s;
}

.pc-card-tile:hover .pc-tile-link svg {
  transform: translateX(4px);
}

/* Responsive */
@media (max-width: 1100px) {
  .pc-grid {
    grid-template-columns: 1fr 1fr;
  }

  .cd-stack-wrap {
    height: 400px;
    max-width: 460px;
    margin: 20px auto 0;
    order: -1;
  }

  .cd-stack-card {
    width: 320px;
  }

  /* lift page-hero-text's children into the grid so the crumb can be
     ordered above the card stack while the rest of the text stays below */
  .cd-hero-grid .page-hero-text {
    display: contents;
    text-align: center;
  }

  .cd-hero-grid .page-crumb {
    order: -2;
  }

  .cd-hero-grid .page-crumb,
  .cd-hero-grid .eyebrow,
  .cd-hero-grid .page-cta-row {
    justify-content: center;
  }

  .cd-hero-grid .page-lead {
    margin-left: auto;
    margin-right: auto;
  }
}

@media (max-width: 760px) {
  .page-sec.flush-top.is-first {
    padding-top: 56px;
  }

  .pc-grid {
    grid-template-columns: 1fr;
  }

  .cd-stack-wrap {
    height: 320px;
    max-width: 320px;
  }

  .cd-stack-card {
    width: 250px;
    transform: translate(-50%, -50%) rotate(calc(-9deg + var(--i) * 2deg))
      translateY(calc(var(--i) * -2px)) scale(1);
  }

  .cd-stack-card:hover {
    transform: translate(-50%, -58%) rotate(0deg) translateY(0) scale(1.08);
  }
}
