/* ======================================================
   Research Page CSS
====================================================== */

/* ----------------------------------------
   Scroll Fade / Visibility Animation
---------------------------------------- */
.fade-init {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-section.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Subtle fade animation (same as homepage hero) */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ======================================================
   Typography Harmonization (Home ↔ Research)
====================================================== */

body {
  font-family: 'Inter', 'Helvetica Neue', sans-serif;
  color: var(--text-color, #111);
  background: var(--bg-light, #fff);
  line-height: 1.7;
  font-size: 1rem;
  margin: 0;
  padding: 0;
}

/* -------------------------
   Headings
------------------------- */

[id^="research-"] .research-subheading h2,
#research-4-collaborators .research-subheading h2 {
  text-align: center;
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--text-color, #111);
  line-height: 1.25;
  margin-bottom: 0.75rem;
}

/* Goals section heading – slightly larger */
.goals-section .research-subheading h2 {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 1rem;
}

/* -------------------------
   Paragraph Text
------------------------- */

[id^="research-"] .research-text p,
#research-4-collaborators .collaborators-list li,
.goals-section .research-text p {
  font-size: clamp(1.05rem, 1.2vw, 1.15rem);
  line-height: 1.8;
  color: var(--text-muted, #444);
}

#research-4-collaborators .collaborators-list {
  font-size: clamp(1.05rem, 1.2vw, 1.15rem);
  line-height: 1.8;
  color: #eee;
}

@media (min-width: 992px) {
  [id^="research-"] .research-subheading h2 {
    font-size: 1.5rem;
  }
  [id^="research-"] .research-text p {
    font-size: 1.1rem;
	  margin: 0rem;
  }
}

/* ======================================================
   Unified Section Layout
====================================================== */

.goals-section,
[id^="research-"],
#research-4-collaborators {
  margin: 0 auto;
  box-sizing: border-box;
  padding: 0rem clamp(1rem, 4vw, 2rem);
  position: relative;
}

/* Inner containers */
[id^="research-"] .inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: clamp(1.25rem, 4vw, 6rem);
  margin: 0;
  padding: 0;
}

/* ======================================================
   Goals Section
====================================================== */

.goals-section {
  text-align: center;
  max-width: 100%;
  padding: 0rem 1rem 0rem 1rem;
  animation: fadeUp 1.2s ease-out both; /* Fades in on page load */
}

.goals-section .content {
  position: relative;
  font-weight: 400;
  z-index: 1;
  max-width: 600px;
  margin: 0 auto;
  padding: 2rem 0rem 0rem 0rem;
}

.goals-section .research-text p {
  text-align: justify;
  margin: 0;
}

/* ======================================================
   Shared Research Section Base Styles
====================================================== */

[id^="research-"] {
  position: relative;
}

[id^="research-"] .image {
  order: -1;
  width: 80%;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  margin: 0;
  padding: 0;
}

[id^="research-"] .image img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  object-fit: cover;
  align-self: flex-start;
}

[id^="research-"] .text {
  width: 100%;
  text-align: left;
  margin: 0;
  padding: 0 1rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

[id^="research-"] .research-subheading,
#research-4-collaborators .research-subheading {
  position: relative;
  display: inline-block;
  margin: 0.8rem 0rem;
}

.blob-target {
  position: relative;
  display: inline-block;
  pointer-events: none;
}

.blob-target::before {
  z-index: -1;
}

/* ======================================================
   Section Dividers
====================================================== */

.section-divider {
  display: block;
  width: 100%;
  margin: 1rem 0rem 3rem 0rem;
  padding: 0;
  line-height: 0;
  border: none;
}

/* ======================================================
   Blob Color Variants
====================================================== */

/* Research 1 — Soft Blue */
#research-1 .blob-target::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 75px;
  height: 75px;
  background: #5f8dd3;
  border-radius: 55% 45% 60% 40% / 50% 60% 40% 50%;
  transform: translate(-50%, -50%);
  opacity: 0.25;
  z-index: -1;
  pointer-events: none;
}

