@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --primary: #ff0055;
  --secondary: #00ff88;
  --accent: #7c3aed;
  --bg-primary: #0a0a0a;
  --bg-secondary: #1a1a1a;
  --bg-card: #1e1e2e;
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --border: rgba(255, 255, 255, 0.1);
  --glow: rgba(255, 0, 85, 0.3);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', sans-serif;
  background: linear-gradient(135deg, var(--bg-primary) 0%, #1a0a1a 50%, var(--bg-primary) 100%);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

/* Animated background particles */
.particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: var(--secondary);
  border-radius: 50%;
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); opacity: 0.5; }
  50% { transform: translateY(-20px) rotate(180deg); opacity: 1; }
}

/* Header section */
.header {
  position: relative;
  z-index: 10;
  text-align: center;
  padding: 4rem 2rem 2rem;
  background: radial-gradient(ellipse at center, rgba(255, 0, 85, 0.1) 0%, transparent 70%);
}

.logo {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 700;
  background: linear-gradient(45deg, var(--primary), var(--secondary), var(--accent));
  background-size: 200% 200%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 3s ease-in-out infinite;
  margin-bottom: 1rem;
  text-shadow: 0 0 30px rgba(255, 0, 85, 0.5);
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-weight: 300;
}

.stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.stat {
  text-align: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--secondary);
  display: block;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Main content */
.container {
  position: relative;
  z-index: 10;
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 3rem;
  color: var(--text-primary);
}

/* Article Content Styling */
.container h3 {
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--secondary);
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.container h4 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--primary);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.container p, .container ul, .container ol {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.container ul, .container ol {
  padding-left: 2rem;
}

.container li {
  margin-bottom: 0.5rem;
}

.container a {
    color: var(--secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.container a:hover {
    color: var(--primary);
    text-decoration: underline;
}


.container pre {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.5rem;
  overflow-x: auto;
  margin: 1.5rem 0;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.container code {
  font-family: 'Courier New', Courier, monospace;
  font-size: 1rem;
  color: var(--text-primary);
}

/* Chart Container */
.chart-container {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 2rem;
    margin: 3rem auto;
    max-width: 900px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.chart-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.chart-grid .chart-container {
    margin: 0;
}

.chart-grid h4 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 1rem;
}

.chart-grid p {
    text-align: center;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}


/* Module grid */
.modules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.module-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2rem;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  backdrop-filter: blur(10px);
}

.module-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.module-card:hover::before {
  transform: scaleX(1);
}

.module-card:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 0 30px var(--glow);
  border-color: var(--primary);
}

.module-number {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  color: white;
}

.module-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1rem;
  padding-right: 3rem;
}

.module-description {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.topics-list {
  list-style: none;
}

.topic-item {
  display: flex;
  align-items: center;
  margin-bottom: 0.75rem;
  padding: 0.5rem;
  border-radius: 8px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.topic-item:hover {
  background: rgba(255, 255, 255, 0.05);
  transform: translateX(5px);
}

.topic-icon {
  width: 8px;
  height: 8px;
  background: var(--secondary);
  border-radius: 50%;
  margin-right: 1rem;
  transition: all 0.3s ease;
}

.topic-item:hover .topic-icon {
  background: var(--primary);
  transform: scale(1.5);
}

.topic-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  transition: color 0.3s ease;
}

.topic-item:hover .topic-text {
  color: var(--text-primary);
}

/* Progress indicator */
.progress-section {
  background: var(--bg-secondary);
  border-radius: 20px;
  padding: 2rem;
  margin: 3rem 0;
  border: 1px solid var(--border);
}

.progress-title {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 2rem;
  color: var(--text-primary);
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: var(--bg-card);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 1rem;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 4px;
  width: 0%;
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes progressLoad {
  to { width: 25%; }
}

.progress-text {
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* Call to action */
.cta-section {
  text-align: center;
  padding: 4rem 2rem;
  background: radial-gradient(ellipse at center, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
}

.cta-button {
  display: inline-block;
  padding: 1rem 3rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  box-shadow: 0 10px 30px rgba(255, 0, 85, 0.3);
  position: relative;
  overflow: hidden;
}

.cta-button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.cta-button:hover::before {
  left: 100%;
}

.cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(255, 0, 85, 0.4);
}

/* Responsive design */
@media (max-width: 768px) {
  .modules-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .stats {
    gap: 2rem;
  }
  
  .header {
    padding: 2rem 1rem 1rem;
  }
  
  .container {
    padding: 1rem;
  }
}

/* Loading animation */
.module-card {
  opacity: 0;
  animation: slideUp 0.6s ease forwards;
}

.module-card:nth-child(1) { animation-delay: 0.1s; }
.module-card:nth-child(2) { animation-delay: 0.2s; }
.module-card:nth-child(3) { animation-delay: 0.3s; }
.module-card:nth-child(4) { animation-delay: 0.4s; }
.module-card:nth-child(5) { animation-delay: 0.5s; }
.module-card:nth-child(6) { animation-delay: 0.6s; }
.module-card:nth-child(7) { animation-delay: 0.7s; }

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.module-card.completed {
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.15), rgba(0, 255, 136, 0.05));
  border-color: var(--secondary);
  position: relative;
}

.module-card.completed::after {
  content: '✓';
  position: absolute;
  top: 1rem;
  left: 1rem;
  width: 30px;
  height: 30px;
  background: var(--secondary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  color: black;
  font-size: 1.2rem;
  animation: checkBounce 0.5s ease-out;
}

@keyframes checkBounce {
  0% { transform: scale(0) rotate(0deg); }
  50% { transform: scale(1.2) rotate(180deg); }
  100% { transform: scale(1) rotate(360deg); }
}

.module-card.completed .module-number {
  background: var(--secondary);
  color: black;
}

.module-card.completed {
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.15), rgba(0, 255, 136, 0.05));
  border-color: var(--secondary);
  position: relative;
}

.module-card.completed::after {
  content: '✓';
  position: absolute;
  top: 1rem;
  left: 1rem;
  width: 30px;
  height: 30px;
  background: var(--secondary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  color: black;
  font-size: 1.2rem;
  animation: checkBounce 0.5s ease-out;
}

@keyframes checkBounce {
  0% { transform: scale(0) rotate(0deg); }
  50% { transform: scale(1.2) rotate(180deg); }
  100% { transform: scale(1) rotate(360deg); }
}

.module-card.completed .module-number {
  background: var(--secondary);
  color: black;
}

a {
  text-decoration: none;
  color: inherit;
}

.topic-item a {
  display: flex;
  align-items: center;
  width: 100%;
}

.topic-item:hover a {
  text-decoration: none;
}

.progress-fill {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}
