:root {
  color-scheme: dark;
  --ink: #101528;
  --surface: rgba(28, 35, 67, 0.86);
  --text: #f5f7ff;
  --muted: #bac3e4;
  --line: rgba(203, 215, 255, 0.18);
  --cyan: #5cd4ff;
  --purple: #a58bff;
  --green: #63e6a7;
  --shadow: 0 20px 55px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 10% -10%, rgba(92, 212, 255, 0.22), transparent 30rem),
    radial-gradient(circle at 90% 5%, rgba(165, 139, 255, 0.2), transparent 28rem),
    var(--ink);
}

a { color: inherit; }

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(1180px, calc(100% - 32px));
  min-height: 82px;
  margin: 0 auto;
}

.brand, .main-nav { display: flex; align-items: center; }
.brand { gap: 10px; color: var(--text); font-weight: 800; text-decoration: none; letter-spacing: 0.02em; }
.brand img { width: 45px; height: 45px; object-fit: contain; }
.main-nav { flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.main-nav a { padding: 9px 12px; border-radius: 9px; color: var(--muted); font-size: 0.9rem; font-weight: 650; text-decoration: none; }
.main-nav a:hover, .main-nav a:focus-visible, .main-nav .is-active { color: var(--text); background: rgba(255, 255, 255, 0.1); outline: none; }

main { width: min(1180px, calc(100% - 32px)); margin: 0 auto 56px; }
.hero { padding: clamp(34px, 7vw, 76px) clamp(20px, 6vw, 74px); overflow: hidden; border: 1px solid var(--line); border-radius: 24px; background: linear-gradient(125deg, rgba(47, 58, 109, 0.94), rgba(23, 29, 57, 0.92)); box-shadow: var(--shadow); }
.eyebrow { margin: 0 0 10px; color: var(--cyan); font-size: 0.74rem; font-weight: 800; letter-spacing: 0.13em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1 { max-width: 720px; margin-bottom: 16px; font-size: clamp(2.1rem, 5vw, 4.45rem); line-height: 0.97; letter-spacing: -0.055em; }
.hero-copy { max-width: 600px; margin-bottom: 36px; color: var(--muted); font-size: clamp(1rem, 2vw, 1.14rem); line-height: 1.55; }

.stats { display: flex; flex-wrap: wrap; gap: 10px; }
.stat-card { display: grid; gap: 2px; min-width: 128px; padding: 13px 16px; border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 13px; background: rgba(11, 16, 35, 0.35); }
.stat-card-wide { min-width: 178px; }
.stat-card strong { color: var(--text); font-size: 1.3rem; }
.stat-card span { color: var(--muted); font-size: 0.78rem; }

.directory { padding-top: 52px; }
.directory-header { display: flex; justify-content: space-between; align-items: end; gap: 18px; margin-bottom: 20px; }
.directory h2 { margin-bottom: 0; font-size: clamp(1.5rem, 3vw, 2rem); letter-spacing: -0.035em; }
.result-count { margin: 0; color: var(--muted); font-size: 0.9rem; white-space: nowrap; }
.filters { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.search-field { flex: 1 1 340px; display: grid; gap: 7px; color: var(--muted); font-size: 0.82rem; font-weight: 700; }
.search-field input { width: 100%; min-height: 46px; border: 1px solid var(--line); border-radius: 11px; padding: 0 14px; color: var(--text); background: var(--surface); font: inherit; }
.search-field input:focus { border-color: var(--cyan); outline: 3px solid rgba(92, 212, 255, 0.18); }
.live-filter { align-self: end; min-height: 46px; padding: 0 17px; border: 1px solid rgba(99, 230, 167, 0.3); border-radius: 11px; color: var(--green); background: rgba(99, 230, 167, 0.08); font: inherit; font-size: 0.88rem; font-weight: 800; cursor: pointer; }
.live-filter:hover, .live-filter:focus-visible, .live-filter.is-active { border-color: var(--green); background: rgba(99, 230, 167, 0.18); outline: none; }

.streamer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 16px; }
.streamer-card { display: flex; flex-direction: column; min-height: 352px; overflow: hidden; border: 1px solid var(--line); border-radius: 16px; color: var(--text); background: var(--surface); box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2); text-decoration: none; transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease; }
.streamer-card:hover, .streamer-card:focus-visible { transform: translateY(-4px); border-color: rgba(92, 212, 255, 0.75); box-shadow: var(--shadow); outline: none; }
.streamer-card.is-live { border-color: rgba(99, 230, 167, 0.5); }
.streamer-media { position: relative; display: grid; min-height: 156px; place-items: center; overflow: hidden; background: linear-gradient(135deg, #293963, #161d39); }
.streamer-media img { width: 100%; height: 100%; position: absolute; inset: 0; object-fit: cover; }
.streamer-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, rgba(9, 13, 29, 0.72)); pointer-events: none; }
.streamer-media.is-offline { background: linear-gradient(135deg, #2a3152, #151a30); }
.offline-message, .preview-message { color: var(--muted); font-size: 0.9rem; font-weight: 750; }
.status { position: absolute; z-index: 1; top: 11px; left: 11px; padding: 6px 9px; border: 1px solid rgba(255, 255, 255, 0.18); border-radius: 999px; color: #d7ddf7; background: rgba(11, 16, 35, 0.76); font-size: 0.72rem; font-weight: 850; }
.status-live { border-color: rgba(99, 230, 167, 0.45); color: #c7ffe1; }
.streamer-body { display: flex; flex: 1; flex-direction: column; padding: 17px; }
.streamer-name { margin-bottom: 7px; font-size: 1.18rem; letter-spacing: -0.025em; }
.objective-name { min-height: 2.6em; margin-bottom: 9px; color: #dce2fa; font-size: 0.86rem; line-height: 1.35; }
.amount-line { margin-bottom: 10px; color: var(--muted); font-size: 0.82rem; }
.progress { height: 7px; overflow: hidden; border-radius: 999px; background: rgba(255, 255, 255, 0.13); }
.progress-value { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--cyan), var(--purple)); }
.card-footer { display: flex; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 15px; color: var(--muted); font-size: 0.73rem; font-weight: 700; }
.watch-link { color: var(--cyan); white-space: nowrap; }
.loading-message, .empty-state { grid-column: 1 / -1; margin: 0; padding: 42px 24px; border: 1px dashed var(--line); border-radius: 16px; color: var(--muted); text-align: center; }
.empty-state h3 { margin-bottom: 8px; color: var(--text); }
.empty-state p { margin-bottom: 0; }
.site-footer { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; width: min(1180px, calc(100% - 32px)); margin: 0 auto; padding: 25px 0 35px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.82rem; }
.site-footer a { color: inherit; text-decoration: none; }
.site-footer a:hover, .site-footer a:focus-visible { color: var(--cyan); }

@media (max-width: 700px) {
  .site-header { flex-direction: column; justify-content: center; padding: 18px 0; }
  .main-nav { justify-content: center; }
  .hero { border-radius: 18px; }
  .directory { padding-top: 36px; }
  .directory-header { align-items: start; flex-direction: column; }
  .live-filter { width: 100%; }
}

@media (max-width: 430px) {
  main, .site-header, .site-footer { width: min(100% - 24px, 1180px); }
  .main-nav a { padding: 8px; font-size: 0.8rem; }
  .stats { display: grid; grid-template-columns: 1fr 1fr; }
  .stat-card, .stat-card-wide { min-width: 0; }
  .stat-card-wide { grid-column: 1 / -1; }
}
