:root {
  /* Color variables */
  --color-midnight: #1E2A38;
  --color-sky: #B0BEC5;
  --color-offwhite: #F5F6F7;
  --color-steel: #4B6584;
  --color-emerald: #20BF6B;
  
  /* Gradients */
  --gradient-cosmic: linear-gradient(135deg, #1E2A38 0%, #4B6584 100%);
  --gradient-nebula: linear-gradient(to right, #1E2A38, #4B6584, #20BF6B);
  
  /* Typography */
  --font-primary: 'Space Grotesk', sans-serif;
  --font-secondary: 'Outfit', sans-serif;
  
  /* Font sizes */
  --text-xs: 0.75rem;   /* 12px */
  --text-sm: 0.875rem;  /* 14px */
  --text-base: 1rem;    /* 16px */
  --text-md: 1.125rem;  /* 18px */
  --text-lg: 1.25rem;   /* 20px */
  --text-xl: 1.5rem;    /* 24px */
  --text-2xl: 2rem;     /* 32px */
  --text-3xl: 2.5rem;   /* 40px */
  
  /* Spacing */
  --space-xs: 0.25rem;  /* 4px */
  --space-sm: 0.5rem;   /* 8px */
  --space-md: 1rem;     /* 16px */
  --space-lg: 1.5rem;   /* 24px */
  --space-xl: 2rem;     /* 32px */
  --space-2xl: 3rem;    /* 48px */
  
  /* UI Elements */
  --radius-sm: 0.25rem; /* 4px */
  --radius-md: 0.5rem;  /* 8px */
  --radius-lg: 1rem;    /* 16px */
  --radius-pill: 9999px;
  
  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.12);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.05);
  
  /* Animations */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
  
  /* Layout */
  --container-width: 1280px;
  --header-height: 4.5rem;
}

/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  line-height: 1.5;
  color: var(--color-midnight);
  background-color: var(--color-offwhite);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-steel);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-emerald);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-secondary);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-md);
}

h1 {
  font-size: var(--text-3xl);
}

h2 {
  font-size: var(--text-2xl);
}

h3 {
  font-size: var(--text-xl);
}

p {
  margin-bottom: var(--space-md);
}

button, .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: var(--text-base);
  border: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  background-color: var(--color-steel);
  color: var(--color-offwhite);
  text-decoration: none;
}

button:hover, .button:hover {
  background-color: var(--color-emerald);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Container */
.container {
  width: 100%;
  max-width: var(--container-width);
  padding: 0 var(--space-lg);
  margin: 0 auto;
}

/* Section spacing */
section {
  padding: var(--space-2xl) 0;
}

/* Header */
.header {
  background-color: rgba(30, 42, 56, 0.95);
  color: var(--color-offwhite);
  position: relative;
  z-index: 100;
  transition: all var(--transition-normal);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.logo {
  font-family: var(--font-secondary);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--color-offwhite);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--color-offwhite);
  font-size: 1.5rem;
  cursor: pointer;
}

.nav-menu {
  display: flex;
  gap: var(--space-lg);
  list-style: none;
}

.nav-menu a {
  color: var(--color-offwhite);
  font-weight: 500;
  position: relative;
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-emerald);
  transition: width var(--transition-fast);
}

.nav-menu a:hover::after {
  width: 100%;
}

/* Hero section */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--gradient-cosmic);
  color: var(--color-offwhite);
  min-height: calc(100vh - var(--header-height));
  display: flex;
  align-items: center;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 600px;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  margin-bottom: var(--space-lg);
  line-height: 1.1;
}

.hero-text {
  font-size: var(--text-lg);
  margin-bottom: var(--space-xl);
  opacity: 0.9;
}

.hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0.6;
}

/* Courses section */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-xl);
}

.course-card {
  background-color: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.course-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.course-image {
  height: 200px;
  background-color: var(--color-steel);
  position: relative;
  overflow: hidden;
}

.course-content {
  padding: var(--space-lg);
}

.course-title {
  font-size: var(--text-lg);
  margin-bottom: var(--space-sm);
}

.course-price {
  color: var(--color-emerald);
  font-weight: 700;
  margin-top: var(--space-md);
  font-size: var(--text-lg);
}

/* Features section */
.features {
  background-color: var(--color-midnight);
  color: var(--color-offwhite);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: var(--space-xl);
}

.feature-item {
  text-align: center;
}

.feature-icon {
  color: var(--color-emerald);
  font-size: 2.5rem;
  margin-bottom: var(--space-md);
}

/* Testimonials */
.testimonial-slider {
  position: relative;
}
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: var(--space-xl)
}
.testimonial-item {
  padding: var(--space-xl);
  background-color: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  margin: 0 var(--space-md);
}
.pathway-item .dimension-element {
  margin: 12px;
}
.pathways-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}
.gravitational-grid {
  display: flex;
  justify-content: space-around;
  padding: 15px;
  gap: 50px;
}
.testimonial-text {
  font-style: italic;
  margin-bottom: var(--space-lg);
}

.testimonial-author {
  display: flex;
  align-items: center;
}

.testimonial-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: var(--space-md);
  background-color: var(--color-sky);
}

/* Contact section */
.contact {
  position: relative;
  overflow: hidden;
  background-color: var(--color-midnight);
  color: var(--color-offwhite);
}

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2xl);
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
}

