.card {
    background: rgba(220, 220, 220, 0.1);
    /* subtle contrast background */
    border: 1px solid rgba(220, 220, 220, 0.3);
    padding: 1rem;
    width: min(320px, 85vw);
    /* wider than before */
    aspect-ratio: 5 / 8;
    /* keeps the original card ratio */
    font-family: 'Space Mono';
    font-size: 1rem;
    border-radius: 8px;
    transform-style: preserve-3d;
    will-change: transform;
}

.card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}
.card-link .research-card {
  cursor: pointer;
}

/* Research cards*/
.research-card {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1rem;
    background: rgba(220, 220, 220, 0.1);
    border: 1px solid rgba(220, 220, 220, 0.1);
    border-radius: 12px;
    overflow: hidden;
}

.research-card:hover {
    background: rgba(220,220,220, 0.2); 
}

.research-card:hover .pub-title {
    color: #d3af37;
}

/* Header */
.research-card .pub-header {
    margin-bottom: 0.75rem;
}

.research-card .pub-title {
    font-size: 0.9rem;
    font-weight: bold;
    margin: 0;
}

.research-card .pub-authors {
    font-size: 0.8rem;
    color: #aaa;
    margin: 0.25rem 0 0 0;
}

.research-card .pub-journal {
    font-size: 0.8rem;
    color: rgb(220, 220, 220);
    margin: 0.25rem 0 0 0;
    font-style: italic;
    display: inline;
}

.research-card .pub-info {
    font-size: 0.8rem;
    color: rgb(220, 220, 220);
    margin: 0 0 0 0em;
    display: inline;
}

/* Journal Image */
.research-card .pub-img-container {
    position: absolute;
    top: 8.5rem;      /* adjust vertical position */
    left: 0;
    right: 0;
    margin: 0 auto;
    width: 91%;   /* required: fixed width */
    aspect-ratio: 4 / 9;
    overflow: hidden;
    border-radius: 8px;
    transform: translateZ(20px);
    transition: transform 0.2s ease;
}

.research-card .pub-img {
    width: 100%;        /* scale image to fill card-journal */
    height: auto;
    object-fit: cover;
    object-position: top;
    border-radius: inherit; /* optional: keeps smooth corners */
}

.research-card .pub-type {
    position: absolute;
    bottom: 34%;
    /* adjust based on journal-img height */
    right: 10%;
    background: rgba(220, 220, 220, 0.8);
    color: rgb(3,2,7);
    font-size: 0.75rem;
    font-weight: bold;
    padding: 4px 10px;
    border-radius: 999px;
    box-shadow: 0 2px 6px rgba(15, 40, 80, 0.1) inset;
}

/* Description */
.research-card .pub-desc {
    margin-top: auto;
    margin-bottom: -1rem;
    font-size: 0.9rem;
    line-height: 1.4;
    color: rgb(220, 220, 220);
}





/* People cards*/
.people-card {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1rem;
    background: rgba(220, 220, 220, 0.1);
    border: 1px solid rgba(220, 220, 220, 0.1);
    border-radius: 12px;
    overflow: hidden;
}

.people-card:hover {
    background: rgba(220,220,220, 0.2); 
}

/* Header */
.people-card .people-header {
    margin-bottom: 0.75rem;
}

.people-card .people-name {
    font-size: 1rem;
    font-weight: bold;
    margin: 0;
}

/* Journal Image */
.people-card .people-img-container {
    position: absolute;
    top: 3.4rem;      /* adjust vertical position */
    left: 0;
    right: 0;
    margin: 0 auto;
    width: 91%;  /* required: fixed width */
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 8px;
    transform: translateZ(20px);
    transition: transform 0.2s ease;
}

.people-card .people-img {
    width: 100%;        /* scale image to fill card-journal */
    height: auto;
    object-fit: cover;
    object-position: top;
    border-radius: inherit; /* optional: keeps smooth corners */
}

.people-card .people-position {
    position: absolute;
    bottom: 29.5%;
    /* adjust based on journal-img height */
    right: 10%;
    background: rgba(220, 220, 220, 0.8);
    color: rgb(3,2,7);
    font-size: 0.75rem;
    font-weight: bold;
    padding: 4px 10px;
    border-radius: 999px;
    box-shadow: 0 2px 6px rgba(15, 40, 80, 0.1) inset;
}

/* Description */
.people-card .people-bio {
    margin-bottom: 2.5rem;
    font-size: 0.9rem;
    line-height: 1.4;
    color: #eee;
}


/* People-card links */
.people-card .people-links {
  display: flex;
  gap: 0.5rem;
  position: absolute;
  bottom: 1.1rem;      /* keep inside the card edge */
  right: 1.1rem;
}

.people-card .social-btn {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(220, 220, 220, 0.35);
  background: rgba(220, 220, 220, 0.08);
  text-decoration: none;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  color: rgb(220, 220, 220);
}

.people-card .social-btn img {
  width: 24px;
  height: 24px;
}

.people-card .social-btn:hover {
  transform: translateY(-1px);
  background: rgba(220, 220, 220, 0.18);
  border-color: rgba(220, 220, 220, 0.6);
}

.people-card .submit-btn {
  display: inline-grid;
  place-items: center;
  width: 180px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(220, 220, 220, 0.35);
  background: rgba(220, 220, 220, 0.08);
  text-decoration: none;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  color: #eee;
  font-size: 0.9rem;
  line-height: 1.4;
}

.people-card .submit-btn:hover {
  transform: translateY(-1px);
  background: rgba(220, 220, 220, 0.18);
  border-color: rgba(220, 220, 220, 0.6);
}