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

:root {
  --bg: #0e0e0e;
  --fg: #b0b0b0;
  --fg-dim: #606060;
  --fg-bright: #d4d4d4;
  --accent: #8a9a7b;
  --surface: #161616;
  --border: #252525;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: "Iosevka", "JetBrains Mono", "Fira Code", "SF Mono", "Cascadia Code", ui-monospace, "DejaVu Sans Mono", "Liberation Mono", Menlo, Consolas, monospace;
  font-size: 0.925rem;
  line-height: 1.65;
  padding: 2.5rem 1.5rem;
  width: 60%;
  margin: 0 auto;
}

nav {
  margin-bottom: 3rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

nav a {
  margin-right: 1.4rem;
}

nav a.active {
  color: var(--fg-bright);
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

h1 {
  color: var(--fg-bright);
  font-size: 1.1rem;
  font-weight: normal;
  margin-bottom: 1.5rem;
}

h2 {
  color: var(--fg-bright);
  font-size: 1rem;
  font-weight: normal;
  margin-top: 2.5rem;
  margin-bottom: 0.8rem;
}

h3 {
  color: var(--fg);
  font-size: 0.925rem;
  font-weight: normal;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

p {
  margin-bottom: 1rem;
}

ul, ol {
  padding-left: 1.2rem;
  margin-bottom: 1rem;
}

li {
  margin-bottom: 0.3rem;
}

li::marker {
  color: var(--fg-dim);
}

pre {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1rem;
  overflow-x: auto;
  margin-bottom: 1rem;
  font-size: 0.85rem;
  line-height: 1.5;
}

code {
  font-family: inherit;
  font-size: 0.9em;
}

p code {
  background: var(--surface);
  padding: 0.15rem 0.35rem;
}

hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

.ascii {
  color: var(--fg-dim);
  line-height: 1.2;
  margin-bottom: 1.5rem;
  user-select: none;
}

.dim {
  color: var(--fg-dim);
}

.bright {
  color: var(--fg-bright);
}

.greeting {
  margin-bottom: 2rem;
}

.note-list {
  list-style: none;
  padding-left: 0;
}

.note-list li {
  margin-bottom: 0.5rem;
}

.note-list .date {
  color: var(--fg-dim);
  display: inline-block;
  min-width: 6.5rem;
}

.spec-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
}

.spec-table td {
  padding: 0.3rem 0;
  vertical-align: top;
}

.spec-table td:first-child {
  color: var(--fg-dim);
  width: 9rem;
  padding-right: 1rem;
}

.likes-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-top: 1rem;
}

.likes-items {
  list-style: none;
  padding-left: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 1rem;
}

.likes-items li {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.4rem;
  margin-bottom: 0;
}

.likes-items img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border: 1px solid var(--border);
  background: var(--surface);
  display: block;
}

.likes-items.poster {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

.likes-items.poster img {
  width: 200px;
  height: 90px;
  aspect-ratio: 2.22;
}

.likes-items.album {
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
}

.likes-items.album img {
  width: 140px;
  height: 140px;
}

.likes-items.cover {
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
}

.likes-items.cover img {
  width: 120px;
  height: 180px;
  aspect-ratio: 2 / 3;
}

.likes-items span {
  font-size: 0.85rem;
  color: var(--fg-dim);
  line-height: 1.3;
}

.note-meta {
  color: var(--fg-dim);
  margin-bottom: 2rem;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.5rem;
  margin-top: 1rem;
  margin-bottom: 2rem;
}

.media-grid img,
.media-grid video {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border: 1px solid var(--border);
  display: block;
}

.media-grid .embed-wrap {
  height: 180px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.media-grid .embed-wrap iframe {
  width: 100%;
  height: 100%;
  border: none;
}

@media (max-width: 768px) {
  body {
    width: 90%;
    padding: 1.5rem 1rem;
    font-size: 0.875rem;
  }

  nav {
    margin-bottom: 2rem;
  }

  nav a {
    margin-right: 1rem;
  }

  .spec-table td:first-child {
    width: 7rem;
  }
}
