/* Custom Global Styles for Saudaa Platform */

/* ── Reduced Motion (WCAG 2.3.3) ──────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .animate-ticker {
    animation: none !important;
  }
  .animate-pulse {
    animation: none !important;
  }
}

/* ── Focus Visible Ring (WCAG 2.4.7) ─────────────────────────────────────── */
:focus-visible {
  outline: 2px solid #42682b;
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── Skip Navigation ─────────────────────────────────────────────────────── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
.focus\:not-sr-only:focus {
  position: fixed;
  width: auto;
  height: auto;
  padding: 0.5rem 1rem;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

/* ── Ticker Accessibility ─────────────────────────────────────────────────── */
.ticker-wrap:hover .animate-ticker,
.ticker-wrap:focus-within .animate-ticker {
  animation-play-state: paused;
}

body {
  font-family: 'Manrope', sans-serif;
  overflow-x: hidden;
}

/* Custom scrollbars */
.custom-scrollbar::-webkit-scrollbar {
  width: 4px;
  height: 4px;
}
.custom-scrollbar::-webkit-scrollbar-track {
  background: transparent;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
  background-color: #c4c8be; /* outline-variant */
  border-radius: 9999px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background-color: #747870; /* outline */
}

/* Ticker Animation */
@keyframes ticker {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-50%, 0, 0);
  }
}

.animate-ticker {
  animation: ticker 30s linear infinite;
}

.animate-ticker:hover {
  animation-play-state: paused;
}

/* Live Price Strip Styling */
#price-ticker {
  display: flex;
  overflow: hidden;
  white-space: nowrap;
}

/* BSE LED Ticker Screen Wrapper */
.bse-ticker-screen {
  position: relative;
  background-color: #0b0c0e !important;
  box-shadow: inset 0 0 12px rgba(0, 0, 0, 0.95);
  border-bottom: 1px solid #1a1d20 !important;
}

/* LED Dotted Panel Overlay Mask (Dot-matrix Pixel Texture) */
.bse-ticker-screen::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: radial-gradient(rgba(0, 0, 0, 0.65) 20%, transparent 24%);
  background-size: 3.5px 3.5px;
  pointer-events: none;
  z-index: 15;
}

/* Vibrant Neon LED Glow Colors */
.text-led-green {
  color: #00e676 !important;
  text-shadow: 0 0 4px rgba(0, 230, 118, 0.45);
}

.text-led-red {
  color: #ff453a !important;
  text-shadow: 0 0 4px rgba(255, 69, 58, 0.5);
}

/* Ambient Shadows */
.ambient-depth-1 {
  box-shadow: 0 4px 20px 0 rgba(53, 61, 50, 0.03);
}

.ambient-depth-2 {
  box-shadow: 0 12px 30px 0 rgba(53, 61, 50, 0.07);
}

/* Preloader Smooth Exit */
.preloader-hidden {
  opacity: 0 !important;
  pointer-events: none !important;
  transition: opacity 0.4s ease-out;
}

/* Discord chat styles */
.discord-system-msg {
  color: #635f4b;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
}

.discord-user-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 8px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 1px 3px;
  border-radius: 3px;
}

/* Highlight effects */
.trader-row-btn {
  transition: all 0.15s ease-in-out;
}
.trader-row-btn:hover {
  transform: translateY(-1px);
}

/* Comparison Modal Animations & Custom Rules */
#compare-modal {
  transition: opacity 0.3s ease-out, visibility 0.3s ease-out;
}

#compare-modal .scale-95 {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.compare-card-selected {
  border-color: #42682b !important; /* primary */
  background-color: #faf9f4 !important; /* surface bg */
  box-shadow: 0 0 0 2px rgba(66, 104, 43, 0.15), 0 4px 12px rgba(53, 61, 50, 0.05);
}

.compare-card-selected .compare-checkbox-indicator {
  background-color: #42682b;
  color: #ffffff;
  border-color: #42682b;
}

/* Comparison results sticky metric header column */
.compare-sticky-col {
  position: sticky;
  left: 0;
  background-color: #f5f4ef; /* surface-container-low */
  z-index: 10;
  border-right: 1px solid rgba(196, 200, 190, 0.5); /* outline-variant */
}

/* Top Performer Highlight Border / Glow */
.top-performer-cell {
  background-color: rgba(139, 181, 111, 0.12) !important; /* primary-container 12% opacity */
  border: 1px solid rgba(66, 104, 43, 0.25) !important;
}

.top-performer-badge {
  background-color: #42682b;
  color: #ffffff;
}

/* Wizard transitions */
.animate-step-in {
  animation: stepIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes stepIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Custom Heatmap Sizing for exact 1600x900 aspect ratio on desktop */
.custom-heatmap-container {
  height: 450px !important;
}
.custom-heatmap-widget {
  height: 400px !important;
}
.custom-heatmap-widget iframe {
  height: 100% !important;
}

@media (min-width: 768px) {
  .custom-heatmap-container {
    height: 700px !important;
  }
  .custom-heatmap-widget {
    height: 650px !important;
  }
}

/* Chatbox Styles */
#calls {
  --ink2: #f5f4ef;
  --edge: #c4c8be;
  --edge2: rgba(196, 200, 190, 0.3);
  --cream: #1b1c19;
  --cream3: #747870;
  --cream4: #efeee9;
  --blood2: #ba1a1a;
  --gold2: #8c6f2d;
  --emerald: #42682b;
  --mono: 'JetBrains Mono', monospace;
  --sans: 'Manrope', sans-serif;
  --serif: Georgia, ui-serif, serif;
  
  background: var(--ink2) !important;
  color: var(--cream) !important;
}

.wr-layout {
  display: grid;
  grid-template-columns: 260px 1fr 280px;
  gap: 16px;
  margin-top: 40px;
  height: 620px;
}

@media (max-width: 1024px) {
  .wr-layout {
    grid-template-columns: 220px 1fr;
  }
  .wr-layout > .wr-col:last-child {
    display: none;
  }
}

@media (max-width: 768px) {
  .wr-layout {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 550px;
  }
  .wr-layout > .wr-col:first-child {
    display: none; /* Hide sidebar channels on mobile and toggle via dropdown instead */
  }
}

.wr-col {
  border: 1px solid var(--edge);
  border-radius: 12px;
  background: #ffffff;
  backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.wr-head {
  padding: 14px 18px;
  border-bottom: 1px solid var(--edge);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wr-head-label {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--cream3);
}

.wr-body {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--edge) transparent;
}

/* Channel list */
.ch {
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--edge2);
  transition: background .2s;
  cursor: pointer; /* Changed from 'none' for normal browser usability */
}

.ch:hover {
  background: rgba(82, 99, 74, 0.05);
}

.ch.active {
  background: rgba(82, 99, 74, 0.1);
  border-left: 3px solid var(--emerald);
}

.ch-ico {
  font-size: 14px;
  flex-shrink: 0;
  color: var(--cream3);
}

.ch-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--cream);
}

.ch-sub {
  font-family: var(--mono);
  font-size: 9px;
  color: var(--cream3);
  margin-top: 1px;
}

.ch-cnt {
  margin-left: auto;
  background: var(--emerald);
  color: #ffffff;
  border-radius: 10px;
  padding: 1px 7px;
  font-size: 9px;
  font-weight: 700;
}

/* Feed */
.feed-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  scrollbar-width: thin;
  scrollbar-color: var(--edge) transparent;
}

.msg {
  display: flex;
  gap: 11px;
  animation: msgIn .4s cubic-bezier(.16, 1, .3, 1) both;
}

@keyframes msgIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.msg-av {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
  background: var(--emerald);
  color: #ffffff;
}

.msg-c {
  flex: 1;
}

