:root {
  --paper: #f4efe8;
  --paper-2: #faf6ef;
  --ink: #1a1512;
  --ink-soft: #4a3f36;
  --dim: #6b5f52;
  --mute: #9b8f80;
  --acc: #c14a2b;
  --line: rgba(26,21,18,0.14);
  --serif: 'Fraunces', 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--serif); color: var(--ink); background: var(--paper);
  font-size: 19px; line-height: 1.7; -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--acc); }

/* ---------- Progress-bar ---------- */
.progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 60; pointer-events: none; }
.progress i { display: block; height: 100%; width: 0; background: var(--acc); transition: width .1s linear; }

/* ---------- Dot-nav ---------- */
.dot-nav { position: fixed; right: 20px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 14px; z-index: 55; }
.dot-nav a { width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid var(--ink); background: transparent; transition: all .25s; position: relative; }
.dot-nav a::before { content: attr(data-label); position: absolute; right: 22px; top: 50%; transform: translateY(-50%); font-family: var(--sans); font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink); opacity: 0; white-space: nowrap; transition: opacity .2s; background: var(--paper); padding: 3px 8px; }
.dot-nav a:hover::before, .dot-nav a.is-active::before { opacity: 1; }
.dot-nav a.is-active { background: var(--acc); border-color: var(--acc); transform: scale(1.3); }

/* ---------- ПЛЁНКИ ПО БОКАМ (реалистичная 35мм плёнка) ---------- */
.film {
  position: fixed; top: 0; bottom: 0; width: 210px; overflow: hidden; z-index: 40;
  pointer-events: none; background: #0a0605;
}
.film--left { left: 30px; } .film--right { right: 30px; }
.film-mark { display: none; }
.film-strip {
  position: relative; display: flex; flex-direction: column; gap: 0;
  padding: 0; z-index: 2; pointer-events: auto;
  animation: filmFlow linear infinite; will-change: transform;
}
.film--left .film-strip { animation-duration: 90s; animation-name: filmFlowDown; }
.film--right .film-strip { animation-duration: 108s; animation-name: filmFlowUp; }
.film:hover .film-strip { animation-play-state: paused; }
@keyframes filmFlowDown { 0% { transform: translateY(-50%); } 100% { transform: translateY(0); } }
@keyframes filmFlowUp { 0% { transform: translateY(0); } 100% { transform: translateY(-50%); } }

/* КАДР = единый блок: чёрные полосы плёнки с перфорацией + фото внутри.
   Всё движется как одно целое, потому что перфорация — часть кадра. */
