:root {
  --bg: #f4f8ff;
  --surface: #ffffff;
  --surface-soft: #f8fbff;
  --text: #0f172a;
  --muted: #475569;
  --accent: #2563eb;
  --accent-strong: #0f3d91;
  --accent-soft: #dbeafe;
  --border: #dbe4f0;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background: linear-gradient(135deg, #f8fbff 0%, #eef5ff 45%, #fdfefe 100%);
  line-height: 1.7;
}

a {
  color: var(--accent);
  text-decoration: none;
}

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

.site-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 24px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(219, 228, 240, 0.85);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.05);
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  color: var(--text);
}

.header-brand img {
  height: 46px;
  width: auto;
  display: block;
}

.nav-toggle {
  display: none;
}

.nav-toggle-label {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 44px;
  height: 44px;
  padding: 10px;
  border-radius: 999px;
  cursor: pointer;
}

.nav-toggle-label span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text);
  border-radius: 999px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.site-nav a {
  padding: 8px 10px;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 600;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.site-nav a:hover {
  background: var(--surface-soft);
  color: var(--accent);
}

@media (max-width: 760px) {
  .site-header {
    flex-wrap: wrap;
  }

  .nav-toggle-label {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    width: 100%;
    padding-top: 8px;
  }

  .site-nav ul {
    flex-direction: column;
    gap: 4px;
  }

  .site-nav a {
    display: block;
    padding: 10px 12px;
    border-radius: 12px;
  }

  .nav-toggle:checked ~ .site-nav {
    display: block;
  }
}

.page-content {
  flex: 1;
  padding: 36px 20px 72px;
}

.content-shell {
  max-width: 1100px;
  margin: 0 auto;
}

.app-page,
.member-page {
  max-width: 900px;
}

.app-header,
.member-header {
  margin-bottom: 1.5rem;
  display: grid;
  gap: 1rem;
}

.app-card,
.member-card {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

.app-image {
  width: 220px;
  max-width: 100%;
  border-radius: 0.75rem;
  object-fit: cover;
}

.member-card img {
  width: 160px;
  max-width: 100%;
  height: auto;
  border-radius: 0.75rem;
  object-fit: cover;
}

.app-meta,
.member-meta {
  color: #4b5563;
  margin: 0.5rem 0;
}

.app-links a,
.member-contact a {
  color: #1d4ed8;
  text-decoration: none;
}

.app-description,
.member-content {
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 24px;
  align-items: start;
}

.content-main {
  min-width: 0;
}

.content-sidebar {
  display: grid;
  gap: 16px;
  position: sticky;
  top: 96px;
}

.info-card {
  padding: 18px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.info-card img {
  width: 100%;
  display: block;
  border-radius: 12px;
  margin-bottom: 12px;
}

.info-card h2 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.info-card p,
.info-card address {
  margin: 0;
  color: var(--muted);
  font-style: normal;
  line-height: 1.6;
}

.mastodon-embed {
  width: 100%;
  min-height: 420px;
  border: 0;
  border-radius: 12px;
  background: white;
}

.hero-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding: 24px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(15, 118, 110, 0.06));
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.eyebrow {
  display: inline-block;
  margin: 0 0 8px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero-card h1 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.15;
}

.hero-card p {
  color: var(--muted);
  margin: 0 0 12px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button.primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.2);
}

.button.secondary {
  background: white;
  color: var(--text);
  border: 1px solid var(--border);
}

.hero-image {
  width: 100%;
  border-radius: 18px;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.14);
  display: block;
  margin-bottom: 2em;
}

.panel {
  margin-top: 24px;
  padding: 24px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.panel h2 {
  margin-top: 0;
  font-size: 1.25rem;
}

.logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
  align-items: center;
  margin-top: 16px;
}

