/* ==========================================================================
   Polytem — homepage theme
   --------------------------------------------------------------------------
   01. Tokens
   02. Reset & base
   03. Typography helpers
   04. Layout primitives
   05. Buttons & icons
   06. Ripple motif
   07. Header & navigation
   08. Mobile menu
   09. Hero
   10. Stats marquee
   11. About
   12. Services
   13. Products
   14. Projects gallery
   15. Why Polytem + kinetic type
   16. Partners
   17. CTA band
   18. FAQ accordion
   19. Contact + form
   20. Footer
   21. AI guide (chat)
   22. Toast & lightbox
   23. Reveal / motion utilities
   24. Scroll-driven animations (progressive)
   25. Responsive
   26. Reduced motion
   ========================================================================== */

/* ------------------------------------------------------------------ 01. Tokens */
:root {
  --blue: #2E51A2;
  --blue-deep: #1e3f6e;
  --green: #109619;
  --green-bright: #76C043;

  --ink: #10233f;
  --ink-2: #263b5a;
  --muted: #55677f;
  --line: rgba(30, 63, 110, 0.12);
  --line-strong: rgba(30, 63, 110, 0.22);

  --bg: #f3f8fb;
  --bg-sky: #e7f0fa;
  --bg-mint: #e9f5e6;
  --surface: #ffffff;
  --surface-glass: rgba(255, 255, 255, 0.72);

  --grad-brand: linear-gradient(125deg, #2E51A2 0%, #1e3f6e 48%, #0f7a2a 100%);
  --grad-text: linear-gradient(100deg, var(--blue) 0%, var(--green) 100%);
  --grad-green: linear-gradient(135deg, #18a821 0%, var(--green) 55%, #0c7d13 100%);

  --radius-s: 10px;
  --radius: 18px;
  --radius-l: 28px;
  --radius-xl: 40px;

  --shadow-s: 0 1px 2px rgba(16, 35, 63, 0.05), 0 6px 18px -8px rgba(16, 35, 63, 0.12);
  --shadow: 0 24px 60px -28px rgba(16, 35, 63, 0.35);
  --shadow-l: 0 40px 90px -40px rgba(16, 35, 63, 0.5);

  --container: 1240px;
  --gutter: clamp(1.1rem, 4vw, 2.5rem);
  --header-h: 76px;
  --section-y: clamp(4.5rem, 9vw, 8rem);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);

  --font-fa: "Vazirmatn", "Vazirmatn Static", Tahoma, "Segoe UI", sans-serif;
  --font-latin: "Manrope", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --font: var(--font-fa);
  --lh-body: 1.95;
  --lh-head: 1.4;
  --track-head: 0;

  --fs-xs: 0.8125rem;
  --fs-s: 0.9375rem;
  --fs-base: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  --fs-lead: clamp(1.05rem, 0.98rem + 0.4vw, 1.25rem);
  --fs-h3: clamp(1.15rem, 1.05rem + 0.45vw, 1.4rem);
  --fs-h2: clamp(1.85rem, 1.3rem + 2.4vw, 3.25rem);

  --dir-flip: 1;
  color-scheme: light;
}

html[lang="en"],
html[lang="ru"] {
  --font: var(--font-latin), var(--font-fa);
  --lh-body: 1.7;
  --lh-head: 1.14;
  --track-head: -0.025em;
}

html[dir="rtl"] { --dir-flip: -1; }

/* ------------------------------------------------------------------ 02. Reset & base */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 12px);
  overflow-x: hidden;
  max-width: 100%;
}

html:not(.lenis) { scroll-behavior: smooth; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0;
  min-height: 100vh;
  max-width: 100%;
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  color: var(--ink);
  background-color: var(--bg);
  background-image:
    radial-gradient(70rem 40rem at 105% 8%, rgba(46, 81, 162, 0.09), transparent 62%),
    radial-gradient(60rem 40rem at -10% 32%, rgba(118, 192, 67, 0.11), transparent 62%),
    radial-gradient(70rem 46rem at 110% 62%, rgba(46, 81, 162, 0.08), transparent 62%),
    radial-gradient(60rem 40rem at -5% 92%, rgba(16, 150, 25, 0.08), transparent 62%);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  position: relative;
}

body.is-locked { overflow: hidden; }

img, picture, svg, video { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, p, figure, blockquote, dl, dd { margin: 0; }
address { font-style: normal; }
[hidden] { display: none !important; }
main:focus,
[tabindex="-1"]:focus { outline: none; }

::selection { background: rgba(118, 192, 67, 0.35); color: var(--ink); }

:focus-visible {
  outline: 3px solid var(--green-bright);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Keep symbol sprite completely out of layout/scroll width (was expanding page ~10px) */
.sprite {
  position: absolute !important;
  left: 0 !important;
  top: 0 !important;
  width: 0 !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  border: 0 !important;
  visibility: hidden;
  pointer-events: none;
}

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: fixed;
  inset-inline-start: 1rem;
  top: 0.75rem;
  z-index: 200;
  padding: 0.75rem 1.25rem;
  background: var(--blue-deep);
  color: #fff;
  font-weight: 700;
  border-radius: 999px;
  transform: translateY(-160%);
  transition: transform 0.3s var(--ease);
}
.skip-link:focus { transform: translateY(0); }

/* ------------------------------------------------------------------ 03. Typography helpers */
.latin { font-family: var(--font-latin); }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 1.1rem;
  font-size: var(--fs-s);
  font-weight: 700;
  color: var(--green);
}
.eyebrow::before {
  content: "";
  width: 1.6rem;
  height: 1.6rem;
  flex: none;
  border-radius: 50%;
  background:
    radial-gradient(circle, var(--green) 0 3px, transparent 3.5px),
    radial-gradient(circle, transparent 6px, rgba(16, 150, 25, 0.45) 6.5px 7.5px, transparent 8px),
    radial-gradient(circle, transparent 10px, rgba(46, 81, 162, 0.35) 10.5px 11.5px, transparent 12px);
}
html[lang="en"] .eyebrow,
html[lang="ru"] .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: var(--fs-xs);
}
.eyebrow--light { color: #c9f2a8; }
.eyebrow--light::before {
  background:
    radial-gradient(circle, #c9f2a8 0 3px, transparent 3.5px),
    radial-gradient(circle, transparent 6px, rgba(255, 255, 255, 0.55) 6.5px 7.5px, transparent 8px),
    radial-gradient(circle, transparent 10px, rgba(255, 255, 255, 0.3) 10.5px 11.5px, transparent 12px);
}

.section-title {
  font-size: var(--fs-h2);
  line-height: var(--lh-head);
  letter-spacing: var(--track-head);
  font-weight: 800;
  color: var(--ink);
  max-width: 22ch;
  text-wrap: balance;
}
.section-title--wide { max-width: 30ch; }

.lead {
  margin-top: 1.25rem;
  font-size: var(--fs-lead);
  color: var(--muted);
  max-width: 60ch;
  text-wrap: pretty;
}

.body-text {
  margin-top: 1rem;
  color: var(--muted);
  max-width: 62ch;
}

/* ------------------------------------------------------------------ 04. Layout primitives */
.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  position: relative;
  padding-block: var(--section-y);
  isolation: isolate;
}

.section--tint {
  background:
    linear-gradient(180deg, rgba(231, 240, 250, 0) 0%, rgba(231, 240, 250, 0.75) 18%, rgba(233, 245, 230, 0.7) 82%, rgba(233, 245, 230, 0) 100%);
}

.section-head { margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head--split {
  display: grid;
  gap: 1rem 4rem;
  align-items: end;
}
.section-head--split .lead { margin-top: 0; }

/* ------------------------------------------------------------------ 05. Buttons & icons */
.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon--dir { transform: scaleX(var(--dir-flip)); }
/* arrow glyph points right → rotate -90deg always faces up (ignore RTL mirroring) */
.icon--up { transform: rotate(-90deg) !important; }

.btn {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 48px;
  padding: 0.7rem 1.4rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: var(--fs-s);
  line-height: 1.3;
  color: var(--btn-fg);
  background: var(--btn-bg);
  border: 1.5px solid transparent;
  overflow: hidden;
  isolation: isolate;
  white-space: nowrap;
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease), background-color 0.3s, color 0.3s, border-color 0.3s;
}
.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.35), transparent 60%);
  opacity: 0;
  transition: opacity 0.4s;
}
.btn:hover::after { opacity: 1; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(0.98); }
.btn .icon { transition: transform 0.45s var(--ease); }
.btn:hover .icon--dir { transform: scaleX(var(--dir-flip)) translateX(4px); }

