/* 🌟 Global Variables & Reset */
:root {
  --primary-bg: #0f172a;
  --secondary-bg: #1e293b;
  --accent-color: #6366f1;
  --accent-gradient: linear-gradient(135deg, #6366f1, #a855f7);
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --glass-bg: rgba(30, 41, 59, 0.7);
  --glass-border: rgba(255, 255, 255, 0.1);
  --card-hover: rgba(255, 255, 255, 0.05);
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--primary-bg);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* 📜 Scroll Progress Bar */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 4px;
  background: var(--accent-gradient);
  z-index: 1001;
  transition: width 0.1s;
}

/* 🔝 Back to Top Button */
#back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--accent-gradient);
  color: white;
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  font-size: 24px;
  cursor: pointer;
  display: none;
  z-index: 999;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

#back-to-top:hover {
  transform: translateY(-5px);
}

/* 🌌 Header & Navigation */
header {
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--glass-border);
  transition: all 0.3s ease;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 5%;
  max-width: 1400px;
  margin: 0 auto;
}

.logo-container {
  display: flex;
  align-items: center;
  text-decoration: none;
  gap: 12px;
}

#site-logo {
  height: 45px;
  transition: transform 0.3s ease;
}

.logo-container:hover #site-logo {
  transform: rotate(10deg);
}

#site-title {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 700;
  background: var(--accent-gradient);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.5px;
}

nav {
  display: flex;
  gap: 30px;
}

nav a,
.dropbtn {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  font-size: 16px;
  transition: color 0.3s ease;
  position: relative;
}

nav a:hover,
.dropbtn:hover,
nav a.active {
  color: var(--text-primary);
}

/* Animated Underline */
nav a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background: var(--accent-gradient);
  transition: width 0.3s ease;
}

nav a:hover::after,
nav a.active::after {
  width: 100%;
}

/* Dropdown Menu */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  display: none;
  position: absolute;
  background-color: var(--secondary-bg);
  min-width: 180px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  border: 1px solid var(--glass-border);
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding: 10px 0;
  z-index: 1000;
  opacity: 0;
  animation: fadeIn 0.2s forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

.dropdown:hover .dropdown-content {
  display: block;
}

.dropdown-content a {
  color: var(--text-secondary);
  padding: 12px 20px;
  text-decoration: none;
  display: block;
  font-size: 14px;
  transition: background 0.2s;
}

.dropdown-content a:hover {
  background-color: var(--card-hover);
  color: var(--accent-color);
}

.dropdown-content a::after {
  display: none;
}

/* Auth Buttons */
.auth-buttons {
  display: flex;
  gap: 15px;
}

.auth-buttons button {
  padding: 10px 24px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: var(--font-body);
}

.login-btn {
  background: transparent;
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
}

.login-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--text-primary);
}

.signup-btn {
  background: var(--accent-gradient);
  border: none;
  color: white;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.signup-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* 🚀 Hero Section */
#hero {
  position: relative;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 20px;
  overflow: hidden;
}

#hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

#hero h2 {
  font-family: var(--font-heading);
  font-size: 4rem;
  line-height: 1.1;
  margin-bottom: 20px;
  background: linear-gradient(to right, #fff, #cbd5e1);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

#hero p {
  font-size: 1.5rem;
  color: var(--text-secondary);
  margin-bottom: 40px;
  min-height: 1.5em;
}

#get-started {
  padding: 16px 40px;
  font-size: 1.2rem;
  font-weight: 600;
  color: white;
  background: var(--accent-gradient);
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 0 20px rgba(99, 102, 241, 0.4);
}

#get-started:hover {
  transform: scale(1.05);
  box-shadow: 0 0 40px rgba(99, 102, 241, 0.6);
}

/* 📐 Sections */
section {
  padding: 100px 20px;
}

.section-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

section h1,
section h2 {
  font-family: var(--font-heading);
  font-size: 3rem;
  margin-bottom: 20px;
  color: var(--text-primary);
}

section p {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 60px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* 🃏 Cards (Buttons) */
.section-buttons {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  perspective: 1000px;
}

.button {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 30px;
  width: 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  transition: transform 0.1s ease, box-shadow 0.3s ease;
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.button::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 24px;
  padding: 2px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.button:hover {
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.button img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 16px;
  margin-bottom: 10px;
  transition: transform 0.3s ease;
}

.button:hover img {
  transform: scale(1.05);
}

.button a,
.button h3 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
  z-index: 1;
}

.button a::after {
  content: ' →';
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  display: inline-block;
  transform: translateX(-10px);
}

.button:hover a::after {
  opacity: 1;
  transform: translateX(0);
}

.math-symbol {
  position: absolute;
  bottom: -20px;
  right: -20px;
  opacity: 0.1;
  transform: rotate(-15deg);
  transition: all 0.5s ease;
  width: 100px;
  height: 100px;
}

.button:hover .math-symbol {
  opacity: 0.2;
  transform: rotate(0deg) scale(1.2);
}

/* 📧 Contact Form */
form {
  max-width: 600px;
  margin: 0 auto;
  background: var(--glass-bg);
  padding: 40px;
  border-radius: 24px;
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(10px);
}

input,
textarea {
  width: 100%;
  padding: 16px;
  margin-bottom: 20px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  transition: border-color 0.3s ease;
}

input:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent-color);
  background: rgba(15, 23, 42, 0.8);
}

textarea {
  height: 150px;
  resize: vertical;
}

form button {
  width: 100%;
  padding: 16px;
  background: var(--accent-gradient);
  color: white;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: transform 0.2s;
}

form button:hover {
  transform: translateY(-2px);
}

/* 🦶 Footer */
footer {
  background: var(--secondary-bg);
  padding: 40px 20px;
  text-align: center;
  border-top: 1px solid var(--glass-border);
  margin-top: 100px;
}

footer p {
  color: var(--text-secondary);
}

/* 📱 Mobile Responsiveness */
.hamburger {
  display: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--text-primary);
}

@media (max-width: 768px) {
  .header-container {
    padding: 15px 20px;
  }

  nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: var(--secondary-bg);
    flex-direction: column;
    padding: 20px;
    border-bottom: 1px solid var(--glass-border);
    gap: 15px;
  }

  nav.active {
    display: flex;
  }

  .hamburger {
    display: block;
  }

  .auth-buttons {
    display: none;
  }

  #hero h2 {
    font-size: 2.5rem;
  }

  .section-buttons {
    flex-direction: column;
    align-items: center;
  }

  .button {
    width: 100%;
    max-width: 350px;
  }
}