:root {
  --bg: #ffffff;
  --fg: #1a1a1a;
  --muted: #666666;
  --link: #1a1a1a;
  --border: #e5e5e5;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121212;
    --fg: #e8e8e8;
    --muted: #999999;
    --link: #e8e8e8;
    --border: #2a2a2a;
  }
}

:root[data-theme="light"] {
  --bg: #ffffff;
  --fg: #1a1a1a;
  --muted: #666666;
  --link: #1a1a1a;
  --border: #e5e5e5;
}

:root[data-theme="dark"] {
  --bg: #121212;
  --fg: #e8e8e8;
  --muted: #999999;
  --link: #e8e8e8;
  --border: #2a2a2a;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light dark;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  font-size: 17px;
  transition: background 0.15s ease, color 0.15s ease;
}

.container {
  max-width: 640px;
  margin: 0 auto;
  padding: 64px 24px 80px;
}

.site-header {
  position: relative;
  margin-bottom: 48px;
}

.site-header h1 {
  font-size: 1.6rem;
  margin: 0 0 4px;
}

.tagline {
  margin: 0 0 16px;
  color: var(--muted);
}

nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
}

nav a:hover {
  color: var(--fg);
  text-decoration: underline;
}

nav a.icon-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

nav a.icon-link:hover {
  text-decoration: none;
}

#theme-toggle {
  position: absolute;
  top: 0;
  right: 0;
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--fg);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  padding: 6px 10px;
}

#theme-toggle:hover {
  border-color: var(--muted);
}

section {
  margin-bottom: 48px;
}

h2 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 0 0 16px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
}

p {
  margin: 0 0 12px;
  font-size: 0.85rem;
}

.links a {
  color: var(--link);
}

a {
  color: var(--link);
}

.entry {
  margin-bottom: 24px;
}

.entry:last-child {
  margin-bottom: 0;
}

.entry-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.entry-header h3 {
  font-size: 0.85rem;
  margin: 0;
  font-weight: 600;
}

.entry-titles {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.entry-company {
  font-size: 1rem;
  margin: 0;
  font-weight: 700;
}

.entry-role {
  font-size: 0.85rem;
  margin: 0;
  font-weight: 500;
  color: var(--muted);
}

.entry .date {
  color: var(--muted);
  font-size: 0.75rem;
  white-space: nowrap;
}

.entry p {
  margin: 6px 0 0;
  color: var(--fg);
}

.entry-list {
  margin: 6px 0 0;
  padding-left: 20px;
  color: var(--fg);
}

.entry-list li {
  margin: 0 0 4px;
  font-size: 0.85rem;
}

.entry-list li:last-child {
  margin-bottom: 0;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.tags li {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--muted);
  background: color-mix(in srgb, var(--fg) 6%, transparent);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 10px;
  line-height: 1.4;
}

footer {
  color: var(--muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

@media (max-width: 480px) {
  .container {
    padding: 40px 20px 60px;
  }

  #theme-toggle {
    position: static;
    margin-top: 12px;
  }
}
