/* Toledo Academy - Avant Garde / Glass & Void Design System */

:root {
  /* Core Palette - Deep Space & Neon */
  --bg-void: #030014;
  --bg-stars: #050510;
  --bg-glass: rgba(255, 255, 255, 0.03);
  --bg-glass-hover: rgba(255, 255, 255, 0.07);

  --primary: #7000FF;
  /* Electric Violet */
  --primary-glow: rgba(112, 0, 255, 0.5);
  --accent: #00F0FF;
  /* Neon Cyan */
  --accent-glow: rgba(0, 240, 255, 0.5);

  --border-light: rgba(255, 255, 255, 0.1);
  --border-glow: rgba(112, 0, 255, 0.3);

  /* Typography - Editorial */
  --text-main: #FFFFFF;
  --text-muted: rgba(255, 255, 255, 0.6);
  --text-dark: #000000;
  /* For rare light backgrounds */

  /* Gradients */
  --gradient-main: linear-gradient(135deg, var(--bg-void) 0%, #1a0b2e 100%);
  --gradient-text: linear-gradient(to right, #fff 20%, var(--accent) 100%);
  --gradient-glow: radial-gradient(circle at center, var(--primary-glow) 0%, transparent 70%);

  /* Spacing & Layout */
  --container-width: 1400px;
  /* Wider for cinematic feel */
  --header-height: 90px;

  /* Shadows */
  --shadow-void: 0 0 50px rgba(0, 0, 0, 0.5);
  --shadow-neon: 0 0 20px var(--primary-glow);
}

/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Space Grotesk', sans-serif;
  background-color: var(--bg-void);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  /* Animated Mesh Gradient - Darkened for better text contrast */
  background-image: radial-gradient(at 0% 0%, hsla(253, 16%, 7%, 1) 0, transparent 50%),
    radial-gradient(at 50% 0%, hsla(225, 39%, 25%, 1) 0, transparent 50%),
    radial-gradient(at 100% 0%, hsla(339, 49%, 25%, 1) 0, transparent 50%);
  background-size: 200% 200%;
  animation: meshGradient 20s ease infinite;
}

@keyframes meshGradient {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

/* Typography Overhaul */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 900;
  /* Ultra Bold "Black" */
  letter-spacing: -0.04em;
  color: var(--text-main);
  line-height: 1.1;
  text-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  /* improved legibility on gradients */
}

h1 {
  font-size: clamp(3.5rem, 8vw, 6rem);
  text-transform: uppercase;
  /* Add shadow to lift text off the mesh gradient */
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

h2 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: 2rem;
}

h3 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

p {
  color: var(--text-muted);
  font-size: 1.125rem;
  font-weight: 300;
  margin-bottom: 1.5rem;
  max-width: 65ch;
}

.text-gradient {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

/* Components - Glass Cards */
.card {
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  padding: 3rem;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
}

/* Fix for Case Study Results Card */
.bg-blue-50 {
  background: var(--bg-glass-hover) !important;
  border: 1px solid var(--border-light);
  color: var(--text-main);
  backdrop-filter: blur(20px);
}

.text-gray-600 {
  color: var(--text-muted) !important;
}

.text-gray-900 {
  color: var(--text-main) !important;
}

.card:hover {
  transform: translateY(-8px) scale(1.02) rotateX(2deg);
  border-color: var(--accent);
  box-shadow: 0 10px 40px rgba(0, 240, 255, 0.15);
  background: var(--bg-glass-hover);
}

/* Ensure no white processing */
.bg-white,
.bg-light {
  background: transparent !important;
  /* Override legacy classes */
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem 2.5rem;
  border-radius: 100px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-decoration: none;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-primary {
  background: var(--primary);
  color: white;
  border: 1px solid var(--primary);
  box-shadow: 0 0 20px var(--primary-glow);
}

.btn-primary:hover {
  background: transparent;
  box-shadow: 0 0 30px var(--primary-glow);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
}

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  display: flex;
  align-items: center;
  z-index: 1000;
  transition: background 0.3s ease;
  background: rgba(3, 0, 20, 0.7);
  backdrop-filter: blur(15px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.mobile-menu-btn {
  display: none;
  /* Hidden by default on desktop */
}

.nav-container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-links {
  display: flex;
  gap: 3rem;
}

.nav-link {
  color: var(--text-muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 500;
}

.nav-link:hover,
.nav-link.active {
  color: var(--accent);
}

/* Hero Section */
.hero {
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding-top: var(--header-height);
  overflow: hidden;
}

.hero-inner {
  min-height: 50vh !important;
  /* Reduced height for inner pages */
  align-items: center;
  /* Ensure vertical centering */
}

.hero .container {
  position: relative;
  z-index: 2;
}

/* Canvas fix from previous step, kept but styled */
#hero-canvas {
  /* Inline style is still in HTML for robustness, but we can reinforce here */
  opacity: 0.6;
  /* Slight dim for text readability */
}

/* Layout Utilities */
.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: 4rem 0;
  /* Reduced from 8rem to fix large gaps */
}

.grid {
  display: grid;
  gap: 2rem;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.process-step {
  background: var(--bg-glass);
  border: 1px solid var(--border-light);
  backdrop-filter: blur(10px);
  padding: 2rem;
  border-radius: 20px;
  position: relative;
  text-align: center;
  transition: transform 0.3s ease;
}

.process-step:hover {
  transform: translateY(-5px);
  border-color: var(--accent);
  box-shadow: 0 10px 30px rgba(0, 240, 255, 0.1);
}

.process-step-number {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.5rem;
  margin: 0 auto 1.5rem;
  color: white;
  box-shadow: 0 0 15px var(--primary-glow);
}

/* Asymmetric / Creative Helpers */
.feature-icon {
  font-size: 3rem;
  color: var(--accent);
  margin-bottom: 1.5rem;
  text-shadow: 0 0 20px var(--accent-glow);
  background: transparent !important;
  /* Override legacy bg */
  padding: 0 !important;
}

/* Feature lists */
ul li {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--text-muted);
}

.material-symbols-outlined {
  vertical-align: middle;
}

/* Animations */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: all 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.reveal-pending {
  opacity: 0;
  transform: translateY(50px) scale(0.95);
}

/* Mobile */
@media (max-width: 768px) {
  h1 {
    font-size: 3rem;
  }

  h2 {
    font-size: 2rem;
  }

  .icon-3d {
    display: inline-block;
    /* font-size is set inline or by parent, but usually large */
    background: linear-gradient(135deg, #fff 0%, var(--primary) 50%, var(--accent) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    transform: perspective(500px) rotateY(15deg) rotateX(10deg);
    filter: drop-shadow(4px 4px 0px rgba(112, 0, 255, 0.3)) drop-shadow(0 0 15px var(--primary-glow));
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    margin-right: 1rem;
  }

  .icon-3d:hover {
    transform: perspective(500px) rotateY(0deg) rotateX(0deg) scale(1.1);
    filter: drop-shadow(0 0 20px var(--accent-glow));
  }

  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  .nav-links {
    display: none;
  }

  .mobile-menu-btn {
    display: block;
    color: white;
    background: transparent !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    padding: 0.5rem;
    font-size: 2rem;
    /* Ensure icon is large enough */
  }

  .mobile-menu {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background: var(--bg-void);
    z-index: 999;
    padding: 2rem;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
  }

  .mobile-menu.active {
    transform: translateX(0);
  }

  .mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: center;
  }

  .mobile-nav-links .nav-link {
    font-size: 1.5rem;
  }
}



/* Footer */
footer {
  border-top: 1px solid var(--border-light);
  background: var(--bg-stars);
  padding: 5rem 0;
  margin-top: 5rem;
}

footer a {
  color: var(--text-light);
  text-decoration: none;
  transition: color 0.3s ease;
}

footer a:hover {
  color: var(--primary);
}

/* Organic Dividers */
.wave-divider {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  overflow: hidden;
  line-height: 0;
  transform: rotate(180deg);
}

.wave-divider svg {
  position: relative;
  display: block;
  width: calc(150% + 1.3px);
  height: 100px;
}

.wave-divider .shape-fill {
  fill: var(--bg-glass);
}

.logo {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: white;
}

.logo-icon {
  width: 48px;
  height: 48px;
  color: var(--primary);
  filter: drop-shadow(0 0 10px var(--primary));
  flex-shrink: 0;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.logo-title {
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: white;
}

.logo-tagline {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}