.btn--sm { min-height: 42px; padding: 0.5rem 1.1rem; font-size: var(--fs-xs); }
.btn--lg { min-height: 56px; padding: 0.9rem 1.8rem; font-size: 1rem; }

.btn--primary {
  --btn-fg: #fff;
  background: var(--grad-green);
  box-shadow: 0 14px 30px -14px rgba(16, 150, 25, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.btn--primary:hover { box-shadow: 0 18px 36px -14px rgba(16, 150, 25, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.25); }

.btn--glass {
  --btn-fg: #fff;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.btn--glass:hover { background: rgba(255, 255, 255, 0.2); border-color: #fff; }

.btn--light {
  --btn-fg: var(--blue-deep);
  background: #fff;
  box-shadow: 0 14px 30px -16px rgba(0, 0, 0, 0.45);
}
.btn--light::after { background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(118, 192, 67, 0.25), transparent 60%); }

.btn--outline {
  --btn-fg: var(--blue);
  border-color: rgba(46, 81, 162, 0.35);
  background: rgba(255, 255, 255, 0.6);
  margin-top: 2rem;
}
.btn--outline:hover { border-color: var(--blue); background: #fff; }

/* ------------------------------------------------------------------ 06. Ripple motif */
.ripple { pointer-events: none; overflow: hidden; max-width: min(100vw, 100%); }
.ripple__ring {
  transform-box: fill-box;
  transform-origin: center;
  animation: ripple-spin 38s linear infinite;
}
.ripple__ring.r2 { animation-duration: 52s; animation-direction: reverse; }
.ripple__ring.r3 { animation-duration: 30s; }
.ripple__ring.r4 { animation-duration: 44s; animation-direction: reverse; }

@keyframes ripple-spin { to { transform: rotate(360deg); } }

.ripple--deco {
  position: absolute;
  z-index: -1;
  color: rgba(46, 81, 162, 0.07);
}

/* ------------------------------------------------------------------ 07. Header & navigation */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: 100%;
  z-index: 100;
  height: var(--header-h);
  color: #fff;
  overflow: hidden;
  box-sizing: border-box;
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease), box-shadow 0.4s var(--ease), transform 0.5s var(--ease);
}
.header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 26, 52, 0.45), transparent);
  opacity: 1;
  transition: opacity 0.4s;
  pointer-events: none;
}
.header.is-scrolled {
  color: var(--ink);
  background: rgba(247, 251, 253, 0.82);
  -webkit-backdrop-filter: saturate(1.6) blur(16px);
  backdrop-filter: saturate(1.6) blur(16px);
  box-shadow: 0 1px 0 var(--line), 0 12px 30px -24px rgba(16, 35, 63, 0.45);
}
.header.is-scrolled::before { opacity: 0; }
.header.is-hidden { transform: translateY(-100%); }

.header__progress {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--blue), var(--green-bright));
  transform-origin: left center;
  transform: scaleX(var(--progress, 0));
  opacity: 0;
  transition: opacity 0.3s;
}
html[dir="rtl"] .header__progress {
  background: linear-gradient(270deg, var(--blue), var(--green-bright));
  transform-origin: right center;
}
.header.is-scrolled .header__progress { opacity: 1; }

.header__inner {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-width: 0;
  max-width: 100%;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
  border-radius: 12px;
}
.brand__mark {
  width: 42px;
  height: 42px;
  max-width: 42px;
  max-height: 42px;
  object-fit: contain;
  flex: 0 0 auto;
  border-radius: 6px;
  background: #fff;
  padding: 3px;
  box-shadow: 0 6px 16px -8px rgba(0, 0, 0, 0.4);
  transition: transform 0.6s var(--ease);
}
@media (hover: hover) {
  .brand:hover .brand__mark { transform: rotate(-6deg) scale(1.05); }
}
.brand__text {
  display: grid;
  line-height: 1.1;
  min-width: 0;
}
.brand__name {
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.08em;
  white-space: nowrap;
}
.brand__sub {
  font-size: 0.75rem;
  font-weight: 500;
  opacity: 0.8;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav { margin-inline-start: auto; }
.nav__list { display: flex; align-items: center; gap: 0.25rem; }
.nav__link {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.4rem 0.8rem;
  font-size: var(--fs-s);
  font-weight: 600;
  border-radius: 999px;
  transition: color 0.3s, background-color 0.3s;
}
.nav__link::after {
  content: "";
  position: absolute;
  inset-inline: 0.8rem;
  bottom: 6px;
  height: 2px;
  border-radius: 2px;
  background: var(--green-bright);
  transform: scaleX(0);
  transition: transform 0.45s var(--ease);
}
.nav__link:hover::after,
.nav__link[aria-current="true"]::after { transform: scaleX(1); }
.header.is-scrolled .nav__link[aria-current="true"] { color: var(--blue); }

.header__tools {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.lang {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
  transition: border-color 0.3s, background-color 0.3s;
}
.header.is-scrolled .lang { border-color: var(--line-strong); background: rgba(255, 255, 255, 0.7); }
.lang__btn {
  min-width: 40px;
  min-height: 36px;
  padding: 0 0.6rem;
  border-radius: 999px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: background-color 0.3s, color 0.3s;
}
.lang__btn:hover { background: rgba(255, 255, 255, 0.16); }
.lang__btn[aria-pressed="true"] {
  background: #fff;
  color: var(--blue-deep);
  box-shadow: 0 4px 10px -6px rgba(0, 0, 0, 0.5);
}
.header.is-scrolled .lang__btn:hover { background: rgba(46, 81, 162, 0.08); }
.header.is-scrolled .lang__btn[aria-pressed="true"] { background: var(--blue); color: #fff; }
.lang__btn[lang="fa"] { font-family: var(--font-fa); }

.burger {
  display: none;
  position: relative;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.08);
  transition: border-color 0.3s, background-color 0.3s;
}
.header.is-scrolled .burger { border-color: var(--line-strong); background: #fff; }
.burger__line {
  position: absolute;
  inset-inline-start: 13px;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.5s var(--ease), opacity 0.3s, width 0.4s var(--ease);
}
.burger__line:nth-child(1) { top: 16px; }
.burger__line:nth-child(2) { top: 22px; width: 14px; }
.burger__line:nth-child(3) { top: 28px; }
.burger:hover .burger__line:nth-child(2) { width: 20px; }
.burger[aria-expanded="true"] .burger__line:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger[aria-expanded="true"] .burger__line:nth-child(2) { opacity: 0; transform: scaleX(0); }
.burger[aria-expanded="true"] .burger__line:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

body.menu-open .header {
  color: #fff;
  background: transparent;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}
body.menu-open .header::before,
body.menu-open .header__progress { opacity: 0; }
body.menu-open .header .lang { border-color: rgba(255, 255, 255, 0.35); background: rgba(255, 255, 255, 0.08); }
body.menu-open .header .lang__btn[aria-pressed="true"] { background: #fff; color: var(--blue-deep); }
body.menu-open .header .burger { border-color: rgba(255, 255, 255, 0.4); background: rgba(255, 255, 255, 0.1); }

/* ------------------------------------------------------------------ 08. Mobile menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  padding: calc(var(--header-h) + 1.5rem) var(--gutter) calc(2rem + env(safe-area-inset-bottom));
  color: #fff;
  overflow-y: auto;
  overscroll-behavior: contain;
  visibility: hidden;
  clip-path: circle(0% at var(--cx, 90%) var(--cy, 38px));
  transition: clip-path 0.8s var(--ease-in-out), visibility 0s linear 0.8s;
}
.mobile-menu.is-open {
  visibility: visible;
  clip-path: circle(150% at var(--cx, 90%) var(--cy, 38px));
  transition: clip-path 0.8s var(--ease-in-out), visibility 0s;
}
.mobile-menu__bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: var(--grad-brand);
}
.ripple--menu {
  position: absolute;
  width: min(140vw, 760px);
  inset-inline-end: -35%;
  bottom: -20%;
  color: rgba(255, 255, 255, 0.09);
}
.mobile-menu__list { display: grid; gap: 0.25rem; }
.mobile-menu__link {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  padding: 0.55rem 0;
  font-size: clamp(1.6rem, 6.5vw, 2.6rem);
  font-weight: 800;
  line-height: 1.3;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  transition: color 0.3s, padding 0.45s var(--ease);
}
.mobile-menu__link:hover,
.mobile-menu__link[aria-current="true"] { color: #c9f2a8; padding-inline-start: 0.6rem; }
.mobile-menu__num {
  font-size: 0.8rem;
  font-weight: 700;
  opacity: 0.55;
  letter-spacing: 0.1em;
}
.mobile-menu__foot {
  margin-top: auto;
  padding-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
}
.mobile-menu__contact {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  font-weight: 600;
  opacity: 0.9;
}
.mobile-menu__item-anim { will-change: transform, opacity; }

/* ------------------------------------------------------------------ 09. Hero */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-block: calc(var(--header-h) + 3rem) clamp(6rem, 13vh, 9rem);
  color: #fff;
  overflow: hidden;
  isolation: isolate;
  contain: paint;
  clip-path: inset(0);
  background: var(--blue-deep);
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: -3;
  overflow: hidden;
  clip-path: inset(0);
  will-change: transform;
}
.hero__slide {
  position: absolute;
  inset: 0;
  overflow: hidden;
  opacity: 0;
  transition: opacity 1.8s var(--ease-in-out);
}
.hero__slide.is-active { opacity: 1; }
.hero__slide picture,
.hero__slide img {
  width: 100%;
  height: 100%;
  max-width: none; /* cover area; parent clips scaled overflow */
}
.hero__slide img {
  object-fit: cover;
  object-position: 45% 65%;
  transform: scale(1.04);
  transform-origin: center center;
  animation: kenburns 22s ease-in-out infinite alternate;
}
.hero__slide:nth-child(2) img {
  object-position: 62% 55%;
  animation-delay: -11s;
}

@keyframes kenburns {
  from { transform: scale(1.04); }
  to   { transform: scale(1.1); }
}

.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(0deg, rgba(9, 25, 50, 0.92) 0%, rgba(9, 25, 50, 0.55) 30%, rgba(9, 25, 50, 0.08) 62%, rgba(9, 25, 50, 0.4) 100%),
    linear-gradient(90deg, rgba(16, 40, 86, 0.72) 0%, rgba(16, 40, 86, 0.25) 45%, transparent 70%);
}
html[dir="rtl"] .hero__scrim {
  background:
    linear-gradient(0deg, rgba(9, 25, 50, 0.92) 0%, rgba(9, 25, 50, 0.55) 30%, rgba(9, 25, 50, 0.08) 62%, rgba(9, 25, 50, 0.4) 100%),
    linear-gradient(270deg, rgba(16, 40, 86, 0.72) 0%, rgba(16, 40, 86, 0.25) 45%, transparent 70%);
}

.ripple--hero {
  position: absolute;
  z-index: -1;
  width: clamp(340px, 52vw, 820px);
  inset-inline-end: clamp(-260px, -12vw, -60px);
  top: 14%;
  color: rgba(255, 255, 255, 0.16);
  mix-blend-mode: overlay;
}

.hero__inner { position: relative; }

.hero__kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  font-size: var(--fs-s);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.88);
}
.hero__kicker-line {
  width: 2.75rem;
  height: 2px;
  background: linear-gradient(90deg, var(--green-bright), rgba(255, 255, 255, 0.6));
  border-radius: 2px;
}
html[lang="en"] .hero__kicker,
html[lang="ru"] .hero__kicker { letter-spacing: 0.06em; }

