* {
  margin: 0;
  padding: 0;
  color: inherit;
}

html {
  color: #fff;
  font-family: "Roboto", sans-serif;
}

body {
  background: #eee fixed center url(/campus.jpg);
  background-size: cover;
}

a,
button {
  cursor: pointer;
  text-decoration: none;
}

a:hover,
button:hover {
  text-shadow: 0 0 0.5em #fff;
}

button {
  border: 0;
  background: none;
  font: inherit;
  text-align: inherit;
}

::selection {
  /* color: #3af; */
  background: rgba(255, 255, 255, 0.1);
  text-shadow: 2px 4px 1em #08f;
}

.ib {
  display: inline-block;
}

.dp1 {
  font-size: 3em;
}

.dp2 {
  font-size: 1.5em;
}

.dim {
  opacity: 0.5;
  font-size: 0.8em;
  /* color: rgba(255, 255, 255, 0.5); */
}

.center {
  text-align: center;
}

h2 {
  margin-block: 1rem;
}

.sb {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: .5em 1em;
}

p {
  margin-block: 0.2em;
}

body>*>*,
.wrap {
  vertical-align: middle;
  margin-inline: auto;
  width: 90%;
  max-width: 80rem;
}

nav {
  position: fixed;
  z-index: 1;
  backdrop-filter: blur(4rem);
  background: linear-gradient(30deg,
      rgba(51, 170, 255, 0.5),
      rgba(51, 187, 153, 0.5));
  padding: 1em 0;
  width: 100%;
}

.banner {
  backdrop-filter: blur(1em);
  background: linear-gradient(30deg,
      rgba(51, 170, 255, 0.2),
      rgba(51, 187, 153, 0.2));
  padding: 6rem 0;
  color: #fff;
}

mark {
  border-radius: 0.2em;
  background: linear-gradient(30deg,
      rgba(51, 170, 255, 0.5),
      rgba(51, 187, 153, 0.2));
}

.pribtn {
  display: inline-block;
  border: 1px solid #fff;
  border-radius: 1em;
  padding: 0.2em 1em;
  color: #fff;
  text-align: center;
}

.pribtn:hover {
  box-shadow: 0 0 0.5em rgba(255, 255, 255, 0.5);
}

#gallery-batches,
#verlist {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15em, 1fr));
  gap: 1rem;
  margin-block: 1rem;
}

.gallery-info,
.gallery-current,
#gallery-batches details,
#gallery-batches .gallery-images button,
#verlist>div {
  backdrop-filter: blur(0.5em);
  box-shadow: 2px 4px 1em rgba(0, 0, 0, 0.2);
  border-radius: 0.5rem;
  background: rgba(0, 0, 0, 0.2);
  padding: 0.5em;
}

#gallery-batches details:not([open]):hover,
#gallery-batches .gallery-images button:hover,
#gallery-batches button[aria-pressed="true"],
#verlist>div:hover {
  box-shadow: 4px 8px 0.5em rgba(0, 0, 0, 0.2);
  background: linear-gradient(30deg, rgba(51, 170, 255, 0.5), rgba(51, 187, 153, 0.5));
}

button:disabled {
  opacity: .6;
  cursor: wait;
}

button:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

.gallery-overview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(20rem, 100%), 1fr));
  gap: 1rem;
  margin-block: 1rem;
}

.gallery-info,
.gallery-current {
  padding: 1rem;
  min-width: 0;
}

.gallery-info>.sb {
  margin-bottom: .75rem;
}

#gallery-credit {
  margin-top: .75rem;
}

#gallery-credit>small,
.gallery-caption>small {
  opacity: .7;
}

#gallery-status {
  margin-top: .5rem;
}

#gallery-status:empty {
  display: none;
}

/* 原生折叠保留键盘操作；展开的批次复用整行网格展示图片。 */
#gallery-batches {
  align-items: start;
}

#gallery-batches details {
  min-width: 0;
}

#gallery-batches details[open] {
  grid-column: 1 / -1;
}

#gallery-batches summary {
  cursor: pointer;
}

#gallery-batches details[open]>summary {
  margin-bottom: .5rem;
}

.gallery-images {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(12rem, 100%), 1fr));
  gap: .5rem;
  margin-top: .5rem;
}

#gallery-batches .gallery-images button {
  display: block;
  position: relative;
  isolation: isolate;
  padding: 0;
  aspect-ratio: 16 / 9;
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

.gallery-images img {
  display: block;
  position: absolute;
  margin: 0;
  inset: 0;
  border-radius: 0;
  aspect-ratio: 16 / 9;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#gallery-batches summary button {
  float: right;
  padding: .1em .5em;
  font-size: .8em;
}

#gallery-batches .gallery-count {
  vertical-align: middle;
  opacity: .7;
  margin-left: .5em;
  border-radius: 1em;
  background: rgb(255 255 255 / 12%);
  padding: .1em .5em;
  font-size: .75em;
}

.gallery-caption>small {
  flex: none;
  font-weight: 400;
  font-size: .8em;
  white-space: nowrap;
}

.gallery-caption {
  display: flex;
  position: absolute;
  align-items: baseline;
  gap: .5rem;
  z-index: 1;
  inset: auto 0 0;
  background: linear-gradient(transparent, rgb(0 0 0 / 80%));
  padding: 1.5rem .5rem .5rem;
  color: #fff;
  line-height: 1.4;
}

#gallery-batches button[aria-pressed="true"] .gallery-caption {
  background: linear-gradient(transparent, rgba(51, 170, 255, 0.7), rgba(51, 187, 153, 0.85));
}

.gallery-caption>span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}