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

body {
  font-family: "Poppins", sans-serif;
  background: #faf9f5;
  min-height: 100vh;
  color: #404040;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px 40px;
}

/* ── Header / Hero ── */
header {
  text-align: center;
  margin-bottom: 40px;
  background: linear-gradient(
    135deg,
    #2b346b 0%,
    #7b2d8e 35%,
    #c2185b 70%,
    #ed5d60 100%
  );
  padding: 50px 40px;
  color: #fff;
}

.header-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 24px;
}

.header-logo img {
  height: 48px;
  width: auto;
}

.header-logo span {
  font-size: 1.4em;
  font-weight: 600;
  letter-spacing: 0.02em;
}

h1 {
  font-size: 2.6em;
  font-weight: 600;
  color: #fff;
  margin-bottom: 10px;
}

.subtitle {
  font-size: 1.1em;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 24px;
  font-weight: 300;
}

.stats {
  display: flex;
  justify-content: center;
  gap: 50px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.stat {
  text-align: center;
}

.stat-number {
  font-size: 2.2em;
  font-weight: 700;
  color: #fff;
}

.stat-label {
  font-size: 0.9em;
  color: rgba(255, 255, 255, 0.75);
  margin-top: 4px;
  font-weight: 300;
}

/* ── Table of Contents ── */
.toc {
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  margin-bottom: 40px;
  box-shadow: 0 2px 12px rgba(43, 52, 107, 0.08);
}

.toc h2 {
  font-size: 1.4em;
  font-weight: 600;
  margin-bottom: 20px;
  color: #2b346b;
  border-bottom: 3px solid #2b346b;
  padding-bottom: 10px;
}

.toc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 12px;
}

.toc-item {
  display: flex;
  align-items: center;
  padding: 12px 14px;
  background: #f3f1fb;
  border-radius: 8px;
  text-decoration: none;
  color: #2b346b;
  transition: all 0.25s ease;
  border-left: 4px solid #7b2d8e;
}

.toc-item:hover {
  background: #e8e4f5;
  transform: translateX(5px);
}

.toc-item-text {
  flex: 1;
  font-weight: 500;
  font-size: 0.95em;
}

.toc-item-count {
  background: linear-gradient(135deg, #7b2d8e, #c2185b);
  color: #fff;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.8em;
  font-weight: 600;
}

/* ── Category Sections ── */
.category-section {
  background: #fff;
  padding: 30px;
  margin-bottom: 28px;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(43, 52, 107, 0.08);
}

.category-header {
  font-size: 1.6em;
  font-weight: 600;
  color: #2b346b;
  margin-bottom: 24px;
  padding-bottom: 14px;
  border-bottom: 3px solid #2b346b;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.category-count {
  font-size: 0.55em;
  font-weight: 600;
  background: linear-gradient(135deg, #2b346b, #7b2d8e);
  color: #fff;
  padding: 5px 16px;
  border-radius: 20px;
}

/* ── Link Cards ── */
.links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
}

.link-card {
  padding: 14px 16px;
  background: #faf9f5;
  border-radius: 8px;
  border-left: 4px solid #7b2d8e;
  transition: all 0.25s ease;
}

.link-card:hover {
  background: #f3f1fb;
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(123, 45, 142, 0.12);
}

.link-card a {
  text-decoration: none;
  color: #2b346b;
  font-weight: 500;
  font-size: 0.93em;
  display: block;
  word-break: break-word;
}

.link-card a:hover {
  color: #7b2d8e;
  text-decoration: underline;
}

.link-title {
  margin-bottom: 4px;
}

.link-url {
  font-size: 0.72em;
  color: #999;
  word-break: break-all;
  font-family: "Monaco", "Courier New", monospace;
}

/* ── Footer ── */
footer {
  text-align: center;
  padding: 36px 30px;
  background: #2b346b;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9em;
  margin-top: 40px;
  border-radius: 12px;
}

footer p {
  margin: 5px 0;
}

footer a {
  color: #ed5d60;
  text-decoration: none;
  font-weight: 500;
}

footer a:hover {
  text-decoration: underline;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  h1 {
    font-size: 1.8em;
  }

  header {
    padding: 30px 20px;
  }

  .stats {
    gap: 24px;
  }

  .links-grid {
    grid-template-columns: 1fr;
  }

  .toc-grid {
    grid-template-columns: 1fr;
  }

  .category-section {
    padding: 20px;
  }
}
