@import url("https://cdn.jsdelivr.net/npm/computer-modern@0.1.3/cmu-bright.css");

:root {
  --paper: #f4efe8;
  --paper-strong: #efe8df;
  --ink: #111111;
  --ink-soft: #3b3b3b;
  --panel: #f9f5f0;
  --line: #171717;
  --red: #d7604d;
  --yellow: #d8b765;
  --green: #5f8e6b;
  --muted: #c8bfaf;
  --accent: #8a9075;
  --shadow: rgba(17, 17, 17, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "CMU Bright", "Computer Modern Bright", "CMU Serif", serif;
  line-height: 1.6;
}

img,
iframe {
  max-width: 100%;
  display: block;
}

button,
a {
  font: inherit;
}

.page-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 20px 12px;
}

.topbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
  padding: 14px 18px;
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: 4px 4px 0 var(--shadow);
}

h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(1.6rem, 2vw, 2.2rem);
}

.tab-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tab-button {
  border: 2px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  padding: 0.55rem 0.95rem;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.tab-button:hover,
.tab-button:focus-visible {
  transform: translate(-1px, -1px);
}

.tab-button.active {
  background: var(--ink);
  color: var(--paper);
}

.main-content {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(260px, 0.9fr);
  gap: 24px;
  align-items: start;
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

.window {
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: 6px 6px 0 var(--shadow);
}

.titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 14px;
  border-bottom: 2px solid var(--line);
  background: var(--paper-strong);
}

.window-controls {
  display: flex;
  gap: 8px;
}

.dot {
  width: 12px;
  height: 12px;
  border: 2px solid var(--line);
  border-radius: 50%;
  display: inline-block;
}

.dot.red { background: var(--red); }
.dot.yellow { background: var(--yellow); }
.dot.green { background: var(--green); }

.title {
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: lowercase;
}

.window-body {
  padding: 20px;
}

.about-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(250px, 0.9fr);
  gap: 24px;
}

.lead {
  font-size: 1.05rem;
}

.bio-copy {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.footnote-marker {
  font-size: 0.75em;
  vertical-align: super;
  color: var(--ink-soft);
}

.footnote {
  margin-top: auto;
  padding-top: 0.85rem;
  border-top: 2px solid var(--line);
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.footnote-label {
  font-weight: 700;
}

.mini-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.mini-list span {
  border: 2px solid var(--line);
  padding: 0.45rem 0.7rem;
  background: white;
}

.profile-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.portrait {
  min-height: 230px;
  border: 2px solid var(--line);
  background: #ded5c8;
  display: grid;
  place-items: center;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.info-block {
  display: grid;
  gap: 8px;
  font-size: 0.95rem;
}

.info-block p {
  margin-bottom: 0;
}

.secondary-button {
  width: fit-content;
  border: 2px solid var(--line);
  background: var(--accent);
  padding: 0.6rem 0.9rem;
  color: var(--paper);
  cursor: pointer;
}

.hidden-note {
  margin: 0;
  padding: 12px;
  border: 2px dashed var(--line);
  background: var(--paper);
  font-style: italic;
}

.hidden-note.hidden {
  display: none;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.project-card {
  border: 2px solid var(--line);
  background: var(--paper);
}

.project-image {
  min-height: 180px;
  border-bottom: 2px solid var(--line);
  background-size: cover;
  background-position: center;
}

.image-one {
  background-image: url("images/piano.jpg");
}

.image-two {
  background-image: url("images/ling.png");
}

.image-three {
  background-image: url("images/awap2026.png");
}

.project-copy {
  padding: 16px;
}

.project-copy h3 {
  margin-bottom: 0.35rem;
}

.timeline {
  display: grid;
  gap: 18px;
}

.entry {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 18px;
  padding: 16px 0;
  border-bottom: 2px solid var(--line);
}

.entry:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.year {
  font-weight: 700;
  color: var(--ink-soft);
}

.entry h3 {
  margin-bottom: 0.45rem;
}

.publications-window {
  margin-top: 24px;
}

.side-stack {
  display: grid;
  gap: 24px;
}

.compact-window {
  min-height: 0;
}

.spotify-body {
  padding: 14px;
}

.contact-body ul {
  margin: 16px 0 0;
  padding-left: 1.1rem;
}

.contact-body a {
  color: var(--ink);
}

.page-footer {
  max-width: 1280px;
  margin: 0 auto;
  padding: 14px 20px 28px;
}

.page-footer p {
  margin: 0;
  text-align: center;
  color: var(--ink-soft);
}

@media (max-width: 920px) {
  .main-content {
    grid-template-columns: 1fr;
  }

  .project-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .page-shell {
    padding-left: 14px;
    padding-right: 14px;
  }

  .topbar {
    padding-left: 12px;
    padding-right: 12px;
  }

  .about-layout {
    grid-template-columns: 1fr;
  }

  .entry {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}
