/* ==========================================================================
   Грузоперевозки 53 — base, header, hero
   ========================================================================== */

:root {
  --paper: #f7f2ea;
  --paper-2: #eee5d8;
  --paper-3: #e4d8c8;
  --ink: #1c1517;
  --ink-2: #2a2022;
  --wine: #5e1721;
  --wine-deep: #3a0d14;
  --red: #c1122f;
  --rose: #d9a3a9;
  --gold: #c9a46a;
  --muted: #6b5c5e;
  --line: rgba(28, 21, 23, 0.14);
  --line-light: rgba(247, 242, 234, 0.16);
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Manrope", "Segoe UI", Arial, sans-serif;
  --max: 1360px;
  --gutter: clamp(20px, 4.4vw, 64px);
  --ease: cubic-bezier(0.22, 0.7, 0.22, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.menu-open {
  overflow: hidden;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

input,
output {
  font: inherit;
}

h1,
h2,
h3,
p {
  margin: 0;
}

::selection {
  background: var(--wine);
  color: var(--paper);
}

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

.container {
  width: min(100% - (var(--gutter) * 2), var(--max));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  z-index: 500;
  background: var(--ink);
  color: var(--paper);
  padding: 12px 18px;
  font-size: 12px;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 16px;
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 400;
  pointer-events: none;
  opacity: 0.035;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

.scroll-progress {
  position: fixed;
  inset: 0 0 auto;
  height: 2px;
  z-index: 450;
  pointer-events: none;
}

.scroll-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--red);
  transition: width 0.1s linear;
}

/* ---------- Typography ---------- */

.h2 {
  font-family: var(--serif);
  font-size: clamp(38px, 5.2vw, 74px);
  font-weight: 500;
  line-height: 0.98;
  letter-spacing: -0.028em;
  max-width: 16ch;
}

.h2 em {
  font-style: italic;
  color: var(--wine);
  font-weight: 500;
}

.kicker {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 24px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.kicker span {
  color: var(--wine);
}

.kicker::after {
  content: "";
  width: 38px;
  height: 1px;
  background: currentColor;
  opacity: 0.35;
}

.section-lead {
  max-width: 54ch;
  margin-top: 24px;
  font-size: clamp(14px, 1.25vw, 17px);
  line-height: 1.65;
  color: var(--muted);
}

/* ---------- Buttons ---------- */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 56px;
  padding: 0 28px;
  border: 1px solid transparent;
  border-radius: 2px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
  white-space: nowrap;
  transition: background 0.3s var(--ease), color 0.3s var(--ease),
    border-color 0.3s var(--ease), transform 0.3s var(--ease);
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.3s var(--ease);
}

.btn:hover svg {
  transform: translateX(4px);
}

.btn--red {
  background: var(--red);
  color: #fff;
}

.btn--red:hover {
  background: #a80f28;
}

.btn--ghost {
  border-color: rgba(247, 242, 234, 0.26);
  background: rgba(247, 242, 234, 0.04);
  color: var(--paper);
  backdrop-filter: blur(10px);
}

.btn--ghost:hover {
  background: rgba(247, 242, 234, 0.1);
  border-color: rgba(247, 242, 234, 0.48);
}

.btn--full {
  width: 100%;
}

.btn--small {
  min-height: 46px;
  padding: 0 20px;
  font-size: 11px;
}

/* ---------- Header ---------- */

.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  padding: 20px 0;
  color: var(--paper);
  transition: background 0.4s var(--ease), color 0.4s var(--ease),
    padding 0.4s var(--ease), border-color 0.4s var(--ease);
  border-bottom: 1px solid transparent;
}

.header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(13, 8, 9, 0.58), transparent);
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.header.is-scrolled {
  padding: 11px 0;
  background: rgba(247, 242, 234, 0.92);
  backdrop-filter: blur(18px);
  border-bottom-color: var(--line);
  color: var(--ink);
}

.header.is-scrolled::before {
  opacity: 0;
}

.header__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none;
}

.logo__mark {
  position: relative;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  background: var(--wine);
  color: var(--paper);
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 600;
  line-height: 1;
  border-radius: 1px;
}

.logo__mark::after {
  content: "";
  position: absolute;
  left: 7px;
  right: 7px;
  bottom: 5px;
  height: 1px;
  background: rgba(247, 242, 234, 0.35);
}

