:root {
  color-scheme: light;
  --ink: #1d1d1b;
  --muted: #6f6a63;
  --line: #ded8ce;
  --paper: #f7f3ed;
  --panel: #fffdf8;
  --accent: #0f766e;
  --accent-ink: #ffffff;
  --danger: #a43f32;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.shell {
  width: 100%;
  min-height: 100vh;
  margin: 0;
  padding: 0;
}

.topbar {
  position: fixed;
  top: 12px;
  left: 12px;
  right: 12px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0;
  pointer-events: none;
}

.topbar > div {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(28px, 5vw, 56px);
  line-height: 1;
  letter-spacing: 0;
}

.masonry {
  width: 100%;
  min-height: 100vh;
  overflow-x: hidden;
  scroll-snap-type: y mandatory;
}

.page {
  width: 100vw;
  height: 100vh;
  margin: 0;
  padding: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #f4f0ea;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.page img {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 0;
  background: #e8e2d8;
  object-fit: cover;
  cursor: zoom-in;
}

.page img:hover {
  filter: saturate(1.02) contrast(1.01);
}

.auth {
  min-height: 100vh;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
  padding: 24px;
  background:
    linear-gradient(90deg, rgb(14 24 35 / 55%), rgb(45 67 78 / 25%)),
    url("/cover") center / cover no-repeat;
}

.auth::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 48%, rgb(255 255 255 / 10%), transparent 34%),
    linear-gradient(180deg, rgb(255 255 255 / 2%), rgb(0 0 0 / 16%));
  pointer-events: none;
}

.auth-panel {
  position: relative;
  z-index: 1;
  width: min(620px, 100%);
  padding: 34px;
  border: 1px solid rgb(255 255 255 / 24%);
  border-radius: 8px;
  background: rgb(14 22 30 / 34%);
  color: #fff;
  box-shadow: 0 24px 70px rgb(0 0 0 / 24%);
  backdrop-filter: blur(18px);
}

.auth-panel .eyebrow {
  color: rgb(218 244 240 / 88%);
}

.auth-panel h1 {
  max-width: 520px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 0.95;
}

label {
  display: block;
  margin-top: 28px;
  margin-bottom: 8px;
  color: rgb(255 255 255 / 72%);
  font-size: 14px;
}

.password-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}

input {
  min-width: 0;
  height: 46px;
  padding: 0 14px;
  border: 1px solid rgb(255 255 255 / 32%);
  border-radius: 6px;
  background: rgb(255 255 255 / 78%);
  color: #111;
  outline: none;
}

input:focus {
  border-color: rgb(255 255 255 / 80%);
  box-shadow: 0 0 0 3px rgb(255 255 255 / 18%);
}

button {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--accent);
  border-radius: 6px;
  background: #ffffff;
  color: var(--accent-ink);
  font-weight: 700;
}

.auth-panel button {
  border-color: #fff;
  background: #fff;
  color: #173742;
}

.ghost {
  pointer-events: auto;
  border-color: rgb(255 255 255 / 42%);
  background: rgb(255 255 255 / 72%);
  color: var(--ink);
  box-shadow: 0 8px 22px rgb(0 0 0 / 10%);
  backdrop-filter: blur(14px);
}

.message {
  min-height: 20px;
  margin: 12px 0 0;
  color: #ffd2c9;
}

.empty {
  min-height: 70vh;
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 8px;
}

.empty h1 {
  max-width: 860px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.1;
}

.lightbox {
  width: min(94vw, 1500px);
  height: min(92vh, 1000px);
  padding: 0;
  border: 0;
  background: #111;
}

.lightbox::backdrop {
  background: rgb(0 0 0 / 78%);
}

.lightbox img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.close,
.nav {
  position: absolute;
  z-index: 2;
  min-width: 42px;
  border-color: rgb(255 255 255 / 20%);
  background: rgb(0 0 0 / 42%);
  color: #fff;
}

.close {
  top: 14px;
  right: 14px;
  font-size: 28px;
}

.nav {
  top: 50%;
  width: 46px;
  height: 64px;
  transform: translateY(-50%);
  font-size: 44px;
  line-height: 1;
}

.nav-left {
  left: 14px;
}

.nav-right {
  right: 14px;
}

.caption {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 12px;
  margin: 0;
  padding: 8px 10px;
  border-radius: 6px;
  background: rgb(0 0 0 / 48%);
  color: #fff;
  font-size: 13px;
  text-align: center;
}

@media (max-width: 1100px) {
}

@media (max-width: 760px) {
  .shell {
    width: 100%;
  }

  .password-row {
    grid-template-columns: 1fr;
  }

  .topbar {
    top: 10px;
    left: 10px;
    right: 10px;
  }

  h1 {
    font-size: 32px;
  }
}