.hero__heading { margin-top: 0.75rem; }

.hero__brand {
  display: block;
  max-width: 100%;
  font-family: var(--font-latin);
  font-weight: 800;
  font-size: clamp(2.6rem, 12vw, 13.5rem);
  line-height: 0.86;
  letter-spacing: -0.045em;
  overflow: hidden;
  padding-block: 0.04em 0.06em;
}
.hero__brand-word {
  display: inline-flex;
  max-width: 100%;
}
.hero__brand .ch {
  display: inline-block;
  background: linear-gradient(180deg, #ffffff 35%, rgba(213, 240, 196, 0.85) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: none;
  will-change: transform;
}

.hero__title {
  display: block;
  margin-top: clamp(0.9rem, 2vw, 1.5rem);
  font-size: clamp(1.45rem, 1rem + 2.2vw, 2.85rem);
  font-weight: 800;
  line-height: var(--lh-head);
  letter-spacing: var(--track-head);
  max-width: 24ch;
  text-wrap: balance;
}
.hero__line { display: block; overflow: hidden; padding-block: 0.04em; }
.hero__line-inner { display: inline-block; will-change: transform; }
.hero__line--accent { color: #b9ec8f; }

.hero__text {
  margin-top: 1.1rem;
  max-width: 44ch;
  font-size: var(--fs-lead);
  color: rgba(255, 255, 255, 0.86);
  text-wrap: pretty;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: clamp(1.6rem, 3vw, 2.4rem);
}

.hero__scroll {
  position: absolute;
  bottom: clamp(3.75rem, 8vh, 5.5rem);
  inset-inline-end: var(--gutter);
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  font-size: var(--fs-xs);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
  min-width: 44px;
}
html[lang="en"] .hero__scroll,
html[lang="ru"] .hero__scroll { text-transform: uppercase; letter-spacing: 0.18em; }
.hero__scroll-track {
  position: relative;
  width: 26px;
  height: 42px;
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.6);
}
.hero__scroll-dot {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 5px;
  height: 8px;
  margin-left: -2.5px;
  border-radius: 4px;
  background: var(--green-bright);
  animation: scroll-dot 2.2s var(--ease) infinite;
}
@keyframes scroll-dot {
  0% { transform: translateY(0); opacity: 0; }
  25% { opacity: 1; }
  80% { transform: translateY(16px); opacity: 0; }
  100% { transform: translateY(16px); opacity: 0; }
}

.hero__curve {
  position: absolute;
  inset-inline: 0;
  bottom: -1px;
  width: 100%;
  height: clamp(36px, 6vw, 80px);
  fill: var(--bg);
  z-index: 1;
}
html[dir="rtl"] .hero__curve { transform: scaleX(-1); }

/* ------------------------------------------------------------------ 10. Stats marquee */
.stats {
  position: relative;
  padding-block: clamp(1.5rem, 3vw, 2.5rem);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  max-width: 100%;
}
.marquee {
  direction: ltr;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee__track {
  display: flex;
  width: max-content;
  direction: ltr;
  animation: marquee 48s linear infinite;
}
html[dir="rtl"] .marquee__track { animation-direction: reverse; }
.marquee:hover .marquee__track,
.marquee:focus-within .marquee__track { animation-play-state: paused; }
.marquee__group { display: flex; align-items: center; flex: none; }

@keyframes marquee {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}

.stat {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  padding-inline: clamp(1.25rem, 3vw, 2.5rem);
  white-space: nowrap;
}
html[dir="rtl"] .stat { direction: rtl; }
.stat__value {
  font-size: clamp(1.7rem, 1.2rem + 2vw, 2.75rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  unicode-bidi: isolate;
  padding-block: 0.1em;
}
.stat__label {
  max-width: 17rem;
  white-space: normal;
  font-size: var(--fs-s);
  font-weight: 600;
  line-height: 1.5;
  color: var(--muted);
}
.stat__sep {
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 50%;
  background:
    radial-gradient(circle, var(--green-bright) 0 3px, transparent 3.5px),
    radial-gradient(circle, transparent 7px, rgba(46, 81, 162, 0.35) 7.5px 8.5px, transparent 9px);
}

/* ------------------------------------------------------------------ 11. About */
.about__ripple {
  width: clamp(420px, 55vw, 760px);
  inset-inline-start: -14%;
  top: 4%;
}
.about__grid {
  display: grid;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: center;
}
.about__media {
  position: relative;
  padding-bottom: 14%;
  padding-inline-end: 12%;
}
.about__img {
  overflow: hidden;
  border-radius: var(--radius-l);
  box-shadow: var(--shadow);
  background: var(--bg-sky);
}
.about__img img { width: 100%; height: 100%; object-fit: cover; }
.about__img--main { aspect-ratio: 1 / 1; }
.about__img--main img { transform: scale(1.12); }
.about__img--sub {
  position: absolute;
  inset-inline-end: 0;
  bottom: 0;
  width: 50%;
  aspect-ratio: 11 / 10;
  border: 6px solid var(--bg);
  border-radius: var(--radius);
}
.about__since {
  position: absolute;
  inset-inline-start: 0;
  bottom: 0;
  display: grid;
  line-height: 1.1;
}
.about__since-num {
  font-family: var(--font-latin);
  font-size: clamp(2.6rem, 5vw, 4.25rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
html[lang="fa"] .about__since-num { font-family: var(--font-fa); letter-spacing: 0; }
.about__since-label { font-size: var(--fs-s); font-weight: 600; color: var(--muted); }

.about__pillars {
  display: grid;
  gap: 1.5rem;
  margin-top: 2.25rem;
}
.pillar {
  position: relative;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line-strong);
}
.pillar::before {
  content: "";
  position: absolute;
  top: -1px;
  inset-inline-start: 0;
  width: 3rem;
  height: 3px;
  border-radius: 3px;
  background: var(--grad-text);
}
.pillar__num {
  display: block;
  font-size: var(--fs-xs);
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--green);
}
.pillar__title {
  margin-top: 0.35rem;
  font-size: var(--fs-h3);
  font-weight: 800;
  line-height: var(--lh-head);
}
.pillar__text { margin-top: 0.4rem; color: var(--muted); font-size: var(--fs-s); }

.quote {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  margin-top: 2.25rem;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius);
  background: linear-gradient(120deg, rgba(46, 81, 162, 0.08), rgba(118, 192, 67, 0.12));
  border-inline-start: 4px solid var(--green);
  font-size: clamp(1.1rem, 1rem + 0.5vw, 1.35rem);
  font-weight: 700;
  line-height: 1.5;
  color: var(--blue-deep);
}
html[lang="en"] .quote p,
html[lang="ru"] .quote p { font-style: italic; }
.quote__icon { width: 1.6em; height: 1.6em; color: var(--green); margin-top: 0.1em; }

/* ------------------------------------------------------------------ 12. Services */
.services__grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}
.service {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: clamp(1.5rem, 2.5vw, 2rem);
  border-radius: var(--radius-l);
  background: var(--surface-glass);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-s);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  overflow: hidden;
  isolation: isolate;
  container-type: inline-size;
  transition: transform 0.6s var(--ease), box-shadow 0.6s var(--ease), border-color 0.4s;
}
.service::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -40%;
  inset-inline-start: -40%;
  width: 180%;
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(118, 192, 67, 0.18) 0 18%, transparent 18.5%),
    repeating-radial-gradient(circle, rgba(46, 81, 162, 0.07) 0 2px, transparent 2px 28px);
  transform: scale(0.15);
  opacity: 0;
  transition: transform 1s var(--ease), opacity 0.6s;
}
.service:hover,
.service:focus-within {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: rgba(118, 192, 67, 0.5);
}
.service:hover::before,
.service:focus-within::before { transform: scale(1); opacity: 1; }