.msg-meta {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 4px;
  flex-wrap: wrap;
}

.msg-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--cream);
}

.msg-badge {
  font-family: var(--mono);
  font-size: 8px;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 2px;
}

.mb-elite {
  background: rgba(212, 168, 75, 0.12);
  color: var(--gold2);
  border: 1px solid rgba(212, 168, 75, 0.2);
}

.mb-pro {
  background: rgba(224, 68, 68, 0.1);
  color: var(--blood2);
  border: 1px solid rgba(224, 68, 68, 0.2);
}

.mb-rise {
  background: rgba(82, 99, 74, 0.1);
  color: var(--emerald);
  border: 1px solid rgba(82, 99, 74, 0.2);
}

.msg-time {
  font-family: var(--mono);
  font-size: 9px;
  color: var(--cream3);
}

.msg-txt {
  font-size: 12px;
  color: rgba(27, 28, 25, 0.85);
  line-height: 1.65;
}

/* Call box */
.call-box {
  margin-top: 10px;
  padding: 14px 16px;
  border-radius: 8px;
  background: rgba(186, 26, 26, 0.05);
  border: 1px solid rgba(186, 26, 26, 0.18);
}

.call-box.gb {
  background: rgba(82, 99, 74, 0.05);
  border-color: rgba(82, 99, 74, 0.2);
}

.cb-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.cb-sym {
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

.cb-sym.r {
  color: var(--blood2);
}

.cb-sym.g {
  color: var(--emerald);
}

.cb-type {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.cb-type.buy {
  color: var(--emerald);
}

.cb-type.sell {
  color: var(--blood2);
}

.cb-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.cb-item-l {
  font-family: var(--mono);
  font-size: 8px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--cream3);
  margin-bottom: 3px;
}

.cb-item-v {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
}

.cb-item-v.g {
  color: var(--emerald);
}

.cb-item-v.r {
  color: var(--blood2);
}

/* Locked */
.locked {
  margin-top: 10px;
  padding: 14px 16px;
  border-radius: 8px;
  background: rgba(212, 168, 75, 0.04);
  border: 1px solid rgba(212, 168, 75, 0.15);
  display: flex;
  gap: 12px;
  align-items: center;
  cursor: pointer; /* Changed from 'none' for browser accessibility */
  transition: all .2s;
}

.locked:hover {
  background: rgba(212, 168, 75, 0.08);
  border-color: rgba(212, 168, 75, 0.3);
  transform: translateY(-1px);
}

.locked-i {
  font-size: 20px;
  flex-shrink: 0;
  color: var(--gold2);
}

.locked-title {
  font-weight: 700;
  font-size: 13px;
  color: var(--gold2);
  margin-bottom: 2px;
}

.locked-desc {
  font-size: 10px;
  color: var(--cream3);
  font-family: var(--mono);
}

/* Feed input */
.feed-foot {
  padding: 13px 16px;
  border-top: 1px solid var(--edge);
  display: flex;
  gap: 9px;
  flex-shrink: 0;
  align-items: center;
}

.feed-inp {
  flex: 1;
  background: var(--cream4) !important;
  border: 1px solid var(--edge) !important;
  border-radius: 6px;
  padding: 9px 13px;
  color: var(--cream) !important;
  font-family: var(--sans);
  font-size: 12px;
  outline: none;
  transition: border-color .2s;
}

.feed-inp:focus {
  border-color: var(--emerald) !important;
}

.feed-inp::placeholder {
  color: var(--cream3);
}

/* Right — movers */
.mover {
  padding: 14px 16px;
  border-bottom: 1px solid var(--edge2);
  display: flex;
  gap: 10px;
  align-items: center;
}

.mv-rank {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 400;
  color: var(--cream3);
  width: 24px;
}

.mv-info {
  flex: 1;
}

.mv-name {
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 2px;
  color: var(--cream);
}

.mv-chg {
  font-family: var(--mono);
  font-size: 10px;
}

.mv-chg.up {
  color: var(--emerald);
}

.mv-chg.dn {
  color: var(--blood2);
}

/* Typing Indicator styles */
.typing-bubble {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.05);
  padding: 10px 16px;
  border-radius: 12px;
  margin-top: 4px;
}

.typing-dot {
  width: 6px;
  height: 6px;
  background: var(--cream3);
  border-radius: 50%;
  animation: typingBounce 1.4s infinite ease-in-out both;
}

.typing-dot:nth-child(2) {
  animation-delay: .2s;
}

.typing-dot:nth-child(3) {
  animation-delay: .4s;
}

@keyframes typingBounce {
  0%, 80%, 100% {
    transform: scale(0);
  }
  40% {
    transform: scale(1);
  }
}

/* Scroll Indicator sliding line animation */
@keyframes scrollLine {
  0% {
    transform: translateY(-100%);
  }
  80% {
    transform: translateY(200%);
  }
  100% {
    transform: translateY(200%);
  }
}

.animate-scroll-line {
  animation: scrollLine 2s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}

/* Footer Custom Styles & Hover Animations */
.social-icon-btn {
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.social-icon-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 4px 12px rgba(66, 104, 43, 0.12);
}
.social-icon-btn svg {
  transition: transform 0.2s ease;
}
.social-icon-btn:hover svg {
  transform: scale(1.1);
}

footer a {
  position: relative;
  transition: color 0.2s ease;
}
footer a::after {
  content: '';
  position: absolute;
  width: 100%;
  transform: scaleX(0);
  height: 1px;
  bottom: -2px;
  left: 0;
  background-color: #42682b; /* primary */
  transform-origin: bottom right;
  transition: transform 0.25s ease-out;
}
footer a:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

/* Mobile Responsive Overrides */

/* Collapsible Mobile Menu panel classes */
.mobile-menu-active {
  display: block !important;
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* 1. Square Heatmap configuration on mobile screen */
@media (max-width: 767px) {
  .custom-heatmap-container {
    height: auto !important;
    aspect-ratio: 1 / 1 !important; /* Forces compact, box-shaped layout */
    max-height: 380px !important;
  }
  .custom-heatmap-widget {
    height: calc(100% - 30px) !important;
  }
}

/* 2. Responsive Floating Chatbot Widget on mobile */
@media (max-width: 639px) {
  #discord-bot-window {
    width: calc(100vw - 32px) !important;
    height: 70vh !important;
    max-height: 480px !important;
  }
  #discord-bot-widget {
    right: 16px !important;
    bottom: 16px !important;
  }
}

/* 3. Horizontal Client Tabs swipe bar on mobile dashboard */
@media (max-width: 639px) {
  #view-trader .flex-1.overflow-hidden {
    flex-direction: column !important;
  }
  
  #trader-clients-list {
    width: 100% !important;
    height: 64px !important;
    display: flex !important;
    flex-direction: row !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    white-space: nowrap !important;
    border-right: none !important;
    border-bottom: 1px solid rgba(196, 200, 190, 0.3) !important;
    padding: 8px !important;
    gap: 8px !important;
    flex-shrink: 0 !important;
  }
  
  #trader-clients-list p {
    display: none !important;
  }
  
  #trader-clients-list button {
    width: auto !important;
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 6px !important;
    padding: 6px 14px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
  }
  
  #trader-clients-list button span:last-child {
    font-size: 8px !important;
    margin-top: 0 !important;
  }
}

.fill-1 {
  font-variation-settings: 'FILL' 1 !important;
}

/* ──────────────────────────────────────────────────────────────────────────
   Visual Polish & Interactive Animation Enhancements
   ────────────────────────────────────────────────────────────────────────── */

/* 1. Scroll-Reveal Animations */
.scroll-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform, opacity;
}

.reveal-active {
  opacity: 1;
  transform: translateY(0);
}

