:root {
  --bg: #0f0717;
  --card: #140a1f;
  --muted: #a3a3b3;
  --accent: #a855f7;
  --accent-2: #6d28d9;
  --glass: rgba(255, 255, 255, 0.04);
  --danger: #fb7185;
  --card-radius: 14px;
  --glass-border: rgba(255, 255, 255, 0.06);
  --shadow: 0 8px 30px rgba(0, 0, 0, 0.7);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI",
    Roboto, "Helvetica Neue", Arial;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html,
body {
  height: 100%;
}

/* === Background and animation === */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 30% 20%, rgba(168, 85, 247, 0.1), transparent 70%),
    radial-gradient(circle at 80% 80%, rgba(109, 40, 217, 0.1), transparent 70%);
  z-index: -1;
}

body {
  background: linear-gradient(120deg, #1a002e, #0a0014, #190028);
  background-size: 400% 400%;
  animation: gradientMove 18s ease infinite;
  color: #e6e6f6;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px;
  overflow-x: hidden;
}

@keyframes gradientMove {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* =========================================================
   CARD LIST
   ========================================================= */

/* === Card Container === */
.card-container {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  margin-top: 10px;
}

/* === Card Base === */
.card {
  display: grid;
  width: 960px;
  max-width: 95vw;
  background: rgba(20, 10, 30, 0.55);
  border-radius: var(--card-radius);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  grid-template-columns: 220px 1fr;
  grid-template-rows: auto;
  align-items: center;
  overflow: hidden;
  position: relative;
  transition: all 0.45s ease;
  transform-origin: center;
  padding: 22px 30px;
  cursor: pointer;
  min-height: 160px;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 35px rgba(168, 85, 247, 0.25);
}

/* Expanded depth focus */
.card.expanded {
  height: auto;
  grid-template-columns: 260px 1fr;
  align-items: start;
  padding: 36px 42px;
  backdrop-filter: blur(18px) brightness(1.05);
  box-shadow: 0 18px 50px rgba(168, 85, 247, 0.35);
  transform: scale(1.02);
  z-index: 3;
}

/* Compact (non-expanded) cards */
.card:not(.expanded) {
  height: 160px;
  overflow: hidden;
  align-items: start !important;
}

/* body blur when a card is active */
body.card-active .card {
  opacity: 0.45;
  filter: blur(2px);
  transition: opacity 0.4s ease, filter 0.4s ease;
}

body.card-active .card.expanded {
  opacity: 1;
  filter: none;
  transform: scale(1.02);
  z-index: 3;
}

/* === Profile Section === */
.profile-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 6px;
}

.profile-section img {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  object-fit: cover;
  transition: all 0.4s ease;
}

.card.expanded .profile-section img {
  width: 120px;
  height: 120px;
  transform: scale(1.05);
}

.profile-section h3 {
  color: var(--accent);
  font-size: 1rem;
  margin-top: 8px;
}

.profile-section .bio {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.3;
  margin-top: 8px;
  max-width: 220px;
  opacity: 0;
  transform: translateY(-5px);
  transition: all 0.4s ease;
}

.card.expanded .bio {
  opacity: 1;
  transform: translateY(0);
}

/* === Stats inside card === */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  align-items: start;
  transition: all 0.4s ease;
}

.stat {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 14px 16px;
  opacity: 0.9;
  transform: translateY(10px);
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.card.expanded .stat {
  transform: translateY(0);
  opacity: 1;
}

.stat h4 {
  font-size: 0.85rem;
  color: #bbaaf2;
  margin-bottom: 3px;
}

.stat p {
  font-weight: 600;
  font-size: 1.1rem;
  color: #f7f3ff;
}

.stat small {
  display: block;
  color: #a39ac6;
  font-size: 0.75rem;
  margin-top: 2px;
}

/* Extended stats only when expanded */
.stat.volatility,
.stat.trustIndex,
.performanceBadge {
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: all 0.4s ease;
}

.card.expanded .stat.volatility,
.card.expanded .stat.trustIndex,
.card.expanded .performanceBadge {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

/* === Badge === */
.performanceBadge {
  margin-top: 10px;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 999px;
  backdrop-filter: blur(6px);
  box-shadow: 0 0 8px rgba(168, 85, 247, 0.2);
}

.performanceBadge.top {
  background: rgba(168, 85, 247, 0.25);
  border-color: rgba(168, 85, 247, 0.5);
}

.performanceBadge.rising {
  background: rgba(96, 165, 250, 0.25);
  border-color: rgba(96, 165, 250, 0.5);
}

.performanceBadge.low {
  background: rgba(239, 68, 68, 0.25);
  border-color: rgba(239, 68, 68, 0.5);
}

/* Fade on scroll */
.fade-init {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}

.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Subtle glow on expand */
.card.expanded::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    circle at top left,
    rgba(168, 85, 247, 0.25),
    transparent 70%
  );
  opacity: 0.25;
  pointer-events: none;
  z-index: 0;
}

