/* петров.space v3: «ваш список имён». Токены и идея: DESIGN.md */
:root {
  --spruce: #0F2F27;   /* Ель */
  --needle: #1C463A;   /* Хвоя */
  --snow: #F3F5F2;     /* Снег */
  --lamp: #F6C453;     /* Гирлянда */
  --frost: #B9CBC3;    /* Иней */
  --moss: #56655F;     /* Мох */
  --rule: #D3DBD6;
  --font: "Geologica", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; margin: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 16px; }
body { background: var(--snow); color: var(--spruce); font: 400 17px/1.6 var(--font); -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility; overflow-x: hidden; }
img, video { display: block; max-width: 100%; }
a { color: inherit; }
ul, ol { padding: 0; list-style: none; }
:focus-visible { outline: 3px solid var(--lamp); outline-offset: 3px; }
.day :focus-visible { outline-color: var(--spruce); }
.wrap { width: min(1200px, 100% - 32px); margin-inline: auto; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 20; padding: 10px 16px; background: var(--lamp); color: var(--spruce); border-radius: 8px; }
.skip:focus { top: 12px; }

h1, h2, h3 { font-weight: 800; letter-spacing: -.03em; text-wrap: balance; }
h1 { font-size: clamp(38px, 4.5vw, 66px); line-height: 1.02; }
h2 { font-size: clamp(34px, 3.8vw, 54px); line-height: 1.05; margin-bottom: 20px; }
h3 { font-size: 24px; line-height: 1.2; letter-spacing: -.02em; font-weight: 700; }

.night { background: var(--spruce); color: var(--snow); }
.day { color: var(--spruce); }

/* кнопки */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 56px; padding: 0 28px; border: 0;
  border-radius: 8px; background: var(--lamp); color: var(--spruce); font: 600 17px/1.2 var(--font); text-decoration: none;
  cursor: pointer; transition: background-color .15s; }
