/* =========================================================
   layout_study.css
   Individual research study pages
   Editorial / research-oriented visual language
   ========================================================= */

/* =========================
   PAGE
   ========================= */

.study-page {
  max-width: 1180px;
  margin: 0 auto;

  padding: clamp(4rem, 7vw, 7rem) 2rem clamp(6rem, 10vw, 10rem);
}

/* =========================
   HERO
   ========================= */

.study-hero {
  max-width: 960px;

  margin-bottom: clamp(4.5rem, 8vw, 7rem);

  padding-bottom: clamp(3rem, 5vw, 4.5rem);

  border-bottom: 1px solid #dcdcdc;
}

.study-eyebrow {
  margin: 0 0 1.35rem;

  color: #777;

  font-size: 0.72rem;
  font-weight: 600;

  letter-spacing: 0.12em;

  text-transform: uppercase;
}

.study-hero h1 {
  max-width: 880px;

  margin: 0;

  color: #1f1f1f;

  font-size: clamp(2.8rem, 5.6vw, 4.8rem);

  line-height: 0.98;

  letter-spacing: -0.05em;

  font-weight: 700;
}

.study-subtitle {
  max-width: 720px;

  margin: 2rem 0 0;

  color: #555;

  font-size: clamp(1.05rem, 1.5vw, 1.2rem);

  line-height: 1.7;
}

.study-tags {
  display: flex;
  flex-wrap: wrap;

  gap: 0.55rem;

  margin-top: 1.8rem;
}

.study-tags span {
  padding: 0.38rem 0.72rem;

  border: 1px solid #d7d7d7;

  border-radius: 999px;

  color: #666;

  font-size: 0.74rem;
}

/* =========================
   BODY
   ========================= */

.study-body {
  max-width: 920px;
}

/* =========================
   INTRO PARAGRAPHS
   ========================= */

.study-body > p:first-child,
.study-body > p:nth-child(2) {
  max-width: 760px;

  color: #333;

  font-size: clamp(1.03rem, 1.3vw, 1.12rem);

  line-height: 1.8;
}

/* =========================
   RESEARCH MODULE TITLES
   ========================= */

.study-body h2 {
  max-width: 820px;

  margin: clamp(5rem, 8vw, 7rem) 0 1.4rem;

  padding-top: clamp(2.5rem, 4vw, 3.5rem);

  border-top: 1px solid #e1e1e1;

  color: #202020;

  font-size: clamp(2rem, 3.8vw, 3.25rem);

  line-height: 1.02;

  letter-spacing: -0.04em;

  font-weight: 700;
}

/*
  The first module should not look
  excessively separated from the intro.
*/

.study-body h2:first-of-type {
  margin-top: 4rem;

  padding-top: 0;

  border-top: 0;
}

/* =========================
   SUBHEADINGS
   e.g. "Related research"
   ========================= */

.study-body h3 {
  margin: 2.6rem 0 1rem;

  color: #777;

  font-size: 0.72rem;

  font-weight: 600;

  letter-spacing: 0.11em;

  text-transform: uppercase;
}

/* =========================
   PARAGRAPHS
   ========================= */

.study-body p {
  max-width: 760px;

  margin: 0 0 1.35rem;

  color: #454545;

  font-size: 1rem;

  line-height: 1.82;
}

/* =========================
   LINKS
   ========================= */

.study-body a {
  color: #333;

  text-decoration-line: underline;
  text-decoration-color: #aaa;
  text-decoration-thickness: 1px;

  text-underline-offset: 4px;

  transition:
    color 160ms ease,
    text-decoration-color 160ms ease;
}

.study-body a:hover {
  color: #000;

  text-decoration-color: #222;
}

/* =========================
   RELATED RESEARCH LIST
   ========================= */

.study-body h3 + ul {
  max-width: 760px;

  margin: 0 0 2rem;

  padding: 0;

  list-style: none;

  border-top: 1px solid #e6e6e6;
}

.study-body h3 + ul li {
  margin: 0;

  padding: 0.85rem 0;

  border-bottom: 1px solid #e6e6e6;

  color: #444;

  line-height: 1.5;
}

.study-body h3 + ul li::before {
  content: "↗";

  display: inline-block;

  margin-right: 0.7rem;

  color: #999;

  font-size: 0.8rem;

  transform: translateY(-1px);
}

.study-body h3 + ul a {
  color: #333;

  text-decoration: none;
}

.study-body h3 + ul a:hover {
  color: #000;
}

/* =========================
   GENERAL LISTS
   ========================= */

.study-body ul,
.study-body ol {
  max-width: 760px;

  margin: 1.5rem 0 2rem;

  padding-left: 1.25rem;

  color: #444;

  line-height: 1.75;
}

.study-body li {
  margin-bottom: 0.5rem;
}

/* =========================
   IMAGES
   ========================= */

.study-body img {
  display: block;

  width: 100%;
  max-width: 920px;

  height: auto;

  margin: 3rem 0 3.5rem;

  border: 1px solid #e2e2e2;

  background: #f7f7f7;
}

/* =========================
   FIGURE CAPTIONS
   ========================= */

.study-body em {
  color: #777;
}

/* =========================
   BLOCKQUOTE
   ========================= */

.study-body blockquote {
  max-width: 760px;

  margin: 2.5rem 0;

  padding: 0 0 0 1.25rem;

  border-left: 2px solid #d0d0d0;

  color: #555;
}

.study-body blockquote p {
  margin: 0;

  font-size: 1.05rem;

  line-height: 1.7;
}

/* =========================
   TABLES
   ========================= */

.study-body table {
  width: 100%;

  margin: 2.5rem 0;

  border-collapse: collapse;

  font-size: 0.9rem;
}

.study-body th,
.study-body td {
  padding: 0.8rem 0.6rem;

  border-bottom: 1px solid #ddd;

  text-align: left;
}

.study-body th {
  color: #555;

  font-size: 0.72rem;

  letter-spacing: 0.08em;

  text-transform: uppercase;
}

/* =========================
   TABLET
   ========================= */

@media (max-width: 900px) {
  .study-page {
    padding: 4rem 1.5rem 6rem;
  }

  .study-hero {
    margin-bottom: 4rem;
  }

  .study-body h2 {
    max-width: 760px;
  }
}

/* =========================
   MOBILE
   ========================= */

@media (max-width: 760px) {
  .study-page {
    padding: 3rem 1rem 4.5rem;
  }

  .study-hero {
    margin-bottom: 3.5rem;

    padding-bottom: 2.5rem;
  }

  .study-hero h1 {
    font-size: clamp(2.3rem, 10vw, 3.5rem);

    line-height: 1;
  }

  .study-subtitle {
    margin-top: 1.5rem;

    font-size: 1rem;
  }

  .study-tags {
    margin-top: 1.4rem;
  }

  .study-body h2 {
    margin-top: 4.5rem;

    padding-top: 2.5rem;

    font-size: clamp(1.9rem, 8vw, 2.7rem);
  }

  .study-body h2:first-of-type {
    margin-top: 3rem;
  }

  .study-body p {
    font-size: 0.98rem;

    line-height: 1.75;
  }

  .study-body h3 {
    margin-top: 2.2rem;
  }

  .study-body img {
    margin: 2.25rem 0 2.75rem;
  }

  .study-body h3 + ul li {
    padding: 0.75rem 0;
  }
}

/* =========================
   REDUCED MOTION
   ========================= */

@media (prefers-reduced-motion: reduce) {
  .study-body a {
    transition: none;
  }
}