/* =========================================================
   FLOATING MENU
   ========================================================= */

.floating-menu {
  position: fixed;
  top: 50%;
  left: 35px;
  transform: translateY(-50%);
  z-index: 9999;
}

/* Round main button */
.menu-button {
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 24px;
  color: #fff;
  cursor: pointer;
  transition: transform 0.25s ease, background 0.25s ease;
}

.menu-button:hover {
  transform: scale(1.08);
  background: rgba(255, 255, 255, 0.12);
}

/* Menu items to the right */
.menu-items {
  position: absolute;
  top: 50%;
  left: 75px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transform: translateY(-50%) translateY(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.floating-menu.open .menu-items {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(-50%) translateY(0);
}

.menu-item {
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
  border-radius: 10px;
  color: #fff;
  font-size: 0.95rem;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.25s ease, transform 0.25s ease;
}

.menu-item:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: translateX(5px);
}

/* =========================================================
   HOME PAGE
   ========================================================= */

.home-wrapper {
  width: 100%;
  height: calc(100vh - 80px);
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.home-title {
  font-size: 3.2rem;
  font-weight: 800;
  color: #ffffffdd;
  text-shadow: 0 0 20px rgba(168, 85, 247, 0.25);
  position: relative;
  overflow: hidden;
  display: inline-block;
}

/* Shimmer */
.shimmer-glow {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    120deg,
    transparent 0%,
    rgba(168, 85, 247, 0.35) 40%,
    rgba(255, 255, 255, 0.75) 50%,
    rgba(109, 40, 217, 0.35) 60%,
    transparent 100%
  );
  transform: translateX(-130%);
  mix-blend-mode: screen;
  pointer-events: none;
}

@keyframes shimmerOnce {
  0% {
    transform: translateX(-130%);
  }
  50% {
    transform: translateX(120%);
  }
  100% {
    transform: translateX(120%);
  }
}

/* Page transition container */
#pageContent {
  opacity: 1;
  transition: opacity 0.4s ease;
}

#pageContent.fade-out {
  opacity: 0;
}

/* =========================================================
   SEARCH / FILTER BAR
   ========================================================= */

.search-wrapper {
  width: 100%;
  max-width: 960px;
  position: relative;
  margin-bottom: 20px;
}

.searchbar {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 20;
}

.searchbar input {
  flex: 1;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.08),
    rgba(255, 255, 255, 0.03)
  );
  color: #e6e6f6;
  font-size: 15px;
  outline: none;
  box-shadow: inset 0 0 8px rgba(0, 0, 0, 0.4);
  transition: border 0.3s, box-shadow 0.3s;
}

.searchbar input:focus {
  border-color: var(--accent-2);
  box-shadow: 0 0 12px rgba(109, 40, 217, 0.3);
}

.filter-btn,
.sort-btn {
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  cursor: pointer;
  transition: 0.25s ease;
  backdrop-filter: blur(6px);
}

.filter-btn:hover,
.sort-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

/* FILTER PANEL BASE */
/* Position filter panel under the Filter button */
.filter-panel {
  position: absolute;
  top: 50px; /* under the search bar */
  left: 815px;   /* align with left side of wrapper */
  z-index: 9999;

  width: 420px;
  padding: 22px;
  border-radius: 18px;
  background: rgba(255,255,255,0.10);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.25);
  box-shadow: 0 8px 30px rgba(0,0,0,0.35);

  display: flex;
  flex-direction: column;
  gap: 20px;

  opacity: 1;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}








.filter-panel.hidden {
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
}


/* ACCORDION */
.accordion-header {
  width: 100%;
  background: rgba(255,255,255,0.12);
  padding: 12px 15px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.25);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}

.accordion-body {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height .25s ease, opacity .25s ease;
  margin-top:10px;
}

.accordion-body.open {
  max-height: 600px;
  opacity: 1;
}

