:root {
  color-scheme: light;
  font-family: system-ui, sans-serif;

  /* Light mode — darkened accent variants for accessible text/links,
     raw logo hex for solid fills (buttons, borders, icons) */
  --color-bg: #f7f5f2;
  --color-surface: #ffffff;
  --color-border: #e4e1db;
  --text-primary: #1a1a1a;
  --text-secondary: #55585c;
  --color-teal: #2f6f70;
  --color-orange: #b8490c;
  --color-teal-solid: #449596;
  --color-orange-solid: #ff6310;
  --on-orange-solid: #1a1a1a;
}

[data-theme="dark"] {
  color-scheme: dark;

  /* Dark mode — cool charcoal. Raw logo hex works directly here since
     both colors already clear WCAG AA against this background. */
  --color-bg: #202225;
  --color-surface: #2b2e32;
  --color-border: #3a3d42;
  --text-primary: #f2f2f0;
  --text-secondary: #a8acb0;
  --color-teal: #449596;
  --color-orange: #ff6310;
  --color-teal-solid: #449596;
  --color-orange-solid: #ff6310;
  --on-orange-solid: #1a1a1a;
}

body {
  margin: 0;
  color: var(--text-primary);
  background: var(--color-bg);
  transition: background-color 0.15s ease, color 0.15s ease;
}
main { max-width: 720px; margin: 0 auto; padding: 1.5rem; }

a {
  color: var(--color-teal);
  text-decoration-color: color-mix(in srgb, var(--color-teal) 40%, transparent);
}
a:visited {
  color: color-mix(in srgb, var(--color-teal) 55%, var(--text-secondary));
}
a:hover {
  color: var(--color-orange);
  text-decoration-color: currentColor;
}
a:active {
  color: color-mix(in srgb, var(--color-orange) 80%, black);
}
a:focus-visible {
  outline: 2px solid var(--color-teal-solid);
  outline-offset: 2px;
}

.site-header {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 720px; margin: 0 auto;
  padding: 1rem 1.5rem; border-bottom: 1px solid var(--color-border);
}

.site-logo { display: flex; align-items: center; gap: 0.5rem; 
  text-decoration: none; color: inherit; font-weight: 600; }
#logo { 
  height:80px;
  /* width: 500px; */
}

.site-header span {font-size: 2.5rem; flex:2;}
.site-header nav { display: flex; align-items: center; }
.site-header nav a { margin-left: 1rem; }

.theme-toggle {
  margin-left: 1rem; border: 1px solid var(--color-border); background: var(--color-surface);
  color: var(--text-primary); border-radius: 999px; padding: 0.35rem 0.8rem;
  font-size: 0.85rem; cursor: pointer;
}
.theme-toggle:hover { border-color: var(--color-teal-solid); }

.site-footer { text-align: center; padding: 2rem; color: var(--text-secondary); font-size: 0.9rem; }

/* People cards */
.who-card, .event-card {
  border: 1px solid var(--color-border); background: var(--color-surface);
  border-radius: 8px; padding: 1.25rem; margin-bottom: 1.25rem;
}
/* ebb: for the next one, the > in the selector means style only the immediate child of .who-card. */
.who-card > img {
  max-width: 160px; aspect-ratio: 1; object-fit: cover;
  border-radius: 50%; display: block; margin-bottom: 0.75rem;
}
.who-jump-nav {
  display: flex; flex-wrap: wrap; gap: 0.4rem;
  margin-bottom: 1.5rem; font-size: 0.9rem;
}
.who-jump-nav a {
  display: inline-block; min-width: 1.6rem; text-align: center;
  padding: 0.15rem 0.3rem; border-radius: 4px;
}
.who-letter-heading {
  color: var(--text-secondary); border-bottom: 1px solid var(--color-border);
  padding-bottom: 0.25rem; margin: 2rem 0 1rem;
}
.who-letter-heading:first-of-type { margin-top: 0; }
.who-projects {
  margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--color-border);
  display: flex; flex-direction: column; gap: 0.85rem;
}
.project-row { display: flex; gap: 0.75rem; align-items: flex-start; }
.project-icon-link { flex-shrink: 0; }
img.project-icon {
  width: 56px; height: 56px; object-fit: cover;
  border-radius: 6px; display: block; margin: 0;
}
.project-info { flex: 1; min-width: 0; }
.project-title { margin: 0; font-weight: 600; }
.project-description { font-size: 0.9rem; color: var(--text-secondary); }
.project-description p { margin: 0.25rem 0 0; }

/* Event cards */
.event-card {
  position: relative;
}
.event-pin {
  position: absolute; top: -0.7rem; left: 50%; transform: translateX(-50%) rotate(-8deg);
  font-size: 1.5rem; line-height: 1; user-select: none;
}
.event-card img {  width:95%;
  max-width: 500px;
  border-radius: 8px;
  margin-bottom: 0.75rem;
}
.event-card--past { opacity: 0.75; }
.event-meta {
  color: var(--text-secondary); font-size: 0.9rem;
  list-style: none; margin: 0; padding: 0;
}
.events-past h2 { margin-top: 2.5rem; }

/* ebb: Specific to just index.html */
figure.homepage {
  width: 80%; 
}
figure.homepage img {
  width:95%; 
  max-width:800px;
  min-width:200px;
}
figcaption {
  font-size:smaller;
  font-style:italic;
  color: var(--color-teal);
}

/* ebb: For mobile portrait mode */
@media (max-width: 600px) {
  .site-header {
    flex-wrap: wrap;
    row-gap: 0.5rem;
  }
  .site-header nav {
    flex-wrap: wrap;
    width: 100%;
  }
  .site-header nav a {
    margin-left: 0;
    margin-right: 1rem;
  }
}
@media (max-width: 480px) {
  .project-row { flex-direction: column; }
}

