/* ============================================================
   Theme: Neumorphism — soft extruded cards on a light-gray
   canvas, asymmetric bento grid, fully responsive.
   Skin for the bento layout. Loaded on demand via the theme
   switcher; remove the stylesheet link to use another theme.
   ============================================================ */
.bento-shell {
  --neu-base: #e0e5ec;
  --neu-card: #e2e7ee;
  --neu-well: #d2d8e1;
  --neu-pill: #e8ecf2;
  --neu-ink: #23272f;
  --neu-body: #414754;
  --neu-muted: #7c8494;
  --neu-accent: #263959;
  --neu-r-lg: 26px;
  --neu-r-md: 18px;
  --neu-raised: 8px 8px 18px rgba(163, 177, 198, 0.55), -8px -8px 18px rgba(255, 255, 255, 0.95);
  --neu-raised-sm: 4px 4px 10px rgba(163, 177, 198, 0.55), -4px -4px 10px rgba(255, 255, 255, 0.95);
  --neu-pressed: inset 5px 5px 11px rgba(163, 177, 198, 0.55), inset -5px -5px 11px rgba(255, 255, 255, 0.9);
  --neu-ring: rgba(255, 255, 255, 0.55);
}

body {
  background-color: #e0e5ec;
  background-image: radial-gradient(1200px 600px at 20% -5%, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 60%),
    linear-gradient(180deg, #e7ebf1 0%, #dde3eb 100%);
  color: #414754;
}

.wrapper {
  max-width: none;
}

/* ---------- Bento shell + grid ---------- */
.bento-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 30px 26px 70px;
}

.bento-grid {
  display: grid;
  gap: 22px;
  align-items: stretch;
  grid-template-columns: 300px minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas:
    "profile bio bio"
    "profile news news"
    "filters filters filters"
    "posts posts posts";
}

.bento-grid-article {
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "article";
}

.bento-shell .sidebar { grid-area: profile; }
.bento-shell .bio-box { grid-area: bio; }
.bento-shell .bio-box { padding-bottom: 12px; }
.bento-shell .news-box { grid-area: news; }
.bento-shell .facts-card { grid-area: facts; }
.bento-shell .paper-filters { grid-area: filters; }
.bento-shell .content-box { grid-area: posts; }
.bento-grid-article > .content-box { grid-area: article; }

#papers { scroll-margin-top: 18px; }

/* ---------- Neu cards (profile / bio / news / facts / filters) ---------- */
.bento-shell .sidebar,
.bento-shell .bio-box,
.bento-shell .news-box,
.bento-shell .facts-card,
.bento-shell .paper-filters {
  width: auto;
  max-width: none;
  margin: 0;
  padding: 26px 24px;
  background: var(--neu-card);
  background-color: #e2e7ee;
  border: 1px solid var(--neu-ring);
  border-radius: var(--neu-r-lg);
  box-shadow: var(--neu-raised);
}

/* Profile card (was the fixed sidebar; scrolls away with the page) */
.bento-shell .sidebar {
  position: static;
  width: auto;
  height: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
}

.bento-shell .about { margin: 0 0 8px; }

.bento-shell .about .cover-author-image {
  width: 112px;
  height: 112px;
  margin: 0 auto 14px;
  border: 4px solid #e9edf3;
  border-radius: 50%;
  overflow: hidden;
  background-color: #d5dbe4;
  box-shadow: var(--neu-raised-sm);
}

.bento-shell .about .author-name {
  font-size: 17px;
  color: var(--neu-ink);
}

.bento-shell .about .author-name::after { display: none; }

.bento-shell .about p {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--neu-body);
  padding: 0 4px;
}

.bento-shell .divider {
  border-bottom: 1px solid rgba(124, 132, 148, 0.35);
  margin: 0.9rem 0;
}

.bento-shell .sidebar .about > a {
  color: var(--neu-accent);
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  padding: 5px 0;
  border-radius: 8px;
}

.bento-shell .sidebar .about > a:hover { text-decoration: underline; }

/* Contact icon discs */
.bento-shell .contact ul {
  display: flex;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 8px;
  margin-top: 10px;
}

.bento-shell .contact ul li { margin-left: 0; }