.btn:hover { background: #FFD574; }
.btn-sm { min-height: 42px; padding: 0 18px; font-size: 15px; }
.btn-line { background: transparent; color: var(--snow); box-shadow: inset 0 0 0 2px var(--frost); }
.btn-line:hover { background: var(--needle); }
.link { font-weight: 500; text-underline-offset: 5px; text-decoration-thickness: 1px; }
.link:hover { text-decoration-thickness: 2px; }

/* шапка */
.bar { display: flex; align-items: center; gap: 28px; padding: 20px 0; font-size: 15px; }
.bar .name { font-weight: 700; font-size: 18px; letter-spacing: -.01em; text-decoration: none; margin-right: auto; }
.bar-link { color: var(--frost); text-decoration: none; }
.bar-link:hover { color: var(--snow); }

/* первый экран */
.hero { padding-bottom: 0; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "h stage" "copy stage";
  grid-template-rows: auto 1fr; column-gap: clamp(32px, 5vw, 80px); padding: clamp(24px, 4vh, 56px) 0 56px; }
.hero h1 { grid-area: h; align-self: start; padding-top: 18px; }
.hero-copy { grid-area: copy; padding-top: 26px; }
.lead { font-size: 20px; line-height: 1.5; color: #DCE6E1; max-width: 33em; }
.hero-act { display: flex; align-items: center; gap: 28px; margin-top: 30px; }
.promise { margin-top: 30px; font-size: 15px; color: var(--frost); max-width: 34em; }
.promise li { position: relative; padding-left: 22px; }
.promise li + li { margin-top: 6px; }
.promise li::before { content: ""; position: absolute; left: 0; top: .62em; width: 10px; height: 6px;
  border-left: 2px solid var(--lamp); border-bottom: 2px solid var(--lamp); transform: rotate(-45deg); }

/* сцена: ролик и список, который горит в такт */
.stage { grid-area: stage; display: grid; grid-template-columns: auto 224px; gap: 20px; align-items: stretch; align-self: start; }
.list { display: flex; flex-direction: column; }
.screen { position: relative; height: min(600px, calc(100vh - 190px)); min-height: 440px; aspect-ratio: 9 / 16; }
.screen video { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; background: var(--needle); }
.sound { position: absolute; left: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 10px; padding: 9px 14px 9px 12px;
  border: 0; border-radius: 8px; background: rgba(15, 47, 39, .82); color: var(--snow); font: 500 14px/1 var(--font); cursor: pointer; }
.sound::before { content: ""; border-left: 9px solid var(--lamp); border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.sound:hover { background: var(--spruce); }
.list-h { font-size: 14px; color: var(--frost); margin-bottom: 10px; }
.names { border-top: 1px solid var(--needle); }
.nm { display: grid; grid-template-columns: 26px 1fr; align-items: baseline; padding: 11px 10px 11px 8px; border-bottom: 1px solid var(--needle);
  border-radius: 4px; transition: background-color .3s, color .3s; }
.nm-n { font-size: 13px; color: var(--frost); font-variant-numeric: tabular-nums; }
.nm-t { font-weight: 500; font-size: 16px; line-height: 1.3; }
.nm-end .nm-t { font-weight: 400; font-size: 14px; color: var(--frost); }
.nm.is-on { background: var(--lamp); color: var(--spruce); border-bottom-color: var(--lamp); }
.nm.is-on .nm-n, .nm.is-on .nm-t { color: var(--spruce); }
.list-note { margin-top: 16px; font-size: 14px; line-height: 1.45; color: var(--frost); }
.picks { display: grid; gap: 8px; margin-top: auto; padding-top: 22px; }
.pick { min-height: 44px; padding: 0 14px; border: 1px solid var(--needle); border-radius: 8px; background: transparent; color: var(--snow);
  font: 500 15px var(--font); text-align: left; cursor: pointer; }
.pick:hover { border-color: var(--frost); }
.pick.is-on { background: var(--snow); color: var(--spruce); border-color: var(--snow); }
.also { padding: 26px 0 30px; border-top: 1px solid var(--needle); color: var(--frost); font-size: 15px; }
.also a { color: var(--snow); font-weight: 500; text-underline-offset: 4px; white-space: nowrap; }

/* новый год */
.ny { padding: 96px 0 40px; border-top: 8px solid var(--needle); }
.ny-head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 14px clamp(32px, 5vw, 80px); align-items: end; margin-bottom: 52px; }
.ny-head h2 { grid-row: span 2; margin: 0; max-width: 11ch; }
.ny-head p { color: #DCE6E1; max-width: 36em; }
.tag { justify-self: start; position: relative; padding: 9px 18px 9px 36px; background: var(--lamp);
  background-image: radial-gradient(circle at 17px 50%, var(--spruce) 0 4px, transparent 4.5px);
  clip-path: polygon(12px 0, 100% 0, 100% 100%, 12px 100%, 0 50%); border-radius: 0 6px 6px 0; }
.ny-head .tag { color: var(--spruce); font-weight: 600; font-size: 16px; }
.offer { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 28px clamp(32px, 5vw, 80px); padding: 40px 0 48px; border-top: 1px solid var(--needle); }
.offer-text p { color: #DCE6E1; margin-top: 12px; max-width: 30em; }
.offer-text .sum { margin-top: 22px; color: var(--snow); font-size: 30px; font-weight: 700; letter-spacing: -.02em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.offer-more .btn { margin-top: 24px; }
.offer-media { display: grid; gap: 22px 14px; align-items: start; }
.reel-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.wide-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mix-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.6fr); }
.mix-row .vid[data-kind="v"], .more-row .vid[data-kind="v"] { grid-row: span 2; }
.more-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); }

/* кадры */
.frame { display: block; width: 100%; padding: 0; border: 0; background: none; color: inherit; text-align: left; font: inherit; cursor: zoom-in; }
.shot { position: relative; display: block; overflow: hidden; border-radius: 6px; background: var(--needle); }
.shot img { width: 100%; height: 100%; object-fit: cover; }
.r-v { aspect-ratio: 9 / 16; } .r-h { aspect-ratio: 16 / 9; } .r-s { aspect-ratio: 1 / 1; }
.pic .shot { background: #E3E8E4; }
.pic .shot img { height: auto; }
.cap { display: block; margin-top: 9px; font-size: 14px; line-height: 1.35; color: var(--moss); }
.night .cap { color: var(--frost); }
.frame:hover .cap { color: inherit; }
.play { position: absolute; left: 10px; bottom: 10px; width: 36px; height: 36px; border-radius: 50%; background: var(--lamp); }
.play::after { content: ""; position: absolute; left: 14px; top: 11px; border-left: 11px solid var(--spruce); border-top: 7px solid transparent; border-bottom: 7px solid transparent; }
.frame:hover .shot img { opacity: .92; }

/* работы */
.works, .prices, .how, .faq { padding-top: 112px; }
.note { color: var(--moss); max-width: 40em; margin-bottom: 30px; }
.tabs { display: flex; gap: 8px 30px; flex-wrap: wrap; margin-bottom: 32px; border-bottom: 1px solid var(--rule); }
.tab { min-height: 44px; border: 0; background: none; padding: 0 0 10px; margin-bottom: -1px; font: 500 17px var(--font); color: var(--moss);
  cursor: pointer; border-bottom: 3px solid transparent; }
.tab:hover { color: var(--spruce); }
.tab[aria-selected="true"] { color: var(--spruce); border-bottom-color: var(--spruce); font-weight: 600; }
.grid-v { display: grid; gap: 26px 14px; grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); }
.grid-h { display: grid; gap: 26px 14px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.masonry { columns: 3 300px; column-gap: 18px; }
.masonry .frame { break-inside: avoid; margin-bottom: 26px; }

/* цены */
.price-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 48px clamp(32px, 5vw, 72px); align-items: start; }
.price { width: 100%; border-collapse: collapse; }
.price tr { border-top: 1px solid var(--rule); }
.price tr:last-child { border-bottom: 1px solid var(--rule); }
.price th, .price td { padding: 20px 0; vertical-align: baseline; text-align: left; }
.price th { font-weight: 500; font-size: 18px; line-height: 1.4; padding-right: 32px; }
.price td { text-align: right; font-weight: 700; font-size: 26px; letter-spacing: -.02em; line-height: 1.15; white-space: nowrap; font-variant-numeric: tabular-nums; }
.price small { display: block; font-size: 14px; font-weight: 400; letter-spacing: 0; color: var(--moss); margin-top: 4px; }
.price .ask { font-size: 18px; font-weight: 500; color: var(--moss); }
.terms { margin-top: 74px; padding: 32px 30px 34px; border-radius: 10px; background: var(--spruce); color: var(--snow); }
.terms h3 { margin-bottom: 18px; }
.terms li { padding: 14px 0; border-top: 1px solid var(--needle); font-size: 16px; color: #DCE6E1; line-height: 1.5; }
.terms b { color: var(--snow); font-weight: 600; }
.terms p { margin: 14px 0 24px; padding-top: 14px; border-top: 1px solid var(--needle); font-size: 15px; color: var(--frost); }
.terms .btn { width: 100%; }

/* шаги */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 28px; counter-reset: s; }
.steps li { counter-increment: s; color: var(--moss); font-size: 16px; border-top: 2px solid var(--spruce); padding-top: 16px; }
.steps li::before { content: counter(s); display: block; font-weight: 800; font-size: 44px; line-height: 1; letter-spacing: -.03em; color: var(--spruce); margin-bottom: 18px; }
.steps b { display: block; color: var(--spruce); font-size: 19px; font-weight: 600; margin-bottom: 6px; }

/* вопросы */
.faq-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 20px clamp(32px, 5vw, 80px); align-items: start; }
.qa details { border-top: 1px solid var(--rule); }
.qa details:last-child { border-bottom: 1px solid var(--rule); }
.qa summary { position: relative; padding: 20px 48px 20px 0; font-weight: 600; font-size: 19px; line-height: 1.35; cursor: pointer; list-style: none; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 14px; height: 14px; margin-top: -7px;
  background: linear-gradient(var(--spruce), var(--spruce)) center / 14px 2px no-repeat, linear-gradient(var(--spruce), var(--spruce)) center / 2px 14px no-repeat;
  transition: transform .2s; }
