/* Global Styles */
:root {
  --primary-color: #6366f1;
  --secondary-color: #8b5cf6;
  --background-color: #f8fafc;
  --card-background: rgba(255, 255, 255, 0.95);
  --text-primary: #1e293b;
  --text-secondary: #475569;
  --border-radius: 12px;
  --transition: all 0.3s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%) fixed;
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

.container {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* Section Styles */
section {
  background: var(--card-background);
  border-radius: var(--border-radius);
  padding: 2rem;
  margin-bottom: 3rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.4);
  position: relative;
  isolation: isolate;
  transform: translateZ(0);
  will-change: transform;
}

section::before {
  content: "";
  position: absolute;
  inset: 0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: inherit;
  z-index: -1;
}

/* Header Styles */
h1 {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 2rem;
  background: linear-gradient(
    45deg,
    var(--primary-color),
    var(--secondary-color)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

h3 {
  font-size: 1.5rem;
  color: var(--text-primary);
  margin: 2rem 0 1rem;
  position: relative;
}

h3::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 60px;
  height: 3px;
  background: linear-gradient(
    90deg,
    var(--primary-color),
    var(--secondary-color)
  );
  border-radius: 2px;
}

/* List Styles */
ul {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1rem;
  margin: 1rem 0;
}

/* Link and Button Styles */
a {
  text-decoration: none;
}

li {
  background: var(--card-background);
  padding: 1rem 1.5rem;
  border-radius: var(--border-radius);
  border: 1px solid rgba(255, 255, 255, 0.4);
  transition: var(--transition);
  cursor: pointer;
  color: var(--text-primary);
  font-weight: 500;
  text-align: center;
  position: relative;
  overflow: hidden;
  transform: translateZ(0);
}

li::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(99, 102, 241, 0.1),
    rgba(139, 92, 246, 0.1)
  );
  opacity: 0;
  transition: var(--transition);
}

li:hover {
  transform: translateY(-3px);
  border-color: var(--primary-color);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.15);
}

li:hover::before {
  opacity: 1;
}

/* Modern 2024 Section Specific */
.modern-2024 {
  border-top: 4px solid var(--primary-color);
}

/* Pretty Modern Section Specific */
.pretty-modern {
  border-top: 4px solid var(--secondary-color);
}

/* Ugly But Fast Section Specific */
.ugly-but-fast {
  border-top: 4px solid #10b981;
}

/* Scrollbar Styles */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--background-color);
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color);
}

/* Performance Optimizations */
* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Responsive Design */
@media (max-width: 768px) {
  .container {
    padding: 0 1rem;
  }

  h1 {
    font-size: 2rem;
  }

  section {
    padding: 1.5rem;
  }

  ul {
    grid-template-columns: 1fr;
  }
}

/* Reduce Motion */
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