.service__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.service__icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 18px;
  color: #fff;
  background: var(--grad-brand);
  box-shadow: 0 12px 24px -12px rgba(30, 63, 110, 0.7);
  transition: transform 0.6s var(--ease), border-radius 0.6s var(--ease);
}
.service__icon .icon { width: 28px; height: 28px; }
.service:hover .service__icon { transform: rotate(-8deg) scale(1.06); border-radius: 50%; }
.service__num {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.2px rgba(46, 81, 162, 0.28);
}
.service__title {
  margin-top: 1.5rem;
  font-size: var(--fs-h3);
  font-weight: 800;
  line-height: var(--lh-head);
}
.service__text { margin-top: 0.5rem; color: var(--muted); font-size: var(--fs-s); }
.service__list {
  display: grid;
  gap: 0.55rem;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px dashed var(--line-strong);
  font-size: var(--fs-s);
  line-height: 1.6;
  color: var(--ink-2);
}
.service__list li {
  position: relative;
  padding-inline-start: 1.5rem;
}
.service__list li::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: 0.45em;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50% 50% 50% 0;
  background: var(--grad-text);
  transform: rotate(-45deg);
}
.service__link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  margin-top: auto;
  padding-top: 1.25rem;
  font-size: var(--fs-s);
  font-weight: 700;
  color: var(--blue);
}
.service__link .icon { transition: transform 0.45s var(--ease); }
.service__link:hover .icon--dir { transform: scaleX(var(--dir-flip)) translateX(4px); }

/* ------------------------------------------------------------------ 13. Products */
.products__grid {
  display: grid;
  gap: clamp(1rem, 2vw, 1.5rem);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
}
.product { container-type: inline-size; }
.product__inner {
  position: relative;
  height: 100%;
  display: grid;
  grid-template-rows: auto 1fr;
  border-radius: var(--radius-l);
  background: var(--surface);
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow: var(--shadow-s);
  transition: transform 0.6s var(--ease), box-shadow 0.6s var(--ease), border-color 0.4s;
}
.product__inner::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 3px;
  background: var(--grad-text);
  transform: scaleX(0);
  transform-origin: var(--origin, left);
  transition: transform 0.7s var(--ease);
}
html[dir="rtl"] .product__inner::after { --origin: right; }
.product:hover .product__inner,
.product:focus-within .product__inner {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: rgba(46, 81, 162, 0.2);
}
.product:hover .product__inner::after,
.product:focus-within .product__inner::after { transform: scaleX(1); }

.product__media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: linear-gradient(160deg, var(--bg-sky), var(--bg-mint));
}
.product__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.1s var(--ease);
}
.product__media img.product__img--contain {
  object-fit: contain;
  padding: 8% 6%;
  background: linear-gradient(180deg, #f6f7f9, #dfe3e8);
}
.product:hover .product__media img { transform: scale(1.07); }

.product__body {
  display: flex;
  flex-direction: column;
  padding: clamp(1.25rem, 2.2vw, 1.75rem);
}
.product__meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--green);
}
html[lang="en"] .product__meta,
html[lang="ru"] .product__meta { text-transform: uppercase; letter-spacing: 0.1em; }
.product__index {
  color: var(--blue);
  padding-inline-end: 0.6rem;
  border-inline-end: 1px solid var(--line-strong);
}
.product__title {
  margin-top: 0.6rem;
  font-size: var(--fs-h3);
  font-weight: 800;
  line-height: var(--lh-head);
}
.product__text { margin-top: 0.5rem; color: var(--muted); font-size: var(--fs-s); }
.product__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  align-self: flex-start;
  min-height: 44px;
  margin-top: auto;
  padding-top: 1rem;
  font-size: var(--fs-s);
  font-weight: 700;
  color: var(--blue);
}
.product__cta .icon { transition: transform 0.45s var(--ease); }
.product__cta:hover { color: var(--green); }
.product__cta:hover .icon--dir { transform: scaleX(var(--dir-flip)) translateX(4px); }

@container (min-width: 560px) {
  .product__inner { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr; }
  .product__media { aspect-ratio: auto; min-height: 100%; }
}