.contact-icon {
  color: var(--color-emerald);
  font-size: 1.5rem;
  margin-top: 3px;
}

.contact-form {
  background-color: rgba(255, 255, 255, 0.05);
  padding: var(--space-xl);
  border-radius: var(--radius-md);
  backdrop-filter: blur(10px);
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: var(--space-md);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background-color: rgba(255, 255, 255, 0.05);
  color: var(--color-offwhite);
  font-family: var(--font-primary);
  transition: border-color var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus {
  border-color: var(--color-emerald);
  outline: none;
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

.form-checkbox {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.form-checkbox input[type="checkbox"] {
  margin-top: 0.2em;
}

.form-submit {
  background-color: var(--color-emerald);
  color: white;
  width: 100%;
}

/* Map */
.map-container {
  height: 300px;
  border-radius: var(--radius-md);
  overflow: hidden;
}

/* Footer */
.footer {
  background-color: var(--color-midnight);
  color: var(--color-sky);
  padding: var(--space-xl) 0;
  font-size: var(--text-sm);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-lg);
}

.footer-logo {
  color: var(--color-offwhite);
  font-weight: 700;
  margin-bottom: var(--space-md);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-lg);
}

.footer-nav a {
  color: var(--color-sky);
}

.footer-nav a:hover {
  color: var(--color-offwhite);
}

.footer-bottom {
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
}

/* Cookies policy popup */
.cookie-popup {
  position: fixed;
  bottom: var(--space-lg);
  right: var(--space-lg);
  max-width: 350px;
  padding: var(--space-lg);
  background-color: var(--color-midnight);
  color: var(--color-offwhite);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  transform: translateY(200%);
  opacity: 0;
  transition: transform var(--transition-normal), opacity var(--transition-normal);
}

.cookie-popup.show {
  transform: translateY(0);
  opacity: 1;
}

.cookie-buttons {
  display: flex;
  gap: var(--space-md);
  margin-top: var(--space-lg);
}

.cookie-accept {
  background-color: var(--color-emerald);
}

.cookie-decline {
  background-color: transparent;
  border: 1px solid var(--color-sky);
}

/* 404 page */
.error-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  text-align: center;
  padding: var(--space-2xl) var(--space-lg);
  background: var(--gradient-cosmic);
  color: var(--color-offwhite);
}

.error-code {
  font-size: 8rem;
  font-weight: 800;
  margin-bottom: var(--space-md);
  line-height: 1;
}

.error-title {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-lg);
}

/* 3D Canvas Animation */
.canvas-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

/* Thank you page */
.thank-you {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  text-align: center;
  background: var(--gradient-cosmic);
  color: var(--color-offwhite);
  padding: var(--space-2xl) var(--space-lg);
}

.thank-you-icon {
  font-size: 5rem;
  color: var(--color-emerald);
  margin-bottom: var(--space-xl);
}

/* Media Queries */
@media (max-width: 1024px) {
  :root {
    --text-3xl: 2.25rem;
    --text-2xl: 1.75rem;
    --space-2xl: 2.5rem;
  }
  
  .contact-wrapper {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }
  
  .nav-menu {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background-color: var(--color-midnight);
    flex-direction: column;
    padding: var(--space-lg);
    gap: var(--space-lg);
    transform: translateY(-100%);
    opacity: 0;
    transition: transform var(--transition-normal), opacity var(--transition-normal);
    pointer-events: none;
  }
  .gravitational-grid {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
  }
  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  :root {
    --text-3xl: 2rem;
    --text-2xl: 1.5rem;
    --text-xl: 1.25rem;
    --space-2xl: 2rem;
    --space-xl: 1.5rem;
  }
  .nav-toggle {
    display: block;
  }
  .gravitational-grid {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
  }
  .hero-content {
    text-align: center;
  }

  .courses-grid {
    grid-template-columns: 1fr;
  }
  
  .cookie-popup {
    left: var(--space-lg);
    right: var(--space-lg);
    max-width: none;
  }
  
  .cookie-buttons {
    flex-direction: column;
  }
  
  .error-code {
    font-size: 6rem;
  }
}

/* Animations */
@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

.animate-float {
  animation: float 4s ease-in-out infinite;
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

.animate-pulse {
  animation: pulse 3s ease-in-out infinite;
}

/* 3D Element Styling */
.dimension-wrapper {
  perspective: 1000px;
  transform-style: preserve-3d;
}

.categories-grid .dimension-element {
  padding: 15px;
  width: 100%;
  transition: transform var(--transition-slow);
  transform-style: preserve-3d;
}

.dimension-element:hover {
  transform: rotateY(10deg) rotateX(5deg);
}

/* Quantum ripple effect */
.quantum-ripple {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.quantum-ripple::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, 
    rgba(32, 191, 107, 0.2) 0%, 
    rgba(32, 191, 107, 0) 70%);
  z-index: -1;
  opacity: 0;
  transition: opacity var(--transition-slow);
}

.quantum-ripple:hover::after {
  opacity: 1;
  animation: ripple 2s ease-out infinite;
}

@keyframes ripple {
  0% {
    transform: scale(0.8);
    opacity: 1;
  }
  100% {
    transform: scale(1.5);
    opacity: 0;
  }
}