:root {
  --bg: #0e1116;
  --panel: #161b22;
  --border: #2d333b;
  --text: #e6edf3;
  --muted: #8b949e;
  --accent: #58a6ff;
  --badge-bg: #1f6feb33;
  --badge-text: #79c0ff;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.5;
}

header {
  padding: 2rem 1.5rem 1rem;
  max-width: 980px;
  margin: 0 auto;
}

h1 { margin: 0 0 0.25rem; font-size: 1.75rem; }
.subtitle { margin: 0; color: var(--muted); font-size: 0.9rem; }

.discord-cta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.25rem 0 0;
  padding: 0.9rem 1.05rem;
  background: linear-gradient(135deg, #3b4577 0%, #4b3f6b 100%);
  border: 1px solid #5865f244;
  border-radius: 10px;
  color: #e6edf3;
  text-decoration: none;
  transition: transform 0.18s ease, border-color 0.18s ease;
  position: relative;
  overflow: hidden;
}
.discord-cta:hover {
  transform: translateY(-1px);
  border-color: #7a85ff77;
}
.discord-cta__icon {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  color: #c7d2fe;
}
.discord-cta__text {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.discord-cta__title {
  font-weight: 700;
  font-size: 0.98rem;
  line-height: 1.25;
  letter-spacing: 0.01em;
}
.discord-cta__subtitle {
  font-size: 0.78rem;
  opacity: 0.85;
  margin-top: 0.15rem;
}
.discord-cta__button {
  flex: 0 0 auto;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.18);
  color: #e6edf3;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 500;
  white-space: nowrap;
  transition: background 0.18s ease;
}
.discord-cta:hover .discord-cta__button {
  background: rgba(255,255,255,0.15);
}
@media (max-width: 560px) {
  .discord-cta { flex-wrap: wrap; }
  .discord-cta__button { width: 100%; text-align: center; margin-top: 0.25rem; }
}

.filters {
  max-width: 980px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.chip {
  background: var(--panel);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  cursor: pointer;
  font-size: 0.85rem;
}
.chip:hover { border-color: var(--accent); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #0d1117; font-weight: 600; }

main {
  max-width: 980px;
  margin: 0 auto;
  padding: 1rem 1.5rem 1.5rem;
  display: grid;
  gap: 0.9rem;
}

.card {
  --accent-color: #7aa2f7;
  position: relative;
  background: #161b22;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.1rem 1.35rem 1.15rem 1.5rem;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--accent-color);
  opacity: 0.55;
  border-radius: 10px 0 0 10px;
}

.card:hover {
  transform: translateY(-1px);
  border-color: color-mix(in srgb, var(--accent-color) 40%, var(--border));
  box-shadow: 0 6px 16px -10px rgba(0, 0, 0, 0.5);
}
.card:hover::before { opacity: 0.85; }

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.55rem;
  font-size: 0.78rem;
  gap: 0.75rem;
}

.badge {
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.015em;
  white-space: nowrap;
}

.card-header time {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  font-size: 0.78rem;
}

.card h2 {
  margin: 0 0 0.55rem;
  font-size: 1.08rem;
  line-height: 1.4;
  font-weight: 600;
  letter-spacing: -0.005em;
}

.card h2 a {
  color: var(--text);
  text-decoration: none;
  background-image: linear-gradient(var(--accent-color), var(--accent-color));
  background-position: 0 100%;
  background-repeat: no-repeat;
  background-size: 0% 1.5px;
  transition: background-size 0.25s ease;
}
.card h2 a:hover { background-size: 100% 1.5px; }

.summary {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

.empty {
  max-width: 980px;
  margin: 1rem auto;
  padding: 1.5rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.95rem;
}

.pagination {
  max-width: 980px;
  margin: 0 auto;
  padding: 0.5rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.35rem;
}

#pagination-top { padding-top: 1rem; }
#pagination-bottom { padding-bottom: 1.25rem; }

.pag-btn {
  background: var(--panel);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.4rem 0.75rem;
  border-radius: 8px;
  font-size: 0.85rem;
  cursor: pointer;
  min-width: 2.25rem;
  font-variant-numeric: tabular-nums;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.pag-btn:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
}
.pag-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.pag-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #0d1117;
  font-weight: 700;
}
.pag-nav { font-weight: 500; }
.pag-ellipsis {
  color: var(--muted);
  padding: 0 0.25rem;
  user-select: none;
}

footer {
  max-width: 980px;
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
  color: var(--muted);
  font-size: 0.8rem;
  border-top: 1px solid var(--border);
  margin-top: 2rem;
}
footer a { color: var(--muted); }
footer a:hover { color: var(--accent); }
.credit {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--border);
  text-align: center;
  font-size: 0.85rem;
}
.credit a { font-weight: 600; }
