/* =====================
   BASE & RESET
   ===================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: sans-serif;
  background: #f5f5f5;
  color: #222;
  line-height: 1.6;
}

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

/* =====================
   SITE WRAPPER
   ===================== */
.site-wrapper {
  max-width: 780px;
  margin: 0 auto;
  padding: 24px 16px;
}

/* =====================
   HEADER
   ===================== */
header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background: #ddd;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.header-text {
  flex: 1;
}

.header-text h1 {
  font-size: 1.4rem;
  font-weight: 700;
}

.header-text p {
  font-size: 0.9rem;
  color: #666;
  margin-top: 2px;
}

.online-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: #4caf50;
  white-space: nowrap;
}

.online-badge::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4caf50;
}

/* =====================
   TAB NAVIGATION
   ===================== */
.tabs {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid #ddd;
  margin-bottom: 24px;
}

.tab {
  padding: 8px 18px;
  border-radius: 6px 6px 0 0;
  font-size: 0.9rem;
  font-weight: 500;
  color: #666;
  transition: background 0.15s, color 0.15s;
}

.tab:hover {
  background: #eee;
  color: #222;
}

.tab.active {
  background: #222;
  color: #fff;
}

/* =====================
   FOOTER
   ===================== */
footer {
  margin-top: 48px;
  text-align: center;
  font-size: 0.8rem;
  color: #aaa;
  padding-top: 16px;
  border-top: 1px solid #ddd;
}

/* =====================
   index.html — 나 위키
   ===================== */
.wiki-section {
  margin-bottom: 28px;
}

.section-title {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #999;
  margin-bottom: 10px;
}

.info-row {
  display: flex;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
  font-size: 0.95rem;
}

.info-label {
  width: 100px;
  flex-shrink: 0;
  color: #888;
  font-size: 0.85rem;
}

.info-value {
  flex: 1;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-block;
  padding: 4px 12px;
  background: #eee;
  border-radius: 999px;
  font-size: 0.85rem;
  color: #444;
}

/* =====================
   playlist.html — 플레이리스트
   ===================== */
.playlist-container {
  /* wrapper */
}

.playlist-header {
  margin-bottom: 20px;
}

.playlist-header h2 {
  font-size: 1.2rem;
  font-weight: 700;
}

.playlist-header p {
  font-size: 0.9rem;
  color: #666;
  margin-top: 4px;
}

.track {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}

.track-num {
  width: 24px;
  text-align: right;
  font-size: 0.85rem;
  color: #aaa;
  flex-shrink: 0;
}

.track-art {
  width: 44px;
  height: 44px;
  background: #ddd;
  border-radius: 4px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  overflow: hidden;
}

.track-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.track-info {
  flex: 1;
  min-width: 0;
}

.track-name {
  font-size: 0.95rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.track-artist {
  font-size: 0.82rem;
  color: #888;
  margin-top: 2px;
}

.track-mood {
  font-size: 0.75rem;
  padding: 3px 10px;
  border-radius: 999px;
  background: #eee;
  color: #555;
  flex-shrink: 0;
}

[data-mood="chill"]   { background: #d0eaff; color: #2a6fa8; }
[data-mood="cozy"]    { background: #ffe8cc; color: #a05a00; }
[data-mood="dreamy"]  { background: #ead9ff; color: #7040b0; }
[data-mood="hype"]    { background: #ffd6d6; color: #c0392b; }
[data-mood="focus"]   { background: #d4f5e9; color: #1a7a4a; }

/* =====================
   blog.html — 블로그
   ===================== */
.compose-box {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 24px;
}

.compose-box textarea {
  width: 100%;
  height: 90px;
  border: none;
  outline: none;
  resize: none;
  font-size: 0.95rem;
  font-family: inherit;
  color: #222;
  background: transparent;
}

.compose-box textarea::placeholder {
  color: #bbb;
}

.compose-box-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
}

.char-count {
  font-size: 0.8rem;
  color: #bbb;
}

#post-submit {
  padding: 6px 16px;
  border: none;
  border-radius: 6px;
  background: #222;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

#post-submit:hover {
  background: #444;
}

#posts-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.post {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 16px;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.post-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #ddd;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.post-username {
  font-weight: 700;
  font-size: 0.9rem;
}

.post-time {
  font-size: 0.78rem;
  color: #bbb;
  margin-left: auto;
}

.post-text {
  font-size: 0.95rem;
  line-height: 1.65;
  margin-bottom: 12px;
  white-space: pre-wrap;
  word-break: break-word;
}

.post-actions {
  display: flex;
  gap: 8px;
}

.btn-like,
.btn-reply {
  padding: 4px 12px;
  border: 1px solid #ddd;
  border-radius: 6px;
  background: transparent;
  font-size: 0.82rem;
  cursor: pointer;
  color: #555;
  transition: background 0.12s;
}

.btn-like:hover  { background: #fff0f0; border-color: #f99; color: #c00; }
.btn-reply:hover { background: #f0f4ff; border-color: #99c; color: #33c; }
.btn-like.liked  { background: #fff0f0; border-color: #f99; color: #c00; }
