/* Shared public layout. Branding, introduction and content use one outer grid. */
:root {
  --wrap: 1160px;
  --ink: #183d35;
  --text: #344b44;
  --muted: #61736c;
  --accent: #23634f;
  --line: #d9e2dc;
  --soft: #f2f6f1;
  --paper: #f8faf7;
  --body: 17px;
  --section: 29px;
  --item: 23px;
}
body { background: #fff; letter-spacing: -.02em; }
.wrap { width: min(var(--wrap), calc(100% - 64px)); margin-inline: auto; }
.button { border-radius: 5px; box-shadow: none; }
.text-link { line-height: 1.6; }

/* The university mark and institute name form one coherent lockup. */
.site-header { border-top: 3px solid var(--ink); background: #fff; box-shadow: none; }
.site-header .header-inner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  min-height: 88px;
  gap: 24px;
}
.site-header .brand {
  display: flex;
  align-items: center;
  gap: 17px;
  min-width: 0;
  max-width: 390px;
}
.site-header .brand-mark { display: flex; align-items: center; flex: none; }
.site-header .university-brand {
  display: block;
  width: 140px;
  height: auto;
  max-width: none;
  max-height: none;
  object-fit: contain;
}
.site-header .brand-text { display: flex; flex-direction: column; min-width: 0; gap: 3px; }
.site-header .has-logo .brand-text { border-left: 1px solid var(--line); padding-left: 17px; }
.site-header .brand-sub { font-size: 12px; line-height: 1.4; color: var(--muted); }
.site-header .brand-name {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -.04em;
  word-break: keep-all;
  overflow-wrap: anywhere;
  text-wrap: pretty;
}
.site-header .main-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 20px;
  padding: 0;
}
.site-header .main-nav a {
  display: flex;
  align-items: center;
  min-height: 48px;
  max-width: none;
  padding: 5px 0;
  font-size: 15px;
  line-height: 1.5;
  white-space: nowrap;
}
.site-header .header-actions { display: flex; align-items: center; gap: 8px; margin: 0; }
.site-header .header-search,
.site-header .language-switch { width: 42px; min-width: 42px; height: 42px; min-height: 42px; }
.site-header .language-switch { border: 0; border-radius: 5px; font-size: 13px; padding: 5px; }
.site-header .header-write {
  min-height: 42px;
  height: auto;
  padding: 9px 13px;
  border-radius: 5px;
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  white-space: nowrap;
}
.site-header .header-write:hover { border-color: #194b3c; background: #194b3c; }
.site-header .header-write .header-write-label { display: inline; }
.site-header .header-write .header-write-short { display: none; }
.site-header .header-write .write-icon { display: block; width: 17px; height: 17px; }
.site-header .menu-toggle { display: none; }
.site-header .main-nav .mobile-nav-search { display: none; }
html[lang='en'] .site-header .brand-sub { max-width: none; font-size: 12px; }
html[lang='en'] .site-header .brand-name { font-size: 23px; line-height: 1.25; letter-spacing: .02em; }
html[lang='en'] .site-header .main-nav { gap: 16px; }
html[lang='en'] .site-header .main-nav a { font-size: 14px; }

/* Explain the institute once, then offer a clear route for each visitor. */
.home-hero { padding: 48px 0 40px; border-bottom: 1px solid var(--line); background: var(--paper); }
.home-introduction { max-width: 940px; min-width: 0; }
.home-hero .hero-affiliation { font-size: 13px; font-weight: 550; line-height: 1.6; margin: 0 0 14px; color: var(--accent); }
.home-hero .hero-title { margin: 0; font-size: 42px; line-height: 1.25; font-weight: 720; letter-spacing: -.045em; text-wrap: pretty; }
.home-hero .hero-intro { max-width: 900px; margin: 18px 0 0; font-size: 23px; line-height: 1.6; color: var(--ink); font-weight: 450; text-wrap: pretty; }
.home-hero .hero-description { max-width: 800px; margin: 10px 0 0; font-size: 16px; line-height: 1.8; color: var(--muted); }
.home-hero .hero-actions { display: flex; flex-direction: row; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.home-hero .hero-actions .button { min-height: 48px; margin: 0; padding: 11px 20px; border: 1px solid var(--accent); border-radius: 5px; font-size: 15px; line-height: 1.6; background: var(--accent); color: #fff; }
.home-hero .hero-actions .button.light { border-color: #bfcec4; background: transparent; color: var(--accent); }
.home-hero .hero-actions .button:hover { background: #194b3c; }
.home-hero .hero-actions .button.light:hover { background: #eaf1e9; }
.audience-paths { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 30px; padding-top: 25px; border-top: 1px solid #cddbd0; }
.audience-path { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; padding: 0 30px; }
.audience-path:first-child { padding-left: 0; }
.audience-path:last-child { padding-right: 0; }
.audience-path + .audience-path { border-left: 1px solid var(--line); }
.audience-kind { color: var(--accent); font-size: 12px; font-weight: 600; line-height: 1.6; }
.audience-path h2 { margin: 5px 0 9px; font-size: 21px; font-weight: 650; line-height: 1.45; text-wrap: pretty; }
.audience-path p { margin: 0 0 10px; color: var(--muted); font-size: 15px; line-height: 1.75; }
.audience-path > .text-link { min-height: 36px; margin-top: auto; gap: 9px; font-size: 14px; }
.audience-path:hover h2,
.audience-path:focus-visible h2 { color: var(--accent); text-decoration: underline; text-underline-offset: 5px; }
.audience-path:focus-visible { border-radius: 2px; outline-offset: 7px; }
.hero-activity { margin: 38px 0 0; border-top: 1px solid var(--line); padding-top: 30px; max-width: 860px; }
.hero-activity > img { width: 100%; max-height: 340px; object-fit: cover; border-radius: 5px; }
.hero-activity figcaption { margin-top: 10px; font-size: 14px; line-height: 1.7; color: var(--muted); }
html[lang='en'] .home-hero .hero-title { font-size: 40px; line-height: 1.2; max-width: 35ch; letter-spacing: -.035em; word-break: normal; }
html[lang='en'] .home-hero .hero-intro { font-size: 22px; line-height: 1.55; }
html[lang='en'] .audience-path h2 { font-size: 20px; line-height: 1.4; word-break: normal; }

/* Home sections retain the same starting line, without a spare title column. */
.home-section { padding: 58px 0; }
.home-hero + .home-section { padding-top: 44px; }
.home-section .editorial-section { display: block; }
.home-section .section-intro { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 30px; align-items: start; padding: 0; margin-bottom: 27px; }
.home-section .section-title { grid-column: 1; font-size: 29px; font-weight: 650; line-height: 1.45; }
.home-section .section-intro > p { grid-column: 1; grid-row: 2; max-width: 700px; margin: 0; font-size: 16px; line-height: 1.8; }
.home-section .section-intro > .text-link { grid-column: 2; grid-row: 1; justify-self: end; align-self: center; max-width: none; margin: 0; font-size: 14px; }
.home-section .section-contribute { grid-column: 2; grid-row: 2; justify-self: end; margin: 0; }
.home-news-content { min-width: 0; }
.home-news-topics { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; margin: 0 0 18px; }
.home-news-topics a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 3px 0;
  color: var(--accent);
  font-size: 14px;
  font-weight: 550;
  line-height: 1.6;
  text-decoration: underline;
  text-decoration-color: #a7bbb0;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}
.home-news-topics a:hover { color: var(--ink); text-decoration-color: currentColor; }
.home-news-content .event-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.home-project-list,
.home-section .research-feature-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 38px; border: 0; }
.home-project-list .project-card,
.home-section .research-feature { border-top: 1px solid var(--ink); border-bottom: 1px solid var(--line); border-radius: 0; background: none; box-shadow: none; }
.home-project-list .project-card-link,
.home-section .research-feature { padding: 25px 0 26px; }
.home-project-list .project-card-link { align-items: start; gap: 18px; }
.home-project-list .project-card-link.has-image { grid-template-columns: minmax(0, 1fr) 24px; }
.home-project-list .project-thumbnail { grid-column: 1 / -1; width: 100%; max-height: 220px; aspect-ratio: 16 / 9; border-radius: 5px; }
.home-project-list .project-card h3,
.home-section .research-feature h3 { font-size: 23px; line-height: 1.55; margin: 15px 0 16px; font-weight: 650; }
.home-project-list .row-arrow { width: 24px; height: 24px; padding: 0; background: none; border-radius: 0; }
.home-section .research-feature.has-image { display: block; }
.home-section .paper-thumbnail { width: 120px; height: 90px; object-fit: cover; margin-bottom: 20px; }
.home-section .event-grid { gap: 28px; }
.home-section .event-card .event-content h3 { font-size: 23px; line-height: 1.55; }
.home-section .event-cover.event-placeholder { padding: 18px 21px; border: 0; border-radius: 5px; background: var(--soft); }
.home-section .event-card-content { padding-top: 20px; }
.home-section .event-meta { font-size: 14px; }
.home-section .field-grid { gap: 32px 48px; }
.home-section .field-card { padding: 23px 0 0; border-radius: 0; background: none; border: 0; border-top: 1px solid var(--line); }

.site-footer { background: var(--soft); padding: 42px 0 24px; }
.site-footer .footer-main { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 56px; align-items: start; padding-bottom: 27px; }
.site-footer .footer-brand-name { font-size: 18px; line-height: 1.6; }
.site-footer .footer-en { font-size: 13px; line-height: 1.75; }
.site-footer .footer-info { font-size: 14px; line-height: 1.85; }
.site-footer .footer-bottom { gap: 8px 24px; }
.site-footer .footer-utilities { gap: 8px 20px; }

@media (max-width: 1200px) {
  .site-header .header-inner { grid-template-columns: minmax(0, 1fr) auto; min-height: 82px; gap: 18px; }
  .site-header .brand { max-width: none; }
  .site-header .main-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; padding: 12px 32px 22px; background: #fff; border-bottom: 1px solid var(--line); max-height: calc(100dvh - 88px); overflow-y: auto; box-shadow: 0 12px 20px #183d3508; }
  .site-header .main-nav.is-open { display: flex; align-items: stretch; flex-direction: column; gap: 0; }
  .site-header .main-nav a { min-height: 48px; width: 100%; padding: 12px; border-bottom: 1px solid var(--line); font-size: 16px; white-space: normal; }
  .site-header .main-nav a[aria-current='page'] { background: var(--soft); border-radius: 4px; }
  .site-header .menu-toggle { display: block; width: 44px; height: 44px; margin: 0; padding: 10px; border-radius: 5px; }
  .site-header .main-nav .mobile-nav-search { display: flex; }
  .home-hero .hero-title { font-size: 40px; }
  .home-hero .hero-intro { font-size: 22px; }
  .no-js .site-header { position: static; }
  .no-js .site-header .header-inner { padding-block: 15px; }
  .no-js .site-header .main-nav { display: flex; position: static; grid-column: 1 / -1; grid-row: 2; max-height: none; flex-direction: row; flex-wrap: wrap; gap: 3px 12px; padding: 8px 0 0; border: 0; box-shadow: none; }
  .no-js .site-header .main-nav a { width: auto; }
  .no-js .site-header .menu-toggle { display: none; }
}
@media (max-width: 900px) {
  .home-hero { padding: 42px 0 34px; }
  .audience-path { padding-inline: 23px; }
  .audience-path h2 { font-size: 20px; }
  .home-project-list,
  .home-section .research-feature-list,
  .home-section .event-grid { gap: 28px; }
}
@media (max-width: 760px) {
  .wrap { width: calc(100% - 40px); }
  .site-header .university-brand { width: 120px; }
  .site-header .brand { gap: 13px; }
  .site-header .has-logo .brand-text { padding-left: 13px; }
  .site-header .brand-name { font-size: 18px; }
  .site-header .brand-sub { font-size: 11px; }
  .site-header .header-actions { gap: 5px; }
  .site-header .header-write { padding: 8px 10px; font-size: 13px; }
  .site-header .header-search { display: none; }
  .site-header .main-nav { padding-inline: 20px; }
  .home-hero { padding: 32px 0 28px; }
  .home-hero .hero-affiliation { margin-bottom: 13px; font-size: 12px; }
  .home-hero .hero-title { font-size: 36px; line-height: 1.3; }
  .home-hero .hero-intro { font-size: 21px; margin-top: 17px; line-height: 1.6; }
  .home-hero .hero-description { font-size: 16px; line-height: 1.8; margin-top: 10px; }
  .home-hero .hero-actions { margin-top: 25px; gap: 10px; }
  .home-hero .hero-actions .button { font-size: 14px; padding: 11px 16px; min-height: 46px; }
  .audience-paths { grid-template-columns: minmax(0, 1fr); margin-top: 25px; padding-top: 0; }
  .audience-path { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 0 16px; padding: 20px 0; }
  .audience-path + .audience-path { border-left: 0; border-top: 1px solid var(--line); }
  .audience-path:last-child { padding-bottom: 0; }
  .audience-kind { grid-column: 1; }
  .audience-path h2 { grid-column: 1; margin: 5px 0 0; font-size: 20px; }
  .audience-path p { grid-column: 1 / -1; margin: 8px 0 0; font-size: 15px; line-height: 1.8; }
  .audience-path > .text-link { grid-column: 2; grid-row: 1 / 3; align-self: center; margin: 0; min-height: 44px; }
  .hero-activity { margin-top: 28px; padding-top: 25px; }
  .home-section { padding: 40px 0; }
  .home-hero + .home-section { padding-top: 34px; }
  .home-news-topics { gap: 3px 20px; margin-bottom: 15px; }
  .home-news-topics a { min-height: 40px; }
  .home-section .section-intro { grid-template-columns: minmax(0, 1fr); gap: 12px; margin-bottom: 23px; }
  .home-section .section-title { font-size: 26px; }
  .home-section .section-intro > p { grid-row: auto; font-size: 16px; }
  .home-section .section-intro > .text-link,
  .home-section .section-contribute { grid-column: 1; grid-row: auto; justify-self: start; margin: 0; }
  .home-project-list,
  .home-section .research-feature-list,
  .home-section .event-grid { grid-template-columns: minmax(0, 1fr); gap: 25px; }
  .home-project-list .project-card h3,
  .home-section .research-feature h3,
  .home-section .event-card .event-content h3 { font-size: 22px; line-height: 1.55; }
  .home-project-list .project-card-link,
  .home-section .research-feature { padding: 23px 0; }
  .site-footer { padding: 32px 0 22px; }
  .site-footer .footer-main { grid-template-columns: minmax(0, 1fr); gap: 25px; }
  .site-footer .footer-brand-name { font-size: 17px; }
  .site-footer .footer-bottom > span:nth-child(2) { margin-left: 0; }
  .site-footer .footer-utilities { margin: 0; justify-content: flex-start; }
  html[lang='en'] .home-hero .hero-title { font-size: 34px; max-width: 28ch; }
  html[lang='en'] .home-hero .hero-intro { font-size: 21px; }
}
@media (max-width: 600px) {
  html { scroll-padding-top: 24px; }
  .site-header { position: relative; }
  .site-header .header-inner { grid-template-columns: minmax(0, 1fr); gap: 0; min-height: 0; padding: 15px 0 10px; }
  .site-header .brand { grid-column: 1; grid-row: 1; justify-self: start; width: 100%; }
  .site-header .brand-name { font-size: 18px; }
  .site-header .header-actions { grid-column: 1; grid-row: 2; justify-self: end; gap: 7px; padding-top: 12px; }
  .site-header .header-search { display: inline-flex; }
  .site-header .header-write { width: auto; min-width: 0; padding: 8px 12px; }
  .site-header .header-write .header-write-label { display: inline; }
  .site-header .header-write .header-write-short { display: none; }
  .site-header .header-write .write-icon { display: block; }
  .site-header .main-nav { max-height: 65dvh; }
  .no-js .site-header .main-nav { grid-row: 3; max-height: none; }
  .no-js .site-header .header-actions { grid-column: 1; grid-row: 2; }
  .home-hero .hero-title { font-size: 34px; }
}
@media (max-width: 420px) {
  .site-header .university-brand { width: 110px; }
  .site-header .brand { gap: 12px; }
  .site-header .has-logo .brand-text { padding-left: 12px; }
  .site-header .brand-name { font-size: 17px; }
  .site-header .brand-sub { font-size: 11px; }
  .home-hero .hero-title { font-size: 31px; }
  .home-hero .hero-intro { font-size: 21px; }
  .home-section .section-title { font-size: 25px; }
  html[lang='en'] .home-hero .hero-title { font-size: 32px; }
}
@media (max-width: 350px) {
  .wrap { width: calc(100% - 32px); }
  .site-header .university-brand { width: 100px; }
  .site-header .brand { gap: 9px; }
  .site-header .has-logo .brand-text { padding-left: 9px; }
  .site-header .brand-name { font-size: 16px; }
  .home-hero .hero-title { font-size: 28px; }
}
@media print {
  .site-header { position: static; }
  .site-header .header-inner { display: block; min-height: 0; }
  .site-header .brand { max-width: none; }
  .site-header .header-actions,
  .site-header .main-nav,
  .home-hero .hero-actions { display: none !important; }
  .home-hero { padding: 25px 0; }
  .audience-paths { grid-template-columns: repeat(3, minmax(0, 1fr)); break-inside: avoid; }
  .audience-path { display: block; padding: 0 20px; }
  .audience-path + .audience-path { border-top: 0; border-left: 1px solid var(--line); }
  .audience-path > .text-link { display: none; }
  .home-section { padding: 25px 0; }
  .home-hero + .home-section { padding-top: 25px; }
}
