:root {
  --white-bg: #ffffff;
  --light-bg: #f5f7fa;
  --code-bg: #1a1a2e;
  --code-text: #ffffff;
  --text-color: #1e293b;
  --highlight-color: #4361ee;
  --secondary-color: #3f37c9;
  --gray-text: #64748b;
  --border-color: #e2e8f0;
  --card-bg: #ffffff;
  --section-title: #e63946;
  --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --header-gradient: linear-gradient(135deg, #4361ee, #3a0ca3);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
}

body {
  background-color: var(--light-bg);
  color: var(--text-color);
  line-height: 1.6;
}

main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.header-container {
  background-image: var(--header-gradient);
  padding: 2.5rem 1rem;
  border-radius: 10px;
  margin-bottom: 1.5rem;
  text-align: center;
  box-shadow: var(--card-shadow);
}

.title {
  color: white;
  margin-bottom: 0.5rem;
  font-size: 2.5rem;
  font-weight: 700;
}

.subtitle {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 0.3rem;
  font-size: 1rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.subtitle a {
  color: #ffd700;
  text-decoration: none;
  font-weight: 600;
}

.subtitle a:hover {
  text-decoration: underline;
}

.cards-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 1.5rem;
}

.card {
  background-color: var(--card-bg);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--card-shadow);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: default;
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.25);
  cursor: pointer;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--section-title);
  margin-bottom: 0.3rem;
  font-size: 1.5rem;
  font-weight: bold;
}

.topic-name {
  color: red;
  font-weight: bold;
  margin-top: 1rem;
  margin-bottom: 0.3rem;
  font-size: 1rem;
}

pre {
  background-color: var(--code-bg);
  color: var(--code-text);
  padding: 1rem;
  border-radius: 8px;
  overflow-x: auto;
  margin: 0.2rem 0 0 0;
  font-family: "Consolas", "Monaco", monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  box-shadow: inset 0 1px 5px rgba(0, 0, 0, 0.2);
  white-space: pre-wrap;
  flex-grow: 1;
  user-select: text;
}

.footer {
  text-align: center;
  padding: 2rem 0;
  margin-top: 3rem;
  color: var(--gray-text);
  font-size: 0.9rem;
  border-top: 1px solid var(--border-color);
}

@media (max-width: 768px) {
  .cards-container {
    grid-template-columns: 1fr;
  }

  .title {
    font-size: 2rem;
  }
}

/* Updated Footer Styles - Horizontally Centered */
.footer {
  text-align: center;
  padding: 2rem 0;
  margin-top: 3rem;
  color: var(--gray-text);
  font-size: 0.9rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.footer p {
  margin: 0.5rem 0;
}

/* Floating Social Media Icons */
.social-icons-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 0;
  /* Removed width: 100% and background-color */
}

.social-icons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 20px;
}

.social-icons a {
  color: inherit;
  text-decoration: none;
  transition: transform 0.3s ease, color 0.3s ease;
  display: flex;
  justify-content: center;
  align-items: center;
}

.social-icons a:hover {
  transform: translateY(-5px);
  opacity: 0.8;
}

.social-icons a i {
  font-size: 2rem;
}

@media (max-width: 576px) {
  .social-icons {
    gap: 15px;
  }

  .social-icons a i {
    font-size: 1.5rem;
  }
}

@media (max-width: 375px) {
  .social-icons {
    gap: 10px;
  }

  .social-icons a i {
    font-size: 1.25rem;
  }
}