.accordion-header {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 10px 14px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,0.2);
  transition: background 0.2s ease;
}

.accordion-header.open {
  background: rgba(255, 255, 255, 0.15);
}










/* FORM ROWS (2 columns) */
.form-row {
  display: grid;
  grid-template-columns: 130px 1fr 1fr;
  gap: 10px;
  align-items: center;
  margin-block:10px;
}

.form-row > label {
  font-size: 13px;
  color: #ccc;
  margin-bottom: 0;
  white-space: nowrap;
}

.form-row input {
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  color: #fff;
  outline: none;
  min-width: 0;
}


/* APPLY BUTTON */
.apply-btn {
  margin-top: 10px;
  width: 100%;
  padding: 12px 0;
  background: #8b3fff;
  color: #fff;
  border-radius: 10px;
  text-align: center;
  border: none;
  font-weight: 600;
  transition: 0.2s;
}


.apply-btn:hover {
  background: #a460ff;
}


/* SORT PANEL BASE */
.sort-panel {
  position: absolute;
  top: 70px;
  right: 10px;

  width: 260px;
  background: rgba(255,255,255,0.08);
  padding: 18px 22px;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,0.20);
  backdrop-filter: blur(16px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.45);

  display: flex;
  flex-direction: column;
  gap: 14px;

  opacity: 1;
  transform: translateY(10px);
  transition: opacity .25s ease, transform .25s ease;
  z-index: 9999;
}

.sort-panel.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px);
}



/* =========================================================
   POPUP OVERLAY + CARD
   ========================================================= */

/* Overlay */
.popup {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
  pointer-events: auto;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.popup.hidden {
  display: none;
}

.popup.visible {
  opacity: 1;
  pointer-events: auto;
}

/* Popup content */
.popup-content {
  width: 45vw;
  max-width: 1500px;
  height: 90vh;
  max-height: 92vh;
  background: rgba(20, 10, 30, 0.7);
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(30px);
  box-shadow: 0 0 45px rgba(0, 0, 0, 0.6);
  padding: 48px 60px;
  position: relative;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  gap: 30px;
  transform: scale(0.97);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.popup.visible .popup-content {
  transform: scale(1);
}

/* Scrollbar styling */
.popup-content::-webkit-scrollbar {
  width: 10px;
}
.popup-content::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.25);
  border-radius: 10px;
}
.popup-content::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.35);
}

/* Close button */
.popup-close {
  position: absolute;
  top: 18px;
  right: 18px;
  padding: 5px 12px;
  font-size: 20px;
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: background 0.25s ease;
}

.popup-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Freeze main page when popup open */
body.popup-open {
  overflow: hidden !important;
  position: fixed !important;
  width: 100%;
  top: 0;
  left: 0;
}

/* =========================================================
   HERO BLOCK (TOP OF POPUP)
   ========================================================= */

/* Wrapper: left metrics, center (avatar + bio + followers/eng), right metrics */
.popup-hero {
  position: relative;
  padding: 1px 0 0px;
  width: 100%;
  display: grid;
  grid-template-areas: "left center right";
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  justify-items: center;
  max-height: 350px;
}

/* Big horizontal halo behind hero section */
.hero-halo {
  position: absolute;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 140%;
  height: 360px;
  background: radial-gradient(
    ellipse at center,
    rgb(168 85 247 / 36%) 0%,
    rgba(168, 85, 247, 0) 100%
  );
  filter: blur(20px);
  z-index: 0;
  pointer-events: none;
  opacity: 0.95;

  animation: heroHaloPulse 4.8s ease-in-out infinite;
}



@keyframes heroHaloPulse {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.35;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.07);
    opacity: 0.95;
  }
  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.35;
  }
}





/* Particle container */
.hero-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: visible;
}

/* Base particle */
.hero-particles span {
  position: absolute;
  width: 6px;
  height: 6px;
  background: rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  filter: blur(3px);

  /* Start at the AVATAR center */
  top: 50%;
  left: 50%;

  /* Each particle gets its own random direction & delay */
  animation: particleFloat 4s ease-out infinite;
  opacity: 0;
}

