/* ==========================================================================
   RISERS COMMUNITY - STYLING SPECIFICATION (GLASSMORPHIC & VELVET GOLD THEME)
   ========================================================================== */

/* === Google Fonts === */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;600;700;800;900&family=Inter:wght@300;400;500;600;700;800&display=swap');

/* === Theme Variables === */
:root {
  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-display: "Cinzel", Georgia, serif;
  --font-accent: "Cinzel", Georgia, serif;
  
  --color-bg: #060608;
  --color-accent: #f59e0b; /* Amber 500 */
  --color-accent-hover: #d97706; /* Amber 600 */
  --color-gold: #d4af37; /* Gold */
  
  --glass-bg: rgba(13, 13, 17, 0.7);
  --glass-bg-hover: rgba(17, 17, 22, 0.85);
  --glass-border: rgba(255, 255, 255, 0.05);
  --glass-border-hover: rgba(212, 175, 55, 0.3);
  
  --text-primary: rgba(248, 250, 252, 0.95);
  --text-secondary: rgba(148, 163, 184, 0.8);
  --text-muted: rgba(100, 116, 139, 0.6);
  
  --transition-smooth: cubic-bezier(0.25, 1, 0.5, 1);
}

/* === Base Resets === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  width: 100%;
  min-height: 100vh;
  background-color: var(--color-bg);
  color: var(--text-primary);
  font-family: var(--font-sans);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Custom Selection */
::selection {
  background-color: var(--color-accent);
  color: #000000;
}

/* Standard cursor restored for professional usability and responsiveness */

/* === Typography Helpers === */
.title-display {
  font-family: var(--font-display);
  letter-spacing: 0.08em;
}

.accent-display {
  font-family: var(--font-accent);
  letter-spacing: 0.1em;
}

/* === Premium Scrollbar === */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg);
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  transition: background 0.3s;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-gold);
}

/* === Ambient Velvet Glow === */
@keyframes ambientGlow {
  0%, 100% {
    opacity: 0.12;
    transform: scale(1) translate(-50%, -50%);
  }
  50% {
    opacity: 0.22;
    transform: scale(1.08) translate(-48%, -52%);
  }
}

.velvet-glow {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 700px;
  height: 500px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.15) 0%, transparent 70%);
  filter: blur(140px);
  pointer-events: none;
  z-index: 0;
  animation: ambientGlow 10s infinite ease-in-out;
}

/* === Cinematic Splash Loader === */
#loader {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  background-color: #050507;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.8s cubic-bezier(0.25, 1, 0.5, 1), visibility 0.8s;
  overflow: hidden;
}

.loader-bg-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.08) 0%, transparent 65%);
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  animation: loaderPulse 3s infinite alternate ease-in-out;
}

.splash-content {
  text-align: center;
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.logo-wrapper {
  position: relative;
  margin-bottom: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.loader-logo {
  width: 96px;
  height: auto;
  z-index: 2;
  filter: drop-shadow(0 0 25px rgba(212, 175, 55, 0.25));
  animation: loaderFloat 4s ease-in-out infinite;
}

.logo-halo {
  position: absolute;
  top: -12px;
  left: -12px;
  right: -12px;
  bottom: -12px;
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-radius: 50%;
  animation: haloSpin 8s linear infinite;
  pointer-events: none;
}

.loader-title {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--text-primary);
  text-transform: uppercase;
  animation: cinematicTitle 2.2s ease-out forwards;
  text-shadow: 0 0 35px rgba(255, 255, 255, 0.15);
}

.loader-status-text {
  margin-top: 0.85rem;
  margin-bottom: 1.5rem;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--color-accent);
  opacity: 0.8;
  height: 15px; /* Prevent reflow height shifts */
  font-family: monospace;
}

.loader-progress-container {
  width: 220px;
  height: 1px;
  background: rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
  border-radius: 1px;
}

.loader-progress-bar {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 0%;
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.5), var(--color-accent));
  box-shadow: 0 0 8px var(--color-accent);
  animation: fillLoaderProgress 2.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes loaderPulse {
  0% { transform: translate(-50%, -50%) scale(0.9); opacity: 0.5; }
  100% { transform: translate(-50%, -50%) scale(1.1); opacity: 1; }
}

@keyframes loaderFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

