/* Activity listing polish */
.quarto-grid-item {
  border-radius: 14px;
  overflow: hidden;
}

.quarto-grid-item .card-title {
  line-height: 1.25;
}

.quarto-grid-item .card-text {
  font-size: 0.95rem;
}

/* General */
.no-underline {
    text-decoration: none;
}

.navbar .dropdown-menu {
  display: block;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.15s ease,
              transform 0.15s ease,
              visibility 0.15s ease;
}

.navbar .dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

@media (min-width: 992px) {
  .navbar .dropdown:hover .dropdown-menu {
    display: block;
    margin-top: 0;
  }
}

/* Global hyperlinks */
:root {
  --bs-primary: #426b73;
  --site-accent: #426b73;
  --site-accent-dark: #2f5158;
}

a {
  color: var(--site-accent);
}

a:hover {
  color: var(--site-accent-dark);
}

a:visited {
  color: var(--site-accent);
}


/* Homepage-specific styling */
.homepage {
  --home-accent: #426b73;
  --home-accent-soft: #e7f0f1;
  --home-ink: #1f2933;
  --home-muted: #5f6f7a;
  --home-line: #d7e1e4;
  --home-bg: #ffffff;
  font-size: 1.02rem;
}

.home-hero {
  min-height: 72vh;
  display: grid;
  align-items: center;
  background:
    linear-gradient(rgba(255,255,255,0.22), rgba(255,255,255,0.90)),
    url("images/black-mt-peninsula.jpg") center / cover no-repeat;
  /*border-bottom: 1px solid var(--home-line);*/
  border-radius: 20px;
  margin-top: -1.5rem;
}

.home-hero-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 5.5rem 1.5rem 4.5rem;
}

.home-kicker {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  color: var(--home-accent);
  font-weight: 700;
  margin-bottom: 1rem;
}

.home-title {
  font-size: clamp(2.4rem, 7vw, 5.2rem);
  line-height: 0.95;
  font-weight: 700;
  margin: 0 0 1.1rem;
  color: var(--home-ink);
}

.home-subtitle {
  max-width: 760px;
  font-size: clamp(1.1rem, 2vw, 1.55rem);
  line-height: 1.45;
  color: var(--home-muted);
  margin-bottom: 1.7rem;
}

.home-actions {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.home-btn {
  display: inline-block;
  padding: 0.72rem 1rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 650;
  border: 1px solid var(--home-accent);
}

.home-btn.primary {
  background: var(--home-accent);
  color: white;
}

.home-btn.secondary {
  color: var(--home-accent);
  background: rgba(255,255,255,0.75);
}

.home-section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 4rem 1.5rem;
}

.home-section.narrow {
  max-width: 980px;
}

.home-about-grid {
  display: grid;
  grid-template-columns: minmax(130px, 2.5fr) minmax(0, 7.5fr);
  gap: 2rem;
  align-items: start;
}

.home-about-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 18px;
  background: var(--home-accent-soft);
  border: 1px solid var(--home-line);
  box-shadow: 0 8px 22px rgba(31, 41, 51, 0.05);
}

.home-section-title {
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  margin: 0 0 1.2rem;
  color: var(--home-ink);
}

.home-lede {
  font-size: 1.13rem;
  line-height: 1.75;
  color: var(--home-ink);
}

.home-muted {
  color: var(--home-muted);
}

.home-two-col {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2.2rem;
  align-items: center;
}

.home-portrait {
  border-radius: 22px;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: var(--home-accent-soft);
  border: 1px solid var(--home-line);
}

.home-list-links {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.2rem;
}

.home-list-links a {
  display: block;
  padding: 0.9rem 1rem;
  border: 1px solid var(--home-line);
  border-radius: 14px;
  text-decoration: none;
  color: var(--home-ink);
  background: white;
}

.home-list-links a span {
  color: var(--home-muted);
}

@media (max-width: 820px) {
  .home-two-col,
  .home-about-grid {
    grid-template-columns: 1fr;
  }

  .home-hero {
    min-height: auto;
  }
}


/* Research subpage */
.research-subpage {
  --research-accent: #426b73;
  --research-accent-soft: #e7f0f1;
  --research-ink: #1f2933;
  --research-muted: #5f6f7a;
  --research-line: #d7e1e4;
  --research-bg: #ffffff;
}

.research-subpage-intro,
.research-subpage-section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 3.5rem 1.5rem;
}

