@font-face {
  font-family: Manrope;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/static/fonts/manrope-cyrillic-400.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Manrope;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/static/fonts/manrope-latin-400.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: Manrope;
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/static/fonts/manrope-cyrillic-500.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Manrope;
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/static/fonts/manrope-latin-500.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: Manrope;
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/static/fonts/manrope-cyrillic-600.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Manrope;
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/static/fonts/manrope-latin-600.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/static/fonts/cormorant-cyrillic-500.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/static/fonts/cormorant-latin-500.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/static/fonts/cormorant-cyrillic-600.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/static/fonts/cormorant-latin-600.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --paper: #e8e1d6;
  --paper-2: #f6f2eb;
  --ink: #1b1916;
  --muted: #6d665d;
  --line: #d3cbc0;
  --walnut: #7c4e32;
  --danger: #8a3a2a;
  --ok: #245244;
  --shadow: 0 24px 60px rgba(40, 30, 20, 0.08);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(124, 78, 50, 0.08), transparent 50%),
    var(--paper);
  color: var(--ink);
  font-family: Manrope, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
}
body.nav-pad { padding-bottom: 3rem; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, textarea { font: inherit; color: inherit; }
::selection { background: #e4cfc2; }

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--ink);
  color: var(--paper-2);
  padding: 0.5rem 0.8rem;
  z-index: 5;
}
.skip:focus { top: 1rem; }

.top, .foot, .intro, #gallery, #project-body, .admin {
  width: min(1180px, calc(100% - 2rem));
  margin-left: auto;
  margin-right: auto;
}

.top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 1.25rem 0 0.9rem;
  border-bottom: 1px solid var(--line);
}
.mark {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.7rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
}
.top-note {
  color: var(--muted);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.72rem;
}

.intro { padding: 3.4rem 0 1.6rem; }
.kicker {
  margin: 0 0 0.6rem;
  color: var(--walnut);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 600;
}
h1, h2, h3 {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 0.96;
}
h1 { font-size: clamp(3.1rem, 8vw, 6.4rem); margin: 0; }
.lead {
  max-width: 38rem;
  margin: 1.5rem 0 0;
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.6rem;
  padding: 0.4rem 0 4rem;
}
.card { list-style: none; }
.card a { text-decoration: none; display: block; }
.card figure {
  margin: 0;
  overflow: hidden;
  background: #ddd6cc;
  aspect-ratio: 4 / 5;
}
.card img, .ph {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ph {
  display: grid;
  place-items: center;
  color: var(--muted);
  background: linear-gradient(160deg, #efe8de, #ddd4c8);
}
.card-meta { padding: 1rem 0.05rem 0; }
.card h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); margin: 0; }
.card p { margin: 0.35rem 0 0; color: var(--muted); font-size: 0.92rem; }

@media (hover: hover) {
  .card img { transition: transform 0.7s ease; }
  .card:hover img { transform: scale(1.035); }
}

@media (min-width: 840px) {
  .intro { padding-top: 4.6rem; }
  .grid { grid-template-columns: 1fr 1fr; gap: 3.2rem 1.6rem; }
  .card:first-child { grid-column: 1 / -1; }
  .card:first-child figure { aspect-ratio: 16 / 9; max-height: 72vh; }
}

.skeleton-card figure, .skeleton-line, .skeleton-title {
  background: linear-gradient(90deg, #e3dbd0 25%, #efe8de 37%, #e3dbd0 63%);
  background-size: 400% 100%;
  animation: shine 1.4s ease infinite;
}
.skeleton-line { height: 0.9rem; margin-top: 0.7rem; width: 46%; }
.skeleton-title { height: 4.2rem; width: min(100%, 28rem); margin: 0.4rem 0 1rem; }
@keyframes shine {
  0% { background-position: 100% 0; }
  100% { background-position: 0 0; }
}
@media (prefers-reduced-motion: reduce) {
  .skeleton-card figure, .skeleton-line, .skeleton-title { animation: none; }
  .card img { transition: none; }
}

.empty, .error-box {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
  max-width: 38rem;
}
.empty h1, .error-box h1 { font-size: clamp(2.4rem, 6vw, 4rem); }
.empty p, .error-box p { color: var(--muted); }

.back { width: min(1180px, calc(100% - 2rem)); margin: 1.2rem auto 0; }
.back a { color: var(--muted); text-underline-offset: 0.2em; }

.project-head { padding-bottom: 0.4rem; }
.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.2rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
}
.meta-row li { letter-spacing: 0.01em; }
.summary {
  max-width: 42rem;
  font-size: 1.08rem;
  margin: 1.2rem 0 0;
}
.summary.muted { color: var(--muted); }

