/* --- BASE & UTILITIES --- */
:root {
  /* Gemma-inspired color palette */
  --primary-bg: #121212; /* Deep charcoal */
  --secondary-bg: #1E1E1E; /* Rich dark gray */
  --ui-elements: #2A2A2A; /* Medium gray */
  --primary-accent: #0088FF; /* Electric blue for interactive elements */
  --secondary-accent: #A855F7; /* Vibrant purple for AI-related elements */
  --tertiary-accent: #06B6D4; /* Cyan for highlights and emphasis */
  --text-primary: #FFFFFF; /* White */
  --text-secondary: #E0E0E0; /* Light gray */
}

body {
  overflow-x: hidden;
  background-color: var(--primary-bg);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  line-height: 1.5;
}

h1, h2, h3, h4, h5, h6, .SAaS-logo {
  font-family: 'Space Grotesk', sans-serif;
  letter-spacing: -0.02em;
}

/* --- LOGO SECTION --- */
.logo-section {
  position: relative;
  text-align: center;
  padding: 2rem 0;
  background-color: rgba(18, 18, 18, 0.95); /* Slightly transparent primary-bg */
  overflow: hidden;
  min-height: 10rem; /* Ensure space is reserved when logo becomes fixed */
}

/* --- FEATURES SECTION --- */
.features-section {
  position: relative;
  padding: 2rem 0 6rem;
  background-color: var(--primary-bg);
}

/* Particles background */
.particles-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1; /* Above the base section but below content */
  pointer-events: none; /* Allow clicks to pass through to content */
}

/* Floating elements */
.floating-element {
  position: absolute;
  pointer-events: none;
  opacity: 0.5;
  filter: blur(1px);
  z-index: 1;
}

.float-1 {
  top: 15%;
  left: 10%;
  width: 10px;
  height: 10px;
  background: var(--primary-accent);
  border-radius: 50%;
  box-shadow: 0 0 15px var(--primary-accent);
  animation: float-animation 8s ease-in-out infinite;
}

.float-2 {
  top: 60%;
  right: 15%;
  width: 15px;
  height: 15px;
  background: var(--secondary-accent);
  border-radius: 50%;
  box-shadow: 0 0 20px var(--secondary-accent);
  animation: float-animation 12s ease-in-out infinite 2s;
}

.float-3 {
  bottom: 20%;
  left: 20%;
  width: 8px;
  height: 8px;
  background: var(--tertiary-accent);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--tertiary-accent);
  animation: float-animation 10s ease-in-out infinite 1s;
}

@keyframes float-animation {
  0% {
    transform: translateY(0) translateX(0);
  }
  25% {
    transform: translateY(-15px) translateX(10px);
  }
  50% {
    transform: translateY(10px) translateX(-10px);
  }
  75% {
    transform: translateY(-5px) translateX(15px);
  }
  100% {
    transform: translateY(0) translateX(0);
  }
}

/* Enhanced glow effects */
.glow-effect {
  position: relative;
}

