
:root {
  color-scheme: dark;
  --bg: #08090d;
  --panel: #0e1118;
  --panel-2: #121620;
  --border: #2a3040;
  --border-bright: #43547e;
  --text: #f1f3f8;
  --muted: #929bad;
  --blue: #4169e1;
  --purple: #7451b9;
  --green: #52c98c;
  --red: #e36a7a;
  --width: 960px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.55;
}

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

.main { min-height: calc(100vh - 70px); }
.section { padding: 64px 0; }

.container {
  width: min(calc(100% - 28px), var(--width));
  margin-inline: auto;
}

.hero { padding-top: 82px; }
.hero-content { text-align: center; }

.hero-pfp {
  width: 118px;
  height: 118px;
  border: 1px solid var(--border);
  border-radius: 8px;
  object-fit: cover;
}

.hero h2 {
  margin: 18px 0 7px;
  font-size: clamp(44px, 9vw, 72px);
  line-height: 1;
  letter-spacing: -4px;
}

.hero-content p {
  max-width: 610px;
  margin: 0 auto;
  color: var(--muted);
}

.hero-about,
.now-playing,
.contact-link,
.loading-spinner,
.notice,
.anilist-profile,
.anilist-stat,
.anime-card,
.spotify-login-box,
.track-row,
.blog-card,
.article {
  border: 1px solid var(--border);
  border-radius: 3px;
  background: var(--panel);
}

.hero-about {
  max-width: 690px;
  margin: 30px auto 0;
  padding: 15px 18px;
  color: var(--muted);
  text-align: center;
}

.hero-about a {
  color: #8ea8ff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.now-playing {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  max-width: 690px;
  margin: 10px auto 0;
  padding: 13px;
}

.now-playing-cover {
  width: 66px;
  height: 66px;
  border-radius: 2px;
  object-fit: cover;
}

.now-playing-info {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.now-playing-label,
.eyebrow {
  color: #8ea8ff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.now-playing-track {
  overflow: hidden;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.now-playing-artist {
  color: var(--muted);
  font-size: 13px;
}

.now-playing-link {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 2px;
  color: #8ea8ff;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 7px;
  margin-top: 15px;
}

.hero-link,
.action-button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  padding: 8px 13px;
  border: 1px solid var(--blue);
  border-radius: 2px;
  background: var(--blue);
  color: white;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.hero-link.secondary,
.action-button.secondary {
  border-color: var(--border);
  background: var(--panel);
  color: var(--muted);
}

.hero-link:hover,
.action-button:hover {
  border-color: #7893ef;
  color: white;
}

.back-to-home {
  position: fixed;
  top: 28px;
  left: 32px;
  z-index: 100;
  width: auto;
  margin: 0;
  padding: 0;
  pointer-events: none;
}

.back-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  pointer-events: auto;
}

.back-button:hover {
  color: #ffffff;
}

.page-heading { margin-bottom: 22px; }

.page-heading h1 {
  margin: 4px 0 5px;
  font-size: clamp(38px, 7vw, 62px);
  line-height: 1;
  letter-spacing: -3px;
}

.page-heading p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
}

.full-page-contacts,
.project-list,
.music-list,
.blog-list {
  display: grid;
  gap: 7px;
}

.contact-link {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 13px;
  min-height: 78px;
  padding: 12px 14px;
}

.contact-link:hover {
  border-color: var(--border-bright);
  background: var(--panel-2);
}

.contact-link svg,
.contact-icon {
  width: 29px;
  height: 29px;
}