@keyframes haloSpin {
  0% { transform: rotate(0deg); border-color: rgba(212, 175, 55, 0.15); }
  50% { border-color: rgba(245, 158, 11, 0.35); }
  100% { transform: rotate(360deg); border-color: rgba(212, 175, 55, 0.15); }
}

@keyframes cinematicTitle {
  0% { letter-spacing: 0.1em; opacity: 0; filter: blur(4px); }
  45% { opacity: 0.85; filter: blur(0); }
  100% { letter-spacing: 0.45em; opacity: 1; }
}

@keyframes fillLoaderProgress {
  to { width: 100%; }
}

/* === Panel Routing === */
.panel-section {
  display: none !important;
  opacity: 0;
}
.panel-section.active {
  display: block !important;
  opacity: 1;
}
#home-panel.active {
  display: flex !important;
}

/* === Premium Glass Panels === */
.glass-panel {
  background-color: var(--glass-bg);
  border: 1px solid var(--glass-border);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.glass-panel-hover {
  transition: all 0.35s var(--transition-smooth);
}

.glass-panel-hover:hover {
  background-color: var(--glass-bg-hover);
  border-color: var(--glass-border-hover);
  box-shadow: 0 12px 40px -10px rgba(0, 0, 0, 0.8);
  transform: translateY(-2px);
}

/* === Custom Cursor Follower (Professional gold ring) === */
#custom-cursor {
  display: none;
  position: fixed;
  width: 20px;
  height: 20px;
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 50%;
  pointer-events: none;
  transform: translate(-50%, -50%);
  z-index: 10000;
  transition: width 0.2s var(--transition-smooth), 
              height 0.2s var(--transition-smooth), 
              border-color 0.2s ease, 
              background-color 0.2s ease;
}

#custom-cursor.hovering {
  width: 32px;
  height: 32px;
  border-color: var(--color-accent);
  background-color: rgba(245, 158, 11, 0.05);
}

#custom-cursor.active {
  width: 14px;
  height: 14px;
  border-color: var(--color-gold);
  background-color: rgba(212, 175, 55, 0.15);
}

.mouse-trail {
  position: fixed;
  width: 4px;
  height: 4px;
  background: rgba(245, 158, 11, 0.4);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  animation: fadeTrail 0.5s ease-out forwards;
}

@keyframes fadeTrail {
  0% {
    opacity: 0.6;
    transform: translate(-50%, -50%) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0);
  }
}

/* === Bouncing Visualizer Bars === */
@keyframes audioBounce {
  0% { transform: scaleY(0.2); }
  100% { transform: scaleY(1); }
}

.visualizer-bar {
  transform: scaleY(0.2);
  transform-origin: bottom;
}

.playing .visualizer-bar {
  animation: audioBounce 0.5s ease-in-out infinite alternate;
}

/* === 3D Flip Card === */
.flip-card {
  perspective: 1000px;
}

.flip-card-inner {
  transition: transform 0.7s cubic-bezier(0.25, 1, 0.5, 1);
  transform-style: preserve-3d;
}

/* Hover or manual class rotation */
.flip-card:hover .flip-card-inner,
.flip-card.flipped .flip-card-inner,
.flip-card-inner.rotateY-180 {
  transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.flip-card-back {
  transform: rotateY(180deg);
}

/* === Hero Background Slideshow === */
.hero-bg {
  position: absolute;
  inset: 0;
  background-position: center;
  background-size: cover;
  z-index: -3;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
  transform: scale(1);
}

.hero-bg.active {
  opacity: 0.25; /* Subtle opacity so overlay content stands out */
}

.hero-bg.zoom-in {
  animation: bgZoomIn 8s ease-out forwards;
}

.hero-bg.zoom-out {
  animation: bgZoomOut 8s ease-out forwards;
}

.hero-bg.pan-left {
  animation: bgPanLeft 8s ease-out forwards;
}

.hero-bg.pan-right {
  animation: bgPanRight 8s ease-out forwards;
}

@keyframes bgZoomIn {
  from { transform: scale(1); }
  to { transform: scale(1.1); }
}

@keyframes bgZoomOut {
  from { transform: scale(1.1); }
  to { transform: scale(1); }
}

@keyframes bgPanLeft {
  from { transform: scale(1.1) translateX(0); }
  to { transform: scale(1.1) translateX(-3%); }
}

@keyframes bgPanRight {
  from { transform: scale(1.1) translateX(-3%); }
  to { transform: scale(1.1) translateX(0); }
}

/* === Particles JS Layer === */
#particles-js {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}