/* ==========================================================================
   RS-ENERGIE - Professional Design System & UI Enhancements
   Anthracite Dark Corporate Theme (WCAG AAA Compliant)
   ========================================================================== */

:root {
  --color-bg-base: #0b0e11;
  --color-surface-card: #14181d;
  --color-surface-elevated: #1a2027;
  --color-surface-hover: #222a33;
  --color-border-subtle: rgba(255, 255, 255, 0.1);
  --color-border-medium: rgba(255, 255, 255, 0.2);
  --color-border-glow: rgba(34, 197, 94, 0.45);
  --color-primary: #10b981;
  --color-primary-hover: #059669;
  --color-primary-accent: #22c55e;
  --color-primary-bright: #4ade80;
  --color-primary-glow: rgba(16, 185, 129, 0.35);
  --color-text-bright: #ffffff;
  --color-text-medium: #f8fafc;
  --color-text-muted: #94a3b8;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5.5rem;
}

body {
  background-color: var(--color-bg-base);
  color: var(--color-text-medium);
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Selection Color */
::selection {
  background: rgba(34, 197, 94, 0.35);
  color: #ffffff;
}

/* Glassmorphism Header */
.glass-nav {
  background: rgba(18, 18, 18, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--color-border-subtle);
}

/* Glass Cards */
.glass-card {
  background: linear-gradient(180deg, rgba(22, 27, 33, 0.88) 0%, rgba(13, 16, 20, 0.94) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--color-border-subtle);
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), 
              border-color 0.3s ease, 
              box-shadow 0.3s ease;
  will-change: transform, box-shadow;
}

.glass-card:hover {
  transform: translate3d(0, -6px, 0);
  border-color: rgba(34, 197, 94, 0.5);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.7), 
              0 0 25px 0 rgba(34, 197, 94, 0.25);
}

/* Shimmer Button Effect */
.btn-shimmer {
  position: relative;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-shimmer::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.25) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: skewX(-20deg);
}

.btn-shimmer:hover::after {
  animation: shimmer 1.2s infinite;
}

@keyframes shimmer {
  0% { left: -100%; }
  100% { left: 200%; }
}

/* Gradient Text for Headings */
.text-gradient-green {
  background: linear-gradient(135deg, #ffffff 40%, #86efac 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-gradient-primary {
  background: linear-gradient(135deg, #10b981 0%, #22c55e 50%, #86efac 100%); filter: drop-shadow(0 2px 10px rgba(34, 197, 94, 0.35));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

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

.reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Floating WhatsApp Button & Pulse */
.floating-whatsapp {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  background-color: #25d366;
  color: #ffffff;
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.4);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease;
}

.floating-whatsapp:hover {
  transform: scale(1.08) translateY(-2px);
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.6);
}

.floating-whatsapp::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid #25d366;
  opacity: 0.75;
  animation: pulse-ring 2s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.25); opacity: 0; }
  100% { transform: scale(1.25); opacity: 0; }
}

/* Mobile Navigation Drawer */
.mobile-nav-backdrop {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-nav-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}

