/*
  СТИЛИ САЙТА (версия 4, бренд «У всех на виду»).
  Порядок файла: шрифты → переменные (цвета, отступы) → общие вещи → блоки сверху вниз по странице.
  Цвета и отступы меняются в одном месте — в блоке :root.
*/

/* ---------- ШРИФТЫ (лежат на своём сервере, в папке fonts) ---------- */
/* unicode-range: браузер качает кириллицу и латиницу отдельными маленькими файлами */
@font-face { font-family: "Fira Cond"; font-weight: 300; font-display: swap; src: url("../fonts/fira-sans-extra-condensed-cyrillic-300-normal.woff2") format("woff2"); unicode-range: U+0400-04FF, U+2116; }
@font-face { font-family: "Fira Cond"; font-weight: 300; font-display: swap; src: url("../fonts/fira-sans-extra-condensed-latin-300-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+2010-2027, U+20BD; }
@font-face { font-family: "Fira Cond"; font-weight: 800; font-display: swap; src: url("../fonts/fira-sans-extra-condensed-cyrillic-800-normal.woff2") format("woff2"); unicode-range: U+0400-04FF, U+2116; }
@font-face { font-family: "Fira Cond"; font-weight: 800; font-display: swap; src: url("../fonts/fira-sans-extra-condensed-latin-800-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+2010-2027, U+20BD; }
@font-face { font-family: "Fira"; font-weight: 400; font-display: swap; src: url("../fonts/fira-sans-cyrillic-400-normal.woff2") format("woff2"); unicode-range: U+0400-04FF, U+2116; }
@font-face { font-family: "Fira"; font-weight: 400; font-display: swap; src: url("../fonts/fira-sans-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+2010-2027, U+20BD; }
@font-face { font-family: "Fira"; font-weight: 600; font-display: swap; src: url("../fonts/fira-sans-cyrillic-600-normal.woff2") format("woff2"); unicode-range: U+0400-04FF, U+2116; }
@font-face { font-family: "Fira"; font-weight: 600; font-display: swap; src: url("../fonts/fira-sans-latin-600-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+2010-2027, U+20BD; }
@font-face { font-family: "JB Mono"; font-weight: 400; font-display: swap; src: url("../fonts/jetbrains-mono-cyrillic-400-normal.woff2") format("woff2"); unicode-range: U+0400-04FF, U+2116; }
@font-face { font-family: "JB Mono"; font-weight: 400; font-display: swap; src: url("../fonts/jetbrains-mono-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+2010-2027, U+20BD; }
@font-face { font-family: "Playfair"; font-weight: 400; font-display: swap; src: url("../fonts/playfair-display-cyrillic-400-normal.woff2") format("woff2"); unicode-range: U+0400-04FF; }
@font-face { font-family: "Playfair"; font-weight: 400; font-display: swap; src: url("../fonts/playfair-display-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF; }

/* ---------- ПЕРЕМЕННЫЕ ---------- */
:root {
  --cream: #F8F1E7;      /* сливки — светлый фон */
  --black: #0B0B0B;      /* тёмный фон и текст */
  --wine: #5B0F18;       /* бордо — главный акцент */
  --wine-deep: #3B0E10;  /* бордо глубокое */
  --wine-light: #E0A3A9; /* бордо для тёмного фона (на чёрном обычное бордо не читается) */
  --sand: #E3D9CC;       /* линии на светлом */
  --sand-bg: #EFE6D9;    /* второй светлый фон */
  --graphite: #26221F;   /* линии на тёмном */
  --gray: #655D55;       /* второстепенный текст на светлом (темнее фирменного серого — чтобы читалось) */
  --gray-dark: #B5ABA0;  /* второстепенный текст на тёмном */

  --f-head: "Fira Cond", "Arial Narrow", sans-serif;
  --f-text: "Fira", "Segoe UI", system-ui, sans-serif;
  --f-mono: "JB Mono", "Consolas", monospace;
  --f-logo: "Playfair", Georgia, serif;

  --pad: clamp(20px, 5vw, 64px);          /* поля страницы */
  --gap: clamp(64px, 10vw, 140px);        /* воздух между разделами */
  --ease: cubic-bezier(.2, .7, .2, 1);    /* одна кривая движения на весь сайт */
}

/* ---------- ОБЩЕЕ ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--cream); color: var(--black); font: 400 clamp(16px, 1.15vw, 18px)/1.5 var(--f-text); }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ol, ul, dl, dd, blockquote { margin: 0; padding: 0; }
ol, ul { list-style: none; }
:focus-visible { outline: 3px solid var(--wine); outline-offset: 3px; }
.dark :focus-visible, .hero :focus-visible, .top :focus-visible { outline-color: var(--cream); }

.wrap { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 var(--pad); }
.section { padding: var(--gap) 0; }
.dark { background: var(--black); color: var(--cream); }
.sand { background: var(--sand-bg); }
.mono { font-family: var(--f-mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.muted { color: var(--gray); font-size: .92em; margin-top: 24px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; z-index: 100; background: var(--cream); padding: 12px 16px; }

/* Заголовки: тонкое начало + жирный финал — фирменный приём */
.h2, .hero__title, .final__title { font-family: var(--f-head); font-weight: 800; text-transform: uppercase; line-height: .95; letter-spacing: .005em; }
.h2 { font-size: clamp(40px, 6.4vw, 92px); max-width: 14ch; margin-bottom: clamp(28px, 4vw, 56px); }
.thin { font-weight: 300; display: block; }
.h3 { font: 600 clamp(18px, 1.5vw, 22px)/1.25 var(--f-text); margin-bottom: 8px; }
.tag { color: var(--wine); margin-bottom: 20px; }
.dark .tag { color: var(--wine-light); }
.lead { font-size: clamp(18px, 1.6vw, 23px); line-height: 1.4; max-width: 46ch; }

/* Кнопки */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 54px; padding: 14px 28px; background: var(--wine); color: var(--cream); font: 600 16px/1.2 var(--f-text); text-decoration: none; border: 1px solid var(--wine); transition: background .25s var(--ease), transform .25s var(--ease); }
.btn:hover { background: var(--wine-deep); transform: translateY(-2px); }
.btn--ghost { background: transparent; border-color: rgba(248, 241, 231, .55); }
.btn--ghost:hover { background: rgba(248, 241, 231, .12); }
.btn--small { min-height: 44px; padding: 10px 18px; font-size: 14px; white-space: nowrap; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- ПОЛОСКА «ЧЕРНОВИК» ---------- */
.draft { background: var(--wine-deep); color: var(--cream); font: 400 12px/1.4 var(--f-mono); letter-spacing: .06em; text-transform: uppercase; text-align: center; padding: 8px 16px; position: relative; z-index: 20; }

/* ---------- ШАПКА (лежит поверх фото) ---------- */
.top { position: absolute; left: 0; right: 0; z-index: 10; color: var(--cream); }
.top__in { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-top: 20px; padding-bottom: 20px; }
.logo { text-decoration: none; display: grid; gap: 2px; }
.logo__name { font: 400 24px/1 var(--f-logo); }
.logo__line { font: 400 10px/1.3 var(--f-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--gray-dark); }
.nav { display: none; gap: 28px; font: 400 13px/1 var(--f-mono); letter-spacing: .08em; text-transform: uppercase; }
.nav a { text-decoration: none; padding: 12px 0; border-bottom: 1px solid transparent; }
.nav a:hover { border-color: var(--cream); }
@media (min-width: 900px) { .nav { display: flex; } }
@media (max-width: 420px) { .logo__line { display: none; } }

/* ---------- 1. ПЕРВЫЙ ЭКРАН ---------- */
.hero { position: relative; min-height: min(100svh, 900px); display: grid; align-content: end; background: var(--black); color: var(--cream); overflow: hidden; }
.hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 78% 30%; }
/* затемнение слева и снизу, чтобы текст читался на любом экране */
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(11, 11, 11, .9) 0%, rgba(11, 11, 11, .55) 45%, rgba(11, 11, 11, 0) 75%), linear-gradient(0deg, rgba(11, 11, 11, .9) 0%, rgba(11, 11, 11, 0) 45%); }
.hero__in, .hero__log { position: relative; z-index: 2; }
.hero__in { padding-top: 140px; padding-bottom: clamp(28px, 4vw, 48px); }
.hero__for { color: var(--gray-dark); margin-bottom: 20px; max-width: 34ch; }
.hero__title { font-size: clamp(56px, 8.6vw, 150px); max-width: 9ch; }
.hero__title em, .final__title em { font-style: normal; color: var(--wine-light); }
.hero__sub { max-width: 44ch; margin: clamp(20px, 2.4vw, 32px) 0; font-size: clamp(17px, 1.45vw, 21px); line-height: 1.45; }
.hero__log { display: flex; flex-wrap: wrap; gap: 8px 28px; padding-top: 16px; padding-bottom: 20px; border-top: 1px solid rgba(248, 241, 231, .25); color: var(--gray-dark); font-size: 12px; }
.hero__log span + span::before { content: "·"; margin-right: 28px; }
@media (max-width: 700px) {
  .hero::after { background: linear-gradient(0deg, rgba(11, 11, 11, .96) 0%, rgba(11, 11, 11, .86) 52%, rgba(11, 11, 11, .2) 80%); }
  .hero__img { object-position: 72% 0; height: 62%; }
  .hero__log span + span::before { display: none; }
  .hero__log { gap: 6px 18px; }
}

/* ---------- 2. ОДНА МЫСЛЬ ---------- */
.statement { background: var(--wine-deep); color: var(--cream); }
.statement__text { font: 800 clamp(34px, 5.4vw, 80px)/1 var(--f-head); text-transform: uppercase; max-width: 20ch; }
.statement__text span { font-weight: 300; color: #E9D9C8; }

/* ---------- 3. ЧЕТЫРЕ МЕСТА ---------- */
.places { display: grid; gap: 0; border-top: 1px solid var(--black); }
.place { display: grid; grid-template-columns: 64px 1fr; column-gap: 16px; padding: 24px 0; border-bottom: 1px solid var(--sand); }
.place__n { grid-row: span 2; font: 300 44px/1 var(--f-head); color: var(--gray); }
.place p { color: var(--gray); max-width: 40ch; }
@media (min-width: 900px) {
  .places { grid-template-columns: repeat(4, 1fr); }
  .place { grid-template-columns: 1fr; padding: 28px 28px 8px 0; border-bottom: 0; border-right: 1px solid var(--sand); }
  .place + .place { padding-left: 28px; }
  .place:last-child { border-right: 0; }
  .place__n { grid-row: auto; margin-bottom: 48px; font-size: 56px; }
}

/* ---------- 4. СМЕТА ---------- */
.smeta-section { background: var(--sand-bg); }
.smeta { margin-top: clamp(32px, 4vw, 56px); background: var(--cream); border: 1px solid var(--black); }
.smeta__head { display: none; }
.row { display: grid; grid-template-columns: 28px 1fr; gap: 6px 14px; align-items: start; padding: 18px clamp(16px, 2.5vw, 32px); border-bottom: 1px solid var(--sand); cursor: pointer; transition: background .2s var(--ease), opacity .2s var(--ease); }
.row:hover { background: #FBF7F0; }
/* свой квадратик-галочка вместо стандартного */
.row input { appearance: none; -webkit-appearance: none; width: 26px; height: 26px; margin: 2px 0 0; border: 1px solid var(--black); background: var(--cream); cursor: pointer; display: grid; place-content: center; }
.row input::after { content: ""; width: 12px; height: 7px; border-left: 2px solid var(--cream); border-bottom: 2px solid var(--cream); transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.row input:checked { background: var(--wine); border-color: var(--wine); }
.row input:checked::after { opacity: 1; }
.row__n { display: none; color: var(--gray); }
.row__body b { display: block; font: 600 clamp(18px, 1.6vw, 22px)/1.25 var(--f-text); }
.row__body small { display: block; font-size: 15px; color: var(--gray); margin-top: 4px; max-width: 52ch; }
.row__price { grid-column: 2; color: var(--black); text-transform: none; letter-spacing: 0; font-size: 15px; white-space: nowrap; }
/* строка без галочки бледнеет и цена зачёркивается */
.row:has(input:not(:checked)) .row__body, .row:has(input:not(:checked)) .row__price { opacity: .45; }
.row:has(input:not(:checked)) .row__price { text-decoration: line-through; }
@media (min-width: 800px) {
  .smeta__head, .row { grid-template-columns: 28px 48px 1fr 220px; gap: 0 20px; align-items: center; }
  .smeta__head { display: grid; padding: 14px clamp(16px, 2.5vw, 32px); border-bottom: 1px solid var(--black); color: var(--gray); font-size: 12px; }
  .smeta__head span:first-child { grid-column: 2; }
  .smeta__head span:last-child, .row__price { text-align: right; }
  .row { padding-top: 22px; padding-bottom: 22px; }
  .row input { margin: 0; }
  .row__n { display: block; }
  .row__price { grid-column: auto; font-size: 16px; }
}
.total { display: grid; background: var(--black); color: var(--cream); }
.total__col { padding: clamp(20px, 3vw, 36px) clamp(16px, 2.5vw, 32px); }
.total__col--mine { background: var(--wine); }
.total__label { color: var(--gray-dark); font-size: 12px; margin-bottom: 10px; }
.total__col--mine .total__label { color: #EBCFD2; }
.total__sum { font: 800 clamp(40px, 5.4vw, 76px)/1 var(--f-head); white-space: nowrap; }
.total__col:first-child .total__sum { font-weight: 300; }
.total__note { margin-top: 10px; font-size: 15px; min-height: 1.5em; }
@media (min-width: 800px) { .total { grid-template-columns: 1.2fr 1fr; } }
.footnote { margin-top: 16px; font-size: 14px; color: var(--gray); max-width: 70ch; }

/* ---------- 5. ПАКЕТЫ ---------- */
.packs { display: grid; gap: 16px; }
.pack { border: 1px solid var(--black); padding: clamp(24px, 3vw, 36px); display: flex; flex-direction: column; gap: 16px; background: var(--cream); }
.pack--main { background: var(--black); color: var(--cream); }
.pack__kind { color: var(--gray); font-size: 12px; }
.pack--main .pack__kind { color: var(--wine-light); }
.pack__name { font: 800 clamp(34px, 3.4vw, 48px)/.95 var(--f-head); text-transform: uppercase; }
.pack__price { font: 300 clamp(44px, 4.6vw, 64px)/1 var(--f-head); white-space: nowrap; padding-bottom: 16px; border-bottom: 1px solid currentColor; }
.pack__list { display: grid; gap: 10px; flex: 1; align-content: start; }
.pack__list li { padding-left: 22px; position: relative; }
.pack__list li::before { content: ""; position: absolute; left: 0; top: .62em; width: 10px; height: 1px; background: currentColor; }
.pack__term { color: var(--gray); font-size: 12px; }
.pack--main .pack__term { color: var(--gray-dark); }
@media (min-width: 900px) { .packs { grid-template-columns: 1fr 1.25fr 1fr; align-items: stretch; } }
.terms { margin-top: clamp(32px, 4vw, 56px); display: grid; gap: 0; border-top: 1px solid var(--black); }
.term { display: grid; gap: 6px; padding: 18px 0; border-bottom: 1px solid var(--sand); }
.term dt { color: var(--gray); font-size: 12px; }
.term dd { max-width: 60ch; }
.term dd span { font-weight: 600; }
@media (min-width: 800px) { .term { grid-template-columns: 220px 1fr; gap: 20px; } }

/* ---------- 6. РАБОТЫ ---------- */
.works { display: grid; gap: 0; border-top: 1px solid var(--graphite); }
.work { display: grid; gap: 8px; padding: 28px 0; border-bottom: 1px solid var(--graphite); text-decoration: none; transition: padding .3s var(--ease); }
.work:hover { padding-left: 16px; }
.work__kind { color: var(--gray-dark); font-size: 12px; }
.work__site { font: 800 clamp(40px, 7vw, 104px)/.95 var(--f-head); text-transform: uppercase; }
.work:hover .work__site { color: var(--wine-light); }
.work__text { color: var(--gray-dark); max-width: 50ch; }
.quote { margin-top: clamp(40px, 5vw, 72px); max-width: 30ch; padding-left: 20px; border-left: 4px solid var(--wine-light); }
.quote p { font-size: clamp(22px, 2.4vw, 34px); line-height: 1.25; }
.quote footer { margin-top: 16px; color: var(--gray-dark); font-size: 12px; max-width: 40ch; }
.quote { max-width: 760px; }

/* ---------- 7. ШАГИ ---------- */
.steps { display: grid; gap: 0; border-top: 1px solid var(--black); }
.step { padding: 24px 0; border-bottom: 1px solid var(--sand); display: grid; grid-template-columns: 64px 1fr; column-gap: 16px; }
.step__n { grid-row: span 2; font: 800 56px/.9 var(--f-head); color: var(--wine); }
.step p { color: var(--gray); max-width: 40ch; }
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(4, 1fr); column-gap: 32px; border-top: 0; }
  .step { grid-template-columns: 1fr; border-top: 1px solid var(--black); border-bottom: 0; }
  .step__n { grid-row: auto; font-size: 88px; margin-bottom: 32px; }
}

/* ---------- 8. ОБО МНЕ ---------- */
.about { display: grid; gap: clamp(32px, 5vw, 80px); align-items: center; }
.about__img { width: 100%; max-width: 520px; aspect-ratio: 4 / 5; object-fit: cover; }
.why { margin-top: 28px; display: grid; gap: 0; border-top: 1px solid var(--black); }
.why li { padding: 16px 0; border-bottom: 1px solid var(--sand); max-width: 56ch; }
.sand .why li { border-color: #D8CCBC; }
@media (min-width: 900px) { .about { grid-template-columns: 5fr 6fr; } }

/* ---------- 9. ВОПРОСЫ ---------- */
.faq { display: grid; gap: 8px; }
.faq__list { border-top: 1px solid var(--black); }
.q { border-bottom: 1px solid var(--sand); }
.q summary { cursor: pointer; list-style: none; padding: 20px 44px 20px 0; position: relative; font: 600 clamp(18px, 1.5vw, 21px)/1.3 var(--f-text); }
.q summary::-webkit-details-marker { display: none; }
.q summary::after { content: "+"; position: absolute; right: 6px; top: 14px; font: 300 32px/1 var(--f-head); color: var(--wine); transition: transform .25s var(--ease); }
.q[open] summary::after { transform: rotate(45deg); }
.q p { padding: 0 0 22px; color: var(--gray); max-width: 58ch; }
@media (min-width: 900px) { .faq { grid-template-columns: 5fr 7fr; gap: 48px; } }

/* ---------- 10. ФИНАЛ И ПОДВАЛ ---------- */
.final__title { font-size: clamp(48px, 8.5vw, 132px); max-width: 11ch; margin-bottom: 28px; }
.final .lead { margin-bottom: 32px; color: #E9D9C8; }
.footer { background: var(--black); color: var(--gray-dark); border-top: 1px solid var(--graphite); }
.footer__in { display: flex; flex-wrap: wrap; gap: 12px 32px; justify-content: space-between; padding-top: 24px; padding-bottom: 24px; font-size: 12px; }
.footer a { padding: 8px 0; }

/* ---------- ПОЯВЛЕНИЕ ПРИ ПРОКРУТКЕ ---------- */
/* Блоки прячутся только если скрипт включился (класс js-reveal ставит main.js) */
.js-reveal .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js-reveal .reveal.is-in { opacity: 1; transform: none; }
.js-reveal .reveal:nth-child(2) { transition-delay: .08s; }
.js-reveal .reveal:nth-child(3) { transition-delay: .16s; }
.js-reveal .reveal:nth-child(4) { transition-delay: .24s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