.logo__text {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.logo__text strong {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.025em;
}

.logo__text small {
  margin-top: 5px;
  font-size: 8px;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  opacity: 0.5;
}

.nav {
  display: flex;
  align-items: center;
  gap: clamp(12px, 1.55vw, 25px);
  margin-left: auto;
}

.nav a {
  position: relative;
  padding: 6px 0;
  font-size: 11px;
  letter-spacing: 0.045em;
  white-space: nowrap;
  opacity: 0.72;
  transition: opacity 0.25s ease;
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 1px;
  width: 0;
  height: 1px;
  background: currentColor;
  transition: width 0.3s var(--ease);
}

.nav a:hover {
  opacity: 1;
}

.nav a:hover::after {
  width: 100%;
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: none;
}

.header__phone {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding-left: 22px;
  border-left: 1px solid rgba(247, 242, 234, 0.18);
  line-height: 1;
  transition: border-color 0.4s ease;
}

.header.is-scrolled .header__phone {
  border-left-color: var(--line);
}

.header__phone-label {
  margin-bottom: 6px;
  font-size: 7px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.48;
}

.header__phone-number {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.015em;
  white-space: nowrap;
}

.burger {
  display: none;
  position: relative;
  width: 44px;
  height: 44px;
  margin-right: -10px;
}

.burger span {
  position: absolute;
  left: 11px;
  right: 11px;
  height: 1.5px;
  background: currentColor;
  transition: transform 0.35s var(--ease), top 0.35s var(--ease);
}

.burger span:first-child {
  top: 18px;
}

.burger span:last-child {
  top: 26px;
}

.burger[aria-expanded="true"] span:first-child {
  top: 22px;
  transform: rotate(45deg);
}

.burger[aria-expanded="true"] span:last-child {
  top: 22px;
  transform: rotate(-45deg);
}

/* ---------- Mobile menu ---------- */

.menu {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  visibility: hidden;
  transform: translateY(-100%);
  transition: transform 0.65s var(--ease), visibility 0.65s;
}

.menu.is-open {
  visibility: visible;
  transform: none;
}

.menu__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.menu__close {
  position: relative;
  width: 44px;
  height: 44px;
  margin-right: -10px;
}

.menu__close span {
  position: absolute;
  top: 50%;
  left: 10px;
  right: 10px;
  height: 1.5px;
  background: var(--ink);
}

.menu__close span:first-child {
  transform: rotate(45deg);
}

.menu__close span:last-child {
  transform: rotate(-45deg);
}

.menu__nav {
  display: flex;
  flex-direction: column;
  padding-top: clamp(20px, 4vh, 48px);
  overflow-y: auto;
}

.menu__nav a {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: clamp(34px, 7vw, 56px);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.02em;
  transition: color 0.25s ease, padding-left 0.25s ease;
}

.menu__nav a span {
  font-family: var(--sans);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--wine);
}

.menu__nav a:hover {
  color: var(--wine);
  padding-left: 8px;
}

.menu__bottom {
  margin-top: auto;
  padding-top: 24px;
  padding-bottom: calc(24px + env(safe-area-inset-bottom));
}

.menu__phones {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-family: var(--serif);
  font-size: clamp(22px, 4vw, 30px);
  line-height: 1.2;
}

.menu__bottom p {
  margin-top: 16px;
  font-size: 10px;
  color: var(--muted);
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100svh;
  padding-top: 140px;
  background: #0d0809;
  color: var(--paper);
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 74% 32%, rgba(94, 23, 33, 0.38), transparent 62%);
}

.hero__glow {
  position: absolute;
  top: -24vw;
  right: -18vw;
  width: 76vw;
  height: 76vw;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(193, 18, 47, 0.2), transparent 62%);
  filter: blur(24px);
}

.hero__map {
  position: absolute;
  top: 50%;
  right: -4vw;
  width: min(760px, 58vw);
  opacity: 0.9;
  transform: translateY(-50%);
  animation: mapFloat 16s ease-in-out infinite alternate;
}

.hero__road {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 36%;
  background: linear-gradient(to top, rgba(193, 18, 47, 0.16), transparent 68%);
  pointer-events: none;
}

.hero__road::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -18%;
  width: 1px;
  height: 86%;
  background: linear-gradient(to top, rgba(247, 242, 234, 0.32), transparent);
  transform: translateX(-50%) rotate(16deg);
  transform-origin: bottom;
  opacity: 0.5;
}

.hero__road::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(247, 242, 234, 0.2), transparent);
}

.hero__fog {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}

.hero__fog--1 {
  left: -12vw;
  bottom: 8%;
  width: 42vw;
  height: 20vw;
  background: var(--wine);
  opacity: 0.2;
  animation: fogMove 18s ease-in-out infinite alternate;
}