.bento-shell .contact ul li a {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--neu-pill);
  background-color: #e8ecf2;
  color: var(--neu-body);
  font-size: 15px;
  padding: 0;
  box-shadow: var(--neu-raised-sm);
  border: 1px solid var(--neu-ring);
}

.bento-shell .contact ul li a:hover {
  color: var(--neu-accent);
  transform: translateY(-2px);
  box-shadow: 6px 6px 14px rgba(163, 177, 198, 0.6), -6px -6px 14px rgba(255, 255, 255, 0.95);
}

.bento-shell .contact ul li a:active {
  transform: translateY(0);
  box-shadow: var(--neu-pressed);
}

.bento-shell footer .copyright {
  color: var(--neu-muted);
  font-size: 12px;
  margin-top: 14px;
}

.bento-shell footer .copyright p { margin: 2px 0; }

/* Bio hero card */
.bento-shell .bio-box {
  padding: 30px 32px 26px;
}

.bento-shell .bio-box .bio-name { color: var(--neu-ink); }
.bento-shell .bio-box .bio-role { color: var(--neu-muted); }
.bento-shell .bio-box .bio-summary { color: var(--neu-body); }
.bento-shell .bio-box .bio-prev { border-top: 1px solid rgba(124, 132, 148, 0.3); }
.bento-shell .bio-box .bio-prev-label { color: var(--neu-muted); }
.bento-shell .bio-box .bio-prev-item a { color: var(--neu-ink); }

/* News card */
.bento-shell .news-box {
  padding: 22px 22px 20px;
  display: flex;
  flex-direction: column;
}

.bento-shell .facts-card {
  display: flex;
  flex-direction: column;
  align-self: start;
}

.bento-shell .facts-card .facts-link {
  margin-top: auto;
}

.bento-shell .news-header-line {
  border-bottom: 1px solid rgba(124, 132, 148, 0.35);
  color: var(--neu-muted);
}

.bento-shell .news-header-line span {
  background: var(--neu-card);
  background-color: #e2e7ee;
  color: var(--neu-body);
  padding: 0 0.7em;
}

.bento-shell .news-box .news-content {
  flex: 1;
  min-height: 100px;
  max-height: 230px;
  background: var(--neu-well);
  background-color: #d2d8e1;
  border-radius: var(--neu-r-md);
  box-shadow: var(--neu-pressed);
  padding: 12px 16px;
}

.bento-shell .news-list li {
  color: var(--neu-body);
  font-size: 0.9rem;
  padding: 7px 0;
  margin-bottom: 0;
  border-bottom: 1px solid rgba(124, 132, 148, 0.25);
}

.bento-shell .news-list li:last-child { border-bottom: none; }

.bento-shell .news-list a { color: var(--neu-accent); font-weight: 700; }

.bento-shell .news-box .news-content::-webkit-scrollbar-thumb { background-color: #aab2c0; }

/* Facts / highlights card */
.facts-card { font-size: 0.92rem; }

.facts-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.facts-icon {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  border-radius: 14px;
  background: var(--neu-pill);
  background-color: #e8ecf2;
  box-shadow: var(--neu-raised-sm);
  border: 1px solid var(--neu-ring);
}

.facts-title {
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--neu-ink);
}

.facts-sub {
  font-size: 0.78rem;
  color: var(--neu-muted);
}

.facts-list {
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.facts-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 16px;
  background: var(--neu-pill);
  background-color: #e8ecf2;
  border: 1px solid var(--neu-ring);
  box-shadow: var(--neu-raised-sm);
}

.facts-disc {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  border-radius: 50%;
  background: var(--neu-well);
  background-color: #d2d8e1;
  box-shadow: var(--neu-pressed);
}

.facts-label {
  flex: 1;
  min-width: 0;
  color: var(--neu-body);
  font-weight: 400;
}

.facts-value {
  font-weight: 700;
  color: var(--neu-ink);
  white-space: nowrap;
}

.facts-link {
  display: block;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--neu-accent);
  text-decoration: none;
  padding: 10px;
  border-radius: 14px;
}

.facts-link:hover { text-decoration: underline; }

/* ---------- Filter pill bar ---------- */
.bento-shell .paper-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 16px 18px;
  border-radius: 22px;
}

