/* ==========================================================================
   Nova Partner v3 - base: fonts, tokens, reset, container, typography, buttons
   Source: Figma "Nova Partner" (MRiZBn4vJwZppF6Z36lsKY), Style Guide 11198:5099,
   variables of 1440_Drivers Page 10147:5640, Components (Button / Main 10583:8304,
   Button / Card 10589:9200, Button 12113:27810).
   Breakpoints used across v3: 1280, 1024, 768, 480.
   ========================================================================== */

@font-face {
  font-family: "Manrope";
  src: url("../../fonts/Manrope-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Manrope";
  src: url("../../fonts/Manrope-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Manrope";
  src: url("../../fonts/Manrope-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Manrope";
  src: url("../../fonts/Manrope-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* ---- colors (Figma paint styles) ---- */
  --v3-primary: #31b4b4;            /* Brand/Primary */
  --v3-primary-10: #eaf7f7;         /* Brand/Primary10% */
  --v3-primary-light: #cbecec;      /* Brand/Primary light */
  --v3-dark: #0a0a0a;               /* Neutral/Dark, Dark BG */
  --v3-white: #ffffff;              /* Neutral/Light */
  --v3-white-10: rgba(255, 255, 255, 0.1);   /* Neutral/Light10% */
  --v3-white-15: rgba(255, 255, 255, 0.15);  /* Neutral/Light15% */
  --v3-white-80: rgba(255, 255, 255, 0.8);   /* Neutral/Light80% */
  --v3-bg-light: #f5f7f7;           /* Light BG, Neutral/Grey */
  --v3-bg-gray: #f2f2f2;            /* Gray BG */
  --v3-gray-50: #d3d3d3;
  --v3-gray-100: #979797;
  --v3-gray-200: #535353;
  --v3-gray-300: #343434;
  --v3-gray-400: #212223;
  --v3-gray-500: #19191a;
  --v3-track: #d8f4f2;              /* Status/Neutral Track */
  --v3-error: #db2546;              /* Status/Error */
  --v3-warning: #e38d02;            /* Status/Warning */
  --v3-warning-20: rgba(250, 204, 21, 0.2);  /* Status/Warning20% */
  --v3-warning-50: rgba(255, 248, 230, 0.5); /* Status/Warning50% */
  --v3-icon-green: #00c27e;
  --v3-icon-red: #fd2530;
  --v3-icon-yellow: #ffda44;
  --v3-icon-blue: #338af3;
  --v3-icon-gray: #f0f0f0;
  --v3-icon-scarlet: #d6222b;
  --v3-telegram: #0099da;
  --v3-map-gray: #ededed;
  --v3-map-white-40: rgba(255, 255, 255, 0.4);
  --v3-gradient-medicover: linear-gradient(90deg, #2fa1dc 0%, #abe354 100%);
  --v3-gradient-map: linear-gradient(180deg, #4aefee 0%, #15c0bf 76%);
  --v3-gradient-overlay-dark: linear-gradient(180deg, #050505 0%, rgba(5, 5, 5, 0) 100%);

  /* ---- radii (Figma variables radius/sm|md|lg) ---- */
  --v3-radius-sm: 8px;
  --v3-radius-md: 10px;
  --v3-radius-lg: 16px;

  /* ---- shadows: only the button hover glow exists in the design ---- */
  --v3-shadow-glow: 0 6px 12px -6px #2ee7d1;
  --v3-shadow-glow-soft: 0 3px 12px -6px rgba(46, 231, 209, 0.5);
  --v3-shadow-glow-card: 0 3px 12px -6px #2ee7d1;

  /* ---- spacing scale (no Figma variables: values measured in the frames) ---- */
  --v3-space-1: 4px;
  --v3-space-2: 8px;
  --v3-space-3: 12px;
  --v3-space-4: 16px;
  --v3-space-5: 20px;
  --v3-space-6: 24px;
  --v3-space-8: 32px;
  --v3-space-10: 40px;
  --v3-space-12: 48px;
  --v3-space-16: 64px;
  --v3-space-24: 96px;

  /* ---- layout: 1440 frame = 62px gutters (1316 content); 430 frame = 20px gutters ---- */
  --v3-container-max: 1440px;
  --v3-gutter: 62px;
  --v3-frame-line: calc(var(--v3-gutter) - 12px);   /* x of the outer dashed guide lines (header + heroes), from the container edge */
  --v3-section-pad: 96px;           /* section header sits 96px below section top on desktop, 48px on mobile */

  /* ---- typography (Desktop/* and Mobile/* text styles) ---- */
  --v3-font: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --v3-fs-h1: clamp(32px, 22.4px + 2vw, 48px);        /* 48 desktop / 32 mobile */
  --v3-fs-h2: clamp(28px, 18.4px + 2vw, 44px);        /* 44 / 28 */
  --v3-fs-cta: clamp(24px, 19.2px + 1vw, 32px);       /* CTA Title 32 / 24 */
  --v3-fs-h3: clamp(20px, 17.6px + 0.5vw, 24px);      /* H3 Bold 24 / 20 */
  --v3-fs-h3-md: 20px;                                /* H3 Medium 20 / 20 */
  --v3-fs-price-lg: 48px;
  --v3-fs-price-sm: 32px;
  --v3-fs-body-l: 20px;
  --v3-fs-body-m: 16px;
  --v3-fs-body-s: 14px;
  --v3-fs-caption: 12px;
  --v3-lh-h1: 1.2;
  --v3-lh-h2: 1.2;                                    /* 1.16 on desktop, see @media below */
  --v3-lh-body-m: 1.4;
  --v3-lh-body-s: 1.2;                                /* 1.3 desktop, 1.2 mobile */
  --v3-lh-tight: 1.3;
  --v3-ls-display: -0.02em;                           /* H1/H2/Price Large letter spacing -2% */
}

@media (min-width: 769px) {
  :root {
    --v3-lh-h2: 1.16;
    --v3-lh-body-s: 1.3;
  }
}
@media (max-width: 1280px) {
  :root { --v3-gutter: 40px; }
}
@media (max-width: 1024px) {
  :root { --v3-section-pad: 72px; --v3-frame-line: calc(var(--v3-gutter) - 4px); }
}
@media (max-width: 768px) {
  :root { --v3-gutter: 24px; --v3-section-pad: 48px; }
}
@media (max-width: 480px) {
  :root { --v3-gutter: 20px; }
}

/* ---- modern minimal reset (scoped to the v3 body) ---- */
:where(body.v3),
:where(body.v3) *,
:where(body.v3) *::before,
:where(body.v3) *::after {
  box-sizing: border-box;
}
body.v3 {
  margin: 0;
  background: var(--v3-white);
  color: var(--v3-dark);
  font-family: var(--v3-font);
  font-size: var(--v3-fs-body-m);
  font-weight: 400;
  line-height: var(--v3-lh-body-m);
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
:where(body.v3) :where(h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd, ul, ol) { margin: 0; }
:where(body.v3) :where(ul, ol)[class] { padding: 0; list-style: none; }
:where(body.v3) :where(img, picture, video, canvas, svg) { display: block; max-width: 100%; }
:where(body.v3) :where(img, video) { height: auto; }
:where(body.v3) :where(button, input, select, textarea) { font: inherit; color: inherit; }
:where(body.v3) :where(button) { cursor: pointer; background: none; border: 0; padding: 0; }
:where(body.v3) :where(a) { color: inherit; text-decoration: none; }
:where(body.v3) :where(table) { border-collapse: collapse; }

:where(body.v3) :focus-visible {
  outline: 2px solid var(--v3-primary);
  outline-offset: 2px;
}

.v3-visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.v3-skip-link {
  position: absolute;
  left: var(--v3-space-4);
  top: -100px;
  z-index: 1000;
  padding: var(--v3-space-3) var(--v3-space-5);
  border-radius: var(--v3-radius-sm);
  background: var(--v3-dark);
  color: var(--v3-white);
  font-weight: 600;
}
.v3-skip-link:focus { top: var(--v3-space-4); }

/* ---- layout ---- */
.v3-container {
  width: 100%;
  max-width: var(--v3-container-max);
  margin-inline: auto;
  padding-inline: var(--v3-gutter);
}
.v3-section {
  position: relative;
  padding-block: var(--v3-section-pad);
}

/* ---- typography classes ---- */
.v3-h1 { font-size: var(--v3-fs-h1); font-weight: 700; line-height: var(--v3-lh-h1); letter-spacing: var(--v3-ls-display); }
.v3-h2 { font-size: var(--v3-fs-h2); font-weight: 700; line-height: var(--v3-lh-h2); letter-spacing: var(--v3-ls-display); }
.v3-cta-title { font-size: var(--v3-fs-cta); font-weight: 500; line-height: var(--v3-lh-tight); }
.v3-h3 { font-size: var(--v3-fs-h3); font-weight: 700; line-height: var(--v3-lh-tight); }
.v3-h3--medium { font-size: var(--v3-fs-h3-md); font-weight: 500; line-height: 0.79; }
.v3-price-lg { font-size: var(--v3-fs-price-lg); font-weight: 700; line-height: 1.2; letter-spacing: var(--v3-ls-display); }
.v3-price-sm { font-size: var(--v3-fs-price-sm); font-weight: 700; line-height: var(--v3-lh-tight); }
.v3-body-l { font-size: var(--v3-fs-body-l); font-weight: 500; line-height: var(--v3-lh-tight); }
.v3-body-m { font-size: var(--v3-fs-body-m); font-weight: 400; line-height: var(--v3-lh-body-m); }
.v3-body-s { font-size: var(--v3-fs-body-s); font-weight: 400; line-height: var(--v3-lh-body-s); }
.v3-caption { font-size: var(--v3-fs-caption); font-weight: 400; line-height: var(--v3-lh-tight); }
/* weight modifiers (Regular 400, Medium 500, SemiBold 600, Bold 700); place after the size class */
.v3-fw-regular { font-weight: 400; }
.v3-fw-medium { font-weight: 500; }
.v3-fw-semibold { font-weight: 600; }
.v3-fw-bold { font-weight: 700; }

@media (max-width: 768px) {
  .v3-h2 { letter-spacing: 0; }   /* Mobile/H2 has letter spacing 0 */
}

/* ---- buttons ----
   .v3-btn                       Button / Main, Contained, Surface=Light (dark button on a light surface)
   .v3-btn--on-dark              Surface=Dark (white button on a dark surface)
   .v3-btn--outline              Variant=Outlined (combine with --on-dark for the white outline)
   .v3-btn--card                 Button / Card (compact teal-outlined button on dark cards)
   .v3-btn--link                 "Button" text link with arrow (put an inline arrow svg as the 2nd child)
   Disabled: [disabled], [aria-disabled="true"] or .is-disabled. Works on <button> and <a>. */
.v3-btn {
  --btn-bg: var(--v3-dark);
  --btn-color: var(--v3-white);
  --btn-border: transparent;
  --btn-hover-bg: var(--v3-primary);
  --btn-hover-color: var(--v3-white);
  --btn-hover-border: transparent;
  --btn-hover-shadow: var(--v3-shadow-glow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--v3-space-3);
  min-height: 52px;
  padding: 0 30px;
  border: 1px solid var(--btn-border);
  border-radius: var(--v3-radius-md);
  background: var(--btn-bg);
  color: var(--btn-color);
  font-family: var(--v3-font);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.375;
  text-align: center;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.v3-btn:hover {
  background: var(--btn-hover-bg);
  color: var(--btn-hover-color);
  border-color: var(--btn-hover-border);
  box-shadow: var(--btn-hover-shadow);
}
.v3-btn:active {
  background: var(--btn-hover-bg);
  color: var(--btn-hover-color);
  border-color: var(--btn-hover-border);
  box-shadow: none;
}
.v3-btn:focus-visible { outline: 2px solid var(--v3-primary); outline-offset: 3px; }

.v3-btn--on-dark {
  --btn-bg: var(--v3-white);
  --btn-color: var(--v3-dark);
  --btn-hover-color: var(--v3-dark);
}
.v3-btn--outline {
  --btn-bg: transparent;
  --btn-color: var(--v3-dark);
  --btn-border: var(--v3-dark);
  --btn-hover-bg: transparent;
  --btn-hover-color: var(--v3-primary);
  --btn-hover-border: var(--v3-primary);
  --btn-hover-shadow: var(--v3-shadow-glow-soft);
}
.v3-btn--outline.v3-btn--on-dark {
  --btn-bg: transparent;
  --btn-color: var(--v3-white);
  --btn-border: var(--v3-white);
  --btn-hover-color: var(--v3-primary);
}

.v3-btn--card {
  --btn-bg: var(--v3-gray-400);
  --btn-color: var(--v3-primary);
  --btn-border: var(--v3-primary);
  --btn-hover-bg: var(--v3-primary);
  --btn-hover-color: var(--v3-dark);
  --btn-hover-border: var(--v3-primary);
  --btn-hover-shadow: var(--v3-shadow-glow-card);
  min-height: 42px;
  padding: 0 20px;
  border-radius: var(--v3-radius-sm);
  font-size: 14px;
  line-height: 1.3;
}

.v3-btn--link {
  --btn-bg: transparent;
  --btn-color: var(--v3-dark);
  --btn-hover-bg: transparent;
  --btn-hover-color: var(--v3-primary);
  min-height: 0;
  padding: 0;
  gap: var(--v3-space-4);
  border: 0;
  border-radius: 0;
}
.v3-btn--link:hover,
.v3-btn--link:active { box-shadow: none; }

.v3-btn:disabled,
.v3-btn[aria-disabled="true"],
.v3-btn.is-disabled {
  --btn-bg: var(--v3-gray-50);
  --btn-color: var(--v3-gray-100);
  --btn-border: transparent;
  --btn-hover-bg: var(--v3-gray-50);
  --btn-hover-color: var(--v3-gray-100);
  --btn-hover-border: transparent;
  --btn-hover-shadow: none;
  cursor: not-allowed;
  pointer-events: none;
}
.v3-btn--outline:disabled,
.v3-btn--outline[aria-disabled="true"],
.v3-btn--outline.is-disabled {
  --btn-bg: transparent;
  --btn-border: var(--v3-gray-50);
  --btn-hover-bg: transparent;
  --btn-hover-border: var(--v3-gray-50);
}
.v3-btn--card:disabled,
.v3-btn--card[aria-disabled="true"],
.v3-btn--card.is-disabled {
  --btn-bg: var(--v3-gray-300);
  --btn-color: var(--v3-gray-400);
  --btn-border: var(--v3-gray-300);
  --btn-hover-bg: var(--v3-gray-300);
  --btn-hover-color: var(--v3-gray-400);
  --btn-hover-border: var(--v3-gray-300);
}
.v3-btn--link:disabled,
.v3-btn--link[aria-disabled="true"],
.v3-btn--link.is-disabled {
  --btn-bg: transparent;
  --btn-color: var(--v3-gray-100);
  --btn-hover-bg: transparent;
}

/* ---- reveal on scroll (js/v3/base.js adds .is-visible once) ---- */
@media (scripting: enabled) {
  [data-v3-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }
  [data-v3-reveal].is-visible {
    opacity: 1;
    transform: none;
  }
}

/* ---- reduced motion ----
   Note: infinite animations (marquees etc.) must additionally set `animation: none` in their own
   reduced-motion rule, because this guard only shortens them. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  [data-v3-reveal] {
    opacity: 1;
    transform: none;
  }
}

/* Bitrix24 inline form (rendered by their loader) re-skinned to the Figma "Forms Dark": 2 columns, dark fields, white button.
   Used by the calculator and the fleet CTA; one column on phones (Figma mobile). */
.v3-b24-dark .b24-form-wrapper { background: transparent !important; box-shadow: none !important; border: 0 !important; padding: 0 !important; max-width: none !important; }
.v3-b24-dark .b24-form-header-padding { display: none !important; }
.v3-b24-dark .b24-form-content { padding: 0 !important; }
.v3-b24-dark form > div:first-child { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.v3-b24-dark .b24-form-field { margin: 0 !important; padding: 0 !important; }
.v3-b24-dark .b24-form-field-list { order: 4; }
.v3-b24-dark .b24-form-field-bool { order: 5; grid-column: 1 / -1; }
.v3-b24-dark .b24-form-control-container { margin: 0 !important; }
.v3-b24-dark .b24-form-control { height: 52px !important; padding: 15px 20px 0 !important; border: 1px solid var(--v3-gray-400) !important; border-radius: var(--v3-radius-md) !important; background: var(--v3-gray-500) !important; color: var(--v3-white) !important; font: 500 16px/1.4 var(--v3-font) !important; box-shadow: none !important; }
.v3-b24-dark .b24-form-control:focus { border-color: var(--v3-primary) !important; }
.v3-b24-dark .b24-form-control-label { color: var(--v3-gray-100) !important; font: 400 12px/1.3 var(--v3-font) !important; }
.v3-b24-dark .b24-form-control-desc,
.v3-b24-dark .b24-form-field-bool label { color: var(--v3-gray-100) !important; font: 400 12px/1.3 var(--v3-font) !important; }
.v3-section .v3-b24-dark .b24-form a.b24-form-sign-abuse-link { color: var(--v3-gray-100) !important; }   /* Bitrix's own link, kept but readable on the dark panel */
.v3-b24-dark .b24-form-btn-container { margin-top: 12px; padding: 0 !important; }
.v3-b24-dark .b24-form-btn { width: 100% !important; height: 52px !important; border: 0 !important; border-radius: var(--v3-radius-md) !important; background: var(--v3-white) !important; color: var(--v3-dark) !important; font: 600 16px/1.4 var(--v3-font) !important; text-transform: none !important; transition: background-color 0.2s ease, color 0.2s ease; }
.v3-b24-dark .b24-form-btn:hover { background: var(--v3-primary) !important; color: var(--v3-white) !important; }
@media (max-width: 480px) { .v3-b24-dark form > div:first-child { grid-template-columns: minmax(0, 1fr); } }
