/* style.css - Modern Smooth Styles for OpenSourceX */

/* CSS Variables for consistent theming */
:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --primary-light: #8b5cf6;
  --secondary: #f8fafc;
  --accent: #06d6a0;
  --text: #1e293b;
  --text-light: #64748b;
  --text-lighter: #94a3b8;
  --white: #ffffff;
  --gray-50: #f8fafc;
  --gray-100: #f1f5f9;
  --gray-200: #e2e8f0;
  --gray-300: #cbd5e1;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --radius: 8px;
  --transition: all 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  line-height: 1.6;
  color: var(--text);
  background-color: var(--white);
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: var(--text);
}

h1 {
  font-size: 2.5rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

h2 {
  font-size: 2rem;
  position: relative;
  display: inline-block;
  margin-bottom: 1.5rem;
}

h2::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 50px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 2px;
}

p {
  margin-bottom: 1rem;
  color: var(--text-light);
}

/* Layout */
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

header {
  background: linear-gradient(135deg, var(--white), var(--gray-50));
  box-shadow: var(--shadow);
  padding: 1rem 2rem;
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

header h1 {
  margin-bottom: 0.5rem;
}

main {
  flex: 1;
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

footer {
  background: var(--text);
  color: var(--white);
  text-align: center;
  padding: 1.5rem;
  margin-top: auto;
}

/* Navigation */
nav {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

nav a {
  text-decoration: none;
  color: var(--text-light);
  font-weight: 500;
  padding: 0.5rem 0;
  position: relative;
  transition: var(--transition);
}

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

nav a.active {
  color: var(--primary);
  font-weight: 600;
}

nav a.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

/* Sections */
section {
  margin-bottom: 3rem;
  padding: 2rem;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: var(--transition);
}

section:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.intro {
  background: linear-gradient(135deg, var(--gray-50), var(--white));
  border-left: 4px solid var(--primary);
}

.announcements {
  border-left: 4px solid var(--accent);
}

/* Lists */
ul {
  list-style: none;
  padding-left: 0;
}

li {
  padding: 0.75rem 1rem;
  margin-bottom: 0.5rem;
  background: var(--gray-50);
  border-radius: var(--radius);
  border-left: 3px solid var(--primary);
  transition: var(--transition);
}

li:hover {
  background: var(--gray-100);
  transform: translateX(5px);
}

li strong {
  color: var(--primary);
}

/* Links */
a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
  font-weight: 500;
}

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

/* Announcements List */
#announcement-list li {
  animation: fadeIn 0.5s ease forwards;
  opacity: 0;
  transform: translateY(10px);
}

#announcement-list li:nth-child(1) { animation-delay: 0.1s; }
#announcement-list li:nth-child(2) { animation-delay: 0.2s; }
#announcement-list li:nth-child(3) { animation-delay: 0.3s; }

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  header {
    padding: 1rem;
  }
  
  main {
    padding: 1rem;
  }
  
  section {
    padding: 1.5rem;
  }
  
  h1 {
    font-size: 2rem;
  }
  
  h2 {
    font-size: 1.75rem;
  }
  
  nav {
    gap: 1rem;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 1.75rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
  
  section {
    padding: 1rem;
  }
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Focus styles for accessibility */
a:focus, button:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* Contributor highlight */
.contributors-list li:last-child {
  background: linear-gradient(135deg, var(--primary-light), var(--accent));
  color: var(--white);
  font-weight: 600;
  border-left: 3px solid var(--white);
}

.contributors-list li:last-child:hover {
  transform: scale(1.02);
}