:root {
  --bg: #f7f9fc;
  --card: #ffffff;
  --text: #0f172a;
  --muted: #5f6b7a;
  --accent: #3b82f6;
  --accent-2: #a855f7;
  --border: #e5e7eb;
  --shadow: 0 20px 60px rgba(15, 23, 42, 0.08);
  --radius: 18px;
  --transition: 220ms ease;
}

[data-theme="dark"] {
  --bg: #0f172a;
  --card: #1e293b;
  --text: #f1f5f9;
  --muted: #94a3b8;
  --accent: #60a5fa;
  --accent-2: #a78bfa;
  --border: #334155;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

a {
  text-decoration: none;
  color: inherit;
}

.gradient-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(900px circle at 15% 20%, rgba(59, 130, 246, 0.18), transparent 50%),
    radial-gradient(850px circle at 80% 0%, rgba(168, 85, 247, 0.16), transparent 50%),
    radial-gradient(700px circle at 70% 80%, rgba(16, 185, 129, 0.12), transparent 45%),
    var(--bg);
  animation: float 18s ease-in-out infinite alternate;
  filter: saturate(120%);
  transition: background var(--transition);
}

[data-theme="dark"] .gradient-bg {
  background:
    radial-gradient(900px circle at 15% 20%, rgba(59, 130, 246, 0.12), transparent 50%),
    radial-gradient(850px circle at 80% 0%, rgba(168, 85, 247, 0.10), transparent 50%),
    radial-gradient(700px circle at 70% 80%, rgba(16, 185, 129, 0.08), transparent 45%),
    var(--bg);
  filter: saturate(100%);
}

@keyframes float {
  from { transform: translateY(0px) scale(1); }
  to { transform: translateY(12px) scale(1.01); }
}

header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(12px);
  background: rgba(247, 249, 252, 0.85);
  border-bottom: 1px solid rgba(229, 231, 235, 0.6);
  z-index: 20;
  transition: background var(--transition), border-color var(--transition);
}

[data-theme="dark"] header {
  background: rgba(15, 23, 42, 0.85);
  border-bottom-color: rgba(51, 65, 85, 0.6);
}

.nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--text);
}

.brand img {
  height: 36px;
  width: auto;
  border-radius: 10px;
  box-shadow: none;
  background: transparent;
  mix-blend-mode: multiply;
  transition: filter var(--transition);
}

[data-theme="dark"] .brand img {
  mix-blend-mode: normal;
  filter: brightness(1.1);
}

.brand span {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.1;
}

nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 0;
}

.nav-item {
  position: relative;
}

.nav-link {
  padding: 10px 14px;
  border-radius: 12px;
  color: var(--text);
  font-weight: 600;
  transition: background var(--transition), transform var(--transition);
}

.nav-link:hover {
  background: rgba(59, 130, 246, 0.12);
  transform: translateY(-1px);
}

.dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 8px;
  display: none;
  flex-direction: column;
  gap: 6px;
  animation: fadeIn 160ms ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.nav-item:hover .dropdown {
  display: flex;
}

.dropdown a {
  padding: 10px 12px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  transition: background var(--transition), color var(--transition);
}

.dropdown a:hover {
  background: rgba(59, 130, 246, 0.08);
  color: var(--text);
}

main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 20px 80px;
}

.hero {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 28px 28px 24px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.hero::after {
  content: "";
  position: absolute;
  inset: -60px;
  background:
    radial-gradient(600px circle at 20% 0%, rgba(59, 130, 246, 0.12), transparent 40%),
    radial-gradient(700px circle at 90% 10%, rgba(168, 85, 247, 0.14), transparent 40%);
  opacity: 0.9;
  z-index: -1;
}

.hero h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 40px);
  letter-spacing: -0.6px;
}

.hero p {
  margin: 0;
  max-width: 720px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}

.hero-actions {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--muted);
  font-weight: 600;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}

.pill strong {
  color: var(--text);
}

.pill:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px rgba(59, 130, 246, 0.14);
}

.sections {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.apv-sections {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.apv-sections .card {
  width: 100%;
}

.apv-sections ul {
  padding-left: 20px;
}

.apv-sections ul ul {
  padding-left: 18px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 60px rgba(59, 130, 246, 0.14);
}

.card table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 8px;
}

.card th,
.card td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  font-size: 14px;
}

.card th {
  font-weight: 700;
  color: var(--text);
  background: rgba(59, 130, 246, 0.05);
}

.card tr:last-child td {
  border-bottom: none;
}

