:root {
  --bg:        #0a0a0f;
  --surface:   #10101a;
  --border:    #1e1e2e;
  --cyan:      #00e5ff;
  --violet:    #a855f7;
  --text:      #e2e8f0;
  --muted:     #64748b;
  --danger:    #f43f5e;
}

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  line-height: 1.7;
  min-height: 100vh;
  background-image:
    linear-gradient(rgba(0,229,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,229,255,0.02) 1px, transparent 1px);
  background-size: 40px 40px;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg, transparent, transparent 2px,
    rgba(0,0,0,0.08) 2px, rgba(0,0,0,0.08) 4px
  );
  pointer-events: none;
  z-index: 999;
}

a { color: var(--cyan); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrapper { max-width: 740px; margin: 0 auto; padding: 0 24px; }

/* HEADER */
header { border-bottom: 1px solid var(--border); padding: 48px 0 32px; margin-bottom: 56px; }
.header-inner { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-title {
  font-family: 'Syne', sans-serif;
  font-size: clamp(2rem, 6vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  background: linear-gradient(120deg, var(--cyan) 0%, var(--violet) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.site-sub {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 6px;
}
.site-sub .cursor {
  display: inline-block; width: 7px; height: 13px;
  background: var(--cyan); margin-left: 2px;
  vertical-align: middle; animation: blink 1.1s step-end infinite;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }

nav { display: flex; gap: 20px; font-family: 'JetBrains Mono', monospace; font-size: 12px; letter-spacing: 0.05em; }
nav a { color: var(--muted); transition: color 0.2s; }
nav a:hover, nav a.active { color: var(--cyan); text-decoration: none; }

/* TAGS */
.tag {
  display: inline-block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px; letter-spacing: 0.08em;
  padding: 3px 8px; border-radius: 3px;
  text-transform: uppercase; margin-right: 6px;
}
.tag-vent  { background: rgba(244,63,94,0.12);  color: var(--danger); border: 1px solid rgba(244,63,94,0.25); }
.tag-irl   { background: rgba(168,85,247,0.12); color: var(--violet); border: 1px solid rgba(168,85,247,0.25); }
.tag-life  { background: rgba(100,116,139,0.12);color: var(--muted);  border: 1px solid rgba(100,116,139,0.25); }
.tag-tech  { background: rgba(0,229,255,0.08);  color: var(--cyan);   border: 1px solid rgba(0,229,255,0.2); }

/* FEATURED */
.featured {
  background: var(--surface); border: 1px solid var(--border);
  border-left: 3px solid var(--danger); border-radius: 4px;
  padding: 28px 32px; margin-bottom: 56px; position: relative;
  cursor: pointer; transition: border-color 0.2s;
}
.featured:hover { border-color: var(--danger); }
.featured::before {
  content: 'pinned'; position: absolute; top: 12px; right: 16px;
  font-family: 'JetBrains Mono', monospace; font-size: 10px;
  letter-spacing: 0.1em; color: var(--danger); text-transform: uppercase;
}
.featured-label { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: var(--danger); text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 12px; }
.featured h2 { font-family: 'Syne', sans-serif; font-size: 1.5rem; font-weight: 700; color: var(--text); margin-bottom: 12px; line-height: 1.3; }
.featured p { color: var(--muted); font-size: 14px; margin-bottom: 20px; }

/* POST LIST */
.section-label { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 20px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.post-list { display: flex; flex-direction: column; }
.post-item { display: grid; grid-template-columns: 1fr auto; align-items: start; gap: 16px; padding: 20px 0; border-bottom: 1px solid var(--border); cursor: pointer; text-decoration: none; }
.post-item:hover .post-title { color: var(--cyan); }
.post-title { font-family: 'Syne', sans-serif; font-weight: 600; font-size: 1rem; color: var(--text); margin-bottom: 6px; transition: color 0.2s; line-height: 1.4; }
.post-excerpt { font-size: 13px; color: var(--muted); line-height: 1.6; }
.post-meta { font-family: 'JetBrains Mono', monospace; font-size: 10px; color: var(--muted); white-space: nowrap; padding-top: 4px; }

/* ABOUT CARD */
.about-card { background: var(--surface); border: 1px solid var(--border); border-radius: 4px; padding: 24px; margin-top: 48px; display: flex; gap: 20px; align-items: flex-start; }
.avatar { width: 52px; height: 52px; border-radius: 50%; background: linear-gradient(135deg, var(--cyan), var(--violet)); display: flex; align-items: center; justify-content: center; font-family: 'Syne', sans-serif; font-weight: 800; font-size: 1.2rem; color: #000; flex-shrink: 0; }
.about-card h3 { font-family: 'Syne', sans-serif; font-weight: 700; font-size: 0.95rem; margin-bottom: 6px; }
.about-card p { font-size: 13px; color: var(--muted); line-height: 1.6; }

/* POST PAGE */
.back-btn { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: var(--muted); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; margin-bottom: 36px; transition: color 0.2s; background: none; border: none; padding: 0; text-decoration: none; }
.back-btn:hover { color: var(--cyan); text-decoration: none; }
.post-full-title { font-family: 'Syne', sans-serif; font-size: clamp(1.6rem, 5vw, 2.4rem); font-weight: 800; letter-spacing: -0.02em; line-height: 1.2; margin-bottom: 16px; }
.post-full-meta { font-family: 'JetBrains Mono', monospace; font-size: 11px; color: var(--muted); margin-bottom: 36px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.post-full-meta .sep { color: var(--border); }
.post-body { font-size: 15px; line-height: 1.8; color: #cbd5e1; }
.post-body p { margin-bottom: 20px; }
.post-body h3 { font-family: 'Syne', sans-serif; font-weight: 700; font-size: 1.1rem; color: var(--text); margin: 32px 0 12px; }
.post-body ul { list-style: none; margin-bottom: 20px; padding-left: 0; }
.post-body ul li { padding: 4px 0 4px 20px; position: relative; font-size: 14px; }
.post-body ul li::before { content: '—'; position: absolute; left: 0; color: var(--cyan); font-family: 'JetBrains Mono', monospace; }
.post-body .callout { background: var(--surface); border-left: 3px solid var(--violet); border-radius: 0 4px 4px 0; padding: 16px 20px; margin: 24px 0; font-size: 14px; color: var(--muted); }
.post-body .callout.warn { border-left-color: var(--danger); }

/* CAT PHOTO PLACEHOLDER */
.cat-photo {
  width: 100%; aspect-ratio: 4/3; background: var(--surface);
  border: 1px dashed var(--border); border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'JetBrains Mono', monospace; font-size: 12px;
  color: var(--muted); margin: 28px 0; letter-spacing: 0.05em;
}

/* FOOTER */
footer { border-top: 1px solid var(--border); margin-top: 80px; padding: 32px 0 48px; font-family: 'JetBrains Mono', monospace; font-size: 11px; color: var(--muted); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
footer span.accent { color: var(--cyan); }

@media (max-width: 600px) {
  .header-inner { flex-direction: column; align-items: flex-start; }
  .post-item { grid-template-columns: 1fr; }
  .post-meta { display: none; }
  .about-card { flex-direction: column; }
}

/* ── ENTER OVERLAY ── */
#enter-overlay {
  position: fixed; inset: 0; z-index: 2000;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  background-image:
    linear-gradient(rgba(0,229,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,229,255,0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  transition: opacity 0.6s ease;
}
#enter-overlay.fade-out { opacity: 0; pointer-events: none; }

#enter-box {
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}

#enter-title {
  font-family: 'Syne', sans-serif;
  font-size: clamp(2.4rem, 8vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(120deg, var(--cyan) 0%, var(--violet) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { filter: brightness(1); }
  50%       { filter: brightness(1.3); }
}

#enter-sub {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

#enter-btn {
  margin-top: 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  letter-spacing: 0.1em;
  color: var(--cyan);
  background: transparent;
  border: 1px solid var(--cyan);
  padding: 12px 32px;
  border-radius: 3px;
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s;
}
#enter-btn:hover {
  background: rgba(0,229,255,0.08);
  box-shadow: 0 0 20px rgba(0,229,255,0.2);
}

#enter-hint {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.06em;
}

/* ── MUSIC PLAYER BAR ── */
#music-player {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(10,10,15,0.94);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  padding: 10px 24px;
  display: flex;
  align-items: center;
  gap: 14px;
}

#music-player .play-btn {
  background: none;
  border: 1px solid var(--cyan);
  color: var(--cyan);
  width: 30px; height: 30px;
  border-radius: 50%;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; flex-shrink: 0;
  transition: background 0.2s;
}
#music-player .play-btn:hover { background: rgba(0,229,255,0.1); }

#music-player .song-info {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  flex-shrink: 0;
  max-width: 220px;
  line-height: 1.6;
}
#music-player .song-info span {
  color: var(--cyan);
  display: block;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
#music-player .song-info .credit {
  color: #3a3a5a;
  font-size: 9px;
  display: block;
  text-transform: none;
  letter-spacing: 0;
}

#music-player .progress-wrap {
  flex: 1; display: flex; align-items: center; gap: 10px; min-width: 0;
}

#music-player .progress-bar {
  flex: 1; height: 3px; background: var(--border);
  border-radius: 2px; cursor: pointer; position: relative;
}
#music-player .progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  border-radius: 2px; width: 0%;
  transition: width 0.1s linear;
  pointer-events: none;
}

#music-player .time {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px; color: var(--muted); white-space: nowrap; flex-shrink: 0;
}

#music-player .vol-btn {
  background: none; border: none; color: var(--muted);
  cursor: pointer; font-size: 13px; flex-shrink: 0;
  transition: color 0.2s; padding: 0;
}
#music-player .vol-btn:hover { color: var(--cyan); }

body { padding-bottom: 58px; }

@media (max-width: 500px) {
  #music-player .song-info { max-width: 120px; }
  #music-player .time { display: none; }
}
