:root {
  --navy: #081831;
  --gold: #edc16c;
  --ink: #18323e;
  --muted: #526276;
  --line: #dce3e3;
  --paper: #f2f5f4;
  color-scheme: light;
  color: var(--ink);
  background: var(--paper);
  font-family: "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
  -webkit-text-size-adjust: 100%;
}

* { box-sizing: border-box; }
body { margin: 0; font-size: 16px; line-height: 1.5; }
button, input { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; text-underline-offset: 4px; }
[hidden] { display: none !important; }
.wrap { width: min(100% - 36px, 560px); margin-inline: auto; }
.header { color: #fff; background: var(--navy); border-bottom: 1px solid #ffffff20; }
.header-inner { min-height: 83px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { min-height: 44px; display: flex; align-items: center; gap: 9px; text-decoration: none; }
.brand-logo { width: 42px; height: 42px; object-fit: contain; mix-blend-mode: lighten; filter: contrast(1.25); }
.brand-name { font-size: 16px; font-weight: 650; letter-spacing: .1em; line-height: 1.3; }
.brand-name small { display: block; margin-top: 5px; color: #bdc9cc; font-size: 9px; letter-spacing: .1em; }
.language { border: 1px solid #ffffff36; border-radius: 4px; padding: 5px 8px; color: #edc16c; font-size: 11px; font-weight: 600; letter-spacing: .06em; }
main { padding-top: 26px; }
.intro { margin-bottom: 22px; }
.intro h1 { max-width: 14ch; margin: 0 0 12px; font-family: Georgia, "Times New Roman", serif; font-size: 34px; font-weight: 400; line-height: 1.1; letter-spacing: -.02em; }
.intro p { max-width: 36ch; margin: 0; color: var(--muted); font-size: 16px; line-height: 1.45; }
.calc-inputs { margin: 0; padding: 20px 18px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.calc-sliders { display: grid; gap: 22px; }
.calc-slider-field > label { display: block; margin-bottom: 10px; font-size: 15px; font-weight: 600; line-height: 1.35; }
.calc-slider-amount { display: flex; align-items: center; gap: 10px; min-height: 58px; padding: 8px 12px; background: #fff; border: 1px solid #bbc8cb; }
.calc-slider-amount:focus-within { outline: 2px solid #977134; outline-offset: 3px; }
.calc-slider-amount input { width: 100%; min-width: 0; min-height: 44px; padding: 0; border: 0; outline: 0; color: var(--navy); background: transparent; font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.4; border-radius: 0; }
.calc-slider-amount input[aria-invalid="true"] { color: #a52828; }
.calc-slider-amount > span { color: var(--muted); white-space: nowrap; font-size: 12px; }
.calc-range { display: block; appearance: none; -webkit-appearance: none; width: 100%; height: 44px; margin: 4px 0 0; padding: 0; cursor: pointer; accent-color: #a77a2d; background: transparent; touch-action: pan-y; }
.calc-range::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(to right, #a77a2d 0%, #a77a2d var(--range-progress), #dce3e3 var(--range-progress), #dce3e3 100%); }
.calc-range::-webkit-slider-thumb { appearance: none; -webkit-appearance: none; width: 26px; height: 26px; margin-top: -10px; border: 3px solid #fff; border-radius: 50%; background: #a77a2d; box-shadow: 0 0 0 1px #a77a2d, 0 2px 7px #08183126; }
.calc-range::-moz-range-track { height: 6px; border-radius: 3px; background: #dce3e3; }
.calc-range::-moz-range-progress { height: 6px; border-radius: 3px; background: #a77a2d; }
.calc-range::-moz-range-thumb { width: 22px; height: 22px; border: 3px solid #fff; border-radius: 50%; background: #a77a2d; box-shadow: 0 0 0 1px #a77a2d; }
.calc-range-scale { display: flex; justify-content: space-between; gap: 12px; color: #5c6d75; font-size: 12px; font-variant-numeric: tabular-nums; }
.input-hint { margin: 20px 0 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 16px; min-height: 58px; padding: 14px 20px; border: 1px solid var(--gold); border-radius: 7px; background: var(--gold); color: #030f27; font-weight: 700; font-size: 18px; line-height: 1.4; transition: background-color .18s; }
.button:hover { background: #f4ce83; border-color: #f4ce83; }
.button:active { background: #e6b456; }
.calc-submit { justify-content: space-between; width: 100%; margin-top: 20px; font-size: 19px; }
.calc-submit > span:last-child { font-size: 25px; font-weight: 400; line-height: 1; }
.amount-error, .noscript-message { margin: 16px 0 0; color: #a52828; font-size: 14px; }
.footer { padding-block: 10px max(20px, env(safe-area-inset-bottom)); text-align: center; }
.footer a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); font-size: 12px; }
:focus-visible { outline: 2px solid #977134; outline-offset: 4px; }
.header :focus-visible { outline-color: var(--gold); }
.skip-link { position: fixed; z-index: 10; top: 8px; left: 8px; padding: 12px 16px; color: var(--navy); background: #fff; transform: translateY(-150%); }
.skip-link:focus { transform: translateY(0); }
.phone-card { padding: 24px 18px 20px; border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); }
.step-back { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; margin: -12px 0 14px -8px; padding: 8px; border: 0; background: transparent; color: var(--muted); font-size: 15px; }
.step-back:hover { color: var(--navy); }
.step-back span { font-size: 22px; line-height: 1; }
.phone-step h2 { margin: 0 0 12px; font-family: Georgia, "Times New Roman", serif; font-size: 29px; font-weight: 400; line-height: 1.15; }
.phone-step h2:focus { outline: 0; }
#phone-description { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.5; }
.amount-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 22px 0; padding: 14px 0; border-block: 1px solid var(--line); }
.amount-summary dt { color: var(--muted); font-size: 11px; line-height: 1.45; }
.amount-summary dd { margin: 5px 0 0; color: var(--navy); font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.form-loading { margin: 28px 0; color: var(--muted); font-size: 15px; }
#bitrix-form-mount { min-width: 0; }
.form-error { margin-top: 20px; padding: 16px; border: 1px solid #e8d7cf; border-radius: 8px; background: #fcf8f5; }
.form-error p { margin: 0; color: #7c3930; font-size: 14px; line-height: 1.5; }
.retry-button { width: 100%; min-height: 48px; margin-top: 16px; font-size: 15px; }
#bitrix-form-mount .b24-form-wrapper { box-shadow: none; border-bottom-color: var(--gold); background: transparent; }
#bitrix-form-mount .b24-form-btn { min-height: 58px; border-radius: 7px; font-family: inherit; font-size: 16px; font-weight: 700; color: #07172e !important; background: var(--gold) !important; }
#bitrix-form-mount .b24-form-control { font-size: 16px !important; }
#bitrix-form-mount .b24-form-content { padding-inline: 0; }
@media (min-width: 761px) {
  .header-inner { min-height: 90px; }
  main { padding-top: 42px; }
  .intro h1 { max-width: none; font-size: 40px; }
  .intro p { max-width: 43ch; }
  .calc-inputs { padding: 28px; }
  .calc-sliders { gap: 28px; }
  .calc-slider-amount { min-height: 64px; }
  .calc-slider-amount input { font-size: 30px; }
}
@media (max-width: 359px) {
  .wrap { width: calc(100% - 28px); }
  .calc-inputs { padding-inline: 14px; }
  .intro h1 { font-size: 32px; }
  .brand-name { font-size: 14px; }
  .phone-card { padding-inline: 14px; }
  .amount-summary { gap: 8px; }
  .amount-summary dd { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
