/* ===== navigation banners ===== */

.navigation_banners {
    display: flex;
    justify-content: center;
    gap: 0.5em;
    margin: 0 0.1em 2em;
}

.navigation_grid {
    display: flex;
    gap: 10px;
    margin-bottom: 1.8em;
}

.banner_vertical,
.banner_horizontal {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    display: block;
    box-shadow: var(--shadow);
    text-decoration: none;
    border: 2px solid #fff;
    transition: transform 0.3s ease;
}

.banner_vertical {
    width: 280px;
    height: 370px;
}

.banner_horizontal {
    width: 100%;
    height: 140px;
}

.banner_vertical img,
.banner_horizontal img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    z-index: 0;
}

.banner_vertical:hover,
.banner_horizontal:hover {
    transform: scale(1.02);
}

.banner_vertical::after,
.banner_horizontal::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
    z-index: 1;
    pointer-events: none;
}

.banner_vertical::before,
.banner_horizontal::before {
    content: attr(data-label);
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: block;
    width: 90%;
    color: var(--surface);
    font-weight: bold;
    font-size: 1.3rem;
    font-variant: small-caps;
    line-height: 1.3;
    text-align: center;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.7);
    pointer-events: none;
    white-space: normal;
    word-wrap: break-word;
    z-index: 2;
}

/* banners with a separate phone image: hidden by default, shown on mobile */
.phone_banner {
    display: none;
}

/* ===== hero block (landing, AMOS) ===== */

.landing_block {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    width: 100%;
    max-width: 870px;
    margin: 0 auto;
    margin-bottom: 1em;
    overflow: hidden;
}

.rectangle {
    background: var(--surface);
    padding: 1.5em;
    padding-right: 180px;
    border-radius: var(--radius-lg);
    max-width: 100%;
}

.circle_cutout {
    width: 320px;
    aspect-ratio: 1;
    background: var(--bg);
    border-radius: 50%;
    display: grid;
    place-items: center;
    margin-left: -160px;
    z-index: 2;
}
.circle_cutout img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: contain;
}

.mobile_logo_daa {
    display: none;
}

/* ===== carousel ===== */

.carousel {
    width: 96%;
    aspect-ratio: 3/2;
    display: flex;
    gap: 1em;
    overflow-x: auto;
    margin: 1em auto;
    anchor-name: --carousel;
    scroll-snap-type: x mandatory;
    scroll-marker-group: after;
    box-shadow: var(--shadow);
    border: 2px solid #fff;
    object-fit: cover;
    border-radius: var(--radius);
}

.carousel::-webkit-scrollbar {
    display: none;
}

.carousel::scroll-button(right), .carousel::scroll-button(left) {
    content: "❯";
    border: none;
    background-color: var(--brand);
    color: var(--bg);
    height: 60px;
    width: 60px;
    border-radius: 50%;
    padding-bottom: .1em;
    cursor: pointer;
    position: fixed;
    position-anchor: --carousel;
    position-area: right center;
    translate: -50%;
    z-index: 1000;
}

.carousel::scroll-button(left) {
    content: "❮";
    position-area: left center;
    translate: 50%;
}

.carousel::scroll-marker-group {
    display: flex;
    justify-content: center;
    gap: .5em;
    margin-top: -3em;
}

.card::scroll-marker {
    content: "";
    height: 1em;
    width: 1em;
    background-color: #d5d5d5;
    border-radius: 50%;
}

.card::scroll-marker:target-current {
    background-color: var(--brand);
}

.card {
    scroll-snap-align: start;
    flex: 0 0 100%;
    aspect-ratio: 3/2;
    text-align: center;
    align-content: center;
}

.card img {
    width: 100%;
    aspect-ratio: 3/2;
}

/* ===== floating / grouped images ===== */

.wrap_image {
  height: 260px;
  margin-top: 5px;
  margin-bottom: 10px;
}

.wrap_image.left {
  float: left;
  margin-left: 0;
  margin-right: 20px;
}

.wrap_image.right {
  float: right;
  margin-right: 0;
  margin-left: 20px;
}

.figs_flex {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 14px;
    margin-bottom: 15px;
}

.figs_flex_image {
    max-height: 260px;
    width: auto;
    margin: 0;
}

.wrap_image figcaption,
.figs_flex_image figcaption{
  font-size: 0.9rem;
  margin-top: 6px;
  color: var(--brand);
  font-weight: bold;
  text-align: center;
}

@media screen and (max-width: 760px) {
    .wrap_image {
        float: none;
        display: block;
        width: 100%;
        margin-bottom: 15px;
        margin-top: 12px;
        max-width: 100%;
        text-align: center;
  }

    .wrap_image.wrap_image.left {
      float: none;
      margin-right: 0;
  }

    .wrap_image.wrap_image.right {
      float: none;
      margin-left: 0;
    }

    .wrap_image img,
    .figs_flex_image img {
        width: 100%;
        height: auto;
        display: block;
  }

    .figs_flex {
        flex-direction: column;
        width: 100%;
  }
}

/* ===== accordions (news, publications) ===== */

details {
    margin-bottom: 0.5em;
    width: 100%;
    border: 2px solid var(--bg);
    border-radius: 5px;
}

summary {
    padding: 0.25em;
    padding-left: 0.5em;
    cursor: pointer;
    background-color: var(--brand);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 5px;
}

summary:hover {
    background-color: var(--brand-dark);
}

summary .accordeon_title {
    color: var(--surface);
    font-weight: bold;
    font-size: 0.8rem;
    text-align: left;
}

summary .accordeon_date {
    margin-left: auto;
    color: var(--surface);
    font-weight: bold;
    font-size: 0.8rem;
    text-align: right;
}