/* Randomized positions */
.hero-particles span:nth-child(1) { left: 48%; top: 58%; animation-delay: 0s; }
.hero-particles span:nth-child(2) { left: 42%; top: 62%; animation-delay: 1s; }
.hero-particles span:nth-child(3) { left: 55%; top: 55%; animation-delay: 2.2s; }
.hero-particles span:nth-child(4) { left: 50%; top: 65%; animation-delay: 1.4s; }
.hero-particles span:nth-child(5) { left: 60%; top: 58%; animation-delay: 3s; }
.hero-particles span:nth-child(6) { left: 38%; top: 55%; animation-delay: 2.7s; }
.hero-particles span:nth-child(7) { left: 46%; top: 50%; animation-delay: 4s; }
.hero-particles span:nth-child(8) { left: 53%; top: 63%; animation-delay: 3.4s; }

@keyframes particleFloat {
  0% {
    transform: translate(0, 0) scale(0.6);
    opacity: 0;
  }
  10% {
    opacity: 0.8;
  }
  60% {
    transform: translate(calc(var(--dx) * 0.7), calc(var(--dy) * 0.7)) scale(1);
    opacity: 0.9;
  }
  100% {
    transform: translate(var(--dx), var(--dy)) scale(0.4);
    opacity: 0;
  }
}

/* Randomized direction and delay for each particle */

.hero-particles span:nth-child(n) {
  --dx: calc((rand(-100, 100)) * 1px);
  --dy: calc((rand(-150, -20)) * 1px);
  --delay: calc(rand(0, 4000) * 1ms);
}


.hero-particles span:nth-child(1)  { --dx: 40px;  --dy: -90px; --delay: 0ms; }
.hero-particles span:nth-child(2)  { --dx: -30px; --dy: -70px; --delay: 300ms; }
.hero-particles span:nth-child(3)  { --dx: 15px;  --dy: -110px; --delay: 800ms; }
.hero-particles span:nth-child(4)  { --dx: -60px; --dy: -100px; --delay: 1200ms; }
.hero-particles span:nth-child(5)  { --dx: 70px;  --dy: -120px; --delay: 1500ms; }
.hero-particles span:nth-child(6)  { --dx: -50px; --dy: -80px; --delay: 2000ms; }
.hero-particles span:nth-child(7)  { --dx: 25px;  --dy: -95px; --delay: 2400ms; }
.hero-particles span:nth-child(8)  { --dx: -20px; --dy: -140px; --delay: 2800ms; }
.hero-particles span:nth-child(9)  { --dx: 55px;  --dy: -130px; --delay: 3100ms; }
.hero-particles span:nth-child(10) { --dx: -10px; --dy: -60px; --delay: 3500ms; }
.hero-particles span:nth-child(11) { --dx: 40px;  --dy: -95px; --delay: 4000ms; }
.hero-particles span:nth-child(12) { --dx: -70px; --dy: -110px; --delay: 4300ms; }
.hero-particles span:nth-child(13) { --dx: 30px;  --dy: -150px; --delay: 4600ms; }
.hero-particles span:nth-child(14) { --dx: -45px; --dy: -90px; --delay: 5000ms; }
.hero-particles span:nth-child(15) { --dx: 60px;  --dy: -130px; --delay: 5400ms; }




















/* Left + right metric columns */
.metrics-left,
.metrics-right {
  display: flex;
  flex-direction: column;
  gap: 14px; /* vertical distance between top/bottom metric boxes */
  z-index: 2;
  padding-bottom:90px;
}

/* Metric boxes with side-fade glass gradient */
.metric-box {
  position: relative;
  width: 220px;
  padding: 18px 20px;
  background: linear-gradient(
    to right,
    rgb(255 0 0 / 0%) 65%,
    rgb(36 18 54) 100%
  );
  border: 0px solid rgba(255, 255, 255, 0.12);
  border-radius: 30px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  text-align: center;
  z-index: 1;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
  transition: transform 0.25s ease, background 0.25s ease;
  min-height:130px;
}

.metric-box:hover {
  background: rgba(255, 255, 255, 0.12);
  transform: scale(1.02);
}

.metric-box h4 {
  font-size: 0.82rem;
  font-weight: 600;
  color: #dacfff;
  margin-bottom: 4px;
}

.metric-box p {
  font-size: 1.38rem;
  font-weight: 700;
  color: #fff;
}

/* Center hero area (avatar + bio + followers/eng) */
.hero-center {
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Avatar */
.popup-avatar {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  border: 3px solid var(--accent);
  object-fit: cover;
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.45);
  margin-bottom: 10px;
}

/* Username */
.hero-username {
  font-size: 1.55rem;
  font-weight: 700;
  color: #fff !important;
  margin-bottom: 6px;
  text-decoration: none !important;
}

