:root {
  --bg: #0f1117;
  --surface: #242836;
  --border: #2e3347;
  --accent: #ff6600;
  --text: #e2e8f0;
  --radius: 10px;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f7f7f7;
    --surface: #ffffff;
    --border: #d8dce8;
    --text: #1a1d2e;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.6;

  & a {
    color: var(--text);
  }
}

body > header {
  max-width: 900px;
  margin: 0 auto;
  padding: 60px 24px 40px;
  text-align: center;

  & .logo {
    width: 60px;
    height: 60px;
    object-fit: contain;
  }

  & h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    background: var(--accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
  }

  & p {
    max-width: 640px;
    margin: 0 auto;
    font-size: 16px;
  }

  & .authors {
    margin-top: 16px;
    font-size: 14px;
    opacity: 0.6;
  }

  & .affiliation {
    margin-top: 6px;
    font-size: 13px;
    opacity: 0.45;
  }

  & .supervisors {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-top: 16px;

    & p:first-child {
      font-size: 14px;
      opacity: 0.6;
    }

    & p + p {
      margin-top: 4px;
      font-size: 13px;
      opacity: 0.45;
    }
  }

  & .links {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 10px;
  }

  & .btn {
    display: inline-block;
    padding: 7px 20px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 6px;
    border: 1px solid color-mix(in srgb, var(--accent) 50%, transparent);
    color: var(--accent);
    text-decoration: none;

    &:hover {
      background: color-mix(in srgb, var(--accent) 10%, transparent);
    }
  }
}

.note {
  display: inline-block;
  font-size: 12px;
  border: 1px solid color-mix(in srgb, var(--text) 20%, transparent);
  border-radius: 6px;
  padding: 3px 10px;
  margin-top: 6px;
  opacity: 0.8;
}

section {
  max-width: max(1200px, 90vw);
  margin: 0 auto;
  padding: 0 24px 64px;

  & > header {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 28px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);

    & h2 {
      font-size: 1.4rem;
      font-weight: 700;
    }
  }

  & h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 28px 0 16px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--accent);

    &:first-of-type {
      margin-top: 0;
    }
  }
}

article {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 16px;
  overflow: hidden;

  & > header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);

    & > b {
      flex-shrink: 0;
      display: inline-flex;
      align-items: center;
      border-radius: 5px;
      padding: 2px 8px;
      font-size: 11px;
      font-weight: 700;
      letter-spacing: 0.06em;
      text-transform: uppercase;
      margin-top: 3px;
      white-space: nowrap;
      color: var(--accent);
      background: color-mix(in srgb, var(--accent) 15%, transparent);
      border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
    }
  }

  & > div {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1px;
    background: var(--border);

    & figure {
      background: var(--surface);
      padding: 14px 16px;

      & figcaption {
        font-size: 11px;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.07em;
        margin-bottom: 10px;
      }

      & audio {
        width: 100%;
        height: 34px;
        border-radius: 6px;
      }

      &.highlight figcaption {
        color: var(--accent);
      }

      &.wide {
        grid-column: span 2;
      }
    }
  }
}

#full article > div,
#additional article > div,
#failures article > div {
  grid-template-columns: repeat(3, 1fr);
}

footer {
  text-align: center;
  padding: 32px 24px 48px;
  font-size: 13px;
  border-top: 1px solid var(--border);
  margin-top: 16px;
}

@media (max-width: 600px) {
  #full article > div,
  #additional article > div,
  #failures article > div {
    grid-template-columns: 1fr;
  }

  figure.wide {
    grid-column: span 1;
  }
}