.card h2, .card h3 {
  margin: 0;
  letter-spacing: -0.3px;
}

.card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

form {
  display: grid;
  gap: 10px;
}

label {
  font-weight: 600;
  color: var(--text);
  font-size: 14px;
  display: grid;
  gap: 4px;
}

input, textarea, select {
  width: 100%;
  padding: 12px 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--card);
  font-family: inherit;
  font-size: 14px;
  color: var(--text);
  transition: border var(--transition), box-shadow var(--transition), transform var(--transition), background var(--transition);
}

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.16);
  transform: translateY(-1px);
}

textarea {
  resize: vertical;
  min-height: 110px;
}

button {
  border: none;
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 700;
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  color: #fff;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 16px 32px rgba(59, 130, 246, 0.24);
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 44px rgba(59, 130, 246, 0.28);
}

button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.status {
  font-size: 14px;
  color: var(--muted);
  min-height: 20px;
}

.status.success { color: #16a34a; }
.status.error { color: #dc2626; }

footer {
  max-width: 1200px;
  margin: 40px auto 60px;
  padding: 0 20px;
  color: var(--muted);
  text-align: center;
  font-size: 14px;
}

/* Cookie Popup */
.cookie-popup {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10000;
  padding: 20px;
  transform: translateY(100%);
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

.cookie-popup.show {
  transform: translateY(0);
  opacity: 1;
  pointer-events: all;
}

.cookie-popup-content {
  max-width: 1200px;
  margin: 0 auto;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.15);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

[data-theme="dark"] .cookie-popup-content {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.cookie-popup-content p {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  flex: 1;
  min-width: 250px;
}

.cookie-accept-btn {
  background: var(--accent);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
  font-family: inherit;
}

.cookie-accept-btn:hover {
  background: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.cookie-accept-btn:active {
  transform: translateY(0);
}

@media (max-width: 600px) {
  .cookie-popup {
    padding: 16px;
  }
  
  .cookie-popup-content {
    flex-direction: column;
    align-items: stretch;
    padding: 18px 20px;
  }
  
  .cookie-popup-content p {
    min-width: auto;
    margin-bottom: 4px;
  }
  
  .cookie-accept-btn {
    width: 100%;
  }
}

.cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cta-buttons a {
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--card);
  font-weight: 700;
  color: var(--text);
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}

.cta-buttons a:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(59, 130, 246, 0.18);
}

/* Dark Mode Toggle */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  transition: all var(--transition);
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.theme-toggle:hover {
  background: rgba(59, 130, 246, 0.12);
  border-color: var(--accent);
  transform: translateY(-1px);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  transition: transform var(--transition), opacity var(--transition);
}

.theme-toggle .sun-icon {
  position: absolute;
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

.theme-toggle .moon-icon {
  position: absolute;
  opacity: 0;
  transform: rotate(90deg) scale(0);
}

[data-theme="dark"] .theme-toggle .sun-icon {
  opacity: 0;
  transform: rotate(90deg) scale(0);
}

[data-theme="dark"] .theme-toggle .moon-icon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

/* Search Functionality */
.search-container {
  margin-top: 32px;
  margin-bottom: 24px;
  position: sticky;
  top: 80px;
  z-index: 10;
}

.search-box {
  position: relative;
  width: 100%;
}

.search-input {
  width: 100%;
  padding: 14px 48px 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  transition: all var(--transition);
  box-shadow: var(--shadow);
}

.search-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.16), var(--shadow);
  transform: translateY(-1px);
}

.search-input::placeholder {
  color: var(--muted);
}

.search-icon {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--muted);
  pointer-events: none;
}

.search-results {
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
  min-height: 20px;
  position: relative;
  z-index: 1;
}

.search-highlight {
  background: rgba(59, 130, 246, 0.2);
  padding: 2px 4px;
  border-radius: 4px;
  font-weight: 600;
  color: var(--accent);
}

[data-theme="dark"] .search-highlight {
  background: rgba(96, 165, 250, 0.25);
  color: var(--accent);
}

.search-no-results {
  padding: 20px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}

.card.hidden {
  display: none;
}

@media (max-width: 800px) {
  .nav {
    flex-direction: column;
    align-items: flex-start;
  }
  nav ul {
    width: 100%;
    flex-wrap: wrap;
    gap: 6px;
  }
  .dropdown {
    position: static;
    display: none;
    box-shadow: none;
    border: none;
    padding-left: 12px;
  }
  .nav-item:hover .dropdown {
    display: flex;
  }
  
  .search-container {
    top: 100px;
  }
  
  .theme-toggle {
    width: 36px;
    height: 36px;
  }
  
  .theme-toggle svg {
    width: 18px;
    height: 18px;
  }
}

/* Discord Widget Styles */
.discord-widget {
  margin-top: 16px;
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  background: var(--card);
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
}

.discord-widget:hover {
  transform: translateY(-3px);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.15);
}

