/* ── 5P Detail Page ──────────────────────────────────────────────────────── */

/* Tab bar */
.fp-tabbar {
  position: absolute;
  top: .75rem;
  right: 1.5rem;
  z-index: 10;
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.fp-tab {
  display: inline-block;
  padding: .35rem 1.1rem;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-decoration: none;
  border: 1.5px solid rgba(255,255,255,0.35);
  border-radius: 2rem;
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(6px);
  transition: background .18s, color .18s, border-color .18s;
}
.fp-tab:hover { background: rgba(255,255,255,0.18); color: #fff; border-color: rgba(255,255,255,0.6); }
.fp-tab.active { background: #b8952a; border-color: #b8952a; color: #fff; }

/* Layout */
.fp-page {
  position: relative;
  padding-top: clamp(2rem, 8vw, 120px);
  padding-bottom: 7rem;
  background: #0f1117;
}
.fp-container { position: relative; z-index: 1; max-width: 1280px; margin: 0 auto; padding: 0 3rem; }

/* Eyebrow & counter */
.fp-eyebrow {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: .08em;
  color: #f0c84a;
  margin-bottom: .35rem;
  text-shadow: 0 1px 6px rgba(0,0,0,0.5);
}
.fp-counter {
  font-size: 1rem;
  color: rgba(255,255,255,0.65);
  margin-bottom: .75rem;
}

/* Title */
.fp-title {
  font-size: clamp(3.5rem, 9vw, 7rem);
  font-weight: 900;
  letter-spacing: -.03em;
  line-height: 1;
  color: #fff;
  margin: 0 0 .2rem;
  text-shadow: 0 2px 16px rgba(0,0,0,0.5);
}
.fp-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  font-weight: 500;
  color: rgba(255,255,255,0.85);
  margin: 0 0 1.75rem;
}

/* SDG icons */
.fp-sdg-row {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-bottom: 2rem;
}
.fp-sdg-row img { width: 68px; height: 68px; border-radius: 5px; }

/* CTA buttons */
.fp-btn-row { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3.5rem; }
.fp-btn {
  display: inline-block;
  padding: .75rem 2rem;
  border: 1.5px solid rgba(255,255,255,0.6);
  border-radius: 2rem;
  font-size: .95rem;
  font-weight: 600;
  color: #fff;
  background: rgba(255,255,255,0.12);
  text-decoration: none;
  transition: background .18s, color .18s, border-color .18s;
  backdrop-filter: blur(6px);
}
.fp-btn:hover { background: #b8952a; border-color: #b8952a; color: #fff; }

/* Stat cards */
.fp-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; margin-bottom: 3rem; }
@media (max-width: 768px) { .fp-stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .fp-stats { grid-template-columns: 1fr; } }

.fp-stat-card {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 1.75rem 1.5rem;
  backdrop-filter: blur(8px);
}
.fp-stat-val {
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  font-weight: 900;
  color: #fff;
  line-height: 1.1;
  letter-spacing: -.02em;
}
.fp-stat-unit {
  font-size: 1.1rem;
  font-weight: 600;
  color: #f0c84a;
  margin-left: .2rem;
}
.fp-stat-label {
  font-size: 1rem;
  font-weight: 700;
  color: #e5e7eb;
  margin-top: .5rem;
  line-height: 1.3;
}
.fp-stat-sub {
  font-size: .82rem;
  color: rgba(255,255,255,0.45);
  margin-top: .25rem;
  line-height: 1.3;
}

/* Gallery slideshow */
.fp-gallery {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: clamp(12rem, 56.25vw, 900px); /* 16:9 of viewport width */
  overflow: hidden;
  background: #111;
  z-index: 0;
}
.fp-gallery::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0)    0%,
    rgba(0,0,0,0.45) 30%,
    rgba(0,0,0,0.72) 55%,
    rgba(0,0,0,0.88) 75%,
    rgba(0,0,0,0.95) 100%
  );
  z-index: 2;
  pointer-events: none;
}
.fp-gallery-main {
  width: 100%;
  height: 100%;
  overflow: hidden;
}
.fp-gallery-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity .7s ease;
  pointer-events: none;
}
.fp-gallery-slide.active {
  opacity: 1;
  pointer-events: auto;
}
.fp-gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Next button */
.fp-next-wrap { display: flex; justify-content: flex-end; }
.fp-next-btn {
  display: inline-block;
  padding: .65rem 1.6rem;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 2rem;
  font-size: .88rem;
  font-weight: 700;
  color: #e5e7eb;
  text-decoration: none;
  transition: background .18s, color .18s;
  backdrop-filter: blur(6px);
}
.fp-next-btn:hover { background: #b8952a; border-color: #b8952a; color: #fff; }
