:root {
  --bg-color: #0f172a;
  --card-bg: rgba(30, 41, 59, 0.7);
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --accent-color: #3b82f6;
  --accent-glow: rgba(59, 130, 246, 0.5);
  --border-color: rgba(255, 255, 255, 0.1);
}

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

body {
  font-family: 'Inter', -apple-system, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-primary);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Dynamic Background */
.background-elements {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.blob {
  position: absolute;
  filter: blur(80px);
  opacity: 0.5;
  border-radius: 50%;
  animation: float 10s infinite alternate ease-in-out;
}
.blob-1 {
  width: 400px; height: 400px;
  background: #3b82f6;
  top: -100px; left: -100px;
}
.blob-2 {
  width: 300px; height: 300px;
  background: #8b5cf6;
  bottom: 10%; right: -50px;
  animation-delay: -5s;
}

@keyframes float {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(50px, 50px) scale(1.1); }
}

/* Navbar */
.navbar {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border-color);
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.logo {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 1px;
}
.logo span {
  color: var(--accent-color);
}
.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  margin-left: 2rem;
  font-weight: 500;
  transition: color 0.3s;
}
.nav-links a:hover, .nav-links a.active {
  color: var(--text-primary);
}

/* Hero */
.hero {
  text-align: center;
  padding: 5rem 2rem;
}
.hero h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  background: linear-gradient(to right, #60a5fa, #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero p {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* Grid */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem 5rem;
}
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

/* Card */
.info-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  backdrop-filter: blur(10px);
  transition: transform 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
}
.info-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.5), 0 0 15px var(--accent-glow);
}
.card-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}
.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.tag {
  background: rgba(59, 130, 246, 0.2);
  color: #60a5fa;
  padding: 0.25rem 0.75rem;
  border-radius: 99px;
  font-size: 0.75rem;
  font-weight: 500;
}
.card-desc {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 1.5rem;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-secondary);
  border-top: 1px solid var(--border-color);
  padding-top: 1rem;
}

/* Skeleton */
.skeleton-card {
  height: 250px;
  background: var(--card-bg);
  border-radius: 16px;
  animation: pulse 1.5s infinite;
}
@keyframes pulse {
  0% { opacity: 0.6; }
  50% { opacity: 0.3; }
  100% { opacity: 0.6; }
}

/* Modal Styling */
.modal {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.modal.show {
  opacity: 1;
  pointer-events: auto;
}
.modal-content {
  background: rgba(30, 41, 59, 0.85);
  border: 1px solid var(--border-color);
  box-shadow: 0 20px 50px rgba(0,0,0,0.5), 0 0 30px var(--accent-glow);
  width: 600px;
  max-width: 90%;
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: translateY(20px);
  transition: transform 0.3s ease;
}
.modal.show .modal-content {
  transform: translateY(0);
}
.modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(15, 23, 42, 0.4);
}
.modal-header h3 {
  font-size: 1.1rem;
  color: var(--text-primary);
  font-weight: 600;
}
.close-btn {
  background: none;
  border: none;
  font-size: 1.75rem;
  cursor: pointer;
  color: var(--text-secondary);
  transition: color 0.2s;
}
.close-btn:hover {
  color: #ef4444;
}
.modal-body {
  padding: 2rem;
  max-height: 60vh;
  overflow-y: auto;
}
.modal-body h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-primary);
}
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
}
.detail-meta span {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}
.detail-desc {
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.6;
  white-space: pre-wrap;
  background: rgba(15, 23, 42, 0.3);
  border: 1px solid var(--border-color);
  padding: 1rem 1.25rem;
  border-radius: 12px;
}
.modal-footer {
  padding: 1.25rem 2rem;
  border-top: 1px solid var(--border-color);
  background: rgba(15, 23, 42, 0.4);
  display: flex;
  justify-content: flex-end;
}
.primary-btn {
  background: var(--accent-color);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.2s;
  box-shadow: 0 4px 10px rgba(59, 130, 246, 0.3);
}
.primary-btn:hover {
  background: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 6px 15px rgba(59, 130, 246, 0.4);
}
.primary-btn:active {
  transform: translateY(0);
}

.hidden {
  display: none !important;
}

/* Make card titles hover clickable */
.info-card {
  cursor: pointer;
}
.info-card .card-title {
  transition: color 0.2s;
}
.info-card:hover .card-title {
  color: var(--accent-color);
}