.glow-effect::before {
  content: '';
  position: absolute;
  top: -5px;
  left: -5px;
  right: -5px;
  bottom: -5px;
  border-radius: inherit;
  background: -webkit-linear-gradient(45deg, var(--primary-accent), var(--secondary-accent), var(--tertiary-accent));
  background: linear-gradient(45deg, var(--primary-accent), var(--secondary-accent), var(--tertiary-accent));
  z-index: -1;
  filter: blur(15px);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.glow-effect:hover::before {
  opacity: 0.7;
}

/* LOGO CONTAINER */
.logo-container {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10;
  padding: 2rem 0;
  transition: all 0.3s ease-out;
}

/* Fixed logo state - applied via JS */
.logo-container.fixed {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 1rem 0;
  z-index: 100;
  background-color: rgba(18, 18, 18, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}


/* LOGO WRAPPER */
.logo-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* LOGO TEXT STYLES */
.SAaS-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.5rem;
}

.SAaS-logo span {
  display: inline-block;
  transition: opacity 0.4s ease-in-out, text-shadow 0.4s ease-in-out, background-position 0.8s ease;
  will-change: opacity, text-shadow, background-position; /* Performance hint for animations */
}

.logo-CK {
  margin-right: 0.2em; /* Add space between CK and SAaS */
}

/* LOGO SUBTITLE STYLES */
.logo-subtitle {
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-align: center;
  opacity: 0.9;
  margin-top: -0.5rem;
  white-space: nowrap;
}

.subtitle-shoes, .subtitle-accessories, .subtitle-services {
  display: inline-block;
  opacity: 1; /* Always visible */
  color: var(--text-secondary); /* Default gray color */
  transition: all 0.4s ease-in-out;
  text-shadow: none;
  margin-right: 0.3em; /* Add spacing between words */
}

.subtitle-shoes.highlighted {
  color: var(--tertiary-accent); /* Light blue glow */
  text-shadow: 0 0 10px var(--tertiary-accent), 0 0 20px var(--tertiary-accent);
}

.subtitle-accessories.highlighted {
  color: var(--tertiary-accent); /* Light blue glow */
  text-shadow: 0 0 10px var(--tertiary-accent), 0 0 20px var(--tertiary-accent);
}

.subtitle-services.highlighted {
  color: var(--tertiary-accent); /* Light blue glow */
  text-shadow: 0 0 10px var(--tertiary-accent), 0 0 20px var(--tertiary-accent);
}

/* Gradient text effect for SAaS letters */
.logo-S, .logo-A, .logo-a, .logo-S2 {
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  background-size: 200% auto;
  animation: gradient-shift 4s ease infinite;
}

/* Remove gradients - make all letters white/gray */
.logo-S, .logo-A, .logo-a, .logo-S2 {
  color: var(--text-secondary);
  background: none;
}

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

/* Initial visibility states */
.logo-CK {
  opacity: 1;
}
.logo-S, .logo-A, .logo-a, .logo-S2 {
  opacity: 0;
}
.subtitle-shoes, .subtitle-accessories, .subtitle-services {
  opacity: 1; /* Always visible */
}

/* Desktop: Make logo letters visible initially */
@media (min-width: 1024px) {
  .logo-S, .logo-A, .logo-a, .logo-S2 {
    opacity: 1;
  }
}

/* Active state for letters - enhance visibility when active */
.logo-S.active, .logo-A.active, .logo-a.active, .logo-S2.active {
  opacity: 1;
  filter: brightness(1.2);
  text-shadow: 0 0 12px currentColor, 0 0 20px currentColor; /* Enhanced glow */
}

/* Final glow effect */
.SAaS-logo.final-glow span {
  background-image: -webkit-linear-gradient(45deg, var(--tertiary-accent), var(--text-secondary), var(--tertiary-accent));
  background-image: linear-gradient(45deg, var(--tertiary-accent), var(--text-secondary), var(--tertiary-accent));
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  text-shadow: 0 0 15px var(--tertiary-accent), 0 0 30px var(--tertiary-accent); /* Larger glow */
  animation: gradient-shift 3s ease infinite;
}

/* Dark translucent style with neon glow */
.logo-wrapper.dark-translucent {
  background-color: rgba(0, 0, 0, 0.6); /* Dark translucent background */
  padding: 1.25rem; /* Add padding */
  border-radius: 1rem; /* Rounded corners */
  box-shadow: 0 0 25px rgba(6, 182, 212, 0.25); /* Enhanced outer glow */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.logo-wrapper.dark-translucent .logo-CK {
  color: var(--text-secondary); /* Slightly brighter text */
  text-shadow: 0 0 15px var(--tertiary-accent), 0 0 30px var(--tertiary-accent); /* Neon glow */
}

.logo-wrapper.dark-translucent .logo-S,
.logo-wrapper.dark-translucent .logo-A,
.logo-wrapper.dark-translucent .logo-a,
.logo-wrapper.dark-translucent .logo-S2 {
  text-shadow: 0 0 15px currentColor, 0 0 30px currentColor; /* Neon glow matching letter color */
}

.logo-wrapper.dark-translucent .logo-subtitle span.active {
  text-shadow: 0 0 10px currentColor, 0 0 20px rgba(currentColor, 0.5); /* Enhanced glow for subtitle */
}

/* CARDS CONTAINER */
.cards-container-wrapper {
  position: relative;
  z-index: 5; /* Lower than the fixed logo */
  width: 100%;
}

/* Desktop horizontal card layout */
@media (min-width: 1024px) {
  .cards-container {
    flex-direction: row !important;
    justify-content: space-between;
    max-width: 100% !important;
    padding: 0 2rem;
  }
  
  .feature-card {
    width: 30%;
    margin: 0;
  }
}

/* CARD STYLES */
.feature-card {
  opacity: 0;
  transform: scale(0.95) translateY(10px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
  will-change: opacity, transform; /* Performance hint for animations */
  
  /* Enhanced Glass Morphism */
  background: rgba(30, 30, 30, 0.5); /* Darker background based on secondary-bg */
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px); /* For Safari */
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 
    0 25px 45px rgba(0, 0, 0, 0.2),
    0 0 0 1px rgba(255, 255, 255, 0.05) inset;
  width: 90%; /* Responsive width */
  max-width: 400px; /* Max width for larger screens */
  margin-left: auto;
  margin-right: auto;
  border-radius: 1rem; /* Rounded corners */
  overflow: hidden;
  transition: 
    opacity 0.5s ease-out, 
    transform 0.5s ease-out, 
    box-shadow 0.3s ease,
    border-color 0.3s ease;
}

/* Card title gradient effects */
.feature-card h3 {
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  background-size: 200% auto;
  transition: background-position 0.5s ease;
  will-change: background-position; /* Performance hint for gradient animations */
  font-family: 'Space Grotesk', sans-serif;
  letter-spacing: -0.01em;
}

/* Specific gradients for each card title */
.shoes-card h3 {
  background-image: -webkit-linear-gradient(45deg, var(--primary-accent), #93c5fd, var(--primary-accent));
  background-image: linear-gradient(45deg, var(--primary-accent), #93c5fd, var(--primary-accent));
}

.accessories-card h3 {
  background-image: -webkit-linear-gradient(45deg, var(--secondary-accent), #d8b4fe, var(--secondary-accent));
  background-image: linear-gradient(45deg, var(--secondary-accent), #d8b4fe, var(--secondary-accent));
}

.services-card h3 {
  background-image: -webkit-linear-gradient(45deg, var(--tertiary-accent), #67e8f9, var(--tertiary-accent));
  background-image: linear-gradient(45deg, var(--tertiary-accent), #67e8f9, var(--tertiary-accent));
}

/* Hover effect for card titles */
.feature-card:hover h3 {
  background-position: right center;
}

/* Enhanced card hover effect */
.feature-card:hover {
  box-shadow: 
    0 30px 60px rgba(0, 0, 0, 0.25),
    0 0 15px rgba(255, 255, 255, 0.1), 
    0 0 30px rgba(6, 182, 212, 0.1),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-5px) scale(1.02);
}

/* Mobile active state (controlled by JS toggleClass) */
.feature-card.is-active {
  opacity: 1;
  transform: scale(1) translateY(0);
}

/* Animate card titles when cards become active */
.feature-card.is-active h3 {
  animation: gradient-shift 3s ease infinite;
}

/* Card image styling */
.feature-card img {
  transition: transform 0.5s ease;
  will-change: transform;
  border-radius: 0.5rem;
}

.feature-card:hover img {
  transform: scale(1.03);
}

/* Card content styling */
.feature-card p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Desktop styles will be controlled directly by the GSAP timeline */


/* Hero section styling */
.hero-section {
  background-color: var(--primary-bg);
  position: relative;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
  -webkit-radial-gradient(circle at top right, rgba(0, 136, 255, 0.15), transparent 50%),
  -webkit-radial-gradient(circle at bottom left, rgba(168, 85, 247, 0.15), transparent 50%);
  background:
  radial-gradient(circle at top right, rgba(0, 136, 255, 0.15), transparent 50%),
  radial-gradient(circle at bottom left, rgba(168, 85, 247, 0.15), transparent 50%);
  z-index: 1;
}

.hero-section p {
  color: var(--text-secondary);
  font-weight: 300;
  line-height: 1.7;
}

/* CTA CONTAINER AND BUTTON */
.cta-container {
  position: relative;
  z-index: 10;
  margin-bottom: 4rem; /* Add space between button and coming soon section */
}

/* Fixed CTA for desktop view */
@media (min-width: 1024px) {
  .cta-container {
    margin-bottom: 8rem; /* Increase space for better positioning */
  }
  
  .cta-container.fixed-bottom {
    position: fixed;
    bottom: 15vh; /* Adjust position for better visibility */
    left: 0;
    right: 0;
    z-index: 100;
  }
}

/* Mobile CTA positioning */
@media (max-width: 1023px) {
  .cta-container {
    /* transform: translateY(150%); */
    transition: transform 0.5s ease-in-out;
  }

  .cta-container.visible {
    transform: translateY(0);
  }
}

.explore-app-btn {
  background: linear-gradient(135deg, var(--tertiary-accent), #0891b2);
  color: white;
  position: relative;
  overflow: hidden;
  box-shadow: 
    0 0 15px rgba(6, 182, 212, 0.5), 
    0 0 30px rgba(6, 182, 212, 0.3);
  animation: button-pulse 3s ease-in-out infinite;
  border-radius: 0.75rem;
  font-family: 'Space Grotesk', sans-serif;
  letter-spacing: 0.02em;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

@keyframes button-pulse {
  0% {
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.5), 0 0 30px rgba(6, 182, 212, 0.3);
  }
  50% {
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.7), 0 0 40px rgba(6, 182, 212, 0.5);
  }
  100% {
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.5), 0 0 30px rgba(6, 182, 212, 0.3);
  }
}

.explore-app-btn:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 0 25px rgba(6, 182, 212, 0.8), 0 0 50px rgba(6, 182, 212, 0.5);
  background: linear-gradient(135deg, #0891b2, var(--tertiary-accent));
}

.explore-app-btn:active {
  transform: translateY(1px) scale(0.99);
}

/* Coming soon section */
#coming-soon {
  background-color: var(--primary-bg);
  position: relative;
  overflow: hidden;
}

#coming-soon::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: -webkit-radial-gradient(circle at center, rgba(6, 182, 212, 0.1), transparent 70%);
  background: radial-gradient(circle at center, rgba(6, 182, 212, 0.1), transparent 70%);
  z-index: 1;
}

#coming-soon h2 {
  position: relative;
  z-index: 2;
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  background-image: -webkit-linear-gradient(45deg, var(--tertiary-accent), #67e8f9, var(--tertiary-accent));
  background-image: linear-gradient(45deg, var(--tertiary-accent), #67e8f9, var(--tertiary-accent));
  background-size: 200% auto;
  animation: gradient-shift 4s ease infinite;
  text-shadow: 0 0 15px rgba(6, 182, 212, 0.5);
}

/* Footer styling */
footer {
  background-color: #0A0A0A; /* Dark background */
  color: #6B7280; /* Gray text */
  border-top: 1px solid rgba(255, 255, 255, 0.05); /* Subtle top border */
}

/* RESPONSIVE BREAKPOINTS */

/* Small mobile devices */
@media (max-width: 479px) {
  .SAaS-logo {
    font-size: 2.5rem; /* Smaller font size for very small screens */
  }
  
  .logo-subtitle {
    font-size: 0.7rem;
    margin-top: -0.3rem;
  }
  
  .feature-card {
    padding: 1rem;
    margin-bottom: 2rem;
  }
  
  .feature-card h3 {
    font-size: 1.25rem;
  }
  
  h1 {
    font-size: 24px;
    line-height: 32px;
  }
  
  h2 {
    font-size: 20px;
    line-height: 28px;
  }
  
  body {
    font-size: 14px;
    line-height: 20px;
  }
}

/* Mobile devices */
@media (min-width: 480px) and (max-width: 767px) {
  .SAaS-logo {
    font-size: 3rem;
  }
  
  .logo-subtitle {
    font-size: 0.8rem;
  }
  
  .feature-card {
    padding: 1.25rem;
    margin-bottom: 2.5rem;
  }
  
  h1 {
    font-size: 24px;
    line-height: 32px;
  }
  
  h2 {
    font-size: 20px;
    line-height: 28px;
  }
  
  body {
    font-size: 14px;
    line-height: 20px;
  }
}

/* Tablets */
@media (min-width: 768px) and (max-width: 1023px) {
  .SAaS-logo {
    font-size: 4rem;
  }
  
  .logo-subtitle {
    font-size: 1rem;
  }
  
  .feature-card {
    max-width: 500px; /* Wider cards on tablets */
    padding: 1.5rem;
  }
  
  .feature-card h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
  }
  
  .cards-container {
    gap: 4rem; /* More spacing between cards */
  }
  
  h1 {
    font-size: 28px;
    line-height: 36px;
  }
  
  h2 {
    font-size: 24px;
    line-height: 32px;
  }
}

/* All mobile and tablet devices */
@media (max-width: 1023px) {
  .hero-logo {
    opacity: 1;
    transform: none;
  }
}

/* Desktop specific adjustments */
@media (min-width: 1024px) {
  .cards-container {
    gap: 6rem; /* Even more spacing for desktop */
  }
  
  .logo-subtitle {
    font-size: 1.2rem;
    margin-top: -0.3rem;
  }
  
  .feature-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.5s ease-out;
  }
  
  h1 {
    font-size: 32px;
    line-height: 40px;
  }
  
  h2 {
    font-size: 24px;
    line-height: 32px;
  }
  
  body {
    font-size: 16px;
    line-height: 24px;
  }
}

/* Prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* --- HERO GALLERY STYLES --- */
#hero-gallery {
    pointer-events: none;
}

#hero-gallery img {
    position: absolute;
    top: 20%;
    left: 30%;
    width: 40%;
    height: 50%;
    object-fit: cover; /* Cover the entire viewport area completely */
    object-position: center;
    border-radius: 0.25rem;
    background-color: rgba(0, 0, 0, 0.8); /* Dark background to hide underlying image */
}
