* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: #ffffff;
  color: #1a1a1a;
  line-height: 1.6;
  padding: 40px 20px;
  transition: background-color 0.3s ease, color 0.3s ease;
}

html.dark-mode body,
body.dark-mode {
  background: #1a1a1a;
  color: #e0e0e0;
}

html.dark-mode header,
body.dark-mode header {
  border-bottom-color: #333;
}

html.dark-mode header h1,
html.dark-mode .section h2,
html.dark-mode .item-header .title,
html.dark-mode .skill-name,
body.dark-mode header h1,
body.dark-mode .section h2,
body.dark-mode .item-header .title,
body.dark-mode .skill-name {
  color: #e0e0e0;
}

html.dark-mode .back-link,
html.dark-mode .item p,
html.dark-mode .skill-level,
body.dark-mode .back-link,
body.dark-mode .item p,
body.dark-mode .skill-level {
  color: #999;
}

html.dark-mode .back-link:hover,
body.dark-mode .back-link:hover {
  color: #e0e0e0;
}

html.dark-mode .section h2,
body.dark-mode .section h2 {
  border-bottom-color: #333;
}

html.dark-mode .item,
body.dark-mode .item {
  border-color: #333;
}

html.dark-mode .item:hover,
body.dark-mode .item:hover {
  border-color: #555;
}

html.dark-mode .skill,
body.dark-mode .skill {
  border-bottom-color: #2a2a2a;
}

.container {
  max-width: 900px;
  margin: 0 auto;
}

header {
  margin-bottom: 60px;
  padding-bottom: 30px;
  border-bottom: 1px solid #e0e0e0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #1a1a1a;
}

.back-link {
  text-decoration: none;
  color: #666;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.back-link:hover {
  color: #1a1a1a;
}

main {
  margin-bottom: 60px;
}

.section {
  margin-bottom: 60px;
}

.section h2 {
  font-size: 1.8rem;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 30px;
  padding-bottom: 10px;
  border-bottom: 1px solid #e0e0e0;
}

.item {
  margin-bottom: 25px;
  padding: 20px;
  border: 1px solid #e0e0e0;
  transition: border-color 0.2s ease;
}

.item:hover {
  border-color: #999;
}

.item-header {
  display: flex;
  gap: 15px;
  align-items: center;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.badge {
  display: inline-block;
  padding: 4px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #666;
  border: 1px solid #ccc;
  letter-spacing: 0.5px;
}

.badge.gold {
  color: #d4af37;
  border-color: #d4af37;
}

.badge.silver {
  color: #c0c0c0;
  border-color: #c0c0c0;
}

.badge.bronze {
  color: #cd7f32;
  border-color: #cd7f32;
}

.badge.highlight {
  color: #1a1a1a;
  border-color: #1a1a1a;
  font-weight: 700;
}

html.dark-mode .badge.highlight,
body.dark-mode .badge.highlight {
  color: #ffd700;
  border-color: #ffd700;
}

.item-header .title {
  font-weight: 600;
  color: #1a1a1a;
  flex: 1;
}

.item p {
  color: #666;
  font-size: 0.95rem;
  line-height: 1.6;
}

.skill {
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid #f0f0f0;
}

.skill:last-child {
  border-bottom: none;
}

.skill-name {
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 5px;
}

.skill-level {
  color: #666;
  font-size: 0.9rem;
}

/* ========== 響應式設計 ========== */
@media (max-width: 768px) {
  body {
    padding: 20px 15px;
  }

  header {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }

  header h1 {
    font-size: 2rem;
  }

  .section h2 {
    font-size: 1.5rem;
  }

  .item {
    padding: 15px;
  }

  .item-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

.theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  background: none;
  border: 1px solid #e0e0e0;
  padding: 10px 15px;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.2s ease;
  z-index: 1000;
}

.theme-toggle:hover {
  border-color: #1a1a1a;
  background: #fafafa;
}

html.dark-mode .theme-toggle,
body.dark-mode .theme-toggle {
  border-color: #333;
}

html.dark-mode .theme-toggle:hover,
body.dark-mode .theme-toggle:hover {
  border-color: #666;
  background: #222;
}
