/* Reset + layout */
html,
body {
  height: 100%;
  margin: 0;
}

/* Page layout */
.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Main content expands */
main {
  flex: 1 0 auto;
}

/* Title section */
main .title {
  padding: 1rem;
  text-align: center;
}

/* Title text */
.title h1 {
  font-family: Helvetica, Arial, sans-serif;
  /* font-family: "Monaco", monospace; */
  font-size: 4.5rem;
  font-weight: 500;
  margin: 0;
  line-height: 1.1;
  margin-top: 1.2rem;
}

/* Footer */
.footer {
  background-color: #e9e9e9;
  color: #000;
  align-items: center;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  flex-direction: row-reverse;
}

.footer p {
  margin: 0;
}

.footer-logo {
  height: 42px;
}

/* Navigation */
.nav {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  margin-top: 2rem;
}

.nav a {
  text-decoration: none;
  font-family: Georgia, serif;
  font-size: 1.1rem;
  color: #000;
  position: relative;
}

.nav a:hover {
  text-decoration: underline;
}

/* Sponsors page */
.site-header {
  text-align: center;
  font-family: "Times New Roman", Times, serif;
  font-size: 1.1rem;
  margin-bottom: 3.8rem;
}

.site-header h1 {
  margin: 0;
  font-weight: normal;
}

.center {
  display: flex;
  justify-content: center; /* horizontal */
  align-items: center; /* vertical */
  height: 70vh;
}

.center img {
  width: auto;
  max-height: 85%;
  max-width: 90%;
  height: auto;
}

/* Quad images */
main .grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: auto;
  column-gap: 8px;
  row-gap: 4px;
  max-width: 900px;
  margin: 0 auto;
}

.grid-item {
  position: relative;
  overflow: hidden;
}

.grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Overlay text */
.overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  color: black;
  display: flex;
  align-items: left;
  justify-content: left;
  text-align: left;
  padding: 12px;

  opacity: 0;
  transition: opacity 0.3s ease;
  font-size: 1.5rem;
  font-family: "Helvetica Neue", Arial, sans-serif;
}

/* Show overlay on hover */
.grid-item:hover .overlay {
  opacity: 1;
}

.grid-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

/* Homepage Description */
main .quad-text {
  margin-top: 8px;
  font-size: 20px;
  line-height: 1.4;
  margin-left: 615px;
  /* color: #444; */
  text-align: left;
}

/* People page */
.image-row {
  display: flex;
  justify-content: center; /* centers images as a group */
  align-items: flex-start;
  gap: 40px;
  margin: 40px auto; /* <-- THIS is the key */
  width: 100%;
}

.image-row image-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.image-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center; /* ensures text is centered */
  width: fit-content;
}

.image-item img {
  height: 20vh; /* relative to viewport */
  max-height: 180px;
  width: auto;
  object-fit: contain;
}

.image-item .caption {
  width: 100%; /* match the image width (since parent shrink-wraps) */
  text-align: center;
  margin: 10px 0 0;
}
