:root {
  color-scheme: light dark;
  --page: #1c211f;
  --panel: rgb(247 248 243 / 0.88);
  --ink: #202723;
  --muted: #607068;
  --line: rgb(32 39 35 / 0.14);
  --gap: 10px;
  --radius: 14px;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  background: var(--page);
  font-family: "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
}

.page-shell {
  height: 100dvh;
  min-height: 100dvh;
  isolation: isolate;
  overflow: hidden;
  position: relative;
  background: var(--page);
}

.photo-wall {
  display: grid;
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: var(--gap);
  height: 100dvh;
  min-height: 100dvh;
  padding: var(--gap);
}

.wall-row {
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  position: relative;
}

.photo-flow {
  display: flex;
  height: 100%;
  width: max-content;
  will-change: transform;
  animation: move-right 300s linear infinite;
}

.photo-set {
  display: flex;
  height: 100%;
  gap: var(--gap);
  padding-right: var(--gap);
}

.photo-card {
  flex: 0 0 auto;
  height: 100%;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius);
  overflow: hidden;
  isolation: isolate;
  position: relative;
  background: #303935;
}

.photo-card > .photo-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translateZ(0);
}

.brand-decal {
  position: absolute;
  z-index: 1;
  display: block;
  width: clamp(28px, 23%, 64px);
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid rgb(255 255 255 / 0.5);
  border-radius: 17%;
  box-shadow: 0 3px 9px rgb(12 32 24 / 0.24);
  opacity: 0.9;
  pointer-events: none;
}

.brand-decal--watermark {
  left: 8px;
  bottom: 8px;
}

.wall-row:nth-child(2) .photo-flow {
  animation-delay: -100s;
}

.wall-row:nth-child(3) .photo-flow {
  animation-delay: -200s;
}

@keyframes move-right {
  from {
    transform: translate3d(-50%, 0, 0);
  }

  to {
    transform: translate3d(0, 0, 0);
  }
}

.brand-panel {
  position: fixed;
  inset: auto auto 22px 22px;
  z-index: 2;
  max-width: min(250px, calc(100vw - 44px));
  padding: 13px 16px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  background: var(--panel);
  box-shadow: 0 14px 36px rgb(10 18 14 / 0.16);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.brand-name,
.brand-note {
  margin: 0;
}

.brand-name {
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  font-weight: 700;
  letter-spacing: 0.06em;
}

.brand-note {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.82rem;
}

.wall-message {
  position: fixed;
  inset: 50% 18px auto;
  z-index: 3;
  margin: 0;
  padding: 14px 16px;
  border-radius: var(--radius);
  color: #f7f8f3;
  background: rgb(32 39 35 / 0.92);
  text-align: center;
  transform: translateY(-50%);
}

@media (max-width: 640px) {
  :root {
    --gap: 7px;
    --radius: 10px;
  }

  .brand-panel {
    inset: auto auto 16px 16px;
    padding: 11px 13px 12px;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --panel: rgb(28 35 31 / 0.86);
    --ink: #eff3eb;
    --muted: #c0ccc2;
    --line: rgb(239 243 235 / 0.16);
  }
}

@media (prefers-reduced-motion: reduce) {
  .photo-flow {
    animation: none;
    transform: none;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .brand-panel {
    background: #eff3eb;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}

@media (prefers-reduced-transparency: reduce) and (prefers-color-scheme: dark) {
  .brand-panel {
    background: #1c231f;
  }
}