/* ------------------------------------------------------------------ 14. Projects gallery */
.gallery {
  display: grid;
  gap: clamp(0.75rem, 1.5vw, 1.25rem);
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: clamp(190px, 19vw, 260px);
  grid-template-areas:
    "a a b c"
    "a a b d"
    "e e f f";
}
.tile--a { grid-area: a; }
.tile--b { grid-area: b; }
.tile--c { grid-area: c; }
.tile--d { grid-area: d; }
.tile--e { grid-area: e; }
.tile--cta { grid-area: f; }

.tile {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: var(--radius-l);
  background: var(--blue-deep);
  color: #fff;
  text-align: start;
  isolation: isolate;
  box-shadow: var(--shadow-s);
}
.tile picture,
.tile img { width: 100%; height: 100%; }
.tile img {
  object-fit: cover;
  transform: scale(1.04);
  transition: transform 1.2s var(--ease), filter 0.6s;
}
.tile:hover img,
.tile:focus-visible img { transform: scale(1.12); }
.tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(9, 25, 50, 0.88) 0%, rgba(9, 25, 50, 0.3) 42%, transparent 70%);
  transition: opacity 0.5s;
}
.tile__caption {
  position: absolute;
  z-index: 1;
  inset-inline: 0;
  bottom: 0;
  display: grid;
  gap: 0.3rem;
  padding: clamp(1rem, 2vw, 1.5rem);
}
.tile__title {
  font-size: clamp(1rem, 0.9rem + 0.5vw, 1.3rem);
  font-weight: 800;
  line-height: 1.35;
}
.tile__text {
  font-size: var(--fs-s);
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.82);
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transform: translateY(8px);
  transition: max-height 0.6s var(--ease), opacity 0.5s, transform 0.6s var(--ease);
}
.tile:hover .tile__text,
.tile:focus-visible .tile__text { max-height: 5em; opacity: 1; transform: none; }
.tile__zoom {
  position: absolute;
  z-index: 1;
  top: 1rem;
  inset-inline-end: 1rem;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  opacity: 0;
  transform: scale(0.7);
  transition: opacity 0.4s, transform 0.5s var(--ease);
}
.tile:hover .tile__zoom,
.tile:focus-visible .tile__zoom { opacity: 1; transform: none; }

.tile--cta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 0.6rem;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  background: var(--grad-brand);
}
.tile--cta::after { display: none; }
.ripple--tile {
  position: absolute;
  z-index: -1;
  width: 120%;
  max-width: 520px;
  inset-inline-end: -25%;
  top: -40%;
  color: rgba(255, 255, 255, 0.12);
}
.tile__cta-title {
  font-size: clamp(1.4rem, 1.1rem + 1.2vw, 2rem);
  font-weight: 800;
  line-height: var(--lh-head);
  letter-spacing: var(--track-head);
}
.tile__cta-text { max-width: 36ch; color: rgba(255, 255, 255, 0.82); font-size: var(--fs-s); }
.tile--cta .btn { margin-top: 0.75rem; }

/* ------------------------------------------------------------------ 15. Why Polytem + kinetic type */
.why { overflow: hidden; }
.why__grid {
  display: grid;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: start;
}
.why__figure {
  margin-top: 2.5rem;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-l);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.why__figure img { width: 100%; height: 100%; object-fit: cover; object-position: 70% 55%; transform: scale(1.12); }

.values {
  display: grid;
  gap: 0;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  border-top: 1px solid var(--line-strong);
}
.value {
  position: relative;
  padding: 1.75rem 0.25rem 1.75rem;
  border-bottom: 1px solid var(--line-strong);
}
.value__icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  color: var(--blue);
  background: #fff;
  box-shadow: 0 0 0 6px rgba(46, 81, 162, 0.06), 0 0 0 12px rgba(118, 192, 67, 0.06);
  transition: transform 0.8s var(--ease), color 0.4s, background-color 0.4s, box-shadow 0.6s var(--ease);
}
.value__icon .icon { width: 24px; height: 24px; }
.value:hover .value__icon {
  color: #fff;
  background: var(--green);
  transform: rotate(-12deg);
  box-shadow: 0 0 0 8px rgba(16, 150, 25, 0.12), 0 0 0 16px rgba(46, 81, 162, 0.08);
}
.value__title {
  margin-top: 1.1rem;
  font-size: var(--fs-h3);
  font-weight: 800;
  line-height: var(--lh-head);
}
.value__text { margin-top: 0.45rem; font-size: var(--fs-s); color: var(--muted); max-width: 38ch; }

.kinetic {
  margin-top: clamp(4rem, 8vw, 7rem);
  display: grid;
  gap: 0.2rem;
  user-select: none;
  pointer-events: none;
  overflow: hidden; /* kinetic lines use negative margins / max-content widths */
  max-width: 100%;
}
.kinetic__line {
  display: flex;
  align-items: center;
  gap: clamp(1.25rem, 3vw, 2.5rem);
  width: max-content;
  white-space: nowrap;
  font-size: clamp(2.6rem, 1.4rem + 6vw, 7.5rem);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: var(--track-head);
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  will-change: transform;
}
.kinetic__line--outline {
  font-family: var(--font-latin);
  letter-spacing: -0.03em;
  background: none;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(46, 81, 162, 0.32);
}
.kinetic__line[data-kinetic="-1"] { margin-inline-start: -30vw; }
.kinetic__dot {
  width: 0.32em;
  height: 0.32em;
  flex: none;
  border-radius: 50%;
  background: var(--green-bright);
  -webkit-text-stroke: 0;
}
.kinetic__line--outline .kinetic__dot { background: rgba(46, 81, 162, 0.25); }

/* ------------------------------------------------------------------ 16. Partners */
.partners__figure {
  position: relative;
  aspect-ratio: 21 / 7;
  border-radius: var(--radius-l);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.partners__figure img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.1); }

.partners__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  margin-top: clamp(1.5rem, 3vw, 2.5rem);
  border-radius: var(--radius-l);
  background: var(--surface-glass);
  border: 1px solid rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  overflow: hidden;
}
.partner {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 1rem;
  align-items: center;
  padding: 1.5rem clamp(1.25rem, 2vw, 1.75rem);
  border-inline-start: 1px solid var(--line);
  transition: background-color 0.4s;
}
.partner:first-child { border-inline-start: 0; }
.partner:hover { background: rgba(255, 255, 255, 0.9); }
.partner__mark {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  color: var(--green);
  background: rgba(118, 192, 67, 0.14);
  transition: transform 0.6s var(--ease), background-color 0.4s, color 0.4s;
}
.partner:hover .partner__mark { transform: rotate(-10deg); background: var(--green); color: #fff; }
.partner__name { font-size: 1.05rem; font-weight: 800; line-height: 1.4; }
.partner__role { font-size: var(--fs-xs); font-weight: 600; color: var(--muted); line-height: 1.5; }

/* ------------------------------------------------------------------ 17. CTA band */
.cta-band { padding-block: clamp(2rem, 5vw, 4rem); }
.cta-band__box {
  position: relative;
  display: grid;
  gap: 2rem;
  align-items: center;
  padding: clamp(2.25rem, 6vw, 4.5rem);
  border-radius: var(--radius-xl);
  background: var(--grad-brand);
  color: #fff;
  overflow: hidden;
  isolation: isolate;
  box-shadow: var(--shadow-l);
}
.cta-band__box::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(40rem 20rem at 90% 120%, rgba(118, 192, 67, 0.45), transparent 60%),
    radial-gradient(30rem 20rem at 0% -20%, rgba(120, 160, 255, 0.35), transparent 60%);
}
.ripple--cta {
  position: absolute;
  z-index: -1;
  width: clamp(360px, 46vw, 640px);
  inset-inline-end: -10%;
  top: 50%;
  translate: 0 -50%;
  color: rgba(255, 255, 255, 0.13);
}
.cta-band__title {
  font-size: clamp(1.7rem, 1.2rem + 2.2vw, 3rem);
  font-weight: 800;
  line-height: var(--lh-head);
  letter-spacing: var(--track-head);
  max-width: 20ch;
  text-wrap: balance;
}
.cta-band__text { margin-top: 1rem; max-width: 52ch; color: rgba(255, 255, 255, 0.85); font-size: var(--fs-lead); }
.cta-band__actions { display: flex; flex-wrap: wrap; gap: 0.85rem; }

