/* Card content stays at reading size even when a section grows past one screen. */
:root {
  --card-copy: #c7cbd1;
  --card-meta: #aeb4bd;
}
[data-theme="light"] {
  --card-copy: #3d4651;
  --card-meta: #596471;
}
#projects .project-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

#projects .database-preview {
  display: grid;
  place-items: center;
  color: #868f9a;
  background:
    radial-gradient(
      circle at 50% 50%,
      rgba(90, 104, 118, 0.1),
      transparent 62%
    ),
    #0d0f11;
}

#projects .database-preview .schema-map {
  width: 88%;
  height: 78%;
  overflow: visible;
}

#projects .database-preview path,
#projects .database-preview rect,
#projects .database-preview line {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

#projects .database-preview rect {
  fill: rgba(255, 255, 255, 0.025);
}

#projects .database-preview circle {
  fill: #41b6a6;
  opacity: 0.78;
}

#projects .database-preview text {
  fill: #c5cad0;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 15px;
  letter-spacing: 0.02em;
}
#projects .compact-project:last-child {
  grid-column: auto;
}
#projects .project-content {
  padding: 22px;
}
#projects .project-content h3,
#projects .compact-project .project-content h3 {
  font-size: 19px;
  line-height: 1.35;
  letter-spacing: -0.3px;
}
#projects .project-content > p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--card-copy);
  margin: 12px 0 20px;
}
#projects .project-meta {
  font-size: 13px;
  line-height: 1.6;
  color: var(--card-meta);
  margin-bottom: 14px;
}
#projects .project-content .tags {
  gap: 7px;
  padding-top: 14px;
}
#projects .project-content .tags span {
  font-size: 12px;
  line-height: 1.4;
  padding: 5px 8px;
  color: var(--card-meta);
}

.stack {
  margin-top: 30px;
}

.stack h3 {
  margin-bottom: 18px;
  font-size: 18px;
  line-height: 1.35;
  font-weight: 550;
  color: var(--ink);
}

.stack .tags {
  gap: 10px;
}

.stack .tags span {
  padding: 8px 11px;
  font-size: 14px;
  line-height: 1.25;
  border-radius: 6px;
}
.project-preview {
  width: calc(100% - 24px);
  margin: 12px 12px 0;
}
.preview-action {
  opacity: 1;
  transform: none;
  font-size: 12px;
  padding: 8px 10px;
}
.filters button {
  font-size: 12px;
}
.work-screen .experience-summary {
  font-size: 16px;
  line-height: 1.75;
  color: var(--card-copy);
}
.work-screen .experience-title p {
  font-size: 15px;
  color: var(--card-copy);
}
.work-screen .experience-title .period {
  font-size: 12px;
  color: var(--card-meta);
  letter-spacing: 0;
}
.work-screen .contribution {
  grid-template-columns: 156px minmax(0, 1fr);
  gap: 8px 24px;
  margin-bottom: 24px;
}
.work-screen .contribution h4 {
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink);
  font-weight: 600;
}
.work-screen .contribution p {
  font-size: 16px;
  line-height: 1.75;
  color: var(--card-copy);
}
.work-screen .contribution::before {
  top: 9px;
}
.work-screen .proof span {
  font-size: 14px;
  color: var(--card-copy);
  line-height: 1.6;
}
.work-screen .experience-card summary {
  font-size: 13px;
  letter-spacing: 0;
  color: var(--card-meta);
}
.work-screen .experience-foot .tags span {
  font-size: 12px;
  color: var(--card-meta);
  padding: 5px 8px;
}
.work-screen .contribution-list > .subtle-link {
  font-size: 13px;
  color: var(--card-copy);
}
.affiliation-copy strong {
  font-size: 14px;
}
.affiliation-copy > span {
  font-size: 12px;
  color: var(--card-meta);
}
.education-row h3 {
  font-size: 17px;
}
.education-row p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--card-copy);
}
.education-row > div > span {
  font-size: 14px;
  line-height: 1.7;
  color: var(--card-meta);
}
@media (max-width: 1100px) {
  .work-screen .contribution {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .work-screen .experience-title {
    grid-template-columns: 1fr;
  }
  .work-screen .experience-title h3 {
    grid-column: auto;
  }
}
@media (max-width: 1000px) {
  #projects .project-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 720px) {
  .stack h3 {
    font-size: 17px;
  }

  .stack .tags {
    gap: 8px;
  }

  .stack .tags span {
    padding: 7px 10px;
    font-size: 13px;
  }

  #projects .project-content {
    padding: 20px;
  }
  #projects .project-content > p {
    font-size: 15px;
    line-height: 1.7;
  }
  .work-screen .experience-summary,
  .work-screen .contribution p {
    font-size: 15px;
    line-height: 1.75;
  }
  .work-screen .experience-title p {
    font-size: 14px;
  }
  .work-screen .experience-title .period {
    font-size: 12px;
  }
  .work-screen .proof span {
    font-size: 13px;
  }
  .work-screen .contribution h4 {
    font-size: 15px;
  }
  .affiliations {
    grid-template-columns: 1fr;
  }
  .affiliation {
    flex-direction: row;
    align-items: center;
    gap: 12px;
    padding: 13px 14px;
  }
  .affiliation-copy strong {
    font-size: 14px;
  }
  .affiliation-copy > span {
    font-size: 12px;
  }
  .education-row h3 {
    font-size: 16px;
  }
  .education-row p {
    font-size: 14px;
  }
  .education-row > div > span {
    font-size: 13px;
  }
}
