@font-face { font-family: "Cormorant"; src: url("fonts/cormorant.woff2") format("woff2"); font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Golos"; src: url("fonts/golos.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }

:root {
  --bg: #F7F3EC;
  --surface: #FFFDF9;
  --ink: #2B2621;
  --muted: #6F6457;
  --rule: #E2D8CB;
  --rule-strong: #CDBFAE;
  --accent: #8A5A42;
  --accent-hover: #74492F;
  --accent-soft: #F1E6DC;
  --ok: #4D6B45;
  --err: #9B3B2E;
  --radius: 14px;
  --gutter: 16px;
  --display: "Cormorant", "Cormorant Garamond", Georgia, serif;
  --text: "Golos", "Golos Text", -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
@media (min-width: 720px) { :root { --gutter: 32px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.55 var(--text); overflow-x: clip; }
img, video { display: block; max-width: 100%; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
h1, h2 { font-family: var(--display); font-weight: 600; line-height: 1.05; margin: 0; letter-spacing: -0.005em; }
.card__price, .facts dd, .spec dd.price { font-variant-numeric: lining-nums; }
h2 { font-size: clamp(32px, 4.4vw, 46px); }
p { margin: 0; }
.wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 var(--gutter); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 22px; border-radius: 999px; border: 1px solid transparent; cursor: pointer; text-decoration: none; font-weight: 500; font-size: 15px; transition: background-color .2s, border-color .2s, color .2s; -webkit-tap-highlight-color: transparent; }
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-hover); }
.btn--primary[aria-pressed="true"] { background: var(--surface); color: var(--accent); border-color: var(--accent); }
.btn--ghost { background: transparent; border-color: var(--rule-strong); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--wide { width: 100%; }
.btn:disabled { opacity: .55; cursor: default; }
.iconbtn { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--rule); background: rgba(255, 253, 249, .92); cursor: pointer; padding: 0; }
.iconbtn svg { width: 20px; height: 20px; fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.count[hidden] { display: none; }
.count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 600; }

/* header */
.top { position: sticky; top: 0; z-index: 20; background: rgba(247, 243, 236, .9); backdrop-filter: saturate(1.2) blur(10px); -webkit-backdrop-filter: saturate(1.2) blur(10px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.top.is-scrolled { border-bottom-color: var(--rule); }
.top__in { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 64px; }
.top__logo { display: block; padding: 4px 0; }
.top__logo img { height: 36px; width: auto; }
.top__right { display: flex; align-items: center; gap: 18px; }
.top__phones { display: none; flex-direction: column; align-items: flex-end; }
.top__phones a { text-decoration: none; font-weight: 500; font-size: 14px; line-height: 1.3; white-space: nowrap; padding: 1px 0; }
@media (min-width: 900px) { .top__phones { display: flex; } }
.foot a { display: inline-block; padding: 11px 0; }
.foot a.foot__logolink { display: block; width: max-content; padding: 0; }
.contact { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; margin-top: 28px; }
.contact__title { width: 100%; font-weight: 600; }
.contact .btn { font-variant-numeric: lining-nums; }
@media (min-width: 900px) { .contact__title { width: auto; margin-right: 12px; } }
.top__sel { min-height: 40px; padding: 0 16px; }
@media (min-width: 720px) { .top__in { height: 80px; } .top__logo img { height: 52px; } }

/* hero */
.hero { display: grid; gap: 28px; padding-top: 28px; padding-bottom: 56px; }
.hero__title { font-size: clamp(48px, 9vw, 92px); }
.hero__title span { display: block; color: var(--muted); font-weight: 500; }
.hero__lead { margin-top: 22px; font-size: 17px; max-width: 34em; }
.facts { display: flex; flex-wrap: wrap; gap: 16px 40px; margin: 28px 0 30px; padding: 18px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.facts div { min-width: 0; }
.facts dt { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 2px 0 0; font-family: var(--display); font-size: 28px; font-weight: 600; line-height: 1.1; }
.hero__media { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--rule); aspect-ratio: 3 / 4; max-height: 78vh; }
.hero__media video { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) {
  .hero { grid-template-columns: 1.05fr .95fr; align-items: center; gap: 64px; padding-top: 48px; padding-bottom: 96px; }
  .hero__media { max-height: calc(100vh - 140px); justify-self: end; width: 100%; max-width: 520px; }
}

/* grid */
.models { padding-bottom: 72px; }
.models__head { display: grid; gap: 8px; margin-bottom: 28px; }
@media (min-width: 900px) { .models__head { grid-template-columns: auto 1fr; align-items: end; gap: 32px; } .models__head p { justify-self: end; text-align: right; max-width: 30em; } }
.grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 36px 20px; grid-template-columns: 1fr; }
@media (min-width: 480px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 14px; } }
@media (min-width: 900px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px 28px; } }
.card { display: flex; flex-direction: column; min-width: 0; }
.card__media { position: relative; display: block; width: 100%; aspect-ratio: 3 / 4; border-radius: var(--radius); overflow: hidden; background: var(--rule); border: 0; padding: 0; cursor: pointer; }
.card__media img, .card__media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .45s ease, transform .9s ease; }
.card__media video { opacity: 0; }
.card__media.is-playing video { opacity: 1; }
@media (hover: hover) { .card__media:hover img { transform: scale(1.02); } }
.card__badge { position: absolute; left: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; border-radius: 999px; background: rgba(255, 253, 249, .9); font-size: 12px; font-weight: 500; }
.card__badge svg { width: 12px; height: 12px; fill: var(--ink); }
.card__body { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 14px 2px 0; }
.card__name { font-family: var(--display); font-size: 26px; font-weight: 600; line-height: 1.1; }
.card__meta { grid-column: 1; font-size: 14px; color: var(--muted); }
.card__price { grid-column: 2; grid-row: 1 / span 2; align-self: start; font-family: var(--display); font-size: 26px; font-weight: 600; white-space: nowrap; }
.card__add { margin-top: 14px; }
@media (min-width: 480px) and (max-width: 899px) {
  .card__name, .card__price { font-size: 22px; }
  .card__body { grid-template-columns: 1fr; }
  .card__price { grid-column: 1; grid-row: auto; }
  .card__add { min-height: 42px; padding: 0 14px; font-size: 14px; }
}

