:root {
  --bg-url: url('/assets/desk.jpeg');
  --mbg-url: url('/assets/mob.jpeg');
  --bg-overlay: rgba(6, 2, 20, 0.5);
  --glass: rgba(10, 5, 30, 0.88);
  --glass-border: rgba(168, 85, 247, 0.25);
  --text: #e2e0f0;
  --text-muted: #8b7fb8;
  --neon-purple: #a855f7;
  --neon-pink: #ec4899;
  --neon-purple-glow: 0 0 8px rgba(168, 85, 247, 0.5), 0 0 20px rgba(168, 85, 247, 0.2);
  --neon-pink-glow: 0 0 8px rgba(236, 72, 153, 0.5), 0 0 20px rgba(236, 72, 153, 0.2);
  --accent: #a855f7;
  --accent-hover: #c084fc;
  --radius: 16px;
  --pill-radius: 999px;
}

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

html { height: 100%; }

body {
  font-family: system-ui, sans-serif;
  color: var(--text);
  height: 100dvh;
  overflow: hidden;
  background: var(--bg-url) no-repeat center center fixed;
  background-size: cover;
}

.page {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  height: 100%;
  padding: 0 1.5rem;
}

.card {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border-radius: var(--radius);
  box-shadow:
    0 0 30px rgba(168, 85, 247, 0.12),
    0 0 60px rgba(236, 72, 153, 0.06),
    0 4px 32px rgba(0, 0, 0, 0.6);
  text-align: center;
  min-width: 300px;
  max-width: 500px;
  width: 100%;
  margin-top: 40dvh;
  max-height: calc(100dvh - 40dvh - 2dvh);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ── Logo ── */

.card__logo {
  display: flex;
  justify-content: center;
  padding: 1.2rem 1.5rem 0.6rem;
  flex-shrink: 0;
}

.card__logo-img {
  height: 72px;
  width: 100%;
  max-width: 100%;
  object-fit: contain;
}

/* ── Title ── */

.card__title {
  color: var(--neon-purple);
  font-size: clamp(0.9rem, 3.5vw, 1rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  padding: 0.2rem 1rem 1rem;
  flex-shrink: 0;
  text-shadow: 0 0 12px rgba(168, 85, 247, 0.4);
}

/* ── List ── */

.list__items {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.5rem 1.5rem 1.5rem;
  scrollbar-width: thin;
  scrollbar-color: var(--neon-purple) transparent;
}

.list__items::-webkit-scrollbar {
  width: 5px;
}

.list__items::-webkit-scrollbar-track {
  background: rgba(168, 85, 247, 0.05);
  border-radius: 3px;
}

.list__items::-webkit-scrollbar-thumb {
  background: var(--neon-purple);
  border-radius: 3px;
  box-shadow: 0 0 6px rgba(168, 85, 247, 0.4);
}

/* ── List item (pill button) ── */

.list__item {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.5rem 1.5rem;
  background: rgba(168, 85, 247, 0.06);
  border: 1px solid rgba(168, 85, 247, 0.3);
  border-radius: var(--pill-radius);
  transition: background 0.25s, color 0.25s, border-color 0.25s, box-shadow 0.25s;
  animation: fadeIn 0.35s ease both;
}

.list__item:hover {
  background: rgba(168, 85, 247, 0.18);
  border-color: var(--neon-purple);
  box-shadow: var(--neon-purple-glow);
}

.list__item a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  font-size: clamp(0.85rem, 3.5vw, 0.95rem);
  display: block;
  width: 100%;
  letter-spacing: 0.04em;
  transition: color 0.25s, text-shadow 0.25s;
}

.list__item:hover a {
  color: #fff;
  text-shadow: 0 0 8px rgba(168, 85, 247, 0.5);
}

.list__item:focus-within {
  outline: 2px solid var(--neon-purple);
  outline-offset: -2px;
  box-shadow: var(--neon-purple-glow);
}

/* ── Empty state ── */

.list__empty {
  text-align: center;
  color: var(--text-muted);
  padding: 1.5rem 0;
  font-size: 0.9rem;
}

/* ── Animations ── */

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 8px rgba(168, 85, 247, 0.4), 0 0 20px rgba(168, 85, 247, 0.15); }
  50% { box-shadow: 0 0 14px rgba(236, 72, 153, 0.5), 0 0 30px rgba(236, 72, 153, 0.2); }
}

@media (prefers-reduced-motion: reduce) {
  .list__item { animation: none; transition: none; }
}

/* ── Mobile ── */

@media (max-width: 600px) {
  body {
    background: var(--mbg-url) no-repeat center center;
    background-size: cover;
    background-attachment: scroll;
  }

  .page {
    align-items: flex-end;
    padding: 0 1rem 1rem;
    padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  }

  .card {
    min-width: 260px;
    max-width: 96vw;
    margin-top: 0;
    max-height: calc(100dvh - 20dvh);
  }

  .card__logo { padding: 1rem 1rem 0.4rem; }
  .card__logo-img { height: 56px; }
  .list__items { padding: 0.5rem 1rem 1rem; overflow-y: scroll; }
}