/* Publication cards generated by scripts/build_pubs.py.
   Colors come from Zensical theme variables (set by Flexoki), so cards follow light/dark mode. */

.pub-card {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.4rem;
  align-items: flex-start;
}
.pub-body {
  flex: 1;
  min-width: 0;          /* lets long <pre> lines scroll instead of widening the card on phones */
}
.md-typeset .pub-title {
  font-weight: 600;
  font-size: 0.8rem;
  margin: 0 0 0.25rem 0;
}
.pub-title-en {
  display: block;        /* own line, under the original title */
  margin-top: 0.1rem;
  font-weight: 400;
  font-style: italic;
  color: var(--md-default-fg-color--light);
}
.md-typeset .pub-authors {
  margin: 0;
}
.md-typeset .pub-venue {
  font-style: italic;
  color: var(--md-default-fg-color--light);
  margin: 0.2rem 0 0.6rem 0;
}
.pub-badge {
  font-style: normal;
  font-size: 0.6rem;
  padding: 0.05rem 0.45rem;
  margin-left: 0.4rem;
  border-radius: 3px;
  color: var(--md-accent-bg-color);
  background: var(--md-accent-fg-color);
}
.pub-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.md-typeset .pub-btn {
  font: inherit;         /* <button> does not inherit the page font by default */
  font-size: 0.6rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.15rem 0.55rem;
  border: 1px solid currentColor;
  border-radius: 3px;
  text-decoration: none;
  cursor: pointer;
  background: transparent;
  color: var(--md-typeset-a-color);
  transition: background 0.15s ease;
}
.md-typeset .pub-btn:hover,
.md-typeset .pub-btn[aria-expanded="true"] {
  background: var(--md-default-fg-color--lightest);
}
/* PAPER button: small menu listing the versions of the paper (PDF, Proceedings, arXiv, HAL) */
.pub-menu {
  position: relative;
  display: inline-flex;
}
.md-typeset .pub-btn[data-pub-menu]::after {
  content: "▾";
  margin-left: 0.35em;
}
.md-typeset .pub-menu-list {
  position: absolute;
  top: calc(100% + 0.25rem);
  left: 0;
  z-index: 3;
  min-width: 8rem;
  padding: 0.25rem 0;
  background: var(--md-default-bg-color);
  border: 1px solid var(--md-default-fg-color--lighter);
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.md-typeset .pub-menu-list:not([hidden]) {
  display: flex;
  flex-direction: column;
}
.md-typeset .pub-menu-list a {
  padding: 0.3rem 0.8rem;
  font-size: 0.65rem;
  color: var(--md-typeset-a-color);
  text-decoration: none;
  white-space: nowrap;
}
.md-typeset .pub-menu-list a:hover {
  background: var(--md-default-fg-color--lightest);
}
.pub-drawer {
  display: none;
  margin-top: 0.75rem;
}
.pub-drawer.open {
  display: block;
}
.md-typeset .pub-drawer pre {
  margin: 0;
}
/* Talks & posters (Activities page): month column + event, title, buttons */
.talk {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.2rem;
}
.talk-date {
  flex: 0 0 2.2rem;
  padding-top: 0.1rem;
  font-size: 0.6rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--md-default-fg-color--light);
}
.talk-body {
  flex: 1;
  min-width: 0;
}
.md-typeset .talk-event {
  margin: 0;
  font-weight: 600;
}
.md-typeset .talk-event a {
  color: inherit;
  text-decoration: none;
}
.md-typeset .talk-event a:hover {
  text-decoration: underline;
}
.md-typeset .talk-title {
  margin: 0.15rem 0 0.5rem 0;
  font-style: italic;
  color: var(--md-default-fg-color--light);
}
/* Kind of contribution (TALK / POSTER): a soft orange tag without border, so that it is
   not taken for a button (outlined) nor for an award (filled with the accent colour).
   Shades of the theme's palette, one pair per colour scheme. */
.talk-kind {
  font-size: 0.55rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.4rem;
  margin-left: 0.4rem;
  border-radius: 3px;
  color: var(--flexoki-orange-700);
  background: var(--flexoki-orange-50);
  vertical-align: 0.1em;
}
[data-md-color-scheme="slate"] .talk-kind {
  color: var(--flexoki-orange-300);
  background: var(--flexoki-orange-950);
}
.talk .pub-badge {
  vertical-align: 0.1em;
}
/* Badges and labels move to the next line as a whole instead of breaking inside */
.pub-badge,
.talk-kind {
  display: inline-block;
  white-space: nowrap;
}