/* ------------------------------------------------------------------ 18. FAQ accordion */
.faq__grid {
  display: grid;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}
.accordion { border-top: 1px solid var(--line-strong); }
.acc-item { border-bottom: 1px solid var(--line-strong); }
.acc-item__heading { font-size: inherit; }
.acc-item__btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  width: 100%;
  min-height: 64px;
  padding: 1.25rem 0;
  text-align: start;
  font-size: clamp(1.02rem, 0.95rem + 0.35vw, 1.2rem);
  font-weight: 700;
  line-height: 1.55;
  transition: color 0.3s;
}
.acc-item__btn:hover { color: var(--blue); }
.acc-item__icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: 50%;
  border: 1.5px solid var(--line-strong);
  color: var(--blue);
  transition: transform 0.5s var(--ease), background-color 0.3s, color 0.3s, border-color 0.3s;
}
.acc-item.is-open .acc-item__icon {
  transform: rotate(135deg);
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}
.acc-item__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.55s var(--ease);
}
.acc-item.is-open .acc-item__panel { grid-template-rows: 1fr; }
.acc-item__inner { overflow: hidden; }
.acc-item__inner p {
  padding-bottom: 1.5rem;
  padding-inline-end: 3.5rem;
  color: var(--muted);
  max-width: 68ch;
}

/* ------------------------------------------------------------------ 19. Contact + form */
.contact__grid {
  display: grid;
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: start;
}
.office {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--line-strong);
}
.office + .office { margin-top: 1.75rem; }
.office__icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  flex: none;
  border-radius: 14px;
  color: #fff;
  background: var(--grad-brand);
}
.office__title { font-size: var(--fs-h3); font-weight: 800; line-height: var(--lh-head); }
.office__address { margin-top: 0.35rem; color: var(--muted); max-width: 46ch; line-height: 1.8; }
.office__lines {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.75rem;
  margin-top: 0.6rem;
  font-size: var(--fs-s);
}
.office__lines > div { display: flex; align-items: center; gap: 0.5rem; }
.office__lines dt { color: var(--muted); font-weight: 600; }
.office__lines dt::after { content: ":"; }
.office__lines dd { font-weight: 800; color: var(--ink); }
.office__lines a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  color: var(--blue);
  transition: color 0.3s;
}
.office__lines a:hover { color: var(--green); }

.contact__mail {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.75rem;
  padding: 0.9rem 1.25rem 0.9rem 0.9rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-s);
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
html[dir="rtl"] .contact__mail { padding: 0.9rem 0.9rem 0.9rem 1.5rem; }
.contact__mail:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.contact__mail .office__icon { border-radius: 50%; }
.contact__mail > span:last-child { display: grid; line-height: 1.35; }
.contact__mail-label { font-size: var(--fs-xs); color: var(--muted); font-weight: 600; }
.contact__mail-value { font-weight: 800; color: var(--blue); }

.form {
  position: relative;
  padding: clamp(1.5rem, 4vw, 2.75rem);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
.form__title { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); font-weight: 800; line-height: var(--lh-head); }
.form__intro { margin-top: 0.4rem; color: var(--muted); font-size: var(--fs-s); }
.form__grid {
  display: grid;
  gap: 1.1rem 1.25rem;
  margin-top: 1.75rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}
.field { display: grid; gap: 0.4rem; }
.field--full { grid-column: 1 / -1; }
.field__label { font-size: var(--fs-s); font-weight: 700; color: var(--ink-2); }
.field__req { color: var(--green); }
.field__input {
  width: 100%;
  min-height: 52px;
  padding: 0.75rem 1rem;
  border-radius: 14px;
  border: 1.5px solid var(--line-strong);
  background: #fff;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ink);
  transition: border-color 0.3s, box-shadow 0.3s, background-color 0.3s;
  appearance: none;
  -webkit-appearance: none;
}
.field__input::placeholder { color: #8b99ab; opacity: 1; }
.field__input:hover { border-color: rgba(46, 81, 162, 0.4); }
.field__input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(46, 81, 162, 0.14);
}
.ltr-input { direction: ltr; text-align: start; }
html[dir="rtl"] .ltr-input { text-align: right; }
html[dir="rtl"] .ltr-input::placeholder { direction: rtl; }
.field__textarea { min-height: 128px; resize: vertical; }
.field__select {
  padding-inline-end: 2.75rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232E51A2' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: 18px;
  background-position: right 1rem center;
  cursor: pointer;
}
html[dir="rtl"] .field__select { background-position: left 1rem center; }

.form.was-validated .field__input:invalid {
  border-color: #c2412d;
  box-shadow: 0 0 0 4px rgba(194, 65, 45, 0.1);
}

.form__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.75rem;
}
.form__note { font-size: var(--fs-xs); color: var(--muted); }

/* ------------------------------------------------------------------ 20. Footer */
.footer {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  margin-top: clamp(2rem, 4vw, 3rem);
  padding-top: clamp(3.5rem, 7vw, 5.5rem);
  color: rgba(255, 255, 255, 0.78);
  background: linear-gradient(160deg, #1e3f6e 0%, #15305a 55%, #0f3a33 100%);
}
.ripple--footer {
  position: absolute;
  z-index: -1;
  width: clamp(380px, 46vw, 680px);
  inset-inline-end: -12%;
  top: -30%;
  color: rgba(255, 255, 255, 0.05);
}
.footer__grid {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
}
.brand--footer { color: #fff; }
.footer__about { margin-top: 1.25rem; max-width: 36ch; font-size: var(--fs-s); }
.footer__slogan {
  margin-top: 1rem;
  max-width: 38ch;
  font-size: var(--fs-s);
  font-weight: 700;
  color: #c9f2a8;
  line-height: 1.7;
}
.footer__title {
  margin-bottom: 1rem;
  font-size: var(--fs-s);
  font-weight: 800;
  color: #fff;
}
html[lang="en"] .footer__title,
html[lang="ru"] .footer__title { text-transform: uppercase; letter-spacing: 0.12em; font-size: var(--fs-xs); }
.footer__links { display: grid; gap: 0.1rem; }
.footer__links a,
.footer__contact a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  transition: color 0.3s;
}
.footer__links a:hover,
.footer__contact a:hover { color: #c9f2a8; }
.footer__contact { display: grid; gap: 0.6rem; font-size: var(--fs-s); }
.footer__contact li { display: flex; align-items: flex-start; gap: 0.6rem; line-height: 1.7; }
.footer__contact .icon { margin-top: 0.25em; color: var(--green-bright); }
.footer__contact li:not(:first-child) .icon { margin-top: 0.7em; }

.lang--footer {
  flex-wrap: wrap;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
}
.lang--footer .lang__btn {
  min-height: 40px;
  padding-inline: 0.9rem;
  color: rgba(255, 255, 255, 0.92);
}
.lang--footer .lang__btn:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}
.lang--footer .lang__btn[aria-pressed="true"] {
  background: #fff;
  color: var(--blue-deep);
  box-shadow: 0 6px 14px -8px rgba(0, 0, 0, 0.55);
}
.lang--footer .lang__btn[lang="en"],
.lang--footer .lang__btn[lang="ru"] { font-family: var(--font-latin); }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: clamp(2.5rem, 5vw, 4rem);
  padding-top: 1.5rem;
  /* empty band under links so fixed AI chat does not cover them */
  padding-bottom: calc(5.75rem + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: var(--fs-xs);
}
.footer__bottom > p { max-width: 48ch; }
.footer__top {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  font-weight: 700;
  color: #fff;
}
.footer__top .icon {
  width: 16px;
  height: 16px;
  transition: transform 0.45s var(--ease);
}
.footer__top:hover .icon.icon--up {
  transform: rotate(-90deg) translateX(3px) !important;
}

/* ------------------------------------------------------------------ 21. AI guide (chat) */
.chat {
  position: fixed;
  z-index: 86;
  bottom: calc(1.25rem + env(safe-area-inset-bottom));
  /* physical corners: LTR → bottom-right, RTL (FA) → bottom-left — fully on-screen */
  right: max(1.25rem, env(safe-area-inset-right));
  left: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  width: max-content;
  max-width: calc(100vw - 2rem);
  height: auto;
  pointer-events: none; /* only launcher/panel receive clicks */
}
html[dir="rtl"] .chat {
  left: max(1.25rem, env(safe-area-inset-left));
  right: auto;
  align-items: flex-start;
}
body.menu-open .chat {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.chat__launcher {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-height: 56px;
  min-width: 56px;
  padding: 0.4rem 1.25rem 0.4rem 0.4rem;
  border-radius: 999px;
  color: #fff;
  background: var(--grad-brand);
  box-shadow: 0 18px 40px -16px rgba(16, 35, 63, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  font-weight: 700;
  font-size: var(--fs-s);
  pointer-events: auto;
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
html[dir="rtl"] .chat__launcher { padding: 0.4rem 0.4rem 0.4rem 1.25rem; }
.chat__launcher:hover { transform: translateY(-3px); }
.chat__launcher-icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--grad-green);
}
.chat__launcher-icon .icon {
  position: absolute;
  width: 24px;
  height: 24px;
  transition: transform 0.5s var(--ease), opacity 0.3s;
}
.chat__icon-close { opacity: 0; transform: rotate(-90deg) scale(0.5); }
.chat.is-open .chat__icon-open { opacity: 0; transform: rotate(90deg) scale(0.5); }
.chat.is-open .chat__icon-close { opacity: 1; transform: none; }
.chat__pulse {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 2px solid var(--green-bright);
  animation: chat-pulse 2.6s var(--ease) infinite;
  pointer-events: none;
}
.chat.is-seen .chat__pulse { display: none; }
@keyframes chat-pulse {
  0% { transform: scale(1); opacity: 0.7; }
  100% { transform: scale(1.25, 1.5); opacity: 0; }
}

.chat__panel {
  position: absolute;
  bottom: calc(100% + 0.85rem);
  right: 0;
  left: auto;
  display: flex;
  flex-direction: column;
  width: min(390px, calc(100vw - 2rem));
  max-height: min(620px, calc(100svh - 7.5rem));
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow-l), 0 0 0 1px var(--line);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(16px) scale(0.96);
  transform-origin: bottom right;
  transition: opacity 0.35s var(--ease), transform 0.5s var(--ease), visibility 0s linear 0.5s;
}
html[dir="rtl"] .chat__panel {
  left: 0;
  right: auto;
  transform-origin: bottom left;
}
.chat.is-open .chat__panel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: none;
  transition: opacity 0.35s var(--ease), transform 0.5s var(--ease), visibility 0s;
}

