@import url('https://fonts.googleapis.com/css2?family=Kode+Mono:wght@400;700&display=swap');

:root {
  --bg: #000000;
  --text: #ffffff;
  --muted: #a1a1a1;
  --muted-2: #71717b;
  --border: rgba(255, 255, 255, 0.08);
  --border-soft: rgba(255, 255, 255, 0.05);
  --card: rgba(255, 255, 255, 0.02);
  --card-2: rgba(24, 24, 27, 0.5);
  --rose: #ff3b6b;
  --pink: #ff8fb1;
  --grad: linear-gradient(90deg, #ff3b6b, #ff8fb1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Kode Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  font-weight: 400;
}

a { color: inherit; text-decoration: none; }

/* background aurora */
.aurora { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.aurora::before, .aurora::after {
  content: ""; position: absolute; width: 60vw; height: 60vw;
  border-radius: 50%; filter: blur(120px); opacity: 0.16;
}
.aurora::before { background: #ff3b6b; top: -12%; left: -10%; }
.aurora::after { background: #ff8fb1; bottom: -12%; right: -10%; }
.bg-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.5); pointer-events: none; z-index: 0; }

/* desktop side nav */
.side-nav {
  position: fixed; left: 24px; top: 50%; transform: translateY(-50%);
  z-index: 50; display: none; flex-direction: column; gap: 16px;
}
@media (min-width: 768px) { .side-nav { display: flex; } }

.nav-brand { display: flex; align-items: center; gap: 8px; }
.nav-brand img {
  width: 20px; height: 20px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2); object-fit: cover;
}
.nav-brand span {
  font-size: 12px; font-weight: 300; letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.6); max-width: 80px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.nav-item {
  display: flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 300; letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.4); transition: all 0.2s;
}
.nav-line { height: 1px; width: 8px; background: rgba(255, 255, 255, 0.4); transition: all 0.2s; }
.nav-item:hover { color: rgba(255, 255, 255, 0.7); }
.nav-item:hover .nav-line { width: 12px; background: rgba(255, 255, 255, 0.7); }
.nav-item.active { color: #fff; }
.nav-item.active .nav-line { width: 16px; background: var(--grad); }

/* mobile bottom nav */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 50;
  border-top: 1px solid var(--border-soft); background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(12px); display: flex; justify-content: space-around;
  padding: 12px 8px; gap: 8px;
}
@media (min-width: 768px) { .bottom-nav { display: none; } }
.bottom-nav a {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  font-size: 10px; font-weight: 300; letter-spacing: 0.1em; color: rgba(255, 255, 255, 0.4);
}
.bottom-nav a.active { color: #fff; }
.bottom-nav img {
  width: 24px; height: 24px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2); object-fit: cover;
}

/* page layout */
.page {
  position: relative; z-index: 10; min-height: 100vh; display: flex;
  justify-content: center; padding: 64px 24px 96px; align-items: flex-start;
}
.page--center { align-items: center; }
@media (min-width: 640px) { .page { padding: 96px 24px 64px; } }
.container {
  width: 100%; max-width: 56rem; display: flex; flex-direction: column; gap: 32px;
  padding: 0 20px;
}