.research-subpage-intro {
  padding-top: 2rem;
  padding-bottom: 2.5rem;
}

.research-kicker {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  color: var(--research-accent);
  font-weight: 700;
  margin-bottom: 0.9rem;
}

.research-title {
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 0.98;
  margin: 0 0 1.15rem;
  color: var(--research-ink);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.research-lede {
  max-width: 900px;
  font-size: 1.12rem;
  line-height: 1.75;
  color: var(--research-ink);
}

.research-muted {
  color: var(--research-muted);
}

.research-band {
  background: #f7fafb;
  border-top: 1px solid var(--research-line);
  border-bottom: 1px solid var(--research-line);
}

.research-section-title {
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  margin: 0 0 1.2rem;
  color: var(--research-ink);
}

.research-subpage-section p,
.research-subpage-section li {
  line-height: 1.65;
}

.demo-button,
.publication-links a {
  font-weight: 650;
  text-decoration: none;
  color: var(--research-accent);
}

.demo-button {
  display: inline-block;
  margin-top: 0.6rem;
  padding: 0.7rem 1rem;
  border: 1px solid var(--research-accent);
  border-radius: 999px;
  background: var(--research-accent-soft);
}

/* Publication cards
   Adjust image size/aspect ratio by changing:
   - --publication-image-width
   - --publication-image-aspect
*/
.publication-list {
  display: grid;
  gap: 1.25rem;
}

.publication-item {
  --publication-image-width: 180px;

  display: grid;
  grid-template-columns: var(--publication-image-width) minmax(0, 1fr);
  gap: 1.25rem;
  align-items: center;
  background: var(--research-bg);
  border: 1px solid var(--research-line);
  border-radius: 18px;
  padding: 1rem;
  box-shadow: 0 8px 22px rgba(31, 41, 51, 0.05);
}

.publication-snapshot-link {
  display: block;
  width: 100%;
  border-radius: 12px;
  text-decoration: none;
  line-height: 0;
}

.publication-snapshot-link:focus-visible {
  outline: 3px solid #426b73;
  outline-offset: 4px;
}

.publication-snapshot {
  width: 100%;
  height: auto;
  /*aspect-ratio: var(--publication-image-aspect);*/
  display: block;
  border-radius: var(--publication-border-radius, 12px);
  border: var(--publication-border, 1px solid #d7e1e4);
  background: var(--publication-background, #e7f0f1);
  transition: transform 0.15s ease, filter 0.15s ease;
}

.publication-snapshot-link:hover .publication-snapshot {
  transform: translateY(-2px);
  filter: brightness(0.96);
}

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

.title-link h3 {
  margin: 0 0 0.35rem;
  color: #1f2933;
  transition:
    color 0.15s ease,
    transform 0.15s ease;
}

.title-link:hover h3 {
  color: #426b73;
  transform: translateX(2px);
}

.title-link:focus-visible {
  outline: 2px solid #426b73;
  outline-offset: 4px;
  border-radius: 4px;
}

.publication-detail h3 {
  display: flex;
  flex-direction: column;
  justify-content: center;
  font-size: 1.12rem;
  color: #1f2933;
  margin-top: 0.5rem;
}

.publication-meta {
  margin-bottom: 0.5rem;
  color: var(--research-muted);/*#5f6f7a;*/
  font-size: 0.95rem;
  line-height: 1.55;
}

.publication-description {
  margin-bottom: 0.5rem;
  color: var(--research-ink);/*#1f2933;*/
  line-height: 1.65;
}

@media (max-width: 720px) {
  .research-title {
    font-size: clamp(2.2rem, 12vw, 3.2rem);
  }

  .publication-item {
    grid-template-columns: 1fr;
  }

  .publication-snapshot-link {
    max-width: 420px;
  }
}



/* Other pages: Education, Engagements */

.site-page {
  --site-accent: #426b73;
  --site-accent-soft: #e7f0f1;
  --site-ink: #1f2933;
  --site-muted: #5f6f7a;
  --site-line: #d7e1e4;
  --site-bg: #ffffff;
}

.site-intro,
.site-section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 3.5rem 1.5rem;
}

.site-intro {
  padding-top: 2rem;
  padding-bottom: 2.5rem;
}

.site-kicker {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  color: var(--site-accent);
  font-weight: 700;
  margin-bottom: 0.9rem;
}

.site-intro h2 {
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1;
  margin: 0 0 1.2rem;
  color: var(--site-ink);
}

.site-lede {
  max-width: 900px;
  font-size: 1.12rem;
  line-height: 1.75;
  color: var(--site-ink);
}

.site-muted {
  color: var(--site-muted);
}

.site-band {
  background: #f7fafb;
  border-top: 1px solid var(--site-line);
  border-bottom: 1px solid var(--site-line);
}

.site-section-title {
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  margin: 0 0 1.2rem;
  color: var(--site-ink);
}

.site-section p,
.site-section li {
  line-height: 1.65;
}

/* FAQ */
.faq-section {
  max-width: 920px;
  margin: 0 auto;
  padding: 1.5rem 1.5rem 3rem 1.5rem;
}

details.faq-item {
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: #ffffff;
  margin: 0.75rem 0;
  padding: 0.95rem 1.1rem;
  box-shadow: 0 3px 12px rgba(15, 23, 42, 0.04);
}

details.faq-item[open] {
  border-color: #cbd5e1;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.07);
}

details.faq-item summary {
  cursor: pointer;
  font-weight: 650;
  color: #111827;
  list-style: none;
}

details.faq-item summary::-webkit-details-marker {
  display: none;
}

details.faq-item summary::after {
  content: "+";
  float: right;
  font-weight: 500;
  color: #64748b;
}

details.faq-item[open] summary::after {
  content: "−";
}

.faq-answer {
  margin-top: 0.85rem;
  color: #374151;
  line-height: 1.65;
}


.faq-section-title {
  font-size: clamp(1.25rem, 2.2vw, 1.65rem);
  margin: 2.2rem 0 1rem;
  color: var(--site-ink);
  font-weight: 750;
  letter-spacing: -0.02em;
}

.faq-section-title:first-child {
  margin-top: 0;
}

.faq-note {
  margin-top: 2.5rem;
  padding: 1rem 1.1rem;
  border-left: 4px solid #94a3b8;
  background: #f8fafc;
  color: #475569;
  border-radius: 10px;
}


/* Education page */
.education-page {
  --education-accent: #426b73;
  --education-accent-soft: #e7f0f1;
  --education-ink: #1f2933;
  --education-muted: #5f6f7a;
  --education-line: #d7e1e4;
  --education-bg: #ffffff;
}

.education-section-lede {
  max-width: 880px;
  font-size: 1.04rem;
  line-height: 1.75;
  color: var(--education-ink);
  margin-bottom: 1.8rem;
}

.education-theme-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.education-theme-card,
.teaching-card,
.supervision-card {
  background: var(--education-bg);
  border: 1px solid var(--education-line);
  border-radius: 18px;
  padding: 1.25rem;
  box-shadow: 0 8px 22px rgba(31, 41, 51, 0.05);
}

.education-theme-card {
  min-height: 260px;
}

.education-card-kicker,
.teaching-card-meta {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  font-weight: 750;
  color: var(--education-accent);
  margin-bottom: 0.75rem;
}

.education-theme-card h3,
.teaching-card h3,
.education-practice-item h3,
.supervision-card h3 {
  color: var(--education-ink);
  margin: 0 0 0.75rem;
  letter-spacing: -0.02em;
}

.education-theme-card p,
.teaching-card p,
.education-practice-item p,
.supervision-card p,
.supervision-card li {
  color: var(--education-ink);
  line-height: 1.65;
}

.teaching-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.teaching-card {
  display: flex;
  flex-direction: column;
  min-height: 330px;
}

.teaching-card p {
  flex: 1;
}

.teaching-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1rem;
}

.teaching-tags span {
  display: inline-block;
  border: 1px solid var(--education-line);
  background: var(--education-accent-soft);
  color: var(--education-accent);
  border-radius: 999px;
  padding: 0.28rem 0.62rem;
  font-size: 0.78rem;
  font-weight: 650;
}

.education-practice-list {
  display: grid;
  gap: 0.9rem;
}

.education-practice-item {
  border-left: 4px solid var(--education-accent);
  background: #f7fafb;
  border-radius: 14px;
  padding: 1rem 1.15rem;
}

.supervision-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1.2fr;
  gap: 1rem;
}

.supervision-card ul {
  margin: 0.4rem 0 0 1.2rem;
  padding: 0;
}

@media (max-width: 980px) {
  .education-theme-grid,
  .teaching-card-grid,
  .supervision-grid {
    grid-template-columns: 1fr;
  }

  .education-theme-card,
  .teaching-card {
    min-height: auto;
  }
}