.conf-filter-btn {
  border: none;
  background: var(--neu-pill);
  background-color: #e8ecf2;
  color: var(--neu-body);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 9px 17px;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: var(--neu-raised-sm);
  border: 1px solid var(--neu-ring);
  transition: transform 0.15s ease, box-shadow 0.2s ease, color 0.15s ease;
}

.conf-filter-btn:hover {
  transform: translateY(-1px);
  color: var(--neu-ink);
  box-shadow: 6px 6px 14px rgba(163, 177, 198, 0.6), -6px -6px 14px rgba(255, 255, 255, 0.95);
}

.conf-filter-btn.active {
  color: var(--neu-accent);
  box-shadow: var(--neu-pressed);
  transform: none;
}

.conf-filter-btn:focus-visible {
  outline: 2px solid var(--neu-accent);
  outline-offset: 2px;
}

.year-filter { position: relative; display: inline-block; }

.conf-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 158px;
  background: #e6eaf0;
  background-color: #e6eaf0;
  border: 1px solid var(--neu-ring);
  border-radius: 16px;
  box-shadow: var(--neu-raised);
  z-index: 40;
  padding: 6px;
}

.conf-dropdown a {
  display: block;
  padding: 8px 14px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--neu-body);
  text-decoration: none;
  border-radius: 10px;
}

.conf-dropdown a:hover { background: rgba(255, 255, 255, 0.6); }