.chat__head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 1rem 1rem 1rem 1.1rem;
  color: #fff;
  background: var(--grad-brand);
  overflow: hidden;
}
.chat__head::after {
  content: "";
  position: absolute;
  width: 220px;
  aspect-ratio: 1;
  inset-inline-end: -70px;
  top: -110px;
  border-radius: 50%;
  background: repeating-radial-gradient(circle, rgba(255, 255, 255, 0.12) 0 3px, transparent 3px 22px);
  pointer-events: none;
}
.chat__avatar {
  width: 44px;
  height: 44px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: #fff;
  padding: 5px;
}
.chat__heading { flex: 1; min-width: 0; }
.chat__title { font-size: 1rem; font-weight: 800; line-height: 1.35; }
.chat__subtitle { font-size: var(--fs-xs); color: rgba(255, 255, 255, 0.82); line-height: 1.5; }
.chat__badge {
  display: inline-block;
  padding: 0 0.5rem;
  border-radius: 999px;
  background: rgba(118, 192, 67, 0.3);
  color: #e0ffc9;
  font-weight: 700;
}
.chat__close {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  transition: background-color 0.3s, transform 0.4s var(--ease);
}
.chat__close:hover { background: rgba(255, 255, 255, 0.24); transform: rotate(90deg); }

.chat__body {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  background:
    radial-gradient(20rem 14rem at 100% 0%, rgba(46, 81, 162, 0.06), transparent 70%),
    radial-gradient(20rem 14rem at 0% 100%, rgba(118, 192, 67, 0.09), transparent 70%),
    #f7fafc;
}
.msg {
  max-width: 88%;
  padding: 0.8rem 1rem;
  border-radius: 18px;
  font-size: var(--fs-s);
  line-height: 1.75;
}
.msg p + p { margin-top: 0.4rem; }
.msg__strong { font-weight: 800; color: var(--blue-deep); }
.msg--bot {
  align-self: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  border-end-start-radius: 6px;
  box-shadow: var(--shadow-s);
}
.msg--user {
  align-self: flex-end;
  color: #fff;
  background: var(--blue);
  border-end-end-radius: 6px;
}
.msg--typing { display: inline-flex; gap: 4px; padding: 0.9rem 1rem; }
.msg--typing span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--blue);
  opacity: 0.4;
  animation: typing 1s infinite;
}
.msg--typing span:nth-child(2) { animation-delay: 0.15s; }
.msg--typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes typing { 50% { opacity: 1; transform: translateY(-3px); } }

.chat__topics-label { font-size: var(--fs-xs); font-weight: 700; color: var(--muted); margin-top: 0.25rem; }
.chat__topics { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chat__topic {
  min-height: 40px;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  border: 1.5px solid rgba(46, 81, 162, 0.25);
  background: #fff;
  color: var(--blue);
  font-size: var(--fs-xs);
  font-weight: 700;
  transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}
.chat__topic:hover { background: var(--blue); color: #fff; border-color: var(--blue); }
.chat__topic[aria-disabled="true"] { opacity: 0.45; pointer-events: none; }

.chat__foot { padding: 0.85rem 1rem 1rem; border-top: 1px solid var(--line); background: #fff; }
.chat__form { display: flex; gap: 0.5rem; }
.chat__input {
  flex: 1;
  min-width: 0;
  min-height: 46px;
  padding: 0 1rem;
  border-radius: 999px;
  border: 1.5px solid var(--line-strong);
  background: #f3f6f9;
  font-size: var(--fs-s);
}
.chat__input:disabled { cursor: not-allowed; }
.chat__send {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  flex: none;
  border-radius: 50%;
  color: #fff;
  background: var(--blue);
}
.chat__send:disabled { opacity: 0.4; cursor: not-allowed; }
.chat__expert {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  margin-top: 0.6rem;
  border-radius: 999px;
  font-size: var(--fs-s);
  font-weight: 700;
  color: var(--green);
  background: rgba(118, 192, 67, 0.12);
  transition: background-color 0.3s;
}
.chat__expert:hover { background: rgba(118, 192, 67, 0.22); }

/* ------------------------------------------------------------------ 22. Toast & lightbox */
.toast {
  position: fixed;
  z-index: 150;
  left: 50%;
  bottom: calc(1.5rem + env(safe-area-inset-bottom));
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: max-content;
  max-width: calc(100vw - 2rem);
  padding: 0.7rem 0.7rem 0.7rem 1rem;
  border-radius: 18px;
  color: #fff;
  background: #10233f;
  box-shadow: var(--shadow-l);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 24px);
  transition: opacity 0.4s var(--ease), transform 0.6s var(--ease), visibility 0s linear 0.6s;
}
.toast.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
  transition: opacity 0.4s var(--ease), transform 0.6s var(--ease), visibility 0s;
}
.toast.is-error .toast__icon { background: #c2412d; }
.toast__icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  flex: none;
  border-radius: 50%;
  background: var(--green);
}
.toast__msg { font-size: var(--fs-s); line-height: 1.6; max-width: 46ch; }
.toast__close {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: 50%;
  transition: background-color 0.3s;
}
.toast__close:hover { background: rgba(255, 255, 255, 0.12); }

.lightbox {
  width: min(1100px, calc(100vw - 2rem));
  max-width: none;
  max-height: calc(100vh - 2rem);
  padding: 0;
  border: 0;
  border-radius: var(--radius-l);
  background: #0c1d36;
  color: #fff;
  overflow: hidden;
  box-shadow: var(--shadow-l);
}
.lightbox[open] { animation: lightbox-in 0.5s var(--ease); }
.lightbox::backdrop {
  background: rgba(6, 16, 32, 0.82);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
@keyframes lightbox-in {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}
.lightbox__figure { display: grid; }
.lightbox__img {
  width: 100%;
  max-height: calc(100vh - 10rem);
  object-fit: contain;
  background: #081426;
}
.lightbox__caption { display: grid; gap: 0.25rem; padding: 1.1rem 1.5rem 1.3rem; }
.lightbox__title { font-size: 1.1rem; font-weight: 800; }
.lightbox__text { font-size: var(--fs-s); color: rgba(255, 255, 255, 0.75); }
.lightbox__close {
  position: absolute;
  z-index: 2;
  top: 0.75rem;
  inset-inline-end: 0.75rem;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  color: #fff;
  background: rgba(6, 16, 32, 0.55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: background-color 0.3s, transform 0.4s var(--ease);
}
.lightbox__close:hover { background: rgba(6, 16, 32, 0.85); transform: rotate(90deg); }

/* ------------------------------------------------------------------ 23. Reveal / motion utilities */
.js [data-reveal] {
  opacity: 0;
  transform: translate3d(0, 34px, 0);
}
.js:not(.has-gsap) [data-reveal] {
  transition: opacity 0.9s var(--ease), transform 1s var(--ease);
  transition-delay: calc(var(--d, 0) * 90ms);
}
.js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* ------------------------------------------------------------------ 24. Scroll-driven animations (progressive) */
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .header__progress {
      transform: scaleX(0);
      animation: progress-grow linear both;
      animation-timeline: scroll(root block);
    }
    @keyframes progress-grow {
      from { transform: scaleX(0); }
      to   { transform: scaleX(1); }
    }
  }
}

@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .product__media img {
      animation: media-settle linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 45%;
    }
    @keyframes media-settle {
      from { scale: 1.18; }
      to   { scale: 1; }
    }
    .service__num {
      animation: num-slide linear both;
      animation-timeline: view();
      animation-range: entry 10% cover 50%;
    }
    @keyframes num-slide {
      from { translate: 0 18px; opacity: 0.2; }
      to   { translate: 0 0; opacity: 1; }
    }
  }
}

