:root {
  color-scheme: dark;
  --bg: #080808;
  --panel: #101010;
  --border: #252525;
  --text: #f4f4f4;
  --muted: #858585;
  --red: #f04444;
}

* { box-sizing: border-box; }
html { background: var(--bg); scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }

.topbar {
  min-height: 66px;
  padding: 0 6%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--border);
}
.logo { font-weight: 900; font-size: 19px; letter-spacing: 2px; }
.logo span { color: var(--red); }
.live { color: var(--muted); font-size: 10px; letter-spacing: 1.3px; }
.live i {
  display: inline-block; width: 6px; height: 6px; margin-right: 6px;
  border-radius: 50%; background: #56d991;
}
.hero {
  text-align: center;
  padding: 85px 20px 55px;
  border-bottom: 1px solid var(--border);
  background: radial-gradient(ellipse at 50% 0%, #231010 0%, var(--bg) 55%);
}
.eyebrow { color: var(--red); font-size: 10px; font-weight: 800; letter-spacing: 2.5px; }
h1 {
  margin: 24px 0;
  font-size: clamp(55px, 10vw, 105px);
  line-height: .94;
  letter-spacing: -6px;
  font-weight: 900;
}
h1 span { color: var(--red); }
.subtitle { max-width: 410px; margin: 0 auto 30px; color: var(--muted); line-height: 1.8; font-size: 14px; }
.searchbox {
  width: min(100%, 540px); min-height: 58px; margin: auto; padding: 6px;
  display: flex; align-items: center; gap: 12px;
  border: 1px solid #383838; background: #0c0c0c; border-radius: 9px;
}
.search-icon { padding-left: 10px; font-size: 26px; color: var(--muted); }
.searchbox input { min-width: 0; flex: 1; padding: 12px 0; color: white; background: transparent; border: 0; outline: none; }
.searchbox input:focus-visible { outline: 1px solid #555; outline-offset: 4px; }
.searchbox button {
  padding: 12px 19px; border: 0; border-radius: 5px;
  background: var(--red); color: white; font-weight: 800; font-size: 11px;
}
.quick-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.secondary { padding: 10px 13px; border: 1px solid var(--border); border-radius: 6px; background: #101010; color: #ccc; font-size: 12px; }
.secondary:hover, .profile-card:hover { border-color: #555; }
.notice { min-height: 20px; margin-top: 18px; color: var(--muted); font-size: 11px; overflow-wrap: anywhere; }
.directory { width: min(1100px, 90%); margin: auto; padding: 48px 0 30px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 15px; margin-bottom: 25px; }
.section-heading h2 { margin: 8px 0 0; font-size: clamp(23px, 4vw, 32px); letter-spacing: -1px; }
.counter { color: var(--muted); font-size: 10px; white-space: nowrap; }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.profile-card {
  min-width: 0; min-height: 158px; padding: 17px; text-align: left;
  border: 1px solid var(--border); border-radius: 8px; background: var(--panel);
  transition: border-color .15s; overflow-wrap: anywhere; color: var(--text);
}
.avatar {
  width: 43px; height: 43px; display: grid; place-items: center; margin-bottom: 20px;
  border: 1px solid #383838; border-radius: 7px; background: #191919;
  color: var(--red); font-size: 18px; font-weight: 900;
}
.profile-name { margin: 0 0 6px; font-size: 14px; font-weight: 750; }
.profile-id { margin: 0; color: var(--muted); font-size: 10px; }
.profile-bio { margin: 12px 0 0; color: #b4b4b4; font-size: 11px; line-height: 1.6; }
.loader { display: flex; justify-content: center; align-items: center; gap: 10px; padding: 25px 0; color: var(--muted); font-size: 11px; }
.loader span { width: 12px; height: 12px; border: 2px solid #444; border-top-color: var(--red); border-radius: 50%; animation: spin .7s linear infinite; }
.loader[hidden] { display: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.more { width: 100%; padding: 15px; border: 1px solid #333; border-radius: 7px; background: #111; color: white; font-weight: 700; }
.more:hover { border-color: var(--red); }
.footer-note { padding: 30px 0 5px; color: #555; text-align: center; font-size: 9px; letter-spacing: 2px; }

.profile-dialog {
  width: min(480px, calc(100% - 28px)); padding: 30px;
  border: 1px solid #383838; border-radius: 12px;
  background: #101010; color: white;
}
.profile-dialog::backdrop { background: rgb(0 0 0 / 80%); }
.close { float: right; border: 0; background: transparent; color: #aaa; font-size: 28px; }
.detail-avatar { width: 66px; height: 66px; display: grid; place-items: center; margin: 24px 0 20px; border: 1px solid #444; border-radius: 10px; color: var(--red); font-size: 26px; font-weight: 900; }
.detail-name { font-size: 27px; margin: 0 0 8px; overflow-wrap: anywhere; }
.detail-id { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.detail-bio { line-height: 1.8; color: #ccc; }
.copy-link { display: inline-block; margin-top: 10px; padding: 11px 14px; border-radius: 6px; background: var(--red); color: white; border: 0; }

@media (max-width: 700px) {
  .hero { padding-top: 65px; }
  h1 { letter-spacing: -3px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .profile-card { padding: 13px; min-height: 150px; }
  .directory { width: 92%; padding-top: 35px; }
}
@media (max-width: 360px) {
  .live { font-size: 8px; letter-spacing: .5px; }
  .grid { grid-template-columns: 1fr; }
  .searchbox { gap: 7px; }
  .searchbox button { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