/* Scroll-reveal staggered delays */
.delay-100 { transition-delay: 100ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }
.delay-400 { transition-delay: 400ms; }
.delay-500 { transition-delay: 500ms; }

/* 2. FAQ Accordion Height Interpolation (via CSS Grid) */
.faq-ans-wrapper {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  visibility: hidden;
  transition: grid-template-rows 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease-out, visibility 0.3s ease;
}

.faq-ans-wrapper.open {
  grid-template-rows: 1fr;
  opacity: 1;
  visibility: visible;
}

/* 3. Springy Chatbot Window Pop-Up */
#discord-bot-window {
  transform: scale(0.85) translateY(12px);
  transform-origin: bottom right;
  transition: opacity 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

#discord-bot-window.chatbot-open {
  transform: scale(1) translateY(0);
  opacity: 1 !important;
}

/* Chatbot FAB idle pulse indicator */
@keyframes fabPulse {
  0% {
    box-shadow: 0 0 0 0 rgba(66, 104, 43, 0.4);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(66, 104, 43, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(66, 104, 43, 0);
  }
}

#discord-bot-widget > button {
  animation: fabPulse 2s infinite;
}

/* 4. Table/Card Row Staggered Fade In */
@keyframes rowFadeIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.leaderboard-row-animate {
  animation: rowFadeIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* 5. Minimalist Hover Card Elevations & Button micro-animations */
.bg-surface-container-lowest, .wr-col, .mover {
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.3s cubic-bezier(0.25, 1, 0.5, 1), border-color 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Specific pricing cards hovers */
#pricing .bg-surface-container-lowest:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px 0 rgba(53, 61, 50, 0.08);
  border-color: rgba(66, 104, 43, 0.3);
}

/* Why Choose cards hovers */
#why-choose .bg-surface-container-lowest:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px 0 rgba(53, 61, 50, 0.06);
  border-color: rgba(66, 104, 43, 0.25);
}

/* How It Works cards hovers */
#how-it-works .bg-surface-container-lowest:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px 0 rgba(53, 61, 50, 0.05);
  border-color: rgba(66, 104, 43, 0.2);
}

/* Button & Link Hover Transitions */
button, a.bg-gradient-to-r, a.bg-surface-container-lowest {
  transition: transform 0.2s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.2s cubic-bezier(0.25, 1, 0.5, 1), background-color 0.2s ease, opacity 0.2s ease;
}

button:hover:not(:disabled), a.bg-gradient-to-r:hover {
  transform: translateY(-1px);
}

button:active:not(:disabled), a.bg-gradient-to-r:active {
  transform: translateY(1px) scale(0.98);
}

/* 6. Custom Mouse Cursor & Muted Shadow */
.custom-cursor-enabled,
.custom-cursor-enabled * {
  cursor: none !important;
}

.custom-cursor-dot {
  width: 6px;
  height: 6px;
  background-color: #42682b; /* primary forest/sage green, visible on light/dark themes */
  border: 1.5px solid rgba(250, 249, 244, 0.95); /* light border for dark theme contrast */
  border-radius: 50%;
  position: fixed;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.15s ease, height 0.15s ease, background-color 0.15s ease;
  will-change: left, top;
}

.custom-cursor-shadow {
  width: 22px;
  height: 22px;
  background-color: rgba(66, 104, 43, 0.2); /* 20% opacity green shadow */
  border-radius: 50%;
  position: fixed;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  filter: blur(0.5px);
  transition: width 0.15s ease, height 0.15s ease, background-color 0.15s ease;
  will-change: left, top;
}

/* Tactile Clickable Hover Effect */
.custom-cursor-dot.cursor-hover {
  width: 4px;
  height: 4px;
  background-color: #2b4c16; /* Muted darker green, less distracting */
}

.custom-cursor-shadow.cursor-hover {
  width: 30px;
  height: 30px;
  background-color: rgba(66, 104, 43, 0.35); /* Expand shadow slightly on clickables */
}

/* Hide if user prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
  .custom-cursor-enabled,
  .custom-cursor-enabled * {
    cursor: auto !important;
  }
  .custom-cursor-dot,
  .custom-cursor-shadow {
    display: none !important;
  }
}

/* BSE Ticker Screen Components override for precompiled Tailwind contrast issues */
.bse-ticker-screen .ticker-title {
  color: #e2e8f0 !important;
  background-color: #12161a !important;
  border: 1px solid #232930 !important;
}

.bse-ticker-screen #market-sim-badge {
  color: #ff9f0a !important;
  background-color: #1a1308 !important;
  border: 1px solid #402d0f !important;
}