/* ------------------------------------------------------------------ 25. Responsive */
@media (min-width: 760px) {
  .section-head--split { grid-template-columns: 1.15fr 1fr; }
  .about__pillars { grid-template-columns: 1fr 1fr; }
  .cta-band__box { grid-template-columns: 1.4fr auto; }
  .cta-band__actions { flex-direction: column; align-items: stretch; }
}

@media (min-width: 960px) {
  .about__grid { grid-template-columns: 1fr 1.05fr; }
  .why__grid { grid-template-columns: 0.9fr 1.1fr; }
  .why__intro { position: sticky; top: calc(var(--header-h) + 2rem); }
  .faq__grid { grid-template-columns: 0.8fr 1.2fr; }
  .faq__intro { position: sticky; top: calc(var(--header-h) + 2rem); }
  .contact__grid { grid-template-columns: 0.9fr 1.1fr; }
}

@media (max-width: 1140px) {
  .nav { display: none; }
  .burger { display: inline-block; }
  .header__tools { margin-inline-start: auto; }
}

@media (max-width: 900px) {
  .gallery {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: clamp(180px, 34vw, 260px);
    grid-template-areas:
      "a a"
      "b c"
      "b d"
      "e e"
      "f f";
  }
  .tile__text { max-height: 5em; opacity: 1; transform: none; }
  .partners__figure { aspect-ratio: 16 / 8; }
  .partner:nth-child(odd) { border-inline-start: 0; }
  .partner:nth-child(n + 3) { border-top: 1px solid var(--line); }
}

@media (max-width: 680px) {
  :root { --header-h: 68px; }
  .header__cta { display: none; }
  .lang__btn { min-width: 38px; min-height: 40px; padding-inline: 0.45rem; }

  .header__inner {
    gap: 0.5rem;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .header__tools {
    flex: 0 0 auto;
    margin-inline-start: auto;
    gap: 0.4rem;
  }
  /* Mobile header: only the square mark — text was pushing past the viewport edge */
  .header .brand {
    gap: 0;
    flex: 0 0 auto;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
  }
  .header .brand__text { display: none; }
  .header .brand__mark {
    width: 36px;
    height: 36px;
    max-width: 36px;
    max-height: 36px;
  }
  /* Decorative ripples with negative offsets expand scroll width on mobile */
  .ripple--hero,
  .ripple--footer,
  .ripple--deco,
  .ripple--menu {
    display: none !important;
  }

  .hero { padding-bottom: clamp(5.5rem, 14vh, 7rem); }
  .hero__scroll { display: none; }
  .hero__actions .btn { flex: 1 1 100%; }
  .hero__brand { font-size: clamp(2.35rem, 11.5vw, 3.6rem); }
  /* No scaled ken-burns on mobile — scaled hero images were expanding page width */
  .hero__slide img {
    transform: none !important;
    animation: none !important;
  }

  .about__media { padding-inline-end: 8%; padding-bottom: 22%; overflow: hidden; }
  .about__img--sub { width: 56%; }
  .about__img--main img,
  .why__figure img { transform: none !important; }

  .gallery {
    grid-template-columns: 1fr;
    grid-auto-rows: auto;
    grid-template-areas: "a" "b" "c" "d" "e" "f";
  }
  .tile:not(.tile--cta) { aspect-ratio: 4 / 3; }
  .tile--b { aspect-ratio: 4 / 5 !important; }

  .partners__list { grid-template-columns: 1fr; }
  .partner { border-inline-start: 0 !important; }
  .partner + .partner { border-top: 1px solid var(--line); }

  .acc-item__inner p { padding-inline-end: 0; }
  .form__submit { width: 100%; }

  .chat {
    right: max(0.85rem, env(safe-area-inset-right));
    left: auto;
    bottom: calc(1rem + env(safe-area-inset-bottom));
    max-width: calc(100vw - 1.7rem);
  }
  html[dir="rtl"] .chat {
    left: max(0.85rem, env(safe-area-inset-left));
    right: auto;
  }
  .chat__launcher {
    padding: 0.3rem !important;
    min-height: 56px;
    min-width: 56px;
  }
  .chat__launcher-label { display: none; }
  .chat__launcher-icon { width: 50px; height: 50px; }
  .chat__panel {
    width: min(390px, calc(100vw - 1.7rem));
    max-height: calc(100svh - 6.25rem - env(safe-area-inset-bottom));
  }

  .toast { bottom: calc(5.5rem + env(safe-area-inset-bottom)); }
}

@media (max-width: 400px) {
  .header__tools { gap: 0.35rem; }
  .brand__name { font-size: 0.82rem; letter-spacing: 0.04em; }
  .lang__btn { min-width: 34px; padding-inline: 0.35rem; }
}

@media (hover: none) {
  .tile__text { max-height: 5em; opacity: 1; transform: none; }
  .tile__zoom { opacity: 1; transform: none; }
}

/* ------------------------------------------------------------------ 26. Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
  .hero__slide img { animation: none; transform: scale(1.04); }
  .marquee { -webkit-mask-image: none; mask-image: none; }
  .marquee__track { animation: none; width: auto; flex-wrap: wrap; justify-content: center; }
  .marquee__group { flex-wrap: wrap; justify-content: center; row-gap: 1rem; }
  .marquee__group[aria-hidden="true"] { display: none; }
  .kinetic__line { width: auto; flex-wrap: wrap; }
  .kinetic__line[data-kinetic="-1"] { margin-inline-start: 0; }
  .chat__pulse { display: none; }
}
