/* =========================
   BASE
========================= */

:root {
  --accent: #0a4678;
  --accent-soft: rgba(10, 70, 120, 0.35);
  --accent-strong: rgba(10, 70, 120, 0.8);
  --text: #222;
  --text-soft: #333;
  --muted: #666;
  --surface: #ddd;
  --background: #f6f6f6;
  --line: #d3d3d3;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: var(--background);
  color: var(--text);
}

/* =========================
   LANGUAGE BAR
========================= */

.language-bar {
  background: var(--accent);
  color: #fff;
  font-size: 0.85rem;
}

.language-inner {
  max-width: 760px;
  margin: auto;
  padding: 6px 20px;
  text-align: right;
}

.language-inner a {
  color: #fff;
  text-decoration: none;
  margin-left: 10px;
  font-weight: 500;
}

.language-inner a:hover {
  text-decoration: underline;
}

/* =========================
   HEADER
========================= */

header {
  text-align: center;
  padding: 70px 20px 50px 20px;
}

h1 {
  font-size: 2.4rem;
  letter-spacing: 0.02em;
  margin: 6px 0 10px 0;
  color: var(--accent);
  font-weight: 600;
}

.tagline {
  margin-top: 6px;
  color: var(--muted);
  font-size: 1.1rem;
}

/* =========================
   MAIN LAYOUT
========================= */

main {
  max-width: 760px;
  margin: auto;
  padding: 20px;
}

section {
  max-width: 720px;
  margin: 60px auto;
  padding: 0 20px;
}

.about,
.projects {
  text-align: justify;
  hyphens: auto;
  margin-bottom: 60px;
}

/* =========================
   TYPOGRAPHY
========================= */

.about h2,
.projects h2,
#impressum h2,
#datenschutz h2 {
  margin-bottom: 18px;
  color: var(--accent);
}

.about p,
.projects p,
#impressum p,
#datenschutz p {
  letter-spacing: -0.02em;
  line-height: 1.7;
  margin: 0 0 16px 0;
  color: var(--text-soft);
}

#impressum,
#datenschutz {
  font-size: 0.95rem;
}

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

ul,
ol {
  padding-left: 1.2em;
}

li {
  text-align: left;
  list-style-position: outside;
  line-height: 1.6;
  margin-bottom: 8px;
}

li::marker {
  color: var(--muted);
}

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

.profiles {
  max-width: 720px;
  margin: 60px auto;
  padding: 0 20px;
}

.links {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  max-width: 720px;
  margin: 40px auto;
}

.links a {
  display: flex;
  align-items: center;
  justify-content: center;

  min-height: 42px;
  padding: 10px 16px;
  box-sizing: border-box;
  width: 100%;

  text-decoration: none;
  text-align: center;
  font-weight: 500;
  font-size: 0.95rem;
  line-height: 1.3;

  background: #ddd;
  color: #870066;
  border: 1px solid var(--accent);
  border-radius: 8px;
}

.links a:hover {
  background: var(--accent);
  color: #fff;
}

.links .external-note {
  grid-column: 1 / -1;
  margin-top: 20px;
}

@media (min-width: 700px) {
  .links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

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

.about a,
.projects a,
footer a,
#impressum a,
#datenschutz a {
  color: #444;
  text-decoration: underline;
  text-decoration-color: var(--accent-soft);
  text-underline-offset: 2px;
}

.about a:hover,
.projects a:hover,
footer a:hover,
#impressum a:hover,
#datenschutz a:hover {
  color: var(--accent);
  text-decoration-color: var(--accent-strong);
}

/* =========================
   FOOTER
========================= */

footer {
  text-align: center;
  padding: 30px;
  color: var(--muted);
}

.identifiers {
  margin-top: 14px;
  font-size: 0.85rem;
  color: #555;
}

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

.social {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 24px;
}

.social a {
  display: inline-flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--accent);
  border-radius: 50%;
  transition: all 0.2s ease;
}

.social a:hover {
  background: var(--accent);
}

.social img {
  width: 21px;
  height: 21px;
  filter: invert(17%);
}

.social a:hover img {
  filter: invert(1);
}

/* =========================
   LEGAL
========================= */

.legal-separator {
  border: none;
  border-top: 1px solid var(--line);
  margin: 60px auto 30px auto;
  max-width: 720px;
}

#impressum,
#datenschutz {
  max-width: 720px;
  margin: 45px auto 60px auto;
  padding: 0 20px;
}

#impressum {
  margin-top: 30px;
}

.mail-imprint {
  overflow-wrap: anywhere;
}

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

@media (max-width: 520px) {
  header {
    padding: 56px 18px 38px 18px;
  }

  h1 {
    font-size: 2rem;
  }

  main {
    padding: 16px;
  }

  section,
  #impressum,
  #datenschutz {
    margin: 44px auto;
    padding: 0 16px;
  }

  .legal-separator {
    margin-top: 46px;
  }
}

/* =========================
   RESEARCH EVOLUTION
========================= */

.research-evolution {
  text-align: justify;
  hyphens: auto;
  margin-bottom: 60px;
}

.research-evolution h2 {
  margin-bottom: 18px;
  color: var(--accent);
}

.research-evolution p {
  letter-spacing: -0.02em;
  line-height: 1.7;
  margin: 0 0 16px 0;
  color: var(--text-soft);
}

.evolution-map {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 14px;
  align-items: stretch;
  margin: 34px 0 30px 0;
}

.evolution-step {
  background: rgba(255, 255, 255, 0.48);
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent);
  border-radius: 10px;
  padding: 18px 16px;
  box-sizing: border-box;
}

.evolution-step h3 {
  margin: 4px 0 10px 0;
  color: var(--accent);
  font-size: 1.05rem;
}

.evolution-step p {
  text-align: left;
  margin-bottom: 0;
  font-size: 0.92rem;
  line-height: 1.55;
}

.step-label {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.evolution-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 1.3rem;
  line-height: 1;
}

.research-details {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
  margin-top: 22px;
}

.research-details summary {
  cursor: pointer;
  color: var(--accent);
  font-weight: 600;
}

.research-details p:first-of-type {
  margin-top: 18px;
}

.research-details ul {
  margin: 10px 0 22px 0;
  padding-left: 1.35em;
}

.research-details li {
  line-height: 1.6;
  margin-bottom: 8px;
}

.research-details a,
.research-evolution a {
  color: #444;
  text-decoration: underline;
  text-decoration-color: var(--accent-soft);
  text-underline-offset: 2px;
}

.research-details a:hover,
.research-evolution a:hover {
  color: var(--accent);
  text-decoration-color: var(--accent-strong);
}

@media (max-width: 760px) {
  .evolution-map {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .evolution-arrow {
    transform: rotate(90deg);
    min-height: 18px;
  }
}