.bse-ticker-screen .fade-mask-left {
  background: linear-gradient(to right, #0b0c0e, transparent) !important;
}

.bse-ticker-screen .fade-mask-right {
  background: linear-gradient(to left, #0b0c0e, transparent) !important;
}

/* ── Subscription Cards Enhancements ──────────────────────────────────────── */
.pricing-card {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.pricing-card:hover {
  transform: translateY(-8px) scale(1.01);
}

/* Checkmark spring animation on card hover */
.pricing-card .material-symbols-outlined {
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), color 0.3s ease, filter 0.3s ease;
}

.pricing-card:hover .material-symbols-outlined.text-primary {
  transform: scale(1.25);
  color: #42682b !important;
  filter: drop-shadow(0 0 3px rgba(66, 104, 43, 0.25));
}

/* Card popular ambient glow */
.pricing-card-popular:hover {
  box-shadow: 0 20px 40px -15px rgba(66, 104, 43, 0.18) !important;
}

/* Button micro-animations */
.pricing-card button {
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.2s ease, opacity 0.2s ease, box-shadow 0.2s ease !important;
}

.pricing-card button:hover {
  transform: scale(1.03);
}

.pricing-card button:active {
  transform: scale(0.97);
}

/* Card SVG graphics subtle interactive rotation/scale */
.pricing-card-icon-wrapper {
  transition: background-color 0.3s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

.pricing-card:hover .pricing-card-icon-wrapper {
  background-color: rgba(66, 104, 43, 0.1) !important;
  transform: scale(1.08) translateY(-2px);
}

.pricing-card-icon-wrapper svg {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.pricing-card:hover .pricing-card-icon-wrapper svg {
  transform: rotate(6deg) scale(1.05);
}

/* Accessible Reduced Motion Settings */
@media (prefers-reduced-motion: reduce) {
  .pricing-card:hover {
    transform: none !important;
  }
  .pricing-card button:hover {
    transform: none !important;
  }
  .pricing-card-icon-wrapper {
    transform: none !important;
  }
  .pricing-card:hover .pricing-card-icon-wrapper {
    transform: none !important;
  }
  .pricing-card:hover .pricing-card-icon-wrapper svg {
    transform: none !important;
  }
  .pricing-card:hover .material-symbols-outlined.text-primary {
    transform: none !important;
  }
}


/* ============================================================================
   DARK CINEMATIC · LIQUID GLASS  —  shared project theme
   ----------------------------------------------------------------------------
   Reusable theme layer applied to every page via `body.theme-dark`. It remaps
   the design-system's semantic Tailwind utilities (bg-surface-*, text-on-*,
   border-outline-*, bg-primary, …) into a deep, glassy palette, so any page
   built on those utilities inherits the look with no per-element rewriting.
   The compiled /tailwind.css is left untouched.

   Hooks (add to <body class>):
     .theme-dark   → colors, surfaces, glass, typography (all pages)
     .app-motion   → entrance + scroll-reveal animations (homepage + content pages)
   Backdrop element (place first inside <body>):
     <div class="app-bg"> … </div>          → animated cinematic backdrop
     <div class="app-bg is-calm"> … </div>  → static glow only (dashboard/admin/404)
   Reusable components (§17): .glass-card .btn-primary .btn-ghost .app-eyebrow
   Homepage-only elements (#calls war-room, .glass-hero, compare modal) are still
   matched here, but only exist on index.html so they no-op elsewhere.
   ============================================================================ */

/* ── 1. Design tokens ─────────────────────────────────────────────────────── */
.theme-dark {
  --bg-deep:        #06070a;
  --bg-base:        #0a0c11;
  --bg-elev:        #0f1320;
  --glass:          rgba(255, 255, 255, 0.045);
  --glass-2:        rgba(17, 22, 32, 0.55);
  --glass-3:        rgba(255, 255, 255, 0.022);
  --glass-line:     rgba(255, 255, 255, 0.10);
  --glass-line-2:   rgba(255, 255, 255, 0.18);
  --txt:            #eef1f6;
  --txt-muted:      #a7b2c0;   /* lifted from #9aa6b6 for clearer secondary text on dark */
  --txt-dim:        #8593a3;   /* lifted from #828e9e — labels/captions stay legible */
  /* Refined premium emerald ramp — muted & modern, but readable on the near-black canvas.
     accent  = jade for text / icons / accents (~7:1 on --bg-deep, comfortably AA/AAA)
     accent-2= soft mint for gradient ends, hovers and highlights
     accent-deep = deep forest for solid fills, containers and the ambient glow base.
     Opacity variants of accent below are expressed as rgba(87, 184, 148, …). */
  --accent:         #57b894;
  --accent-2:       #8ad9bc;
  --accent-deep:    #0f4034;
  --accent-soft:    rgba(87, 184, 148, 0.12);
  --accent-glow:    rgba(87, 184, 148, 0.30);
  --violet:         #7c5cff;
  --gold:           #f5b544;
  --red:            #ff5d6c;
  --ease:           cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── 2. Base canvas ───────────────────────────────────────────────────────── */
body.theme-dark {
  background-color: var(--bg-deep);
  color: var(--txt);
}

/* Fixed cinematic backdrop: deep base + slow-drifting light blobs + grid.
   z-index:-1 keeps it above body's own background but beneath all in-flow
   content, so nothing needs per-element z-index. */
.theme-dark .app-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(1100px 700px at 50% -12%, rgba(87, 184, 148, 0.08), transparent 60%),
    radial-gradient(900px 700px at 100% 30%, rgba(34, 92, 96, 0.06), transparent 60%),
    var(--bg-deep);
}
.app-bg .blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(72px);
  opacity: 0.55;
  mix-blend-mode: screen;
  will-change: transform;
}
.app-bg .b1 {
  width: 48vw; height: 48vw; left: -10vw; top: -8vw;
  background: radial-gradient(circle, rgba(87, 184, 148, 0.40), transparent 70%);
  animation: cineDrift1 26s var(--ease) infinite alternate;
}
.app-bg .b2 {
  width: 44vw; height: 44vw; right: -12vw; top: 14vh;
  background: radial-gradient(circle, rgba(40, 104, 104, 0.30), transparent 70%);
  animation: cineDrift2 34s var(--ease) infinite alternate;
}
.app-bg .b3 {
  width: 40vw; height: 40vw; left: 26vw; bottom: -16vh;
  background: radial-gradient(circle, rgba(74, 98, 92, 0.16), transparent 70%);
  animation: cineDrift3 40s var(--ease) infinite alternate;
}
.app-bg .grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(circle at 50% 28%, #000 0%, transparent 72%);
          mask-image: radial-gradient(circle at 50% 28%, #000 0%, transparent 72%);
}
.app-bg .vignette {
  position: absolute; inset: 0;
  background: radial-gradient(125% 85% at 50% 0%, transparent 42%, rgba(0, 0, 0, 0.55) 100%);
}
@keyframes cineDrift1 { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(7vw, 5vh, 0) scale(1.12); } }
@keyframes cineDrift2 { from { transform: translate3d(0,0,0) scale(1.05); } to { transform: translate3d(-6vw, 7vh, 0) scale(0.95); } }
@keyframes cineDrift3 { from { transform: translate3d(0,0,0) scale(0.95); } to { transform: translate3d(5vw, -6vh, 0) scale(1.15); } }

/* ── 3. Liquid-glass system ──────────────────────────────────────────────── */
.theme-dark .glass {
  background: var(--glass);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
          backdrop-filter: blur(20px) saturate(150%);
  border: 1px solid var(--glass-line);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 20px 50px -24px rgba(0, 0, 0, 0.65);
}
.theme-dark .glass-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.025));
  -webkit-backdrop-filter: blur(30px) saturate(165%);
          backdrop-filter: blur(30px) saturate(165%);
  border: 1px solid var(--glass-line-2);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    inset 0 -1px 0 rgba(255, 255, 255, 0.04),
    0 32px 90px -34px rgba(0, 0, 0, 0.8),
    0 0 70px -24px var(--accent-glow);
  animation: glassIn 1.1s var(--ease) both;
}
/* Soft specular sheen sweeping across the hero glass */
.theme-dark .glass-hero::after {
  content: "";
  position: absolute;
  top: -60%; left: -30%;
  width: 60%; height: 220%;
  background: linear-gradient(105deg, transparent, rgba(255, 255, 255, 0.10), transparent);
  transform: rotate(8deg);
  z-index: -1;
  animation: glassSheen 7s var(--ease) 1.2s infinite;
}
@keyframes glassIn  { from { opacity: 0; transform: translateY(40px) scale(0.965); filter: blur(14px); } to { opacity: 1; transform: none; filter: blur(0); } }
@keyframes glassSheen { 0% { left: -40%; } 55%, 100% { left: 130%; } }

/* ── 4. Cinematic entrance (load + scroll) ───────────────────────────────── */
@keyframes heroRise { from { opacity: 0; transform: translateY(26px); filter: blur(8px); } to { opacity: 1; transform: none; filter: blur(0); } }
.app-motion .hero-rise { animation: heroRise 0.95s var(--ease) both; }
.app-motion .hero-d1 { animation-delay: 0.35s; }
.app-motion .hero-d2 { animation-delay: 0.50s; }
.app-motion .hero-d3 { animation-delay: 0.65s; }
.app-motion .hero-d4 { animation-delay: 0.80s; }

.app-motion .scroll-reveal {
  opacity: 0;
  transform: translateY(34px);
  filter: blur(6px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease), filter 0.9s var(--ease);
}
.app-motion .reveal-active {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}
/* If JS is disabled, never hide content */
@media (scripting: none) {
  .app-motion .scroll-reveal,
  .app-motion .hero-rise { opacity: 1 !important; transform: none !important; filter: none !important; animation: none !important; }
}