.conf-dropdown a.venue-cvpr { color: #6D28D9; }
.conf-dropdown a.venue-eg { color: #0369A1; }
.conf-dropdown a.venue-3dv { color: #B45309; }
.conf-dropdown a.venue-eccv { color: #B45309; }

/* ---------- Publications area ---------- */
.bento-shell .content-box {
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Publication row-cards */
.bento-shell .post {
  position: relative;
  width: 100%;
  max-width: none;
  margin: 0;
  height: auto;
  flex-direction: row;
  align-items: center;
  gap: 22px;
  padding: 20px 22px;
  border-radius: 24px;
  overflow: hidden;
  background: var(--neu-card);
  background-color: #e2e7ee;
  border: 1px solid var(--neu-ring);
  box-shadow: var(--neu-raised);
}

.bento-shell .post:hover {
  transform: translateY(-3px);
  box-shadow: 11px 11px 24px rgba(163, 177, 198, 0.6), -11px -11px 24px rgba(255, 255, 255, 0.95);
}

.bento-shell .post .post-thumbnail {  width: 215px;
  flex-shrink: 0;
  align-self: center;
  height: 210px;
  margin: 0;
  border-radius: var(--neu-r-md);
  background-color: #ffffff;
  box-shadow: var(--neu-pressed);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.bento-shell .post .post-content {
  flex: 1;
  min-width: 0;
  width: auto;
  padding: 0;
  overflow: visible;
  display: flex;
  flex-direction: column;
}

.bento-shell .post .post-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--neu-muted);
  margin-bottom: 6px;
}

.bento-shell .post .post-meta-dot { color: #b6bdc9; }

.bento-shell .post .post-content .post-title { margin: 0 0 8px; font-size: 22px; }

.bento-shell .post .post-content .post-title a { color: var(--neu-ink); }

.bento-shell .post .post-content .post-title a:hover { color: var(--neu-accent); }

.bento-shell .post .post-content p {
  font-size: 14px;
  line-height: 1.55;
  text-align: left;
  color: var(--neu-body);
  margin-bottom: 12px;
}

.bento-shell .post .post-links { margin-top: 0; }

.post.filtered-out { display: none !important; }

.bento-shell .post-featured {
  border: 1px solid rgba(109, 40, 217, 0.35);
  box-shadow: var(--neu-raised), 0 0 0 3px rgba(109, 40, 217, 0.12);
}

.bento-shell .post-number-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--neu-muted);
  background: rgba(232, 236, 242, 0.9);
  border-radius: 999px;
  padding: 3px 9px;
  box-shadow: var(--neu-raised-sm);
}

.bento-shell .post-pin-badge {
  position: absolute;
  top: 10px;
  right: 14px;
  z-index: 2;
  color: #6D28D9;
  font-size: 17px;
}

.bento-shell article.post[data-post-link] { cursor: pointer; }

/* Conference pill keeps its venue color, lifted onto the card */
.bento-shell .post-conference-tag {
  box-shadow: 0 3px 8px rgba(10, 16, 34, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

/* Action buttons as small neu pills */
.bento-shell .post-link-button {
  background: var(--neu-pill);
  background-color: #e8ecf2;
  border: 1px solid var(--neu-ring);
  color: var(--neu-body);
  border-radius: 999px;
  box-shadow: var(--neu-raised-sm);
  font-weight: 700;
  font-size: 0.82em;
}

.bento-shell .post-link-button:hover {
  background-color: #eef1f6;
  border-color: var(--neu-ring);
  color: var(--neu-ink);
  transform: translateY(-1px);
  box-shadow: 6px 6px 14px rgba(163, 177, 198, 0.6), -6px -6px 14px rgba(255, 255, 255, 0.95);
}

.bento-shell .post-link-button:active { box-shadow: var(--neu-pressed); transform: none; }

.bento-shell .post-link-button:focus-visible {
  outline: 2px solid var(--neu-accent);
  outline-offset: 2px;
}

.bento-shell .post-link-button.copy-button {
  background-color: #e8ecf2;
  color: var(--neu-body);
}

.bento-shell .github-stars.counter-badge {
  background: var(--neu-well);
  background-color: #d2d8e1;
  color: var(--neu-ink);
  box-shadow: var(--neu-pressed);
}

/* Pagination pills */
.bento-shell .pagination ul {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
}

.bento-shell .pagination p { margin: 0; }

.bento-shell a.older-posts,
.bento-shell a.newer-posts {
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--neu-pill);
  background-color: #e8ecf2;
  border: 1px solid var(--neu-ring);
  color: var(--neu-body);
  box-shadow: var(--neu-raised-sm);
}

.bento-shell a.older-posts:hover,
.bento-shell a.newer-posts:hover {
  color: var(--neu-accent);
  transform: translateY(-2px);
}

.bento-shell .page-number {
  font-size: 13px;
  font-weight: 700;
  color: var(--neu-muted);
}

/* Article / post pages inside the bento shell */
.bento-shell .article-page {
  background: var(--neu-card);
  background-color: #e2e7ee;
  border: 1px solid var(--neu-ring);
  border-radius: var(--neu-r-lg);
  box-shadow: var(--neu-raised);
  overflow: hidden;
}

.bento-shell .page-footer { border-bottom: none; margin-bottom: 0; padding-bottom: 10px; }

.bento-shell .page-footer .page-share a,
.bento-shell .page-footer .page-tag a {
  background: var(--neu-pill);
  background-color: #e8ecf2;
  border: 1px solid var(--neu-ring);
  color: var(--neu-body);
  border-radius: 999px;
  box-shadow: var(--neu-raised-sm);
}

.bento-shell .page-footer .page-share a:hover,
.bento-shell .page-footer .page-tag a:hover {
  color: var(--neu-accent);
  text-decoration: none;
}

/* Business-card thumbnail sits in an inset well on the profile card */
.bento-shell .bc-thumb { max-width: 150px; }

.bento-shell .bc-thumb-frame {
  border-radius: 10px;
  background: var(--neu-well);
  background-color: #d2d8e1;
  box-shadow: var(--neu-pressed);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.bento-shell .bc-thumb:hover .bc-thumb-frame {
  transform: translateY(-2px);
  box-shadow: var(--neu-pressed), 0 10px 22px rgba(10, 16, 34, 0.18);
}

.bento-shell .bc-thumb-label { color: var(--neu-muted); }
.bento-shell .bc-thumb:hover .bc-thumb-label { color: var(--neu-body); }

/* ---------- Responsive: tablets ---------- */
@media only screen and (max-width: 1024px) {
  .bento-grid {
    grid-template-columns: 270px minmax(0, 1fr);
    grid-template-areas:
      "profile bio"
      "profile news"
      "filters filters"
      "posts posts";
  }

  .bento-grid-article {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "article";
  }

  .bento-shell .post { gap: 18px; padding: 18px; }

  .bento-shell .post .post-thumbnail { width: 180px; height: 170px; }
}

/* ---------- Responsive: phones ---------- */
@media only screen and (max-width: 760px) {
  .bento-shell { padding: 16px 14px 56px; }

  .bento-grid,
  .bento-grid-article {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "profile"
      "bio"
      "news"
      "filters"
      "posts";
    gap: 16px;
  }

  .bento-shell .sidebar,
  .bento-shell .bio-box,
  .bento-shell .news-box,
  .bento-shell .facts-card,
  .bento-shell .paper-filters {
    border-radius: 20px;
    padding: 20px 18px;
    box-shadow: 5px 5px 12px rgba(163, 177, 198, 0.55), -5px -5px 12px rgba(255, 255, 255, 0.95);
  }

  .bento-shell .bio-box { padding: 22px 20px 20px; }

  .bento-shell .bio-box .bio-name { font-size: 1.7rem; }

  .bento-shell .news-box .news-content {
    min-height: 0;
    max-height: 135px;
  }

  .bento-shell .content-box { gap: 16px; }

  .bento-shell .post {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 16px 16px 20px;
    border-radius: 20px;
    box-shadow: 5px 5px 12px rgba(163, 177, 198, 0.55), -5px -5px 12px rgba(255, 255, 255, 0.95);
  }

  .bento-shell .post .post-thumbnail {
    width: 100%;
    height: 200px;
  }

  .bento-shell .post .post-content .post-title { font-size: 19px; }

  .bento-shell .post .post-content p { font-size: 13.5px; }

  .bento-shell .paper-filters { gap: 8px; }

  .conf-filter-btn { padding: 8px 14px; font-size: 12px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .bento-shell .post:hover,
  .conf-filter-btn:hover,
  .bento-shell .post-link-button:hover,
  .bento-shell a.older-posts:hover,
  .bento-shell a.newer-posts:hover,
  .bento-shell .contact ul li a:hover {
    transform: none;
  }
}

/* Linked highlight rows: the anchor fills the row via display:contents */
.facts-list.facts-links a {
  display: contents;
  text-decoration: none;
  color: inherit;
}

/* BibTeX box on publication pages */
.bento-shell .bibtex-box {
  position: relative;
  border-radius: var(--neu-r-md);
  border-radius: 18px;
  background: var(--neu-well);
  background-color: #d2d8e1;
  box-shadow: var(--neu-pressed);
  padding: 0;
}
.bento-shell .bibtex-copy {
  position: absolute;
  top: 10px;
  right: 10px;
  border: 1px solid var(--neu-ring);
  background: var(--neu-pill);
  background-color: #e8ecf2;
  color: var(--neu-body);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 700;
  padding: 7px 15px;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: var(--neu-raised-sm);
}
.bento-shell .bibtex-copy:hover { color: var(--neu-ink); }
.bento-shell .bibtex-copy:active { box-shadow: var(--neu-pressed); }
.bento-shell .bibtex-pre {
  margin: 0;
  padding: 22px 18px 16px;
  overflow-x: auto;
  background: transparent;
  color: var(--neu-body);
  font-size: 13px;
}

/* Avatar photo always fills its circular frame (overrides base 100px phone size) */
.bento-shell .about .cover-author-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Conference pill stays bottom-right at every width (base moves it left below 1190px) */
.bento-shell .post-conference-tag {
  left: auto;
  right: 16px;
}

/* Help popup matches the soft neumorphic cards */
.help-shell {
  background: #e2e7ee;
  border-radius: 20px;
  box-shadow: 9px 9px 18px #b8bec9, -9px -9px 18px #ffffff;
  color: #414754;
}
.help-title { color: #23272f; }
.help-sub { color: #8a93a3; }
.help-close { color: #8a93a3; }
.help-close:hover { color: #23272f; background: #d5dbe4; }
.help-list li { background: #e8ecf2; border-radius: 12px; box-shadow: inset 2px 2px 5px #b8bec9, inset -2px -2px 5px #ffffff; }
.help-list kbd {
  background: #d5dbe4; color: #23272f; border-radius: 8px;
  box-shadow: 2px 2px 4px #b8bec9, -2px -2px 4px #ffffff;
}
.help-desc strong { color: #23272f; }