/* Bio inside hero block — narrow so it wraps down */
.hero-bio {
  max-width: 200px;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.45;
  margin-bottom: 18px;
  word-wrap: break-word;
  text-align: center;
}

/* Followers + Engagement inline */
.hero-stats-inline {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom:100px;
}

.hero-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-label {
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: #baa4f2;
  text-transform: uppercase;
  margin-bottom: 3px;
  font-weight: 800;
}

.stat-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
}

/* Dot between Followers / Engagement */
.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  opacity: 0;
}

/* =========================================================
   POPUP LOWER SECTIONS (ABOUT / NOTES)
   ========================================================= */

.popup-section {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.popup-section h3 {
  margin-bottom: 8px;
  color: var(--accent);
  font-size: 1.2rem;
  text-align: center;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.popup-item {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 14px;
  border-radius: 10px;
}

.popup-item h4 {
  font-size: 0.85rem;
  color: #bbaaf2;
  margin-bottom: 4px;
}

.popup-item p {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}

/* =========================================================
   CARD ACTION MENU & DETAY BUTTON
   ========================================================= */

.card-action-menu {
  position: absolute;
  right: -80px;
  top: 40px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(12px);
  padding: 12px;
  border-radius: 12px;
  transition: opacity 0.25s ease, transform 0.25s ease;
  opacity: 0;
  transform: translateY(-5px);
  pointer-events: none;
  z-index: 9999;
}

.card-action-menu.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.card-action-menu button {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: background 0.25s;
}

.card-action-menu button:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Detail button inside card (only when expanded) */
.detail-btn {
  opacity: 0;
  pointer-events: none;
  transform: translateY(5px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  margin-top: 10px;
  padding: 8px 14px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 0.85rem;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.card.expanded .detail-btn {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.detail-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

.hero-username a:hover {
  text-decoration: underline;
  opacity: 0.85;
}


.popup-hero .hero-username a {
  color: #fff !important;
  text-decoration: none !important;
}

.popup-hero .hero-username a:hover {
  text-decoration: underline !important;
  opacity: 0.85;
}




/* Mini popup overlay */
.mini-popup {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999999;
}


.mini-popup.hidden {
  display: none;
}

/* Mini card */
.mini-popup-content {
  position: relative;
  width: 380px;
  padding: 28px;
  background: rgba(30, 15, 45, 0.9);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 14px;
  backdrop-filter: blur(12px);
  box-shadow: 0 0 25px rgba(0,0,0,0.4);
}


/* Text container */
.mini-popup-inner {
  font-size: 1.2rem;
  text-align: center;
  position: relative;
  z-index: 2;
  color: white;
}

.mini-popup-blur-layer {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  /* ✔ HEAVY Instagram blur */
  backdrop-filter: blur(8px) saturate(100%);
  /* ✔ Instagram purple-black mask */
  background: rgb(5 5 12 / 90%);


  z-index: 3;
  transition: opacity 0.35s ease;
}

/* When unlocked → blur fades out */
.mini-popup-blur-layer.unlocked {
  opacity: 0;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

/* Info (revealed when blur removed) */
.mini-popup-info {
  position: relative;
  z-index: 2;
  font-size: 1.2rem;
  font-weight: 600;
  padding: 10px;
  color: #fff;
}

/* Unlock button */
.mini-popup-unlock {
  position: absolute;
  bottom: -22px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 14px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 10px;
  color: #fff;
  cursor: pointer;
  z-index: 4;
}

.mini-unlock-btn:hover {
  background: rgba(255,255,255,0.2);
}

/* Toolbar */
.popup-toolbar {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 30px;
}

.toolbar-btn {
  padding: 10px 20px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  border-radius: 10px;
  cursor: pointer;
  transition: 0.25s ease;
  backdrop-filter: blur(6px);
}

.toolbar-btn:hover {
  background: rgba(255,255,255,0.15);
}


.loading-spinner {
  width: 100%;
  display: flex;
  justify-content: center;
  margin: 20px 0;
}

.loading-spinner.hidden {
  display: none;
}

.spinner-ring {
  width: 38px;
  height: 38px;
  border: 4px solid rgba(255,255,255,0.15);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spinLoader 0.6s linear infinite;
  filter: drop-shadow(0 0 6px rgba(168,85,247,0.5));
}

@keyframes spinLoader {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