/* ── 5. Semantic utility remaps (text) ───────────────────────────────────── */
.theme-dark .text-on-surface        { color: var(--txt); }
.theme-dark .text-on-background      { color: var(--txt); }
.theme-dark .text-on-surface-variant { color: var(--txt-muted); }
.theme-dark .text-secondary          { color: var(--txt-muted); }
.theme-dark .text-outline            { color: var(--txt-dim); }
.theme-dark .text-outline\/80        { color: rgba(130, 142, 158, 0.8); }
.theme-dark .text-outline\/70        { color: rgba(130, 142, 158, 0.7); }
.theme-dark .text-outline-variant\/80 { color: rgba(154, 166, 182, 0.55); }
.theme-dark .text-primary            { color: var(--accent); }
.theme-dark .text-primary\/80        { color: rgba(87, 184, 148, 0.85); }
.theme-dark .text-primary-container  { color: #81ded0; }
.theme-dark .text-on-primary         { color: #ffffff; }
.theme-dark .text-on-primary\/80     { color: rgba(255, 255, 255, 0.8); }
.theme-dark .text-on-primary\/70     { color: rgba(255, 255, 255, 0.7); }
.theme-dark .text-error              { color: var(--red); }

/* ── 6. Semantic utility remaps (surfaces) ───────────────────────────────── */
.theme-dark .bg-background           { background-color: var(--bg-deep); }
.theme-dark .bg-surface              { background-color: transparent; }
.theme-dark .bg-surface\/80          { background-color: rgba(8, 10, 14, 0.55); }
.theme-dark .bg-surface\/95          { background-color: rgba(8, 10, 14, 0.85); }
.theme-dark .bg-surface-variant      { background-color: rgba(255, 255, 255, 0.05); }
.theme-dark .bg-surface-dim          { background-color: rgba(0, 0, 0, 0.3); }
.theme-dark .bg-surface-container        { background-color: rgba(255, 255, 255, 0.016); }
.theme-dark .bg-surface-container\/5     { background-color: rgba(255, 255, 255, 0.03); }
.theme-dark .bg-surface-container-low    { background-color: rgba(255, 255, 255, 0.022); }
.theme-dark .bg-surface-container-low\/50,
.theme-dark .bg-surface-container-low\/40,
.theme-dark .bg-surface-container-low\/35,
.theme-dark .bg-surface-container-low\/20 { background-color: rgba(255, 255, 255, 0.03); }
.theme-dark .bg-surface-container-high   { background-color: rgba(255, 255, 255, 0.055); }
.theme-dark .bg-surface-container-high\/60,
.theme-dark .bg-surface-container-high\/40 { background-color: rgba(255, 255, 255, 0.045); }
.theme-dark .bg-surface-container-highest\/90 { background-color: rgba(20, 26, 36, 0.82); }

/* Primary card surface → liquid glass */
.theme-dark .bg-surface-container-lowest {
  background: var(--glass-2);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
          backdrop-filter: blur(16px) saturate(140%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 18px 44px -26px rgba(0, 0, 0, 0.6);
}
.theme-dark .bg-surface-container-lowest:hover {
  border-color: var(--accent);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 26px 60px -28px rgba(0, 0, 0, 0.7),
    0 0 42px -16px var(--accent-glow);
}

/* Accent / brand fills */
.theme-dark .bg-primary            { background-color: var(--accent); }
.theme-dark .bg-primary\/95        { background-color: rgba(87, 184, 148, 0.95); }
.theme-dark .bg-primary\/90        { background-color: rgba(87, 184, 148, 0.9); }
.theme-dark .bg-primary\/20        { background-color: rgba(87, 184, 148, 0.2); }
.theme-dark .bg-primary\/10        { background-color: rgba(87, 184, 148, 0.12); }
.theme-dark .bg-primary\/5         { background-color: rgba(87, 184, 148, 0.07); }
.theme-dark .bg-primary-container  { background-color: var(--accent-deep); }
.theme-dark .bg-secondary\/5       { background-color: rgba(154, 166, 182, 0.06); }
.theme-dark .bg-on-primary\/10     { background-color: rgba(255, 255, 255, 0.1); }
.theme-dark .bg-outline-variant\/30 { background-color: rgba(255, 255, 255, 0.08); }
.theme-dark .bg-on-background\/40  { background-color: rgba(2, 3, 5, 0.62); }
.theme-dark .bg-on-background\/80  { background-color: rgba(2, 3, 5, 0.86); }
.theme-dark .bg-error              { background-color: var(--red); }

/* ── 7. Semantic utility remaps (borders / dividers) ─────────────────────── */
.theme-dark .border-outline-variant      { border-color: rgba(255, 255, 255, 0.12); }
.theme-dark .border-outline-variant\/60  { border-color: rgba(255, 255, 255, 0.14); }
.theme-dark .border-outline-variant\/50  { border-color: rgba(255, 255, 255, 0.12); }
.theme-dark .border-outline-variant\/40  { border-color: rgba(255, 255, 255, 0.10); }
.theme-dark .border-outline-variant\/30  { border-color: rgba(255, 255, 255, 0.08); }
.theme-dark .border-outline-variant\/20  { border-color: rgba(255, 255, 255, 0.06); }
.theme-dark .border-primary              { border-color: var(--accent); }
.theme-dark .border-primary\/20          { border-color: rgba(87, 184, 148, 0.28); }
.theme-dark .border-primary-container     { border-color: rgba(87, 184, 148, 0.4); }
.theme-dark .border-primary-container\/30 { border-color: rgba(87, 184, 148, 0.25); }
.theme-dark .divide-outline-variant\/20 > :not([hidden]) ~ :not([hidden]) { border-color: rgba(255, 255, 255, 0.06); }

/* ── 8. Gradient stops, rings, placeholders, focus ───────────────────────── */
.theme-dark .from-primary { --tw-gradient-from: var(--accent) var(--tw-gradient-from-position); --tw-gradient-to: rgb(87 184 148 / 0) var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.theme-dark .to-primary-container { --tw-gradient-to: var(--accent-2) var(--tw-gradient-to-position); }
.theme-dark .from-surface { --tw-gradient-from: transparent var(--tw-gradient-from-position); --tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.theme-dark .to-background { --tw-gradient-to: transparent var(--tw-gradient-to-position); }
.theme-dark .ring-primary { --tw-ring-color: var(--accent); }
.theme-dark .placeholder\:text-outline::placeholder { color: var(--txt-dim); }
.theme-dark :focus-visible { outline-color: var(--accent); }

/* ── 9. Hardcoded-hex (stats strip) remaps ───────────────────────────────── */
.theme-dark .bg-\[\#f5f4ef\]        { background-color: transparent; }
.theme-dark .border-\[\#c4c8be\]\/60 { border-color: rgba(255, 255, 255, 0.12); }
.theme-dark .border-\[\#c4c8be\]\/40 { border-color: rgba(255, 255, 255, 0.10); }

/* ── 10. Header / nav glass polish ───────────────────────────────────────── */
.theme-dark > header {
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06), 0 10px 34px -16px rgba(0, 0, 0, 0.65);
}

/* ── 11. Glassmorphic Buttons & CTAs (No Green) ─────────────────────────── */
.theme-dark a.bg-primary,
.theme-dark button.bg-primary,
.theme-dark a.bg-primary-container,
.theme-dark button.bg-primary-container,
.theme-dark a.bg-gradient-to-r,
.theme-dark button.bg-gradient-to-r,
.theme-dark a.border-primary,
.theme-dark button.border-primary,
.theme-dark .btn-primary,
.theme-dark .btn-ghost {
  background: rgba(255, 255, 255, 0.07) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.theme-dark a.bg-primary:hover,
.theme-dark button.bg-primary:hover,
.theme-dark a.bg-primary-container:hover,
.theme-dark button.bg-primary-container:hover,
.theme-dark a.bg-gradient-to-r:hover,
.theme-dark button.bg-gradient-to-r:hover,
.theme-dark a.border-primary:hover,
.theme-dark button.border-primary:hover,
.theme-dark .btn-primary:hover,
.theme-dark .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.14) !important;
  border-color: rgba(255, 255, 255, 0.25) !important;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  transform: translateY(-1px) !important;
}

.theme-dark a.bg-primary:active,
.theme-dark button.bg-primary:active,
.theme-dark a.bg-gradient-to-r:active,
.theme-dark button.bg-gradient-to-r:active,
.theme-dark a.border-primary:active,
.theme-dark button.border-primary:active,
.theme-dark .btn-primary:active,
.theme-dark .btn-ghost:active {
  transform: translateY(0.5px) !important;
  background: rgba(255, 255, 255, 0.05) !important;
}

/* ── 12. War-room (#calls) dark theming ──────────────────────────────────── */
.theme-dark #calls {
  --ink2: transparent;
  --edge: rgba(255, 255, 255, 0.10);
  --edge2: rgba(255, 255, 255, 0.06);
  --cream: #eef1f6;
  --cream3: #9aa6b6;
  --cream4: rgba(255, 255, 255, 0.05);
  --emerald: var(--accent);
  --gold2: var(--gold);
  --blood2: var(--red);
  background: transparent !important;
  color: var(--txt) !important;
}
.theme-dark #calls .wr-col {
  background: var(--glass-2);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
          backdrop-filter: blur(16px) saturate(140%);
  border-color: rgba(255, 255, 255, 0.10);
}
.theme-dark #calls .msg-txt { color: rgba(238, 241, 246, 0.85); }
.theme-dark #calls .msg-av,
.theme-dark #calls .ch-cnt { color: #ffffff; }

/* ── 13. Compare-modal selected / sticky theming ─────────────────────────── */
.theme-dark .compare-card-selected {
  background-color: var(--accent-soft) !important;
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 2px var(--accent-glow), 0 8px 24px rgba(0, 0, 0, 0.5);
}
.theme-dark .compare-card-selected .compare-checkbox-indicator,
.theme-dark .top-performer-badge { background-color: var(--accent); color: #ffffff; border-color: var(--accent); }
.theme-dark .compare-sticky-col { background-color: var(--bg-elev); border-right-color: rgba(255, 255, 255, 0.1); }
.theme-dark .top-performer-cell { background-color: var(--accent-soft) !important; border: 1px solid rgba(87, 184, 148, 0.3) !important; }

/* ── 14. Custom cursor → premium magnetic glass cursor ───────────────────── */
html.custom-cursor-enabled,
html.custom-cursor-enabled * {
  cursor: none !important;
}

.custom-cursor-dot {
  position: fixed;
  top: 0;
  left: 0;
  width: 6px;
  height: 6px;
  background-color: #ffffff;
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  transition: opacity 0.3s ease;
  mix-blend-mode: difference;
}

.custom-cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  width: 24px;
  height: 24px;
  border: 1.5px solid rgba(255, 255, 255, 0.45);
  pointer-events: none;
  z-index: 9999;
  box-sizing: border-box;
  transition: opacity 0.3s ease, border-color 0.25s ease, background-color 0.25s ease;
  mix-blend-mode: difference;
}

.custom-cursor-ring.ring-hover {
  border-color: rgba(255, 255, 255, 0.95);
  background-color: rgba(255, 255, 255, 0.12);
}

/* ── 15. Reduced-motion guards for new motion ────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .app-bg .blob { animation: none !important; }
  .theme-dark .glass-hero,
  .theme-dark .glass-hero::after,
  .app-motion .hero-rise { animation: none !important; }
  .theme-dark .glass-hero { opacity: 1 !important; transform: none !important; filter: none !important; }
  .app-motion .scroll-reveal { opacity: 1 !important; transform: none !important; filter: none !important; }
}

/* Logo Corner responsiveness */
.logo-corner {
  display: none !important;
}
@media (min-width: 480px) {
  .logo-corner {
    display: flex !important;
  }
}

/* ── 16. Top capsule nav: one-line labels; icon-only on compact mobile ─────── */
/* Only matches the floating capsule (a <nav> nested in a <header>), not the     */
/* dashboard/admin sidebar navs. Keeps the 5-item navbar from wrapping/clipping. */
header nav a,
header nav button {
  white-space: nowrap;
  flex-shrink: 0; /* never let tablet crowding compress items into wrapping */
}
@media (max-width: 479px) {
  header nav a span:not(.material-symbols-outlined) {
    display: none;
  }
}

/* iOS 26 Glassmorphism Capsule Navbar & General Glass */
.ios-glass {
  background-color: rgba(6, 7, 10, 0.75) !important;
  -webkit-backdrop-filter: blur(24px) saturate(180%) !important;
          backdrop-filter: blur(24px) saturate(180%) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 12px 40px -10px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
}

#mobile-fullscreen-menu {
  background-color: rgba(6, 7, 10, 0.88) !important;
  -webkit-backdrop-filter: blur(24px) saturate(180%) !important;
          backdrop-filter: blur(24px) saturate(180%) !important;
}

header.ios-glass {
  background-color: rgba(6, 7, 10, 0.45) !important;
  position: absolute !important;
  left: 16px !important;
  right: 16px !important;
  width: auto !important;
  transform: none !important;
}

@media (min-width: 768px) {
  header.ios-glass {
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) !important;
    width: auto !important;
  }
}

header.ios-glass nav a {
  position: relative;
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  border: 1px solid transparent;
}

/* Active tab style - premium white glass */
header.ios-glass nav a.active {
  background-color: rgba(255, 255, 255, 0.12) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.15) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.2);
}