.logo-grid a {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 94px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--surface-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.logo-grid a:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.logo-grid img {
  max-width: 100%;
  max-height: 72px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.project-list {
  list-style: none;
  padding: 0 !important;
  margin: 0;
  display: grid;
  gap: 12px;
}

.project-list li {
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--surface-soft);
  border: 1px solid var(--border);
}

.project-list img {
  max-width: 180px !important;
}

.search-input {
  width: 100%;
  max-width: 420px;
  padding: 10px 14px;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  margin-bottom: 18px;
}

.publication-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.publication-item {
  margin-left: -1em;
}

.publication-title {
  font-weight: 700;
  margin: 0;
}

.publication-meta {
  color: #4b5563;
  margin: 0;
}

.publication-links a {
  color: #1d4ed8;
  text-decoration: none;
  margin-right: 1rem;
}

.publication-links a:hover {
  text-decoration: underline;
}

.content-shell h1,
.content-shell h2,
.content-shell h3 {
  color: var(--text);
  line-height: 1.25;
}

.content-shell h1 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  margin-top: 0;
}

.content-shell h2 {
  font-size: 1.25rem;
  margin-top: 2rem;
}

.content-shell p,
.content-shell ul,
.content-shell li {
  color: var(--muted);
}

.content-shell ul {
  padding-left: 1.2rem;
}

.content-shell img {
  max-width: 100%;
  height: auto;
}

.site-footer {
  padding: 28px 20px 36px;
  background: linear-gradient(135deg, #0f172a 0%, #14243d 100%);
  color: #e2e8f0;
}

.footer-grid {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.footer-grid div {
  margin: 0 24px;
}

.site-footer h2 {
  font-size: 1rem;
  margin: 0 0 10px;
  color: white;
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
}

.site-footer a {
  color: #cbd5e1;
}

.site-footer a:hover {
  color: white;
}

.footer-meta {
  max-width: 1100px;
  margin: 18px auto 0;
  padding-top: 16px;
  border-top: 1px solid rgba(226, 232, 240, 0.18);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  color: #cbd5e1;
}

.logo-inv {
  filter: grayscale(1) contrast(100) brightness(1) invert(65%);
}

.logo-xsmall {
  max-height: 15px;
  max-width: 15px;
}

.logo-small {
  max-height: 25px !important;
  max-width: 25px !important;
  display: inline !important;
  border-radius: 0px !important;
  margin-bottom: 0px !important;
  vertical-align: middle;
}

.loader {
  display: inline-block;
  width: 13px;
  aspect-ratio: 4;
  background: radial-gradient(circle closest-side,#000 90%,#0000) 0/calc(100%/3) 100% space;
  clip-path: inset(0 100% 0 0);
  animation: l1 1s steps(4) infinite;
}

.software-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}
.software-item {
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  background: #fff;
  padding: 1rem;
}
.software-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: inherit;
}
.software-link img {
  width: 160px;
  max-width: 100%;
  border-radius: 0.75rem;
  display: block;
}
.software-link h3 {
  margin: 0 0 0.35rem;
}
.software-link p {
  margin: 0;
  color: #4b5563;
}

/* Mastodon social media */
.mt-container {
    border: 1px solid lightgrey;
    border-radius: 10px;
    font-size: smaller;
    max-height: 78vh;
    /*max-height: 37%;*/
    text-align: justify;
}

.mt-post-preview {
    display: none !important;
}

.mt-post-counter-bar {
    display: none !important;
}

.mt-btn-violet.btn-see-more {
    border-radius: 20px !important;
    background-color: white !important;
    border: 1px solid var(--mt-color-btn-bg) !important;
    color: var(--mt-color-btn-bg) !important;
    font-size: smaller !important;
}

.mt-btn-violet.btn-refresh {
    display: none !important;
}
/* END Mastodon */

@keyframes l1 {to{clip-path: inset(0 -34% 0 0)}}

@media (max-width: 780px) {
  .site-header {
    align-items: flex-start;
  }

  .site-nav {
    width: 100%;
  }

  .content-grid {
    grid-template-columns: 1fr;
  }

  .content-sidebar {
    position: static;
  }

  .hero-card {
    grid-template-columns: 1fr;
  }
}