.film-frame {
  position: relative; width: 100%; height: 230px;
  background: #050302; padding: 18px 34px;
}
/* перфорация — прямоугольные отверстия по обоим краям */
.film-frame::before, .film-frame::after {
  content: ''; position: absolute; top: 0; bottom: 0; width: 26px;
  background-image: repeating-linear-gradient(
    0deg, transparent 0px, transparent 5px,
    #f4efe8 5px, #f4efe8 17px,
    transparent 17px, transparent 22px);
  background-size: 100% 22px;
  z-index: 4;
}
.film-frame::before { left: 3px; }
.film-frame::after { right: 3px; }
/* сам фото-квадрат внутри плёнки — БОЛЬШЕ */
.film-photo {
  position: relative; width: 100%; height: 100%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.6);
  overflow: hidden;
}
.film-photo::after {
  content: attr(data-n); position: absolute; top: 4px; left: 6px;
  font-family: var(--sans); font-size: 8px; letter-spacing: 0.1em;
  color: rgba(255,180,80,0.7); z-index: 4;
}
.ff-1{background:linear-gradient(160deg,#2d2422,#4a3835)}
.ff-2{background:linear-gradient(160deg,#3a2f2a,#6b5b40)}
.ff-3{background:linear-gradient(160deg,#2a2d33,#3f4552)}
.ff-4{background:linear-gradient(160deg,#38302a,#5a4736)}
.ff-5{background:linear-gradient(160deg,#2f2925,#503d33)}
.ff-6{background:linear-gradient(160deg,#33302a,#7a6647)}
.ff-7{background:linear-gradient(160deg,#40352c,#8a6f4a)}
.ff-8{background:linear-gradient(160deg,#25201d,#4c3f34)}
.ff-9{background:linear-gradient(160deg,#1e1a17,#5c4633)}
.ff-10{background:linear-gradient(160deg,#2d2b28,#88724d)}
.ff-11{background:linear-gradient(160deg,#3b3128,#a08464)}
.ff-12{background:linear-gradient(160deg,#26221f,#4a4133)}
.ff-13{background:linear-gradient(160deg,#312a24,#7b5f45)}
.ff-14{background:linear-gradient(160deg,#282625,#5a5044)}
.ff-15{background:linear-gradient(160deg,#3c332c,#96795a)}
.ff-16{background:linear-gradient(160deg,#231e1b,#4c3d30)}
.ff-17{background:linear-gradient(160deg,#2e2a26,#665542)}
.ff-18{background:linear-gradient(160deg,#3a2e26,#a48661)}
.ff-19{background:linear-gradient(160deg,#28221e,#57452f)}
.ff-20{background:linear-gradient(160deg,#332b24,#7d6244)}

/* контент с отступами под плёнки */
.wrap { padding: 0 270px; }

/* ---------- Sections ---------- */
.chapter { max-width: 720px; margin: 0 auto; padding: 60px 24px; position: relative; }
.chapter-n { display: block; font-family: var(--sans); font-size: 12px; letter-spacing: 0.28em; color: var(--acc); font-weight: 700; margin-bottom: 20px; text-transform: uppercase; }
.chapter h1, .chapter h2 { font-family: var(--serif); font-weight: 700; line-height: 1.05; letter-spacing: -0.02em; margin: 0 0 22px; }
.chapter h1 { font-size: clamp(52px, 7vw, 96px); }
.chapter h2 { font-size: clamp(36px, 5vw, 60px); }
.chapter em { color: var(--acc); font-style: italic; }
.chapter .lead { font-size: 22px; line-height: 1.5; color: var(--dim); margin-bottom: 26px; max-width: 620px; }
.chapter p { font-size: 18px; line-height: 1.7; margin: 0 0 16px; max-width: 620px; }
.chapter .signature { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--acc); margin-top: 30px; }

/* Prologue */
.prologue { min-height: 72vh; display: flex; align-items: flex-end; padding-bottom: 40px; padding-top: 60px; }
.prologue .meta { font-family: var(--sans); font-size: 11px; letter-spacing: 0.3em; color: var(--mute); text-transform: uppercase; margin-bottom: 26px; display: flex; gap: 22px; flex-wrap: wrap; }
.prologue h1 .line { display: block; opacity: 0; transform: translateY(30px); animation: enter 1.1s ease forwards; }
.prologue h1 .line:nth-child(2) { animation-delay: .18s; }
.prologue h1 .line:nth-child(3) { animation-delay: .36s; }
@keyframes enter { to { opacity: 1; transform: none; } }
.prologue .scroll-hint { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); font-family: var(--sans); font-size: 10px; letter-spacing: 0.28em; color: var(--dim); text-transform: uppercase; }
.prologue .scroll-hint::after { content: '↓'; display: block; margin: 8px auto 0; color: var(--acc); font-size: 16px; animation: bob 2s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(6px); } }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s ease, transform .9s ease; }
.reveal.is-in { opacity: 1; transform: none; }

/* Directions */
.directions { list-style: none; padding: 0; margin: 24px 0 0; }
.directions li { padding: 22px 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: 74px 1fr auto; gap: 20px; align-items: baseline; }
.directions li:last-child { border-bottom: 1px solid var(--line); }
.directions .d-n { font-family: var(--sans); font-size: 12px; letter-spacing: 0.24em; color: var(--acc); font-weight: 700; text-transform: uppercase; }
.directions .d-name { font-family: var(--serif); font-size: 26px; font-weight: 700; margin: 0; }
.directions .d-price { font-family: var(--sans); font-size: 14px; color: var(--dim); letter-spacing: 0.05em; white-space: nowrap; }

/* Prices */
.prices { list-style: none; padding: 0; margin: 24px 0 0; }
.prices li { padding: 18px 0; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 20px; font-family: var(--serif); font-size: 20px; }
.prices li:last-child { border-bottom: 1px solid var(--line); }
.prices .p-name { font-weight: 700; }
.prices .p-val { color: var(--acc); font-style: italic; white-space: nowrap; }
.prices-note { font-size: 14px; color: var(--mute); margin-top: 18px; }

/* Locations */
.locations { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 24px; list-style: none; padding: 0; margin: 24px 0 0; }
.locations li { padding: 12px 0; border-top: 1px solid var(--line); font-family: var(--serif); font-size: 19px; }
.locations li::before { content: '·'; color: var(--acc); margin-right: 10px; }

/* Reviews */
.review-full { margin: 40px 0 0; }
.review-full blockquote { margin: 0 0 44px; padding-left: 22px; border-left: 3px solid var(--acc); }
.review-full p { font-family: var(--serif); font-style: italic; font-size: 22px; line-height: 1.5; color: var(--ink); margin: 0 0 14px; max-width: 600px; }
.review-full footer { font-family: var(--sans); font-size: 12px; letter-spacing: 0.15em; color: var(--dim); text-transform: uppercase; }

/* Epilogue */
.epilogue { padding-bottom: 70px; }
.contacts-list { list-style: none; padding: 0; margin: 30px 0 20px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 560px; }
.contacts-list li { display: flex; flex-direction: column; gap: 4px; padding: 12px 0; border-top: 1px solid var(--line); }
.contacts-list li:nth-child(-n+2) { border-top: 0; }
.contacts-list span { font-family: var(--sans); font-size: 10px; letter-spacing: 0.24em; color: var(--mute); text-transform: uppercase; }
.contacts-list a { color: var(--ink); font-family: var(--serif); font-size: 19px; text-decoration: none; }
.contacts-list a:hover { color: var(--acc); }
.soc-link { display: inline-flex !important; align-items: center; gap: 10px; }
.cta-write { display: inline-block; margin-top: 14px; font-family: var(--serif); font-size: 40px; font-style: italic; color: var(--acc); text-decoration: none; border-bottom: 2px solid var(--acc); padding-bottom: 3px; transition: opacity .2s; }
.cta-write:hover { opacity: 0.7; }

/* Footer */
.foot { padding: 32px 24px; border-top: 1px solid var(--line); font-family: var(--sans); font-size: 11px; letter-spacing: 0.14em; color: var(--mute); text-transform: uppercase; text-align: center; }
.foot a { color: var(--mute); text-decoration: underline; }

/* Responsive */
@media (max-width: 900px) {
  .wrap { padding: 0 140px; }
  .film { width: 130px; }
  .film-strip { padding: 10px 30px; }
  .film::before { left: 4px; } .film::after { right: 4px; }
  .film-mark { left: 30px; } .film--right .film-mark { left: auto; right: 30px; }
}
@media (max-width: 640px) {
  body { font-size: 17px; }
  .wrap { padding: 0; }
  .film { display: none; }
  .dot-nav { right: 12px; }
  .dot-nav a::before { display: none; }
  .chapter { padding: 80px 22px; }
  .directions li { grid-template-columns: 1fr; gap: 4px; }
  .directions .d-price { margin-top: 6px; }
  .locations { grid-template-columns: 1fr; }
  .contacts-list { grid-template-columns: 1fr; }
  .cta-write { font-size: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  .prologue h1 .line, .prologue .scroll-hint::after, .reveal, .film-strip { animation: none; opacity: 1; transform: none; transition: none; }
}