.discord-widget-loading {
  padding: 60px 20px;
  text-align: center;
  color: var(--text);
}

.loading-spinner {
  width: 40px;
  height: 40px;
  margin: 0 auto 16px;
  border: 4px solid rgba(0, 0, 0, 0.1);
  border-top-color: var(--text);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.discord-widget-header {
  background: rgba(0, 0, 0, 0.03);
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.discord-widget-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.discord-logo-img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
}

.discord-widget-title {
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
  margin: 0;
}

.discord-widget-members {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

.discord-widget-members::before {
  content: '';
  width: 8px;
  height: 8px;
  background: #57f287;
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 8px rgba(87, 242, 135, 0.6);
}

.discord-widget-content {
  background: transparent;
  padding: 24px;
  max-height: 420px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.discord-widget-notice {
  padding: 14px 18px;
  background: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: 10px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.6;
  margin-bottom: 20px;
}

.discord-widget-notice strong {
  color: #d97706;
  font-weight: 700;
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
}

.discord-widget-channels {
  flex: 1;
}

.discord-widget-section-title {
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

.discord-channels-grid {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.discord-channel {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  transition: all var(--transition);
  cursor: pointer;
  position: relative;
  background: rgba(0, 0, 0, 0.02);
}

.discord-channel:hover {
  background: rgba(0, 0, 0, 0.05);
  transform: translateX(4px);
  color: var(--text);
}

.discord-channel-voice {
  opacity: 0.9;
}

.discord-channel-icon {
  font-size: 18px;
  opacity: 0.9;
  flex-shrink: 0;
}

.discord-channel-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.discord-channel-badge {
  font-size: 10px;
  color: var(--text);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 2px 8px;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 4px;
  flex-shrink: 0;
  opacity: 0.7;
}

.discord-members-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
}

.discord-member {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: rgba(0, 0, 0, 0.02);
  border-radius: 10px;
  transition: all var(--transition);
  cursor: pointer;
}

.discord-member:hover {
  background: rgba(0, 0, 0, 0.05);
  transform: translateX(4px);
}

.discord-member-avatar-wrapper {
  position: relative;
  flex-shrink: 0;
}

.discord-member-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border);
  display: block;
}

.discord-member-status {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2.5px solid var(--card);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
}

.discord-member-status.online {
  background: #57f287;
  box-shadow: 0 0 8px rgba(87, 242, 135, 0.6);
}

.discord-member-status.idle {
  background: #fee75c;
  box-shadow: 0 0 8px rgba(254, 231, 92, 0.6);
}

.discord-member-status.dnd {
  background: #ed4245;
  box-shadow: 0 0 8px rgba(237, 66, 69, 0.6);
}

.discord-member-info {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.discord-member-name {
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  margin: 0 0 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.discord-member-game {
  color: var(--muted);
  font-size: 11px;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.discord-widget-footer {
  padding: 20px 24px;
  background: rgba(0, 0, 0, 0.02);
  text-align: center;
  border-top: 1px solid var(--border);
}

.discord-join-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 28px;
  background: var(--card);
  color: var(--text);
  border: 2px solid var(--border);
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  transition: all var(--transition);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  width: 100%;
  max-width: 300px;
}

.discord-join-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  background: rgba(0, 0, 0, 0.02);
  border-color: var(--accent);
  color: var(--accent);
}

.discord-widget-error {
  padding: 40px 20px;
  text-align: center;
  color: var(--text);
}

.discord-widget-error p {
  margin: 0;
  color: var(--muted);
}

/* Scrollbar styling voor Discord widget */
.discord-widget-content::-webkit-scrollbar {
  width: 10px;
}

.discord-widget-content::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 5px;
}

.discord-widget-content::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 5px;
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.discord-widget-content::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.3);
}

@media (max-width: 600px) {
  .discord-members-grid {
    grid-template-columns: 1fr;
  }
  
  .discord-widget-content {
    padding: 20px;
  }
  
  .discord-widget-header {
    padding: 16px 20px;
  }
  
  .discord-widget-footer {
    padding: 16px 20px;
  }
}