/* reveal animation */
.reveal { opacity: 0; transform: translateY(14px); animation: reveal 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
@keyframes reveal { to { opacity: 1; transform: none; } }

.section-head {
  display: flex; align-items: center; gap: 8px; font-size: 12px;
  font-weight: 300; letter-spacing: 0.1em; color: rgba(255, 255, 255, 0.6);
}
.section-head .line { height: 1px; width: 16px; background: rgba(255, 255, 255, 0.4); }
.page-title { font-size: 30px; font-weight: 700; letter-spacing: -0.02em; color: #fff; }
.lead { color: rgba(255, 255, 255, 0.6); font-size: 14px; line-height: 1.6; max-width: 85%; }
.link { color: rgba(255, 255, 255, 0.9); font-weight: 500; }
.link:hover { color: #fff; }

/* hero */
.hero { display: flex; flex-direction: column-reverse; align-items: center; gap: 16px; }
@media (min-width: 640px) { .hero { flex-direction: row; justify-content: space-between; } }
.hero-text { display: flex; flex-direction: column; gap: 4px; align-items: center; text-align: center; }
@media (min-width: 640px) { .hero-text { align-items: flex-start; text-align: left; } }
.hero h1 { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; color: #fff; }
@media (min-width: 640px) { .hero h1 { font-size: 36px; } }
.hero .sub { font-size: 14px; color: rgba(255, 255, 255, 0.5); line-height: 1.5; }
@media (min-width: 640px) { .hero .sub { font-size: 18px; } }
.cursor {
  display: inline-block; width: 10px; height: 1em; background: var(--grad);
  margin-left: 4px; vertical-align: -2px; animation: blink 1s steps(2) infinite;
}
@keyframes blink { 0%, 50% { opacity: 1; } 51%, 100% { opacity: 0; } }

.socials { display: flex; gap: 12px; margin-top: 8px; }
.socials a {
  width: 24px; height: 24px; display: grid; place-items: center;
  background: #d4d4d8; transition: background 0.2s, transform 0.2s; border-radius: 4px;
}
.socials a:hover { background: #fff; transform: translateY(-2px); }
.socials svg { width: 14px; height: 14px; fill: #000; }

.socials.lg { gap: 16px; margin-top: 12px; }
.socials.lg a { width: 36px; height: 36px; border-radius: 8px; }
.socials.lg svg { width: 20px; height: 20px; }

/* avatar decorations + status + now playing */
.avatar-wrap { position: relative; display: inline-block; flex-shrink: 0; }
.avatar-wrap .avatar-deco {
  position: absolute; top: 50%; left: 50%; width: 156%; height: 156%;
  transform: translate(-50%, -50%); pointer-events: none; z-index: 3;
  display: none;
}
.avatar-wrap.nav { width: 20px; height: 20px; }
.avatar-wrap.nav .avatar-deco { width: 180%; height: 180%; }
.avatar-wrap.nav .avatar { width: 20px; height: 20px; }

.status { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 13px; color: rgba(255, 255, 255, 0.7); }
.status-dot { width: 9px; height: 9px; border-radius: 999px; background: #747f8d; flex-shrink: 0; box-shadow: 0 0 8px currentColor; }
.status-dot.online { background: #3ba55d; color: #3ba55d; }
.status-dot.idle { background: #faa61a; color: #faa61a; }
.status-dot.dnd { background: #ed4245; color: #ed4245; }
.status-dot.offline { background: #747f8d; color: #747f8d; }

.nowplaying {
  display: flex; align-items: center; gap: 10px; margin-top: 10px;
  background: var(--card); border: 1px solid var(--border); border-radius: 10px;
  padding: 8px 10px; max-width: 320px;
}
.nowplaying .np-art { width: 38px; height: 38px; border-radius: 6px; object-fit: cover; flex-shrink: 0; background: #27272a; }
.nowplaying .np-meta { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.nowplaying .np-title { font-size: 13px; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nowplaying .np-artist { font-size: 11px; color: rgba(255, 255, 255, 0.5); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 12px; margin-right: 6px; }
.np-eq span { width: 3px; background: var(--grad); border-radius: 2px; animation: eq 0.9s ease-in-out infinite; }
.np-eq span:nth-child(2) { animation-delay: 0.2s; }
.np-eq span:nth-child(3) { animation-delay: 0.4s; }
@keyframes eq { 0%, 100% { height: 4px; } 50% { height: 12px; } }

.avatar {
  border-radius: 999px; overflow: hidden; flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero .avatar { width: 80px; height: 80px; }
@media (min-width: 640px) { .hero .avatar { width: 96px; height: 96px; } }

/* project cards */
.cards { display: flex; flex-direction: column; gap: 8px; }
.project {
  display: flex; align-items: center; gap: 12px; background: var(--card);
  backdrop-filter: blur(4px); border: 1px solid var(--border); border-radius: 8px;
  padding: 14px; transition: all 0.2s; position: relative; overflow: hidden;
}
.project:hover { border-color: rgba(255, 255, 255, 0.15); }
.project .thumb {
  width: 56px; height: 56px; border-radius: 14px; flex-shrink: 0;
  display: grid; place-items: center; overflow: hidden;
  color: var(--accent-soft); font-weight: 700;
}
.project .pbody { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.project .prow { display: flex; flex-direction: column; }
@media (min-width: 640px) { .project .prow { flex-direction: row; align-items: center; justify-content: space-between; gap: 8px; } }
.project .ptitle { font-size: 13px; font-weight: 500; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.project .pmeta { font-size: 10px; color: rgba(255, 255, 255, 0.5); }
.project .pdesc { font-size: 12px; color: rgba(255, 255, 255, 0.6); }

/* github stats */
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 640px) { .stats-grid { grid-template-columns: repeat(4, 1fr); } }
.stat {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  border: 1px solid #27272a; border-radius: 8px; background: var(--card-2); padding: 8px 12px;
}
.stat .num { font-size: 18px; font-weight: 700; color: #fff; }
.stat .lbl { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-2); }

/* top languages */
.lang-list { display: flex; flex-direction: column; gap: 12px; }
.lang-row { display: flex; align-items: center; gap: 8px; }
.lang-dot { width: 10px; height: 10px; border-radius: 999px; background: var(--grad); flex-shrink: 0; }
.lang-name { font-size: 12px; color: rgba(255, 255, 255, 0.8); width: 64px; }
.lang-bar { flex: 1; height: 8px; border-radius: 999px; background: #27272a; overflow: hidden; }
.lang-fill { height: 100%; background: var(--grad); border-radius: 999px; }
.lang-pct { font-size: 12px; color: rgba(255, 255, 255, 0.6); width: 40px; text-align: right; }

/* skills pills */
.pills { display: flex; flex-wrap: wrap; gap: 10px; }
.pill {
  display: flex; align-items: center; gap: 8px; border: 1px solid #27272a;
  background: var(--card-2); padding: 6px 12px; border-radius: 8px;
  font-size: 12px; color: #d4d4d8; transition: all 0.2s;
}
.pill:hover { background: rgba(255, 59, 107, 0.12); border-color: rgba(255, 59, 107, 0.4); color: #fff; }
.pill svg, .pill img { width: 18px; height: 18px; display: block; }

/* project thumb with logo */
.project .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* github icon + commit graph */
.gh-head { display: flex; align-items: center; gap: 10px; }
.gh-head svg { width: 22px; height: 22px; fill: #fff; }
.contrib { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; overflow-x: auto; padding-bottom: 4px; }
.contrib-months { display: flex; justify-content: space-between; font-size: 10px; color: rgba(255, 255, 255, 0.4); }
.contrib-grid { display: grid; grid-auto-flow: column; grid-template-rows: repeat(7, 11px); gap: 3px; width: max-content; }
.contrib-cell { width: 11px; height: 11px; border-radius: 2px; background: #18181b; }
.contrib-cell.l1 { background: rgba(255, 59, 107, 0.3); }
.contrib-cell.l2 { background: rgba(255, 59, 107, 0.5); }
.contrib-cell.l3 { background: rgba(255, 59, 107, 0.75); }
.contrib-cell.l4 { background: #ff3b6b; }
.contrib-legend { display: flex; align-items: center; gap: 4px; font-size: 10px; color: rgba(255, 255, 255, 0.4); justify-content: flex-end; margin-top: 4px; }
.contrib-legend .contrib-cell { width: 10px; height: 10px; }

/* music list rows */
.music-tabs { display: flex; gap: 4px; padding: 4px; border-radius: 8px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border-soft); width: fit-content; margin-bottom: 12px; }
.music-tab { padding: 4px 12px; border-radius: 6px; font-size: 12px; font-weight: 500; color: rgba(255, 255, 255, 0.4); transition: all 0.2s; cursor: pointer; }
.music-tab.active { background: rgba(255, 255, 255, 0.08); color: #fff; }
.music-tab:hover { color: rgba(255, 255, 255, 0.6); }
.music-list { display: flex; flex-direction: column; gap: 6px; }
.music-row { display: flex; align-items: center; gap: 10px; background: var(--card); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; }
.music-row .rank { font-size: 12px; color: rgba(255, 255, 255, 0.4); width: 16px; text-align: center; flex-shrink: 0; }
.music-row .mthumb { width: 36px; height: 36px; border-radius: 6px; flex-shrink: 0; object-fit: cover; background: #27272a; }
.music-row .mbody { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.music-row .mtitle { font-size: 13px; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.music-row .msub { font-size: 11px; color: rgba(255, 255, 255, 0.5); }
.music-empty { color: rgba(255, 255, 255, 0.5); font-size: 13px; padding: 12px 4px; }
.token-box { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.token-box input { flex: 1; min-width: 200px; background: var(--card-2); border: 1px solid #27272a; border-radius: 8px; padding: 8px 10px; color: #fff; font-family: inherit; font-size: 12px; }
.token-box button { background: var(--grad); border: 0; border-radius: 8px; padding: 8px 14px; color: #fff; font-family: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }

.empty {
  border: 1px dashed var(--border); border-radius: 12px; padding: 28px;
  color: rgba(255, 255, 255, 0.5); text-align: center; font-size: 13px;
}

/* music */
.spotify-link {
  display: inline-flex; align-items: center; gap: 8px; font-size: 12px;
  color: rgba(255, 255, 255, 0.9); border: 1px solid #27272a; background: var(--card-2);
  padding: 8px 12px; border-radius: 8px; transition: all 0.2s; margin-top: 4px;
}
.spotify-link:hover { background: rgba(255, 59, 107, 0.12); border-color: rgba(255, 59, 107, 0.4); }

.spotify-card {
  display: flex; align-items: center; gap: 16px; background: var(--card);
  backdrop-filter: blur(4px); border: 1px solid var(--border); border-radius: 12px;
  padding: 16px; margin-top: 12px;
}
.spotify-card .sc-icon {
  width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0; display: grid;
  place-items: center; background: var(--grad); color: #fff; object-fit: cover;
}
.spotify-card .sc-icon svg { width: 26px; height: 26px; fill: #fff; }
.spotify-card .sc-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.spotify-card .sc-name { font-size: 15px; font-weight: 700; color: #fff; }
.spotify-card .sc-sub { font-size: 12px; color: rgba(255, 255, 255, 0.5); }