/* how */
.how { padding-bottom: 88px; }
.steps { list-style: none; counter-reset: s; margin: 24px 0 0; padding: 0; display: grid; gap: 14px; }
.steps li { counter-increment: s; position: relative; padding: 18px 18px 18px 64px; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius); }
.steps li::before { content: counter(s); position: absolute; left: 18px; top: 14px; font-family: var(--display); font-size: 34px; font-weight: 600; line-height: 1; color: var(--accent); }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 20px; } }

/* footer */
.foot { border-top: 1px solid var(--rule); padding: 32px 0 calc(40px + env(safe-area-inset-bottom)); }
.foot__in { display: grid; gap: 10px; font-size: 14px; }
.foot__logo { height: 34px; width: auto; margin-bottom: 6px; }
body.has-selbar .foot { padding-bottom: calc(110px + env(safe-area-inset-bottom)); }

/* mobile selection bar */
.selbar { position: fixed; z-index: 30; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 8px 8px 20px; border-radius: 999px; background: var(--ink); color: #fff; box-shadow: 0 10px 30px rgba(43, 38, 33, .25); font-weight: 500; }
.selbar[hidden] { display: none; }
.selbar .btn { min-height: 42px; background: #fff; color: var(--ink); }
@media (min-width: 900px) { .selbar { display: none !important; } }

/* dialogs */
dialog { padding: 0; border: 0; color: var(--ink); background: var(--surface); max-width: none; max-height: none; }
dialog::backdrop { background: rgba(30, 26, 22, .55); }
body.is-locked { overflow: hidden; }

.modal { width: 100%; height: 100%; margin: 0; }
.modal__in { position: relative; min-height: 100%; display: grid; grid-template-rows: auto 1fr; }
.modal__close { position: fixed; top: calc(10px + env(safe-area-inset-top)); right: 10px; z-index: 3; }
.viewer { position: relative; background: #EDE6DC; }
.stage { position: relative; aspect-ratio: 3 / 4; max-height: 76vh; width: 100%; margin: 0 auto; overflow: hidden; touch-action: pan-y; }
.stage img, .stage video { width: 100%; height: 100%; object-fit: contain; }
.stage__nav { position: absolute; top: calc(50% - 40px); z-index: 2; }
.stage__nav--prev { left: 10px; } .stage__nav--next { right: 10px; }
.thumbs { display: flex; gap: 8px; padding: 10px 12px 12px; overflow-x: auto; scrollbar-width: none; }
.thumbs::-webkit-scrollbar { display: none; }
.thumb { position: relative; flex: 0 0 auto; width: 56px; aspect-ratio: 3 / 4; padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden; cursor: pointer; background: var(--rule); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb[aria-selected="true"] { border-color: var(--accent); }
.thumb__play { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(30, 26, 22, .25); }
.thumb__play svg { width: 18px; height: 18px; fill: #fff; }
.info { padding: 22px var(--gutter) calc(28px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 18px; }
.info .eyebrow { margin: 0; }
.info__title { font-size: clamp(36px, 5vw, 52px); }
.spec { display: grid; grid-template-columns: auto 1fr; gap: 8px 20px; margin: 0; padding: 16px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.spec dt { color: var(--muted); font-size: 14px; }
.spec dd { margin: 0; font-weight: 500; }
.spec dd.price { font-family: var(--display); font-size: 30px; font-weight: 600; line-height: 1; }.tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { padding: 5px 12px; border-radius: 999px; background: var(--accent-soft); font-size: 13px; }
.info__desc { max-width: 36em; }
.info__nav { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: auto; }
.info__nav .btn { padding: 0 12px; font-size: 14px; }
@media (min-width: 900px) {
  .modal { width: min(1180px, calc(100% - 64px)); height: min(860px, calc(100% - 64px)); margin: auto; border-radius: 18px; overflow: hidden; }
  .modal__in { grid-template-rows: none; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); height: 100%; min-height: 0; }
  .modal__close { position: absolute; top: 14px; right: 14px; }
  .viewer { display: flex; flex-direction: column; min-height: 0; }
  .stage { flex: 1; aspect-ratio: auto; max-height: none; min-height: 0; }
  .info { overflow-y: auto; padding: 56px 40px 32px; }
}
/* Телефон, повёрнутый горизонтально: кадр слева на всю высоту, описание справа */
@media (max-width: 899px) and (min-width: 560px) and (max-height: 560px) and (orientation: landscape) {
  .modal__in { grid-template-rows: none; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); height: 100%; min-height: 0; }
  .viewer { display: flex; flex-direction: column; min-height: 0; }
  .stage { flex: 1; aspect-ratio: auto; max-height: none; min-height: 0; }
  .thumbs { padding: 6px 10px calc(8px + env(safe-area-inset-bottom)); }
  .thumb { width: 40px; }
  .info { overflow-y: auto; padding: 20px calc(16px + env(safe-area-inset-right)) 20px 20px; gap: 14px; }
  .info__title { font-size: 34px; }
  .modal__close { position: absolute; }
}
.modal, .drawer { height: 100%; height: 100dvh; }
@media (min-width: 900px) { .modal { height: min(860px, calc(100dvh - 64px)); } }

.drawer { width: 100%; height: 100%; margin: 0; }
.drawer__in { display: flex; flex-direction: column; height: 100%; }
.drawer__head { display: flex; align-items: center; justify-content: space-between; padding: calc(14px + env(safe-area-inset-top)) var(--gutter) 14px; border-bottom: 1px solid var(--rule); }
.drawer__head h2 { font-size: 34px; }
.drawer__body { flex: 1; overflow-y: auto; padding: 18px var(--gutter); }
.drawer__foot { display: grid; gap: 10px; padding: 14px var(--gutter) calc(14px + env(safe-area-inset-bottom)); border-top: 1px solid var(--rule); background: var(--surface); }
@media (min-width: 720px) {
  .drawer { width: 460px; margin: 0 0 0 auto; height: 100%; }
  .drawer__head, .drawer__body, .drawer__foot { padding-left: 28px; padding-right: 28px; }
}
.empty { padding: 8px 0 18px; }
.sel { list-style: none; margin: 0 0 22px; padding: 0; display: grid; gap: 12px; }
.sel li { display: grid; grid-template-columns: 64px 1fr auto; gap: 4px 12px; align-items: start; padding: 10px; border: 1px solid var(--rule); border-radius: 12px; background: var(--bg); }
.sel img { width: 64px; height: 85px; object-fit: cover; border-radius: 8px; grid-row: span 2; }
.sel__name { font-family: var(--display); font-size: 21px; font-weight: 600; line-height: 1.15; }
.sel__meta { font-size: 13px; color: var(--muted); }
.sel li > div:nth-child(2) { min-width: 0; }
.sel__qty { grid-column: 2 / span 2; display: flex; gap: 8px; align-items: center; margin-top: 4px; min-width: 0; }
.sel__qty input { flex: 1 1 0; min-width: 0; max-width: 150px; min-height: 44px; padding: 0 10px; border: 1px solid var(--rule-strong); border-radius: 10px; background: var(--surface); }
.sel__qty select { flex: 0 0 auto; min-height: 44px; padding: 0 8px; border: 1px solid var(--rule-strong); border-radius: 10px; background: var(--surface); }
.sel__rm { width: 44px; height: 44px; }
.fields { border: 0; margin: 0; padding: 0; display: grid; gap: 12px; }
.fields legend { font-weight: 600; margin-bottom: 10px; padding: 0; }
.fields label { display: grid; gap: 6px; font-size: 14px; }
.fields input, .fields textarea { width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid var(--rule-strong); border-radius: 10px; background: var(--surface); font-size: 16px; }
.fields textarea { resize: vertical; }
.fields .is-invalid { border-color: var(--err); }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.status { font-size: 14px; line-height: 1.45; }
.status:empty { display: none; }
.status.ok { color: var(--ok); }
.status.err { color: var(--err); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