/* Research 2 — Beige */
#research-2 .blob-target::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 75px;
  height: 75px;
  background: #d6b7a2;
  border-radius: 55% 45% 60% 40% / 50% 60% 40% 50%;
  transform: translate(-50%, -50%);
  opacity: 0.35;
  z-index: -1;
  pointer-events: none;
}

/* Research 3 — Green */
#research-3 .blob-target::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 75px;
  height: 75px;
  background: #a0d67a;
  border-radius: 55% 45% 60% 40% / 50% 60% 40% 50%;
  transform: translate(-50%, -50%);
  opacity: 0.35;
  z-index: -1;
  pointer-events: none;
}

/* Research 4 — Burnt Orange */
#research-4 .blob-target::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 75px;
  height: 75px;
  background: #d3723a;
  border-radius: 55% 45% 60% 40% / 50% 60% 40% 50%;
  transform: translate(-50%, -50%);
  opacity: 0.35;
  z-index: -1;
  pointer-events: none;
}

/* Collaborators — Teal Outline */
#research-4-collaborators .blob-target::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 75px;
  height: 75px;
  background: rgba(0, 163, 157, 0.05);
  border: 2px solid #d6e2f3;
  border-radius: 55% 45% 60% 40% / 50% 60% 40% 50%;
  transform: translate(-50%, -50%);
  opacity: 0.9;
  z-index: -1;
  pointer-events: none;
}

/* ======================================================
   Collaborators Section 
====================================================== */

#research-4-collaborators {
  background: #000;
  color: #fff;
  text-align: center;
  position: relative;
  overflow: hidden;
  width: 100vw; /* Full width */
  margin-left: calc(-50vw + 50%);
  padding: 4rem 1rem;
}

#research-4-collaborators .research-subheading {
  text-align: center;
  margin-bottom: 1rem;
}

#research-4-collaborators .blob-target {
  display: inline-block;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

#research-4-collaborators .collaborators-list {
  list-style-type: disc;
  text-align: justify;
  max-width: clamp(320px, 60vw, 900px);
  margin: 1.5rem auto;
  padding-left: 1.5rem;
}



/* Ensure all text is white */
#research-4-collaborators .research-subheading h2,
#research-4-collaborators .collaborators-list,
#research-4-collaborators .collaborators-list li {
  color: #fff;
}

/* ======================================================
   Responsive Layouts
====================================================== */

@media (min-width: 768px) {
  #research-1 .inner,
  #research-2 .inner,
  #research-3 .inner,
  #research-4 .inner {
    flex-direction: row;
    align-items: flex-start;
    justify-content: center;
    gap: clamp(2rem, 4vw, 5rem);
  }

  #research-1 .image,
  #research-2 .image,
  #research-4 .image {
    order: 0;
    flex: 1 1 40%;
  }

  #research-3 .image {
    order: 1;
    flex: 1 1 40%;
  }

  #research-1 .text,
  #research-2 .text,
  #research-3 .text,
  #research-4 .text {
    flex: 1 1 55%;
    max-width: 600px;
  }

  #research-1 .blob-target::before,
  #research-2 .blob-target::before,
  #research-3 .blob-target::before,
  #research-4 .blob-target::before {
    width: 120px;
    height: 120px;
  }
}

@media (min-width: 1200px) {
  #research-1 .inner,
  #research-2 .inner,
  #research-3 .inner,
  #research-4 .inner {
    justify-content: center;
  }

  #research-1 .text,
  #research-2 .text,
  #research-3 .text,
  #research-4 .text {
    flex: 1 1 50%;
    max-width: 500px;
  }

  #research-1 .image,
  #research-2 .image,
  #research-3 .image,
  #research-4 .image {
    flex: 1 1 45%;
    max-width: 600px;
  }

  #research-4-collaborators .blob-target::before {
    width: 110px;
    height: 110px;
    opacity: 0.8;
  }
}