summary::after {
    content: "❯";
    font-size: 1.2rem;
    margin-left: 0.5rem;
    margin-right: 0.5rem;
    color: var(--surface);
}

details[open] summary::after {
    transform: rotate(90deg);
}

.news_content {
    display: flex;
    gap: 1rem;
    background-color: var(--bg);
    padding: 0.5rem 2em 0.5rem;
}

.accordeon_content {
    display: block;
    gap: 1rem;
    background-color: var(--bg);
    padding: 0.5rem 2em 0.5rem;
}

.accordeon_text {
    font-size: 0.9rem;
    line-height: 1.4;
}

/* ===== lightbox ===== */

.thumb {
  max-height: 240px;
  object-fit: contain;
  cursor: pointer;
  border-radius: 5px;
  transition: transform 0.3s;
}

.thumb:hover {
  transform: scale(1.02);
}

.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 3050;
}

.lightbox a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.lightbox:target {
  display: flex;
}

.lightbox img {
  max-width: 100%;
  max-height: 100%;
}

.lightbox_figure {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 20px;

  max-width: 90vw;
  max-height: 90vh;
  z-index: 2000;
}

.lightbox_figure img {
  display: block;
  max-width: 75vw;
  max-height: 90vh;
  object-fit: contain;
}

.lightbox_caption {
  color: #000000;

  max-width: 320px;

  background: rgb(255, 255, 255);
  padding: 12px 14px;
  border-radius: 8px;

  user-select: text;
  -webkit-user-select: text;
  z-index: 2000;

  max-height: 80vh;
  overflow-y: auto;
}

.lightbox_x {
  position: fixed;
  top: 12px;
  right: 12px;
  color: #ffffff;
  font-size: 1.5rem;
  font-weight: bold;
  text-decoration: none;
  background: rgba(0,0,0,0.65);
  padding: 6px 12px;
  border-radius: 8px;
  z-index: 3050;
  cursor: pointer;
  line-height: 1.3;
  transition: background 0.2s color 0.2s;
}

.lightbox_x:hover {
  color: var(--brand);
  background: rgba(0,0,0,0.85);
}

.lightbox_caption strong {
    color: var(--brand);
    font-size: 1rem;
    margin-bottom: 5px;
}

.lightbox_caption p {
    line-height: 1.3;
}

.lightbox_caption::-webkit-scrollbar {
    width: 6px;
}

.lightbox_caption::-webkit-scrollbar-thumb {
    background: var(--brand);
    border-radius: 6px;
}

@media screen and (max-width: 760px) {
    .lightbox_figure {
    flex-direction: column;
    align-items: center;
    max-height: 90vh;
  }

    .lightbox_figure img {
    max-width: 100%;
    max-height: 60vh;
  }

    .lightbox_caption {
    max-width: 100%;
    max-height: 30vh;
  }
}

/* ===== contact cards (people, history, research topics) ===== */

.contact_grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 10px;
    margin-bottom: 2.5em;
}

.contact_card {
    background-color: var(--surface);
    border-radius: var(--radius-card);
    padding: 0px 10px 0px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
}

.contact_card_reversed {
    background-color: var(--brand);
    border-radius: var(--radius-card);
    padding: 0px 10px 0px;
    box-shadow: var(--shadow-sm);
    display: flex;
}

.contact_card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.contact_card img {
    border-radius: 50%;
    max-width: 100px;
    aspect-ratio: 1;
    object-fit: cover;
    border: 2px solid var(--brand);
}

.contact_email {
  color: var(--brand);
}

.contact_card .name {
    padding-top: 0.9em;
    padding-bottom: 0.2rem;
    font-size: 1.1rem;
}

.contact_content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.contact_info {
    align-items: center;
}

.contact_sheet h2 {
    margin: 0.75em 0 0.25em;
}

.info_card p {
    color: var(--surface);
    font-size: 1rem;
}

/* ===== news items (news pages, study page video) ===== */

.news_media {
    flex: 1;
}

.news_media img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    display: block;
}

.accordeon_tab {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.accordeon_icon {
    height: 25px;
    aspect-ratio: 1;
    object-fit: contain;
}

.news_content .accordeon_text {
    flex: 2;
}

.news_content .accordeon_text,
.news_content .accordeon_text p {
    hyphens: auto;
    font-size: 0.8rem;
}

.news_video {
    width: 90%;
    padding: 0.5rem;
    flex: none;
    margin: 0 auto;
}

.video_wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 4px;
}

.video_wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* ===== partner logos (landing, ago) ===== */

.collab_banners {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0;
}

.collab_banners:first-of-type {
    flex-direction: row;
}

.collab_banners:first-of-type .logo_horizontal {
    width: calc(50% - 10px);
    max-width: 200px;
}

.collab_banners:last-of-type {
    flex-direction: row;
}

.collab_banners:last-of-type .logo_square {
    width: calc(33.333% - 10px);
    max-width: 85px;
}

.logo_horizontal, .logo_square {
    position: relative;
    width: 25%;
    height: 90px;
    border-radius: var(--radius);
    overflow: hidden;
    display: block;
    text-decoration: none;
    border: 2px solid #fff;
    transition: transform 0.3s ease;
    background-color: var(--surface);
}

.logo_square {
    width: 90px;
}

.logo_horizontal img, .logo_square img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.logo_square img {
    object-fit: cover;
}

.logo_horizontal:hover, .logo_square:hover {
    transform: scale(1.02);
}

@media screen and (max-width: 760px) {
    .collab_banners:first-of-type .logo_horizontal {
        width: calc(50% - 10px);
    }

    .collab_banners:last-of-type .logo_square {
        width: calc(33.333% - 10px);
    }
}