.hero__fog--2 {
  right: 8%;
  top: 18%;
  width: 28vw;
  height: 14vw;
  background: var(--red);
  opacity: 0.09;
  animation: fogMove 22s ease-in-out infinite alternate-reverse;
}

.hero__shade {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(13, 8, 9, 0.95) 0%, rgba(13, 8, 9, 0.79) 38%, rgba(13, 8, 9, 0.22) 68%, rgba(13, 8, 9, 0.5) 100%),
    linear-gradient(0deg, #0d0809 0%, transparent 32%, transparent 80%, rgba(13, 8, 9, 0.35) 100%);
}

.hero__inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex: 1;
  align-items: flex-end;
  justify-content: space-between;
  gap: 48px;
  padding-bottom: clamp(36px, 6vh, 76px);
}

.hero__copy {
  max-width: 780px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 26px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(247, 242, 234, 0.58);
}

.eyebrow::before {
  content: "";
  width: 36px;
  height: 1px;
  background: var(--red);
}

.eyebrow span {
  color: var(--red);
}

.hero__title {
  font-family: var(--serif);
  font-size: clamp(46px, 7.1vw, 104px);
  font-weight: 500;
  line-height: 0.91;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.hero__title em {
  font-style: italic;
  color: var(--rose);
  font-weight: 500;
}

.hero__lead {
  max-width: 520px;
  margin-top: 28px;
  font-size: clamp(14px, 1.25vw, 17px);
  line-height: 1.65;
  color: rgba(247, 242, 234, 0.62);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.hero__phone-card {
  position: relative;
  flex: none;
  width: 340px;
  margin-bottom: 6px;
  padding: 28px;
  border: 1px solid rgba(247, 242, 234, 0.22);
  border-radius: 2px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
}

.hero__phone-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 56px;
  height: 2px;
  background: var(--red);
}

.hero__phone-eyebrow {
  margin-bottom: 18px;
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.phone-lockup {
  display: block;
}

.phone-lockup__number {
  display: flex;
  align-items: center;
  font-family: var(--serif);
  font-size: clamp(23px, 2vw, 30px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.phone-lockup__circle {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 1.35em;
  height: 1.35em;
  margin: 0 0.05em;
  border: 1.5px solid var(--red);
  border-radius: 50%;
  font-size: 0.82em;
  line-height: 1;
}

.phone-lockup__note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  font-family: var(--sans);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(247, 242, 234, 0.48);
}

.phone-lockup__note i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #7bd88f;
  box-shadow: 0 0 0 4px rgba(123, 216, 143, 0.1);
  animation: pulseDot 2.6s ease-out infinite;
}

.hero__phone-card .phone-lockup__number {
  color: var(--wine);
}

.hero__phone-card .phone-lockup__circle {
  color: var(--red);
}

.hero__phone-card .phone-lockup__note {
  color: var(--muted);
}

.hero__phone-extra {
  display: flex;
  gap: 16px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.hero__phone-extra a {
  font-size: 11px;
  letter-spacing: 0.02em;
  color: var(--muted);
  transition: color 0.25s ease;
}

.hero__phone-extra a:hover {
  color: var(--wine);
}

.hero__stats {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 22px 0 26px;
  border-top: 1px solid rgba(247, 242, 234, 0.14);
}

.hero-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-left: 24px;
  border-left: 1px solid rgba(247, 242, 234, 0.1);
}

.hero-stat:first-child {
  padding-left: 0;
  border-left: 0;
}

.hero-stat__value {
  font-family: var(--serif);
  font-size: clamp(20px, 1.8vw, 26px);
  line-height: 1;
}

.hero-stat__label {
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(247, 242, 234, 0.42);
}

/* ---------- Section base ---------- */

.section {
  position: relative;
  padding: clamp(72px, 9vw, 132px) 0;
}

section[id],
main[id] {
  scroll-margin-top: 84px;
}

@media (max-width: 760px) {
  section[id],
  main[id] {
    scroll-margin-top: 70px;
  }
}

.section-head {
  margin-bottom: clamp(40px, 5vw, 72px);
}

.section-head--split {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: end;
}

.section-head--split .section-lead {
  justify-self: end;
  max-width: 40ch;
  margin-bottom: 6px;
}

.section-head--light .kicker {
  color: rgba(247, 242, 234, 0.45);
}

.section-head--light .kicker span {
  color: var(--rose);
}

.section-head--light .h2 em {
  color: var(--rose);
}

.section-head--light .section-lead {
  color: rgba(247, 242, 234, 0.55);
}
