:root {
  color-scheme: light dark;
}

* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
  margin: 0;
  padding: 2rem 1.25rem;
  color: #111;
  background: #fff;
}

main {
  max-width: 40rem;
  margin: 0 auto;
}

h1 {
  font-size: 2rem;
  margin: 0 0 0.25rem;
}

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

h1 a:visited {
  color: inherit;
}

.role {
  font-size: 1.1rem;
  color: #444;
  margin: 0 0 0.5rem;
}

.meta {
  font-size: 0.95rem;
  color: #555;
  margin: 0 0 1.5rem;
}

header {
  text-align: center;
}

nav {
  margin: 0.75rem 0 1.25rem;
  display: flex;
  justify-content: center;
  gap: 1rem;
  font-size: 0.95rem;
}

nav a {
  text-decoration: none;
  color: #333;
  border-bottom: 1px solid transparent;
}

nav a:hover {
  border-bottom-color: #333;
}

.video-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
}

.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.project-card {
  aspect-ratio: 4 / 3;
  background: #e2e2e2;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #333;
  font-weight: 600;
  border-radius: 0.3rem;
}

.project-card:hover {
  background: #d3d3d3;
}

.project-images {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1.5rem;
}

.img-placeholder {
  aspect-ratio: 16 / 10;
  background: #e2e2e2;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
  border-radius: 0.3rem;
}

h2 {
  font-size: 1.1rem;
  border-bottom: 1px solid #ddd;
  padding-bottom: 0.25rem;
  margin-top: 2rem;
}

h3 {
  font-size: 1rem;
  margin-bottom: 0.15rem;
}

.dates {
  font-size: 0.85rem;
  color: #666;
  margin: 0 0 0.35rem;
}

article {
  margin-bottom: 1.25rem;
}

a {
  color: #0645ad;
}

a:visited {
  color: #4a3d8f;
}

/* links.html */
.links-page {
  text-align: center;
}

.link-list {
  list-style: none;
  padding: 0;
  margin: 2rem 0;
}

.link-list li {
  margin-bottom: 0.85rem;
}

.link-list a {
  display: block;
  padding: 0.75rem 1rem;
  border: 1px solid #ccc;
  border-radius: 0.4rem;
  text-decoration: none;
  color: #111;
}

.link-list a:hover {
  border-color: #888;
}

.back {
  font-size: 0.9rem;
}

@media (prefers-color-scheme: dark) {
  body {
    color: #eee;
    background: #111;
  }
  .role { color: #bbb; }
  .meta { color: #999; }
  h2 { border-color: #333; }
  .dates { color: #999; }
  a { color: #8ab4ff; }
  a:visited { color: #b39ddb; }
  .link-list a {
    border-color: #444;
    color: #eee;
  }
  .link-list a:hover { border-color: #777; }
  nav a { color: #ddd; }
  nav a:hover { border-bottom-color: #ddd; }
  .project-card { background: #2a2a2a; color: #ddd; }
  .project-card:hover { background: #383838; }
  .img-placeholder { background: #2a2a2a; color: #aaa; }
}