/* Inactive tabs hover with glass switching effect */
header.ios-glass nav a:not(.active):hover {
  background-color: rgba(255, 255, 255, 0.06) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.05) !important;
  transform: translateY(-1px);
}

/* Active tab hover effect */
header.ios-glass nav a.active:hover {
  background-color: rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}








/* ── 17. Reusable theme components (shared across every page) ─────────────── */
/* Calm backdrop variant: static glow only, no drifting blobs (dashboard/admin/404). */
.app-bg.is-calm .blob { animation: none !important; opacity: 0.16; }
.app-bg.is-calm .grid { opacity: 0.5; }

/* Liquid-glass card surface (supplements the bg-surface-container-lowest remap). */
.theme-dark .glass-card {
  background: var(--glass-2);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
          backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid var(--glass-line);
  border-radius: 1rem;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 18px 44px -26px rgba(0,0,0,0.6);
}

/* Brand buttons styled as glassmorphic in Section 11. */

/* Section eyebrow / pill label. */
.theme-dark .app-eyebrow {
  display: inline-flex; align-items: center; gap: .375rem;
  font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent); background: var(--accent-soft);
  border: 1px solid rgba(87, 184, 148, 0.22); padding: .25rem .75rem; border-radius: 999px;
}

/* ── 18. Amber/warning callouts → dark-glass gold (e.g. legal compliance notices)
   Star ratings use text-amber-500 and are intentionally left gold. ─────────── */
