/* === Analyzer Pro Gating UI === */
.apexcharts-radialbar-area path,
.apexcharts-radialbar-track path,
.apexcharts-inner circle {
  fill: transparent !important;
  background: transparent !important;
}
.apexcharts-canvas {
  background: transparent !important;
}
.blurred {
  filter: blur(4px) brightness(0.7);
  transition: filter .4s ease;
}
.btn-upgrade {
  opacity:1!important;
  pointer-events:auto!important;
}
[data-pro="true"].blurred {
  position: relative;
}
.btn-upgrade, .unlock-badge {
  background: linear-gradient(135deg, #6c63ff, #8e7cff);
  color: #fff !important;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  padding: 10px 20px;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  transition: all 0.3s ease;
}
.btn-upgrade:hover {
  transform: translate(-50%, -50%) scale(1.05);
  box-shadow: 0 4px 12px rgba(108, 99, 255, 0.4);
}
.unlock-badge::after {
  content: "💎 Pro Feature";
  font-size: 12px;
  margin-left: 8px;
  color: #fff;
}

/* Gauge subtext fix - ensure readable below circular gauge */
.cb-gauge-subtext-fix {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  z-index: 25 !important;
  margin-top: 6px !important;
}

/* Ensure charts sit below subtext within cards */
.gauge-box .apexcharts-canvas,
.gauge-box .apexcharts-svg,
.gauge-container .apexcharts-canvas,
.gauge-container .apexcharts-svg {
  position: relative !important;
  z-index: 0 !important;
}

/* Optional styling tweak */
.apexcharts-canvas {
  margin-top: 10px !important;
}

/* --- FINAL PRO BLUR OVERRIDE --- */
body.pro-active * {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  transition: none !important;
  will-change: auto !important;
}

/* Target any leftover blurred/gated containers directly */
.blurred,
[data-pro="true"],
.cb-card.blurred,
.cb-gauge.blurred,
.cb-report.blurred,
.cb-result.blurred {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* Ensure ApexCharts layers are never blurred */
.apexcharts-canvas,
.apexcharts-inner,
.apexcharts-svg,
.apexcharts-radialbar,
.apexcharts-radialbar path,
.apexcharts-text {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
}

/* --- FINAL PATCH: Visual Unlock + Scroll Fix --- */

/* Remove underline (border or pseudo-element) under titles */
.cb-card h3::after,
.cb-gauge h3::after,
.cb-report h3::after,
.cb-result h3::after {
  content: none !important;
  border: none !important;
  background: none !important;
}

/* Completely disable pseudo-element blurs */
.blurred::before,
.blurred::after,
[data-pro="true"]::before,
[data-pro="true"]::after,
.cb-card::before,
.cb-card::after,
.cb-gauge::before,
.cb-gauge::after,
.cb-report::before,
.cb-report::after,
.cb-result::before,
.cb-result::after {
  content: none !important;
  display: none !important;
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* Ensure full-page scroll always works */
html, body {
  overflow: auto !important;
  height: auto !important;
}

/* Reinforce full unlock visuals */
body.pro-active * {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  transition: none !important;
  will-change: auto !important;
}

/* --- FINAL PATCH 2: Overlay, Underline, and Scroll Restore --- */

/* 1. Remove any white bottom line under titles */
.cb-card h3,
.cb-gauge h3,
.cb-report h3,
.cb-result h3 {
  border-bottom: none !important;
  box-shadow: none !important;
}
.cb-card h3::before,
.cb-card h3::after,
.cb-gauge h3::before,
.cb-gauge h3::after,
.cb-report h3::before,
.cb-report h3::after,
.cb-result h3::before,
.cb-result h3::after {
  content: none !important;
  display: none !important;
  border: none !important;
  background: none !important;
}

/* 2. Kill any overlay layers that sit on blurred cards */
.cb-card > div[class*="overlay"],
.cb-gauge > div[class*="overlay"],
.cb-report > div[class*="overlay"],
.cb-result > div[class*="overlay"],
.blurred > div[class*="overlay"],
[data-pro="true"] > div[class*="overlay"] {
  display: none !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* 3. Make sure blurred cards are fully visible */
.blurred,
[data-pro="true"],
.cb-card.blurred,
.cb-gauge.blurred,
.cb-report.blurred,
.cb-result.blurred {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  transition: none !important;
}

/* 4. Restore full scroll height */
html, body, .analyzer-wrapper, .cb-container, .cb-main {
  overflow: auto !important;
  height: auto !important;
  min-height: 100vh !important;
}

/* 5. Reinforce full unlock once Pro active */
body.pro-active * {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  transition: none !important;
  will-change: auto !important;
}

/* --- LAYOUT RESTORE PATCH: Fix analyzer centering + footer interactivity --- */

/* 1️⃣ Restore normal scrolling without breaking layout */
html, body {
  overflow-x: hidden !important;
  overflow-y: auto !important;
  height: auto !important;
  min-height: 100vh !important;
}

/* 2️⃣ Center and restore analyzer container layout */
.cb-container,
.cb-main,
.analyzer-wrapper,
.content-wrapper {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  height: auto !important;
  min-height: 100vh !important;
  overflow: visible !important;
}

/* 3️⃣ Restore grid layouts for gauges and report cards */
.cb-results-grid,
.cb-gauges,
.cb-reports {
  display: grid !important;
  width: 100% !important;
  max-width: 100% !important;
  overflow: visible !important;
  height: auto !important;
}

/* 4️⃣ Ensure footer and links are clickable */
footer,
.cb-footer,
.bottom-section,
footer a,
footer button,
footer .social-icons,
footer .social-icons a {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  cursor: pointer !important;
  position: relative !important;
  z-index: 10 !important;
}

footer a,
footer button,
footer .social-icons a {
  pointer-events: auto !important;
  cursor: pointer !important;
}

/* 5️⃣ Remove problematic universal overflow rule - replace with selective fixes */
/* Removed: * { overflow: visible !important; } - was breaking layout */

/* 6️⃣ Fix specific wrapper/container overflow issues without universal override */
section,
main {
  overflow: visible !important;
}

div[id*="wrapper"]:not(.analyzer-wrapper),
div[class*="wrapper"]:not(.analyzer-wrapper):not(.content-wrapper),
div[class*="container"]:not(.cb-container) {
  overflow: visible !important;
}

/* --- FINAL ANALYZER UNLOCK + FOOTER ROW FIX --- */

/* 1️⃣ Force html and body to allow vertical scroll */
html, body {
  overflow-x: hidden !important;
  overflow-y: auto !important;
}

/* 2️⃣ Footer socials horizontal flex row layout */
.cb-footer-socials,
footer .social-icons,
.cb-footer .social-icons,
.footer-socials {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap !important;
  gap: 12px !important;
  align-items: center !important;
  justify-content: center !important;
}

.cb-footer-socials a,
footer .social-icons a,
.cb-footer .social-icons a,
.footer-socials a {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  pointer-events: auto !important;
  cursor: pointer !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* 3️⃣ Remove underline and pseudo-element lines under headings when Pro active */
body.pro-active .cb-card h3::before,
body.pro-active .cb-card h3::after,
body.pro-active .cb-gauge h3::before,
body.pro-active .cb-gauge h3::after,
body.pro-active .cb-report h3::before,
body.pro-active .cb-report h3::after,
body.pro-active .cb-result h3::before,
body.pro-active .cb-result h3::after {
  content: none !important;
  display: none !important;
  border: none !important;
  background: none !important;
  box-shadow: none !important;
}

body.pro-active .cb-card h3,
body.pro-active .cb-gauge h3,
body.pro-active .cb-report h3,
body.pro-active .cb-result h3 {
  border-bottom: none !important;
  box-shadow: none !important;
}

/* 4️⃣ Remove all blur and backdrop-filter effects when Pro active */
body.pro-active .cb-card,
body.pro-active .cb-gauge,
body.pro-active .cb-report,
body.pro-active .cb-result,
body.pro-active [data-pro="true"],
body.pro-active .blurred,
body.pro-active .pro-blur {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* 5️⃣ Ensure containers have visible overflow and auto height for full scroll */
.cb-container,
.cb-main,
.analyzer-wrapper,
.cb-results-grid,
.cb-gauges,
.cb-reports {
  overflow: visible !important;
  height: auto !important;
  min-height: auto !important;
}

/* ============================================================
   FINAL SCROLL + BLUR OVERRIDE PRIORITY (PRO-ACTIVE CASCADE)
   ============================================================
   These rules must be at the VERY BOTTOM to win CSS cascade
   ============================================================ */

/* 1️⃣ Force all wrappers/containers to allow full scroll when Pro active */
body.pro-active [class*="wrapper"],
body.pro-active [class*="container"],
body.pro-active .cb-main,
body.pro-active .cb-container,
body.pro-active .content-wrapper,
body.pro-active .cb-results-grid {
  height: auto !important;
  min-height: 100vh !important;
  overflow-y: visible !important;
  overflow-x: hidden !important;
}

/* 2️⃣ Ultimate blur removal - highest priority when Pro active */
body.pro-active * {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  transition: none !important;
  will-change: auto !important;
}

/* 3️⃣ Remove all pseudo-element blur/underlines when Pro active */
body.pro-active .blurred::before,
body.pro-active .blurred::after,
body.pro-active [data-pro="true"]::before,
body.pro-active [data-pro="true"]::after,
body.pro-active .cb-card::before,
body.pro-active .cb-card::after,
body.pro-active .cb-gauge::before,
body.pro-active .cb-gauge::after,
body.pro-active .cb-report::before,
body.pro-active .cb-report::after,
body.pro-active .cb-result::before,
body.pro-active .cb-result::after {
  content: none !important;
  display: none !important;
  filter: none !important;
  backdrop-filter: none !important;
  border: none !important;
  background: none !important;
  box-shadow: none !important;
}

/* 4️⃣ Remove white underlines under gauge/card headings when Pro active */
body.pro-active .cb-card h3,
body.pro-active .cb-gauge h3,
body.pro-active .cb-report h3,
body.pro-active .cb-result h3 {
  border-bottom: none !important;
  box-shadow: none !important;
}

body.pro-active .cb-card h3::before,
body.pro-active .cb-card h3::after,
body.pro-active .cb-gauge h3::before,
body.pro-active .cb-gauge h3::after,
body.pro-active .cb-report h3::before,
body.pro-active .cb-report h3::after,
body.pro-active .cb-result h3::before,
body.pro-active .cb-result h3::after {
  content: none !important;
  display: none !important;
  border: none !important;
  background: none !important;
  box-shadow: none !important;
}

/* 5️⃣ Footer socials horizontal layout (ensure no parent overrides) */
body.pro-active .cb-footer-socials,
body.pro-active footer .social-icons,
body.pro-active .cb-footer .social-icons,
body.pro-active .footer-socials {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 12px !important;
}

body.pro-active .cb-footer-socials *,
body.pro-active footer .social-icons *,
body.pro-active .cb-footer .social-icons * {
  display: inline-flex !important;
}

/* 6️⃣ Force html/body overflow when Pro active */
body.pro-active,
body.pro-active html {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  height: auto !important;
  min-height: 100vh !important;
}

/* 7️⃣ Ensure sidebar scrolls when Pro active */
body.pro-active .sidebar-wrapper,
body.pro-active .sidebar .sidebar-wrapper {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  height: calc(100vh - 75px) !important;
  -webkit-overflow-scrolling: touch !important;
}

/* 8️⃣ Prevent blur/underlines from reappearing - ONLY when pro-active */
body.pro-active *:not(.swal2-container):not(.swal2-popup):not(.swal2-backdrop-show):not(.swal2-title):not(.swal2-content) {
  filter: none !important;
  backdrop-filter: none !important;
}

body.pro-active .blurred,
body.pro-active [data-pro="true"],
body.pro-active .pro-blur,
body.pro-active .cb-gauge,
body.pro-active .cb-card,
body.pro-active .cb-report,
body.pro-active .cb-result {
  filter: none !important;
  backdrop-filter: none !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

body.pro-active .blurred::before,
body.pro-active .blurred::after,
body.pro-active [data-pro="true"]::before,
body.pro-active [data-pro="true"]::after,
body.pro-active .cb-card::before,
body.pro-active .cb-card::after,
body.pro-active .cb-gauge::before,
body.pro-active .cb-gauge::after,
body.pro-active .cb-report::before,
body.pro-active .cb-report::after,
body.pro-active .cb-result::before,
body.pro-active .cb-result::after {
  content: none !important;
  display: none !important;
  filter: none !important;
  border: none !important;
  background: none !important;
  box-shadow: none !important;
}

/* Remove white underlines under gauge/card titles ONLY when pro-active */
body.pro-active .cb-card h3,
body.pro-active .cb-gauge h3,
body.pro-active .cb-report h3,
body.pro-active .cb-result h3 {
  border-bottom: none !important;
  border: none !important;
  box-shadow: none !important;
  background: none !important;
  background-image: none !important;
}

body.pro-active .cb-card h3::before,
body.pro-active .cb-card h3::after,
body.pro-active .cb-gauge h3::before,
body.pro-active .cb-gauge h3::after,
body.pro-active .cb-report h3::before,
body.pro-active .cb-report h3::after,
body.pro-active .cb-result h3::before,
body.pro-active .cb-result h3::after {
  content: none !important;
  display: none !important;
  border: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
  background: none !important;
  background-image: none !important;
  height: 0 !important;
  width: 0 !important;
}

/* 9️⃣ Footer spacing normalized - balanced height (60-80px total) */
body.pro-active .new-footer,
.new-footer {
  padding: 20px 40px 20px !important;
  margin-top: 0 !important;
  min-height: auto !important;
  height: auto !important;
}

body.pro-active .footer-container,
.footer-container {
  gap: 12px !important;
  z-index: 200 !important;
  padding: 0 !important;
}

body.pro-active .social-icons,
body.pro-active .footer-links,
body.pro-active .social-link,
body.pro-active .footer-link {
  pointer-events: auto !important;
  z-index: 201 !important;
  position: relative !important;
  cursor: pointer !important;
}

body.pro-active .social-link,
body.pro-active .footer-link {
  opacity: 1 !important;
  visibility: visible !important;
}

/* 🔟 Remove any overlay blocking footer interactions */
body.pro-active .pro-upgrade-popup,
body.pro-active .global-lock-overlay,
body.pro-active .locked-overlay,
body.pro-active [class*="overlay"]:not(.swal2-backdrop-show) {
  display: none !important;
  pointer-events: none !important;
  z-index: -1 !important;
}

/* 1️⃣1️⃣ Pro Unlock popup normal sizing - small, centered */
.pro-unlock-popup-normal,
.swal2-popup.pro-unlock-popup-normal {
  max-width: 400px !important;
  width: 400px !important;
  padding: 1.5rem !important;
  height: auto !important;
  max-height: none !important;
  margin: auto !important;
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
}

.pro-unlock-title-normal,
.swal2-title.pro-unlock-title-normal {
  font-size: 1.5rem !important;
  margin-bottom: 0.75rem !important;
  line-height: 1.3 !important;
}

.pro-unlock-content-normal,
.swal2-content.pro-unlock-content-normal {
  font-size: 0.95rem !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* Ensure Swal popup is properly sized */
body .swal2-popup {
  max-width: 400px !important;
  width: auto !important;
  height: auto !important;
  max-height: 90vh !important;
  padding: 1.5rem !important;
}

/* Unify all feedback card backgrounds to match Sound Match card */
.report-card {
  background: #062c85 !important;
}

/* Strengthen background consistency for analyzer cards */
.report-card,
.cb-card,
.report-card[data-type],
.cb-gauge-card {
  background: #062c85 !important;
  background-color: #062c85 !important;
  box-shadow: 0 0 20px rgba(0,0,0,0.4) !important;
}

.blurred-locked {
  filter: blur(6px) !important;
  opacity: 0.6 !important;
  pointer-events: none !important;
}