.mobile-nav-drawer {
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-nav-drawer.is-open {
  transform: translateX(0);
}

/* Toast Notifications */
#toast-notification {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  max-width: 420px;
  transform: translateY(-50px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

#toast-notification.show {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* Custom Accordion Chevron */
details summary::-webkit-details-marker {
  display: none;
}
details summary {
  list-style: none;
}
details[open] .faq-icon {
  transform: rotate(180deg);
}

/* ==================== PARTNER FLOW MARQUEE BANNER ==================== */
.partner-flow {
  --ink: #0f172a;
  --muted: #475569;
  --line: rgba(226, 232, 240, 0.9);
  box-sizing: border-box;
  overflow: hidden;
  background: linear-gradient(135deg, #f8fafc 0%, #ffffff 50%, #f1f5f9 100%);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: clamp(28px, 4vw, 48px) 0;
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.1);
  font-family: 'Montserrat', sans-serif;
  color: var(--ink);
}

.partner-flow * {
  box-sizing: border-box;
}

.partner-flow__intro {
  padding: 0 clamp(20px, 5vw, 64px) 28px;
  text-align: center;
}

.partner-flow__intro .eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  color: #16a34a;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.partner-flow h2 {
  margin: 0;
  font-size: clamp(24px, 3.2vw, 36px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: #0f172a;
}

.partner-flow p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
  font-weight: 500;
}

.flows {
  display: grid;
  gap: 16px;
}

.marquee {
  position: relative;
  display: flex;
  overflow: hidden;
  isolation: isolate;
  mask-image: linear-gradient(to right, transparent 0%, #000 8%, #000 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 8%, #000 92%, transparent 100%);
}

.track {
  display: flex;
  width: max-content;
  will-change: transform;
  transform: translate3d(0, 0, 0);
  backface-visibility: hidden;
}

.row-private .track {
  animation: flow-left 72s linear infinite;
}

.row-business .track {
  animation: flow-right 64s linear infinite;
}

.logo-set {
  display: flex;
  align-items: center;
  gap: clamp(40px, 5.5vw, 84px);
  padding-right: clamp(40px, 5.5vw, 84px);
}

.logo {
  width: 145px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.logo img {
  display: block;
  max-height: 44px;
  max-width: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(15, 23, 42, 0.06));
  opacity: 0.95;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.business-logo {
  width: 152px;
  height: 60px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.12);
}

.business-logo img {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
  opacity: 1;
  filter: none;
}

.marquee:hover .track {
  animation-play-state: paused;
}

.marquee:hover .logo img {
  opacity: 1;
  transform: scale(1.05);
}

@keyframes flow-left {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-50%, 0, 0); }
}

@keyframes flow-right {
  0% { transform: translate3d(-50%, 0, 0); }
  100% { transform: translate3d(0, 0, 0); }
}

@media (max-width: 640px) {
  .partner-flow {
    border-radius: 16px;
    padding: 24px 0;
  }
  .partner-flow__intro {
    padding: 0 16px 20px;
  }
  .partner-flow p {
    font-size: 13.5px;
  }
  .flows {
    gap: 12px;
  }
  .logo-set {
    gap: 36px;
    padding-right: 36px;
  }
  .logo {
    width: 110px;
    height: 46px;
  }
  .logo img {
    max-height: 32px;
  }
  .business-logo {
    width: 116px;
    height: 46px;
  }
  .row-private .track {
    animation-duration: 56s;
  }
  .row-business .track {
    animation-duration: 50s;
  }
}

/* Reduced Motion */
@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;
  }
  .reveal-on-scroll {
    opacity: 1 !important;
    transform: none !important;
  }
  .row-private .track,
  .row-business .track {
    animation: none;
    transform: none;
  }
  .logo-set[aria-hidden="true"] {
    display: none;
  }
}


/* ==========================================================================
   ENHANCED 60FPS ANIMATIONS & MOTION SYSTEM
   ========================================================================== */

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translate3d(0, 24px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes floatSkyline {
  0%, 100% { transform: scale(1.04) translate3d(0, 0, 0); }
  50% { transform: scale(1.07) translate3d(0, -8px, 0); }
}

.animate-fade-in-up {
  animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  will-change: transform, opacity;
}

.delay-100 { animation-delay: 0.12s; }
.delay-200 { animation-delay: 0.24s; }
.delay-300 { animation-delay: 0.36s; }

/* Scroll Reveal */
.reveal-on-scroll {
  opacity: 0;
  transform: translate3d(0, 28px, 0);
  transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

/* Glass Card Elevation */
.glass-card {
  background: linear-gradient(180deg, rgba(22, 27, 33, 0.88) 0%, rgba(13, 16, 20, 0.94) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--color-border-subtle);
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), 
              border-color 0.3s ease, 
              box-shadow 0.3s ease;
  will-change: transform, box-shadow;
}

.glass-card:hover {
  transform: translate3d(0, -6px, 0);
  border-color: rgba(34, 197, 94, 0.5);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.7), 
              0 0 25px 0 rgba(34, 197, 94, 0.25);
}