.theme-dark .bg-amber-50          { background-color: rgba(245, 181, 68, 0.10); }
.theme-dark .border-amber-300\/60 { border-color: rgba(245, 181, 68, 0.35); }
.theme-dark .border-amber-300     { border-color: rgba(245, 181, 68, 0.35); }
.theme-dark .text-amber-900       { color: #f3d39b; }
.theme-dark .text-amber-800       { color: #f0c674; }

/* ── 19. Leaderboard Countdown Flip Cards ────────────────────────────────── */
.flip-card {
  position: relative;
  width: 5rem;
  height: 6rem;
  perspective: 400px;
}
@media (min-width: 640px) {
  .flip-card {
    width: 7rem;
    height: 8rem;
    perspective: 600px;
  }
}

.card-panel {
  position: absolute;
  left: 0;
  width: 100%;
  height: 50%;
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  background: var(--glass-2);
  border: 1.5px solid var(--glass-line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.card-panel-top {
  top: 0;
  border-top-left-radius: 1rem;
  border-top-right-radius: 1rem;
  border-bottom: 0.5px solid rgba(0, 0, 0, 0.4);
  transform-origin: bottom center;
}

.card-panel-bottom {
  bottom: 0;
  border-bottom-left-radius: 1rem;
  border-bottom-right-radius: 1rem;
  border-top: 0.5px solid rgba(0, 0, 0, 0.4);
  transform-origin: top center;
}

.card-digit {
  position: absolute;
  left: 50%;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--accent);
  text-shadow: 0 0 12px var(--accent-glow);
  letter-spacing: -0.05em;
}
@media (min-width: 640px) {
  .card-digit {
    font-size: 4.5rem;
  }
}

.card-panel-top .card-digit {
  bottom: 0;
  transform: translate(-50%, 50%);
}

.card-panel-bottom .card-digit {
  top: 0;
  transform: translate(-50%, -50%);
}

.card-divider {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 2px;
  background-color: rgba(0, 0, 0, 0.95);
  box-shadow: 0 0.5px 0 rgba(255, 255, 255, 0.08);
  z-index: 10;
}

/* Static vs Animating Z-indexes */
.panel-static-top { z-index: 1; }
.panel-static-bottom { z-index: 1; }
.panel-flip-top { z-index: 3; transform: rotateX(0deg); }
.panel-flip-bottom { z-index: 2; transform: rotateX(90deg); }

/* Animation trigger classes */
.flip-card.flipping .panel-flip-top {
  animation: flip-top-anim 0.55s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.flip-card.flipping .panel-flip-bottom {
  animation: flip-bottom-anim 0.55s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes flip-top-anim {
  0% {
    transform: rotateX(0deg);
  }
  50%, 100% {
    transform: rotateX(-90deg);
  }
}

@keyframes flip-bottom-anim {
  0%, 50% {
    transform: rotateX(90deg);
  }
  100% {
    transform: rotateX(0deg);
  }
}

/* ── 20. Strategy Selector Flipping Text Animation ────────────────────────── */
.strategy-flip-text {
  display: inline-block;
  opacity: 1;
  transform: translateY(0);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
}

.strategy-flip-text.flip-out {
  transform: translateY(-100%);
  opacity: 0;
}

.strategy-flip-text.flip-in {
  transform: translateY(100%);
  opacity: 0;
  transition: none;
}

/* ── 21. Sticky Navbar & Ticker Screen Scroll Alignment ─────────────────── */
:root {
  --nav-height: 64px;
  --nav-top: 16px;
}

body.scrolled {
  --nav-top: 64px; /* Position navbar below the 64px sticky ticker strip */
}

.nav-wrapper {
  transition: top 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
  top: var(--nav-top) !important;
}

.bse-ticker-screen {
  position: -webkit-sticky;
  position: sticky !important;
  top: 0px !important; /* Stick at the very top of the viewport */
  transition: top 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
  z-index: 45 !important;
}

/* ── 22. Logo Size Constraints ────────────────────────────────── */
.preloader-logo-container {
  width: 280px !important;
  height: 280px !important;
  margin-top: -70px !important;
  margin-bottom: -40px !important;
}

.navbar-logo-container {
  width: 140px !important;
  height: 140px !important;
  margin-top: -42px !important;
  margin-bottom: -42px !important;
}

.footer-logo-container {
  width: 180px !important;
  height: 180px !important;
  margin-top: -50px !important;
  margin-bottom: -50px !important;
}

.mobile-logo-container {
  width: 100px !important;
  height: 100px !important;
  margin-top: -30px !important;
  margin-bottom: -30px !important;
}

/* Testimonials Slider on Mobile */
.testimonials-slider {
  display: flex !important;
  flex-direction: row !important;
  overflow-x: auto !important;
  scroll-snap-type: x mandatory !important;
  gap: 16px !important;
  padding-bottom: 16px !important;
  margin-left: -16px !important;
  margin-right: -16px !important;
  padding-left: 16px !important;
  padding-right: 16px !important;
  scrollbar-width: none; /* Firefox */
}

.testimonials-slider::-webkit-scrollbar {
  display: none; /* Safari and Chrome */
}

.testimonial-card {
  width: 290px !important;
  flex-shrink: 0 !important;
  scroll-snap-align: start !important;
}

@media (min-width: 768px) {
  .testimonials-slider {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 32px !important;
    overflow-x: visible !important;
    scroll-snap-type: none !important;
    padding-bottom: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  
  .testimonial-card {
    width: auto !important;
    flex-shrink: 1 !important;
  }
}

/* Feedback Widget custom layout and dropdown colors */
.feedback-widget-card {
  background-color: var(--color-surface-container-lowest, #0b0d12) !important;
  border: 1px solid rgba(156, 175, 145, 0.2) !important;
  border-radius: 16px !important;
  padding: 20px !important;
  margin-bottom: 24px !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15) !important;
  transition: all 0.3s ease !important;
  width: 100% !important;
}

.feedback-widget-flex {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px !important;
  width: 100% !important;
}

.feedback-widget-info {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 16px !important;
  width: 100% !important;
}

.feedback-widget-icon {
  width: 40px !important;
  height: 40px !important;
  border-radius: 12px !important;
  background-color: rgba(156, 175, 145, 0.1) !important;
  border: 1px solid rgba(156, 175, 145, 0.2) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: #9caf91 !important;
  flex-shrink: 0 !important;
}

.feedback-widget-text {
  flex-grow: 1 !important;
  min-width: 0 !important;
  text-align: center !important;
  width: 100% !important;
}

.feedback-widget-text h4 {
  font-size: 13px !important;
  font-weight: 700 !important;
  color: #ffffff !important;
  margin: 0 0 4px 0 !important;
}

.feedback-widget-text p {
  font-size: 11px !important;
  color: #a3a3a3 !important;
  line-height: 1.5 !important;
  margin: 0 !important;
}

.feedback-widget-btn-container {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  flex-shrink: 0 !important;
}

#feedback-category {
  background-color: #111318 !important;
  color: #ffffff !important;
  border: 1px solid rgba(156, 175, 145, 0.3) !important;
}

#feedback-category option {
  background-color: #111318 !important;
  color: #ffffff !important;
}

@media (min-width: 768px) {
  .feedback-widget-flex {
    flex-direction: row !important;
    gap: 24px !important;
  }

  .feedback-widget-info {
    flex-direction: row !important;
    text-align: left !important;
    align-items: center !important;
    width: auto !important;
  }

  .feedback-widget-text {
    text-align: left !important;
    width: auto !important;
  }

  .feedback-widget-btn-container {
    width: auto !important;
    justify-content: flex-end !important;
  }
}

/* Pricing Slider on Mobile Viewports */
.pricing-slider {
  display: flex !important;
  flex-direction: row !important;
  overflow-x: auto !important;
  scroll-snap-type: x mandatory !important;
  gap: 16px !important;
  padding-bottom: 20px !important;
  margin-left: -16px !important;
  margin-right: -16px !important;
  padding-left: 16px !important;
  padding-right: 16px !important;
  scrollbar-width: none; /* Firefox */
}

.pricing-slider::-webkit-scrollbar {
  display: none; /* Safari and Chrome */
}

.pricing-slider-card {
  width: 295px !important;
  flex-shrink: 0 !important;
  scroll-snap-align: start !important;
}

@media (min-width: 768px) {
  .pricing-slider {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 32px !important;
    overflow-x: visible !important;
    scroll-snap-type: none !important;
    padding-bottom: 0 !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  
  .pricing-slider-card {
    width: auto !important;
    flex-shrink: 1 !important;
  }
}

/* ============================================================================
   23. PREMIUM GREEN REFINEMENT — readability, typography & hierarchy
   ----------------------------------------------------------------------------
   Builds on the refined emerald tokens (§1). Three concerns, in order:
   (a) Typography — make the gradient hero text legible and balance headings.
   (b) Layout — tighten the hero's vertical rhythm and lift decorative accents.
   (c) Hierarchy — give the primary CTA an on-brand emerald-glass identity that
       is clearly distinct from neutral/ghost actions, without a loud fill.
   Scoped to .theme-dark so light surfaces (dashboard/admin) are untouched.
   ============================================================================ */

/* (a) Typography ─────────────────────────────────────────────────────────── */
/* Gradient hero word ("Verified Traders."): both stops are now readable jade →
   mint, so the whole phrase stays legible end-to-end. Heavier weight + a faint
   emerald drop-shadow give it presence on the glass without raising saturation. */
.theme-dark .glass-hero h1 .bg-clip-text {
  font-weight: 800;
  letter-spacing: -0.015em;
  filter: drop-shadow(0 1px 10px rgba(87, 184, 148, 0.22));
}

/* Balanced, even line breaks for the headline; calmer tracking for the measure. */
.theme-dark .glass-hero h1 {
  text-wrap: balance;
  letter-spacing: -0.02em;
}

/* Subhead: comfortable measure + line-height for readability (not too dim). */
.theme-dark .glass-hero p {
  text-wrap: pretty;
  line-height: 1.65;
}

/* (b) Layout & decorative accents ────────────────────────────────────────── */
/* The scroll-progress line used the deep-forest container token (near-invisible
   on dark). Use the brighter mint so the cue actually reads. */
.theme-dark .animate-scroll-line {
  background-color: var(--accent-2) !important;
  box-shadow: 0 0 8px rgba(87, 184, 148, 0.45);
}

/* (c) Primary CTA — emerald liquid-glass (overrides the neutral glass in §11) ─
   Appears later in the cascade than §11, so it wins for primary actions while
   ghost/secondary buttons keep the neutral treatment. Subtle tint + soft brand
   glow rather than a saturated fill, per the muted-premium direction. */
.theme-dark a.bg-primary,
.theme-dark button.bg-primary,
.theme-dark a.bg-gradient-to-r,
.theme-dark button.bg-gradient-to-r,
.theme-dark .btn-primary {
  background: linear-gradient(180deg, rgba(87, 184, 148, 0.18), rgba(87, 184, 148, 0.08)) !important;
  color: #ecfff7 !important;
  border: 1px solid rgba(138, 217, 188, 0.32) !important;
  box-shadow:
    0 10px 34px -12px rgba(15, 64, 52, 0.65),
    inset 0 1px 0 rgba(255, 255, 255, 0.10),
    0 0 26px -14px var(--accent-glow) !important;
}

.theme-dark a.bg-primary:hover,
.theme-dark button.bg-primary:hover,
.theme-dark a.bg-gradient-to-r:hover,
.theme-dark button.bg-gradient-to-r:hover,
.theme-dark .btn-primary:hover {
  background: linear-gradient(180deg, rgba(87, 184, 148, 0.26), rgba(87, 184, 148, 0.13)) !important;
  border-color: rgba(138, 217, 188, 0.48) !important;
  box-shadow:
    0 16px 44px -12px rgba(15, 64, 52, 0.7),
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 0 34px -10px var(--accent-glow) !important;
  transform: translateY(-1px) !important;
}

.theme-dark a.bg-primary:active,
.theme-dark button.bg-primary:active,
.theme-dark a.bg-gradient-to-r:active,
.theme-dark button.bg-gradient-to-r:active,
.theme-dark .btn-primary:active {
  transform: translateY(0.5px) !important;
  background: linear-gradient(180deg, rgba(87, 184, 148, 0.14), rgba(87, 184, 148, 0.07)) !important;
}

/* Primary CTA icon inherits the brighter mint for a crisp, on-brand accent. */
.theme-dark a.bg-primary .material-symbols-outlined,
.theme-dark button.bg-primary .material-symbols-outlined {
  color: #ecfff7;
}

/* Reduced-motion: drop the CTA lift. */
@media (prefers-reduced-motion: reduce) {
  .theme-dark a.bg-primary:hover,
  .theme-dark button.bg-primary:hover,
  .theme-dark a.bg-gradient-to-r:hover,
  .theme-dark button.bg-gradient-to-r:hover,
  .theme-dark .btn-primary:hover { transform: none !important; }
}

/* ── 24. Mobile Navbar Hamburger Toggle & Full-screen Overlay ──── */
#mobile-menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 14px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
}
@media (max-width: 767px) {
  #mobile-menu-toggle {
    display: flex;
  }
}
#mobile-menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: #ffffff;
  border-radius: 9px;
  transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.3s ease;
}
#mobile-menu-toggle.is-active .bar-1 {
  transform: translateY(6px) rotate(45deg);
}
#mobile-menu-toggle.is-active .bar-2 {
  opacity: 0;
}
#mobile-menu-toggle.is-active .bar-3 {
  transform: translateY(-6px) rotate(-45deg);
}