.zone { padding: 2.4rem 0 0.6rem; border-top: 1px solid var(--line); }
.zone-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
}
.zone h2 { font-size: clamp(2rem, 4vw, 3rem); margin: 0.2rem 0; }
.swipe-hint {
  display: none;
  margin: 0.8rem 0 0;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.stage {
  margin-top: 0.9rem;
  background: #d9d1c6;
  aspect-ratio: 3 / 2;
  cursor: grab;
  touch-action: pan-y;
  user-select: none;
}
.stage img { width: 100%; height: 100%; object-fit: cover; }
.zone-tools {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-top: 0.85rem;
}
.counter { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 0.92rem; }
.film {
  display: flex;
  gap: 0.45rem;
  overflow-x: auto;
  padding: 0.8rem 0 1rem;
  scroll-snap-type: x mandatory;
}
.film button {
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  min-height: 0;
  width: 4.6rem;
  height: 3.4rem;
  flex: 0 0 auto;
  scroll-snap-align: start;
  opacity: 0.55;
  letter-spacing: 0;
  text-transform: none;
}
.film button[aria-current="true"] { opacity: 1; outline: 1px solid var(--walnut); outline-offset: 3px; }
.film img { width: 100%; height: 100%; object-fit: cover; }

button, .button {
  appearance: none;
  background: transparent;
  color: var(--ink);
  border: 0;
  border-bottom: 1px solid currentColor;
  border-radius: 0;
  min-height: 44px;
  padding: 0.35rem 0;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 600;
}
button[type="submit"], a.button {
  background: var(--ink);
  color: var(--paper-2);
  border: 0;
  border-radius: 999px;
  min-height: 46px;
  padding: 0.8rem 1.4rem;
}
button.ghost, a.ghost {
  background: transparent;
  color: var(--ink);
  border: 0;
  border-bottom: 1px solid currentColor;
  border-radius: 0;
  min-height: 0;
  padding: 0.2rem 0;
}
button:disabled { opacity: 0.45; cursor: progress; }
button.danger {
  background: transparent;
  color: var(--danger);
  border: 0;
  border-bottom: 1px solid currentColor;
  border-radius: 0;
  min-height: 0;
  padding: 0.2rem 0;
}
.zone-tools button { min-height: 0; }

@media (max-width: 720px) {
  .zone-tools button,
  .lightbox .lb-nav { display: none; }
  .swipe-hint { display: block; }
  .zone-tools { justify-content: flex-start; margin-top: 0.55rem; }
  .stage { margin-left: -1rem; margin-right: -1rem; aspect-ratio: 4 / 5; }
  .intro { padding-top: 2.2rem; }
  h1 { font-size: clamp(2.7rem, 14vw, 3.6rem); }
}

.foot {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
  border-top: 1px solid var(--line);
  margin-top: 2rem;
  padding: 1.2rem 0 2rem;
  color: var(--muted);
  font-size: 0.92rem;
}
.foot a { color: var(--ink); }

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(22, 18, 15, 0.92);
  display: none;
  z-index: 20;
  padding: 1rem;
}
.lightbox.open { display: grid; grid-template-rows: auto 1fr auto; }
.lb-stage {
  display: grid;
  place-items: center;
  min-height: 0;
  touch-action: pan-y;
}
.lightbox img {
  max-height: calc(100vh - 8rem);
  max-width: min(1200px, 100%);
  margin: auto;
  object-fit: contain;
  width: auto;
  height: auto;
}
.lb-bar, .lb-cap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #f3efe8;
  gap: 0.8rem;
}
.lightbox button {
  background: transparent;
  color: #f3efe8;
  border: 0;
  border-bottom: 1px solid rgba(243, 239, 232, 0.7);
  border-radius: 0;
  min-height: 0;
  padding: 0.2rem 0;
}

.admin { padding: 2rem 0 3rem; }
.admin h1 { font-size: clamp(2.8rem, 7vw, 4.8rem); }
.panel {
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line);
  padding: 1.6rem 0 0.4rem;
  margin: 1.6rem 0;
  box-shadow: none;
}
.panel h2 { font-size: 2rem; margin: 0 0 0.4rem; }
.hint { color: var(--muted); margin: 0.3rem 0 0.9rem; }
label { display: block; margin: 0.75rem 0; }
label span, .field-name {
  display: block;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.2rem;
}
input[type="password"], input[type="url"], input[type="text"], textarea {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid #c9c0b4;
  padding: 0.65rem 0;
  border-radius: 0;
}
textarea { min-height: 7rem; resize: vertical; }
.drop {
  border: 1px dashed #b7ad9f;
  padding: 1.1rem;
  display: block;
  background: rgba(255, 252, 248, 0.45);
}
.drop input { margin-top: 0.7rem; }
.row { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
.check { display: flex; gap: 0.6rem; align-items: flex-start; }
.check input { margin-top: 0.25rem; }
.notice { min-height: 1.4rem; margin: 0.6rem 0; }
.notice.bad { color: var(--danger); }
.notice.good { color: var(--ok); }
.proj {
  border-top: 1px solid var(--line);
  padding: 1rem 0 1.2rem;
}
.proj-top { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; }
.proj h3 { margin: 0; font-size: 2rem; }
.proj h3 a { text-decoration: none; }
.grid-2 { display: grid; gap: 0.4rem 1rem; }
@media (min-width: 800px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .span-2 { grid-column: 1 / -1; }
}

.noscript {
  width: min(1180px, calc(100% - 2rem));
  margin: 1rem auto;
  color: var(--danger);
}