.contact-text {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.contact-text > span {
  font-size: 15px;
  font-weight: 700;
}

.project-description,
.contact-url,
.small-text {
  color: var(--muted);
  font-size: 12px;
}

.contact-url { text-align: right; }

.copy-link {
  width: 100%;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.loading-spinner,
.notice {
  padding: 20px;
  color: var(--muted);
  text-align: center;
}

.notice.error {
  border-color: #6d333d;
  color: #ff9caa;
}

.notice.success {
  border-color: #2e6248;
  color: #8ce3b7;
}

.project-card {
  grid-template-columns: 34px minmax(0, 1fr) 145px;
}

.project-meta {
  display: grid;
  justify-items: end;
  gap: 2px;
  color: var(--muted);
  font-size: 11px;
}

.project-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 5px;
}

.project-stat {
  color: var(--muted);
  font-size: 11px;
}

.project-language { color: #8ea8ff; }

.anilist-stats {
  display: grid;
  gap: 12px;
}

.anilist-profile { overflow: hidden; }

.anilist-banner {
  height: 190px;
  background: linear-gradient(120deg, #264db9, #68439d);
  background-size: cover;
  background-position: center;
}

.anilist-profile-main {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  padding: 0 14px 14px;
  margin-top: -45px;
}

.anilist-avatar {
  width: 92px;
  height: 92px;
  border: 4px solid var(--panel);
  border-radius: 3px;
  object-fit: cover;
}

.anilist-profile-main h2 {
  margin: 0;
  font-size: 24px;
}

.anilist-profile-main a {
  color: #8ea8ff;
  font-size: 12px;
  text-decoration: underline;
}

.anilist-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 7px;
}

.anilist-stat { padding: 14px; }

.anilist-stat strong {
  display: block;
  font-size: 23px;
}

.anilist-stat span {
  color: var(--muted);
  font-size: 11px;
}

.anilist-section-title {
  margin: 22px 0 9px;
  font-size: 18px;
}

.anime-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 7px;
}

.anime-card { overflow: hidden; }

.anime-card:hover { border-color: var(--border-bright); }

.anime-card img {
  display: block;
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
}

.anime-card-info { padding: 8px; }

.anime-card-title {
  display: -webkit-box;
  overflow: hidden;
  font-size: 12px;
  font-weight: 700;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.anime-card-meta {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.spotify-login-box {
  display: grid;
  gap: 11px;
  padding: 18px;
}

.spotify-login-box h2,
.spotify-login-box p { margin: 0; }

.spotify-login-box p {
  color: var(--muted);
  font-size: 13px;
}

.music-status { margin: 10px 0; }

.track-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 10px;
}

.track-cover {
  width: 64px;
  height: 64px;
  border-radius: 2px;
  object-fit: cover;
  background: var(--panel-2);
}

.track-name { font-weight: 700; }

.track-artist,
.track-album,
.track-time {
  color: var(--muted);
  font-size: 12px;
}

.track-open {
  padding: 7px 9px;
  border: 1px solid var(--border);
  border-radius: 2px;
  color: #8ea8ff;
  font-size: 12px;
}

.progress {
  height: 4px;
  margin-top: 7px;
  background: #202635;
}

.progress-fill {
  height: 100%;
  background: var(--blue);
}

.section-label {
  margin: 28px 0 9px;
  font-size: 18px;
}

.blog-card { padding: 14px; }

.blog-card:hover {
  border-color: var(--border-bright);
  background: var(--panel-2);
}

.blog-card h2 {
  margin: 2px 0;
  font-size: 18px;
}

.blog-date,
.blog-card p {
  color: var(--muted);
  font-size: 12px;
}

.article {
  max-width: 740px;
  padding: 18px;
}

.article h1 {
  margin-top: 3px;
  font-size: 38px;
}

.footer {
  padding: 24px 0;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

#particles {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

@media (max-width: 720px) {
  .back-to-home {
    top: 18px;
    left: 14px;
  }

  .section { padding: 48px 0; }
  .hero { padding-top: 58px; }

  .hero h2,
  .page-heading h1 { letter-spacing: -2px; }

  .now-playing,
  .track-row {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .now-playing-link,
  .track-open {
    grid-column: 1 / -1;
  }

  .contact-link,
  .project-card {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .contact-url,
  .project-meta {
    grid-column: 2;
    justify-items: start;
    text-align: left;
  }

  .anilist-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .anime-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