/* Full-screen Overlay Menu styling */
#mobile-fullscreen-menu {
  opacity: 0;
  transition: opacity 0.4s cubic-bezier(0.25, 1, 0.5, 1);
  pointer-events: none;
}
#mobile-fullscreen-menu.is-active {
  opacity: 1;
  pointer-events: auto;
}
#mobile-fullscreen-menu.is-closing {
  opacity: 0;
  pointer-events: none;
}

/* Link transitions and stagger delay inside full-screen menu */
#mobile-fullscreen-menu .nav-item {
  transform: translateY(30px);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.5s ease;
}
#mobile-fullscreen-menu.is-active .nav-item {
  transform: translateY(0);
  opacity: 1;
}

/* Stagger delays for menu items + CTA */
#mobile-fullscreen-menu.is-active .nav-item:nth-child(1) { transition-delay: 0.1s; }
#mobile-fullscreen-menu.is-active .nav-item:nth-child(2) { transition-delay: 0.15s; }
#mobile-fullscreen-menu.is-active .nav-item:nth-child(3) { transition-delay: 0.20s; }
#mobile-fullscreen-menu.is-active .nav-item:nth-child(4) { transition-delay: 0.25s; }
#mobile-fullscreen-menu.is-active .nav-item:nth-child(5) { transition-delay: 0.30s; }
#mobile-fullscreen-menu.is-active #mobile-overlay-cta {
  transform: translateY(30px);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1) 0.35s, opacity 0.5s ease 0.35s;
}
#mobile-fullscreen-menu.is-active #mobile-overlay-cta {
  transform: translateY(0);
  opacity: 1;
}

/* Redesigned Notification / Live News Bell Animations */
@keyframes custom-bell-ring {
  0% { transform: rotate(0); }
  5% { transform: rotate(15deg); }
  10% { transform: rotate(-15deg); }
  15% { transform: rotate(10deg); }
  20% { transform: rotate(-10deg); }
  25% { transform: rotate(5deg); }
  30% { transform: rotate(-5deg); }
  35% { transform: rotate(0); }
  100% { transform: rotate(0); }
}

.animate-bell-ring {
  animation: custom-bell-ring 2s ease-in-out infinite;
  transform-origin: top center;
  display: inline-block;
}

/* Redesigned Notification Bell Positioning and Styling */
#live-news-trigger {
  position: fixed !important;
  left: 24px !important;
  bottom: 24px !important;
  z-index: 40 !important;
}

#live-news-trigger button {
  position: relative !important;
  width: 48px !important;
  height: 48px !important;
  border-radius: 9999px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* Dynamic bottom transitions for bottom floaters on mobile viewports */
#live-news-trigger, #discord-bot-widget {
  transition: bottom 0.3s cubic-bezier(0.25, 1, 0.5, 1) !important;
}

@media (max-width: 639px) {
  body.mobile-cta-active #live-news-trigger {
    bottom: 80px !important;
  }
  body.mobile-cta-active #discord-bot-widget {
    bottom: 80px !important;
  }
}