.qa details[open] summary::after { transform: rotate(45deg); }
.qa summary:hover { color: var(--needle); }
.qa details p { padding: 0 48px 24px 0; color: var(--moss); max-width: 40em; }

/* контакты */
.contact { margin-top: 120px; padding: 96px 0 40px; }
.contact h2 { font-size: clamp(36px, 5vw, 68px); max-width: 15ch; }
.contact p { color: #DCE6E1; font-size: 19px; max-width: 34em; }
.mail-box { display: flex; gap: 12px; flex-wrap: wrap; margin: 34px 0 96px; }
.js-mail { overflow-wrap: anywhere; }
.contact .legal { font-size: 14px; color: var(--frost); }
.contact-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 40px clamp(32px, 5vw, 80px); align-items: end; margin-bottom: 96px; }
.contact-grid .mail-box { margin-bottom: 0; }
.send { padding-bottom: 4px; }
.send h3 { margin-bottom: 12px; }
.send li { padding: 12px 0 12px 22px; border-top: 1px solid var(--needle); color: #DCE6E1; position: relative; font-size: 16px; line-height: 1.45; }
.send li::before { content: ""; position: absolute; left: 0; top: 1.15em; width: 8px; height: 8px; border-radius: 50%; background: var(--lamp); }

/* липкая кнопка на телефоне */
.dock { display: none; }

/* просмотр: медиа по своим пропорциям, сверху и снизу поле под × и для тапа по фону */
.lb { --gap-x: 16px; --gap-y: 76px; margin: auto; border: 0; padding: 0; background: transparent; max-width: none; max-height: none; overflow: visible; }
.lb::backdrop { background: rgba(8, 26, 21, .93); }
.lb-body { display: grid; place-items: center; }
.lb-media { display: block; border-radius: 6px; background: #000; object-fit: contain; }
.lb-v { aspect-ratio: 9 / 16; width: auto; height: min(calc(100vh - 2 * var(--gap-y)), calc((100vw - 2 * var(--gap-x)) * 16 / 9)); }
.lb-h { aspect-ratio: 16 / 9; height: auto; width: min(1100px, calc(100vw - 2 * var(--gap-x)), calc((100vh - 2 * var(--gap-y)) * 16 / 9)); }
.lb-img { background: transparent; width: auto; height: auto; max-width: calc(100vw - 2 * var(--gap-x)); max-height: calc(100vh - 2 * var(--gap-y)); }
.lb-close { position: fixed; top: 14px; right: 16px; width: 48px; height: 48px; border: 0; border-radius: 8px; background: var(--snow);
  color: var(--spruce); font: 400 30px/1 var(--font); cursor: pointer; }
@supports (height: 100dvh) {
  .lb-v { height: min(calc(100dvh - 2 * var(--gap-y)), calc((100vw - 2 * var(--gap-x)) * 16 / 9)); }
  .lb-h { width: min(1100px, calc(100vw - 2 * var(--gap-x)), calc((100dvh - 2 * var(--gap-y)) * 16 / 9)); }
  .lb-img { max-height: calc(100dvh - 2 * var(--gap-y)); }
}

@media (max-width: 900px) {
  .bar { flex-wrap: wrap; row-gap: 6px; column-gap: 22px; }
  .bar .name { flex: 1 1 auto; }
  .bar .btn-sm { order: 2; }
  .bar-link { order: 3; padding: 4px 0 6px; font-size: 15px; }
  .bar-link:first-of-type { flex-basis: auto; }
  .bar::after { content: ""; order: 2; flex-basis: 100%; height: 0; }
}
@media (max-width: 1080px) {
  .stage { grid-template-columns: auto 200px; }
  .price-grid { grid-template-columns: 1fr; }
  .terms { margin-top: 0; }
}
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; grid-template-areas: "h" "stage" "copy"; grid-template-rows: auto; padding-top: 18px; }
  .hero h1 { padding-top: 0; }
  .hero h1 { max-width: 14ch; }
  .stage { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 14px; margin-top: 22px; align-items: start; max-width: 620px; }
  .screen { height: auto; min-height: 0; width: 100%; }
  .ny-head, .offer, .faq-grid, .contact-grid { grid-template-columns: 1fr; }
  .ny-head h2 { grid-row: auto; }
  .steps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  h3 { font-size: 21px; }
  .bar { padding: 14px 0; }
  .bar .name { font-size: 16px; }
  .lead { font-size: 17px; }
  .hero-copy { padding-top: 22px; }
  .hero-act { margin-top: 22px; gap: 22px; }
  .promise { margin-top: 22px; }
  .list-h { margin-bottom: 6px; font-size: 13px; }
  .list-note { display: none; }
  .nm { grid-template-columns: 18px 1fr; padding: 8px 6px; }
  .nm-t { font-size: 14px; }
  .nm-end .nm-t { font-size: 13px; }
  .picks { margin-top: 14px; gap: 6px; }
  .pick { min-height: 40px; font-size: 14px; padding: 0 10px; }
  .sound { left: 8px; bottom: 8px; padding: 8px 10px; font-size: 13px; }
  .ny { padding-top: 64px; }
  .offer { padding: 32px 0 40px; }
  .offer-text .sum { font-size: 26px; }
  .reel-row { gap: 8px; }
  .reel-row .cap { font-size: 12px; }
  .mix-row, .wide-row { grid-template-columns: 1fr 1fr; gap: 16px 10px; }
  .mix-row .vid[data-kind="v"] { grid-row: auto; }
  .offer-media .cap { font-size: 13px; }
  .more-row { grid-template-columns: 1fr 1fr; }
  .more-row .vid[data-kind="v"] { grid-row: span 2; }
  .works, .prices, .how, .faq { padding-top: 80px; }
  .tabs { gap: 4px 20px; }
  .tab { font-size: 16px; }
  .grid-v { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 10px; }
  .price tr { display: block; padding: 16px 0; }
  .price th, .price td { display: block; padding: 0; text-align: left; white-space: normal; }
  .price th { font-size: 16px; padding-right: 0; margin-bottom: 4px; }
  .price td { font-size: 24px; }
  .terms { padding: 26px 20px 28px; }
  .steps { grid-template-columns: 1fr; gap: 0; }
  .steps li { display: grid; grid-template-columns: 44px 1fr; border-top-width: 1px; padding: 16px 0 18px; }
  .steps li::before { grid-row: span 2; font-size: 30px; margin: 0; }
  .steps b { margin-bottom: 2px; }
  .qa summary { font-size: 17px; padding-right: 36px; }
  .qa details p { padding-right: 0; }
  .contact { margin-top: 80px; padding-top: 64px; }
  .contact p { font-size: 17px; }
  .mail-box .btn { width: 100%; }
  .contact-grid { margin-bottom: 56px; gap: 40px; }
  .contact { padding-bottom: 96px; }
  .dock { display: flex; position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 10; min-height: 54px; align-items: center; justify-content: center;
    border-radius: 10px; background: var(--lamp); color: var(--spruce); font-weight: 600; font-size: 17px; text-decoration: none;
    box-shadow: 0 0 0 1px rgba(15, 47, 39, .25); transform: translateY(160%); transition: transform .25s; }
  .dock.is-on { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* заявка */
.lead { display: grid; gap: 16px; margin: 34px 0 30px; max-width: 34em; }
.fld { display: grid; gap: 7px; font-size: 15px; color: var(--frost); }
.fld i { font-style: normal; color: var(--moss); margin-left: 6px; }
.fld input, .fld textarea { width: 100%; font: 400 17px/1.45 var(--font); color: var(--snow); background: #0b241e;
  border: 1px solid var(--needle); border-radius: 6px; padding: 13px 14px; resize: vertical; }
.fld input::placeholder, .fld textarea::placeholder { color: #6f8a80; }
.fld input:focus, .fld textarea:focus { outline: 2px solid var(--lamp); outline-offset: 1px; border-color: transparent; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.agree { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--frost); line-height: 1.45; }
.agree input { width: 18px; height: 18px; margin-top: 1px; accent-color: var(--lamp); flex: none; }
.agree a, .contact .legal a { color: inherit; }
.lead .btn { justify-self: start; }
.lead-msg { min-height: 1.5em; font-size: 16px; margin: 0; }
.lead-msg.is-ok { color: var(--lamp); } .lead-msg.is-err { color: #ffb4a8; }
.mail-box .or { color: var(--frost); font-size: 15px; align-self: center; margin-right: 6px; }
@media (max-width: 560px) { .lead .btn { justify-self: stretch; } }

/* страница политики */
.doc-page { background: var(--snow); }
.doc { max-width: 720px; padding: 48px 0 96px; }
.doc h1 { font-size: clamp(32px, 5vw, 52px); margin: 24px 0 8px; }
.doc h2 { font-size: 22px; margin: 34px 0 8px; }
.doc p { font-size: 17px; line-height: 1.6; color: #2b3a35; }
.doc .doc-date { color: var(--moss); font-size: 15px; }

/* шапка портфолио */
.pf-hero { padding: 26px 0 64px; }
.pf-hero h1 { max-width: 16ch; padding-top: 18px; }
.pf-copy { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 24px 56px; align-items: end; margin-top: 26px; }
.pf-copy .hero-act { justify-content: flex-end; }
.show { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 48px; }
.show video { width: 100%; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 10px; background: #0b241e; }
.ny-teaser { padding-top: 72px; padding-bottom: 40px; }
.ny-teaser .offer { border-top: 0; }
.ny-teaser h2 { margin-bottom: 18px; }
.ny-teaser .btn { margin-top: 22px; }
@media (max-width: 900px) {
  .pf-copy { grid-template-columns: 1fr; }
  .pf-copy .hero-act { justify-content: flex-start; }
}
@media (max-width: 560px) {
  .show { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 32px; }
  .show video:nth-child(n+3) { display: none; }
}
