@redneckz/wildless-cms-uni-blocks 0.12.3 → 0.12.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (326) hide show
  1. package/bin/migration-scripts/0.12.3.js +2 -0
  2. package/bin/migration-scripts/0.9.10.js +1 -1
  3. package/bundle/bundle.umd.js +43 -77
  4. package/bundle/bundle.umd.min.js +1 -1
  5. package/bundle/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  6. package/bundle/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
  7. package/bundle/components/BenefitsBlock/benefitImageStyles.mobile.d.ts +1 -0
  8. package/bundle/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
  9. package/bundle/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.d.ts +1 -0
  10. package/bundle/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
  11. package/bundle/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.d.ts +1 -0
  12. package/bundle/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
  13. package/bundle/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
  14. package/bundle/components/BonusBenefitsBlock/renderBonusBenefits.mobile.d.ts +4 -0
  15. package/bundle/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
  16. package/bundle/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
  17. package/bundle/components/CarouselProgramsCard/programCardStyles.mobile.d.ts +2 -0
  18. package/bundle/components/Tabs/tabItemClasses.d.ts +2 -3
  19. package/dist/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  20. package/dist/components/BenefitsBlock/BenefitsBlock.js +4 -6
  21. package/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
  22. package/dist/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
  23. package/dist/components/BenefitsBlock/benefitImageStyles.js +4 -0
  24. package/dist/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
  25. package/dist/components/BenefitsBlock/benefitImageStyles.mobile.d.ts +1 -0
  26. package/dist/components/BenefitsBlock/benefitImageStyles.mobile.js +4 -0
  27. package/dist/components/BenefitsBlock/benefitImageStyles.mobile.js.map +1 -0
  28. package/dist/components/Blocks.mobile.js +6 -0
  29. package/dist/components/Blocks.mobile.js.map +1 -1
  30. package/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
  31. package/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
  32. package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
  33. package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js +4 -0
  34. package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
  35. package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.d.ts +1 -0
  36. package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js +4 -0
  37. package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js.map +1 -0
  38. package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
  39. package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js +4 -0
  40. package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
  41. package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.d.ts +1 -0
  42. package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js +4 -0
  43. package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js.map +1 -0
  44. package/dist/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
  45. package/dist/components/BonusBenefitsBlock/renderBonusBenefit.js +11 -0
  46. package/dist/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
  47. package/dist/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
  48. package/dist/components/BonusBenefitsBlock/renderBonusBenefits.js +20 -0
  49. package/dist/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
  50. package/dist/components/BonusBenefitsBlock/renderBonusBenefits.mobile.d.ts +4 -0
  51. package/dist/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js +8 -0
  52. package/dist/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js.map +1 -0
  53. package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
  54. package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  55. package/dist/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
  56. package/dist/components/CarouselCatalogCard/CatalogCard.js +20 -0
  57. package/dist/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
  58. package/dist/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
  59. package/dist/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  60. package/dist/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
  61. package/dist/components/CarouselProgramsCard/programCardStyles.js +5 -0
  62. package/dist/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
  63. package/dist/components/CarouselProgramsCard/programCardStyles.mobile.d.ts +2 -0
  64. package/dist/components/CarouselProgramsCard/programCardStyles.mobile.js +5 -0
  65. package/dist/components/CarouselProgramsCard/programCardStyles.mobile.js.map +1 -0
  66. package/dist/components/Tabs/LinkTab.js +2 -1
  67. package/dist/components/Tabs/LinkTab.js.map +1 -1
  68. package/dist/components/Tabs/Tabs.js +3 -2
  69. package/dist/components/Tabs/Tabs.js.map +1 -1
  70. package/dist/components/Tabs/renderGroupTab.js +7 -13
  71. package/dist/components/Tabs/renderGroupTab.js.map +1 -1
  72. package/dist/components/Tabs/tabItemClasses.d.ts +2 -3
  73. package/dist/components/Tabs/tabItemClasses.js +10 -46
  74. package/dist/components/Tabs/tabItemClasses.js.map +1 -1
  75. package/dist/components/TariffsTable/TariffsTable.mobile.js +0 -1
  76. package/dist/components/TariffsTable/TariffsTable.mobile.js.map +1 -1
  77. package/dist/ui-kit/PhoneInput/PhoneInput.js +1 -1
  78. package/dist/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  79. package/lib/common.css +1 -1
  80. package/lib/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  81. package/lib/components/BenefitsBlock/BenefitsBlock.fixture.mobile.d.ts +6 -0
  82. package/lib/components/BenefitsBlock/BenefitsBlock.js +4 -6
  83. package/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
  84. package/lib/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
  85. package/lib/components/BenefitsBlock/benefitImageStyles.js +2 -0
  86. package/lib/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
  87. package/lib/components/BenefitsBlock/benefitImageStyles.mobile.d.ts +1 -0
  88. package/lib/components/BenefitsBlock/benefitImageStyles.mobile.js +2 -0
  89. package/lib/components/BenefitsBlock/benefitImageStyles.mobile.js.map +1 -0
  90. package/lib/components/Blocks.mobile.js +6 -0
  91. package/lib/components/Blocks.mobile.js.map +1 -1
  92. package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.fixture.mobile.d.ts +7 -0
  93. package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
  94. package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
  95. package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
  96. package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js +2 -0
  97. package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
  98. package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.d.ts +1 -0
  99. package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js +2 -0
  100. package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js.map +1 -0
  101. package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
  102. package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js +2 -0
  103. package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
  104. package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.d.ts +1 -0
  105. package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js +2 -0
  106. package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js.map +1 -0
  107. package/lib/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +2 -0
  108. package/lib/components/BonusBenefitsBlock/renderBonusBenefit.js +8 -0
  109. package/lib/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
  110. package/lib/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
  111. package/lib/components/BonusBenefitsBlock/renderBonusBenefits.js +17 -0
  112. package/lib/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
  113. package/lib/components/BonusBenefitsBlock/renderBonusBenefits.mobile.d.ts +3 -0
  114. package/lib/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js +5 -0
  115. package/lib/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js.map +1 -0
  116. package/lib/components/CarouselCatalogCard/CarouselCatalogCard.fixture.d.ts +0 -11
  117. package/lib/components/CarouselCatalogCard/CarouselCatalogCard.fixture.mobile.d.ts +6 -0
  118. package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
  119. package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  120. package/lib/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
  121. package/lib/components/CarouselCatalogCard/CatalogCard.js +18 -0
  122. package/lib/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
  123. package/lib/components/CarouselProgramsCard/CarouselProgramsCard.fixture.d.ts +0 -1
  124. package/lib/components/CarouselProgramsCard/CarouselProgramsCard.fixture.mobile.d.ts +7 -0
  125. package/lib/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
  126. package/lib/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  127. package/lib/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
  128. package/lib/components/CarouselProgramsCard/programCardStyles.js +3 -0
  129. package/lib/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
  130. package/lib/components/CarouselProgramsCard/programCardStyles.mobile.d.ts +2 -0
  131. package/lib/components/CarouselProgramsCard/programCardStyles.mobile.js +3 -0
  132. package/lib/components/CarouselProgramsCard/programCardStyles.mobile.js.map +1 -0
  133. package/lib/components/Tabs/LinkTab.js +3 -2
  134. package/lib/components/Tabs/LinkTab.js.map +1 -1
  135. package/lib/components/Tabs/Tabs.fixture.mobile.d.ts +8 -0
  136. package/lib/components/Tabs/Tabs.js +3 -2
  137. package/lib/components/Tabs/Tabs.js.map +1 -1
  138. package/lib/components/Tabs/renderGroupTab.d.ts +0 -1
  139. package/lib/components/Tabs/renderGroupTab.js +9 -15
  140. package/lib/components/Tabs/renderGroupTab.js.map +1 -1
  141. package/lib/components/Tabs/renderTab.d.ts +0 -1
  142. package/lib/components/Tabs/tabItemClasses.d.ts +2 -3
  143. package/lib/components/Tabs/tabItemClasses.js +8 -43
  144. package/lib/components/Tabs/tabItemClasses.js.map +1 -1
  145. package/lib/components/TariffsTable/TariffsTable.mobile.js +0 -1
  146. package/lib/components/TariffsTable/TariffsTable.mobile.js.map +1 -1
  147. package/lib/ui-kit/PhoneInput/PhoneInput.js +1 -1
  148. package/lib/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  149. package/mobile/bundle/bundle.umd.js +507 -335
  150. package/mobile/bundle/bundle.umd.min.js +1 -1
  151. package/mobile/bundle/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  152. package/mobile/bundle/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
  153. package/mobile/bundle/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
  154. package/mobile/bundle/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
  155. package/mobile/bundle/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
  156. package/mobile/bundle/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
  157. package/mobile/bundle/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
  158. package/mobile/bundle/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
  159. package/mobile/bundle/components/Tabs/tabItemClasses.d.ts +2 -3
  160. package/mobile/dist/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  161. package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js +4 -6
  162. package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
  163. package/mobile/dist/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
  164. package/mobile/dist/components/BenefitsBlock/benefitImageStyles.js +4 -0
  165. package/mobile/dist/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
  166. package/mobile/dist/components/Blocks.js +6 -0
  167. package/mobile/dist/components/Blocks.js.map +1 -1
  168. package/mobile/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
  169. package/mobile/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
  170. package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
  171. package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js +4 -0
  172. package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
  173. package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
  174. package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js +4 -0
  175. package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
  176. package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
  177. package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefit.js +11 -0
  178. package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
  179. package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
  180. package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefits.js +8 -0
  181. package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
  182. package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
  183. package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  184. package/mobile/dist/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
  185. package/mobile/dist/components/CarouselCatalogCard/CatalogCard.js +20 -0
  186. package/mobile/dist/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
  187. package/mobile/dist/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
  188. package/mobile/dist/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  189. package/mobile/dist/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
  190. package/mobile/dist/components/CarouselProgramsCard/programCardStyles.js +5 -0
  191. package/mobile/dist/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
  192. package/mobile/dist/components/Tabs/LinkTab.js +2 -1
  193. package/mobile/dist/components/Tabs/LinkTab.js.map +1 -1
  194. package/mobile/dist/components/Tabs/Tabs.js +3 -2
  195. package/mobile/dist/components/Tabs/Tabs.js.map +1 -1
  196. package/mobile/dist/components/Tabs/renderGroupTab.js +7 -13
  197. package/mobile/dist/components/Tabs/renderGroupTab.js.map +1 -1
  198. package/mobile/dist/components/Tabs/tabItemClasses.d.ts +2 -3
  199. package/mobile/dist/components/Tabs/tabItemClasses.js +10 -46
  200. package/mobile/dist/components/Tabs/tabItemClasses.js.map +1 -1
  201. package/mobile/dist/components/TariffsTable/TariffsTable.js +0 -1
  202. package/mobile/dist/components/TariffsTable/TariffsTable.js.map +1 -1
  203. package/mobile/dist/ui-kit/PhoneInput/PhoneInput.js +1 -1
  204. package/mobile/dist/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  205. package/mobile/lib/common.css +1 -1
  206. package/mobile/lib/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  207. package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js +4 -6
  208. package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
  209. package/mobile/lib/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
  210. package/mobile/lib/components/BenefitsBlock/benefitImageStyles.js +2 -0
  211. package/mobile/lib/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
  212. package/mobile/lib/components/Blocks.js +6 -0
  213. package/mobile/lib/components/Blocks.js.map +1 -1
  214. package/mobile/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
  215. package/mobile/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
  216. package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
  217. package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js +2 -0
  218. package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
  219. package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
  220. package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js +2 -0
  221. package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
  222. package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
  223. package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefit.js +8 -0
  224. package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
  225. package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
  226. package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefits.js +5 -0
  227. package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
  228. package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
  229. package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
  230. package/mobile/lib/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
  231. package/mobile/lib/components/CarouselCatalogCard/CatalogCard.js +18 -0
  232. package/mobile/lib/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
  233. package/mobile/lib/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
  234. package/mobile/lib/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
  235. package/mobile/lib/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
  236. package/mobile/lib/components/CarouselProgramsCard/programCardStyles.js +3 -0
  237. package/mobile/lib/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
  238. package/mobile/lib/components/Tabs/LinkTab.js +3 -2
  239. package/mobile/lib/components/Tabs/LinkTab.js.map +1 -1
  240. package/mobile/lib/components/Tabs/Tabs.js +3 -2
  241. package/mobile/lib/components/Tabs/Tabs.js.map +1 -1
  242. package/mobile/lib/components/Tabs/renderGroupTab.js +9 -15
  243. package/mobile/lib/components/Tabs/renderGroupTab.js.map +1 -1
  244. package/mobile/lib/components/Tabs/tabItemClasses.d.ts +2 -3
  245. package/mobile/lib/components/Tabs/tabItemClasses.js +8 -43
  246. package/mobile/lib/components/Tabs/tabItemClasses.js.map +1 -1
  247. package/mobile/lib/components/TariffsTable/TariffsTable.js +0 -1
  248. package/mobile/lib/components/TariffsTable/TariffsTable.js.map +1 -1
  249. package/mobile/lib/ui-kit/PhoneInput/PhoneInput.js +1 -1
  250. package/mobile/lib/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
  251. package/mobile/src/common.css +3 -0
  252. package/mobile/src/components/BenefitsBlock/BenefitsBlock.tsx +37 -34
  253. package/mobile/src/components/BenefitsBlock/benefitImageStyles.tsx +1 -0
  254. package/mobile/src/components/Blocks.ts +6 -0
  255. package/mobile/src/components/BonusBenefitsBlock/BonusBenefitsBlock.tsx +13 -49
  256. package/mobile/src/components/BonusBenefitsBlock/bonusBenefitAlign.ts +1 -0
  257. package/mobile/src/components/BonusBenefitsBlock/bonusBenefitStyles.ts +1 -0
  258. package/mobile/src/components/BonusBenefitsBlock/renderBonusBenefit.tsx +29 -0
  259. package/mobile/src/components/BonusBenefitsBlock/renderBonusBenefits.tsx +14 -0
  260. package/mobile/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +3 -3
  261. package/mobile/src/components/CarouselCatalogCard/CatalogCard.ts +22 -0
  262. package/mobile/src/components/CarouselInvestmentCard/CarouselInvestmentCard.example.json +1 -11
  263. package/mobile/src/components/CarouselProductCard/CarouselProductCard.example.json +1 -11
  264. package/mobile/src/components/CarouselProgramsCard/CarouselProgramsCard.tsx +21 -11
  265. package/mobile/src/components/CarouselProgramsCard/programCardStyles.ts +2 -0
  266. package/mobile/src/components/CarouselRecommendationCard/CarouselRecommendationCard.example.json +1 -12
  267. package/mobile/src/components/ErrorBlock/ErrorBlock.example.json +1 -11
  268. package/mobile/src/components/MobileAppTile/MobileAppTile.example.json +1 -11
  269. package/mobile/src/components/PictureText/PictureText.example.json +1 -11
  270. package/mobile/src/components/ProductBlock/ProductBlock.example.json +1 -11
  271. package/mobile/src/components/ProductTile/ProductTile.example.json +4 -12
  272. package/mobile/src/components/Tabs/LinkTab.tsx +19 -8
  273. package/mobile/src/components/Tabs/Tabs.tsx +7 -4
  274. package/mobile/src/components/Tabs/renderGroupTab.tsx +21 -33
  275. package/mobile/src/components/Tabs/tabItemClasses.ts +12 -45
  276. package/mobile/src/components/TariffsTable/TariffsTable.tsx +0 -1
  277. package/mobile/src/components/Tile/Tile.example.json +1 -11
  278. package/mobile/src/ui-kit/PhoneInput/PhoneInput.tsx +5 -1
  279. package/package.json +1 -1
  280. package/src/common.css +3 -0
  281. package/src/components/BenefitsBlock/BenefitsBlock.fixture.mobile.tsx +43 -0
  282. package/src/components/BenefitsBlock/BenefitsBlock.fixture.tsx +0 -1
  283. package/src/components/BenefitsBlock/BenefitsBlock.tsx +37 -34
  284. package/src/components/BenefitsBlock/benefitImageStyles.mobile.tsx +1 -0
  285. package/src/components/BenefitsBlock/benefitImageStyles.tsx +1 -0
  286. package/src/components/Blocks.mobile.ts +6 -0
  287. package/src/components/BonusBenefitsBlock/BonusBenefitsBlock.fixture.mobile.tsx +67 -0
  288. package/src/components/BonusBenefitsBlock/BonusBenefitsBlock.tsx +13 -49
  289. package/src/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.ts +1 -0
  290. package/src/components/BonusBenefitsBlock/bonusBenefitAlign.ts +1 -0
  291. package/src/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.ts +1 -0
  292. package/src/components/BonusBenefitsBlock/bonusBenefitStyles.ts +1 -0
  293. package/src/components/BonusBenefitsBlock/renderBonusBenefit.tsx +29 -0
  294. package/src/components/BonusBenefitsBlock/renderBonusBenefits.mobile.tsx +14 -0
  295. package/src/components/BonusBenefitsBlock/renderBonusBenefits.tsx +27 -0
  296. package/src/components/Carousel/Carousel.fixture.tsx +13 -2
  297. package/src/components/CarouselCatalogCard/CarouselCatalogCard.fixture.mobile.tsx +23 -0
  298. package/src/components/CarouselCatalogCard/CarouselCatalogCard.fixture.tsx +3 -25
  299. package/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +3 -3
  300. package/src/components/CarouselCatalogCard/CatalogCard.ts +22 -0
  301. package/src/components/CarouselInvestmentCard/CarouselInvestmentCard.example.json +1 -11
  302. package/src/components/CarouselProductCard/CarouselProductCard.example.json +1 -11
  303. package/src/components/CarouselProgramsCard/CarouselProgramsCard.fixture.mobile.tsx +34 -0
  304. package/src/components/CarouselProgramsCard/CarouselProgramsCard.fixture.tsx +2 -7
  305. package/src/components/CarouselProgramsCard/CarouselProgramsCard.tsx +21 -11
  306. package/src/components/CarouselProgramsCard/programCardStyles.mobile.ts +2 -0
  307. package/src/components/CarouselProgramsCard/programCardStyles.ts +2 -0
  308. package/src/components/CarouselRecommendationCard/CarouselRecommendationCard.example.json +1 -12
  309. package/src/components/ErrorBlock/ErrorBlock.example.json +1 -11
  310. package/src/components/MobileAppTile/MobileAppTile.example.json +1 -11
  311. package/src/components/PictureText/PictureText.example.json +1 -11
  312. package/src/components/PictureText/PictureText.fixture.mobile.tsx +0 -6
  313. package/src/components/PictureText/PictureText.fixture.tsx +0 -6
  314. package/src/components/ProductBlock/ProductBlock.example.json +1 -11
  315. package/src/components/ProductBlock/ProductBlock.fixture.mobile.tsx +0 -6
  316. package/src/components/ProductTile/ProductTile.example.json +4 -12
  317. package/src/components/Tabs/LinkTab.tsx +19 -8
  318. package/src/components/Tabs/Tabs.fixture.mobile.tsx +55 -0
  319. package/src/components/Tabs/Tabs.fixture.tsx +8 -17
  320. package/src/components/Tabs/Tabs.tsx +7 -4
  321. package/src/components/Tabs/renderGroupTab.tsx +21 -33
  322. package/src/components/Tabs/tabItemClasses.ts +12 -45
  323. package/src/components/TariffsTable/TariffsTable.mobile.tsx +0 -1
  324. package/src/components/Tile/Tile.example.json +1 -11
  325. package/src/ui-kit/PhoneInput/PhoneInput.tsx +5 -1
  326. package/tailwind.config.cjs +25 -12
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniBlocks={})}(this,(function(e){"use strict";let t;const l=e=>(...l)=>t[e](...l),n=l("useState"),a=l("useEffect"),i=l("useCallback"),r=l("useMemo"),s=l("useRef");const o=e=>e&&!e.endsWith("/")?`${e}/`:e,c={PROD_BRANCH:"master"},d=new class{_=c;setup(e){this._=e}get TEST_BRANCH(){return this._.TEST_BRANCH}get RC_BRANCH(){return this._.RC_BRANCH}get PROD_BRANCH(){return this._.PROD_BRANCH||c.PROD_BRANCH}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ASSIST_PROJECT_ID(){return this._.ASSIST_PROJECT_ID}get SITEMAP(){return this._.SITEMAP}get FOOTER(){return this._.FOOTER}get CHAT_BOT(){return this._.CHAT_BOT}get CDN(){return o(this._.CDN)}get BASE_PATH(){return o(this._.BASE_PATH)}get YANDEX_MAP_API_KEY(){return this._.YANDEX_MAP_API_KEY}get YANDEX_METRIKA_ID(){return this._.YANDEX_METRIKA_ID}},m="likesToken";function h(){async function e(){try{const e=JSON.parse(globalThis.localStorage?.getItem(m)||"");if(e?.token)return e}catch(e){}try{const e=await fetch("/assist/v1/public/auth",{method:"POST",mode:"cors",headers:{"Content-Type":"application/json"},body:JSON.stringify({prefix:"guest"})}),{token:t,name:l}=await e.json();return globalThis.localStorage?.setItem(m,JSON.stringify({token:t,name:l})),{token:t,name:l}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...t){if(!t.length)return[];const{token:l}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l},body:JSON.stringify({node_ids:t})}),{likes:n}=await e.json();return n||[]}catch(e){return console.error(e),[]}},like:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}},dislike:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}}}}const u=(...e)=>globalThis._uni._jsx(...e),p=(...e)=>globalThis._uni._jsxs(...e),x=e=>{const t=e;return t._tmpl||(t._tmpl=globalThis.__UNI_REACT__?e:g(e)),t._tmpl},g=e=>{function t(t,l){const{children:n,...a}=t||{},i=l?.slots?.default,r=n||i&&i();return e(Object.assign(a,r&&{children:r}),l)}return t.inheritAttrs=!1,t};class f{subscribers={};subjectsStateMap={};subscribe(e,t){this.subscribers[e]=(this.subscribers[e]||[]).concat(t);const l=this.subjectsStateMap[e];return l&&t(l),()=>{this.unsubscribe(e,t)}}unsubscribe(e,t){this.subscribers[e]=this.subscribers[e]?.filter((e=>e!==t))}fire(e,t){e in this.subjectsStateMap&&(this.subjectsStateMap[e]=t),this.subscribers[e]?.forEach((e=>e(t)))}subject(e,t){this.subjectsStateMap[e]=t}}const b=new f;function v(e,{sensitivity:t,rootRef:l}={}){const n=s(null),i=r((()=>({threshold:N(t),root:l?.current})),[t,l?.current]);return a((()=>{if(!n.current)return;const t=new IntersectionObserver(e,i);return t.observe(n.current),()=>{t.disconnect()}}),[e,i]),n}function N(e=0){const t=Math.round(10*e);return new Array(t).fill(0).map(((e,l)=>Math.min(l/t)),1).concat(1)}const y=new f;const w=(...e)=>e.flatMap((e=>e)).filter(Boolean).join(" "),k={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white",gray:"bg-main-divider text-primary-text",transparent:"bg-transparent text-primary-text","":""},C=x((({className:e,version:t="primary",isTheme:l=!0,defaultPadding:r="p-m",padding:s,block:o,tag:c="section",role:d,children:m})=>{const h=c,p=function(e){return v(i((t=>{if(!e||!t?.length)return;const l=t[t.length-1];y.fire("intersection",{block:e,intersection:l})}),[e]),{sensitivity:1})}(o),[x,g]=n(!1);a((()=>b.subscribe("tab",(e=>{g(Boolean(e.label&&o?.labels?.length&&!o.labels.includes(e.label)))}))),[o]);const f=t&&l;return u(h,{className:w("font-sans",f?"group":"",k[t],x?"hidden":"",s||r,e),...f?{"data-ver":t}:{},...o?.anchor?{id:o.anchor,ref:p}:{},role:d,children:m})})),S={h0:"text-h0",h1:"text-h1",h2:"text-h2",h3:"text-h3",h4:"text-h4",h5:"text-h5",h6:"text-h6"},I=x((({className:e="",headingType:t="h3",as:l="h3",title:n,children:a})=>u(l,{className:w("font-sans m-0",S[t],e),children:n||a}))),T=e=>e,B=(e,t)=>{const[l,a]=n(e),[r,o]=n(!1),[c,d]=n({}),m=s({}),h=i(((e,t)=>{const{parse:n=T,format:i=T}=t||{};return m.current||(m.current={}),m.current[e]||=t=>{a((l=>({...l,[e]:n(t)}))),d((t=>({...t,[e]:!0})))},{value:i(l[e]),isDirty:r||c[e],onChange:m.current[e]}}),[l,r,c]),u=i((()=>{a(e),o(!1),d({})}),[e]),p=i((e=>{e.preventDefault(),o(!0),t&&t(l)}),[t,l]);return[l,{isDirty:r||Object.values(c).some(Boolean),field:h,reset:u,onSubmit:p}]},R=e=>t=>t&&Object.entries(e).flatMap((([e,l])=>l(t[e])))||[],P=e=>!e?.length,$=e=>t=>l=>e(l)?[]:[t],M=e=>null!=e,_=new Map;function V(e,t,{fallback:l,cache:i}={}){const s=r((()=>j(e)),[e]),[o]=(e=>Boolean(e&&Array.isArray(e)&&1===e.length&&"string"==typeof e[0]))(s)?s:[],[c,d]=n(void 0),[m,h]=n(void 0);a((()=>{!s.some(M)||(async()=>{try{const e=await(o?((e,t=_)=>l=>{const n=t.get(l);if(M(n))return n;const a=e(l);return M(a)?t.set(l,Promise.resolve(a)):t.delete(l),a})(t,i)(o):t(...s));d(e),h(void 0)}catch(e){d(void 0),h(e)}})()}),[t,i,s]);const u=l&&o&&l[o];return{data:!c&&u?u:c,error:m,mutate:()=>Promise.resolve(void 0),isValidating:!1}}function j(e){return Array.isArray(e)?e:e instanceof Function?j(e()):[e]}async function z(e,t){try{return e?await D(e,t):null}catch(e){console.error(e)}return null}async function D(e,t){const l=await fetch(e,{...t,headers:{...t?.headers,"Content-Type":"application/json"}});return await l.json()}const L=[];function A(){const{data:e}=V("/api/v1/regions",D);return e||L}const O=(e="")=>({open:t=>b.fire("dialog",{type:"open",id:e,message:t}),close:()=>b.fire("dialog",{type:"close"})}),E=e=>Boolean(e?.includes(":")),F=(e,t)=>Boolean(e&&!E(e)&&(!t||"_self"===t)),U=e=>(e||"").replace(/\?.*/,"").replace(/\/$/,""),H=(...e)=>e.filter(Boolean).join("/").replace(/\/+/g,"/");var X=Object.freeze({__proto__:null,isURL:E,isLocalURL:F,isHash:e=>Boolean(e?.startsWith("#")),withoutQuery:U,joinPath:H});const W=e=>(t,l=d.BASE_PATH)=>{if(!t||E(t)||K(t,d.CDN))return t;const n=t.startsWith("/");return H(K(t,l)?"":l,n?"/":e.pathname?.split("/").slice(0,-1).join("/"),t)},K=(e,t)=>t&&e&&e.startsWith(t),G=(e,t)=>G._impl(e,t);function J(){return J._impl()}function Y(e={}){const{isRemote:t,basePath:l}=e,n=J(),{close:a}=O();return e=>({...e,href:t&&!l?e.href:W(n)(e.href,l),"aria-label":e.text,onClick:G(i(e),e)});function i({href:e,target:l,onClick:i}){return r=>{i&&i(r),e&&!t&&F(e,l)&&(a(),r?.preventDefault(),n.push(e))}}}G._impl=e=>e,G.setup=e=>{G._impl=e},J._impl=()=>({href:globalThis.location?.href||"/",pathname:globalThis.location?.pathname||"/",query:{},push:()=>{},replace:()=>{}}),J.setup=e=>{J._impl=e};const q={primary:"text-white bg-primary-main hover:bg-primary-hover active:bg-primary-active",secondary:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active",white:"text-primary-main bg-white hover:text-white hover:bg-primary-hover active:bg-white active:text-primary-main",link:"",transparent:"",gray:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active","":""},Z="bg-main-divider text-main-disabled",Q={primary:Z,secondary:Z,white:Z,link:"",transparent:"",gray:Z,"":""},ee="text-center font-sans select-none",te={primary:"group-hover/btn:brightness-0 group-hover/btn:invert",secondary:"group-hover/btn:brightness-0 group-hover/btn:invert",white:"group-hover/btn:brightness-0 group-hover/btn:invert",link:"",transparent:"",gray:"group-hover/btn:brightness-0 group-hover/btn:invert","":""},le=x((e=>{const{text:t,aboveText:l,appendLeft:n,appendRight:a,version:i="primary"}=e;return p("div",{className:w(ne(e),"flex gap-2"),children:[n?u("div",{className:te[i],children:n}):null,ae(e)?p("div",{children:[l?u("div",{className:"text-xs-light text-left",children:l}):null,u("div",{className:"text-left "+(l?"text-s -mt-0.5":"text-l"),children:t})]}):null,a?u("div",{className:te[i],children:a}):null]})})),ne=e=>{const{version:t,aboveText:l,rounded:n}=e;if("link"===t)return"";const a=""+(l?"py-2.5 px-9":"py-4 px-9");return["group/btn items-center justify-center",ae(e)?a:"h-12 w-12",n?"rounded-full":""].join(" ")},ae=({text:e,aboveText:t,appendLeft:l})=>Boolean(e||t||!l),ie=({className:e,rounded:t,version:l})=>["inline-block",ee,l?Q[l]:"",t?"rounded-full":"rounded-md",e].join(" "),re=({className:e,rounded:t,version:l})=>[ee,"border border-transparent inline-block cursor-pointer no-underline focus:border-primary-text focus:border h-fit",l?q[l]:"",t?"rounded-full":"rounded-md",e].join(" "),se=x((({disabled:e,children:t,...l})=>{const n=Y()(l),a=t??u(le,{...n});return u(e?ce:oe,{...n,children:a})})),oe=x((({className:e="",href:t,rel:l,target:n,ariaLabel:a,version:i,rounded:r,onClick:s,children:o})=>u("a",{className:re({className:e,version:i,rounded:r}),href:t,rel:l,target:n,"aria-label":a,role:t?"link":"button",onClick:s,children:o}))),ce=x((({className:e,ariaLabel:t,version:l,rounded:n,children:a})=>u("div",{role:"button","aria-disabled":"true","aria-label":t,tabIndex:-1,className:ie({className:e,rounded:n,version:l}),children:a}))),de=x((({children:e,...t})=>u("p",{className:["font-sans",...Object.values(t)].join(" "),children:e}))),me=x((({children:e,...t})=>u("span",{className:["font-sans",...Object.values(t)].join(" "),children:e}))),he=x((({link:e})=>p(de,{size:"text-s-light",color:"text-secondary-text",children:[u(me,{children:"Нажимая кнопку, вы подтверждаете согласие с "}),e?u(se,{href:e.href,ariaLabel:"условия передачи данных",target:e.target,className:"text-primary-main",children:u(me,{children:e.text})}):null]}))),ue=(e,t)=>{const{value:l,isDirty:n}=e,a=n?t(l):[];return{...e,errors:a,error:a[0]}},pe=x((({key:e,className:t="",inputClassName:l="",id:n,name:a,type:r="text",label:s,placeholder:o,value:c="",valid:d=!0,children:m,onChange:h,onFocus:x,onBlur:g,pattern:f})=>{const b=i((e=>{h&&h(e.target?.value||"")}),[h]),v=m?"pr-8":"",N=d?"border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text":"border-error";return p("div",{className:w("relative",t),children:[p("label",{children:[s?u("div",{className:"mb-2",children:u(me,{size:"text-m",font:"font-light",children:s})}):null,u("input",{className:w("w-full border rounded-md text-primary-text outline-none p-4",v,N,l),id:n,name:a||n,placeholder:o,type:r,value:c,onInput:b,onFocus:x,onBlur:g,pattern:f},e)]}),m]})})),xe=x((({className:e,label:t,value:l="",error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(pe,{type:"text","aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs-light",color:"text-error",children:n}):null})]}))),ge=e=>"_"===e,fe=e=>/\d/.test(e),be=e=>ge(e)||fe(e),ve=[..."+7 (___) ___-__-__"],Ne=ve.findIndex(ge),ye=ve.map(((e,t)=>be(e)?ve.slice(0,t).filter(be).length:-1));const we=x((({children:e,onChange:t,...l})=>{const n=i((e=>t&&t(function(e){const t=e.replace(/\D/g,""),l=ve.map(((e,l)=>fe(e)?e:t.charAt(ye[l])||e)),n=ye.indexOf(t.length-1)+1;return(n?l.slice(0,Math.max(Ne,n)):l).join("")}(e))),[t]);return u(pe,{onChange:n,onFocus:n,...l,children:e})})),ke=x((({className:e,label:t,value:l,error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(we,{"aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs-light",color:"text-error",children:n}):null})]}))),Ce="Некорректно заполненное поле",Se=$((e=>null!=e&&""!==e))(Ce),Ie=$((e=>"string"==typeof e&&e.length>1))(Ce),Te=$((e=>"string"==typeof e&&(10===e.length||12===e.length)))(Ce),Be=(Re=/^(\+7)?[\s-]?\(?[0-9]{3}\)?[\s-]?[0-9]{3}[\s-]?[0-9]{2}[\s-]?[0-9]{2}$/,$((e=>"string"==typeof e&&Re.test(e))))(Ce);var Re;const Pe=e=>p("div",{className:"flex justify-between gap-5 mb-5",children:[p("div",{className:"w-1/2",children:[u(xe,{className:"shrink-0 w-full mb-3",label:"Наименование организации",...ue(e("fullName"),Se)}),u(xe,{className:"shrink-0 w-full mb-3",label:"Контактное лицо",...ue(e("name"),Ie)})]}),p("div",{className:"w-1/2",children:[u(xe,{className:"shrink-0 w-full mb-3",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)})]})]}),$e=[{name:"Торговый эквайринг"},{name:"Мобильный эквайринг"},{name:"Интернет-эквайринг"},{name:"QR-эквайринг (СБП)"},{name:"Все виды эквайринга"}];function Me(e=!1){const[t,l]=n(e),a=i((()=>l(!0)),[]),r=i((()=>l(!1)),[]),s=i((()=>l((e=>!e))),[]);return[t,{setValue:l,setTrue:a,setFalse:r,toggle:s}]}function _e(e){const t=s(null);return a((()=>{const l=l=>{t&&t.current&&l.target instanceof Node&&!t.current.contains(l.target)&&e()};return document.addEventListener("click",l),()=>{document.removeEventListener("click",l)}}),[e]),t}const Ve={normal:"",color:"text-primary-main",black:"text-black",white:"text-black"},je=x((({className:e="",imageClassName:t="",name:l="",alt:n=`Иконка ${l}`,title:a=n,iconVersion:i="color",...r})=>{const s=J(),o=W(s)(H(d.CDN,"/icons",`${l}.svg`));return"normal"!==i?u(De,{className:e,children:p("svg",{className:w(ze(r.width),Ve[i],"white"===i?"invert":"",t),...r,"aria-hidden":"true",children:[a?u("title",{children:a}):null,n?u("desc",{children:n}):null,u("use",{href:`${o}#icon`,xlinkHref:`${o}#icon`})]})}):(e.includes("h-")||(r.style={height:`${r.height}px`}),u("img",{className:e,src:o,alt:n,title:a,"aria-hidden":"true",...r}))})),ze=e=>e?"":"w-full h-full",De=x((({className:e,children:t})=>e?u("div",{className:e,children:t}):t)),Le=x((({className:e="",label:t,options:l=[],value:n,valid:a=!0,isBorder:r=!0,placeholder:s="",onChange:o})=>{const[c,{setFalse:d,toggle:m}]=Me(),h=_e(d),x=i((e=>{d(),o&&o(e)}),[o]);return p("div",{className:e,ref:h,children:[t?u("div",{className:"mb-2",children:u(me,{size:"text-m",color:"text-primary-text",font:"font-light",children:t})}):null,p("div",{className:w("relative",c?"z-20":"z-10"),children:[p("div",{className:w("text-l flex justify-between items-center mb-0.5 text-primary-text cursor-pointer",Ee(r,a)),onClick:m,children:[u("p",{className:"p-4 pr-8 h-14 overflow-hidden text-ellipsis whitespace-nowrap",children:Oe(n)||s}),u(je,{className:w("absolute right-3",c?"":"rotate-180"),name:"ArrowUpIcon",width:"16",height:"16"})]}),l?.length?u("div",{className:w("h-0",c?"":"overflow-hidden"),children:u("div",{className:"bg-white text-l max-h-64 overflow-y-auto overflow-x-hidden rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]",children:l.map(Ae(x,c,(e=>e.key===n?.key)))})}):null]})]})})),Ae=(e,t,l)=>(n,a)=>p("div",{onClick:()=>{e(n)},className:"flex px-4 py-3 cursor-pointer hover:bg-main-divider pr-11 relative",children:[u("span",{className:"min-h-6",children:Oe(n)}),u(je,{name:"DoneSimpleIcon",width:"16",height:"16",className:w("absolute right-4 pt-0.5",l(n)&&t?"":"hidden")})]},String(a)),Oe=e=>e?.text||e?.key||"",Ee=(e,t)=>w(e?"border rounded-md hover:border-primary-hover":"",t?" border-gray":"border-error"),Fe=x((e=>p("div",{children:[u(Le,{...e,valid:!e.error}),u("div",{className:"h-2",children:e.error?u(me,{size:"text-xs-light",color:"text-error",children:e.error}):null})]}))),Ue=({regions:e,field:t})=>p("div",{className:"flex justify-between gap-5 mb-7",children:[u("div",{className:"w-1/2",children:u(Fe,{label:"Вид эквайринга",placeholder:"Выберите эквайринг",options:$e.map((({name:e=""})=>({key:e,text:e}))),...ue(t("acquiringType"),Se)})}),u("div",{className:"w-1/2",children:u(Fe,{label:"Адрес",placeholder:"Выберите адрес",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)})})]}),He=x((({value:e=!1,text:t,type:l="checkbox",onChange:n})=>p("div",{role:l,"aria-checked":e,className:"flex justify-start items-center w-full cursor-pointer mb-3",onClick:()=>n&&n(!e),children:[u("div",{className:w("relative flex-shrink-0 duration-300 w-9 h-5 mr-3 rounded-2xl",e?"bg-primary-main":"bg-main-divider"),children:u("div",{className:w("absolute opacity-80 duration-500 top-0.5 w-4 h-4 bg-white rounded-full",e?"left-[50%]":"left-[5%]")})}),u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:t})]}))),Xe=e=>p("div",{className:"mb-5",children:[u(He,{text:"Хочу купить онлайн-кассу",...e("onlineCheckout")}),u(He,{text:"Хочу купить POS-терминал",...e("posTerminal")})]}),We=(e,t)=>{const l=re({className:"text-white",version:e?.version});return u("button",{type:"submit",className:w("p-4",l,t),children:e?.text?e.text:"Отправить заявку"})},Ke={acquiringType:{key:"Торговый эквайринг"},fullName:"",inn:"",name:"",phone:"",onlineCheckout:!1,posTerminal:!1},Ge=R({acquiringType:Se,region:Se,fullName:Se,inn:Te,name:Ie,phone:Be}),Je=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{acquiringType:t,region:l,fullName:a,inn:i,name:r,phone:s,onlineCheckout:o,posTerminal:c}=e;P(Ge(e))&&n({typeForm:"acqr",region:l?.text||"",partnerComments:`Вид эквайринга=${t?.key||""}/Онлайн касса=${o}/POS-терминал=${c}`,fullName:a,inn:i,name:r,phone:s})}),[n]),[,{field:r,...s}]=B(Ke,a),o=A();return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Вид эквайринга и регион",className:"text-center mb-4"}),Ue({regions:o,field:r}),u(I,{headingType:"h6",title:"Данные организации",className:"text-center mb-4"}),Pe(r),Xe(r),We(t,"mb-4"),u(he,{link:l})]})})),Ye=e=>p("div",{className:"flex justify-between gap-5",children:[p("div",{className:"w-1/2",children:[u(xe,{className:"shrink-0 w-full mb-3",label:"Контактное лицо",...ue(e("name"),Ie)}),u(xe,{className:"shrink-0 w-full mb-3",label:"ИНН",...ue(e("inn"),Te)})]}),p("div",{className:"w-1/2",children:[u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)}),u(xe,{className:"shrink-0 w-full mb-3",label:"Электронная почта",...ue(e("mail"),Se)})]})]}),qe=({regions:e,field:t})=>u("div",{className:"flex justify-between gap-5 mb-5",children:u("div",{className:"w-full",children:u(Fe,{label:"Регион",placeholder:"Выберите регион",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)})})}),Ze={name:"",phone:"",inn:"",mail:""},Qe=R({region:Se,name:Ie,phone:Be,inn:Te,mail:Se}),et=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{region:t,name:l,phone:a,inn:i,mail:r}=e;P(Qe(e))&&n({typeForm:"bcrd",region:t?.text||"",name:l,phone:a,inn:i,mail:r})}),[n]),[,{field:r,...s}]=B(Ze,a),o=A();return p("form",{className:"container",onSubmit:s.onSubmit,children:[qe({regions:o,field:r}),Ye(r),We(t,"mb-4"),u(he,{link:l})]})})),tt=[];const lt=async e=>await z(e,{method:"GET"})||tt,nt=["От 1 000 ₽","До 1 000 000 000 ₽"],at=["От 1 мес","До 15 лет"],it=e=>p("div",{className:"flex justify-between gap-5 mb-7",children:[p("div",{className:"w-1/2",children:[u(xe,{className:"shrink-0 w-full mb-3",label:"Наименование организации",...e("fullName")}),u(xe,{className:"shrink-0 w-full mb-3",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)})]}),p("div",{className:"w-1/2",children:[u(xe,{className:"shrink-0 w-full mb-3",label:"Годовая выручка, ₽",...ue(e("annualRevenue"),Se)}),u(xe,{className:"shrink-0 w-full mb-3",label:"Контактное лицо",...ue(e("name"),Ie)}),u(xe,{className:"shrink-0 w-full mb-3",label:"Электронная почта",...e("mail")})]})]}),rt=(e,{normalize:t,format:l})=>{const{value:a,onFocus:r,onBlur:s,onChange:o}=e,[c,d]=n(!1),m=i((e=>{d(!0),r&&r(e)}),[]),h=i((()=>{d(!1),o&&o(t(a)),s&&s()}),[o,a]);return{value:c||!l?a:l(a),onFocus:m,onBlur:h}},st=(e,t,l)=>Math.max(t,Math.min(e,l)),ot=(e=0)=>(t=0)=>new Intl.NumberFormat("ru-RU",{minimumFractionDigits:0,maximumFractionDigits:e}).format(Number(t)||0);function ct(e){const t=(e||"").replace(/\D/g,""),l=parseInt(t,10);return Number.isNaN(l)?0:l}function dt({list:e=[],min:t,max:l,step:n,value:a=e[0]||t,disabled:i,onChange:r}){const s=e.length?e.indexOf(a):a,o={backgroundSize:`${(100*(s-t)/(l-t)).toFixed(2)}% 100%`};return p("div",{children:[e.length?u("div",{className:"absolute w-full flex justify-between -bottom-[3px] px-4",children:e.map(((e,t)=>u("div",{className:"w-2 h-2 rounded-full "+(s<=t||i?"bg-gray":"bg-primary-main")},String(t))))}):null,u("div",{className:"absolute inset-x-0 -bottom-1 px-4 leading-[18px]",children:u("input",{className:"box-border w-full m-0 cursor-pointer slider relative z-10",style:o,type:"range",min:t,max:l,step:n,value:s,disabled:i,onInput:t=>{const l=ct(t.target?.value),n=e.length?e[l]:l;r&&r(n||0)}})})]})}const mt=1,ht=100,ut=x((e=>{const{className:t,title:l,items:n=[],list:a=[],min:r=(a.length?0:mt),max:s=(a.length?a.length-1:ht),step:o=1,value:c=a[0]||r,disabled:d=!1,onChange:m}=e,h=rt(e,{normalize:(e=0)=>a.length?pt(a)(e):st(e,r,s),format:ot()}),x=i((e=>{m&&m(ct(e.target?.value))}),[m]);return p("div",{className:t,children:[p("label",{className:"block relative",children:[l?u(me,{size:"text-m",font:"font-light",color:"text-primary-text",children:l}):null,u("input",{className:w("m-0 mt-2 font-sans text-h3 w-full h-14","border border-solid border-gray rounded-md outline-none","p-0 pl-4 box-border","text-primary-text hover:border-primary-hover focus:border-primary-text","disabled:border-gray disabled:bg-main-divider"),disabled:d,onInput:x,...h}),dt({list:a,min:r,max:s,step:o,disabled:d,value:c,onChange:m})]}),xt(n)]})})),pt=e=>t=>e.reduce(((e,l)=>Math.abs(l-t)<Math.abs(e-t)?l:e)),xt=e=>u("div",{className:"flex justify-between my-2",children:e.map(((e,t)=>u(me,{size:"text-s-light",color:"text-secondary-text",children:e},String(t))))}),gt=e=>p("div",{className:"flex justify-between gap-5 mb-7",children:[p("div",{className:"w-1/2",children:[u("label",{children:u(me,{size:"text-m-light",children:"Сумма кредита, ₽"})}),u(ut,{items:nt,min:1e3,max:1e9,...e("amount")})]}),p("div",{className:"w-1/2",children:[u("label",{children:u(me,{size:"text-m-light",children:"Срок кредита, месяцев"})}),u(ut,{items:at,min:1,max:180,...e("term")})]})]}),ft=({regions:e,branches:t,field:l})=>p("div",{className:"flex justify-between gap-5 mb-7",children:[u("div",{className:"w-1/2",children:u(Fe,{label:"Регион",placeholder:"Выберите регион",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(l("region"),Se)})}),u("div",{className:"w-1/2",children:u(Fe,{label:"Адрес",placeholder:"Выберите адрес",options:t.map((({branchCode:e="",address:t=""})=>({key:e,text:t}))),...ue(l("department"),Se)})})]}),bt={amount:1e3,term:12,fullName:"",inn:"",name:"",phone:"",mail:"",annualRevenue:""},vt=R({annualRevenue:Se,inn:Te,name:Ie,phone:Be,region:Se,department:Se}),Nt=x((({button:e,link:t,onSubmit:l})=>{const n=i((e=>{const{amount:t,term:n,fullName:a,inn:i,name:r,phone:s,mail:o,region:c,department:d,annualRevenue:m}=e;P(vt(e))&&l({typeForm:"cred",fullName:a,inn:i,name:r,phone:s,mail:o,region:c?.text||"",department:d?.text||"",partnerComments:`Сумма=${t}/Срок=${n}/Выручка=${m}`})}),[l]),[a,{field:r,...s}]=B(bt,n),o=A(),c=function(e){const{data:t}=V(e?`/api/v1/branches?regionCode=${e}`:null,lt);return t||tt}(a.region?.key).filter((e=>e?.address));return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Параметры кредита",className:"text-center mb-4"}),gt(r),u(I,{headingType:"h6",title:"Данные организации",className:"text-center mb-4"}),it(r),u(I,{headingType:"h6",title:"Офис банка",className:"text-center mb-4"}),ft({regions:o,branches:c,field:r}),We(e,"mb-4"),u(he,{link:t})]})})),yt={name:"",phone:""},wt=R({name:Ie,phone:Be}),kt=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{name:t,phone:l}=e;P(wt(e))&&n({typeForm:"dpst",name:t,phone:l})}),[n]),[,{field:r,...s}]=B(yt,a);return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Оставьте заявку и мы ответим на любые вопросы по депозитам",className:"text-center mb-4"}),p("div",{className:"max-w-[560px] m-auto",children:[u(xe,{className:"shrink-0 w-full mb-3",label:"Имя",...ue(r("name"),Ie)}),u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(r("phone"),Be)})]}),p("div",{className:"flex justify-between items-center max-w-[560px] m-auto",children:[u("div",{className:"flex-1",children:u(he,{link:l})}),We(t)]})]})})),Ct=(e,t)=>e?.media&&t?.media?e.media-t.media:0,St=x((({className:e="",image:t,imageClassName:l="",pathPrefix:n})=>{const a=J();return p("picture",{className:e,children:[t?.sources?.length?t.sources.filter((e=>e?.src)).sort(Ct).map((({src:e,format:l,media:i},r)=>u("source",{srcSet:Tt(a,n)(e),type:Bt(l),media:i?`(max-width: ${i}px)`:"",...t.size},`${r}_${e}`))):null,t?.src?It({...t,src:Tt(a,n)(t.src)},l):null]})})),It=(e,t="")=>u("img",{src:e.src,className:w("object-contain",t),alt:e.alt||e.title,title:e.title||"",style:{width:e.size?.width?`${e.size?.width}px`:"100%",height:e.size?.height?`${e.size?.height}px`:"auto"},...e.size}),Tt=(e,t)=>l=>l&&!E(l)?W(e)(H(t,l)):l,Bt=e=>e?`image/${String(e)}`:void 0,Rt=x((({className:e="",image:t,imageClassName:l="",pathPrefix:n,...a})=>t?.src||t?.icon?t.icon?u(je,{className:e,imageClassName:l,iconVersion:t?.iconVersion,name:t.icon,...a}):u(St,{className:e,imageClassName:l,image:t,pathPrefix:n}):null)),Pt=x((({className:e,viewBox:t,fill:l="none",width:n,height:a,paths:i,...r})=>u("svg",{xmlns:"http://www.w3.org/2000/svg",className:e,viewBox:t,fill:l,width:n,height:a,children:i.map((({d:e,fill:t,...l},n)=>u("path",{d:e,fill:t||"currentColor",...r,...l},n)))}))),$t=[{d:"M10.207.793a1 1 0 0 1 0 1.414l-6 6a1 1 0 0 1-1.414 0l-2.5-2.5a1 1 0 0 1 1.414-1.414L3.5 6.086 8.793.793a1 1 0 0 1 1.414 0Z",fillRule:"evenodd",clipRule:"evenodd",fill:"white"}],Mt=x((({className:e,value:t,text:l,disabled:n,isRadio:a,onChange:r})=>{const s=i((e=>{n||(e.preventDefault(),r&&r(!t))}),[r,n,t]),o=a?u("div",{className:"absolute left-1 w-3 h-3 rounded-full bg-primary-main"}):u(Pt,{paths:$t,className:"absolute left-1 ml-px block",width:"11",height:"9",fill:"white",viewBox:"0 0 11 9"});return u("div",{className:e,children:p("label",{className:"flex items-center relative cursor-pointer group/box",onClick:s,children:[u("div",{className:w("appearance-none w-5 h-5 border-solid cursor-pointer m-0",a?"rounded-full border-2":_t(t),t?"border-primary-main":"border-gray",n?"bg-main-disabled":"group-hover/box:border-primary-hover"),role:"checkbox","aria-checked":Boolean(t),"aria-disabled":Boolean(n)}),t?o:null,l?u("span",{className:"font-sans ml-3 text-l-light",children:l}):null]})})})),_t=e=>w("rounded border",e?"bg-primary-main":""),Vt=e=>{const t=e("text");return p("div",{className:"mb-6",children:[p("div",{className:"flex items-center mb-4 gap-6",children:[u(Mt,{text:"Валютный контроль",...e("currencyControl")}),u(Mt,{text:"Документарные операции",...e("documentaryOperations")}),u(Mt,{text:"Конверсионные операции",...e("conversionOperations")})]}),u("textarea",{placeholder:"Укажите интересующий вас вопрос, место ведения бизнеса и удобное время для телефонного звонка",className:"block w-full resize-y min-h-24 p-4 outline-none border rounded-md border-main-stroke hover:border-primary-hover active:focus:border-primary-text",value:t.value,onInput:e=>t.onChange&&t.onChange(e.target?.value||"")})]})},jt=e=>p("div",{children:[p("div",{className:"flex justify-between gap-5",children:[u("div",{className:"w-1/2",children:u(xe,{className:"shrink-0 w-full mb-3",label:"Наименование организации",...ue(e("fullName"),Se)})}),u("div",{className:"w-1/2",children:u(xe,{className:"shrink-0 w-full mb-3",label:"ФИО",...ue(e("name"),Ie)})})]}),p("div",{className:"flex justify-between gap-5 mb-7",children:[u("div",{className:"w-1/2",children:u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)})}),u("div",{className:"w-1/2",children:u(xe,{className:"shrink-0 w-full mb-3",label:"Электронная почта",...ue(e("mail"),Se)})})]})]}),zt={fullName:"",name:"",phone:"",mail:"",currencyControl:!1,documentaryOperations:!1,conversionOperations:!1,text:""},Dt=R({fullName:Se,name:Ie,phone:Be,mail:Se}),Lt=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{fullName:t,name:l,phone:a,mail:i,currencyControl:r,documentaryOperations:s,conversionOperations:o,text:c}=e;P(Dt(e))&&n({typeForm:"kved",fullName:t,name:l,phone:a,mail:i,partnerComments:`Валютный контроль=${r}/Документарные операции=${s}/Конверсионные операции=${o}/Доп инф=${c}`})}),[n]),[,{field:r,...s}]=B(zt,a);return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Данные организации",className:"text-center mb-4"}),jt(r),u(I,{headingType:"h6",title:"Интересующий вопрос",className:"text-center mb-4"}),Vt(r),p("div",{className:"flex items-center pb-9 mb-9 border-b border-main-divider",children:[We(t,"mr-5"),u(he,{link:l})]}),u(I,{headingType:"h6",title:"Или свяжитесь с нами удобным способом",className:"text-center mb-4"}),p("div",{className:"flex",children:[p("a",{className:"flex items-center text-primary-text no-underline mr-6",href:"tel:8 (800) 200-78-70","aria-label":"8 (800) 200-78-70",children:[u(Rt,{image:{icon:"PhoneIcon"},width:"24",height:"24",className:"mr-3"}),u("span",{children:"8 (800) 200-78-70"})]}),p("a",{className:"flex items-center text-primary-text no-underline","aria-label":"ved@rshb.ru",href:"mailto:ved@rshb.ru",children:[u(Rt,{image:{icon:"MailIcon"},width:"24",height:"24",className:"mr-3"}),u("span",{children:"ved@rshb.ru"})]})]})]})})),At=x((({responseType:e})=>{const t="OK"===e;return p("div",{className:`flex items-center mt-5 p-5 rounded-md ${t?"bg-ok":"bg-fail"}`,children:[u(Rt,t?{image:{icon:"ResponceOKIcon"},width:"42",height:"42",className:"mr-4"}:{image:{icon:"ResponceFailIcon"},width:"37",height:"34",className:"mr-4"}),p("div",{children:[u(I,{headingType:"h6",title:t?"Ваша заявка отправлена":"Не удалось отправить заявку",className:"mb-1"}),u(me,{size:"text-l-light",color:"text-secondary-text",children:t?"Совсем скоро мы с вами свяжемся":"Пожалуйста, повторите позднее"})]})]})})),Ot={credit:e=>u(Nt,{...e}),acquiring:e=>u(Je,{...e}),"business-card":e=>u(et,{...e}),deposit:e=>u(kt,{...e}),wed:e=>u(Lt,{...e})},Et={send:async function(e){try{const t=await fetch("/api/v1/sendcorporatelead",{method:"POST",headers:{"Content-Type":"application/json"},mode:"cors",body:JSON.stringify(e)});return await t.json()}catch(e){return null}}},Ft=x((e=>{const{className:t,title:l,typeForm:a="credit",button:r,link:s,...o}=e,[c,d]=n(""),m=i((async e=>{const t=await Et.send(e)?"OK":"Fail";return d(t),t}),[]);return u(C,{className:t,defaultPadding:"p-default",...o,children:p("div",{className:"container max-w-[978px]",children:[l?u(I,{headingType:"h3",title:l,className:"text-center mb-8"}):null,Ot[a]({button:r,link:s,onSubmit:m}),c?u(At,{responseType:c}):null]})})})),Ut=x((({className:e="",title:t,benefitList:l,...n})=>p(C,{className:w("flex flex-col items-center",e),defaultPadding:"p-default",...n,children:[t?u(I,{headingType:"h3",as:"h2",className:"max-w-[47rem] text-center",title:t}):null,l?.length?u("div",{className:"flex flex-wrap w-full justify-center gap-x-20 mt-8",children:l.map(Ht)}):null]}))),Ht=(e,t)=>{const l=e.description;return p("div",{className:"flex items-center basis-1/2 max-w-[500px] mb-14",children:[e?.icon?.icon?u(Rt,{className:"w-12 h-12 min-w-12 p-3 rounded-icon bg-main-divider text-primary-main group-data-secondary:bg-white/30 group-data-secondary:text-black",image:e.icon}):null,e?.icon?.src?u(Rt,{image:e.icon}):null,p("div",{className:"ml-5 h-full",children:[e?.label?u(I,{headingType:"h6",children:e.label}):null,Xt(l)]})]},String(t))},Xt=e=>{const t=e?.benefitType||null;return e&&t?u("div",{className:"mt-2 text-l-light text-secondary-text group-data-secondary:text-white/80",children:"list"===t?Kt(e):Wt(e)}):null},Wt=e=>e?.name||null,Kt=e=>{const t=e?.bullets?"list-disc pl-6":"";return e?.items&&e.items.length>0?u("ul",{className:t,children:e.items.map(((e,t)=>u("li",{children:e},`benefitListItem-${t}`)))}):null},Gt=(e,{className:t,buttonClassName:l,isVertical:n}={})=>e?.length&&e.some((e=>e?.text||e?.icon?.icon))?u("div",{className:w("flex",n?"flex-col gap-xs justify-items-stretch":"flex-wrap gap-s",t),children:e.map(Jt(l))}):null,Jt=(e="")=>(t,l)=>{const{text:n,icon:a,iconRight:i,version:r,...s}=t||{},o="secondary"===r?"color":"white",c=a?.iconVersion?a?.iconVersion:o;return n||a?.icon?u(se,{className:w("basis-full sm:basis-auto",e),appendLeft:Yt({...a,iconVersion:c}),appendRight:Yt({...i,iconVersion:c}),version:r,text:n,...s},l?String(l):""):null},Yt=e=>e?.icon||e?.src?u(Rt,{image:e,width:String(e?.size?.width||24),height:String(24)}):null,qt={XXL:{title:{headingType:"h0",as:"h1"},descriptionSize:"text-h5",descriptionStyle:"mt-m"},XL:{title:{headingType:"h1",as:"h1"},descriptionSize:"text-xl-light",descriptionStyle:"mt-s"},L:{title:{headingType:"h2",as:"h2"},descriptionSize:"text-xl-light",descriptionStyle:"mt-s"},M:{title:{headingType:"h3",as:"h2"},descriptionSize:"text-xl-light",descriptionStyle:"mt-text"},S:{title:{headingType:"h4",as:"h2"},descriptionSize:"text-xl-light",descriptionStyle:"mt-xs"},XS:{title:{headingType:"h5",as:"h2"},descriptionSize:"text-l-light",descriptionStyle:"mt-xs"}},Zt={H6:"text-h6",XL_L:"text-xl-light",XL_R:"text-xl",L_L:"text-l-light",L_R:"text-l",M:"text-m-light",S:"text-s-light",XS:"text-xs-light"},Qt=x((({className:e,version:t="",headlineVersion:l="XL",title:n,description:a,align:i="text-center",as:r,isPadding:s=!0,isTheme:o=!1,...c})=>{const d=qt[l],m={marginTop:d.descriptionStyle};return p(C,{className:e,defaultPadding:s?"p-default":"",version:t,isTheme:o,...c,children:[n?u(I,{className:w("whitespace-pre-wrap",i),...d?.title,as:r||d?.title.as,title:n}):null,a?u(de,{size:d.descriptionSize,align:i,...m,children:a}):null]})})),el=x((e=>{const{className:t="",title:l,description:n,bonusItems:a,...i}=e;return u(C,{className:t,defaultPadding:"p-default",...i,children:p("div",{className:"container",children:[u(Qt,{className:"!p-0",title:l,description:n,headlineVersion:"M"}),u("div",{className:"flex flex-wrap w-full mt-9",children:a?.length?a.map(((e,t)=>p("div",{className:"flex-grow w-[49%] border border-gray p-9 mb-3 mx-2 even:mr-0 odd:ml-0 last:odd:mx-0",children:[e?.title?u(me,{size:"text-h4",children:e.title}):null,e?.description?u("div",{className:"mt-2",children:u(de,{size:"text-xl",font:"font-light",children:e.description})}):null,p("div",{className:"flex justify-between items-end mt-3",children:[Gt(e?.buttons),e.bonusItemContent?.bonusType?tl(e.bonusItemContent):null]})]},String(t)))):null})]})})})),tl=e=>u("div",{children:"count"===e.bonusType?ll(e):nl(e)}),ll=e=>p("div",{className:"relative -bottom-3 h-auto flex items-end mt-14 shrink-0",children:[e.bonusCount?u("span",{className:"font-mohave -tracking-[5px] text-title-extra bg-clip-text text-transparent bg-green-to-yellow -mb-7",children:e.bonusCount}):null,e.bonusName?u("span",{className:"text-h2 bg-clip-text text-transparent bg-green-to-yellow",children:e.bonusName}):null]}),nl=e=>e.image?u(Rt,{className:"w-12 h-12 min-w-12 p-3 rounded-icon",image:e.image}):null,al={left:"text-left",center:"text-center",right:"text-right"},il=x((({bonusBenefits:e,cardTextAlign:t="center",className:l="",columnsCount:n="4",subtitle:a,title:i,...r})=>p(C,{className:w("flex flex-col text-center",l),defaultPadding:"p-default",...r,children:[u(Qt,{className:"!p-0 mb-8",title:i,description:a,headlineVersion:"M"}),e?.length?u("div",{className:`grid gap-1 ${al[t]} ${sl(n)}`,children:e.map(rl)}):null]}))),rl=({icon:e,title:t,description:l},n)=>p("div",{className:w("flex flex-col items-center text-h6",l||t?"":"justify-center"),children:[t?u("span",{children:t}):null,e?u(Rt,{image:e,height:"180",className:"w-auto"}):null,l?u("span",{children:l}):null]},String(n)),sl=e=>{switch(e){case"3":return"grid-cols-3";case"4":return"grid-cols-4";default:return"grid-cols-5"}},ol=x((e=>{const{title:t,image:l,cardItems:n,button:a}=e;return p("div",{className:"border-gray border p-9 w-1/2",children:[l?p("div",{className:"flex justify-center",children:[l?.src?u(Rt,{className:"mb-5",image:l}):null,l?.icon?u(Rt,{image:l}):null]}):null,t?u(I,{headingType:"h4",title:t,className:"mb-6"}):null,n?.length?u("ul",{children:n.map(((e,t)=>cl(e,String(t))))}):null,Gt([a],{buttonClassName:"mt-6"})]})})),cl=(e,t)=>{const{icon:l,text:n}=e;return p("li",{className:"flex items-center gap-3.5 mb-3 last:mb-0",children:[l?.icon?u(Rt,{image:l,className:"w-12 h-12 min-w-12 p-3 rounded-icon bg-main-divider"}):null,l?.src?u(Rt,{image:l}):null,u("span",{className:"text-xl-light",children:n})]},t)},dl=x((({className:e,title:t,cards:l,...n})=>p(C,{className:e,defaultPadding:"p-default",...n,children:[u(I,{headingType:"h3",title:t,className:"text-center mb-8"}),u("div",{className:"flex gap-5",children:l?.length?l.map(((e,t)=>u(ol,{...e},String(t)))):null})]}))),ml=x((({buttons:e,className:t,...l})=>u(C,{className:w("!bg-transparent",t),defaultPadding:"p-0",...l,children:Gt(e)}))),hl=e=>{const{itemCount:t,visibleItemCount:l}=e,[a,r]=n(0),s=i((()=>r((e=>Math.min(e+1,t-1)))),[t]),o=i((()=>r((e=>Math.max(e-1,0)))),[t]),c=function({itemCount:e,visibleItemCount:t}){return Boolean(t&&e>t)}(e)&&a<t-(l||1),d=a>0;return[a,{inc:s,dec:o,canInc:c,canDec:d,isScrollAvailable:d||c}]};const ul=x((({className:e,disabled:t,...l})=>u(se,{rounded:!0,className:`group/btn shadow-[0_4px_25px_rgba(0,0,0,0.07)] w-12 h-12 min-h-12 max-h-12 flex items-center justify-center ${t?"bg-secondary-light text-secondary-text":"bg-white text-primary-text hover:text-primary-main"} ${e||""}`,disabled:t,...l,children:u(Rt,{className:"w-4 h-4 min-w-4 min-h-4 rounded-full box-border",image:{icon:"ArrowLeftIcon",iconVersion:"black"},imageClassName:"group-hover/btn:text-primary-main",width:"16",height:"16"})}))),pl=x((e=>u(ul,{...e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left"}))),xl=x((e=>u(ul,{...e,className:`${e.className||""} rotate-180`,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right"})));function gl({dec:e,inc:t,canDec:l,canInc:n,btnClass:a,className:i=""}){return l||n?p("div",{children:[l?u(ul,{className:`absolute z-40 ${a[0]} ${i}`,onClick:e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left",disabled:!l}):null,n?u(ul,{className:`absolute z-40 rotate-180 ${a[1]} ${i}`,onClick:t,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right",disabled:!n}):null]}):null}const fl=x((({title:e,value:t,postfix:l="",prefix:n,className:a=""})=>p("div",{className:w("mb-7",a),children:[e?u(me,{size:"text-l-light",color:"text-secondary-text",children:e}):null,u("div",t?{children:p(me,{size:"text-h3",children:[n," ",ot(2)(Math.round(t))," ",l]})}:{children:u(me,{size:"text-h3",children:"-"})})]}))),bl=Math.round(23.5),vl={minSum:1e4,maxSum:5e6,minMonths:13,maxMonths:60,rate:12.5,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,isInsurance:!0},Nl={minSumTravel:6e3,maxSumTravel:2e5,minSumOther:6e3,maxSumOther:2e5,maxBonus:5e3,prefMonthsNum:2,prefTravelBonusRate:.015,prefRestBonusRate:.01,travelBonusRate:.015,restBonusRate:.01},yl={minSum:5e4,maxSum:5e6,minMonths:2,maxMonths:10,rate:0,isMonthlyInterestPayment:!0,isRemoteRegistration:!0},wl={minSum:1e3,maxSum:5e5,minDays:1,maxDays:1095,rate:0,isMonthlyInterestPayment:!0,isReplenished:!1,isPartialWithdrawal:!1,isSmallBusiness:!1,depositeName:"Депозит 'Стабильный'"},kl=x((({rate:e,title:t="Ставка",unit:l,depositeName:n,isShowDepositeName:a,rateBlockClassName:i,fractionDigits:r=2})=>p("div",{children:[u(me,{size:"text-l-light",color:"text-secondary-text",children:t}),p("div",{className:"relative",children:[p("div",{className:"flex justify-start gradient-color-text",children:[u("span",{className:w("font-mohave text-title-huge pr-6 -mt-4",i),children:String(e.toFixed(r)).replace(".",",")}),l?u("span",{className:"text-7xl",children:l}):null]}),n&&a?u("div",{className:"absolute bottom-7 w-full text-center whitespace-nowrap",children:n}):null]})]}))),Cl=e=>e?u(de,{size:"text-s-light",color:"text-secondary-text",children:e}):null;function Sl({isShowItems:e=!0,step:t=1e3,...l}){const n=[`От ${ot(2)(l.min||0)} ₽`,`До ${ot(2)(l.max||0)} ₽`];return u(ut,{items:e?n:[],step:t,...l})}function Il(e){const{data:t}=V(`/wcms-resources/${e}.json`,D);return t}const Tl=(e,t)=>{const{travelExpenseValue:l,restExpenseValue:n}=e,a=Il(t||"bonus-calculator-data")||Nl,[i,r]=((e,t,l)=>{const{minSumTravel:n,minSumOther:a,maxBonus:i,prefMonthsNum:r,prefTravelBonusRate:s,prefRestBonusRate:o,travelBonusRate:c,restBonusRate:d}=e;if(t===n&&l===a)return[0,0];const m=Math.min(Math.round(s*t)+Math.round(o*l),i);return[m,m*r+Math.min(Math.round(c*t)+Math.round(d*l),i)*(12-r)]})(a,l,n);return{...a,...e,monthBonus:i,yearBonus:r}},Bl=x((({className:e="",sourceBookDir:t="",buttons:l,footnote:n})=>{const[a,{field:i}]=B({travelExpenseValue:6e3,restExpenseValue:6e3}),{minSumTravel:r,maxSumTravel:s,minSumOther:o,maxSumOther:c,monthBonus:d,yearBonus:m}=Tl(a,t);return p("section",{className:w("flex justify-between",e),children:[p("div",{className:"w-[468px]",children:[Sl({title:"Сумма покупок в категории путешествия, ₽",min:r,max:s,step:500,isShowItems:!1,...i("travelExpenseValue")}),Sl({title:"Сумма покупок в остальных категориях, ₽",className:"mt-7",min:o,max:c,step:500,isShowItems:!1,...i("restExpenseValue")})]}),u("div",{children:d>=0?u(kl,{title:"Баллов за месяц",rate:d,rateBlockClassName:"tracking-[-14px]",fractionDigits:0}):null}),p("div",{className:"w-full max-w-[350px]",children:[m>=0?u(fl,{title:"Баллов за год",value:m}):null,Gt(l,{className:"mt-7",isVertical:!0}),Cl(n)]})]})})),Rl=e=>`${e} ${Number(e)%10==1?"дня":"дней"}`,Pl={horizontal:"gap-10",vertical:"flex-col gap-3"},$l=x((({items:e,checkedItem:t,onChange:l,orientation:n="horizontal"})=>u("div",{className:`flex ${Pl[n]}`,children:e?.map((({id:e,text:n})=>u(Mt,{isRadio:!0,text:n,value:t===e,onChange:()=>l&&l(e)},String(e))))}))),Ml=({items:e,title:t,orientation:l="horizontal",value:n,onChange:a})=>p("div",{children:[t?u("div",{className:"mb-3",children:u(me,{color:"text-secondary-text",font:"font-light",children:t})}):null,u($l,{orientation:l,items:e,checkedItem:e[n?0:1].id,onChange:t=>a&&a(t===e[0].id)})]}),_l=e=>Ml({...e,items:[{id:"everyMonth",text:"Ежемесячно"},{id:"atEndTerm",text:"В конце срока"}]}),Vl=x((({title:e="Ставка"})=>p("div",{children:[u(me,{size:"text-l-light",color:"text-secondary-text",children:e}),u("div",{className:"mt-1 pt-1 pl-5 pb-1.5",children:u(je,{name:"PercentIcon",width:"90",height:"85"})}),u("div",{className:"w-[250px] mt-3.5",children:p(de,{size:"text-xl-light",color:"text-primary-text",children:["Процентная ставка для срока ",u("strong",{children:"1-30 дней"})," устанавливается при обращении в Банк"]})})]}))),jl=e=>e,zl=(e=jl)=>t=>t.reduceRight(((t,l)=>e(t)>e(l)?t:l)),Dl=zl(),Ll=e=>{const t=[...e];t.sort((([e],[t])=>e-t));let l=1;for(;l<t.length;){const[e,n]=t[l-1],[a,i]=t[l];n>=a?t.splice(l-1,2,[e,Math.max(n,i)]):l++}return t},Al=(e=jl)=>zl((t=>-e(t))),Ol=Al(),El=([e,t],l,n=[])=>l&&l[e]&&l[t]?{[e]:l[e],[t]:l[t]}:Fl([e,t],n),Fl=([e,t],l=[])=>({[e]:l.length?Ol(l.filter((t=>t[e])).map((t=>t[e]))):0,[t]:l.length?Dl(l.filter((e=>e[t])).map((e=>e[t]))):0}),Ul=(e,[t,l],n)=>e>=n[t]&&e<=n[l],Hl=(e,t)=>e?t.isReplenished&&t.isPartialWithdrawal:!t.isReplenished&&!t.isPartialWithdrawal,Xl=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,daysValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a/30)-n):Math.round(n*e*a/365/100)},Wl=x((({className:e="",sourceBookDir:t,buttons:l,footnote:n,bottomFootnote:a,isShowDepositeName:i})=>{const[r,{field:s}]=B({moneyValue:1e5,daysValue:90,isReplenished:!1,isPartialWithdrawal:!1,isSmallBusiness:!1,isMonthlyInterestPayment:!1}),o=((e,t)=>{const{daysValue:l,moneyValue:n,isPartialWithdrawal:a,isReplenished:i,isSmallBusiness:r,isMonthlyInterestPayment:s}=e,o=Il(t||"business-calculator-data"),c=i||a,d=l<90||l>730;if(l<=30)return{...wl,...e,isDisabledOperatingDeposit:d,isShowUnknownRate:!0};const m=o?.rateRows?.find((e=>s===e.isMonthlyInterestPayment&&r===e.isSmallBusiness&&Hl(c,e)&&Ul(n,["minSum","maxSum"],e)&&Ul(l,["minDays","maxDays"],e)))||wl,{rate:h}=m,u=Xl(h,e),p=n+u,x=o?.rateRows||[wl];return{...m,...Fl(["minSum","maxSum"],x),...Fl(["minDays","maxDays"],x),...e,isDisabledOperatingDeposit:d,income:u,finalSum:p}})(r,t),{income:c,finalSum:d,rate:m,depositeName:h,isShowUnknownRate:x}=o;return p("section",{className:e,children:[p("div",{className:"flex justify-between",children:[p("div",{className:"w-[486px]",children:[Sl({title:"Сумма вклада, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),(g={title:"Срок вклада, дни",min:o.minDays,max:o.maxDays,...s("daysValue"),value:o.daysValue},u(ut,{className:"mt-7",items:[`От ${Rl(g.min||0)}`,`До ${Rl(g.max||0)}`],step:1,...g})),p("div",{className:"mt-7 flex justify-between",children:[Kl(o,s),_l({title:"Выплата процентов",orientation:"vertical",...s("isMonthlyInterestPayment")})]})]}),x?u(Vl,{}):u(kl,{rate:m,depositeName:h,isShowDepositeName:i,rateBlockClassName:"tracking-[-25px]",unit:"%"}),p("div",{className:"w-full max-w-[350px]",children:[u(fl,{title:"Доход по вкладу",value:c,postfix:"₽",prefix:"+"}),u(fl,{title:"Сумма в конце срока",value:d,postfix:"₽"}),Gt(l,{className:"mt-7",isVertical:!0}),u("div",{className:"mt-7",children:Cl(n)})]})]}),u("div",{className:"mt-5",children:Cl(a)})]});var g})),Kl=(e,t)=>p("div",{children:[u(Mt,{text:"Пополнение",disabled:e.isDisabledOperatingDeposit,...t("isReplenished"),value:e.isReplenished}),u(Mt,{className:"mt-3",disabled:e.isDisabledOperatingDeposit,text:"Частичное снятие",...t("isPartialWithdrawal"),value:e.isPartialWithdrawal}),u(Mt,{className:"mt-3",text:"Являюсь малым предприятием",...t("isSmallBusiness"),value:e.isSmallBusiness})]}),Gl=({min:e=0,max:t=0,availableMonths:l,...n})=>u(ut,{className:"mt-7",items:[`От ${Jl(e)}`,`До ${Jl(t)}`],step:1,...l?.length?{list:l}:{min:e,max:t},...n}),Jl=e=>`${e} ${Number(e)%10==1?"месяца":"месяцев"}`,Yl=e=>ql({...e,fieldKey:"isSalaryClient",viewSettingFieldKey:"isShowSalaryClient"})&&ql({...e,fieldKey:"isStateEmployee",viewSettingFieldKey:"isShowStateEmployee"})&&ql({...e,fieldKey:"isPensionClient",viewSettingFieldKey:"isShowPensionClient"})&&ql({...e,fieldKey:"isInsurance",viewSettingFieldKey:"isShowInsurance"}),ql=({row:e,userInputParams:t,paramsViewSettings:l,fieldKey:n,viewSettingFieldKey:a})=>!!l&&!l[a]||t[n]===e[n],Zl=(e,t,l)=>{let{moneyValue:n,monthsValue:a}=e;const i=Il(t||"credit-calculator-data"),s=i?.rateRows||[vl],o=(({limitRows:e,userInputParams:t,paramsViewSettings:l})=>e?.find((e=>Yl({row:e,userInputParams:t,paramsViewSettings:l}))))({limitRows:i?.limitRows||[],userInputParams:e,paramsViewSettings:l}),{minSum:c,maxSum:d}=El(["minSum","maxSum"],o,s),{minMonths:m,maxMonths:h}=El(["minMonths","maxMonths"],o,s);n=st(n,c,d),a=st(a,m,h);const u=(({rateRows:e=[],userInputParams:t,paramsViewSettings:l,moneyValue:n,monthsValue:a})=>e?.find((e=>Yl({row:e,userInputParams:t,paramsViewSettings:l})&&Ul(n,["minSum","maxSum"],e)&&Ul(a,["minMonths","maxMonths"],e)))||vl)({rateRows:s,userInputParams:e,paramsViewSettings:l,moneyValue:n,monthsValue:a}),{rate:p}=u,x=((e,t)=>{const{isAnnuity:l,moneyValue:n,monthsValue:a}=t;if(0===e)return 0;if(l){const t=e/1200;return n*(t+t/(Math.pow(1+t,a)-1))}return Math.round(n/a)+n*(e/1200)})(p,e);return r((()=>({...u,...e,minSum:c,maxSum:d,minMonths:m,maxMonths:h,moneyValue:n,monthsValue:a,monthlyPayment:x})),[e,i])},Ql=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:a})=>{const[i,{field:r}]=B({isAnnuity:!1,isInsurance:!0,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,moneyValue:2e5,monthsValue:bl}),s=Zl(i,t,a);return p("section",{className:w("flex justify-between",e),children:[p("div",{className:"w-[468px]",children:[Sl({title:"Сумма кредита, ₽",step:500,min:s.minSum,max:s.maxSum,...r("moneyValue"),value:s.moneyValue}),Gl({title:"Срок кредита, месяцев",min:s.minMonths,max:s.maxMonths,...r("monthsValue"),value:s.monthsValue}),u("div",{className:"mt-7",children:en({...s,...a},r)})]}),u(kl,{title:"Ставка",rate:s.rate,rateBlockClassName:"tracking-[-25px]",unit:"%"}),p("div",{className:"w-full max-w-[350px]",children:[u(fl,{title:"Ежемесячный платеж",value:s.monthlyPayment,postfix:"₽"}),(o={orientation:"vertical",...r("isAnnuity")},Ml({...o,items:[{id:"annuity",text:"Аннуитетный"},{id:"differential",text:"Дифференцированный"}]})),Gt(l,{className:"mt-7",isVertical:!0}),Cl(n)]})]});var o})),en=(e,t)=>p("div",{children:[e.isShowSalaryClient?u(Mt,{text:"Получаю зарплату на счёт в Россельхозбанке",...t("isSalaryClient"),value:e.isSalaryClient}):null,e.isShowStateEmployee?u(Mt,{className:"mt-3",text:"Работаю в бюджетной организации",...t("isStateEmployee"),value:e.isStateEmployee}):null,e.isShowPensionClient?u(Mt,{className:"mt-3",text:"Получаю пенсию на карту Россельхозбанка",...t("isPensionClient"),value:e.isPensionClient}):null,e.isShowInsurance?u(Mt,{className:"mt-3",text:"Комплексная страховая защита",...t("isInsurance"),value:e.isInsurance}):null]}),tn=(e,t,l)=>{const{moneyValue:n,monthsValue:a}=e,i=Il(t||"deposit-calculator-data"),r=i?.rateRows?.[0]?an(i.rateRows[0].minMonths,i.rateRows[0].maxMonths):1,s=!l?.isShowMonthlyInterestPayment,o=!l?.isShowRemoteRegistration,c=i?.rateRows?.find((t=>nn({row:t,userInputParams:e,paramKey:"isMonthlyInterestPayment",isExclude:s})&&nn({row:t,userInputParams:e,paramKey:"isRemoteRegistration",isExclude:o})&&Ul(n,["minSum","maxSum"],t)&&Ul(a||r,["minMonths","maxMonths"],t)))||yl,{rate:d}=c,m=ln(d,e),h=n+m,u=i?.rateRows||[yl];return{...c,...Fl(["minSum","maxSum"],u),...Fl(["minMonths","maxMonths"],u),availableMonths:Ll(u.map((e=>[e.minMonths,e.maxMonths]))).flatMap((([e,t])=>((e,t,l=1)=>Array.from({length:Math.abs(t-e)/l+1},((n,a)=>t>=e?e+a*l:e-a*l)))(e,t))),...e,defaultMonth:r,income:m,finalSum:h}},ln=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,monthsValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a)-n):Math.round(n*e*30*a/365/100)},nn=({row:e,userInputParams:t,paramKey:l,isExclude:n})=>n||t[l]===e[l],an=(e,t)=>e+Math.round((t-e)/2),rn=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:i})=>{const[r,{field:s}]=B({moneyValue:2e4,monthsValue:0,isMonthlyInterestPayment:!1,isRemoteRegistration:!1}),o=tn(r,t,i),{defaultMonth:c,income:d,finalSum:m,rate:h}=o,{onChange:x}=s("monthsValue");return a((()=>{x&&x(c)}),[c]),p("section",{className:w("flex justify-between",e),children:[p("div",{className:"w-[468px]",children:[Sl({title:"Сумма вклада, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),Gl({title:"Срок вклада, месяцев",min:o.minMonths,max:o.maxMonths,availableMonths:o.availableMonths,...s("monthsValue"),value:o.monthsValue}),u("div",{className:"mt-7",children:sn({...o,...i},s)})]}),u(kl,{rate:h,rateBlockClassName:"tracking-[-25px]",unit:"%"}),p("div",{className:"w-full max-w-[350px]",children:[u(fl,{title:"Доход по вкладу",value:d,postfix:"₽",prefix:"+"}),u(fl,{title:"Сумма в конце срока",value:m,postfix:"₽"}),Gt(l,{className:"mt-7",isVertical:!0}),Cl(n)]})]})})),sn=(e,t)=>{return p("div",{className:"flex flex-col gap-y-7",children:[e.isShowMonthlyInterestPayment?_l({title:"Выплата процентов",...t("isMonthlyInterestPayment"),value:e.isMonthlyInterestPayment}):null,e.isShowRemoteRegistration?(l={title:"Оформление",...t("isRemoteRegistration"),value:e.isRemoteRegistration},Ml({...l,items:[{id:"remote",text:"Дистанционно"},{id:"office",text:"Офис Банка"}]})):null]});var l},on={CreditCalculatorForm:Ql,DepositCalculatorForm:rn,BusinessDepositCalculatorForm:Wl,BonusCalculatorForm:Bl},cn=(e,t)=>{const l=e?.calcType;if(!l||!(l in on))return null;const n=on[l];return u("section",{className:"box-border relative bg-white flex shrink-0 self-start basis-full",role:"listitem",children:p("div",{className:"box-border p-9 w-full",children:[e?.title?u(I,{className:"text-center mb-6",title:e.title}):null,u(n,{...e})]})},String(t))},dn=x((({className:e="",calculatorTabs:t=[],...l})=>{const a=t.map((e=>e.nav||{})),r=t.map((({calculatorBlock:e})=>e||{})),[s,o]=n(0),c=i((e=>o(e)),[]),[d,m]=hl({itemCount:t?.length,visibleItemCount:3});return p(C,{className:w("box-border overflow-hidden relative",e),defaultPadding:"p-0",...l,children:[p("div",{className:"bg-white",children:[a.length>1?mn({activeIndex:d,tabsNav:a,slideIndexShift:s,onClick:c}):null,gl({...m,btnClass:["left-3","right-3"],className:"top-8"})]}),u("div",{className:"flex",style:{transform:`translateX(-${s}00%)`},role:"list",children:r?.length?r.map(cn):null})]})}));function mn({activeIndex:e,tabsNav:t,slideIndexShift:l,onClick:n}){return p("div",{children:[u("div",{style:{transform:`translateX(-${388*e}px)`},className:"flex flex-col justify-end items-center h-[126px] pt-9 box-border duration-1000",children:u("div",{className:"w-full flex flex-nowrap items-end gap-2",children:t.map(((e,t)=>function({tab:e,i:t,isActive:l,onClick:n}){const a=l?"h-[88px] w-[387px] min-w-[387px] p-5 border-none bg-primary-main text-white":"h-[77px] w-[328px] min-w-[328px] px-5 py-4 ease-in duration-300 bg-white text-primary-text",i=l?"text-xl mb-1.5":"text-l mb-[3px]",r=l?"text-l-light text-white":"text-m-light text-secondary-text",s=l?"":"text-primary-main",o=e?.icon?.iconVersion,c=l?"white":"normal";return p("button",{type:"button",onClick:n,"aria-label":e?.title,className:w("box-border relative border border-gray cursor-pointer text-left border-b-0 flex hover:h-[88px]",a),children:[u(Rt,{className:`h-6 w-6 min-w-6 min-h-6 mr-4 ${s}`,image:{...e?.icon,iconVersion:o??c},width:"24",height:"24"}),p("div",{className:"border-0",children:[u("div",{className:i,children:e?.title}),u("div",{className:r,children:e.description})]})]},String(t))}({tab:e,i:t,isActive:Boolean(t===l),onClick:()=>n(t)})))})}),u("div",{className:"w-full h-2 bg-primary-main"})]})}const hn=x((e=>{const{onChange:t,min:l,max:n,defaultValue:a="0",fractionDigits:r=0,...s}=e,o=rt(e,{normalize:(e=a)=>l&&n?String(st(Number(un(e)),l,n)):un(e),format:ot(r)}),c=i((e=>t&&t(un(e))),[t]);return u(pe,{onChange:c,...s,...o})})),un=(e="")=>e.replaceAll(",",".").replace(/[^\d.]/g,"").replace(/([^.]*\.[^.]*)\./,"$1"),pn=x((e=>u(hn,{...e,fractionDigits:2,children:u("div",{className:"absolute right-4 bottom-4",children:u(me,{size:"text-xl",font:"font-light",children:"₽"})})}))),xn="amount",gn={[xn]:1500},fn=x((({className:e="",title:t="Укажите сумму перевода",label:l="Сумма перевода",placeholder:n="1500",button:a,...i})=>{const[{amount:r},{field:s}]=B(gn),o=r<=0,c=o?ie({version:a?.version}):re({className:"text-white",version:a?.version}),d=Y();return p(C,{className:w("flex flex-col items-center",e),defaultPadding:"p-default",...i,children:[t?u(I,{className:"pb-5 xl:pb-9 self-start xl:self-center",headingType:"h2",title:t}):null,p("form",{className:"w-full xl:max-w-[468px]",method:"POST",action:"https://www.rshb.ru/p2p/",children:[u(pn,{name:xn,valid:!o,placeholder:n,label:l,...s(xn,{parse:Number,format:String})}),a?.text?u("button",{type:"submit",className:w("w-full p-4 mt-5 xl:mt-6",c),disabled:o,...d(a),children:a.text}):null]})]})})),bn=({blockClassName:e,block:t,render:l})=>l({blockClassName:e,block:t}),vn=[];function Nn(e,t,{className:l,...n}={}){const{key:a,blockDecorator:i=bn,blocksRegistry:r={},ancestors:s=vn}=t,{type:o}=e;o&&o in r||console.warn(`No block with "${o}" is registered`);const c=o&&r[o];return i({blockClassName:w("scroll-mt-12",l,e.style||"col-span-12"),block:e,ancestors:s,render:({block:l,blockClassName:i})=>{const{content:r}=l;return c?u(c,{className:i,block:e,options:t,...r,...n},a):null}},a)}const yn=[],wn=(e,{key:t,ancestors:l=yn,slotName:n=null,renderProps:a=Nn,...i})=>(e||[]).map(((e,r)=>a(e,{...i,key:`${t||e.type}-${r}`,ancestors:i.parent?[...l||yn,[i.parent,n]]:l})));function kn({children:e,block:t,options:l,renderProps:n}){return e||(t&&l?wn(t.blocks,{...l,parent:t,renderProps:n}):null)}const Cn=e=>({height:"calc(100vh - 242px)",minHeight:`${e||866}px`}),Sn=x((({className:e="",style:t,idx:l,activeIndex:n,observerOptions:a,children:r,onIntersection:s})=>{const o=v(i((e=>{e.length&&s&&s(l||0,e[e.length-1])}),[s,l]),a);return u("div",{className:`inline-block snap-always box-border ${e}`,style:t,"aria-current":Boolean(l===n),ref:o,children:r})})),In=["min-w-[100%]","min-w-[50%]","min-w-[33.33%]","min-w-[25%]"],Tn=x((({className:e="",containerRef:t,activeIndex:l,visibleItemCount:n=0,gap:a=0,padding:r=0,listType:o="horizontal-list",snapAlign:c="snap-center",minHeight:d,children:m,onVisibleItemsChange:h,onVisibleIndicesChange:p})=>{const x={sensitivity:1,rootRef:t},g=s([]),f=i(((e,t)=>{const l=[...g.current||[]];l[e]=t,g.current=l,h&&h(l),p&&p(Rn(l))}),[h,p]),b=n>0?a*Number(n)-1:0,v="vertical-list"===o,N="horizontal-list"===o,y={...N?Bn(r,b):{},...v?Cn(d):{},gap:`${a}px`};return u("div",{className:w("box-border overflow-auto no-scrollbar",o,e),style:y,ref:t,children:(k=(e,t)=>u(Sn,{className:w(c,n?In[n-1]:"",v?"h-full":""),style:N?Bn(r/4):{},activeIndex:l,idx:t,observerOptions:x,onIntersection:f,children:e},String(t)),e=>null==e?e:Array.isArray(e)?e.map(k):k(e,0))(m)});var k})),Bn=(e,t=0)=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e+t}px`}),Rn=e=>e.map(((e,t)=>[e,t])).filter((([e])=>e&&e.intersectionRatio>=.9)).map((([,e])=>e)),Pn={"horizontal-list":"mx-auto mt-5 w-fit","vertical-list":"absolute flex-col justify-center h-full top-0 left-4"},$n={"horizontal-list":"w-6","vertical-list":"h-6"},Mn=x((({containerRef:e,activeIndex:t,dotCount:l=0,listType:n="horizontal-list",version:a})=>l?u("div",{className:w("flex gap-2",Pn[n],a?"group":""),...a?{"data-ver":a}:{},children:new Array(l).fill(null).map(((l,a)=>u("div",{className:`cursor-pointer rounded-full transition-width duration-300 bg-primary-main group-data-secondary:bg-white group-data-transparent:bg-white ${a===t?$n[n]:"w-2 h-2 opacity-30"}`,role:"button","aria-hidden":!0,onClick:()=>(l=>{l!==t&&e?.current&&e.current.children[l]?.scrollIntoView({behavior:"smooth",block:"nearest"})})(a)},String(a))))}):null)),_n=e=>t=>e.scrollWidth/t,Vn=e=>(t,l)=>{e.scrollBy({left:l*_n(e)(t),behavior:"smooth"})},jn=({itemCount:e,isCyclic:t,onVisibleIndicesChange:l})=>{const a=s(null),[r,o]=n([]),c=i((e=>{o((t=>{return(l=t)===(n=e)||Boolean(l&&n&&l?.length===n?.length&&l.every(((e,t)=>e===n[t])))?t:e;var l,n})),l&&l(e)}),[e]),[d,m]=r.length?[Al()(r),zl()(r)]:[-1,-1],h=d>0,u=m<e-1,p=i((()=>{var l;a.current&&(t&&!h?(l=a.current).scrollTo({left:l.scrollWidth,behavior:"smooth"}):Vn(a.current)(e,-1))}),[t,e,h]),x=i((()=>{a.current&&(t&&!u?a.current.scrollTo({left:0,behavior:"smooth"}):Vn(a.current)(e,1))}),[e,t,u]);return[a,{scrollLeft:p,scrollRight:x,canScrollLeft:t||h,canScrollRight:t||u,visibleIndicesRange:[d,m],handleVisibleIndicesChange:c}]},zn="absolute top-[calc(50%-24px)] z-40",Dn="absolute top-0 bottom-0 z-40 w-[84px] pointer-events-none",Ln=x((({scroll:e,arrowsPadded:t,isBlur:l,onScrollLeft:n,onScrollRight:a,hasEdgeBlocks:r,activeIndex:s,itemCount:o})=>{const{canScrollLeft:c,canScrollRight:d,scrollLeft:m,scrollRight:h}=e,x=r?s>0:c,g=r?s<o-1:d,f=i((()=>{r?(c&&s!==o-1&&m(),n()):m()}),[m,n,r,c,s,o]),b=i((()=>{r?(d&&0!==s&&h(),a()):h()}),[h,a,r,c,s,o]);return p("div",{children:[An(l,e),x?u(pl,{className:w(zn,t?"left-8":"left-0"),onClick:f}):null,g?u(xl,{className:w(zn,t?"right-8":"right-0"),onClick:b}):null]})})),An=(e,t)=>e?p("div",{children:[t.canScrollLeft?u("div",{className:w(Dn,"left-0 bg-opacity-from-white")}):null,t.canScrollRight?u("div",{className:w(Dn,"right-0 bg-opacity-to-white")}):null]}):null,On=x((({className:e="",itemCount:t,visibleItemCount:l,isBlur:a=!0,isCyclic:r=!1,arrowsPadded:s=!0,isPadding:o=!0,showDots:c=!1,isAlignCenter:d=!1,...m})=>{const{blocks:h=[]}=m.block||{},x=t||h?.length,[g,f]=n(Math.floor((l||0)/2)),b=i((()=>f((e=>e+1))),[]),v=i((()=>f((e=>e-1))),[]),[N,y]=jn({itemCount:x,isCyclic:r}),[k]=y.visibleIndicesRange,S=h&&"CarouselBankHistoryCard"===h[0]?.type;return u(C,{className:e,defaultPadding:En(o),...m,children:p("div",{className:w(Fn(d),"relative max-w-full"),children:[u(Tn,{containerRef:N,visibleItemCount:l,snapAlign:"snap-start",gap:4,onVisibleIndicesChange:y.handleVisibleIndicesChange,children:kn({...m,renderProps:S?(e,t)=>Nn(e,t,{blocksLength:h?.length,activeIndex:g}):Nn})}),u(Ln,{scroll:y,isBlur:a,arrowsPadded:s,onScrollLeft:v,onScrollRight:b,hasEdgeBlocks:S,activeIndex:g,itemCount:x}),c?Un(N,k,x):null]})})}));On.childrenTypes=["CarouselCard","CarouselBankHistoryCard","CarouselCatalogCard","CarouselInvestmentCard","CarouselProductCard","CarouselProgramsCard","CarouselRecommendationCard","CarouselTariffsCard","CarouselRichTextCard","CarouselInvestmentCard","CarouselEventCard"];const En=e=>e?"p-default":"",Fn=e=>e?"flex justify-center":"",Un=(e,t,l)=>u(Mn,{containerRef:e,activeIndex:t,dotCount:l,listType:"horizontal-list"}),Hn=x((({title:e,description:t,blocksLength:l=0,activeIndex:n,options:a})=>{const i=Number(a?.key?.split("-").slice(-1)[0])||0;return u(C,{className:"flex h-[485px]",defaultPadding:"p-0",children:u("div",i===n?{className:"relative flex items-center w-full",children:u(Qt,{headlineVersion:"M",title:e,description:t,align:"text-left",className:w("absolute z-10 h-[385px] w-[440px] p-8 text-white shadow-dark-blue",Kn(i,l),Xn(i))})}:{className:"flex w-full items-center justify-center",children:u("div",{className:w("flex justify-center items-center h-[300px] w-[340px] font-mohave text-title-large tracking-[-0.03em]",Xn(i)),children:u("span",{className:Wn(i),children:e})})})})})),Xn=e=>{switch(e%3){case 0:default:return"bg-primary-main";case 1:return"bg-green-light";case 2:return"bg-yellow-light"}},Wn=e=>{switch(e%3){case 1:case 2:return"gradient-color-text-on-yellow";default:return"gradient-color-text-on-green"}},Kn=(e,t)=>0===e?"left-9":e===t-1?"right-9":"-left-[25px]",Gn=e=>{const t="col-span-",l=e?.split(/\s+/).find((e=>e.startsWith(t)));return l?parseInt(l.substring(t.length),10):12},Jn={normal:"min-w-[970px]",small:"min-w-[355px]"};function Yn(e="",t="normal"){return Gn(e)<=4?"w-[375px]":Jn[t]}const qn="absolute border border-solid border-gray w-full h-full sm:hidden",Zn=x((({className:e="",button:t,description:l,title:n,carouselVersion:a="normal",version:i=""})=>u("section",{className:w("flex pb-9 pl-12 sm:p-5 border-box h-full sm:max-w-[375px]",Yn(e,a),e),children:p("div",{className:"relative w-full",children:[u("div",{className:`${qn} z-10 top-9 right-12 bg-green-dark`}),u("div",{className:`${qn} z-10 top-6 right-8 bg-green`}),u("div",{className:`${qn} z-10 top-3 right-4 bg-green-light`}),p("div",{className:"relative h-full bg-white z-10 p-10 border border-solid border-green-light",children:[u(Qt,{className:"!p-0",title:n,description:l,headlineVersion:"L",align:"text-left",version:i}),Gt([t],{className:"mt-14 sm:justify-center",isVertical:!0})]})]})}))),Qn={black:"bg-black",white:"bg-white"},ea=x((({className:e="",title:t,description:l,image:n,price:a,button:i,colors:r,...s})=>p(C,{className:w("border box-border border-gray min-w-[392px] h-full flex flex-col justify-left",e),...s,children:[n?.src?u(Rt,{className:"mb-5 flex justify-center",image:n}):null,t?u(I,{headingType:"h6",as:"h4",className:"text-left mb-1.5",title:t}):null,l?u("div",{className:"mb-4",children:u(de,{size:"text-m",align:"text-left",font:"font-light",children:l})}):null,r?.length?p("div",{className:"flex mb-4 text-secondary-text",children:[u("div",{className:"mr-1.5",children:u(me,{size:"text-s",align:"text-left",font:"font-light",children:"Доступные цвета:"})}),r.map(ta)]}):null,a?p(me,{size:"text-h3",align:"text-left",children:[a," ₽"]}):null,Gt([i],{buttonClassName:"mt-5 w-full"})]}))),ta=(e,t)=>u("div",{role:"figure",className:`w-6 h-6 ml-3 border border-solid border-main-divider rounded-full ${Qn[e]}`},String(t)),la=x((({className:e="",href:t,target:l,isRemote:n=!1,children:a})=>{const i=Y({isRemote:n})({href:t,target:l});return u(t?"a":"div",{className:w("block",e),...t?i:{},children:a})})),na=x((({className:e="",icon:t,title:l,description:n,href:a,target:i,...r})=>u(C,{className:w("w-[365px]",e),defaultPadding:"p-0",...r,children:p(la,{className:"flex flex-col",href:a,target:i,children:[t?.icon?u(Rt,{image:t}):null,t?.src?u(Rt,{image:t}):null,l?u(I,{headingType:"h6",as:"h4",className:"text-left pt-3 mb-2",title:l}):null,n?u("div",{className:"mb-4",children:u(me,{font:"font-light",size:"text-m",color:"text-secondary-text",children:n})}):null]})}))),aa={start:"self-start",center:"self-center",end:"self-end"},ia=x((({className:e,defaultPadding:t,padding:l,title:n="",insetTitle:a="",buttons:i,leftImage:r,rightImage:s,imageAlign:o,backImage:c,children:d})=>p("div",{className:w("relative flex flex-col gap-lg font-sans overflow-hidden",l||t,e),children:[c?u("div",{className:"absolute bottom-0 right-0 z-0",children:c}):null,n?u("div",{className:"relative",children:n}):null,p("div",{className:"grow relative flex flex-wrap sm:flex-nowrap justify-between items-stretch gap-lg",children:[ra(r,{imageAlign:o}),p("div",{className:w("flex flex-col gap-lg max-w-[600px] xl:max-w-[728px]",r?"":"grow"),children:[a,u("div",{className:"grow",children:d}),i]}),ra(s,{className:"-order-1 sm:order-1",imageAlign:o})]})]}))),ra=(e,{className:t,imageAlign:l})=>e?u("div",{className:w("flex-shrink-0",l&&aa[l],t),children:e}):null,sa={1:"flex-col",2:"gap-x-10 flex-wrap"},oa=x((({className:e,padding:t,additionalDescription:l,cardsList:n=[],columnsMode:a=1,description:i,image:r,title:s,...o})=>u(C,{className:w("box-border text-left w-[697px]","border border-solid border-gray group-data-secondary:border-white/50",e),defaultPadding:"p-0",...o,children:p(ia,{className:"h-full",padding:t,defaultPadding:"p-m",title:s?u(I,{headingType:"h4",as:"h3",className:"mb-3.5 z-10",title:s}):null,backImage:r?.src?u(Rt,{image:r}):null,children:[p("div",{className:"flex justify-between mb-4",children:[i?u("div",{className:"w-1/3",children:u(me,{size:"text-h6",children:i})}):null,l?u(me,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:l}):null]}),n.length?u("ul",{className:w("list-none m-0 p-0 flex gap-y-2",sa[a]),children:ca(n,a)}):null]})}))),ca=(e,t)=>e.slice(0,[4,9][t-1]).map(((e,l)=>{return p("li",{className:2===t?"basis-[calc(50%-20px)]":"",children:[e?.parameter?u("div",{className:"pr-2.5",children:u(me,{size:(n=t,1===n?"text-h6":"text-l"),children:e.parameter})}):null,e?.parameterDescription?u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:e.parameterDescription}):null]},String(l));var n})),da="bg-transparent border-white border h-[70px] absolute w-[316px] top-0",ma=x((({text:e,href:t="",target:l="",className:n=""})=>{const a=Y()({href:t,target:l});return e?p("div",{className:`relative group/link cursor-pointer w-[328px] h-[82px] ${n}`,children:[p("a",{className:"absolute border border-primary-main ml-3 px-6 py-5\n text-l-light bg-white text-primary-text flex w-[316px]\n justify-between items-center group-hover/link:text-primary-main z-10",role:"link",...a,children:[u("div",{className:"p-0.5",children:e}),u("div",{className:"w-6 h-6",children:u(Rt,{className:"w-4 h-4 min-w-4 min-h-4 rounded-full box-border brightness-0 group-hover/link:brightness-100",image:{icon:"ArrowRightIcon",iconVersion:"black"},imageClassName:"group-hover/link:text-primary-main",width:"24",height:"24"})})]}),u("div",{className:`${da} mx-1.5 mt-1.5`}),u("div",{className:`${da} mt-3 mr-3`})]}):null})),ha=x((({className:e,additionalDescription:t,description:l,links:n,title:a,...i})=>p(C,{className:w("flex w-full overflow-hidden justify-between",e),...i,children:[p("div",{className:"flex flex-col max-w-96 pr-m text-white text-xl-light",children:[u(Qt,{isPadding:!1,title:a,description:l,as:"h1",align:"text-left"}),t?u(Qt,{className:"pt-s",description:t,align:"text-left",isPadding:!1}):null]}),n?.length?ua(n):null]}))),ua=e=>{const t=Math.ceil(e.length/10);return u(On,{className:"min-w-[832px] w-[832px]",version:"",isBlur:!1,isCyclic:!0,itemCount:t,arrowsPadded:!1,showDots:!0,children:new Array(t).fill(null).map(((t,l)=>u("div",{className:"w-[672px] min-w-[672px] ml-10 mr-10 flex flex-wrap self-start",children:e.slice(10*l,10*(l+1)).map(((e,t)=>u(ma,{className:"m-1",...e},String(t))))},String(l))))})},pa={L:"w-1.5 h-1.5 mr-4",M:"w-1.5 h-1.5 mr-3",S:"w-1 h-1 mr-2"},xa=x((({className:e,isDotted:t=!0,children:l,size:n="M"})=>p("div",{className:w("font-sans flex",e),role:"listitem",children:[t?u("div",{className:"shrink-0",children:u("div",{className:w("align-middle inline-block rounded-full bg-primary-text group-data-secondary:bg-white",pa[n])})}):null,u("span",{children:l})]}))),ga={S:"text-l-light",M:"text-h6",L:"text-h5"},fa={S:"ml-2",M:"ml-3",L:"ml-4"},ba=x((({className:e,hasIndent:t,isDotted:l,items:n,listItemSize:a="M"})=>n?.length?u("section",{className:w("flex flex-col gap-2 text-left text-primary-text group-data-secondary:text-white group-data-gray:text-secondary-text",ga[a],t?fa[a]:"",e),role:"list",children:n.map(((e,t)=>u(xa,{isDotted:l,size:a,children:e},String(t))))}):null)),va=x((({additionalDescription:e,align:t="text-center",button:l={},className:n="",description:a,headlineSmallVersion:i="H6",href:r,icon:s,isDotted:o=!0,isFullWidth:c=!0,items:d=[],target:m,title:h,version:u="primary",...x})=>p(C,{className:w("h-full flex flex-col justify-between min-w-[260px]","box-border border-solid border border-gray",t,n),defaultPadding:"p-0",version:u,...x,children:[p(la,{className:"p-s",href:r,target:m,children:[Na(s),ya(i,h),wa(a,h),Ca(d,o,u),ka(e)]}),Gt([l],{className:w("p-s pt-0",c?"":"self-center min-w-[158px]"),isVertical:c})]}))),Na=e=>p("div",{className:"flex justify-center",children:[e?.src?u(Rt,{className:"mb-5",image:e}):null,e?.icon?u(Rt,{className:"w-8 h-8 min-w-8 mb-5",image:e}):null]}),ya=(e,t)=>t?u("div",{children:u(me,{size:Zt[e],children:t})}):null,wa=(e,t)=>e?u("div",{className:t?"mt-2":"",children:u(de,{size:"text-l",children:e})}):null,ka=e=>e?u("div",{className:"mt-auto",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text group-data-secondary:text-white/80",children:e})}):null,Ca=(e,t,l="primary")=>e?.length?u(ba,{className:w("max-w-[308px] mt-2 text-s","primary"===l?"!text-secondary-text":""),items:e.filter((e=>e?.text)).map((e=>e.text)),isDotted:t}):null,Sa=x((({className:e="",title:t,icon:l,list:n=[],href:a,target:i,...r})=>u(C,{className:w("border border-gray",e),defaultPadding:"p-0",...r,children:p(la,{className:"flex",href:a,target:i,children:[p("div",{className:"w-[200px] min-w-[200px] self-center",children:[l?.icon?u(Rt,{image:l}):null,l?.src?u(Rt,{image:l}):null]}),p("div",{className:"p-8 pl-3 w-full",children:[t?u(I,{className:"mb-3.5",headingType:"h5",title:t}):null,n.length?u("div",{className:"flex flex-col gap-3",children:n?.map(Ia)}):null]})]})}))),Ia=(e,t)=>p("div",{className:"break-words",children:[e.title?u("div",{className:"text-h6",children:e.title}):null,e.description?u("span",{className:"text-l-light mt-1",children:e.description}):null]},String(t)),Ta={default:"w-14 h-14",small:"w-12 h-12"},Ba=(e,t)=>e?"":w("group/media flex items-center justify-center box-border",Ta[t]),Ra=[{origins:["t.me","telegram.org"],iconMapped:{icon:"TelegramIcon"},label:"Телеграм"},{origins:["vk.com"],iconMapped:{icon:"VKIcon"},label:"ВКонтакте"},{origins:["ok.ru"],iconMapped:{icon:"OkIcon"},label:"Одноклассники"},{origins:["apps.apple.com"],iconMapped:{icon:"AppleIcon"},label:"App Store"},{origins:["play.google.com"],iconMapped:{icon:"PlayMarketIcon"},label:"Google Play"},{origins:["youtube.com"],iconMapped:{icon:"YoutubeIcon"},label:"Youtube"}],Pa=x((({buttonSize:e="default",rounded:t=!1,icon:l,...n})=>{const{href:a,version:i,text:r=""}=n,{iconMapped:s,label:o}=Ra.find((({origins:e})=>e.some((e=>a?.includes(e)))))||{},c=$a(l)??s;return u(se,{className:w(t?"rounded-full":"rounded-md","border border-solid hover:border-transparent","group-data-primary:border-main-divider","hover:bg-primary-main hover:text-black","group-data-secondary:bg-white border-main-divider group-data-secondary:hover:bg-secondary-hover","group-data-gray:border-green",Ba(r,e)),"aria-label":o,rel:"noopener noreferrer",target:"_blank",text:r,version:i,...n,children:c&&!r?u(Rt,{image:c,imageClassName:"group-hover/media:text-white",width:"24",height:"24"}):null})})),$a=e=>e?.src||e?.icon?e:void 0,Ma=x((({className:e="",media:t,children:l,buttonSize:n})=>p("div",{className:"font-sans",children:[u("div",{className:`flex gap-1 ${e}`,children:t?.map(((e,t)=>u(Pa,{buttonSize:n,...e},String(t))))}),u(me,{size:"text-s-light",color:"text-secondary-text",children:l})]}))),_a=x((({className:e="",description:t,href:l,icon:n,items:a=[],socialMedia:i=[],target:r,title:s,align:o="text-left",version:c="primary",...d})=>u(C,{className:w("relative min-w-[524px] min-h-[218px] h-full box-border group-data-gray:bg-main-divider/50","border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider",e),defaultPadding:"p-s",version:c,...d,children:p(la,{href:l,target:r,children:[u(Qt,{className:"mb-4",title:s,description:t,headlineVersion:"S",isPadding:!1,align:o}),p("div",{className:"w-1/2 h-full flex flex-col flex-1 justify-end",children:[a.length?u(ba,{items:a,listItemSize:"S"}):null,i.length?u(Ma,{className:"pt-10",media:i}):null]}),Va(n)]})}))),Va=e=>p("div",{className:"absolute bottom-0 right-0",children:[e?.icon?u(Rt,{image:e}):null,e?.src?u(Rt,{image:e}):null]}),ja=x((e=>{const{__html:t="",richVersion:l=""}=e;return u("div",{className:w(l,"md-container"),dangerouslySetInnerHTML:{__html:t}})})),za=x((({className:e="",__html:t,richVersion:l="striped",...n})=>u(C,{className:w("border border-gray h-full min-w-96",e),...n,children:u(ja,{__html:t,richVersion:l})}))),Da=x((({className:e="",isFoldButtonOnTop:t=!1,unfoldedByDefault:l=!1,renderFoldableSection:a,renderFoldButton:r})=>{const[s,o]=n(l),c=i((()=>{o((e=>!e))}),[]),d=a({isUnfolded:s,onToggle:c}),m=r?r({isUnfolded:s,onToggle:c}):null;return p("div",t?{className:e,children:[m,d]}:{className:e,children:[d,m]})})),La=x((({className:e="",isUnfolded:t,children:l})=>{const n=s(null);return a((()=>{n.current&&(n.current.style.maxHeight=t?`${n.current.scrollHeight}px`:"")}),[t,l?.length]),u("div",{ref:n,className:`transition-max-h duration-300 overflow-hidden ${n.current||!t?"max-h-0":""} ${e}`,children:l})})),Aa=(e=!1)=>e?"p-8 mt-8 pt-20":"p-8 mt-20",Oa=(e,t)=>{const{title:l,description:n,buttons:a}=e;return p("div",{className:"py-5 border-b border-main-divider",children:[l?u("div",{className:"opacity-80",children:u(me,{size:"text-m",color:"text-secondary-text",children:l})}):null,n?u("div",{className:"mt-1",children:u(me,{size:"text-h6",color:"text-primary-text",children:n})}):null,a?.length?u("div",{className:"text-primary-main",children:Gt(a)}):null]},String(t))},Ea=x((({className:e="",title:t,icon:l,isHighlighting:n=!1,button:a,cardCells:i=[],...r})=>{const s=i.map(Oa),o=s.slice(0,1),c=s.slice(1);return p(C,{className:w("relative border border-gray flex flex-col",e),defaultPadding:Aa(n),...r,children:[n?Ha():null,Fa(l),t?u(I,{className:"text-center pt-2",headingType:"h5",title:t}):null,a?u(se,{className:"w-full mt-4",...a}):null,i.length?u(Da,{renderFoldableSection:({isUnfolded:e})=>p("div",{children:[o,u(La,{isUnfolded:e,children:c})]}),renderFoldButton:i.length>1?Ua:null}):null]})})),Fa=e=>u("div",{className:"w-[267px] min-w-[267px] self-center",children:e?.src||e?.icon?u(Rt,{image:e}):null}),Ua=({isUnfolded:e,onToggle:t})=>p("button",{className:"w-full cursor-pointer text-primary-main pt-5 flex justify-between items-center",onClick:t,children:[u("div",{children:e?"Скрыть":"Подробнее о тарифе"}),u(je,{className:"text-primary-text",name:e?"ArrowUpIcon":"ArrowDownIcon",width:"16",height:"16"})]}),Ha=()=>p("div",{className:"absolute -top-7 -right-4 h-[60px] w-[60px] bg-white flex flex-col items-center justify-center rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]",children:[u(je,{iconVersion:"black",name:"HeartIcon",width:"23",height:"22"}),u(de,{size:"text-s",font:"font-normal",align:"text-center",color:"text-primary-text",children:"ХИТ"})]}),Xa="bg-gradient-to-r from-main-gradient-start to-main-gradient-end",Wa="border-gray border-solid border",Ka="border-main-divider border border-t-0 border-x-0",Ga="w-[200px] mr-6",Ja=x((({icon:e,image:t,title:l,link:n})=>p("div",{className:`w-80 box-border flex flex-col items-center rounded-t-md border-b-0 px-7 pt-7 pb-[46px] ${Wa} ${Xa}`,role:"columnheader",children:[e&&!t?.src&&u(Rt,{className:"h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4",image:e,width:"63",height:"63"}),t?.src&&u(Rt,{className:"mb-[18px]",image:t}),l?u(I,{headingType:"h4",as:"h3",className:"text-center text-white",title:l}):null,n?.text&&u("div",{className:"mt-auto w-full",children:u(se,{href:n.href,target:n.target,className:"mt-4 w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active",children:u("div",{className:"text-xs-light font-medium py-[11px]",children:n.text})})})]}))),Ya={comparison:"flex gap-4 duration-1000",tariff:"flex flex-grow duration-1000"},qa=x((({children:e,activeIndex:t,columnWidth:l,version:n="comparison"})=>u("div",{className:"flex flex-1 overflow-hidden",children:u("div",{className:Ya[n],style:{transform:`translateX(-${t*l}px)`},children:e})}))),Za=x((({children:e})=>u("div",{className:"self-start flex flex-col",role:"row",children:u("div",{className:"flex",children:e})}))),Qa=x((({colHeaders:e,activeIndex:t})=>p(Za,{children:[u("div",{className:Ga,role:"columnheader"}),u(qa,{activeIndex:t,columnWidth:336,children:e.map(((e,t)=>u(Ja,{...e},String(t))))})]}))),ei=x((({cell:e,isFirstRow:t,isLastRow:l,isFillGradient:n})=>u("div",{className:`w-80 box-border flex flex-col ${Wa} ${l?"border-t-0 rounded-b-md":"border-y-0"} ${n?Xa:""}`,role:"cell",children:u("div",{className:`mx-7 h-full ${Ka} ${n&&t?"border-t":""} ${l?"border-b-0":"border-solid"}`,children:e.map(((e,t)=>ni(e,t,n)))})}))),ti=(e=!1)=>"text-xl m-0 "+(e?"text-white":""),li=(e=!1)=>"text-s opacity-80 "+(e?"text-white":"text-secondary-text"),ni=({label:e,description:t},l,n)=>p("div",{className:"first:pt-7 pt-6 last:pb-7",children:[e?u("h4",{className:ti(n),children:e}):null,t?u("div",{className:li(n),children:t}):null]},String(l)),ai=(e=!1)=>`text-s py-7 ${Ka} w-[200px] mr-6 ${e?"border-b-0":"border-solid"}`,ii=x((({row:{header:e,data:t},activeIndex:l,isColoredFirstColumn:n,isFirstRow:a,isLastRow:i})=>p(Za,{children:[e?.title?u("div",{className:ai(i),children:e.title}):null,t?.length?u(qa,{activeIndex:l,columnWidth:336,children:t.map(((e,t)=>u(ei,{cell:e,isFirstRow:a,isLastRow:i,isFillGradient:n&&0===t},String(t))))}):null]}))),ri=x((({rowData:e,isColoredFirstColumn:t,activeIndex:l,controls:n})=>{const{isScrollAvailable:a}=n;return p("div",{className:"relative",children:[e.map(((e,n,{length:a})=>u(ii,{row:e,isFirstRow:0===n,isLastRow:n+1===a,activeIndex:l,isColoredFirstColumn:t},String(n)))),a?gl({...n,btnClass:["top-[108px]","top-[44px]"],className:"right-7",isDisabled:!0}):null]})})),si=x((({columns:e=[],rowHeaders:t,isShowAllRow:l,visibleRowLength:n,isColoredFirstColumn:a})=>{const i=e?.map((({header:e})=>e||{})),r=e?.map((({data:e})=>e))||[],s=t?.map(((e,t)=>({header:e,data:r.map((e=>e?.[t]||[{}]))}))).slice(0,l?t.length:n),[o,c]=hl({itemCount:e.length,visibleItemCount:3}),{isScrollAvailable:d}=c;return p("div",{children:[p("div",{role:"table",children:[i?.length?u(Qa,{colHeaders:i,activeIndex:o}):null,s?.length?u(ri,{rowData:s,isColoredFirstColumn:a,activeIndex:o,controls:c}):null]}),d?u("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"}):null]})})),oi=x((({className:e="",title:t,rowHeaders:l,columns:a,visibleRowLength:r=0,isColoredFirstColumn:s=!1,...o})=>{const[c,d]=n(!r),m=i((()=>d((e=>!e))),[]);return p(C,{className:w("overflow-hidden relative",e),defaultPadding:"p-default",...o,children:[u(I,{headingType:"h2",className:"max-w-[47rem] text-center mb-9 mx-auto",title:t}),u(si,{columns:a,rowHeaders:l,isShowAllRow:c,isColoredFirstColumn:s,visibleRowLength:r}),r?ci({isShowAllRow:c,onClick:m}):null]})})),ci=({isShowAllRow:e,onClick:t})=>u("div",{className:"pr-12",children:p("div",{className:"flex w-full",children:[u("div",{className:Ga}),u("button",{onClick:t,className:"mt-5 flex-1 border-gray border-solid border text-primary-text bg-white hover:border-primary-main hover:text-primary-main",children:u("div",{className:"font-sans text-xs-light font-medium py-3",children:e?"Скрыть":"Показать все параметры"})})]})}),di=x((({className:e,contacts:t,info:l,version:n="secondary",...a})=>p(C,{className:w("flex",e),defaultPadding:"p-default",version:n,...a,children:[l?.length?mi(l):null,t?.length?mi(t):null]}))),mi=e=>u("div",{className:"flex grow basis-0",children:e.map(((e,t)=>hi({column:e,index:t})))}),hi=({column:e,index:t})=>e?u("div",{className:"flex flex-col grow basis-0 pr-11 last:pr-0",children:e.map((({title:e="",description:t,additionalDescription:l,button:n},a)=>p("div",{className:"mt-6 first:mt-0",children:[u(Qt,{className:"!p-0",title:e,description:t,headlineVersion:"XS",align:"text-left"}),l?u("div",{className:"mt-1.5 opacity-80",children:u(de,{size:"text-m",font:"font-light",children:l})}):null,n?.href?u(se,{className:"mt-6",...n}):null]},String(a))))},`col-${String(t)}`):null,ui=e=>null==e||""===e||Array.isArray(e)&&0===e.length||"object"==typeof e&&0===Object.keys(e).length,pi=(e,t)=>Object.entries(e).map((([t,l])=>"number"==typeof l?((e,t)=>l=>ui(t[e])||ui(l[e])||xi(t[e])<=xi(l[e]))(t,e):"object"==typeof l&&"min"in l&&"max"in l?((e,t)=>l=>ui(t[e])||ui(l[e])||xi(t[e]?.min)>=xi(l[e]?.min)&&xi(t[e]?.min)<=xi(l[e]?.max))(t,e):Array.isArray(l)?((e,t)=>l=>ui(t[e])||ui(l[e])||t[e]?.some((t=>l[e]?.includes(t))))(t,e):((e,t)=>l=>ui(t[e])||ui(l[e])||t[e]===l[e])(t,e))).every((e=>e(t))),xi=e=>Number(e||0),gi=x((({className:e="",label:t,icon:l,dataTheme:n="",disabled:a=!1,onClick:i})=>p("button",{className:w("flex justify-center w-full px-0 py-4 border border-transparent outline-none focus:border-primary-text",a?"bg-main-divider text-main-disabled hover:bg-main-divider":"bg-primary-main text-white hover:bg-primary-hove",e),onClick:i,disabled:a,"data-theme":n,children:[u("span",{className:"text-h4 pr-3",children:t}),l?u(Rt,{image:{icon:l,iconVersion:"white"},className:"flex-shrink-0 my-auto",width:"20",height:"20"}):null]}))),fi=({isUnfolded:e,onToggle:t})=>u(gi,{icon:["ArrowDownIcon","ArrowUpIcon"][Number(e)],label:["Развернуть","Скрыть"][Number(e)],onClick:t}),bi=["ArrowDownIcon","ArrowUpIcon"],vi="grid grid-cols-12 gap-1 border-box",Ni=x((({label:e="",filtrationState:t={},topItemsCount:l=0,block:n,notFound:a,...i})=>{const r=n?.blocks?.filter((e=>pi(t,e.content||{})))||[],[s,o]=l>0?[r.slice(0,l),r.slice(l)]:[r,[]];return p("div",{children:[u("div",{className:w(r.length?"hidden":"block"),children:a?yi(a):null}),p("div",{className:w(r.length?"":"hidden"),children:[u("div",{className:w("mb-1",vi),children:wn(s,{...i.options,parent:n})}),u(Da,{renderFoldableSection:({isUnfolded:e})=>u(La,{className:w(vi,e?"mb-1":""),isUnfolded:e,children:wn(o,{...i.options,parent:n})}),renderFoldButton:({isUnfolded:t,onToggle:n})=>u(gi,{className:w(l<1?"hidden":""),disabled:!o?.length,label:e,icon:bi[Number(t)],dataTheme:i.options?.page?.colorPalette,onClick:n})})]})]})}));function yi({title:e,description:t}){return p("div",{className:"bg-white py-20",children:[e?u("div",{className:"mb-2",children:u(de,{align:"text-center",children:u(me,{size:"text-h4",children:e})})}):null,t?u(de,{size:"text-xl",font:"font-light",align:"text-center",children:t}):null]})}const wi=x((({value:e,onChange:t,items:l=[],multiple:n})=>l.map((l=>u(He,{text:l.title,value:[e].flatMap((e=>e)).includes(l.value),onChange:()=>(l=>{if(t)if(n){const n=e?.includes(l);t(n?(e||[]).filter((e=>e!==l)):[...e||[],l])}else t(e===l?"":l)})(l.value),type:n?"checkbox":"radio"},l.value))))),ki=({field:e,reset:t,filtrationSchema:l,resetButton:n,children:a})=>p("form",{className:"flex justify-between bg-white p-9 mb-1",children:[p("div",{className:"flex gap-11",children:[a,Object.entries(l).map(Ci(e))]}),n?u("div",{children:u(se,{className:"w-72 ml-3",onClick:t,...n})}):null]}),Ci=e=>([t,l])=>{const n=l?.type;return"array"===n?Si(t,e)(l):null},Si=(e,t)=>l=>{const n=l?.items?.enum?.map(((e,t)=>({value:e,title:l?.items?.enumNames?.[t]||""})))||[];return p("div",{children:[l?.title?u("div",{className:"mb-4",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:l.title})}):null,u(wi,{items:n,multiple:!0,...t(e)})]},e)},Ii={sum:500,period:{min:3,max:36}},Ti=x((({className:e,filtrationSchema:t={},resetButton:l,sumInput:n,periodInput:a,...i})=>{const[r,{field:s,reset:o}]=B(Ii),c=a?.max||36,d=p("div",{children:[u(pn,{label:n?.title,min:500,max:1e9,...s("sum",{parse:Number,format:String})}),u(ut,{title:a?.title,items:["От 3 мес","До 3 лет"],min:a?.min||3,max:c,...s("period",{parse:e=>({min:e,max:c}),format:({min:e})=>e})})]});return p(C,{className:w(e),defaultPadding:"p-0",version:"transparent",...i,children:[ki({field:s,reset:o,filtrationSchema:t,resetButton:l,children:d}),u(Ni,{filtrationState:r,...i})]})}));Ti.childrenTypes=["ProductTile"],Ti.childSchema=e=>e?.filtrationSchema||{};const Bi=e=>"Image"===e?.errorContentType&&e?.image?u(Rt,{image:e.image}):"Code"===e?.errorContentType&&e.code?u("div",{className:"font-mohave text-title-extra gradient-color-text",children:e.code}):null,Ri=x((({className:e="",title:t,subtitle:l,error:n,button:a,...i})=>{return p(C,{className:w("flex flex-col justify-center items-center",e),defaultPadding:(r=a?.text,r?"py-20 pt-3 pb-1":"mb-16 pb-2 mt-24 pt-3"),version:"transparent",...i,children:[u("div",{className:"flex justify-center py-20",children:Bi(n)}),t?u(I,{headingType:"h1",className:"text-left mb-4",title:t}):null,l?u("div",{className:"font-sans text-xl-light mb-7 max-w-[613px] text-center",children:l}):null,a?.text?u(se,{className:"py-4 px-9",version:a?.version,...a,children:a.text}):null]});var r}));var Pi;!function(e){e.EUR="EUR",e.USD="USD",e.GBP="GBP",e.AUD="AUD",e.CNY="CNY",e.RUB="RUB"}(Pi||(Pi={}));const $i={USD:"DollarIcon",EUR:"EuroIcon",GBP:"DollarIcon",AUD:"DollarIcon",CNY:"DollarIcon",RUB:"RoundRubleIcon"},Mi=e=>e?ji.format(e):"",_i=(e,t)=>p("td",{className:"pt-4 pl-11",children:[u("div",{children:Mi(e)}),u("div",{className:w("font-normal text-sm text-secondary-text",(t||0)>=0?"text-green":"text-red"),children:Mi(t)})]}),Vi=(e,t="")=>p("td",{className:"pt-4 pl-11",children:[u("div",{children:Mi(e)}),u("div",{className:"font-normal text-sm text-green",children:t})]}),ji=new Intl.NumberFormat("ru",{style:"currency",currency:Pi.RUB}),zi=e=>u("th",{className:"pl-11",children:u(me,{size:"text-m-light",align:"text-left",color:"text-secondary-text",children:e})}),Di=x((({className:e,currencies:t=[],actuality:l="",officeName:n="",...a})=>{const i=Li(t,4);return p(C,{className:e,...a,children:[p("div",{className:"flex flex-row flex-grow-0 justify-between mb-8",children:[u(I,{headingType:"h4",title:"Курс обмена валют в "+n,className:"whitespace-pre-wrap text-h4 mb-5"}),u("div",{className:"pl-11",children:u(me,{size:"text-m-light",align:"text-left",color:"text-secondary-text",children:l})})]}),u("div",{className:"flex flex-row pt-4 text-left",children:i.length>0?p("table",{className:w("h-fit w-fit",e),children:[u("thead",{children:p("tr",{children:[u("th",{children:u(me,{size:"text-m-light",align:"text-left",color:"text-secondary-text",children:"Валюта"})}),zi("Купить"),zi("Продать"),zi("Лучшая покупка"),zi("Лучшая продажа")]})}),u("tbody",{children:i.map((e=>(({title:e,buyPrice:t,buyDifference:l,sellPrice:n,sellDifference:a,buyOfficeName:i,sellOfficeName:r})=>p("tr",{className:"pb-1 text-h6",children:[u("td",{className:"pt-4",children:p("div",{className:"flex items-center",children:[e?u(Rt,{image:{icon:$i[e]},width:"24",height:"24"}):null,u("span",{className:"ml-2",children:e})]})}),_i(t,l),_i(n,a),Vi(t,i),Vi(n,r)]},e))(e)))})]}):null})]})})),Li=(e,t)=>e.sort(((e,t)=>Number(e.id)-Number(t.id))).slice(0,t);var Ai;!function(e){e.RUB="RUB",e.EUR="EUR",e.USD="USD"}(Ai||(Ai={}));const Oi=new Intl.NumberFormat("ru",{style:"currency",currency:Ai.RUB}),Ei=e=>e?Oi.format(e):"",Fi="text-left text-m-light text-secondary-text",Ui=`${Fi} pl-11`,Hi={USD:"DollarIcon",EUR:"EuroIcon"},Xi=x((({className:e,exchangeCurrencyItems:t})=>p("table",{className:`h-fit w-fit ${e}`,children:[u("thead",{children:p("tr",{children:[u("th",{className:Fi,children:"Валюта"}),u("th",{className:Ui,children:"Купить"}),u("th",{className:Ui,children:"Продать"})]})}),u("tbody",{children:t.map(Wi)})]}))),Wi=e=>{const t=e?.currency?.currency;return p("tr",{className:"pb-1 text-h6",children:[u("td",{className:"pt-4",children:p("div",{className:"flex items-center",children:[t?u(Rt,{image:{icon:Hi[t]},width:"24",height:"24"}):null,u("span",{className:"ml-2",children:t})]})}),u("td",{className:"pt-4 pl-11",children:Ei(e?.saleExchangeRate)}),u("td",{className:"pt-4 pl-11",children:Ei(e?.buyExchangeRate)})]},t)},Ki=x((({className:e="",address:t})=>p("div",{className:`flex ${e}`,children:[u(Rt,{image:{icon:"GpsIcon"},width:"24",height:"24"}),p("div",{className:"ml-3",children:[t?u("p",{className:"text-primary-main m-0 mb-1 text-l",children:t}):null,u("p",{className:"text-secondary-text m-0 text-m",children:"Курс указан для заданного офиса"})]})]}))),Gi=(e,t,l)=>{const n=Number(Ji(e))*Math.pow(t,l?-1:1);return Number.isInteger(n)?n:((e,t=2)=>{const l=10**t;return Math.round(parseFloat(String(e))*l)/l})(n)},Ji=e=>e.replace(/[^\d.,]/g,"").replace(",","."),Yi=e=>{return(t=[[e=>e.value!==Ai.RUB&&e.oppositeValue!==Ai.RUB,()=>e.handleConvert(e.value,Ai.RUB)],[e=>e.value===Ai.RUB&&e.oppositeValue===Ai.RUB,()=>e.handleConvert(e.value,Ai.USD)],[()=>!0,()=>e.handleConvert(e.value)]],e=>{const[,l]=t.find((([t])=>t(e)))||[];return l})(e)?.();var t};function qi(e){const{placeholder:t,rates:l,selected:n,value:a,setValue:i,setSelected:r}=e,s=l.map((e=>({key:e?.currency?.currency??"",text:e?.currency?.currency??""}))),o={key:n,text:n};return p("div",{className:"relative flex",children:[u(pe,{className:"shrink-0 text-l w-full appearance-none mr-[-90px]",placeholder:t,type:"text",value:a,onChange:i}),s.length?u(Le,{isBorder:!1,onChange:e=>r(e.key),options:s,value:o}):null]})}const Zi=x((({className:e="",currencyRatesBuy:t,currencyRatesSell:l,button:a})=>{const[r,s]=n({inputSell:"",inputBuy:"",selectSell:t?.[0]?.currency?.currency||Ai.RUB,selectBuy:l?.[0]?.currency?.currency||Ai.USD}),o=i((e=>s((t=>({...t,...e})))),[]);return p("div",{className:`grid gap-[18px] pt-2 ${e}`,children:[qi({placeholder:"Хочу продать",rates:l,selected:r.selectSell,setSelected:Qi(r,o,l),value:r.inputSell,setValue:e=>tr(o,l)(e,r.selectSell,r.selectBuy)}),qi({placeholder:"Получу",rates:t,selected:r.selectBuy,setSelected:er(r,o,t),value:r.inputBuy,setValue:e=>lr(o,t)(e,r.selectBuy,r.selectSell)}),a?.text?u(se,{className:"py-4",version:a?.version,...a,children:a.text}):null]})})),Qi=(e,t,l)=>n=>{t({selectSell:n}),Yi({value:n,oppositeValue:e.selectBuy,handleConvert:(n=e.selectSell,a=e.selectBuy)=>{tr(t,l)(e.inputSell,n,a)}})},er=(e,t,l)=>n=>{t({selectBuy:n}),Yi({value:n,oppositeValue:e.selectSell,handleConvert:(n=e.selectBuy,a=e.selectSell)=>lr(t,l)(e.inputBuy,n,a)})},tr=(e,t)=>(l,n,a)=>{e({inputSell:Ji(l),selectBuy:a});const i=t.find((e=>e.currency?.currency===a))?.buyExchangeRate||t.find((e=>e.currency?.currency===n))?.saleExchangeRate;i&&e({inputBuy:String(Gi(l,i,n===Ai.RUB)||"")})},lr=(e,t)=>(l,n,a)=>{e({inputBuy:Ji(l),selectSell:a});const i=t.find((e=>e.currency?.currency===a))?.saleExchangeRate||t.find((e=>e.currency?.currency===n))?.buyExchangeRate;i&&e({inputSell:String(Gi(l,i,n===Ai.RUB)||"")})};const nr=async e=>{const t=await ar(),l=t?.code||"000";return{region:t,exchangeRates:await ir(e,l)}},ar=async()=>{try{return await D("/api/v1/region",{method:"GET"})}catch(e){return console.log(e),{}}},ir=async(e,t)=>{try{return await D(e+`?regionCode=${t}`,{method:"GET"})}catch(e){return console.log(e),{}}},rr=x((({className:e="",title:t="Курсы обмена валют",button:l,...n})=>{const{exchangeRates:a}=function(){const{data:e}=V("/api/v1/exchangerates",nr);return e||{}}(),i=sr(a?.exchangeRate?.currencies),r=i.filter((e=>e.buyExchangeRate));r.unshift({currency:{currency:Ai.RUB}});const s=i.filter((e=>e.saleExchangeRate));return s.push({currency:{currency:Ai.RUB}}),u(C,{className:w("box-border min-h-80",e),...n,children:u(ia,{className:"h-full",title:u(I,{headingType:"h4",title:t,className:"whitespace-pre-wrap"}),children:p("div",{className:"flex gap-xxl",children:[p("div",{children:[i?u(Xi,{className:"mb-xl",exchangeCurrencyItems:i}):null,u(Ki,{address:a?.address})]}),i.length&&r.length&&s.length?u(Zi,{className:"grow",currencyRatesBuy:r,currencyRatesSell:s,button:l}):null]})})})})),sr=e=>e?.filter((e=>1===e?.currency?.id||2===e?.currency?.id))||[],or={};function cr(e,t={}){const{data:l}=V(`/wcms-resources/${e}.json`,D,{fallback:t});return l||or}const dr={"bg-white":"color",transparent:"white"},mr={"bg-white":"text-primary-main",transparent:"text-white"},hr=(e,t,l)=>u(Rt,t?.src?{image:t,className:mr[e],width:l?.width,height:l?.height,pathPrefix:"/wcms-resources/"}:{image:{icon:t?.icon||"LogoIcon",iconVersion:dr[e]},className:mr[e],width:l?.width,height:l?.height}),ur={"bg-white":"text-primary-text",transparent:"text-white"},pr=(e,t,l)=>u("span",{className:`${ur[t]} ml-2.5 font-medium ${l||""}`,children:e||"Россельхозбанк"}),xr=x((({className:e="",href:t,logo:l,children:n=l?.title,targetBlank:a,bgColor:i="bg-white",showTitle:r=!0})=>p("a",{className:`inline-flex items-center font-sans no-underline ${e}`,href:t||"/",target:a?"_blank":"_self","aria-label":l?.title||"Россельхозбанк",children:[hr(i,l?.image,{width:"40",height:"45"}),r?pr(n||l?.title,i):null]}))),gr=x((({className:e,onClick:t})=>u("button",{className:w("flex justify-center items-center w-12 h-12 p-1 bg-transparent border-none",e),onClick:t,title:"Закрыть",children:u(Rt,{image:{icon:"CloseIcon"},width:"24",height:"24"})})));function fr(e){throw new Error(e)}function br({onOpen:e,onClose:t}={}){a((()=>b.subscribe("dialog",(l=>{switch(l.type){case"open":e&&e(l);break;case"close":t&&t();break;default:fr(l)}}))),[e,t])}function vr(e,...t){return e.map(((e,l)=>[e,...t.map((e=>e[l]))]))}const Nr=e=>t=>{if(e===t)return 1;if(!e||!t)return 0;const{m:l,s1Matches:n,s2Matches:a}=function(e,t){const l=Math.max(0,Math.floor(Math.max(e.length,t.length)/2)-1),n=new Array(e.length),a=new Array(t.length);let i=0;for(let r=0;r<e.length;r++){const s=Math.max(0,r-l),o=Math.min(r+l,t.length-1);for(let l=s;l<=o;l++)n[r]||a[l]||e[r]!==t[l]||(i++,n[r]=!0,a[l]=!0)}return{m:i,s1Matches:n,s2Matches:a}}(e,t);if(0===l)return 0;const i=function(e,t,{s1Matches:l,s2Matches:n}){let a=0;for(let i=0,r=0;i<e.length;i++){if(!l[i])continue;let s=r;for(;s<t.length;s++)if(n[s]){r=s+1;break}e[i]!==t[s]&&a++}return a}(e,t,{s1Matches:n,s2Matches:a}),r=(l/e.length+l/t.length+(l-i/2)/l)/3,s=r>.7?.1*function(e,t){let l=0;for(;e[l]===t[l]&&l<4;)l++;return l}(e,t):0;return r+s*(1-r)};const yr=(e,t)=>(l,n)=>{for(const[a,i]of n)l.set(a,e(l.get(a)||t,i));return l},wr=(e=[])=>e.reduce(((e,t)=>e+t),0),kr=e=>e.toLowerCase().split(/[^0-9a-zа-я-]+/).filter((e=>e.length>=3&&!/[0-9a-z]/.test(e))),Cr=e=>t=>e.map((([e,l])=>[Nr(t)(e),l])).filter((([e])=>e>=.8)).map((([e,t])=>Ir(t,e))).reduce(yr(Math.max,0),new Map),Sr=e=>t=>{return vr(t,t.map((({title:e})=>e)).map((e=>t=>{const l=kr(t||"");return l.length?wr(e.map((e=>Dl(l.map(Nr(e)))))):0})(e))).sort((n=([,e])=>e,l=(e,t)=>n(e)-n(t),(e,t)=>-l(e,t))).map((([e])=>e));var l,n},Ir=(e,t)=>new Map(e.map((e=>[e,t]))),Tr=["/"],Br=({basePathList:e=Tr,initialQuery:t="",wasOpened:l})=>{const[i,s]=n(t||"");a((()=>{null!=t&&s(t)}),[t]);const o=r((()=>e.map((e=>l?e:null))),[l,e]),{data:c}=V(o,Rr),[d,m]=n(null);return((e,t,l=300)=>{a((()=>{const t=setTimeout(e,l);return()=>{clearTimeout(t)}}),t)})((()=>{c&&m(c.map((e=>t=>{const{corpus:l,dictionary:n}=t||{};if(!(e&&l?.length&&n&&Object.keys(n).length))return[];const a=kr(e);if(!a.length)return[];const i=Object.entries(n),r=[...a.map(Cr(i)).reduce(yr(((e,t)=>e+t),0),new Map).entries()].filter((([,e])=>e>=.799*a.length)).map((([e])=>l[e]));return Sr(a)(r)})(i)))}),[c,i]),[d,{value:i,onChange:s}]},Rr=async(...e)=>(await Promise.allSettled(e.map((e=>z(H(e,"/","search.index.json")))))).map((e=>"fulfilled"===e.status?e.value:{})),Pr=x((({className:e,isOpened:t,head:l,children:n,onClose:i})=>(a((()=>{const e=({key:e})=>{"Escape"===e&&i&&i()};return globalThis.document?.addEventListener("keydown",e),()=>{globalThis.document?.removeEventListener("keydown",e)}}),[i]),t?u("div",{className:w("fixed inset-0 bg-white text-l-light z-50 overflow-x-hidden overflow-y-scroll no-scrollbar",e),role:"dialog",children:p("div",{className:"relative container pb-12 min-h-full",children:[p("div",{className:"sticky bg-white pt-6 top-0",children:[u(gr,{className:"absolute top-10 -right-12",onClick:i}),l]}),n]})}):null)));function $r(e,t=!1){const[l,{setTrue:a,setFalse:r}]=Me(t),[o,c]=n({id:e}),d=s(l);d.current||=l;br({onOpen:i((t=>{t.id===e?(c(t),a()):r()}),[e]),onClose:r});const m=i((()=>{r(),b.fire("dialog",{type:"close"})}),[]);return{...o,isOpened:l,wasOpened:d.current,onClose:m}}const Mr=x((({className:e,topItems:t})=>{const l=Y({isRemote:!0});return u("div",{className:w("flex items-start justify-between",e),children:t?.map(l).map(_r)})})),_r=(e,t)=>{const{text:l,items:n,href:a,target:i,onClick:r}=e;return p("div",{className:"flex flex-col gap-3.5 w-1/4",children:[u("a",{className:"leading-5 text-l text-primary-text hover:text-primary-main no-underline",href:a,target:i||"_self",onClick:r,children:l||`Раздел ${t}`}),n?.map(((e,t)=>u(Vr,{...e,basePath:o(a),index:t},String(t))))]},String(t))},Vr=x((({text:e,index:t,basePath:l,...n})=>{const a=Y({isRemote:!(!d.BASE_PATH||!l)&&!d.BASE_PATH.startsWith(l),basePath:l}),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-l-light text-secondary-text hover:text-primary-main no-underline","overflow-x-hidden overflow-ellipsis whitespace-nowrap"),href:i,target:r||"_self",onClick:s,children:e||`Раздел ${t}`})})),jr=x((({className:e,value:t,autoFocus:l,onChange:n,onFocus:a})=>{const r=i((e=>{n&&n(e.target?.value||"")}),[n]);return p("div",{className:w("font-sans relative",e),role:"form",children:[u("div",{className:"absolute h-full flex items-center pl-4 pointer-events-none",children:u(Rt,{image:{icon:"LoupeIcon"},width:"24",height:"24"})}),u("input",{className:w("h-12 pl-12 w-full text-l text-black outline-none box-border","border border-solid rounded-md border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text"),value:t,type:"text",name:"search-bar-input",placeholder:"Поиск по сайту",autoFocus:l,onChange:r,onFocus:a})]})})),zr="search",Dr=x((({topItems:e})=>{const t=$r(zr),l=r((()=>e?.map((e=>e.href||"/"))),[e]),[n,i]=Br({basePathList:l,initialQuery:t.message,wasOpened:t.wasOpened}),s=r((()=>Lr(e)(n)),[e,n]);return a((()=>function(e){for(const t of e.filter((({items:e})=>e?.length)))console.group(t.text),console.table(t.items,["text","href"]),console.groupEnd()}(s)),[s]),u(Pr,{...t,head:u(jr,{className:"my-5",autoFocus:!0,...i}),children:u(Mr,{topItems:s})})})),Lr=e=>t=>e?.length&&t?.length?vr(e,t).map((([e,t])=>({...e,items:t?.map((({title:e,uri:t})=>({text:e,href:H("/",t)})))}))):[];const Ar=x((({className:e})=>{const[t,l]=n(""),a=i((()=>l("")),[]);br({onClose:a});const{open:r}=O(zr),s=i((e=>{l(e),Or(e)&&r(e)}),[]);return p("div",{className:e,children:[u(jr,{value:t,onChange:s}),u(gr,{className:"absolute top-2 right-3 sm:hidden",onClick:a})]})})),Or=e=>e&&e.length>=3,Er=x((({className:e="",items:t,hasButton:l})=>p("div",{className:e,children:[t?.length?t.map(Fr):null,l?u(se,{version:"primary",className:"mb-6 w-full",href:"https://www.rshb.ru/feedback/question/",target:"_blank",ariaLabel:"Обратная связь",text:"Обратная связь"}):null]}))),Fr=(e,t)=>p("div",{className:"mb-6",children:[u("div",{className:"mb-4",children:u(me,{size:"text-l",font:"font-medium",children:e?.title})}),u("div",{children:e.items?.map(Ur)})]},String(t)),Ur=(e,t)=>p("div",{className:"mb-4",children:[u("div",{children:Hr(e.type,e.text)}),u("div",{className:"mt-1 text-s-light text-secondary-text",children:e.description})]},String(t)),Hr=(e,t="")=>{switch(e){case"tel":return u("a",{className:"text-h6 text-primary-text hover:text-primary-main no-underline",href:`tel:${Xr(t)}`,children:t});case"email":return u("a",{className:"text-xl-light text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return u("span",{children:t})}},Xr=e=>e.replaceAll(/\D/g,""),Wr=x((({className:e="",index:t,text:l,...n})=>{const a=Y(),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-secondary-text",e),href:i,target:r,onClick:s,children:l||`Документ ${t}`})})),Kr=x((({className:e="",links:t})=>u("div",{className:e,children:t?.length?u("div",{className:"flex justify-between items-center gap-5 py-5 border-solid border-x-0 border-y border-y-main-divider",children:t.map(((e,t)=>u(Wr,{index:t,className:"text-l-light max-w-[292px]",...e},String(t))))}):null}))),Gr=x((({className:e="",index:t,...l})=>{const n=Y({isRemote:!0}),{href:a,target:i,text:r,onClick:s}=n(l);return u("a",{className:`text-xs-light text-secondary-text visited:text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${e}`,href:a,target:i,onClick:s,children:r||`Документ ${t}`})})),Jr=x((({className:e="",links:t})=>p("div",{className:e,children:[u("div",{className:"pt-4 xl:pt-5",children:u(me,{size:"text-xs-light",color:"text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?u("div",{className:"flex justify-start items-start gap-5 pt-4",children:t.map(((e,t)=>u(Gr,{index:t,...e},String(t))))}):null]}))),Yr="w-[204px]",qr=x((({className:e="",...t})=>{const l=t.options?.page?.fallback,n=cr(d.SITEMAP||"sitemap",l),{documents:a,relatedEnterprises:i,contacts:r,socialMedia:s,mobileApps:o,logo:c}=cr(d.FOOTER||"footer",l);return p(C,{tag:"footer",className:e,...t,children:[p("div",{className:"flex items-stretch gap-[54px] pb-8 xl:gap-8",children:[u(xr,{className:Yr,logo:c}),u(Ar,{className:"grow"})]}),p("div",{className:"flex items-stretch gap-[54px] xl:gap-8",children:[p("div",{className:"w-[204px] flex flex-col shrink-0 overflow-hidden",children:[u(Er,{items:r,hasButton:!0}),u(Ma,{media:s,children:"Соцсети"}),u(Ma,{className:"mt-6",media:o,children:"Мобильное приложение"})]}),u(Mr,{className:"flex-grow",topItems:n?.topItems})]}),u(Kr,{className:"mt-[98px]",links:i}),u(Jr,{links:a})]})})),Zr=x((({className:e="",title:t,description:l,calendar:n,...a})=>p(C,{className:e,defaultPadding:"p-default",...a,children:[u(Qt,{className:"!p-0 mb-4",title:t,description:l,headlineVersion:"M"}),n?Qr(n):null]}))),Qr=e=>{const t=100/(e.reduce(((e,t)=>t?.month?.length?e+t.month.length:e),0)||1),l=e.filter((e=>e?.month?.length)).map((e=>({...e,flexBasis:`${e?.month?.length?e.month.length*t:""}%`})));return p("div",{className:"w-full flex flex-col justify-center mt-13",children:[u("div",{className:"flex w-full mb-3 text-h6 text-center",children:l.map((e=>es(e,t)))}),u("div",{className:"flex w-full",children:l.map(((e,t)=>p("div",{className:"pr-[11px] mr-3 border-r border-main-divider last:border-r-0 last:pr-0 last:mr-0",style:{flexBasis:e.flexBasis},children:[u("div",{className:"flex",children:ts(e)}),p("div",{className:"text-s-light text-primary-text mt-3",children:[u("span",{children:e.text})," ",u("span",{className:"text-primary-main",children:e.greenText})]})]},`monthItem-${t}`)))})]})},es=(e,t)=>e.month?.map(((e,l)=>u("div",{style:{flexBasis:`${t}%`},children:e.text},`monthName-${l}`))),ts=e=>e.month?.map((e=>e.image?.src?u("div",{className:"h-[207px] border-r pr-3 mr-3 border-main-divider last:border-r-0 last:pr-0 last:mr-0",children:u(Rt,{image:e.image,className:"flex"})},`monthImage-${e.image.src}`):null)),ls=864e5;function ns(e,t,l=globalThis?.localStorage){const n=i((async(...n)=>{const a=`async:${e}`,i=function(e){const{data:t=null,timestamp:l=null}=e?JSON.parse(e):{};return t&&Date.now()-l<ls?t:void 0}(l.getItem(a));if(i)return i;const r=await t(...n);return l.setItem(a,JSON.stringify({data:r,timestamp:Date.now()})),r}),[e,t]);return V(e,n)}const as=()=>{const e=globalThis.localStorage?.getItem("location");try{return e?JSON.parse(e):null}catch(e){return null}},is=e=>({href:t})=>U(E(t)?e.href:e.pathname).startsWith(U(t));const rs=x((({className:e,searchTerm:t,onSearch:l})=>p("form",{className:`font-sans relative ${e}`,children:[u("div",{className:"absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none",children:t?null:u("label",{htmlFor:"search-bar-input",className:"text-secondary-text ",children:"Поиск по филиалам"})}),u("input",{id:"search-bar-input",className:"h-12 pl-4 w-full peer text-l text-black border border-solid rounded-md box-border\n outline-none border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text",value:t,onChange:e=>l(e.target.value.toLowerCase()),type:"text",name:"location-search-bar-input"})]}))),ss="location",os=x((({currentLocation:e,onChangeLocation:t,foreignOffices:l})=>{const a=$r(ss),[r,s]=n(""),o=ds(function(){const{data:e}=V("/api/v1/regions",D);return e||[]}()).sort(((e,t)=>e.name.localeCompare(t.name))),c=((e,t)=>{const l=new Map;for(const n of e){const e=t(n),a=l.get(e)||[];l.set(e,[...a,n])}return l})(o,cs),d=i((e=>{a.onClose&&a.onClose(),t&&t(e)}),[a.onClose,t]);return p(Pr,{...a,head:p("div",{children:[u(ms,{currentLocation:e,onChangeLocation:d}),u(rs,{onSearch:s,searchTerm:r,className:"mb-7"})]}),children:[r&&r.length>=3?u("div",{children:o.filter((({name:e})=>e&&Nr(e.toLowerCase())(r.toLowerCase())>=.8)).map(us(d))}):u("div",{className:"columns-5",children:Array.from(c.entries()).map(hs(d))}),u(ps,{foreignOffices:l})]})})),cs=e=>e.name?.charAt(0)||"",ds=e=>e.map((e=>({...e,name:e.name?.replace(/республика|область|край'/gi,"").trim()||""}))),ms=x((({currentLocation:e,onChangeLocation:t})=>e?p("div",{className:"mb-4",children:[u(me,{size:"text-l",font:"font-light",children:"Сейчас выбран: "}),u("button",{className:"cursor-pointer",onClick:()=>{t&&t(e)},children:u(me,{color:"text-primary-main",children:e.name})})]}):null)),hs=e=>([t,l])=>p("div",{className:"break-inside-avoid mb-7 w-[224px]",children:[u("div",{className:"mb-2.5",children:u(me,{size:"text-h6",children:t})}),l.map(us(e))]},t),us=e=>t=>u("div",{className:"mb-1",children:u("button",{className:"cursor-pointer hover:text-primary-hover",onClick:()=>{e&&e(t)},children:t.name||""})},t.id),ps=x((({foreignOffices:e})=>e?.length?p("div",{className:"border-t border-main-divider mt-7 pt-7",children:[u("div",{className:"mb-4",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:"Представительства за рубежом:"})}),u("div",{className:"flex gap-10",children:e.map(((e,t)=>u(xs,{...e},String(t))))})]}):null)),xs=x((({icon:e,...t})=>{const l=Y(),{text:n,target:a,href:i,onClick:r}=l(t);return p("div",{className:"flex gap-x-3",children:[e?u(Rt,{pathPrefix:"/wcms-resources/",image:e}):null,n?u("a",{className:"hover:text-primary-hover",href:i,target:a,onClick:r,children:n}):null]})})),gs=x((({className:e="",active:t,flat:l,children:n,...a})=>{const i=Y({isRemote:!0}),{href:r,target:s,text:o,onClick:c}=i(a);return u("a",{className:w(fs(t,l),e),href:r,target:s,onClick:c,rel:"noopener noreferrer","aria-label":o,children:u("span",{className:bs(t,l),children:o||n})})})),fs=(e=!1,t=!1)=>w("inline-block border border-solid bg-transparent text-center no-underline",e?"rounded-md border-primary-main group-data-transparent:border-white":"border-transparent",t?"":"px-4 py-2"),bs=(e=!1,t=!1)=>w("font-sans text-s-light",e?"text-primary-main":w(t?"text-primary-text":"text-secondary-text","hover:text-primary-main"),"group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),vs={default:"w-6 h-6",large:"w-12 h-12"},Ns=x((({className:e,isRounded:t,buttonSize:l="default",isGrayBg:n=!1,disabled:a,ariaLabel:i,image:r,onClick:s})=>u("button",{className:w("group/btn border-0 flex shrink-0 items-center",n?"p-3 rounded-full":"p-0 bg-inherit",n&&!t?"bg-main-divider":"",t?"w-8 h-8 text-secondary-light hover:text-secondary-hove":`${vs[l]} text-primary-text hover:text-primary-main`,"group-data-transparent:text-white",e),type:"button",disabled:a,"aria-label":i,onClick:s,children:u(Rt,{image:r,className:w("h-full",t?"bg-main-divider/20 rounded-full":""),imageClassName:"group-hover/btn:text-primary-hover group-hover/btn:invert-0"})}))),ys=x((({className:e,version:t,locationName:l,officesLink:n})=>{const a="transparent"===t?"white":"black",{open:r}=O(ss),s=i((()=>r()),[]),{open:o}=O(zr),c=i((()=>o()),[]);return p("div",{className:w("flex items-center gap-5",e),children:[u(gs,{flat:!0,href:"#",text:l,onClick:s}),n?u(gs,{flat:!0,href:n,text:"Офисы и банкоматы"}):null,u(Ns,{image:{icon:"LoupeIcon",iconVersion:a},ariaLabel:"Поиск",onClick:c})]})})),ws=x((({className:e="",items:t,activeItem:l})=>{const a=Y(),[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),c=_e(i((()=>s(!1)),[]));return p("div",{className:w(r?"bg-white rounded-md shadow-blue-gray":"",e),ref:c,children:[u("button",{className:"group/btn flex justify-between items-center h-6","aria-label":""+(r?"Скрыть другие разделы":"Показать другие разделы"),onClick:o,children:Array(3).fill(null).map(((e,t)=>u("div",{className:"w-[3px] h-[3px] rounded mr-1 bg-primary-text group-hover/btn:bg-primary-hover group-data-transparent:bg-white"},String(t))))}),u("div",{className:w("absolute flex flex-col rounded-md bg-white p-6 pb-2",r?"":"hidden"),"aria-hidden":!r,children:t?.map(((e,t)=>{const{text:n,...i}=e;return u("a",{className:w("text-l-light pb-4 hover:text-primary-main",e===l?"text-primary-main":""),...a(i),children:n},e.href||String(t))}))})]})})),ks=x((({className:e="",active:t,dataItemName:l,children:n,...a})=>{const i=Y(),{href:r,target:s,text:o,onClick:c}=i(a);return p("a",{className:w("relative inline-block bg-transparent text-center no-underline",e),href:r,target:s,"data-item-name":l,onClick:c,children:[u("span",{className:Cs(t),children:o||n}),t?u("div",{className:"absolute left-0 right-0 -bottom-3 h-0.5 bg-primary-main group-data-transparent:bg-transparent"}):null]})})),Cs=(e=!1)=>w("font-sans text-l-light",e?"text-primary-main":"text-primary-text hover:text-primary-main","group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),Ss=x((({observerOptions:e,onVisibilityChange:t,children:l,className:n,...a})=>{const r=v(i((e=>{if(!e.length||!t)return;const l=e[e.length-1];t(l.isIntersecting)}),[t]),e);return u("span",{ref:r,className:n,children:u(ks,{...a,children:l})})})),Is=e=>globalThis[e];function Ts(e,t){const[l,r]=n(),s=i((()=>r(Is(e))),[e]);return a((()=>{const l=document.getElementById(t);if(!l){const e=document.createElement("script");return e.src=t,e.async=!0,e.id=t,e.addEventListener("load",s),document.head.appendChild(e),()=>{document.head.removeChild(e),r(void 0)}}if(!Is(e))return l.addEventListener("load",s),()=>{l.removeEventListener("load",s)};s()}),[e,t]),l}const Bs={personal:"//chat.mes.rshb.ru/assets/js/webchat_rshb",business:""},Rs=x((e=>{const[t,{setTrue:l}]=Me();return t?u(Ps,{...e}):$s({...e,onClick:l})})),Ps=x((({chat:e="personal",...t})=>((e=>{a((()=>globalThis.localStorage?.setItem("webchat-keep-open",String(Date.now()))),[]),Ts("chatbot",Bs[e])})(e),$s(t)))),$s=({className:e,iconVersion:t,onClick:l})=>u(Ns,{className:w("text-page__btn-chat",e),image:{icon:"HeadphonesIcon",iconVersion:t},ariaLabel:"Чат",onClick:l,buttonSize:"large",isGrayBg:!0}),Ms={default:"px-5 bg-main-divider rounded hover:text-primary-main",transparent:"text-white hover:text-primary-hover"},_s=x((({version:e,internetBankUrl:t})=>t?u(se,{href:t,ariaLabel:"Интернет-банк",target:"_blank",className:w("py-3 ml-3 text-l font-light whitespace-nowrap hover:text-primary-main",Ms["transparent"===e?"transparent":"default"]),children:"Интернет-банк"}):null)),Vs=x((({subItems:e=[],version:t,internetBankUrl:l})=>{const a="transparent"===t?"white":"black",i=(e=>(t=[])=>{const l=t?.filter(is(e));return l?.length?zl((e=>e.href?.length||0))(l):void 0})(J())(e),[o,c]=n(e.length),m=e.slice(o),h=s(null),x={rootRef:h},g=r((()=>e.map(((e,t)=>e=>{c(e?js(t):zs(t))}))),[e]);return p("nav",{className:"relative mt-3 flex items-center justify-between",children:[u("div",{ref:h,className:"overflow-hidden whitespace-nowrap pb-3 mt-2",children:e.map(((e,t)=>u(Ss,{className:w("ml-8 first:ml-0",o-1<t?"invisible":""),active:e===i,observerOptions:x,onVisibilityChange:g[t],...e},String(t))))}),m.length?u(ws,{className:"relative w-auto z-40",items:m,activeItem:i}):null,d.CHAT_BOT?u(Rs,{className:"ml-9",iconVersion:a,chat:d.CHAT_BOT}):null,u(_s,{version:t,internetBankUrl:l})]})})),js=e=>t=>Math.max(t,e+1),zs=e=>t=>Math.min(t,e),Ds={"bg-white":"primary",transparent:"transparent"},Ls=x((({bgColor:e="bg-white",className:t,showSubMenu:l=!0,version:r=Ds[e],...s})=>{const o=J(),{topItems:c,logo:m,defaultLocation:h,foreignOffices:x,officesLink:g,internetBankUrl:f}=cr(d.SITEMAP||"sitemap",s.options?.page?.fallback),b=c?.find((e=>is(d.BASE_PATH?{pathname:d.BASE_PATH}:e))(o)),[v,N]=function(e="Москва"){const t=as(),[l,r]=n(t?.region??{name:e}),{data:s}=ns("/api/v1/region",D);return a((()=>{r(t?.region&&t?.manual?t.region:s||{name:e})}),[s]),[l,i((e=>{globalThis.localStorage?.setItem("location",JSON.stringify({manual:!0,region:e})),r(e)}),[])]}(h);return p(C,{tag:"header",className:w("pt-6 px-20",l&&b?.items?.length?"pb-4":"pb-5",t),defaultPadding:"",version:r,...s,children:[p("div",{className:"container",children:[p("div",{className:"flex items-center",children:[u(xr,{className:"mr-8",bgColor:e,logo:m}),c?.map(((e,t)=>u(gs,{active:e===b,...e},String(t)))),u(ys,{version:r,className:"ml-auto",locationName:v.name,officesLink:g})]}),u("div",{className:w("mt-6 h-px bg-main-divider","transparent"===r?"opacity-30":"")}),l&&b?.items?.length?u(Vs,{subItems:b.items,version:r,internetBankUrl:f}):null]}),u(Dr,{topItems:c}),u(os,{currentLocation:v,foreignOffices:x,onChangeLocation:N})]})})),As={XXL:"gap-12",XL:"gap-10",L:"gap-8",M:"gap-4",S:"gap-2",XS:"gap-1","":""},Os=x((({className:e="",gap:t="XS",isPadding:l=!1,version:n="transparent",isTheme:a=!1,...i})=>u(C,{className:w("relative","grid grid-cols-12",As[t],e),defaultPadding:l?"p-default":"",version:n,isTheme:a,...i,children:kn(i)})));Os.childrenTypes={exclude:["HorizontalLayout"]};const Es=x((e=>{const{className:t,image:l,...n}=e;return u(C,{className:t,defaultPadding:"p-0",...n,children:u(Rt,{image:l})})})),Fs=x((({className:e="",cards:t=[],button:l})=>{const[a,r]=n(0),s=i((e=>r(e)),[]),o=t.length,[c,d]=hl({itemCount:o,visibleItemCount:2}),{canDec:m,canInc:h}=d,x=t[c]?.href;return p("section",{role:"listitem",className:`min-w-full text-center ${e}`,children:[p("div",{className:"relative overflow-hidden",children:[o?Us({activeIndex:c,cards:t,selectedCardIndex:a,onClick:s}):null,gl({...d,btnClass:["left-12","right-12"],className:"top-[62px]"}),m?u("div",{className:"absolute top-0 left-0 h-full w-[136px] bg-opacity-from-white"}):null,h?u("div",{className:"absolute top-0 right-0 h-full w-[136px] bg-opacity-to-white"}):null]}),u(se,{className:"w-60 text-center",version:"primary",...l,href:x})]})}));function Us({activeIndex:e,cards:t,selectedCardIndex:l,onClick:n}){const a=460*e,i=t.length>2?"justify-start":"justify-center";return u("div",{style:{transform:`translateX(-${a}px)`},className:"duration-1000 px-12",children:u("div",{className:`w-full flex flex-nowrap gap-3.5 pb-12 ${i}`,children:t.map(((e,t)=>function({slide:e,i:t,isActive:l,onClick:n}){return p("button",{type:"button",onClick:n,className:"p-[30px] min-w-[460px] flex items-center bg-white border-solid border relative "+(l?"shadow-dark-blue border-primary-main":"ease-in duration-300 border-gray"),children:[e?.icon?u(Rt,{className:"p-5 rounded-full bg-secondary-light mr-[30px]",image:e.icon,width:"108",height:"108"}):null,p("div",{className:"flex gap-3.5",children:[e?.sum?Hs("страховая сумма",e.sum):null,e?.fee?Hs("страховой взнос",e.fee):null]}),Xs(l)]},String(t))}({slide:e,i:t,isActive:Boolean(t===l),onClick:()=>n(t)})))})})}function Hs(e,t){return p("div",{className:"flex flex-col text-left whitespace-pre",children:[p("span",{className:"text-h6",children:[ot(2)(t)," ₽"]}),u("span",{className:"text-secondary-text text-l mt-1",children:e})]})}function Xs(e){return e?u(Rt,{className:"h-6 w-6 min-w-6 min-h-6 absolute right-4 top-4",image:{icon:"DoneIcon"},width:"24",height:"24"}):null}const Ws=x((({className:e="",title:t,insuranceTabs:l=[],button:a,...r})=>{const[s,o]=n(0),c=i((e=>o(e)),[]);return p(C,{className:w("box-border overflow-hidden relative px-0",e),defaultPadding:"p-default",...r,children:[t?u(I,{className:"text-center mb-8",title:t,headingType:"h3"}):null,l?.length>1?u("div",{className:"p-1.5 bg-secondary-light w-fit mx-auto mb-7 rounded-md",children:l.map(((e,t)=>function({title:e,i:t,isActive:l,onClick:n}){return u("button",{type:"button",onClick:n,"aria-label":e,className:"box-border px-4 py-3 text-m-light "+(l?"bg-primary-main text-white rounded-md":"text-secondary-text"),children:e},String(t))}({title:e?.title,i:t,isActive:Boolean(t===s),onClick:()=>c(t)})))}):null,u("div",{className:"flex",style:{transform:`translateX(-${s}00%)`},role:"list",children:Ks({insuranceTabs:l,button:a})})]})})),Ks=({insuranceTabs:e,button:t})=>{const l=e?.map((e=>e.cards));return l?.length?l.map(((e,l)=>u(Fs,{button:t,cards:e},String(l)))):null};const Gs=e=>t=>t.reduce(((t,l,n)=>t.length?t.concat({...e,key:`sep-${n}`},l):[l]),[]),Js={yellow:"bg-yellow",green:"bg-green","green-light":"bg-green-light","green-dark":"bg-green-dark"},Ys={XS:"h-[40px]",S:"h-[68px]",M:"h-[102px]",L:"h-[136px]",XL:"h-[204px]"},qs=x((e=>{const{className:t="",items:l,isDotted:n,investmentZeroColumn:a,investmentColumns:i,...r}=e,s=i?[...i]:[];return a&&s.unshift(a),u(C,{className:t,...r,children:p("div",{className:"container text-m-light",children:[s?.length?p("div",{children:[p("div",{className:"flex items-end relative pl-9 pr-5 text-white",children:[Gs(u("div",{className:"w-px h-4 bg-gray"}))(s.map(Zs)),u("div",{className:"absolute right-[30px] w-px h-4 bg-gray"})]}),u("div",{className:"border-t border-gray -mt-2 ml-9 mr-8"}),u("div",{className:"flex justify-between text-primary-text mt-3 -mx-10",children:s.map(to)})]}):null,l?.length?u(ba,{className:"mt-9 max-w-[657px]",items:l,isDotted:n,listItemSize:"M"}):null]})})})),Zs=(e,t,l)=>{const n=1===t,a=t===l.length-1;return u("div",{className:`${Qs(n,a,e.cells)}`,children:e.cells?.length?u("div",{className:"w-full "+(a?"border-4 border-green-more-dark p-1.5 min-w-[290px]":""),children:e.cells.reverse().map(eo)}):null},`column_${t}`)},Qs=(e,t,l=[])=>[l.length?"flex-1":"flex-0",!l.length||e||t?"":"pl-2.5",l.length&&!t?"pr-2.5 pb-8":"pb-[22px]"].join(" "),eo=(e,t)=>{const l=e.cellSize||"XS",n=e.cellColor||"green";return e.text?u("div",{className:`flex-1 flex items-center justify-center relative py-2 ${Ys[l]} ${Js[n]} ${"XS"===l?"px-3":"px-11"}`,children:u("div",{className:"text-center",children:e.text})},`cell_${t}`):null},to=(e,t,l)=>{const n=0===t,a=t===l.length-1;return u("div",{className:`flex-1 max-w-[180px] text-center px-2 ${n?"pl-9":""} ${a?"mr-3.5":" "}`,children:e.title},`title_${t}`)},lo=x((({doc:e,icon:t})=>{const{text:l,fileSize:n,...a}=e;return p("a",{className:"flex box-border gap-3 group/item h-fit w-fit text-primary-text no-underline hover:text-primary-main",role:"link",...a,children:[t,l?p(me,{size:"text-l",font:"font-light",children:[l,u(me,{color:"text-secondary-text",children:a?.href&&no(ao(a.href),n)})]}):null]})})),no=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),ao=e=>{if(!e)return"";const t=e.lastIndexOf(".");return-1!==t?e.substring(t+1):""},io={double:"flex-wrap",single:"flex-col"},ro=x((({className:e="",title:t,description:l,align:n="text-center",documents:a,icon:i={icon:"DocIcon"},columnsMode:r="double",...s})=>p(C,{className:e,defaultPadding:"p-default",...s,children:[u(Qt,{className:"!p-0",title:t,description:l,align:n,headlineVersion:"M",as:"h2"}),a?.length?u("div",{className:w("mt-8 flex gap-6",io[r]),role:"list",children:a.map(((e,t)=>u("div",{className:"double"===r?"basis-[calc(50%-20px)]":"",role:"listitem",children:u(lo,{doc:e,icon:i?u(Rt,{className:"min-w-6 min-h-6",image:i,width:"24",height:"24"}):null})},String(t))))}):null]}))),so=e=>e?u("div",{className:"mb-5 pt-0.5 sm:mb-0 sm:pt-0",children:u(me,{size:"text-xl","font-weight":"light",children:e})}):null,oo=e=>e?.length?u(ba,{items:e,className:"text-l-light mb-2 last:mb-0"}):u("span",{className:"text-m-light text-secondary-text",children:"Наведите камеру телефона на QR-код и скачайте приложение"}),co=x((({className:e,padding:t,alignTitle:l="left",buttons:n=[],description:a,headingType:i="h4",image:r,items:s,qr:o,title:c="Мобильное приложение",version:d="primary",...m})=>{const h="secondary"===d?"p-3.5 min-w-[120px]":"min-w-[92px]";return u(C,{className:w("min-h-80",e),defaultPadding:"p-0",version:d,...m,children:p(ia,{className:"h-full",padding:t,defaultPadding:"p-default",title:c?u(I,{headingType:i,title:c,className:w("whitespace-pre-wrap",al[l])}):null,backImage:r?.src?u(Rt,{image:r}):null,buttons:Gt(n,{isVertical:n.length>3}),children:[so(a),p("div",{className:"flex flex-1 gap-s items-center",children:[o?.src?u("div",{className:w("flex justify-center bg-white rounded-md",h),children:u(Rt,{className:"w-fit",image:o})}):null,oo(s)]})]})})})),mo={},ho=x((({className:e,filtrationSchema:t={},resetButton:l,...n})=>{const[a,{field:i,reset:r}]=B(mo);return p(C,{className:w(e),defaultPadding:"p-0",version:"transparent",...n,children:[ki({field:i,reset:r,filtrationSchema:t,resetButton:l}),u(Ni,{filtrationState:a,...n})]})}));ho.childrenTypes=["ProductTile"],ho.childSchema=e=>e?.filtrationSchema||{};const uo=[{coords:[55.77,37.46],text:"Трактир"},{coords:[55.66,37.48],text:"Трактор"},{coords:[55.65,37.42],text:"Ресторан"},{coords:[55.64,37.54],text:"Музей"},{coords:[55.54,37.52],text:"Библиотека"},{coords:[55.53,37.56],text:"Школа"},{coords:[55.61,37.61],text:"Аптека"},{coords:[55.8,37.58],text:"Бар"},{coords:[55.71,37.35],text:"Институт"},{coords:[55.74,37.57],text:"Университет"},{coords:[55.58,37.69],text:"Больница"},{coords:[55.57,37.7],text:"Цирк"},{coords:[55.55,37.64],text:"Магазин"},{coords:[55.5,37.75],text:"Булочная"},{coords:[55.81,37.73],text:"Полиция"},{coords:[55.73,37.68],text:"Салон красоты"},{coords:[55.86,37.76],text:"Баня"},{coords:[55.38,37.69],text:"Гараж"},{coords:[55.91,37.5],text:"Дом"},{coords:[55.62,37.32],text:"Прачечная"},{coords:[55.85,37.41],text:"Стадион"},{coords:[55.67,37.24],text:"Вокзал"},{coords:[55.79,37.41],text:"Кафе"}];function po(e,t,l){t.geoObjects.removeAll();const n=e.templateLayoutFactory.createClass('<div style="margin-top: -3px;">{{properties.geoObjects.length}}</div>'),a=new e.Clusterer({clusterIcons:[{href:"icons/MapMarkerClusterIcon.svg",size:[78,84],offset:[-35,-50]}],clusterIconContentLayout:n,clusterHideIconOnBalloonOpen:!1,geoObjectHideIconOnBalloonOpen:!1}),i=l.map((t=>new e.Placemark(t,{},{iconLayout:"default#image",iconImageHref:"icons/MapMarkerSingleIcon.svg",iconImageSize:[78,84],iconImageOffset:[-35,-50]})));a.add(i),t.geoObjects.add(a),t.setBounds(e.util.bounds.fromPoints(l)).then((()=>{t.getZoom()>10&&t.setZoom(10)}))}const xo={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"flex items-center justify-center",font:"text-center font-sans"},go=e=>u("a",{className:`select-none cursor-pointer px-9 h-12 bg-primary-main text-white ${Object.values(xo).join(" ")}`,href:`https://yandex.ru/maps/?ll=${[e[1],e[0]]}&z=10&l=map`,target:"_blank",children:"Открыть на карте"}),fo={border:"border border-transparent rounded-md",position:"relative flex items-center",font:"text-center font-sans",shadow:"shadow-[0_4px_25px_rgba(0,0,0,0.07)]"},bo=(e,t,l)=>p("div",{className:`${Object.values(fo).join(" ")} bg-white py-3 pl-11 pr-4 w-full`,children:[u(je,{name:"LoupeIcon",iconVersion:"black",width:"20",height:"20",className:"absolute left-4"}),u("input",{type:"text",placeholder:"Введите адрес или метро",onChange:t=>{const n=t.target?.value?t.target?.value.toLowerCase():"";if(n){const t=e.filter((e=>e.text.toLowerCase().indexOf(n)>-1?e:null));l(t)}else l(null)},className:"border-0 focus:border-0 outline-0 w-full"})]}),vo={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"absolute flex items-center justify-center",font:"text-center font-sans"},No=(e,t,l)=>u("div",{className:`select-none cursor-pointer py-4 w-12 bg-white ${Object.values(vo).join(" ")} ${l}`,onClick:()=>{t.geolocation.get({provider:"yandex",autoReverseGeocode:!0,mapStateAutoApply:!0}).then((function(t){e.geoObjects.add(t.geoObjects)}))},children:u(je,{name:"UserGeoLocationIcon",width:"20",height:"16"})}),yo={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border-b border-b-2 border-gray last:border-0",position:"relative flex items-center justify-center",font:"text-center font-sans text-l"},wo=x((({yandexMaps:e,direction:t="in"})=>{const l="in"===t?"PlusIcon":"MinusIcon";return u("div",{onClick:()=>{const l=e.current.getZoom(),n="in"===t?l+1:l-1;e.current.setZoom(n,{checkZoomRange:!0})},className:`${Object.values(yo).join(" ")} bg-white select-none cursor-pointer w-12 h-12`,children:u(je,{name:l,width:"20",height:"16"})})})),ko={border:"border border-transparent rounded-md ",position:"absolute flex items-center justify-center",size:"w-12 h-12",focus:"focus:border-primary-text focus:border",font:"text-center font-sans",active:"active:bg-primary-active",hover:"hover:bg-primary-hover",other:"select-none cursor-pointer"},Co=x((({points:e,className:t="",zoom:l=5,showSearchField:i=!1})=>{const r=s(null),o=Ts("ymaps",`https://api-maps.yandex.ru/2.1/?apikey=${d.YANDEX_MAP_API_KEY||""}&lang=ru_RU`),[c,m]=n(),[h,x]=n(Bo(uo)),g=So(e);if(a((()=>{r?.current||o?.ready((()=>{r.current=new o.Map("map",{center:g,zoom:l,controls:[],suppressMapOpenBlock:!0}),po(o,r.current,h)}))}),[o,r,h]),a((()=>{if(r.current&&h&&o){const e=h.length<1?Bo(uo):h;po(o,r.current,e)}}),[r,h,o]),!o)return null;const f=c?"z-[100000]":"z-10";return p("div",{id:"map",className:`${c?"":"relative"} w-full ${t}`,children:[u("div",{className:`absolute flex left-2 top-4 w-[50%] ${f}`,children:i?bo(uo,0,(e=>{if(e){const t=Bo(e);x(t)}})):go(g)}),u("div",{className:`${Object.values(ko).join(" ")} ${f} right-2 top-4 bg-white`,onClick:()=>{const e=r.current.container;c?e.exitFullscreen():e.enterFullscreen(),m(e.isFullscreen())},children:u(je,{name:"FullScreenIcon",width:"16",height:"16"})}),p("div",{className:`absolute right-2 top-52 z-10 w-12 overflow-hidden border border-transparent rounded-md ${f}`,children:[u(wo,{yandexMaps:r}),u(wo,{yandexMaps:r,direction:"out"})]}),No(r.current,o,`right-2 top-80 ${f}`)]})})),So=e=>[To(Io(e,0)),To(Io(e,1))],Io=(e,t)=>e.map((e=>e[t])),To=e=>e.reduce(((e,t)=>e+t))/e.length,Bo=e=>e?e.map((e=>e.coords)):null,Ro={id:123,branchType:{id:7,code:"21",name:"Отделение на балансе филиала"},shortName:"Ейский ДО",name:"ДО №3349/3/05",address:"353682, Краснодарский край, г.Ейск, ул.Гоголя, 349/ ул.Баррикадная, 42/1",lawAddress:"353682, Краснодарский край, г.Ейск, ул.Гоголя, 349/ ул.Баррикадная, 42/1",openDate:"2000-12-05",closeDate:null,bik:"040349536",corAcc:"30101810700000000536",registrationNumber:"3349/3/05",phone:"+7(XXX)XXX-XX-XX",fax:"+7(XXX)XXX-XX-XY",okpo:"55105921",ogrn:"1027700342890",kpp:"231002002",inn:"7725114488",branchCode:"0305",upperBranchCode:"0300",timeZone:"+03:00",exchangeRate:{currencies:[{buyExchangeRate:0,saleExchangeRate:0,currency:{id:3,code:"156",currency:"CNY",name:"Китайский юань"}},{buyExchangeRate:59.15,saleExchangeRate:69.25,currency:{id:2,code:"978",currency:"EUR",name:"Евро"}},{buyExchangeRate:58.4,saleExchangeRate:70.05,currency:{id:1,code:"840",currency:"USD",name:"Американский доллар"}}],lastUpdate:"2022-11-11 03:56:17"},workSchedule:{id:413,workTime:"09.00–16.30",lunchHour:"без перерыва",workTimeSaturday:"09.00–15.00",lunchHourSaturday:"без перерыва",workingMonday:!1,workingTuesday:!1,workingWednesday:!0,workingThursday:!0,workingFriday:!0,workingSaturday:!0,workingSunday:!1},gpsLatitude:46.709744,gpsLongitude:38.260703,range:null,safeBoxCaseVolumes:null},Po=[{title:"Деловой центр",time:"1 мин",distance:"~30 м.",icon:"MetroIcon"},{title:"Выставочная",time:"5 мин",distance:"~120 м.",icon:"MetroIcon"},{title:"Деловой центр",time:"8 мин",distance:"~350 м.",icon:"MetroIcon"}],$o=({lunchHour:e,status:t,workTime:l})=>{const n=/\d+/gi.test(e)?`Перерыв ${e}`:e;return t?p("div",{className:"flex",children:[u("div",{className:"p-3 border rounded-md text-m flex items-center cursor-pointer text-primary-main border-green-light mr-4",children:l||null}),u("div",{className:"p-3 border rounded-md text-m flex items-center cursor-pointer text-yellow border-golden",children:e?n:null})]}):u("div",{className:"flex",children:u("div",{className:"p-3 border rounded-md text-m flex items-center cursor-pointer text-error border-error",children:"Выходной"})})},Mo=({icon:e,title:t,distance:l,time:n},a)=>p("div",{className:"flex mr-4",children:[u(je,{name:e,width:"16",height:"16",className:"mr-1"}),t?p("span",{className:"text-m",children:[t," "]}):null,p("span",{className:"text-m-light",children:[l?` (${l})`:null,n?`, ${n}`:null]})]},`nearbyOffice${a}`),_o=({title:e,status:t,workTime:l,lunchHour:n,description:a},i)=>p("div",{className:"flex flex-col pb-3 border-b border-solid border-main-divider mb-3 last:border-0",children:[p("div",{className:"flex justify-between items-center w-full pb-1 text-l text-primary-text",children:[u("div",{children:e}),t?null:u("div",{className:"text-m-light text-error",children:"Выходной"}),t&&l?u("div",{children:l}):null]}),t&&n?Vo(n):null,a?u("div",{className:"pb-1 text-s-light text-secondary-text",children:a}):null]},`day${i}`),Vo=e=>/\d+/gi.test(e)?p("div",{className:"flex justify-between items-center w-full pb-1 text-m-light text-error",children:[u("div",{children:"Перерыв"}),u("div",{children:e})]}):u("div",{className:"flex justify-between items-center w-full pb-1 text-m-light text-primary-main",children:u("div",{children:e})}),jo=x((({className:e=""})=>{const t=Ro,{name:l,address:n,gpsLatitude:a,gpsLongitude:i,workSchedule:r}=t,{workingMonday:s,workingTuesday:o,workingWednesday:c,workingThursday:d,workingFriday:m,workingSaturday:h,workingSunday:x}=r,{workTime:g,lunchHour:f,workTimeSaturday:b,lunchHourSaturday:v}=r,N=a&&i?[a,i]:null,y=[{title:"Понедельник",status:s,workTime:g,lunchHour:f},{title:"Вторник",status:o,workTime:g,lunchHour:f},{title:"Среда",status:c,workTime:g,lunchHour:f},{title:"Четверг",status:d,workTime:g,lunchHour:"13:00 - 14:00",description:"Не работает прием денег с 17:00 до 19:00"},{title:"Пятница",status:m,workTime:g,lunchHour:f},{title:"Суббота",status:h,workTime:b,lunchHour:v},{title:"Воскресенье",status:x}],w=(new Date).getDay(),k=w>0?y[w-1]:y[6];return p("div",{className:`flex flex-col font-sans bg-white w-full ${e}`,children:[p("div",{className:"flex flex-col px-12 pt-12",children:[p("div",{className:"flex justify-between",children:[u("div",{className:"text-h2",children:l}),$o(k)]}),p("div",{className:"flex text-l-light pt-4",children:[u(je,{name:"GeolocationIcon",width:"24",height:"24",className:"pr-1"}),n]}),u("div",{className:"flex pt-4",children:Po.map(Mo)})]}),p("div",{className:"flex justify-between pt-8",children:[u("div",{className:"flex-grow h-full w-full overflow-hidden",children:N?u(Co,{points:[N],className:"h-full"}):null}),u("div",{className:"w-[434px] min-w-[434px] pl-9 pr-12 pb-14 flex flex-col",children:y.map(_o)})]})]})})),zo=x((({className:e="",title:t,servicesList:l,...n})=>p(C,{className:w("flex flex-col",e),...n,children:[t?u(I,{headingType:"h5",className:"mb-5",title:t}):null,l?.length?u("ul",{className:"list-none m-0 p-0",children:l.map(Do)}):null]}))),Do=(e,t)=>p("li",{className:"flex mb-5 last:mb-0 list-none",children:[e.icon?u(Rt,{className:"mr-3 min-w-6 min-h-6 w-6 h-6",width:"24",height:"24",image:e.icon}):null,e.label?u("span",{className:"text-l-light",children:e.label}):null]},`list_item_${String(t)}`),Lo=x((({text:e,size:t,align:l,font:n,children:a,...i})=>u(C,{defaultPadding:"p-0",...i,children:u(de,{size:t,align:l,font:n,children:e||a})}))),Ao=(e=[])=>e?.length?wr(e)/e.length:0,Oo=x((({className:e,icon:t,label:l,description:n,benefitsVersion:a="normal"})=>p("div",{className:w("flex gap-s",n?"items-start":"items-center",e),children:[t?u("div",{className:Eo(a),children:u(Rt,{className:"w-6 h-6",image:{...t,iconVersion:t.iconVersion||a}})}):null,p("div",{className:"gap-0.5",children:[l?u(me,{color:"text-primary-text group-data-secondary:text-white",size:"text-h6",children:l}):null,n?u(de,{font:"font-light",size:"text-m",color:"text-secondary-text group-data-secondary:text-white",children:n}):null]})]})));function Eo(e){return w("w-12 h-12 min-w-12 p-2.5 box-border flex items-center justify-center rounded-icon","normal"===e?"bg-secondary-light text-primary-main":"bg-primary-main text-black group-data-secondary:bg-white/30 group-data-secondary:text-black")}const Fo=e=>({type:t,...l},n)=>"rte"===t&&"__html"in l?u(ja,{__html:l.__html}):u(Oo,{benefitsVersion:e,...l},String(n)),Uo=e=>"rte"===e.type?e.__html?.length||0:Math.max(e.label?.length||0,e.description?.length||0),Ho=e=>{return((t=e.map(Uo))?.length?Math.sqrt(Math.abs(Ao(t.map((e=>e**2)))-Ao(t)**2)):0)>16;var t},Xo=x((({className:e,benefitsVersion:t="normal",benefits:l})=>l?.length?u("div",{className:w("flex gap-x-m gap-y-s",Ho(l)?"flex-col":"flex-wrap",e),children:l.map(Fo(t))}):null)),Wo=x((({className:e,tags:t})=>t?.length?u("div",{className:w("flex flex-wrap gap-xs",e),role:"list",children:t.map(Ko)}):null)),Ko=(e,t)=>u("div",{className:"py-2 px-2.5 border-solid border rounded-md border-gray",role:"listitem",children:u(me,{size:"text-m-light",children:e})},String(t)),Go=x((({className:e,title:t,description:l,headlineVersion:n="L",align:a="text-left",isInsetTitle:i=!0,benefits:r,benefitsVersion:s,__html:o,items:c,isDotted:d=!0,listItemSize:m,tags:h,buttons:x,image:g,imageOptions:{imageAlign:f,directionRight:b=!0}={},children:v})=>{const N=g?.src?u(Rt,{image:g}):null,y=u(Qt,{title:t,description:l,headlineVersion:n,align:a,isPadding:!1});return u(ia,{className:e,...i?{insetTitle:y}:{title:y},...b?{rightImage:N}:{leftImage:N},imageAlign:f,buttons:Gt(x),children:p("div",{className:"flex flex-col gap-m",children:[u(Xo,{benefitsVersion:s,benefits:r}),o?u(ja,{__html:o}):null,c?.length?u(ba,{items:c,isDotted:d,listItemSize:m}):null,v,h?.length?u(Wo,{tags:h}):null]})})})),Jo=(e,t)=>e||t?p("div",{className:"flex flex-wrap xl:flex-nowrap xl:bg-main-divider xl:rounded-md p-xs gap-m",children:[Number(e)>0?Yo("Страховая сумма:",e):null,Number(t)>0?Yo("Ежемесячный лимит:",t):null]}):null,Yo=(e,t=0)=>p("div",{className:"basis-full flex flex-col-reverse sm:flex-row sm:justify-between items-baseline whitespace-pre",children:[u(me,{font:"font-light",size:"text-l",children:e}),p(me,{size:"text-h6",color:"text-primary-text",children:[ot(2)(t)," ₽"]})]}),qo=x((({className:e,headlineVersion:t="M",align:l="text-center",sum:n,monthLimit:a,...i})=>u(C,{className:e,defaultPadding:"p-default",...i,children:u(Go,{className:"h-full",headlineVersion:t,align:l,isInsetTitle:!1,...i,imageOptions:{directionRight:!1,imageAlign:"center",...i.imageOptions},children:Jo(Number(n),Number(a))})}))),Zo=x((({className:e,title:t,description:l="Блок в разработке...",...n})=>p(C,{className:w("box-border",e),...n,children:[u(Qt,{className:"max-w-[600px]",title:t,description:l,headlineVersion:"L",align:"text-left",isPadding:!1}),u("figure",{className:"m-0 mt-m min-w-[80%]",children:Qo()})]}))),Qo=(e=3)=>tc(100,e).map((e=>Math.floor(e))).map(ec),ec=(e,t)=>u("div",{style:{width:`${e||100}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),tc=(e,t)=>[e].concat(t>0?tc(e/1.618,t-1):[]);function lc({text:e,href:t,target:l,icon:n},a){const i="primary"===a?"white":"black",r={text:e,href:t,target:l,ariaLabel:e};return p("div",{className:"flex items-center gap-3",children:[u(se,{className:"w-12 h-12 min-h-12 min-w-12 flex items-center justify-center",version:a,rounded:!0,...r,children:u(Rt,{className:"w-4 h-4",image:{...n,icon:n?.icon||"ArrowLeftIcon",iconVersion:n?.iconVersion||i}})}),u(se,{version:"link",...r})]})}const nc=x((({className:e,backwardButton:t,...l})=>p(C,{className:w("overflow-hidden flex flex-col gap-lg box-border",e),defaultPadding:"p-default",...l,children:[t?.text?lc(t,l.version&&"primary"!==l.version?"white":"primary"):null,u(Go,{className:"grow h-full",...l})]}))),ac=x((({className:e="",slides:t=[],...l})=>{const[a,i]=n(0);return p(C,{className:w("box-border overflow-hidden",e),defaultPadding:"py-default",...l,children:[u("div",{className:"flex duration-1000",style:{transform:`translateX(-${100*a}%)`},role:"list",children:t.map((({productBlock:e},t)=>u("div",{className:"box-border grow-0 shrink-0 basis-full",role:"listitem",children:u(Go,{className:"pl-default h-full",headlineVersion:"XXL",...e,...l})},String(t))))}),u("div",{className:"h-28 px-xs mt-m -mb-m flex gap-xs box-border",children:t.map(ic({activeSlideIndex:a,onClick:i}))})]})})),ic=({activeSlideIndex:e,onClick:t})=>({nav:l},n)=>{const a=n===e,i=a?"min-w-[350px] bg-white shadow-dark-blue border-none p-6":"min-w-[290px] ease-in duration-300 bg-white/10 px-6 py-5 hover:py-6 backdrop-blur",r=a?"text-primary-text text-h6 py-2":"text-l pb-1 text-secondary-text group-data-secondary:text-white",s=a?"text-secondary-text text-l-light":"text-m-light text-secondary-text group-data-secondary:text-white/80";return p("button",{type:"button",onClick:()=>t(n),"aria-label":l?.title,className:w("relative px-6 box-border overflow-hidden text-left grow basis-0 border border-gray group-data-secondary:border-white/50",i),children:[u("div",{className:r,children:l?.title}),u("div",{className:s,children:l?.description})]},String(n))};function rc(e,t){if(!e)return null;return u("div",{className:`mt-2.5 z-10 ${t?.src?"max-w-[calc(100%-186px)]":"100%"}`,children:u(de,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:e})})}const sc=(e,t)=>{const{type:l}=e;if("default"!==l&&"rte"!==l)return null;switch(l){case"default":return[u(me,{size:"text-h6",children:e.label},`label-${t}`),u(me,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:e.description},`desc-${t}`)];case"rte":return u("div",{className:"col-span-2",children:u(ja,{__html:e.__html})});default:fr(e)}};function oc(e,t){return e?.src?u(Rt,{className:w("absolute",t?"right-0":"left-0","bottom-0"),image:e}):null}const cc=x((({className:e="",title:t,headlineVersion:l="S",description:n,additionalDescription:a,benefits:i=[],buttons:r,image:s,directionRight:o=!0,...c})=>p(C,{className:w("overflow-hidden box-border relative min-h-[364px] flex flex-col justify-between",e),...c,children:[p("div",{className:w("flex flex-col",o?"":"items-end"),children:[u(Qt,{className:w("!p-0 !bg-transparent z-10",t||n?"mb-3.5":""),title:t,description:n,headlineVersion:l,as:"h2",align:"text-left"}),dc(i,s),rc(a,s)]}),Gt(r,{className:w("mt-5 text-l",o?"":"justify-end")}),oc(s,o)]})));function dc(e,t){if(!e.length)return null;return u("div",{className:w("z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline",t?.src?"max-w-[calc(100%-186px)]":"100%"),children:e.length?e.map(sc):null})}const mc=x((({className:e,title:t="Акции и спецпредложения",description:l,headlineVersion:n="S",date:a,buttons:i=[],...r})=>u(C,{className:w("box-border",e),...r,children:p(ia,{className:"h-full",title:t?u(Qt,{title:t,headlineVersion:n,align:"text-left",isPadding:!1}):null,buttons:Gt(i),children:[a?u("div",{className:"text-s mb-2",children:hc(a)}):null,u("div",{className:"text-l",children:l})]})})));function hc(e){return new Date(e).toLocaleString("ru-RU",{day:"numeric",month:"long",year:"numeric"}).replace("г.","")}const uc=x((({address:e,email:t,telephone:l,button:n,className:a="",__html:i,icon:r,title:s,version:o="primary",...c})=>p(C,{className:w("box-border text-left",a),version:o,...c,children:[p("div",{className:"w-full flex justify-between",children:[s?u(I,{headingType:"h4",as:"h3",className:"mb-6",title:s}):null,pc(r)]}),p("div",{className:"w-full",children:[i?xc(i):null,gc("Адрес",e,"GeolocationIcon"),gc("Телефон",l,"PhoneIcon"),gc("E-mail",t,"MailIcon"),n?.text?Gt([n],{className:"mb-6"}):null]})]}))),pc=e=>p("div",{className:"self-end",children:[e?.src?u(Rt,{image:e}):null,e?.icon?u(Rt,{image:e}):null]}),xc=e=>u("div",{className:"border-b border-main-divider pb-5 my-5",children:u(ja,{__html:e})}),gc=(e,t,l)=>p("div",{className:"flex mb-4",children:[u(je,{className:"pr-4",iconVersion:"black",name:l,width:"24",height:"24"}),p("div",{className:"flex flex-col first:pb-1",children:[u(me,{size:"text-m-light",children:e}),t?u(me,{size:"text-h6",color:"text-green",children:t}):null]})]}),fc=x((e=>{const{__html:t,richVersion:l,...n}=e;return u(C,{defaultPadding:"p-0",...n,children:u(ja,{__html:t,richVersion:l})})})),bc=e=>e?"MinusIcon":"PlusIcon",vc=x((({className:e="",label:t="Развернуть",labelIcon:l,labelIconBgVersion:n,isExpanded:a,isFoldButtonOnTop:i=!0,version:r="primary",...s})=>u(C,{className:w("w-full","border-0 border-b border-solid border-main-divider last:border-b-0",e),defaultPadding:"p-0",tag:"div",version:"transparent",...s,children:u(Da,{isFoldButtonOnTop:i,unfoldedByDefault:a,renderFoldableSection:({isUnfolded:e})=>u(La,{className:w("gap-5 [&>*]:p-0","grid grid-cols-12 [&>*]:pb-4"),isUnfolded:e,children:kn(s)}),renderFoldButton:({isUnfolded:e,onToggle:a})=>Nc({version:r,label:t,labelIcon:l,labelIconBgVersion:n,isUnfolded:e,onToggle:a})})})));vc.childrenTypes={exclude:["RollupItem"]};const Nc=({version:e,label:t,labelIcon:l,labelIconBgVersion:n,isUnfolded:a,onToggle:i})=>{const r=t||(a?"Скрыть":"Развернуть");return"primary"===e?yc({label:r,labelIcon:l,labelIconBgVersion:n,icon:bc(a),onToggle:i}):u(gi,{label:r,icon:a?"ArrowUpIcon":"ArrowDownIcon",onClick:i})},yc=({label:e,labelIconBgVersion:t,icon:l,onToggle:n,labelIcon:a})=>p("button",{className:w("border-none bg-transparent px-0 flex justify-between items-center w-full group/button",a?.icon?"py-2":"py-5"),onClick:n,children:[p("div",{className:"flex items-center group-hover/button:text-primary-main",children:[null,e?u(me,{size:"text-h6",font:"font-normal",children:e}):null]}),l?u(je,{name:l,iconVersion:"color",width:"24",height:"24"}):null]}),wc=x((({data:e,fieldLabel:t,fieldValue:l,selected:n,placeholder:a="",setSelected:i,label:r})=>{const s=e.filter(Boolean).map((e=>({key:e?.[l||t],text:e?.[t]}))),o=s.find((e=>e.key===n));return u(Le,{options:s,label:r,placeholder:a||n,onChange:e=>i(e.key),value:o})})),kc=x((({regions:e=[],selectedRegion:t,onSelectedRegion:l,branches:n=[],selectedBranch:a,onSelectedBranch:i})=>p("div",{className:"flex justify-between gap-4 mb-6",children:[u("div",{className:"max-w-[396px] w-1/2",children:u(wc,{data:e,fieldValue:"code",fieldLabel:"name",selected:t,setSelected:l,label:"Регион"})}),u("div",{className:"max-w-[396px] w-1/2",children:u(wc,{data:n,fieldValue:"branchCode",fieldLabel:"address",selected:a,setSelected:i,label:"Отделение",placeholder:"Выберите отделение"})})]}))),Cc=x((({name:e,text:t,value:l,checked:n,onChange:a,className:i})=>u("div",{className:i,children:p("label",{className:"font-sans flex items-center relative cursor-pointer",children:[u("input",{className:"appearance-none flex justify-center items-center shrink-0 w-5 h-5 border border-gray hover:border-primary-hover\n checked:border-2 checked:!border-primary-main focus:checked:border-primary-main focus:border-primary-text active:border-primary-text\n after:block after:w-2.5 after:h-2.5 after:rounded-full checked:after:bg-primary-main outline-none rounded-full cursor-pointer",type:"radio",value:l,name:e,checked:n,onChange:e=>a(e.target.value)}),t?u("span",{className:"text-primary-text ml-3 cursor-pointer",children:t}):null]})}))),Sc=x((()=>{const[e,t]=n("option2"),l=i((e=>t(e)),[]);return p("div",{children:[u(Cc,{className:"mb-2",name:"contractType",text:"Простое хранение",value:"option1",checked:"option1"===e,onChange:l}),u(Cc,{name:"contractType",text:"Сделка с недвижимостью",value:"option2",checked:"option2"===e,onChange:l})]})})),Ic=["От 1 дня","До 365 дней"],Tc=x((({days:e,setDays:t})=>p("div",{className:"mb-6",children:[u("span",{className:"block text-m-light mb-[3px]",children:"Срок аренды"}),u(ut,{min:1,max:365,value:e,items:Ic,onChange:t})]}))),Bc=x((({caseVolumes:e=[],selectedCaseVolume:t,onSelectedCaseVolume:l,safeBoxCases:n=[],selectedBoxSize:a,onSelectedBoxSize:i})=>p("div",{className:"flex justify-between mb-6",children:[u("div",{className:"mr-4 w-full",children:u(wc,{data:e,fieldLabel:"volume",selected:t,setSelected:l,label:"Размер",placeholder:"Выберите размер"})}),u("div",{className:"w-full",children:u(wc,{data:n,fieldLabel:"safeBoxCasesSize",selected:a,setSelected:i,label:"Параметры ячейки, мм (ВхШхД)",placeholder:"Выберите параметр ячейки"})})]}))),Rc=x((({regions:e,selectedRegion:t,branches:l,selectedBranch:n,days:a,selectedCaseVolume:i,selectedBoxSize:r,safeBoxCases:s,caseVolumes:o,onChange:c,onClick:d})=>p("div",{className:"flex-1 mr-9",children:[u(kc,{regions:e,selectedRegion:t,onSelectedRegion:e=>c({selectedRegion:e}),branches:l,selectedBranch:n,onSelectedBranch:Pc(c)}),u(Tc,{days:a,setDays:e=>c({days:e})}),u(Bc,{caseVolumes:o,selectedCaseVolume:i,onSelectedCaseVolume:$c(c),safeBoxCases:s,selectedBoxSize:r,onSelectedBoxSize:e=>c({selectedBoxSize:e})}),u("span",{className:"text-secondary-text text-l-light",children:"Тип договора"}),p("div",{className:"flex justify-between items-center mt-5",children:[u(Sc,{}),u(se,{text:"Офисы на карте",version:"primary",onClick:d})]})]}))),Pc=e=>t=>{e({selectedBranch:t,selectedCaseVolume:"",selectedBoxSize:""})},$c=e=>t=>{e({selectedCaseVolume:t,selectedBoxSize:""})},Mc=x((({days:e,tariffs:t=[]})=>{const l=Vc(e,t);return p("div",{className:"flex flex-col justify-between",children:[p("div",{className:"flex",children:[_c("Аренда за",e,"mr-11"),_c("Цена",l+" ₽")]}),p("div",{className:"bg-primary-main px-10 pt-10 pb-4 text-center",children:[u(Rt,{image:{icon:"PackA4Icon"},width:"290",height:"257"}),p("span",{className:"text-s-light text-white opacity-80 mt-2 inline-block",children:["На рисунки изображена пачка",u("br",{})," листов формата А4"]})]})]})})),_c=(e,t,l="")=>p("div",{className:l,children:[u("div",{className:"text-m-light text-secondary-text mb-1",children:e}),u("span",{className:"text-h3 text-primary-text",children:t})]}),Vc=(e,t)=>{const l=jc(e);return e*(t?.find((e=>e.tariffType===String(l)))?.tariffValue||0)},jc=e=>{let t=1;switch(!0){case e>30&&e<=90:t=2;break;case e>90&&e<=180:t=3;break;case e>180&&e<=365:t=4}return t},zc=(e,t)=>e.find((e=>e.branchCode===t)),Dc=x((e=>{const{regions:t,data:l,branches:n,onChange:i,onClick:r}=e;a((()=>{i({selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:""})}),[l.selectedRegion,i]);const s=zc(n,l.selectedBranch),o=Lc(s?.safeBoxCaseVolumes),c=Ac(s?.safeBoxCaseVolumes,l.selectedCaseVolume)?.safeBoxCases,d=Oc(c,l.selectedBoxSize);return p("div",{className:"flex justify-between align-top mb-6",children:[u(Rc,{...l,regions:t,onClick:r,branches:n,caseVolumes:o,safeBoxCases:c,onChange:i}),u(Mc,{days:l.days,tariffs:d})]})})),Lc=e=>e?.length?e?.filter((e=>e?.safeBoxCases?.length)):[],Ac=(e,t)=>e?.find((e=>e.volume===t)),Oc=(e,t)=>e?.find((e=>e.safeBoxCasesSize===t))?.tariffs,Ec=[];const Fc=async e=>await z(e,{method:"GET"})||Ec,Uc=x((({title:e,footnote:t,className:l="",...a})=>{const[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),[c,d]=n({selectedRegion:"",selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:"",days:26}),m=A(),h=Hc(c.selectedRegion,m),x=function(e){const{data:t}=V(e?`/api/v1/safeboxes?regionCode=${e}`:null,Fc);return t||Ec}(h),g=i((e=>d((t=>({...t,...e})))),[d]),f=(b=zc(x,c.selectedBranch)||x,Array.isArray(b)?b.map((e=>e.gpsLatitude&&e.gpsLongitude?[e.gpsLatitude,e.gpsLongitude]:[])):b?.gpsLatitude&&b?.gpsLongitude?[[b.gpsLatitude,b.gpsLongitude]]:[]);var b;return p(C,{className:l,defaultPadding:"",...a,children:[p("div",{className:"px-8 py-12",children:[e?u(I,{title:e,headingType:"h3",as:"h2",className:"text-primary-text mb-2.5 text-center"}):null,u(Dc,{regions:m,branches:x,data:{...c,selectedRegion:h},onClick:o,onChange:g}),t?u("p",{className:"text-s-light text-secondary-text",children:t}):null]}),f.length&&r?u(Co,{points:f,className:"h-[640px]"}):null]})})),Hc=(e,t)=>!e&&t?.length&&t[0]?.code?t[0].code:e,Xc=e=>Boolean(e?.icon||e?.src),Wc=({styleMap:e,isMainButton:t,version:l})=>(n,a,i)=>{const{label:r,description:s,button:o,items:c,isDotted:d}=n;return p("div",{className:w("relative flex flex-col items-center text-center whitespace-pre-line overflow-hidden",Kc(i.length)),children:[p("div",{className:w(o?.text?"mb-8":"","text-center"),children:[r?u("div",{className:"mb-2",children:u(me,{size:"text-h6",children:r})}):null,p("div",{className:"flex flex-col items-center",children:[s?u("div",{className:e.description,children:s}):null,u(ba,{className:w(s?`${e.description} mt-0.5`:"text-h6"),items:c,listItemSize:"M",isDotted:d})]})]}),o?.text&&!t?u(se,{className:"box-border py-3 h-12 w-full max-w-[240px] mt-auto",version:l,...o,children:o?.text}):null]},String(a))},Kc=e=>e<5?"w-[276px]":"w-[210px]",Gc={description:"text-white/80 text-l-light group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconText:"text-white group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconBackground:"bg-white/30 group-data-primary:bg-main-divider",iconConnector:"bg-white group-data-primary:bg-secondary-light",dot:"bg-white/80 group-data-primary:bg-secondary-text"},Jc=x((({className:e="",showLines:t=!0,steps:l=[],buttons:n,size:a="normal",version:i="primary",stepVersion:r="gray",title:s,...o})=>{const c=l.length>3,d=Gc,m=(e=>e?"":"opacity-0")(t),h=(e=>e<5?"px-[88px]":"px-[55px]")(l.length),x=Boolean(n?.every((e=>e?.text)));return p(C,{className:w("box-border flex flex-col items-center overflow-hidden",e),defaultPadding:"p-default",version:i,...o,children:[s?u(I,{headingType:"h4",className:"max-w-[752px] text-center mb-9",title:s}):null,l?.length?p("div",{className:"box-border",children:[u("div",{className:w("flex items-center",h),children:Gs(u("div",{className:w("h-0.5 w-full bg-secondary-light flex-1",m)}))(l.map(Yc(d,a,r)))}),u("div",{className:w("flex justify-between mt-4",c?"gap-x-3":"gap-x-[101px]"),children:l.map((g={styleMap:d,isMainButton:x,version:i},(e,t,l)=>{const{type:n}=e;if("default"!==n&&"rte"!==n)return null;switch(n){case"default":return Wc(g)(e,t,l);case"rte":return u("div",{className:w("text-center",Kc(l.length)),children:u(ja,{__html:e.__html})},String(t));default:return null}}))})]}):null,Gt(n,{className:"mt-8"})]});var g})),Yc=(e,t,l)=>({icon:n},a)=>{const i="secondary"===l?"group-data-primary:text-white":"text-secondary-text",r="secondary"===l?"white":"color";return u(C,{className:`${"normal"===t?"h-[100px] w-[100px]":"h-[63px] w-[63px]"} flex justify-center items-center text-center rounded-full p-[26px] box-border z-10`,version:l,children:Xc(n)?u(Rt,{image:{...n,iconVersion:n.iconVersion||r},width:"48",height:"48"}):u("span",{className:w("text-h4","transparent"===l?e.iconText:i),children:a+1})},String(a))},qc=x((({className:e,version:t,gap:l=14,padding:n=16,showDots:a=!0,minHeight:i,children:r,onVisibleIndicesChange:s,listType:o="horizontal-list"})=>{const c=Array.isArray(r)?r.length:0,[d,m]=jn({itemCount:c,onVisibleIndicesChange:s}),[h]=m.visibleIndicesRange;return p("div",{className:w(e,"vertical-list"===o?"relative h-full":""),children:[u(Tn,{containerRef:d,activeIndex:h,visibleItemCount:1,gap:l,padding:n,onVisibleIndicesChange:m.handleVisibleIndicesChange,listType:o,minHeight:i,children:r}),a?u(Mn,{containerRef:d,activeIndex:h,dotCount:c,listType:o,version:t}):null]})})),Zc=x((({listType:e,showDots:t,options:l,version:n,...a})=>u(C,{version:n,defaultPadding:"p-0",...a,children:u(qc,{listType:e,showDots:t,version:n,children:kn({...a,options:l})})})));Zc.childrenTypes={exclude:["SwipeListControlBlock"]};const Qc="h-12 flex-1 flex items-center justify-center cursor-pointer",ed="font-sans text-m text-center",td="text-white",ld="text-secondary-text group-hover/btn:text-primary-main",nd="text-primary-main",ad={div:{scrollable:{active:`inline-flex px-4 grow whitespace-nowrap ${Qc} bg-white text-primary-main`,default:`inline-flex px-4 grow whitespace-nowrap ${Qc} group/btn bg-white`},centered:{active:`px-4 rounded-md ${Qc} bg-primary-main text-white whitespace-nowrap`,default:`px-4 rounded-md ${Qc} group/btn bg-transparent whitespace-nowrap`},wideScreen:{active:`${Qc} bg-primary-main text-white whitespace-nowrap`,default:`${Qc} group/btn bg-white whitespace-nowrap`}},text:{scrollable:{active:"h-full border-0 border-b-2",default:""},centered:{active:"",default:""},wideScreen:{active:"",default:""}}},id={link:{scrollable:{active:`inline-flex px-4 grow whitespace-nowrap ${Qc} bg-white text-primary-main`,default:`inline-flex px-4 grow whitespace-nowrap ${Qc} group/btn bg-white`},centered:{active:`px-4 rounded-md ${Qc} bg-primary-main text-white whitespace-nowrap`,default:`px-4 rounded-md ${Qc} group/btn bg-transparent whitespace-nowrap`},wideScreen:{active:`${Qc} bg-primary-main text-white`,default:`${Qc} group/btn bg-white`}},text:{scrollable:{active:`${ed} flex items-center h-full border-0 border-b-2 text-primary-main`,default:`${ed} ${ld}`},centered:{active:`${ed} text-white`,default:`${ed} ${ld}`},wideScreen:{active:`${ed} text-white`,default:`${ed} ${ld}`}}},rd=(e,t,l)=>{const n=t?"active":"default";return ad[e][l||"wideScreen"][n]},sd=(e,t,l)=>{const n=t?"active":"default";return id[e][l||"wideScreen"][n]},od=x((e=>{const{tab:t,currentTab:l,onClick:n,tabsMode:a}=e,i="link"===l?.type&&l.href===t.href,r=Y()(t);return u("a",{role:"tab",className:sd("link",i,a),target:t.target,href:r.href,onClick:e=>{r.onClick(e),n(t)},children:u("span",{className:sd("text",i,a),children:t.text})})})),cd=(e,t,l)=>e?u("h3",{className:"scrollable"===l?`${ed} ${t?nd:ld}`:`${ed} ${t?td:ld}`,children:e}):null,dd=(e,t,l)=>e&&t?u("div",{className:"min-w-[22px] h-[22px] rounded-full text-xs ml-2 flex justify-center items-center "+(l?"bg-white/30 text-white":"bg-main-divider text-secondary-text group-hover/btn:text-primary-main"),children:t}):null,md=({page:e,showCounter:t,...l})=>(n,a)=>{const i=n.type;if("group"!==i&&"link"!==i)return null;switch(i){case"group":return(({page:e,currentTab:t,showCounter:l,onClick:n,tabsMode:a})=>(i,r)=>{const s=t===i,o=i.ref&&e?.blocks?e.blocks.filter((e=>e?.labels?.includes(i.ref))).length:0;return u("div",{className:rd("div",s,a),role:"tab","aria-selected":s,onClick:()=>n(i),children:p("div",{className:`flex flex-1 items-center justify-center ${rd("text",s,a)}`,children:[cd(i.title,s,a),dd(l,o,s)]})},`group-${String(r)}`)})({page:e,showCounter:t,...l})(n,a);case"link":return u(od,{tab:n,...l},String(a));default:fr(i)}return null},hd=x((({tabs:e,...t})=>u("div",{className:"flex p-1 m-auto bg-main-gray rounded-md",children:e?.map(md({...t}))}))),ud=x((e=>{const{tabs:t,...l}=e,[n,a]=jn({itemCount:t?.length||0,isCyclic:!1});return p("div",{className:"relative max-w-full m-auto",children:[u("div",{className:"font-sans max-w-full w-full overflow-hidden relative bg-white",children:u(Tn,{containerRef:n,snapAlign:"snap-start",onVisibleIndicesChange:a.handleVisibleIndicesChange,children:t?.map(md({...l}))})}),a.canScrollLeft?u(pl,{className:"absolute z-40 top-0 left-6",onClick:a.scrollLeft}):null,a.canScrollRight?u(xl,{className:"absolute z-40 top-0 rotate-180 right-6",onClick:a.scrollRight}):null]})})),pd=x((e=>{const{className:t="",tabs:l,isSticky:r,...s}=e,[o,c]=n(l?l[0]:void 0);a((()=>{l&&l[0]&&gd(l[0])}),[]),a((()=>{"group"===o?.type&&b.subject("tab",{type:o.type,label:o.ref})}),[o]);const d=i((e=>{gd(e),c(e)}),[]);return u(C,{className:`relative box-border flex gap-x-1 w-full ${r?"sticky top-1 z-20":""} ${t}`,defaultPadding:"p-0",role:"tablist",...s,children:xd({tabs:l,onClick:d,currentTab:o,...s})})})),xd=({tabsMode:e,tabs:t,...l})=>{switch(e){case"wideScreen":return t?.map(md({tabsMode:e,...l}));case"centered":return u(hd,{tabs:t,tabsMode:e,...l});case"scrollable":return u(ud,{tabs:t,tabsMode:e,...l})}return null},gd=e=>{"group"===e.type&&b.fire("tab",{type:e.type,label:e.ref}),"link"===e.type&&b.fire("tab",{type:e.type,label:e.href})},fd=x((({isOpen:e,onClick:t})=>p(se,{version:"primary",onClick:t,className:"w-full flex items-center justify-center rounded-none py-5",children:[u("div",{className:"text-h4",children:e?"Скрыть":"Показать"}),u(je,{name:e?"ArrowUpIcon":"ArrowDownIcon",className:"ml-3",iconVersion:"white",width:"20",height:"20"})]}))),bd={Buttons:({buttons:e})=>Gt(e),Img:({image:e})=>e?.src?u(Rt,{image:e}):null,List:({isDotted:e,...t})=>u(ba,{className:"flex flex-col justify-between items-start text-h6",isDotted:e??!0,...t}),LabelDescription:({label:e,description:t})=>p("div",{children:[e?u("div",{className:"text-h6 m-0 "+(t?"mb-1":""),children:e}):null,t?u("div",{className:"text-secondary-text text-l-light",children:t}):null]}),Table:x((({isVisible:e,displayTable:t,dataUrl:l,pdfUrl:n,isOpen:a})=>e?u(fd,{isOpen:a,onClick:()=>{t({dataUrl:l,pdfUrl:n})}}):null))},vd=({rowIdx:e,cellIdx:t,setTableInner:l,tableInner:i,openTableInnerIdx:r,setOpenTableInnerIdx:s})=>(o,c)=>{const[d,m]=n(!0);a((()=>{t===r&&i||m(!0)}),[i,r]);return p("div",{className:"Table"===o?.tableCellType?"ml-10":"first:pt-5 last:pb-5 pl-10",children:[c>0?u("div",{className:"h-5"}):null,Nd({cell:o,cellProps:{rowIdx:e,cellIdx:t,fieldIdx:c,displayTable:e=>{m(!1),s(t),l(e)},isVisible:d}})]},String(c))},Nd=({cell:e,cellProps:t})=>{if(!e)return null;const{tableCellType:l,...n}=e;if(!l||!(l in bd))return null;return u(bd[l],{...t,...n})},yd=x((({cells:e,rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})=>u("div",{className:"first:pl-0 w-80 flex-grow flex flex-col border-solid border-main-divider border border-t-0 border-x-0",role:"cell",children:e?.length?e.map(vd({rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})):null}))),wd=x((({rows:e})=>{const t=e?.[0]?.length??0,[l,n]=hl({itemCount:t,visibleItemCount:5});return p("div",{children:[e?.map(kd(l)),gl({...n,btnClass:["left-3 top-20","right-3 top-20"],className:""})]})})),kd=e=>(t,l)=>{if(!t?.length)return null;const[n,...a]=t,i=[...Array(e).keys()].reduce(((e,t)=>140*(a?.[t]?.cols?.length??1)+e),0),r=["flex duration-1000 text-center",0!==l?"font-normal":"font-light"].join(" ");return p("div",{className:"flex border-main-divider border border-t-0 border-x-0 border-solid",children:[n?.data?u("div",{className:"text-xl-light w-[214px] pb-5 "+(0===l?"pt-8":"pt-6"),children:n.data}):null,u("div",{className:"flex flex-grow overflow-hidden",children:u("div",{className:r,style:{transform:`translateX(-${i}px)`},children:a?.map(((t,l)=>p("div",{className:"flex flex-col flex-grow justify-center pt-6 pb-5 odd:bg-main-divider",children:[t?.data?u("div",{className:"text-xl-light mb-3",children:t.data}):null,t?.cols?Cd(t.cols,e):null]},`row${l}`)))})})]},String(l))},Cd=(e,t)=>e?.length>0?u("div",{className:`flex ${t} ${0===t?"text-secondary-text":""} last:mr-3`,children:e.map(((e,t)=>u("div",{className:"w-[76px] text-h6 mr-5 first:ml-8",children:e},String(t))))}):null,Sd=x((({activeTabIndex:e,items:t})=>{const[l,a]=n({}),r=i((e=>a((t=>({...t,[e]:!t[e]})))),[]);return u("div",{children:t.map(((t,n)=>{const a=`activeTabIdx:${e}-tableIdx:${n}`;return p("div",{className:"w-full",children:[p("div",{className:"flex p-4 bg-gray text-xl-light text-center justify-center cursor-pointer relative",onClick:()=>r(a),children:[t.title,u(Rt,{image:{icon:l[a]?"PlusIcon":"MinusIcon"},className:"absolute right-[22px]",width:"24",height:"24"})]}),u("div",{className:"w-full pl-2 overflow-hidden transition-height duration-500 ease-in-out "+(l[a]?"h-0":""),children:u("div",{className:"relative",children:u(wd,{rows:t.rowsData})})})]},a)}))})})),Id=x((({currencies:e,linkToPDF:t,activeTabIndex:l,setActiveTabIndex:n})=>p("div",{className:"flex justify-between w-full pt-2.5 pb-3",children:[e&&e.length>1?u("div",{className:"flex bg-secondary-light p-1.5 rounded-md",children:e.map(((e,t)=>u("div",{className:"rounded-md text-xl-light px-4 py-3 cursor-pointer "+(t===l?"bg-primary-main text-white":"text-secondary-text"),onClick:()=>n(t),children:e||t+1},e)))}):null,t?u(se,{href:t,version:"secondary",target:"_blank",appendLeft:u(je,{name:"DocDownloadIcon",iconVersion:"color",className:"mr-0.5",width:"20",height:"20"}),text:"Скачать в PDF"}):null]})));async function Td(e){const t=await fetch(e);return await t.json()}const Bd=x((({dataUrl:e,pdfUrl:t,onClick:l})=>{const{tableData:a}=function(e){const{data:t}=V(function(e){return`/wcms-resources/${e||"tariffs-inner-table-data"}.json`}(e),Td);return t||{}}(e),[r,s]=n(0),o=i((e=>s(e)),[]),c=a?.[r]?.items??[],d=a?.map((e=>e.currency??""));return p("div",a?{className:"bg-white z-10",children:[u(Id,{currencies:d,activeTabIndex:r,setActiveTabIndex:o,linkToPDF:t}),u(Sd,{activeTabIndex:r,items:c}),u(fd,{onClick:l,isOpen:!0})]}:{className:"my-5 text-h6 text-center",children:[u("p",{children:"Данных нет"}),u(fd,{onClick:l,isOpen:!0})]})})),Rd=x((({children:e,tableInner:t,onHideContentClick:l})=>p("div",{className:"self-start flex flex-col",role:"row",children:[u("div",{className:"flex",children:e}),t?u("div",{className:"origin-top animate-expansion",children:u(Bd,{...t,onClick:l})}):null]}))),Pd=x((({row:{header:e,data:t},activeIndex:l,rowIdx:a,...r})=>{const[s,o]=n(void 0),c=i((e=>o(e)),[]),[d,m]=n(void 0),h=i((e=>m(e)),[]);return p(Rd,{onHideContentClick:()=>o(void 0),tableInner:s,...r,children:[u("div",{className:"text-s py-5 w-[354px] flex-shrink-0 border-main-divider border border-t-0 border-x-0",children:p("div",{className:"flex items-center text-primary-text",role:"cell",children:[e?.icon?u(Rt,{className:"mr-3.5 max-w-6",image:e.icon,width:"24",height:"24"}):null,e?.title?u("div",{className:"text-m-light",children:e?.title}):null]})}),t?.length?u(qa,{activeIndex:l,columnWidth:360,version:"tariff",children:t.map(((e,t)=>u(yd,{cells:e,rowIdx:a,cellIdx:t,setTableInner:c,tableInner:s,openTableInnerIdx:d,setOpenTableInnerIdx:h,...r},String(t))))}):null]})})),$d=x((({className:e="",title:t,description:l,rowHeaders:n,tariffsColumns:a,hiddenRowsNum:i=0,...r})=>{const s=a?.map((({data:e})=>e))||[],o=n?.map(((e,t)=>({header:e,data:s.map((e=>e?.[t]||[]))}))),c=s.length,[d,m]=hl({itemCount:c,visibleItemCount:2}),h=(o||[]).map(((e,t)=>u(Pd,{row:e,activeIndex:d,rowIdx:t,...r},String(t)))),[x,g]=i>0?[h.slice(0,-i),h.slice(-i)]:[h,[]];return p(C,{className:w("overflow-hidden relative",e),defaultPadding:w("p-default",c>1?"pr-0":""),...r,children:[Md({title:t,description:l}),_d(l),i>0?u(Da,{renderFoldableSection:({isUnfolded:e})=>p(Vd,{controls:m,children:[x,u(La,{isUnfolded:e,children:g})]}),renderFoldButton:fi}):u(Vd,{controls:m,children:h})]})}));function Md({title:e,description:t}){return e?u(I,{headingType:"h3",className:"text-center "+(t?"mb-2.5":"mb-8"),title:e}):null}function _d(e){return e?u("div",{className:"mb-9 text-center text-l",children:e}):null}const Vd=x((({children:e,controls:t})=>{const{isScrollAvailable:l}=t;return p("div",{role:"table",children:[p("div",{className:"relative",children:[e,gl({...t,btnClass:["top-[108px]","top-[44px]"],className:"right-7"})]}),l?u("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"}):null]})})),jd=x((({className:e="",title:t,description:l,iconVersion:n,image:a,__html:i,items:r=[],...s})=>p(C,{className:w("flex gap-3 bg-white group-data-secondary:bg-primary-main/10",e),...s,children:["small"===n?u("div",{className:"mt-1",children:zd()}):null,"big"===n?Dd(a):null,p("div",{className:"flex flex-col w-fit gap-3",children:[t?u(me,{size:"text-l",font:"font-medium",color:"text-primary-text group-data-secondary:text-white",children:t}):null,l?Ld(l):null,r?.length?Ad(r,!0):null,i?u(ja,{__html:i}):null]})]}))),zd=()=>u("div",{className:"rounded-full h-4 w-4 text-center text-xs-light bg-primary-main text-white group-data-secondary:bg-white group-data-secondary:text-primary-main",children:"i"}),Dd=e=>e?.src?u(Rt,{className:"h-fit",image:e}):null,Ld=e=>u(de,{size:"text-s",color:"text-secondary-text group-data-secondary:text-white",children:e}),Ad=(e,t)=>u("ul",{className:w("text-secondary-text group-data-secondary:text-white/80",t?"list-disc pl-6":""),children:e.map(((e,t)=>u("li",{children:u(me,{size:"text-s",font:"font-light",children:e})},`listItem-${t}`)))}),Od=x((({className:e,headlineVersion:t="S",listItemSize:l="M",...n})=>u(C,{className:e,...n,children:u(Go,{className:"h-full",headlineVersion:t,listItemSize:l,...n,imageOptions:{imageAlign:"end",...n.imageOptions}})}))),Ed={stretch:"items-stretch",left:"items-start",center:"items-center",right:"items-end"},Fd=x((({className:e="",gap:t="",align:l="stretch",isPadding:n=!1,isInnerPadding:a=!0,version:i="transparent",isTheme:r=!1,...s})=>{const o=a?"":"!p-0";return u(C,{className:w("relative","flex flex-col [&>*]:max-w-full",As[t],l&&Ed[l],e),defaultPadding:n?"p-default":"",version:i,isTheme:r,...s,children:kn({...s,renderProps:(e,t)=>Nn(e,t,{className:o})})})}));Fd.childrenTypes=[];const Ud=e=>Gn(e)<10?"py-6 px-11":"py-12 px-32",Hd=x((({className:e,title:t,url:l,previewImg:n,...a})=>{const i=J();return p(C,{className:e,defaultPadding:Ud(e),...a,children:[u(Qt,{title:t,headlineVersion:"M"}),l?u("video",{className:"m-auto w-full object-fill",preload:"metadata",poster:W(i)(n?.src),style:{maxHeight:524},controls:!0,children:u("source",{src:W(i)(l)})}):null]})})),Xd={ApplicationForm:Ft,BenefitsBlock:Ut,Bonus:el,BonusBenefitsBlock:il,BusinessBlock:dl,ButtonsBlock:ml,Calculator:dn,CardTransfer:fn,Carousel:On,CarouselBankHistoryCard:Hn,CarouselCard:Zn,CarouselCatalogCard:ea,CarouselEventCard:na,CarouselInvestmentCard:oa,CarouselLinks:ha,CarouselProductCard:va,CarouselProgramsCard:Sa,CarouselRecommendationCard:_a,CarouselRichTextCard:za,CarouselTariffsCard:Ea,ComparisonTable:oi,ContactsBlock:di,DepositFiltration:Ti,ErrorBlock:Ri,ExchangeRateTile:rr,Footer:qr,GracePeriod:Zr,Header:Ls,Headline:Qt,HorizontalLayout:Os,ImgBlock:Es,InsuranceAmountBlock:Ws,InvestmentInfo:qs,LinkDocs:ro,MobileAppTile:co,MortgageFiltration:ho,OfficeMap:jo,OfficeServicesBlock:zo,ParagraphBlock:Lo,PictureText:qo,Placeholder:Zo,ProductBlock:nc,ProductGallery:ac,ProductTile:cc,PromoTile:mc,RepresentativeOfficeInfo:uc,RichTextBlock:fc,RollupItem:vc,SafeDepositRental:Uc,StepsBlock:Jc,SwipeListControlBlock:Zc,Tabs:pd,TariffsTable:$d,TextBlock:jd,Tile:Od,VerticalLayout:Fd,Video:Hd,ExchangeRateOffice:Di};const Wd=["Header","Footer"],Kd=([,{target:e}])=>Math.abs(e.getBoundingClientRect().top);function Gd(e=globalThis){const t=s(new Map);a((()=>y.subscribe("intersection",(({block:e,intersection:l})=>{t.current&&t.current.set(e,l)}))),[]),a((()=>{const l=((e,t=600)=>{let l;const n=(...a)=>{n.dispose(),l=setTimeout((()=>{e(...a)}),t)};return n.dispose=()=>{l&&clearTimeout(l)},n})((()=>{!function(e){const t=`#${l=e?.anchor,l?.replace("#","")||""}`;var l;globalThis.location?.hash!==t&&globalThis.history?.replaceState(globalThis.history?.state,"",t)}(globalThis.scrollY>3*globalThis.innerHeight/4?function(e){const t=e.filter((([e])=>!Wd.includes(e.type||""))).filter((([,{intersectionRatio:e}])=>e>.01)),[l]=t.length>0?Al(Kd)(t):[];return l}([...t.current||[]]):void 0)}),100);return e.addEventListener("scroll",l),()=>{l.dispose(),e.removeEventListener("scroll",l)}}),[e])}const Jd="cookieClose",Yd=x((({termLink:e,personalDataPolicyLink:t})=>{const{isOpened:l,onClose:n}=$r("cookie",!globalThis.localStorage?.getItem(Jd)),a=i((()=>{globalThis.localStorage?.setItem(Jd,"true"),n&&n()}),[n]);return l?u("div",{className:"container z-40 fixed bottom-0 left-0 right-0 pointer-events-none",children:p("div",{className:"bg-white m-6 p-6 rounded-md flex items-center pointer-events-auto shadow-[0_4px_25px_rgba(0,0,0,0.07)]",children:[u("div",{className:"flex-1",children:p(de,{size:"text-s-light",color:"text-primary-text",children:["АО «Россельхозбанк» использует",u(la,{isRemote:!0,className:w(qd(e?.href)),...e,children:"cookie"}),"(файлы с данными о прошлых посещениях сайта) для персонализации сервисов и удобства пользователей. Вы можете запретить сохранение cookie в настройках своего браузера.",u(la,{isRemote:!0,className:w(qd(t?.href)),...t,children:"Обработка Ваших персональных данных"}),"производится в соответствии с требованиями Федерального закона от 27.07.2006 № 152-Ф3 «О персональных данных»."]})}),u("div",{className:"w-24 flex justify-end",children:u(gr,{className:"bg-main-gray rounded-md",onClick:a})})]})}):null})),qd=e=>["inline mx-1",e?"text-green-dark":""],Zd=h();const Qd=x((({className:e,onClick:t,ariaLabel:l})=>u("button",{type:"button",className:`border-0 w-9 bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":l,children:em()}))),em=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return p("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[u("path",{...e,strokeMiterlimit:"10",d:"M21.48 11.95c.5-1.4-.4-2.6-1.9-2.6h-4c-.6 0-1.1-.5-1-1.2l.5-3.2c.2-.9-.4-1.9-1.3-2.2-.8-.3-1.8.1-2.2.7l-4.1 6.1M7.48 18.35l3.1 2.4c.4.4 1.3.6 1.9.6h3.8c1.2 0 2.5-.9 2.8-2.1l1.24-3.77"}),u("path",{...e,d:"M2.38 18.35v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9Z"})]})},tm=x((({className:e=""})=>{const t=function(e){const[t,l]=n(0);return a((()=>{(async()=>{const[t]=await Zd.getLikeCount(e);l(t?.value||0)})()}),[e]),{likeCount:t,like:i((async()=>{l(await Zd.like(e))}),[e]),dislike:i((async()=>{l(await Zd.dislike(e))}),[e])}}(J().pathname);return p("div",{className:`border-main border-2 border-solid bg-white flex w-[125px] items-center justify-center gap-3 p-2 font-sans ${e}`,children:[u(Qd,{onClick:G(t.like),ariaLabel:"Поставить отметку «лайк»"}),u(Qd,{onClick:G(t.dislike),className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),u("span",{className:"select-none",children:t.likeCount})]})})),lm=x((e=>{const{className:t="",blocksRegistry:l,blockDecorator:n,data:a={}}=e,{style:i,blocks:r,slots:s,likeControl:o,colorPalette:c="pc"}=a,d={key:"",page:a,blocksRegistry:l,blockDecorator:n,parent:a};Gd();const[m,{setTrue:h,setFalse:x}]=Me();return br({onOpen:h,onClose:x}),p("section",{className:w("relative",i,t,m?"overflow-hidden h-screen":""),"data-theme":c,children:[s?.header?u("div",{className:"mb-5 shadow-[0_8px_32px_0px_#00000014]",children:wn(s?.header,{...d,slotName:"header"})}):null,p("div",{className:"container grid grid-cols-12 gap-1",children:[wn(r,d),s?.footer?wn(s?.footer,{...d,slotName:"footer"}):null]}),o?u("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:u(tm,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto"})}):null,u(Yd,{termLink:{href:"/pd-policy#cookie",target:"_blank"},personalDataPolicyLink:{href:"/pd-policy",target:"_blank"}})]})}));lm.childrenTypes=[],lm.slots=()=>["header","footer"];e.Blocks=Xd,e.ContentPage=lm,e.DaDataAPI=function(e=""){return{getFetcherAddress:async function(){if(!("geolocation"in navigator))return null;try{const t=await(async()=>new Promise((e=>navigator.geolocation.getCurrentPosition((({coords:t})=>e(t))))))(),l=await fetch(`${e}/geolocate`,{method:"POST",mode:"cors",body:JSON.stringify({lat:t.latitude,lon:t.longitude,count:1})});return(await l.json())?.suggestions?.[0]?.data?.city}catch(e){return console.error(e),null}}}},e.LikeAPI=h,e.handlerDecorator=G,e.joinList=Gs,e.packageVersion="0.12.3",e.projectSettings=d,e.setup=(e,t)=>{globalThis._uni={_jsx:e,_jsxs:t||e}},e.setupHooks=e=>{t=e},e.url=X,e.useRouter=J,Object.defineProperty(e,"__esModule",{value:!0})}));
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniBlocks={})}(this,(function(e){"use strict";let t;const l=e=>(...l)=>t[e](...l),n=l("useState"),a=l("useEffect"),i=l("useCallback"),r=l("useMemo"),s=l("useRef");const o=e=>e&&!e.endsWith("/")?`${e}/`:e,c={PROD_BRANCH:"master"},d=new class{_=c;setup(e){this._=e}get TEST_BRANCH(){return this._.TEST_BRANCH}get RC_BRANCH(){return this._.RC_BRANCH}get PROD_BRANCH(){return this._.PROD_BRANCH||c.PROD_BRANCH}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ASSIST_PROJECT_ID(){return this._.ASSIST_PROJECT_ID}get SITEMAP(){return this._.SITEMAP}get FOOTER(){return this._.FOOTER}get CHAT_BOT(){return this._.CHAT_BOT}get CDN(){return o(this._.CDN)}get BASE_PATH(){return o(this._.BASE_PATH)}get YANDEX_MAP_API_KEY(){return this._.YANDEX_MAP_API_KEY}get YANDEX_METRIKA_ID(){return this._.YANDEX_METRIKA_ID}},m="likesToken";function h(){async function e(){try{const e=JSON.parse(globalThis.localStorage?.getItem(m)||"");if(e?.token)return e}catch(e){}try{const e=await fetch("/assist/v1/public/auth",{method:"POST",mode:"cors",headers:{"Content-Type":"application/json"},body:JSON.stringify({prefix:"guest"})}),{token:t,name:l}=await e.json();return globalThis.localStorage?.setItem(m,JSON.stringify({token:t,name:l})),{token:t,name:l}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...t){if(!t.length)return[];const{token:l}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l},body:JSON.stringify({node_ids:t})}),{likes:n}=await e.json();return n||[]}catch(e){return console.error(e),[]}},like:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}},dislike:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}}}}const u=(...e)=>globalThis._uni._jsx(...e),p=(...e)=>globalThis._uni._jsxs(...e),g=e=>{const t=e;return t._tmpl||(t._tmpl=globalThis.__UNI_REACT__?e:x(e)),t._tmpl},x=e=>{function t(t,l){const{children:n,...a}=t||{},i=l?.slots?.default,r=n||i&&i();return e(Object.assign(a,r&&{children:r}),l)}return t.inheritAttrs=!1,t};class f{subscribers={};subjectsStateMap={};subscribe(e,t){this.subscribers[e]=(this.subscribers[e]||[]).concat(t);const l=this.subjectsStateMap[e];return l&&t(l),()=>{this.unsubscribe(e,t)}}unsubscribe(e,t){this.subscribers[e]=this.subscribers[e]?.filter((e=>e!==t))}fire(e,t){e in this.subjectsStateMap&&(this.subjectsStateMap[e]=t),this.subscribers[e]?.forEach((e=>e(t)))}subject(e,t){this.subjectsStateMap[e]=t}}const b=new f;function v(e,{sensitivity:t,rootRef:l}={}){const n=s(null),i=r((()=>({threshold:y(t),root:l?.current})),[t,l?.current]);return a((()=>{if(!n.current)return;const t=new IntersectionObserver(e,i);return t.observe(n.current),()=>{t.disconnect()}}),[e,i]),n}function y(e=0){const t=Math.round(10*e);return new Array(t).fill(0).map(((e,l)=>Math.min(l/t)),1).concat(1)}const N=new f;const w=(...e)=>e.flatMap((e=>e)).filter(Boolean).join(" "),k={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white",gray:"bg-main-divider text-primary-text",transparent:"bg-transparent text-primary-text","":""},C=g((({className:e,version:t="primary",isTheme:l=!0,defaultPadding:r="p-m",padding:s,block:o,tag:c="section",role:d,children:m})=>{const h=c,p=function(e){return v(i((t=>{if(!e||!t?.length)return;const l=t[t.length-1];N.fire("intersection",{block:e,intersection:l})}),[e]),{sensitivity:1})}(o),[g,x]=n(!1);a((()=>b.subscribe("tab",(e=>{x(Boolean(e.label&&o?.labels?.length&&!o.labels.includes(e.label)))}))),[o]);const f=t&&l;return u(h,{className:w("font-sans",f?"group":"",k[t],g?"hidden":"",s||r,e),...f?{"data-ver":t}:{},...o?.anchor?{id:o.anchor,ref:p}:{},role:d,children:m})})),S={h0:"text-h0",h1:"text-h1",h2:"text-h2",h3:"text-h3",h4:"text-h4",h5:"text-h5",h6:"text-h6"},I=g((({className:e="",headingType:t="h3",as:l="h3",title:n,children:a})=>u(l,{className:w("font-sans m-0",S[t],e),children:n||a}))),T=e=>e,B=(e,t)=>{const[l,a]=n(e),[r,o]=n(!1),[c,d]=n({}),m=s({}),h=i(((e,t)=>{const{parse:n=T,format:i=T}=t||{};return m.current||(m.current={}),m.current[e]||=t=>{a((l=>({...l,[e]:n(t)}))),d((t=>({...t,[e]:!0})))},{value:i(l[e]),isDirty:r||c[e],onChange:m.current[e]}}),[l,r,c]),u=i((()=>{a(e),o(!1),d({})}),[e]),p=i((e=>{e.preventDefault(),o(!0),t&&t(l)}),[t,l]);return[l,{isDirty:r||Object.values(c).some(Boolean),field:h,reset:u,onSubmit:p}]},R=e=>t=>t&&Object.entries(e).flatMap((([e,l])=>l(t[e])))||[],P=e=>!e?.length,M=e=>t=>l=>e(l)?[]:[t],_=e=>null!=e,$=new Map;function V(e,t,{fallback:l,cache:i}={}){const s=r((()=>j(e)),[e]),[o]=(e=>Boolean(e&&Array.isArray(e)&&1===e.length&&"string"==typeof e[0]))(s)?s:[],[c,d]=n(void 0),[m,h]=n(void 0);a((()=>{!s.some(_)||(async()=>{try{const e=await(o?((e,t=$)=>l=>{const n=t.get(l);if(_(n))return n;const a=e(l);return _(a)?t.set(l,Promise.resolve(a)):t.delete(l),a})(t,i)(o):t(...s));d(e),h(void 0)}catch(e){d(void 0),h(e)}})()}),[t,i,s]);const u=l&&o&&l[o];return{data:!c&&u?u:c,error:m,mutate:()=>Promise.resolve(void 0),isValidating:!1}}function j(e){return Array.isArray(e)?e:e instanceof Function?j(e()):[e]}async function z(e,t){try{return e?await D(e,t):null}catch(e){console.error(e)}return null}async function D(e,t){const l=await fetch(e,{...t,headers:{...t?.headers,"Content-Type":"application/json"}});return await l.json()}const L=[];function A(){const{data:e}=V("/api/v1/regions",D);return e||L}const O=(e="")=>({open:t=>b.fire("dialog",{type:"open",id:e,message:t}),close:()=>b.fire("dialog",{type:"close"})}),E=e=>Boolean(e?.includes(":")),F=(e,t)=>Boolean(e&&!E(e)&&(!t||"_self"===t)),U=e=>(e||"").replace(/\?.*/,"").replace(/\/$/,""),H=(...e)=>e.filter(Boolean).join("/").replace(/\/+/g,"/");var X=Object.freeze({__proto__:null,isURL:E,isLocalURL:F,isHash:e=>Boolean(e?.startsWith("#")),withoutQuery:U,joinPath:H});const W=e=>(t,l=d.BASE_PATH)=>{if(!t||E(t)||K(t,d.CDN))return t;const n=t.startsWith("/");return H(K(t,l)?"":l,n?"/":e.pathname?.split("/").slice(0,-1).join("/"),t)},K=(e,t)=>t&&e&&e.startsWith(t),G=(e,t)=>G._impl(e,t);function J(){return J._impl()}function Y(e={}){const{isRemote:t,basePath:l}=e,n=J(),{close:a}=O();return e=>({...e,href:t&&!l?e.href:W(n)(e.href,l),"aria-label":e.text,onClick:G(i(e),e)});function i({href:e,target:l,onClick:i}){return r=>{i&&i(r),e&&!t&&F(e,l)&&(a(),r?.preventDefault(),n.push(e))}}}G._impl=e=>e,G.setup=e=>{G._impl=e},J._impl=()=>({href:globalThis.location?.href||"/",pathname:globalThis.location?.pathname||"/",query:{},push:()=>{},replace:()=>{}}),J.setup=e=>{J._impl=e};const q={primary:"text-white bg-primary-main hover:bg-primary-hover active:bg-primary-active",secondary:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active",white:"text-primary-main bg-white hover:text-white hover:bg-primary-hover active:bg-white active:text-primary-main",link:"",transparent:"",gray:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active","":""},Z="bg-main-divider text-main-disabled",Q={primary:Z,secondary:Z,white:Z,link:"",transparent:"",gray:Z,"":""},ee="text-center font-sans select-none",te={primary:"group-hover/btn:brightness-0 group-hover/btn:invert",secondary:"group-hover/btn:brightness-0 group-hover/btn:invert",white:"group-hover/btn:brightness-0 group-hover/btn:invert",link:"",transparent:"",gray:"group-hover/btn:brightness-0 group-hover/btn:invert","":""},le=g((e=>{const{text:t,aboveText:l,appendLeft:n,appendRight:a,version:i="primary"}=e;return p("div",{className:w(ne(e),"flex gap-2"),children:[n?u("div",{className:te[i],children:n}):null,ae(e)?p("div",{children:[l?u("div",{className:"text-xs-light text-left",children:l}):null,u("div",{className:"text-left "+(l?"text-s -mt-0.5":"text-l"),children:t})]}):null,a?u("div",{className:te[i],children:a}):null]})})),ne=e=>{const{version:t,aboveText:l,rounded:n}=e;if("link"===t)return"";const a=""+(l?"py-2.5 px-9":"py-4 px-9");return["group/btn items-center justify-center",ae(e)?a:"h-12 w-12",n?"rounded-full":""].join(" ")},ae=({text:e,aboveText:t,appendLeft:l})=>Boolean(e||t||!l),ie=({className:e,rounded:t,version:l})=>["inline-block",ee,l?Q[l]:"",t?"rounded-full":"rounded-md",e].join(" "),re=({className:e,rounded:t,version:l})=>[ee,"border border-transparent inline-block cursor-pointer no-underline focus:border-primary-text focus:border h-fit",l?q[l]:"",t?"rounded-full":"rounded-md",e].join(" "),se=g((({disabled:e,children:t,...l})=>{const n=Y()(l),a=t??u(le,{...n});return u(e?ce:oe,{...n,children:a})})),oe=g((({className:e="",href:t,rel:l,target:n,ariaLabel:a,version:i,rounded:r,onClick:s,children:o})=>u("a",{className:re({className:e,version:i,rounded:r}),href:t,rel:l,target:n,"aria-label":a,role:t?"link":"button",onClick:s,children:o}))),ce=g((({className:e,ariaLabel:t,version:l,rounded:n,children:a})=>u("div",{role:"button","aria-disabled":"true","aria-label":t,tabIndex:-1,className:ie({className:e,rounded:n,version:l}),children:a}))),de=g((({children:e,...t})=>u("p",{className:["font-sans",...Object.values(t)].join(" "),children:e}))),me=g((({children:e,...t})=>u("span",{className:["font-sans",...Object.values(t)].join(" "),children:e}))),he=g((({link:e})=>p(de,{size:"text-s-light",color:"text-secondary-text",children:[u(me,{children:"Нажимая кнопку, вы подтверждаете согласие с "}),e?u(se,{href:e.href,ariaLabel:"условия передачи данных",target:e.target,className:"text-primary-main",children:u(me,{children:e.text})}):null]}))),ue=(e,t)=>{const{value:l,isDirty:n}=e,a=n?t(l):[];return{...e,errors:a,error:a[0]}},pe=g((({key:e,className:t="",inputClassName:l="",id:n,name:a,type:r="text",label:s,placeholder:o,value:c="",valid:d=!0,children:m,onChange:h,onFocus:g,onBlur:x,pattern:f})=>{const b=i((e=>{h&&h(e.target?.value||"")}),[h]),v=m?"pr-8":"",y=d?"border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text":"border-error";return p("div",{className:w("relative",t),children:[p("label",{children:[s?u("div",{className:"mb-2",children:u(me,{size:"text-m",font:"font-light",children:s})}):null,u("input",{className:w("w-full border rounded-md text-primary-text outline-none p-4",v,y,l),id:n,name:a||n,placeholder:o,type:r,value:c,onInput:b,onFocus:g,onBlur:x,pattern:f},e)]}),m]})})),ge=g((({className:e,label:t,value:l="",error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(pe,{type:"text","aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs-light",color:"text-error",children:n}):null})]}))),xe=e=>"_"===e,fe=e=>/\d/.test(e),be=e=>xe(e)||fe(e),ve=[..."+7 (___) ___-__-__"],ye=ve.findIndex(xe),Ne=ve.map(((e,t)=>be(e)?ve.slice(0,t).filter(be).length:-1));const we=g((({children:e,onChange:t,...l})=>{const n=i((e=>t&&t(function(e){const t=e.replace(/\D/g,""),l=ve.map(((e,l)=>fe(e)?e:t.charAt(Ne[l])||e)),n=Ne.indexOf(t.length-1)+1;return(n?l.slice(0,Math.max(ye,n)):l).join("")}(e))),[t]);return u(pe,{onChange:n,onFocus:e=>n(e?.target?.value||""),...l,children:e})})),ke=g((({className:e,label:t,value:l,error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(we,{"aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs-light",color:"text-error",children:n}):null})]}))),Ce="Некорректно заполненное поле",Se=M((e=>null!=e&&""!==e))(Ce),Ie=M((e=>"string"==typeof e&&e.length>1))(Ce),Te=M((e=>"string"==typeof e&&(10===e.length||12===e.length)))(Ce),Be=(Re=/^(\+7)?[\s-]?\(?[0-9]{3}\)?[\s-]?[0-9]{3}[\s-]?[0-9]{2}[\s-]?[0-9]{2}$/,M((e=>"string"==typeof e&&Re.test(e))))(Ce);var Re;const Pe=e=>p("div",{className:"flex justify-between gap-5 mb-5",children:[p("div",{className:"w-1/2",children:[u(ge,{className:"shrink-0 w-full mb-3",label:"Наименование организации",...ue(e("fullName"),Se)}),u(ge,{className:"shrink-0 w-full mb-3",label:"Контактное лицо",...ue(e("name"),Ie)})]}),p("div",{className:"w-1/2",children:[u(ge,{className:"shrink-0 w-full mb-3",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)})]})]}),Me=[{name:"Торговый эквайринг"},{name:"Мобильный эквайринг"},{name:"Интернет-эквайринг"},{name:"QR-эквайринг (СБП)"},{name:"Все виды эквайринга"}];function _e(e=!1){const[t,l]=n(e),a=i((()=>l(!0)),[]),r=i((()=>l(!1)),[]),s=i((()=>l((e=>!e))),[]);return[t,{setValue:l,setTrue:a,setFalse:r,toggle:s}]}function $e(e){const t=s(null);return a((()=>{const l=l=>{t&&t.current&&l.target instanceof Node&&!t.current.contains(l.target)&&e()};return document.addEventListener("click",l),()=>{document.removeEventListener("click",l)}}),[e]),t}const Ve={normal:"",color:"text-primary-main",black:"text-black",white:"text-black"},je=g((({className:e="",imageClassName:t="",name:l="",alt:n=`Иконка ${l}`,title:a=n,iconVersion:i="color",...r})=>{const s=J(),o=W(s)(H(d.CDN,"/icons",`${l}.svg`));return"normal"!==i?u(De,{className:e,children:p("svg",{className:w(ze(r.width),Ve[i],"white"===i?"invert":"",t),...r,"aria-hidden":"true",children:[a?u("title",{children:a}):null,n?u("desc",{children:n}):null,u("use",{href:`${o}#icon`,xlinkHref:`${o}#icon`})]})}):(e.includes("h-")||(r.style={height:`${r.height}px`}),u("img",{className:e,src:o,alt:n,title:a,"aria-hidden":"true",...r}))})),ze=e=>e?"":"w-full h-full",De=g((({className:e,children:t})=>e?u("div",{className:e,children:t}):t)),Le=g((({className:e="",label:t,options:l=[],value:n,valid:a=!0,isBorder:r=!0,placeholder:s="",onChange:o})=>{const[c,{setFalse:d,toggle:m}]=_e(),h=$e(d),g=i((e=>{d(),o&&o(e)}),[o]);return p("div",{className:e,ref:h,children:[t?u("div",{className:"mb-2",children:u(me,{size:"text-m",color:"text-primary-text",font:"font-light",children:t})}):null,p("div",{className:w("relative",c?"z-20":"z-10"),children:[p("div",{className:w("text-l flex justify-between items-center mb-0.5 text-primary-text cursor-pointer",Ee(r,a)),onClick:m,children:[u("p",{className:"p-4 pr-8 h-14 overflow-hidden text-ellipsis whitespace-nowrap",children:Oe(n)||s}),u(je,{className:w("absolute right-3",c?"":"rotate-180"),name:"ArrowUpIcon",width:"16",height:"16"})]}),l?.length?u("div",{className:w("h-0",c?"":"overflow-hidden"),children:u("div",{className:"bg-white text-l max-h-64 overflow-y-auto overflow-x-hidden rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]",children:l.map(Ae(g,c,(e=>e.key===n?.key)))})}):null]})]})})),Ae=(e,t,l)=>(n,a)=>p("div",{onClick:()=>{e(n)},className:"flex px-4 py-3 cursor-pointer hover:bg-main-divider pr-11 relative",children:[u("span",{className:"min-h-6",children:Oe(n)}),u(je,{name:"DoneSimpleIcon",width:"16",height:"16",className:w("absolute right-4 pt-0.5",l(n)&&t?"":"hidden")})]},String(a)),Oe=e=>e?.text||e?.key||"",Ee=(e,t)=>w(e?"border rounded-md hover:border-primary-hover":"",t?" border-gray":"border-error"),Fe=g((e=>p("div",{children:[u(Le,{...e,valid:!e.error}),u("div",{className:"h-2",children:e.error?u(me,{size:"text-xs-light",color:"text-error",children:e.error}):null})]}))),Ue=({regions:e,field:t})=>p("div",{className:"flex justify-between gap-5 mb-7",children:[u("div",{className:"w-1/2",children:u(Fe,{label:"Вид эквайринга",placeholder:"Выберите эквайринг",options:Me.map((({name:e=""})=>({key:e,text:e}))),...ue(t("acquiringType"),Se)})}),u("div",{className:"w-1/2",children:u(Fe,{label:"Адрес",placeholder:"Выберите адрес",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)})})]}),He=g((({value:e=!1,text:t,type:l="checkbox",onChange:n})=>p("div",{role:l,"aria-checked":e,className:"flex justify-start items-center w-full cursor-pointer mb-3",onClick:()=>n&&n(!e),children:[u("div",{className:w("relative flex-shrink-0 duration-300 w-9 h-5 mr-3 rounded-2xl",e?"bg-primary-main":"bg-main-divider"),children:u("div",{className:w("absolute opacity-80 duration-500 top-0.5 w-4 h-4 bg-white rounded-full",e?"left-[50%]":"left-[5%]")})}),u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:t})]}))),Xe=e=>p("div",{className:"mb-5",children:[u(He,{text:"Хочу купить онлайн-кассу",...e("onlineCheckout")}),u(He,{text:"Хочу купить POS-терминал",...e("posTerminal")})]}),We=(e,t)=>{const l=re({className:"text-white",version:e?.version});return u("button",{type:"submit",className:w("p-4",l,t),children:e?.text?e.text:"Отправить заявку"})},Ke={acquiringType:{key:"Торговый эквайринг"},fullName:"",inn:"",name:"",phone:"",onlineCheckout:!1,posTerminal:!1},Ge=R({acquiringType:Se,region:Se,fullName:Se,inn:Te,name:Ie,phone:Be}),Je=g((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{acquiringType:t,region:l,fullName:a,inn:i,name:r,phone:s,onlineCheckout:o,posTerminal:c}=e;P(Ge(e))&&n({typeForm:"acqr",region:l?.text||"",partnerComments:`Вид эквайринга=${t?.key||""}/Онлайн касса=${o}/POS-терминал=${c}`,fullName:a,inn:i,name:r,phone:s})}),[n]),[,{field:r,...s}]=B(Ke,a),o=A();return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Вид эквайринга и регион",className:"text-center mb-4"}),Ue({regions:o,field:r}),u(I,{headingType:"h6",title:"Данные организации",className:"text-center mb-4"}),Pe(r),Xe(r),We(t,"mb-4"),u(he,{link:l})]})})),Ye=e=>p("div",{className:"flex justify-between gap-5",children:[p("div",{className:"w-1/2",children:[u(ge,{className:"shrink-0 w-full mb-3",label:"Контактное лицо",...ue(e("name"),Ie)}),u(ge,{className:"shrink-0 w-full mb-3",label:"ИНН",...ue(e("inn"),Te)})]}),p("div",{className:"w-1/2",children:[u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)}),u(ge,{className:"shrink-0 w-full mb-3",label:"Электронная почта",...ue(e("mail"),Se)})]})]}),qe=({regions:e,field:t})=>u("div",{className:"flex justify-between gap-5 mb-5",children:u("div",{className:"w-full",children:u(Fe,{label:"Регион",placeholder:"Выберите регион",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)})})}),Ze={name:"",phone:"",inn:"",mail:""},Qe=R({region:Se,name:Ie,phone:Be,inn:Te,mail:Se}),et=g((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{region:t,name:l,phone:a,inn:i,mail:r}=e;P(Qe(e))&&n({typeForm:"bcrd",region:t?.text||"",name:l,phone:a,inn:i,mail:r})}),[n]),[,{field:r,...s}]=B(Ze,a),o=A();return p("form",{className:"container",onSubmit:s.onSubmit,children:[qe({regions:o,field:r}),Ye(r),We(t,"mb-4"),u(he,{link:l})]})})),tt=[];const lt=async e=>await z(e,{method:"GET"})||tt,nt=["От 1 000 ₽","До 1 000 000 000 ₽"],at=["От 1 мес","До 15 лет"],it=e=>p("div",{className:"flex justify-between gap-5 mb-7",children:[p("div",{className:"w-1/2",children:[u(ge,{className:"shrink-0 w-full mb-3",label:"Наименование организации",...e("fullName")}),u(ge,{className:"shrink-0 w-full mb-3",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)})]}),p("div",{className:"w-1/2",children:[u(ge,{className:"shrink-0 w-full mb-3",label:"Годовая выручка, ₽",...ue(e("annualRevenue"),Se)}),u(ge,{className:"shrink-0 w-full mb-3",label:"Контактное лицо",...ue(e("name"),Ie)}),u(ge,{className:"shrink-0 w-full mb-3",label:"Электронная почта",...e("mail")})]})]}),rt=(e,{normalize:t,format:l})=>{const{value:a,onFocus:r,onBlur:s,onChange:o}=e,[c,d]=n(!1),m=i((e=>{d(!0),r&&r(e)}),[]),h=i((()=>{d(!1),o&&o(t(a)),s&&s()}),[o,a]);return{value:c||!l?a:l(a),onFocus:m,onBlur:h}},st=(e,t,l)=>Math.max(t,Math.min(e,l)),ot=(e=0)=>(t=0)=>new Intl.NumberFormat("ru-RU",{minimumFractionDigits:0,maximumFractionDigits:e}).format(Number(t)||0);function ct(e){const t=(e||"").replace(/\D/g,""),l=parseInt(t,10);return Number.isNaN(l)?0:l}function dt({list:e=[],min:t,max:l,step:n,value:a=e[0]||t,disabled:i,onChange:r}){const s=e.length?e.indexOf(a):a,o={backgroundSize:`${(100*(s-t)/(l-t)).toFixed(2)}% 100%`};return p("div",{children:[e.length?u("div",{className:"absolute w-full flex justify-between -bottom-[3px] px-4",children:e.map(((e,t)=>u("div",{className:"w-2 h-2 rounded-full "+(s<=t||i?"bg-gray":"bg-primary-main")},String(t))))}):null,u("div",{className:"absolute inset-x-0 -bottom-1 px-4 leading-[18px]",children:u("input",{className:"box-border w-full m-0 cursor-pointer slider relative z-10",style:o,type:"range",min:t,max:l,step:n,value:s,disabled:i,onInput:t=>{const l=ct(t.target?.value),n=e.length?e[l]:l;r&&r(n||0)}})})]})}const mt=1,ht=100,ut=g((e=>{const{className:t,title:l,items:n=[],list:a=[],min:r=(a.length?0:mt),max:s=(a.length?a.length-1:ht),step:o=1,value:c=a[0]||r,disabled:d=!1,onChange:m}=e,h=rt(e,{normalize:(e=0)=>a.length?pt(a)(e):st(e,r,s),format:ot()}),g=i((e=>{m&&m(ct(e.target?.value))}),[m]);return p("div",{className:t,children:[p("label",{className:"block relative",children:[l?u(me,{size:"text-m",font:"font-light",color:"text-primary-text",children:l}):null,u("input",{className:w("m-0 mt-2 font-sans text-h3 w-full h-14","border border-solid border-gray rounded-md outline-none","p-0 pl-4 box-border","text-primary-text hover:border-primary-hover focus:border-primary-text","disabled:border-gray disabled:bg-main-divider"),disabled:d,onInput:g,...h}),dt({list:a,min:r,max:s,step:o,disabled:d,value:c,onChange:m})]}),gt(n)]})})),pt=e=>t=>e.reduce(((e,l)=>Math.abs(l-t)<Math.abs(e-t)?l:e)),gt=e=>u("div",{className:"flex justify-between my-2",children:e.map(((e,t)=>u(me,{size:"text-s-light",color:"text-secondary-text",children:e},String(t))))}),xt=e=>p("div",{className:"flex justify-between gap-5 mb-7",children:[p("div",{className:"w-1/2",children:[u("label",{children:u(me,{size:"text-m-light",children:"Сумма кредита, ₽"})}),u(ut,{items:nt,min:1e3,max:1e9,...e("amount")})]}),p("div",{className:"w-1/2",children:[u("label",{children:u(me,{size:"text-m-light",children:"Срок кредита, месяцев"})}),u(ut,{items:at,min:1,max:180,...e("term")})]})]}),ft=({regions:e,branches:t,field:l})=>p("div",{className:"flex justify-between gap-5 mb-7",children:[u("div",{className:"w-1/2",children:u(Fe,{label:"Регион",placeholder:"Выберите регион",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(l("region"),Se)})}),u("div",{className:"w-1/2",children:u(Fe,{label:"Адрес",placeholder:"Выберите адрес",options:t.map((({branchCode:e="",address:t=""})=>({key:e,text:t}))),...ue(l("department"),Se)})})]}),bt={amount:1e3,term:12,fullName:"",inn:"",name:"",phone:"",mail:"",annualRevenue:""},vt=R({annualRevenue:Se,inn:Te,name:Ie,phone:Be,region:Se,department:Se}),yt=g((({button:e,link:t,onSubmit:l})=>{const n=i((e=>{const{amount:t,term:n,fullName:a,inn:i,name:r,phone:s,mail:o,region:c,department:d,annualRevenue:m}=e;P(vt(e))&&l({typeForm:"cred",fullName:a,inn:i,name:r,phone:s,mail:o,region:c?.text||"",department:d?.text||"",partnerComments:`Сумма=${t}/Срок=${n}/Выручка=${m}`})}),[l]),[a,{field:r,...s}]=B(bt,n),o=A(),c=function(e){const{data:t}=V(e?`/api/v1/branches?regionCode=${e}`:null,lt);return t||tt}(a.region?.key).filter((e=>e?.address));return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Параметры кредита",className:"text-center mb-4"}),xt(r),u(I,{headingType:"h6",title:"Данные организации",className:"text-center mb-4"}),it(r),u(I,{headingType:"h6",title:"Офис банка",className:"text-center mb-4"}),ft({regions:o,branches:c,field:r}),We(e,"mb-4"),u(he,{link:t})]})})),Nt={name:"",phone:""},wt=R({name:Ie,phone:Be}),kt=g((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{name:t,phone:l}=e;P(wt(e))&&n({typeForm:"dpst",name:t,phone:l})}),[n]),[,{field:r,...s}]=B(Nt,a);return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Оставьте заявку и мы ответим на любые вопросы по депозитам",className:"text-center mb-4"}),p("div",{className:"max-w-[560px] m-auto",children:[u(ge,{className:"shrink-0 w-full mb-3",label:"Имя",...ue(r("name"),Ie)}),u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(r("phone"),Be)})]}),p("div",{className:"flex justify-between items-center max-w-[560px] m-auto",children:[u("div",{className:"flex-1",children:u(he,{link:l})}),We(t)]})]})})),Ct=(e,t)=>e?.media&&t?.media?e.media-t.media:0,St=g((({className:e="",image:t,imageClassName:l="",pathPrefix:n})=>{const a=J();return p("picture",{className:e,children:[t?.sources?.length?t.sources.filter((e=>e?.src)).sort(Ct).map((({src:e,format:l,media:i},r)=>u("source",{srcSet:Tt(a,n)(e),type:Bt(l),media:i?`(max-width: ${i}px)`:"",...t.size},`${r}_${e}`))):null,t?.src?It({...t,src:Tt(a,n)(t.src)},l):null]})})),It=(e,t="")=>u("img",{src:e.src,className:w("object-contain",t),alt:e.alt||e.title,title:e.title||"",style:{width:e.size?.width?`${e.size?.width}px`:"100%",height:e.size?.height?`${e.size?.height}px`:"auto"},...e.size}),Tt=(e,t)=>l=>l&&!E(l)?W(e)(H(t,l)):l,Bt=e=>e?`image/${String(e)}`:void 0,Rt=g((({className:e="",image:t,imageClassName:l="",pathPrefix:n,...a})=>t?.src||t?.icon?t.icon?u(je,{className:e,imageClassName:l,iconVersion:t?.iconVersion,name:t.icon,...a}):u(St,{className:e,imageClassName:l,image:t,pathPrefix:n}):null)),Pt=g((({className:e,viewBox:t,fill:l="none",width:n,height:a,paths:i,...r})=>u("svg",{xmlns:"http://www.w3.org/2000/svg",className:e,viewBox:t,fill:l,width:n,height:a,children:i.map((({d:e,fill:t,...l},n)=>u("path",{d:e,fill:t||"currentColor",...r,...l},n)))}))),Mt=[{d:"M10.207.793a1 1 0 0 1 0 1.414l-6 6a1 1 0 0 1-1.414 0l-2.5-2.5a1 1 0 0 1 1.414-1.414L3.5 6.086 8.793.793a1 1 0 0 1 1.414 0Z",fillRule:"evenodd",clipRule:"evenodd",fill:"white"}],_t=g((({className:e,value:t,text:l,disabled:n,isRadio:a,onChange:r})=>{const s=i((e=>{n||(e.preventDefault(),r&&r(!t))}),[r,n,t]),o=a?u("div",{className:"absolute left-1 w-3 h-3 rounded-full bg-primary-main"}):u(Pt,{paths:Mt,className:"absolute left-1 ml-px block",width:"11",height:"9",fill:"white",viewBox:"0 0 11 9"});return u("div",{className:e,children:p("label",{className:"flex items-center relative cursor-pointer group/box",onClick:s,children:[u("div",{className:w("appearance-none w-5 h-5 border-solid cursor-pointer m-0",a?"rounded-full border-2":$t(t),t?"border-primary-main":"border-gray",n?"bg-main-disabled":"group-hover/box:border-primary-hover"),role:"checkbox","aria-checked":Boolean(t),"aria-disabled":Boolean(n)}),t?o:null,l?u("span",{className:"font-sans ml-3 text-l-light",children:l}):null]})})})),$t=e=>w("rounded border",e?"bg-primary-main":""),Vt=e=>{const t=e("text");return p("div",{className:"mb-6",children:[p("div",{className:"flex items-center mb-4 gap-6",children:[u(_t,{text:"Валютный контроль",...e("currencyControl")}),u(_t,{text:"Документарные операции",...e("documentaryOperations")}),u(_t,{text:"Конверсионные операции",...e("conversionOperations")})]}),u("textarea",{placeholder:"Укажите интересующий вас вопрос, место ведения бизнеса и удобное время для телефонного звонка",className:"block w-full resize-y min-h-24 p-4 outline-none border rounded-md border-main-stroke hover:border-primary-hover active:focus:border-primary-text",value:t.value,onInput:e=>t.onChange&&t.onChange(e.target?.value||"")})]})},jt=e=>p("div",{children:[p("div",{className:"flex justify-between gap-5",children:[u("div",{className:"w-1/2",children:u(ge,{className:"shrink-0 w-full mb-3",label:"Наименование организации",...ue(e("fullName"),Se)})}),u("div",{className:"w-1/2",children:u(ge,{className:"shrink-0 w-full mb-3",label:"ФИО",...ue(e("name"),Ie)})})]}),p("div",{className:"flex justify-between gap-5 mb-7",children:[u("div",{className:"w-1/2",children:u(ke,{className:"shrink-0 w-full mb-3",label:"Телефон",...ue(e("phone"),Be)})}),u("div",{className:"w-1/2",children:u(ge,{className:"shrink-0 w-full mb-3",label:"Электронная почта",...ue(e("mail"),Se)})})]})]}),zt={fullName:"",name:"",phone:"",mail:"",currencyControl:!1,documentaryOperations:!1,conversionOperations:!1,text:""},Dt=R({fullName:Se,name:Ie,phone:Be,mail:Se}),Lt=g((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{fullName:t,name:l,phone:a,mail:i,currencyControl:r,documentaryOperations:s,conversionOperations:o,text:c}=e;P(Dt(e))&&n({typeForm:"kved",fullName:t,name:l,phone:a,mail:i,partnerComments:`Валютный контроль=${r}/Документарные операции=${s}/Конверсионные операции=${o}/Доп инф=${c}`})}),[n]),[,{field:r,...s}]=B(zt,a);return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Данные организации",className:"text-center mb-4"}),jt(r),u(I,{headingType:"h6",title:"Интересующий вопрос",className:"text-center mb-4"}),Vt(r),p("div",{className:"flex items-center pb-9 mb-9 border-b border-main-divider",children:[We(t,"mr-5"),u(he,{link:l})]}),u(I,{headingType:"h6",title:"Или свяжитесь с нами удобным способом",className:"text-center mb-4"}),p("div",{className:"flex",children:[p("a",{className:"flex items-center text-primary-text no-underline mr-6",href:"tel:8 (800) 200-78-70","aria-label":"8 (800) 200-78-70",children:[u(Rt,{image:{icon:"PhoneIcon"},width:"24",height:"24",className:"mr-3"}),u("span",{children:"8 (800) 200-78-70"})]}),p("a",{className:"flex items-center text-primary-text no-underline","aria-label":"ved@rshb.ru",href:"mailto:ved@rshb.ru",children:[u(Rt,{image:{icon:"MailIcon"},width:"24",height:"24",className:"mr-3"}),u("span",{children:"ved@rshb.ru"})]})]})]})})),At=g((({responseType:e})=>{const t="OK"===e;return p("div",{className:`flex items-center mt-5 p-5 rounded-md ${t?"bg-ok":"bg-fail"}`,children:[u(Rt,t?{image:{icon:"ResponceOKIcon"},width:"42",height:"42",className:"mr-4"}:{image:{icon:"ResponceFailIcon"},width:"37",height:"34",className:"mr-4"}),p("div",{children:[u(I,{headingType:"h6",title:t?"Ваша заявка отправлена":"Не удалось отправить заявку",className:"mb-1"}),u(me,{size:"text-l-light",color:"text-secondary-text",children:t?"Совсем скоро мы с вами свяжемся":"Пожалуйста, повторите позднее"})]})]})})),Ot={credit:e=>u(yt,{...e}),acquiring:e=>u(Je,{...e}),"business-card":e=>u(et,{...e}),deposit:e=>u(kt,{...e}),wed:e=>u(Lt,{...e})},Et={send:async function(e){try{const t=await fetch("/api/v1/sendcorporatelead",{method:"POST",headers:{"Content-Type":"application/json"},mode:"cors",body:JSON.stringify(e)});return await t.json()}catch(e){return null}}},Ft=g((e=>{const{className:t,title:l,typeForm:a="credit",button:r,link:s,...o}=e,[c,d]=n(""),m=i((async e=>{const t=await Et.send(e)?"OK":"Fail";return d(t),t}),[]);return u(C,{className:t,defaultPadding:"p-default",...o,children:p("div",{className:"container max-w-[978px]",children:[l?u(I,{headingType:"h3",title:l,className:"text-center mb-8"}):null,Ot[a]({button:r,link:s,onSubmit:m}),c?u(At,{responseType:c}):null]})})})),Ut=g((({className:e="",title:t,benefitList:l,...n})=>p(C,{className:e,defaultPadding:"p-default",...n,children:[t?u(I,{headingType:"h3",as:"h2",className:"text-center",title:t}):null,l?.length?u("div",{className:"sm:flex sm:flex-wrap w-full sm:justify-center sm:gap-x-m gap-y-lg sm:gap-y-0 mt-8",role:"list",children:l.map(Ht)}):null]}))),Ht=(e,t)=>p("div",{className:"flex items-center sm:basis-1/2 sm:max-w-[400px] mb-14",role:"listitem",children:[e?.icon?.icon?u(Rt,{className:w("p-3 mr-5 shrink-0 bg-main-divider text-primary-main group-data-secondary:bg-white/30 group-data-secondary:text-black","w-12 h-12 min-w-12 rounded-full"),image:e.icon}):null,e?.icon?.src?u(Rt,{className:"mr-5 shrink-0",image:e.icon}):null,e?.label?p("div",{className:"sm:h-full",children:[u(I,{headingType:"h6",children:e.label}),Xt(e.description)]}):null]},String(t)),Xt=e=>{const t=e?.benefitType||null;return e&&t?u("div",{className:"mt-2 text-l-light text-secondary-text group-data-secondary:text-white/80",children:"list"===t?Kt(e):Wt(e)}):null},Wt=e=>e?.name||null,Kt=e=>{const t=e?.bullets?"list-disc pl-6":"";return e?.items&&e.items.length>0?u("ul",{className:t,children:e.items.map(((e,t)=>u("li",{children:e},`benefitListItem-${t}`)))}):null},Gt=(e,{className:t,buttonClassName:l,isVertical:n}={})=>e?.length&&e.some((e=>e?.text||e?.icon?.icon))?u("div",{className:w("flex",n?"flex-col gap-xs justify-items-stretch":"flex-wrap gap-s",t),children:e.map(Jt(l))}):null,Jt=(e="")=>(t,l)=>{const{text:n,icon:a,iconRight:i,version:r,...s}=t||{},o="secondary"===r?"color":"white",c=a?.iconVersion?a?.iconVersion:o;return n||a?.icon?u(se,{className:w("basis-full sm:basis-auto",e),appendLeft:Yt({...a,iconVersion:c}),appendRight:Yt({...i,iconVersion:c}),version:r,text:n,...s},l?String(l):""):null},Yt=e=>e?.icon||e?.src?u(Rt,{image:e,width:String(e?.size?.width||24),height:String(24)}):null,qt={XXL:{title:{headingType:"h0",as:"h1"},descriptionSize:"text-h5",descriptionStyle:"mt-m"},XL:{title:{headingType:"h1",as:"h1"},descriptionSize:"text-xl-light",descriptionStyle:"mt-s"},L:{title:{headingType:"h2",as:"h2"},descriptionSize:"text-xl-light",descriptionStyle:"mt-s"},M:{title:{headingType:"h3",as:"h2"},descriptionSize:"text-xl-light",descriptionStyle:"mt-text"},S:{title:{headingType:"h4",as:"h2"},descriptionSize:"text-xl-light",descriptionStyle:"mt-xs"},XS:{title:{headingType:"h5",as:"h2"},descriptionSize:"text-l-light",descriptionStyle:"mt-xs"}},Zt={H6:"text-h6",XL_L:"text-xl-light",XL_R:"text-xl",L_L:"text-l-light",L_R:"text-l",M:"text-m-light",S:"text-s-light",XS:"text-xs-light"},Qt=g((({className:e,version:t="",headlineVersion:l="XL",title:n,description:a,align:i="text-center",as:r,isPadding:s=!0,isTheme:o=!1,...c})=>{const d=qt[l],m={marginTop:d.descriptionStyle};return p(C,{className:e,defaultPadding:s?"p-default":"",version:t,isTheme:o,...c,children:[n?u(I,{className:w("whitespace-pre-wrap",i),...d?.title,as:r||d?.title.as,title:n}):null,a?u(de,{size:d.descriptionSize,align:i,...m,children:a}):null]})})),el=g((e=>{const{className:t="",title:l,description:n,bonusItems:a,...i}=e;return u(C,{className:t,defaultPadding:"p-default",...i,children:p("div",{className:"container",children:[u(Qt,{className:"!p-0",title:l,description:n,headlineVersion:"M"}),u("div",{className:"flex flex-wrap w-full mt-9",children:a?.length?a.map(((e,t)=>p("div",{className:"flex-grow w-[49%] border border-gray p-9 mb-3 mx-2 even:mr-0 odd:ml-0 last:odd:mx-0",children:[e?.title?u(me,{size:"text-h4",children:e.title}):null,e?.description?u("div",{className:"mt-2",children:u(de,{size:"text-xl",font:"font-light",children:e.description})}):null,p("div",{className:"flex justify-between items-end mt-3",children:[Gt(e?.buttons),e.bonusItemContent?.bonusType?tl(e.bonusItemContent):null]})]},String(t)))):null})]})})})),tl=e=>u("div",{children:"count"===e.bonusType?ll(e):nl(e)}),ll=e=>p("div",{className:"relative -bottom-3 h-auto flex items-end mt-14 shrink-0",children:[e.bonusCount?u("span",{className:"font-mohave -tracking-[5px] text-title-extra bg-clip-text text-transparent bg-green-to-yellow -mb-7",children:e.bonusCount}):null,e.bonusName?u("span",{className:"text-h2 bg-clip-text text-transparent bg-green-to-yellow",children:e.bonusName}):null]}),nl=e=>e.image?u(Rt,{className:"w-12 h-12 min-w-12 p-3 rounded-icon",image:e.image}):null,al={left:"text-left",center:"text-center",right:"text-right"},il="text-center",rl=({icon:e,title:t,description:l},n)=>p("div",{className:w("flex flex-col","items-center",l||t?"":"justify-center"),children:[t?u(me,{size:"text-h6",font:"font-normal",align:il,children:t}):null,e?u(Rt,{image:e,height:"180",className:"w-auto"}):null,l?u(me,{size:"text-h6",font:"font-normal",align:il,children:l}):null]},String(n)),sl=(e,t,l)=>u("div",{className:`grid gap-1 ${al[l]} ${ol(t)}`,children:e.map(rl)}),ol=e=>{switch(e){case"3":return"grid-cols-3";case"4":return"grid-cols-4";default:return"grid-cols-5"}},cl=g((({bonusBenefits:e,cardTextAlign:t="center",className:l="",columnsCount:n="4",subtitle:a,title:i,...r})=>p(C,{className:w("p-default",l),defaultPadding:"p-default",...r,children:[u(Qt,{className:"mb-4 sm:mb-8",isPadding:!1,title:i,description:a,headlineVersion:"M"}),e?.length?sl(e,n,t):null]}))),dl=g((e=>{const{title:t,image:l,cardItems:n,button:a}=e;return p("div",{className:"border-gray border p-9 w-1/2",children:[l?p("div",{className:"flex justify-center",children:[l?.src?u(Rt,{className:"mb-5",image:l}):null,l?.icon?u(Rt,{image:l}):null]}):null,t?u(I,{headingType:"h4",title:t,className:"mb-6"}):null,n?.length?u("ul",{children:n.map(((e,t)=>ml(e,String(t))))}):null,Gt([a],{buttonClassName:"mt-6"})]})})),ml=(e,t)=>{const{icon:l,text:n}=e;return p("li",{className:"flex items-center gap-3.5 mb-3 last:mb-0",children:[l?.icon?u(Rt,{image:l,className:"w-12 h-12 min-w-12 p-3 rounded-icon bg-main-divider"}):null,l?.src?u(Rt,{image:l}):null,u("span",{className:"text-xl-light",children:n})]},t)},hl=g((({className:e,title:t,cards:l,...n})=>p(C,{className:e,defaultPadding:"p-default",...n,children:[u(I,{headingType:"h3",title:t,className:"text-center mb-8"}),u("div",{className:"flex gap-5",children:l?.length?l.map(((e,t)=>u(dl,{...e},String(t)))):null})]}))),ul=g((({buttons:e,className:t,...l})=>u(C,{className:w("!bg-transparent",t),defaultPadding:"p-0",...l,children:Gt(e)}))),pl=e=>{const{itemCount:t,visibleItemCount:l}=e,[a,r]=n(0),s=i((()=>r((e=>Math.min(e+1,t-1)))),[t]),o=i((()=>r((e=>Math.max(e-1,0)))),[t]),c=function({itemCount:e,visibleItemCount:t}){return Boolean(t&&e>t)}(e)&&a<t-(l||1),d=a>0;return[a,{inc:s,dec:o,canInc:c,canDec:d,isScrollAvailable:d||c}]};const gl=g((({className:e,disabled:t,...l})=>u(se,{rounded:!0,className:`group/btn shadow-[0_4px_25px_rgba(0,0,0,0.07)] w-12 h-12 min-h-12 max-h-12 flex items-center justify-center ${t?"bg-secondary-light text-secondary-text":"bg-white text-primary-text hover:text-primary-main"} ${e||""}`,disabled:t,...l,children:u(Rt,{className:"w-4 h-4 min-w-4 min-h-4 rounded-full box-border",image:{icon:"ArrowLeftIcon",iconVersion:"black"},imageClassName:"group-hover/btn:text-primary-main",width:"16",height:"16"})}))),xl=g((e=>u(gl,{...e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left"}))),fl=g((e=>u(gl,{...e,className:`${e.className||""} rotate-180`,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right"})));function bl({dec:e,inc:t,canDec:l,canInc:n,btnClass:a,className:i=""}){return l||n?p("div",{children:[l?u(gl,{className:`absolute z-40 ${a[0]} ${i}`,onClick:e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left",disabled:!l}):null,n?u(gl,{className:`absolute z-40 rotate-180 ${a[1]} ${i}`,onClick:t,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right",disabled:!n}):null]}):null}const vl=g((({title:e,value:t,postfix:l="",prefix:n,className:a=""})=>p("div",{className:w("mb-7",a),children:[e?u(me,{size:"text-l-light",color:"text-secondary-text",children:e}):null,u("div",t?{children:p(me,{size:"text-h3",children:[n," ",ot(2)(Math.round(t))," ",l]})}:{children:u(me,{size:"text-h3",children:"-"})})]}))),yl=Math.round(23.5),Nl={minSum:1e4,maxSum:5e6,minMonths:13,maxMonths:60,rate:12.5,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,isInsurance:!0},wl={minSumTravel:6e3,maxSumTravel:2e5,minSumOther:6e3,maxSumOther:2e5,maxBonus:5e3,prefMonthsNum:2,prefTravelBonusRate:.015,prefRestBonusRate:.01,travelBonusRate:.015,restBonusRate:.01},kl={minSum:5e4,maxSum:5e6,minMonths:2,maxMonths:10,rate:0,isMonthlyInterestPayment:!0,isRemoteRegistration:!0},Cl={minSum:1e3,maxSum:5e5,minDays:1,maxDays:1095,rate:0,isMonthlyInterestPayment:!0,isReplenished:!1,isPartialWithdrawal:!1,isSmallBusiness:!1,depositeName:"Депозит 'Стабильный'"},Sl=g((({rate:e,title:t="Ставка",unit:l,depositeName:n,isShowDepositeName:a,rateBlockClassName:i,fractionDigits:r=2})=>p("div",{children:[u(me,{size:"text-l-light",color:"text-secondary-text",children:t}),p("div",{className:"relative",children:[p("div",{className:"flex justify-start gradient-color-text",children:[u("span",{className:w("font-mohave text-title-huge pr-6 -mt-4",i),children:String(e.toFixed(r)).replace(".",",")}),l?u("span",{className:"text-7xl",children:l}):null]}),n&&a?u("div",{className:"absolute bottom-7 w-full text-center whitespace-nowrap",children:n}):null]})]}))),Il=e=>e?u(de,{size:"text-s-light",color:"text-secondary-text",children:e}):null;function Tl({isShowItems:e=!0,step:t=1e3,...l}){const n=[`От ${ot(2)(l.min||0)} ₽`,`До ${ot(2)(l.max||0)} ₽`];return u(ut,{items:e?n:[],step:t,...l})}function Bl(e){const{data:t}=V(`/wcms-resources/${e}.json`,D);return t}const Rl=(e,t)=>{const{travelExpenseValue:l,restExpenseValue:n}=e,a=Bl(t||"bonus-calculator-data")||wl,[i,r]=((e,t,l)=>{const{minSumTravel:n,minSumOther:a,maxBonus:i,prefMonthsNum:r,prefTravelBonusRate:s,prefRestBonusRate:o,travelBonusRate:c,restBonusRate:d}=e;if(t===n&&l===a)return[0,0];const m=Math.min(Math.round(s*t)+Math.round(o*l),i);return[m,m*r+Math.min(Math.round(c*t)+Math.round(d*l),i)*(12-r)]})(a,l,n);return{...a,...e,monthBonus:i,yearBonus:r}},Pl=g((({className:e="",sourceBookDir:t="",buttons:l,footnote:n})=>{const[a,{field:i}]=B({travelExpenseValue:6e3,restExpenseValue:6e3}),{minSumTravel:r,maxSumTravel:s,minSumOther:o,maxSumOther:c,monthBonus:d,yearBonus:m}=Rl(a,t);return p("section",{className:w("flex justify-between",e),children:[p("div",{className:"w-[468px]",children:[Tl({title:"Сумма покупок в категории путешествия, ₽",min:r,max:s,step:500,isShowItems:!1,...i("travelExpenseValue")}),Tl({title:"Сумма покупок в остальных категориях, ₽",className:"mt-7",min:o,max:c,step:500,isShowItems:!1,...i("restExpenseValue")})]}),u("div",{children:d>=0?u(Sl,{title:"Баллов за месяц",rate:d,rateBlockClassName:"tracking-[-14px]",fractionDigits:0}):null}),p("div",{className:"w-full max-w-[350px]",children:[m>=0?u(vl,{title:"Баллов за год",value:m}):null,Gt(l,{className:"mt-7",isVertical:!0}),Il(n)]})]})})),Ml=e=>`${e} ${Number(e)%10==1?"дня":"дней"}`,_l={horizontal:"gap-10",vertical:"flex-col gap-3"},$l=g((({items:e,checkedItem:t,onChange:l,orientation:n="horizontal"})=>u("div",{className:`flex ${_l[n]}`,children:e?.map((({id:e,text:n})=>u(_t,{isRadio:!0,text:n,value:t===e,onChange:()=>l&&l(e)},String(e))))}))),Vl=({items:e,title:t,orientation:l="horizontal",value:n,onChange:a})=>p("div",{children:[t?u("div",{className:"mb-3",children:u(me,{color:"text-secondary-text",font:"font-light",children:t})}):null,u($l,{orientation:l,items:e,checkedItem:e[n?0:1].id,onChange:t=>a&&a(t===e[0].id)})]}),jl=e=>Vl({...e,items:[{id:"everyMonth",text:"Ежемесячно"},{id:"atEndTerm",text:"В конце срока"}]}),zl=g((({title:e="Ставка"})=>p("div",{children:[u(me,{size:"text-l-light",color:"text-secondary-text",children:e}),u("div",{className:"mt-1 pt-1 pl-5 pb-1.5",children:u(je,{name:"PercentIcon",width:"90",height:"85"})}),u("div",{className:"w-[250px] mt-3.5",children:p(de,{size:"text-xl-light",color:"text-primary-text",children:["Процентная ставка для срока ",u("strong",{children:"1-30 дней"})," устанавливается при обращении в Банк"]})})]}))),Dl=e=>e,Ll=(e=Dl)=>t=>t.reduceRight(((t,l)=>e(t)>e(l)?t:l)),Al=Ll(),Ol=e=>{const t=[...e];t.sort((([e],[t])=>e-t));let l=1;for(;l<t.length;){const[e,n]=t[l-1],[a,i]=t[l];n>=a?t.splice(l-1,2,[e,Math.max(n,i)]):l++}return t},El=(e=Dl)=>Ll((t=>-e(t))),Fl=El(),Ul=([e,t],l,n=[])=>l&&l[e]&&l[t]?{[e]:l[e],[t]:l[t]}:Hl([e,t],n),Hl=([e,t],l=[])=>({[e]:l.length?Fl(l.filter((t=>t[e])).map((t=>t[e]))):0,[t]:l.length?Al(l.filter((e=>e[t])).map((e=>e[t]))):0}),Xl=(e,[t,l],n)=>e>=n[t]&&e<=n[l],Wl=(e,t)=>e?t.isReplenished&&t.isPartialWithdrawal:!t.isReplenished&&!t.isPartialWithdrawal,Kl=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,daysValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a/30)-n):Math.round(n*e*a/365/100)},Gl=g((({className:e="",sourceBookDir:t,buttons:l,footnote:n,bottomFootnote:a,isShowDepositeName:i})=>{const[r,{field:s}]=B({moneyValue:1e5,daysValue:90,isReplenished:!1,isPartialWithdrawal:!1,isSmallBusiness:!1,isMonthlyInterestPayment:!1}),o=((e,t)=>{const{daysValue:l,moneyValue:n,isPartialWithdrawal:a,isReplenished:i,isSmallBusiness:r,isMonthlyInterestPayment:s}=e,o=Bl(t||"business-calculator-data"),c=i||a,d=l<90||l>730;if(l<=30)return{...Cl,...e,isDisabledOperatingDeposit:d,isShowUnknownRate:!0};const m=o?.rateRows?.find((e=>s===e.isMonthlyInterestPayment&&r===e.isSmallBusiness&&Wl(c,e)&&Xl(n,["minSum","maxSum"],e)&&Xl(l,["minDays","maxDays"],e)))||Cl,{rate:h}=m,u=Kl(h,e),p=n+u,g=o?.rateRows||[Cl];return{...m,...Hl(["minSum","maxSum"],g),...Hl(["minDays","maxDays"],g),...e,isDisabledOperatingDeposit:d,income:u,finalSum:p}})(r,t),{income:c,finalSum:d,rate:m,depositeName:h,isShowUnknownRate:g}=o;return p("section",{className:e,children:[p("div",{className:"flex justify-between",children:[p("div",{className:"w-[486px]",children:[Tl({title:"Сумма вклада, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),(x={title:"Срок вклада, дни",min:o.minDays,max:o.maxDays,...s("daysValue"),value:o.daysValue},u(ut,{className:"mt-7",items:[`От ${Ml(x.min||0)}`,`До ${Ml(x.max||0)}`],step:1,...x})),p("div",{className:"mt-7 flex justify-between",children:[Jl(o,s),jl({title:"Выплата процентов",orientation:"vertical",...s("isMonthlyInterestPayment")})]})]}),g?u(zl,{}):u(Sl,{rate:m,depositeName:h,isShowDepositeName:i,rateBlockClassName:"tracking-[-25px]",unit:"%"}),p("div",{className:"w-full max-w-[350px]",children:[u(vl,{title:"Доход по вкладу",value:c,postfix:"₽",prefix:"+"}),u(vl,{title:"Сумма в конце срока",value:d,postfix:"₽"}),Gt(l,{className:"mt-7",isVertical:!0}),u("div",{className:"mt-7",children:Il(n)})]})]}),u("div",{className:"mt-5",children:Il(a)})]});var x})),Jl=(e,t)=>p("div",{children:[u(_t,{text:"Пополнение",disabled:e.isDisabledOperatingDeposit,...t("isReplenished"),value:e.isReplenished}),u(_t,{className:"mt-3",disabled:e.isDisabledOperatingDeposit,text:"Частичное снятие",...t("isPartialWithdrawal"),value:e.isPartialWithdrawal}),u(_t,{className:"mt-3",text:"Являюсь малым предприятием",...t("isSmallBusiness"),value:e.isSmallBusiness})]}),Yl=({min:e=0,max:t=0,availableMonths:l,...n})=>u(ut,{className:"mt-7",items:[`От ${ql(e)}`,`До ${ql(t)}`],step:1,...l?.length?{list:l}:{min:e,max:t},...n}),ql=e=>`${e} ${Number(e)%10==1?"месяца":"месяцев"}`,Zl=e=>Ql({...e,fieldKey:"isSalaryClient",viewSettingFieldKey:"isShowSalaryClient"})&&Ql({...e,fieldKey:"isStateEmployee",viewSettingFieldKey:"isShowStateEmployee"})&&Ql({...e,fieldKey:"isPensionClient",viewSettingFieldKey:"isShowPensionClient"})&&Ql({...e,fieldKey:"isInsurance",viewSettingFieldKey:"isShowInsurance"}),Ql=({row:e,userInputParams:t,paramsViewSettings:l,fieldKey:n,viewSettingFieldKey:a})=>!!l&&!l[a]||t[n]===e[n],en=(e,t,l)=>{let{moneyValue:n,monthsValue:a}=e;const i=Bl(t||"credit-calculator-data"),s=i?.rateRows||[Nl],o=(({limitRows:e,userInputParams:t,paramsViewSettings:l})=>e?.find((e=>Zl({row:e,userInputParams:t,paramsViewSettings:l}))))({limitRows:i?.limitRows||[],userInputParams:e,paramsViewSettings:l}),{minSum:c,maxSum:d}=Ul(["minSum","maxSum"],o,s),{minMonths:m,maxMonths:h}=Ul(["minMonths","maxMonths"],o,s);n=st(n,c,d),a=st(a,m,h);const u=(({rateRows:e=[],userInputParams:t,paramsViewSettings:l,moneyValue:n,monthsValue:a})=>e?.find((e=>Zl({row:e,userInputParams:t,paramsViewSettings:l})&&Xl(n,["minSum","maxSum"],e)&&Xl(a,["minMonths","maxMonths"],e)))||Nl)({rateRows:s,userInputParams:e,paramsViewSettings:l,moneyValue:n,monthsValue:a}),{rate:p}=u,g=((e,t)=>{const{isAnnuity:l,moneyValue:n,monthsValue:a}=t;if(0===e)return 0;if(l){const t=e/1200;return n*(t+t/(Math.pow(1+t,a)-1))}return Math.round(n/a)+n*(e/1200)})(p,e);return r((()=>({...u,...e,minSum:c,maxSum:d,minMonths:m,maxMonths:h,moneyValue:n,monthsValue:a,monthlyPayment:g})),[e,i])},tn=g((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:a})=>{const[i,{field:r}]=B({isAnnuity:!1,isInsurance:!0,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,moneyValue:2e5,monthsValue:yl}),s=en(i,t,a);return p("section",{className:w("flex justify-between",e),children:[p("div",{className:"w-[468px]",children:[Tl({title:"Сумма кредита, ₽",step:500,min:s.minSum,max:s.maxSum,...r("moneyValue"),value:s.moneyValue}),Yl({title:"Срок кредита, месяцев",min:s.minMonths,max:s.maxMonths,...r("monthsValue"),value:s.monthsValue}),u("div",{className:"mt-7",children:ln({...s,...a},r)})]}),u(Sl,{title:"Ставка",rate:s.rate,rateBlockClassName:"tracking-[-25px]",unit:"%"}),p("div",{className:"w-full max-w-[350px]",children:[u(vl,{title:"Ежемесячный платеж",value:s.monthlyPayment,postfix:"₽"}),(o={orientation:"vertical",...r("isAnnuity")},Vl({...o,items:[{id:"annuity",text:"Аннуитетный"},{id:"differential",text:"Дифференцированный"}]})),Gt(l,{className:"mt-7",isVertical:!0}),Il(n)]})]});var o})),ln=(e,t)=>p("div",{children:[e.isShowSalaryClient?u(_t,{text:"Получаю зарплату на счёт в Россельхозбанке",...t("isSalaryClient"),value:e.isSalaryClient}):null,e.isShowStateEmployee?u(_t,{className:"mt-3",text:"Работаю в бюджетной организации",...t("isStateEmployee"),value:e.isStateEmployee}):null,e.isShowPensionClient?u(_t,{className:"mt-3",text:"Получаю пенсию на карту Россельхозбанка",...t("isPensionClient"),value:e.isPensionClient}):null,e.isShowInsurance?u(_t,{className:"mt-3",text:"Комплексная страховая защита",...t("isInsurance"),value:e.isInsurance}):null]}),nn=(e,t,l)=>{const{moneyValue:n,monthsValue:a}=e,i=Bl(t||"deposit-calculator-data"),r=i?.rateRows?.[0]?sn(i.rateRows[0].minMonths,i.rateRows[0].maxMonths):1,s=!l?.isShowMonthlyInterestPayment,o=!l?.isShowRemoteRegistration,c=i?.rateRows?.find((t=>rn({row:t,userInputParams:e,paramKey:"isMonthlyInterestPayment",isExclude:s})&&rn({row:t,userInputParams:e,paramKey:"isRemoteRegistration",isExclude:o})&&Xl(n,["minSum","maxSum"],t)&&Xl(a||r,["minMonths","maxMonths"],t)))||kl,{rate:d}=c,m=an(d,e),h=n+m,u=i?.rateRows||[kl];return{...c,...Hl(["minSum","maxSum"],u),...Hl(["minMonths","maxMonths"],u),availableMonths:Ol(u.map((e=>[e.minMonths,e.maxMonths]))).flatMap((([e,t])=>((e,t,l=1)=>Array.from({length:Math.abs(t-e)/l+1},((n,a)=>t>=e?e+a*l:e-a*l)))(e,t))),...e,defaultMonth:r,income:m,finalSum:h}},an=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,monthsValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a)-n):Math.round(n*e*30*a/365/100)},rn=({row:e,userInputParams:t,paramKey:l,isExclude:n})=>n||t[l]===e[l],sn=(e,t)=>e+Math.round((t-e)/2),on=g((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:i})=>{const[r,{field:s}]=B({moneyValue:2e4,monthsValue:0,isMonthlyInterestPayment:!1,isRemoteRegistration:!1}),o=nn(r,t,i),{defaultMonth:c,income:d,finalSum:m,rate:h}=o,{onChange:g}=s("monthsValue");return a((()=>{g&&g(c)}),[c]),p("section",{className:w("flex justify-between",e),children:[p("div",{className:"w-[468px]",children:[Tl({title:"Сумма вклада, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),Yl({title:"Срок вклада, месяцев",min:o.minMonths,max:o.maxMonths,availableMonths:o.availableMonths,...s("monthsValue"),value:o.monthsValue}),u("div",{className:"mt-7",children:cn({...o,...i},s)})]}),u(Sl,{rate:h,rateBlockClassName:"tracking-[-25px]",unit:"%"}),p("div",{className:"w-full max-w-[350px]",children:[u(vl,{title:"Доход по вкладу",value:d,postfix:"₽",prefix:"+"}),u(vl,{title:"Сумма в конце срока",value:m,postfix:"₽"}),Gt(l,{className:"mt-7",isVertical:!0}),Il(n)]})]})})),cn=(e,t)=>{return p("div",{className:"flex flex-col gap-y-7",children:[e.isShowMonthlyInterestPayment?jl({title:"Выплата процентов",...t("isMonthlyInterestPayment"),value:e.isMonthlyInterestPayment}):null,e.isShowRemoteRegistration?(l={title:"Оформление",...t("isRemoteRegistration"),value:e.isRemoteRegistration},Vl({...l,items:[{id:"remote",text:"Дистанционно"},{id:"office",text:"Офис Банка"}]})):null]});var l},dn={CreditCalculatorForm:tn,DepositCalculatorForm:on,BusinessDepositCalculatorForm:Gl,BonusCalculatorForm:Pl},mn=(e,t)=>{const l=e?.calcType;if(!l||!(l in dn))return null;const n=dn[l];return u("section",{className:"box-border relative bg-white flex shrink-0 self-start basis-full",role:"listitem",children:p("div",{className:"box-border p-9 w-full",children:[e?.title?u(I,{className:"text-center mb-6",title:e.title}):null,u(n,{...e})]})},String(t))},hn=g((({className:e="",calculatorTabs:t=[],...l})=>{const a=t.map((e=>e.nav||{})),r=t.map((({calculatorBlock:e})=>e||{})),[s,o]=n(0),c=i((e=>o(e)),[]),[d,m]=pl({itemCount:t?.length,visibleItemCount:3});return p(C,{className:w("box-border overflow-hidden relative",e),defaultPadding:"p-0",...l,children:[p("div",{className:"bg-white",children:[a.length>1?un({activeIndex:d,tabsNav:a,slideIndexShift:s,onClick:c}):null,bl({...m,btnClass:["left-3","right-3"],className:"top-8"})]}),u("div",{className:"flex",style:{transform:`translateX(-${s}00%)`},role:"list",children:r?.length?r.map(mn):null})]})}));function un({activeIndex:e,tabsNav:t,slideIndexShift:l,onClick:n}){return p("div",{children:[u("div",{style:{transform:`translateX(-${388*e}px)`},className:"flex flex-col justify-end items-center h-[126px] pt-9 box-border duration-1000",children:u("div",{className:"w-full flex flex-nowrap items-end gap-2",children:t.map(((e,t)=>function({tab:e,i:t,isActive:l,onClick:n}){const a=l?"h-[88px] w-[387px] min-w-[387px] p-5 border-none bg-primary-main text-white":"h-[77px] w-[328px] min-w-[328px] px-5 py-4 ease-in duration-300 bg-white text-primary-text",i=l?"text-xl mb-1.5":"text-l mb-[3px]",r=l?"text-l-light text-white":"text-m-light text-secondary-text",s=l?"":"text-primary-main",o=e?.icon?.iconVersion,c=l?"white":"normal";return p("button",{type:"button",onClick:n,"aria-label":e?.title,className:w("box-border relative border border-gray cursor-pointer text-left border-b-0 flex hover:h-[88px]",a),children:[u(Rt,{className:`h-6 w-6 min-w-6 min-h-6 mr-4 ${s}`,image:{...e?.icon,iconVersion:o??c},width:"24",height:"24"}),p("div",{className:"border-0",children:[u("div",{className:i,children:e?.title}),u("div",{className:r,children:e.description})]})]},String(t))}({tab:e,i:t,isActive:Boolean(t===l),onClick:()=>n(t)})))})}),u("div",{className:"w-full h-2 bg-primary-main"})]})}const pn=g((e=>{const{onChange:t,min:l,max:n,defaultValue:a="0",fractionDigits:r=0,...s}=e,o=rt(e,{normalize:(e=a)=>l&&n?String(st(Number(gn(e)),l,n)):gn(e),format:ot(r)}),c=i((e=>t&&t(gn(e))),[t]);return u(pe,{onChange:c,...s,...o})})),gn=(e="")=>e.replaceAll(",",".").replace(/[^\d.]/g,"").replace(/([^.]*\.[^.]*)\./,"$1"),xn=g((e=>u(pn,{...e,fractionDigits:2,children:u("div",{className:"absolute right-4 bottom-4",children:u(me,{size:"text-xl",font:"font-light",children:"₽"})})}))),fn="amount",bn={[fn]:1500},vn=g((({className:e="",title:t="Укажите сумму перевода",label:l="Сумма перевода",placeholder:n="1500",button:a,...i})=>{const[{amount:r},{field:s}]=B(bn),o=r<=0,c=o?ie({version:a?.version}):re({className:"text-white",version:a?.version}),d=Y();return p(C,{className:w("flex flex-col items-center",e),defaultPadding:"p-default",...i,children:[t?u(I,{className:"pb-5 xl:pb-9 self-start xl:self-center",headingType:"h2",title:t}):null,p("form",{className:"w-full xl:max-w-[468px]",method:"POST",action:"https://www.rshb.ru/p2p/",children:[u(xn,{name:fn,valid:!o,placeholder:n,label:l,...s(fn,{parse:Number,format:String})}),a?.text?u("button",{type:"submit",className:w("w-full p-4 mt-5 xl:mt-6",c),disabled:o,...d(a),children:a.text}):null]})]})})),yn=({blockClassName:e,block:t,render:l})=>l({blockClassName:e,block:t}),Nn=[];function wn(e,t,{className:l,...n}={}){const{key:a,blockDecorator:i=yn,blocksRegistry:r={},ancestors:s=Nn}=t,{type:o}=e;o&&o in r||console.warn(`No block with "${o}" is registered`);const c=o&&r[o];return i({blockClassName:w("scroll-mt-12",l,e.style||"col-span-12"),block:e,ancestors:s,render:({block:l,blockClassName:i})=>{const{content:r}=l;return c?u(c,{className:i,block:e,options:t,...r,...n},a):null}},a)}const kn=[],Cn=(e,{key:t,ancestors:l=kn,slotName:n=null,renderProps:a=wn,...i})=>(e||[]).map(((e,r)=>a(e,{...i,key:`${t||e.type}-${r}`,ancestors:i.parent?[...l||kn,[i.parent,n]]:l})));function Sn({children:e,block:t,options:l,renderProps:n}){return e||(t&&l?Cn(t.blocks,{...l,parent:t,renderProps:n}):null)}const In=e=>({height:"calc(100vh - 242px)",minHeight:`${e||866}px`}),Tn=g((({className:e="",style:t,idx:l,activeIndex:n,observerOptions:a,children:r,onIntersection:s})=>{const o=v(i((e=>{e.length&&s&&s(l||0,e[e.length-1])}),[s,l]),a);return u("div",{className:`inline-block snap-always box-border ${e}`,style:t,"aria-current":Boolean(l===n),ref:o,children:r})})),Bn=["min-w-[100%]","min-w-[50%]","min-w-[33.33%]","min-w-[25%]"],Rn=g((({className:e="",containerRef:t,activeIndex:l,visibleItemCount:n=0,gap:a=0,padding:r=0,listType:o="horizontal-list",snapAlign:c="snap-center",minHeight:d,children:m,onVisibleItemsChange:h,onVisibleIndicesChange:p})=>{const g={sensitivity:1,rootRef:t},x=s([]),f=i(((e,t)=>{const l=[...x.current||[]];l[e]=t,x.current=l,h&&h(l),p&&p(Mn(l))}),[h,p]),b=n>0?a*Number(n)-1:0,v="vertical-list"===o,y="horizontal-list"===o,N={...y?Pn(r,b):{},...v?In(d):{},gap:`${a}px`};return u("div",{className:w("box-border overflow-auto no-scrollbar",o,e),style:N,ref:t,children:(k=(e,t)=>u(Tn,{className:w(c,n?Bn[n-1]:"",v?"h-full":""),style:y?Pn(r/4):{},activeIndex:l,idx:t,observerOptions:g,onIntersection:f,children:e},String(t)),e=>null==e?e:Array.isArray(e)?e.map(k):k(e,0))(m)});var k})),Pn=(e,t=0)=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e+t}px`}),Mn=e=>e.map(((e,t)=>[e,t])).filter((([e])=>e&&e.intersectionRatio>=.9)).map((([,e])=>e)),_n={"horizontal-list":"mx-auto mt-5 w-fit","vertical-list":"absolute flex-col justify-center h-full top-0 left-4"},$n={"horizontal-list":"w-6","vertical-list":"h-6"},Vn=g((({containerRef:e,activeIndex:t,dotCount:l=0,listType:n="horizontal-list",version:a})=>l?u("div",{className:w("flex gap-2",_n[n],a?"group":""),...a?{"data-ver":a}:{},children:new Array(l).fill(null).map(((l,a)=>u("div",{className:`cursor-pointer rounded-full transition-width duration-300 bg-primary-main group-data-secondary:bg-white group-data-transparent:bg-white ${a===t?$n[n]:"w-2 h-2 opacity-30"}`,role:"button","aria-hidden":!0,onClick:()=>(l=>{l!==t&&e?.current&&e.current.children[l]?.scrollIntoView({behavior:"smooth",block:"nearest"})})(a)},String(a))))}):null)),jn=e=>t=>e.scrollWidth/t,zn=e=>(t,l)=>{e.scrollBy({left:l*jn(e)(t),behavior:"smooth"})},Dn=({itemCount:e,isCyclic:t,onVisibleIndicesChange:l})=>{const a=s(null),[r,o]=n([]),c=i((e=>{o((t=>{return(l=t)===(n=e)||Boolean(l&&n&&l?.length===n?.length&&l.every(((e,t)=>e===n[t])))?t:e;var l,n})),l&&l(e)}),[e]),[d,m]=r.length?[El()(r),Ll()(r)]:[-1,-1],h=d>0,u=m<e-1,p=i((()=>{var l;a.current&&(t&&!h?(l=a.current).scrollTo({left:l.scrollWidth,behavior:"smooth"}):zn(a.current)(e,-1))}),[t,e,h]),g=i((()=>{a.current&&(t&&!u?a.current.scrollTo({left:0,behavior:"smooth"}):zn(a.current)(e,1))}),[e,t,u]);return[a,{scrollLeft:p,scrollRight:g,canScrollLeft:t||h,canScrollRight:t||u,visibleIndicesRange:[d,m],handleVisibleIndicesChange:c}]},Ln="absolute top-[calc(50%-24px)] z-40",An="absolute top-0 bottom-0 z-40 w-[84px] pointer-events-none",On=g((({scroll:e,arrowsPadded:t,isBlur:l,onScrollLeft:n,onScrollRight:a,hasEdgeBlocks:r,activeIndex:s,itemCount:o})=>{const{canScrollLeft:c,canScrollRight:d,scrollLeft:m,scrollRight:h}=e,g=r?s>0:c,x=r?s<o-1:d,f=i((()=>{r?(c&&s!==o-1&&m(),n()):m()}),[m,n,r,c,s,o]),b=i((()=>{r?(d&&0!==s&&h(),a()):h()}),[h,a,r,c,s,o]);return p("div",{children:[En(l,e),g?u(xl,{className:w(Ln,t?"left-8":"left-0"),onClick:f}):null,x?u(fl,{className:w(Ln,t?"right-8":"right-0"),onClick:b}):null]})})),En=(e,t)=>e?p("div",{children:[t.canScrollLeft?u("div",{className:w(An,"left-0 bg-opacity-from-white")}):null,t.canScrollRight?u("div",{className:w(An,"right-0 bg-opacity-to-white")}):null]}):null,Fn=g((({className:e="",itemCount:t,visibleItemCount:l,isBlur:a=!0,isCyclic:r=!1,arrowsPadded:s=!0,isPadding:o=!0,showDots:c=!1,isAlignCenter:d=!1,...m})=>{const{blocks:h=[]}=m.block||{},g=t||h?.length,[x,f]=n(Math.floor((l||0)/2)),b=i((()=>f((e=>e+1))),[]),v=i((()=>f((e=>e-1))),[]),[y,N]=Dn({itemCount:g,isCyclic:r}),[k]=N.visibleIndicesRange,S=h&&"CarouselBankHistoryCard"===h[0]?.type;return u(C,{className:e,defaultPadding:Un(o),...m,children:p("div",{className:w(Hn(d),"relative max-w-full"),children:[u(Rn,{containerRef:y,visibleItemCount:l,snapAlign:"snap-start",gap:4,onVisibleIndicesChange:N.handleVisibleIndicesChange,children:Sn({...m,renderProps:S?(e,t)=>wn(e,t,{blocksLength:h?.length,activeIndex:x}):wn})}),u(On,{scroll:N,isBlur:a,arrowsPadded:s,onScrollLeft:v,onScrollRight:b,hasEdgeBlocks:S,activeIndex:x,itemCount:g}),c?Xn(y,k,g):null]})})}));Fn.childrenTypes=["CarouselCard","CarouselBankHistoryCard","CarouselCatalogCard","CarouselInvestmentCard","CarouselProductCard","CarouselProgramsCard","CarouselRecommendationCard","CarouselTariffsCard","CarouselRichTextCard","CarouselInvestmentCard","CarouselEventCard"];const Un=e=>e?"p-default":"",Hn=e=>e?"flex justify-center":"",Xn=(e,t,l)=>u(Vn,{containerRef:e,activeIndex:t,dotCount:l,listType:"horizontal-list"}),Wn=g((({title:e,description:t,blocksLength:l=0,activeIndex:n,options:a})=>{const i=Number(a?.key?.split("-").slice(-1)[0])||0;return u(C,{className:"flex h-[485px]",defaultPadding:"p-0",children:u("div",i===n?{className:"relative flex items-center w-full",children:u(Qt,{headlineVersion:"M",title:e,description:t,align:"text-left",className:w("absolute z-10 h-[385px] w-[440px] p-8 text-white shadow-dark-blue",Jn(i,l),Kn(i))})}:{className:"flex w-full items-center justify-center",children:u("div",{className:w("flex justify-center items-center h-[300px] w-[340px] font-mohave text-title-large tracking-[-0.03em]",Kn(i)),children:u("span",{className:Gn(i),children:e})})})})})),Kn=e=>{switch(e%3){case 0:default:return"bg-primary-main";case 1:return"bg-green-light";case 2:return"bg-yellow-light"}},Gn=e=>{switch(e%3){case 1:case 2:return"gradient-color-text-on-yellow";default:return"gradient-color-text-on-green"}},Jn=(e,t)=>0===e?"left-9":e===t-1?"right-9":"-left-[25px]",Yn=e=>{const t="col-span-",l=e?.split(/\s+/).find((e=>e.startsWith(t)));return l?parseInt(l.substring(t.length),10):12},qn={normal:"min-w-[970px]",small:"min-w-[355px]"};function Zn(e="",t="normal"){return Yn(e)<=4?"w-[375px]":qn[t]}const Qn="absolute border border-solid border-gray w-full h-full sm:hidden",ea=g((({className:e="",button:t,description:l,title:n,carouselVersion:a="normal",version:i=""})=>u("section",{className:w("flex pb-9 pl-12 sm:p-5 border-box h-full sm:max-w-[375px]",Zn(e,a),e),children:p("div",{className:"relative w-full",children:[u("div",{className:`${Qn} z-10 top-9 right-12 bg-green-dark`}),u("div",{className:`${Qn} z-10 top-6 right-8 bg-green`}),u("div",{className:`${Qn} z-10 top-3 right-4 bg-green-light`}),p("div",{className:"relative h-full bg-white z-10 p-10 border border-solid border-green-light",children:[u(Qt,{className:"!p-0",title:n,description:l,headlineVersion:"L",align:"text-left",version:i}),Gt([t],{className:"mt-14 sm:justify-center",isVertical:!0})]})]})}))),ta={black:"bg-black",white:"bg-white"},la=g((({className:e="",title:t,description:l,image:n,price:a,button:i,colors:r,...s})=>p(C,{className:w("border box-border border-gray p-default sm:p-7 h-full flex flex-col justify-left",e),...s,children:[n?.src?u(Rt,{className:"mb-5 flex justify-center",image:n}):null,t?u(I,{headingType:"h6",as:"h4",className:"text-left mb-1.5",title:t}):null,l?u("div",{className:"mb-4",children:u(de,{size:"text-m",align:"text-left",font:"font-light",children:l})}):null,r?.length?p("div",{className:"flex mb-4 text-secondary-text",children:[u("div",{className:"mr-1.5",children:u(me,{size:"text-s",align:"text-left",font:"font-light",children:"Цвета:"})}),r.map(na)]}):null,a?p(me,{size:"text-h3",align:"text-left",children:[a," ₽"]}):null,Gt([i],{buttonClassName:"mt-5 w-full"})]}))),na=(e,t)=>u("div",{role:"figure",className:`w-6 h-6 ml-1 sm:ml-3 border border-solid border-main-divider rounded-full ${ta[e]}`},String(t)),aa=g((({className:e="",href:t,target:l,isRemote:n=!1,children:a})=>{const i=Y({isRemote:n})({href:t,target:l});return u(t?"a":"div",{className:w("block",e),...t?i:{},children:a})})),ia=g((({className:e="",icon:t,title:l,description:n,href:a,target:i,...r})=>u(C,{className:w("w-[365px]",e),defaultPadding:"p-0",...r,children:p(aa,{className:"flex flex-col",href:a,target:i,children:[t?.icon?u(Rt,{image:t}):null,t?.src?u(Rt,{image:t}):null,l?u(I,{headingType:"h6",as:"h4",className:"text-left pt-3 mb-2",title:l}):null,n?u("div",{className:"mb-4",children:u(me,{font:"font-light",size:"text-m",color:"text-secondary-text",children:n})}):null]})}))),ra={start:"self-start",center:"self-center",end:"self-end"},sa=g((({className:e,defaultPadding:t,padding:l,title:n="",insetTitle:a="",buttons:i,leftImage:r,rightImage:s,imageAlign:o,backImage:c,children:d})=>p("div",{className:w("relative flex flex-col gap-lg font-sans overflow-hidden",l||t,e),children:[c?u("div",{className:"absolute bottom-0 right-0 z-0",children:c}):null,n?u("div",{className:"relative",children:n}):null,p("div",{className:"grow relative flex flex-wrap sm:flex-nowrap justify-between items-stretch gap-lg",children:[oa(r,{imageAlign:o}),p("div",{className:w("flex flex-col gap-lg max-w-[600px] xl:max-w-[728px]",r?"":"grow"),children:[a,u("div",{className:"grow",children:d}),i]}),oa(s,{className:"-order-1 sm:order-1",imageAlign:o})]})]}))),oa=(e,{className:t,imageAlign:l})=>e?u("div",{className:w("flex-shrink-0",l&&ra[l],t),children:e}):null,ca={1:"flex-col",2:"gap-x-10 flex-wrap"},da=g((({className:e,padding:t,additionalDescription:l,cardsList:n=[],columnsMode:a=1,description:i,image:r,title:s,...o})=>u(C,{className:w("box-border text-left w-[697px]","border border-solid border-gray group-data-secondary:border-white/50",e),defaultPadding:"p-0",...o,children:p(sa,{className:"h-full",padding:t,defaultPadding:"p-m",title:s?u(I,{headingType:"h4",as:"h3",className:"mb-3.5 z-10",title:s}):null,backImage:r?.src?u(Rt,{image:r}):null,children:[p("div",{className:"flex justify-between mb-4",children:[i?u("div",{className:"w-1/3",children:u(me,{size:"text-h6",children:i})}):null,l?u(me,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:l}):null]}),n.length?u("ul",{className:w("list-none m-0 p-0 flex gap-y-2",ca[a]),children:ma(n,a)}):null]})}))),ma=(e,t)=>e.slice(0,[4,9][t-1]).map(((e,l)=>{return p("li",{className:2===t?"basis-[calc(50%-20px)]":"",children:[e?.parameter?u("div",{className:"pr-2.5",children:u(me,{size:(n=t,1===n?"text-h6":"text-l"),children:e.parameter})}):null,e?.parameterDescription?u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:e.parameterDescription}):null]},String(l));var n})),ha="bg-transparent border-white border h-[70px] absolute w-[316px] top-0",ua=g((({text:e,href:t="",target:l="",className:n=""})=>{const a=Y()({href:t,target:l});return e?p("div",{className:`relative group/link cursor-pointer w-[328px] h-[82px] ${n}`,children:[p("a",{className:"absolute border border-primary-main ml-3 px-6 py-5\n text-l-light bg-white text-primary-text flex w-[316px]\n justify-between items-center group-hover/link:text-primary-main z-10",role:"link",...a,children:[u("div",{className:"p-0.5",children:e}),u("div",{className:"w-6 h-6",children:u(Rt,{className:"w-4 h-4 min-w-4 min-h-4 rounded-full box-border brightness-0 group-hover/link:brightness-100",image:{icon:"ArrowRightIcon",iconVersion:"black"},imageClassName:"group-hover/link:text-primary-main",width:"24",height:"24"})})]}),u("div",{className:`${ha} mx-1.5 mt-1.5`}),u("div",{className:`${ha} mt-3 mr-3`})]}):null})),pa=g((({className:e,additionalDescription:t,description:l,links:n,title:a,...i})=>p(C,{className:w("flex w-full overflow-hidden justify-between",e),...i,children:[p("div",{className:"flex flex-col max-w-96 pr-m text-white text-xl-light",children:[u(Qt,{isPadding:!1,title:a,description:l,as:"h1",align:"text-left"}),t?u(Qt,{className:"pt-s",description:t,align:"text-left",isPadding:!1}):null]}),n?.length?ga(n):null]}))),ga=e=>{const t=Math.ceil(e.length/10);return u(Fn,{className:"min-w-[832px] w-[832px]",version:"",isBlur:!1,isCyclic:!0,itemCount:t,arrowsPadded:!1,showDots:!0,children:new Array(t).fill(null).map(((t,l)=>u("div",{className:"w-[672px] min-w-[672px] ml-10 mr-10 flex flex-wrap self-start",children:e.slice(10*l,10*(l+1)).map(((e,t)=>u(ua,{className:"m-1",...e},String(t))))},String(l))))})},xa={L:"w-1.5 h-1.5 mr-4",M:"w-1.5 h-1.5 mr-3",S:"w-1 h-1 mr-2"},fa=g((({className:e,isDotted:t=!0,children:l,size:n="M"})=>p("div",{className:w("font-sans flex",e),role:"listitem",children:[t?u("div",{className:"shrink-0",children:u("div",{className:w("align-middle inline-block rounded-full bg-primary-text group-data-secondary:bg-white",xa[n])})}):null,u("span",{children:l})]}))),ba={S:"text-l-light",M:"text-h6",L:"text-h5"},va={S:"ml-2",M:"ml-3",L:"ml-4"},ya=g((({className:e,hasIndent:t,isDotted:l,items:n,listItemSize:a="M"})=>n?.length?u("section",{className:w("flex flex-col gap-2 text-left text-primary-text group-data-secondary:text-white group-data-gray:text-secondary-text",ba[a],t?va[a]:"",e),role:"list",children:n.map(((e,t)=>u(fa,{isDotted:l,size:a,children:e},String(t))))}):null)),Na=g((({additionalDescription:e,align:t="text-center",button:l={},className:n="",description:a,headlineSmallVersion:i="H6",href:r,icon:s,isDotted:o=!0,isFullWidth:c=!0,items:d=[],target:m,title:h,version:u="primary",...g})=>p(C,{className:w("h-full flex flex-col justify-between min-w-[260px]","box-border border-solid border border-gray",t,n),defaultPadding:"p-0",version:u,...g,children:[p(aa,{className:"p-s",href:r,target:m,children:[wa(s),ka(i,h),Ca(a,h),Ia(d,o,u),Sa(e)]}),Gt([l],{className:w("p-s pt-0",c?"":"self-center min-w-[158px]"),isVertical:c})]}))),wa=e=>p("div",{className:"flex justify-center",children:[e?.src?u(Rt,{className:"mb-5",image:e}):null,e?.icon?u(Rt,{className:"w-8 h-8 min-w-8 mb-5",image:e}):null]}),ka=(e,t)=>t?u("div",{children:u(me,{size:Zt[e],children:t})}):null,Ca=(e,t)=>e?u("div",{className:t?"mt-2":"",children:u(de,{size:"text-l",children:e})}):null,Sa=e=>e?u("div",{className:"mt-auto",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text group-data-secondary:text-white/80",children:e})}):null,Ia=(e,t,l="primary")=>e?.length?u(ya,{className:w("max-w-[308px] mt-2 text-s","primary"===l?"!text-secondary-text":""),items:e.filter((e=>e?.text)).map((e=>e.text)),isDotted:t}):null,Ta=g((({className:e="",title:t,icon:l,list:n=[],href:a,target:i,...r})=>u(C,{className:w("border border-gray",e),defaultPadding:"p-lg sm:p-0",...r,children:p(aa,{className:"sm:flex sm:items-center",href:a,target:i,children:[u("div",{className:"min-w-[200px] flex justify-center",children:l?.src||l?.icon?u(Rt,{image:l}):null}),p("div",{className:"sm:px-3 py-xl",children:[t?u(I,{className:"mb-2 sm:mb-3.5",headingType:"h6",title:t}):null,n.length?u("div",{className:"flex flex-col gap-2 sm:gap-3",children:n?.map(Ba)}):null]})]})}))),Ba=(e,t)=>p("div",{className:"flex flex-row-reverse justify-between gap-y-1 sm:flex-col",children:[e.title?u(me,{size:"text-l",font:"font-normal",children:e.title}):null,e.description?u(de,{size:"text-l",font:"font-light",color:"text-secondary-text",children:e.description}):null]},String(t)),Ra={default:"w-14 h-14",small:"w-12 h-12"},Pa=(e,t)=>e?"":w("group/media flex items-center justify-center box-border",Ra[t]),Ma=[{origins:["t.me","telegram.org"],iconMapped:{icon:"TelegramIcon"},label:"Телеграм"},{origins:["vk.com"],iconMapped:{icon:"VKIcon"},label:"ВКонтакте"},{origins:["ok.ru"],iconMapped:{icon:"OkIcon"},label:"Одноклассники"},{origins:["apps.apple.com"],iconMapped:{icon:"AppleIcon"},label:"App Store"},{origins:["play.google.com"],iconMapped:{icon:"PlayMarketIcon"},label:"Google Play"},{origins:["youtube.com"],iconMapped:{icon:"YoutubeIcon"},label:"Youtube"}],_a=g((({buttonSize:e="default",rounded:t=!1,icon:l,...n})=>{const{href:a,version:i,text:r=""}=n,{iconMapped:s,label:o}=Ma.find((({origins:e})=>e.some((e=>a?.includes(e)))))||{},c=$a(l)??s;return u(se,{className:w(t?"rounded-full":"rounded-md","border border-solid hover:border-transparent","group-data-primary:border-main-divider","hover:bg-primary-main hover:text-black","group-data-secondary:bg-white border-main-divider group-data-secondary:hover:bg-secondary-hover","group-data-gray:border-green",Pa(r,e)),"aria-label":o,rel:"noopener noreferrer",target:"_blank",text:r,version:i,...n,children:c&&!r?u(Rt,{image:c,imageClassName:"group-hover/media:text-white",width:"24",height:"24"}):null})})),$a=e=>e?.src||e?.icon?e:void 0,Va=g((({className:e="",media:t,children:l,buttonSize:n})=>p("div",{className:"font-sans",children:[u("div",{className:`flex gap-1 ${e}`,children:t?.map(((e,t)=>u(_a,{buttonSize:n,...e},String(t))))}),u(me,{size:"text-s-light",color:"text-secondary-text",children:l})]}))),ja=g((({className:e="",description:t,href:l,icon:n,items:a=[],socialMedia:i=[],target:r,title:s,align:o="text-left",version:c="primary",...d})=>u(C,{className:w("relative min-w-[524px] min-h-[218px] h-full box-border group-data-gray:bg-main-divider/50","border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider",e),defaultPadding:"p-s",version:c,...d,children:p(aa,{href:l,target:r,children:[u(Qt,{className:"mb-4",title:s,description:t,headlineVersion:"S",isPadding:!1,align:o}),p("div",{className:"w-1/2 h-full flex flex-col flex-1 justify-end",children:[a.length?u(ya,{items:a,listItemSize:"S"}):null,i.length?u(Va,{className:"pt-10",media:i}):null]}),za(n)]})}))),za=e=>p("div",{className:"absolute bottom-0 right-0",children:[e?.icon?u(Rt,{image:e}):null,e?.src?u(Rt,{image:e}):null]}),Da=g((e=>{const{__html:t="",richVersion:l=""}=e;return u("div",{className:w(l,"md-container"),dangerouslySetInnerHTML:{__html:t}})})),La=g((({className:e="",__html:t,richVersion:l="striped",...n})=>u(C,{className:w("border border-gray h-full min-w-96",e),...n,children:u(Da,{__html:t,richVersion:l})}))),Aa=g((({className:e="",isFoldButtonOnTop:t=!1,unfoldedByDefault:l=!1,renderFoldableSection:a,renderFoldButton:r})=>{const[s,o]=n(l),c=i((()=>{o((e=>!e))}),[]),d=a({isUnfolded:s,onToggle:c}),m=r?r({isUnfolded:s,onToggle:c}):null;return p("div",t?{className:e,children:[m,d]}:{className:e,children:[d,m]})})),Oa=g((({className:e="",isUnfolded:t,children:l})=>{const n=s(null);return a((()=>{n.current&&(n.current.style.maxHeight=t?`${n.current.scrollHeight}px`:"")}),[t,l?.length]),u("div",{ref:n,className:`transition-max-h duration-300 overflow-hidden ${n.current||!t?"max-h-0":""} ${e}`,children:l})})),Ea=(e=!1)=>e?"p-8 mt-8 pt-20":"p-8 mt-20",Fa=(e,t)=>{const{title:l,description:n,buttons:a}=e;return p("div",{className:"py-5 border-b border-main-divider",children:[l?u("div",{className:"opacity-80",children:u(me,{size:"text-m",color:"text-secondary-text",children:l})}):null,n?u("div",{className:"mt-1",children:u(me,{size:"text-h6",color:"text-primary-text",children:n})}):null,a?.length?u("div",{className:"text-primary-main",children:Gt(a)}):null]},String(t))},Ua=g((({className:e="",title:t,icon:l,isHighlighting:n=!1,button:a,cardCells:i=[],...r})=>{const s=i.map(Fa),o=s.slice(0,1),c=s.slice(1);return p(C,{className:w("relative border border-gray flex flex-col",e),defaultPadding:Ea(n),...r,children:[n?Wa():null,Ha(l),t?u(I,{className:"text-center pt-2",headingType:"h5",title:t}):null,a?u(se,{className:"w-full mt-4",...a}):null,i.length?u(Aa,{renderFoldableSection:({isUnfolded:e})=>p("div",{children:[o,u(Oa,{isUnfolded:e,children:c})]}),renderFoldButton:i.length>1?Xa:null}):null]})})),Ha=e=>u("div",{className:"w-[267px] min-w-[267px] self-center",children:e?.src||e?.icon?u(Rt,{image:e}):null}),Xa=({isUnfolded:e,onToggle:t})=>p("button",{className:"w-full cursor-pointer text-primary-main pt-5 flex justify-between items-center",onClick:t,children:[u("div",{children:e?"Скрыть":"Подробнее о тарифе"}),u(je,{className:"text-primary-text",name:e?"ArrowUpIcon":"ArrowDownIcon",width:"16",height:"16"})]}),Wa=()=>p("div",{className:"absolute -top-7 -right-4 h-[60px] w-[60px] bg-white flex flex-col items-center justify-center rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]",children:[u(je,{iconVersion:"black",name:"HeartIcon",width:"23",height:"22"}),u(de,{size:"text-s",font:"font-normal",align:"text-center",color:"text-primary-text",children:"ХИТ"})]}),Ka="bg-gradient-to-r from-main-gradient-start to-main-gradient-end",Ga="border-gray border-solid border",Ja="border-main-divider border border-t-0 border-x-0",Ya="w-[200px] mr-6",qa=g((({icon:e,image:t,title:l,link:n})=>p("div",{className:`w-80 box-border flex flex-col items-center rounded-t-md border-b-0 px-7 pt-7 pb-[46px] ${Ga} ${Ka}`,role:"columnheader",children:[e&&!t?.src&&u(Rt,{className:"h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4",image:e,width:"63",height:"63"}),t?.src&&u(Rt,{className:"mb-[18px]",image:t}),l?u(I,{headingType:"h4",as:"h3",className:"text-center text-white",title:l}):null,n?.text&&u("div",{className:"mt-auto w-full",children:u(se,{href:n.href,target:n.target,className:"mt-4 w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active",children:u("div",{className:"text-xs-light font-medium py-[11px]",children:n.text})})})]}))),Za={comparison:"flex gap-4 duration-1000",tariff:"flex flex-grow duration-1000"},Qa=g((({children:e,activeIndex:t,columnWidth:l,version:n="comparison"})=>u("div",{className:"flex flex-1 overflow-hidden",children:u("div",{className:Za[n],style:{transform:`translateX(-${t*l}px)`},children:e})}))),ei=g((({children:e})=>u("div",{className:"self-start flex flex-col",role:"row",children:u("div",{className:"flex",children:e})}))),ti=g((({colHeaders:e,activeIndex:t})=>p(ei,{children:[u("div",{className:Ya,role:"columnheader"}),u(Qa,{activeIndex:t,columnWidth:336,children:e.map(((e,t)=>u(qa,{...e},String(t))))})]}))),li=g((({cell:e,isFirstRow:t,isLastRow:l,isFillGradient:n})=>u("div",{className:`w-80 box-border flex flex-col ${Ga} ${l?"border-t-0 rounded-b-md":"border-y-0"} ${n?Ka:""}`,role:"cell",children:u("div",{className:`mx-7 h-full ${Ja} ${n&&t?"border-t":""} ${l?"border-b-0":"border-solid"}`,children:e.map(((e,t)=>ii(e,t,n)))})}))),ni=(e=!1)=>"text-xl m-0 "+(e?"text-white":""),ai=(e=!1)=>"text-s opacity-80 "+(e?"text-white":"text-secondary-text"),ii=({label:e,description:t},l,n)=>p("div",{className:"first:pt-7 pt-6 last:pb-7",children:[e?u("h4",{className:ni(n),children:e}):null,t?u("div",{className:ai(n),children:t}):null]},String(l)),ri=(e=!1)=>`text-s py-7 ${Ja} w-[200px] mr-6 ${e?"border-b-0":"border-solid"}`,si=g((({row:{header:e,data:t},activeIndex:l,isColoredFirstColumn:n,isFirstRow:a,isLastRow:i})=>p(ei,{children:[e?.title?u("div",{className:ri(i),children:e.title}):null,t?.length?u(Qa,{activeIndex:l,columnWidth:336,children:t.map(((e,t)=>u(li,{cell:e,isFirstRow:a,isLastRow:i,isFillGradient:n&&0===t},String(t))))}):null]}))),oi=g((({rowData:e,isColoredFirstColumn:t,activeIndex:l,controls:n})=>{const{isScrollAvailable:a}=n;return p("div",{className:"relative",children:[e.map(((e,n,{length:a})=>u(si,{row:e,isFirstRow:0===n,isLastRow:n+1===a,activeIndex:l,isColoredFirstColumn:t},String(n)))),a?bl({...n,btnClass:["top-[108px]","top-[44px]"],className:"right-7",isDisabled:!0}):null]})})),ci=g((({columns:e=[],rowHeaders:t,isShowAllRow:l,visibleRowLength:n,isColoredFirstColumn:a})=>{const i=e?.map((({header:e})=>e||{})),r=e?.map((({data:e})=>e))||[],s=t?.map(((e,t)=>({header:e,data:r.map((e=>e?.[t]||[{}]))}))).slice(0,l?t.length:n),[o,c]=pl({itemCount:e.length,visibleItemCount:3}),{isScrollAvailable:d}=c;return p("div",{children:[p("div",{role:"table",children:[i?.length?u(ti,{colHeaders:i,activeIndex:o}):null,s?.length?u(oi,{rowData:s,isColoredFirstColumn:a,activeIndex:o,controls:c}):null]}),d?u("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"}):null]})})),di=g((({className:e="",title:t,rowHeaders:l,columns:a,visibleRowLength:r=0,isColoredFirstColumn:s=!1,...o})=>{const[c,d]=n(!r),m=i((()=>d((e=>!e))),[]);return p(C,{className:w("overflow-hidden relative",e),defaultPadding:"p-default",...o,children:[u(I,{headingType:"h2",className:"max-w-[47rem] text-center mb-9 mx-auto",title:t}),u(ci,{columns:a,rowHeaders:l,isShowAllRow:c,isColoredFirstColumn:s,visibleRowLength:r}),r?mi({isShowAllRow:c,onClick:m}):null]})})),mi=({isShowAllRow:e,onClick:t})=>u("div",{className:"pr-12",children:p("div",{className:"flex w-full",children:[u("div",{className:Ya}),u("button",{onClick:t,className:"mt-5 flex-1 border-gray border-solid border text-primary-text bg-white hover:border-primary-main hover:text-primary-main",children:u("div",{className:"font-sans text-xs-light font-medium py-3",children:e?"Скрыть":"Показать все параметры"})})]})}),hi=g((({className:e,contacts:t,info:l,version:n="secondary",...a})=>p(C,{className:w("flex",e),defaultPadding:"p-default",version:n,...a,children:[l?.length?ui(l):null,t?.length?ui(t):null]}))),ui=e=>u("div",{className:"flex grow basis-0",children:e.map(((e,t)=>pi({column:e,index:t})))}),pi=({column:e,index:t})=>e?u("div",{className:"flex flex-col grow basis-0 pr-11 last:pr-0",children:e.map((({title:e="",description:t,additionalDescription:l,button:n},a)=>p("div",{className:"mt-6 first:mt-0",children:[u(Qt,{className:"!p-0",title:e,description:t,headlineVersion:"XS",align:"text-left"}),l?u("div",{className:"mt-1.5 opacity-80",children:u(de,{size:"text-m",font:"font-light",children:l})}):null,n?.href?u(se,{className:"mt-6",...n}):null]},String(a))))},`col-${String(t)}`):null,gi=e=>null==e||""===e||Array.isArray(e)&&0===e.length||"object"==typeof e&&0===Object.keys(e).length,xi=(e,t)=>Object.entries(e).map((([t,l])=>"number"==typeof l?((e,t)=>l=>gi(t[e])||gi(l[e])||fi(t[e])<=fi(l[e]))(t,e):"object"==typeof l&&"min"in l&&"max"in l?((e,t)=>l=>gi(t[e])||gi(l[e])||fi(t[e]?.min)>=fi(l[e]?.min)&&fi(t[e]?.min)<=fi(l[e]?.max))(t,e):Array.isArray(l)?((e,t)=>l=>gi(t[e])||gi(l[e])||t[e]?.some((t=>l[e]?.includes(t))))(t,e):((e,t)=>l=>gi(t[e])||gi(l[e])||t[e]===l[e])(t,e))).every((e=>e(t))),fi=e=>Number(e||0),bi=g((({className:e="",label:t,icon:l,dataTheme:n="",disabled:a=!1,onClick:i})=>p("button",{className:w("flex justify-center w-full px-0 py-4 border border-transparent outline-none focus:border-primary-text",a?"bg-main-divider text-main-disabled hover:bg-main-divider":"bg-primary-main text-white hover:bg-primary-hove",e),onClick:i,disabled:a,"data-theme":n,children:[u("span",{className:"text-h4 pr-3",children:t}),l?u(Rt,{image:{icon:l,iconVersion:"white"},className:"flex-shrink-0 my-auto",width:"20",height:"20"}):null]}))),vi=({isUnfolded:e,onToggle:t})=>u(bi,{icon:["ArrowDownIcon","ArrowUpIcon"][Number(e)],label:["Развернуть","Скрыть"][Number(e)],onClick:t}),yi=["ArrowDownIcon","ArrowUpIcon"],Ni="grid grid-cols-12 gap-1 border-box",wi=g((({label:e="",filtrationState:t={},topItemsCount:l=0,block:n,notFound:a,...i})=>{const r=n?.blocks?.filter((e=>xi(t,e.content||{})))||[],[s,o]=l>0?[r.slice(0,l),r.slice(l)]:[r,[]];return p("div",{children:[u("div",{className:w(r.length?"hidden":"block"),children:a?ki(a):null}),p("div",{className:w(r.length?"":"hidden"),children:[u("div",{className:w("mb-1",Ni),children:Cn(s,{...i.options,parent:n})}),u(Aa,{renderFoldableSection:({isUnfolded:e})=>u(Oa,{className:w(Ni,e?"mb-1":""),isUnfolded:e,children:Cn(o,{...i.options,parent:n})}),renderFoldButton:({isUnfolded:t,onToggle:n})=>u(bi,{className:w(l<1?"hidden":""),disabled:!o?.length,label:e,icon:yi[Number(t)],dataTheme:i.options?.page?.colorPalette,onClick:n})})]})]})}));function ki({title:e,description:t}){return p("div",{className:"bg-white py-20",children:[e?u("div",{className:"mb-2",children:u(de,{align:"text-center",children:u(me,{size:"text-h4",children:e})})}):null,t?u(de,{size:"text-xl",font:"font-light",align:"text-center",children:t}):null]})}const Ci=g((({value:e,onChange:t,items:l=[],multiple:n})=>l.map((l=>u(He,{text:l.title,value:[e].flatMap((e=>e)).includes(l.value),onChange:()=>(l=>{if(t)if(n){const n=e?.includes(l);t(n?(e||[]).filter((e=>e!==l)):[...e||[],l])}else t(e===l?"":l)})(l.value),type:n?"checkbox":"radio"},l.value))))),Si=({field:e,reset:t,filtrationSchema:l,resetButton:n,children:a})=>p("form",{className:"flex justify-between bg-white p-9 mb-1",children:[p("div",{className:"flex gap-11",children:[a,Object.entries(l).map(Ii(e))]}),n?u("div",{children:u(se,{className:"w-72 ml-3",onClick:t,...n})}):null]}),Ii=e=>([t,l])=>{const n=l?.type;return"array"===n?Ti(t,e)(l):null},Ti=(e,t)=>l=>{const n=l?.items?.enum?.map(((e,t)=>({value:e,title:l?.items?.enumNames?.[t]||""})))||[];return p("div",{children:[l?.title?u("div",{className:"mb-4",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:l.title})}):null,u(Ci,{items:n,multiple:!0,...t(e)})]},e)},Bi={sum:500,period:{min:3,max:36}},Ri=g((({className:e,filtrationSchema:t={},resetButton:l,sumInput:n,periodInput:a,...i})=>{const[r,{field:s,reset:o}]=B(Bi),c=a?.max||36,d=p("div",{children:[u(xn,{label:n?.title,min:500,max:1e9,...s("sum",{parse:Number,format:String})}),u(ut,{title:a?.title,items:["От 3 мес","До 3 лет"],min:a?.min||3,max:c,...s("period",{parse:e=>({min:e,max:c}),format:({min:e})=>e})})]});return p(C,{className:w(e),defaultPadding:"p-0",version:"transparent",...i,children:[Si({field:s,reset:o,filtrationSchema:t,resetButton:l,children:d}),u(wi,{filtrationState:r,...i})]})}));Ri.childrenTypes=["ProductTile"],Ri.childSchema=e=>e?.filtrationSchema||{};const Pi=e=>"Image"===e?.errorContentType&&e?.image?u(Rt,{image:e.image}):"Code"===e?.errorContentType&&e.code?u("div",{className:"font-mohave text-title-extra gradient-color-text",children:e.code}):null,Mi=g((({className:e="",title:t,subtitle:l,error:n,button:a,...i})=>{return p(C,{className:w("flex flex-col justify-center items-center",e),defaultPadding:(r=a?.text,r?"py-20 pt-3 pb-1":"mb-16 pb-2 mt-24 pt-3"),version:"transparent",...i,children:[u("div",{className:"flex justify-center py-20",children:Pi(n)}),t?u(I,{headingType:"h1",className:"text-left mb-4",title:t}):null,l?u("div",{className:"font-sans text-xl-light mb-7 max-w-[613px] text-center",children:l}):null,a?.text?u(se,{className:"py-4 px-9",version:a?.version,...a,children:a.text}):null]});var r}));var _i;!function(e){e.EUR="EUR",e.USD="USD",e.GBP="GBP",e.AUD="AUD",e.CNY="CNY",e.RUB="RUB"}(_i||(_i={}));const $i={USD:"DollarIcon",EUR:"EuroIcon",GBP:"DollarIcon",AUD:"DollarIcon",CNY:"DollarIcon",RUB:"RoundRubleIcon"},Vi=e=>e?Di.format(e):"",ji=(e,t)=>p("td",{className:"pt-4 pl-11",children:[u("div",{children:Vi(e)}),u("div",{className:w("font-normal text-sm text-secondary-text",(t||0)>=0?"text-green":"text-red"),children:Vi(t)})]}),zi=(e,t="")=>p("td",{className:"pt-4 pl-11",children:[u("div",{children:Vi(e)}),u("div",{className:"font-normal text-sm text-green",children:t})]}),Di=new Intl.NumberFormat("ru",{style:"currency",currency:_i.RUB}),Li=e=>u("th",{className:"pl-11",children:u(me,{size:"text-m-light",align:"text-left",color:"text-secondary-text",children:e})}),Ai=g((({className:e,currencies:t=[],actuality:l="",officeName:n="",...a})=>{const i=Oi(t,4);return p(C,{className:e,...a,children:[p("div",{className:"flex flex-row flex-grow-0 justify-between mb-8",children:[u(I,{headingType:"h4",title:"Курс обмена валют в "+n,className:"whitespace-pre-wrap text-h4 mb-5"}),u("div",{className:"pl-11",children:u(me,{size:"text-m-light",align:"text-left",color:"text-secondary-text",children:l})})]}),u("div",{className:"flex flex-row pt-4 text-left",children:i.length>0?p("table",{className:w("h-fit w-fit",e),children:[u("thead",{children:p("tr",{children:[u("th",{children:u(me,{size:"text-m-light",align:"text-left",color:"text-secondary-text",children:"Валюта"})}),Li("Купить"),Li("Продать"),Li("Лучшая покупка"),Li("Лучшая продажа")]})}),u("tbody",{children:i.map((e=>(({title:e,buyPrice:t,buyDifference:l,sellPrice:n,sellDifference:a,buyOfficeName:i,sellOfficeName:r})=>p("tr",{className:"pb-1 text-h6",children:[u("td",{className:"pt-4",children:p("div",{className:"flex items-center",children:[e?u(Rt,{image:{icon:$i[e]},width:"24",height:"24"}):null,u("span",{className:"ml-2",children:e})]})}),ji(t,l),ji(n,a),zi(t,i),zi(n,r)]},e))(e)))})]}):null})]})})),Oi=(e,t)=>e.sort(((e,t)=>Number(e.id)-Number(t.id))).slice(0,t);var Ei;!function(e){e.RUB="RUB",e.EUR="EUR",e.USD="USD"}(Ei||(Ei={}));const Fi=new Intl.NumberFormat("ru",{style:"currency",currency:Ei.RUB}),Ui=e=>e?Fi.format(e):"",Hi="text-left text-m-light text-secondary-text",Xi=`${Hi} pl-11`,Wi={USD:"DollarIcon",EUR:"EuroIcon"},Ki=g((({className:e,exchangeCurrencyItems:t})=>p("table",{className:`h-fit w-fit ${e}`,children:[u("thead",{children:p("tr",{children:[u("th",{className:Hi,children:"Валюта"}),u("th",{className:Xi,children:"Купить"}),u("th",{className:Xi,children:"Продать"})]})}),u("tbody",{children:t.map(Gi)})]}))),Gi=e=>{const t=e?.currency?.currency;return p("tr",{className:"pb-1 text-h6",children:[u("td",{className:"pt-4",children:p("div",{className:"flex items-center",children:[t?u(Rt,{image:{icon:Wi[t]},width:"24",height:"24"}):null,u("span",{className:"ml-2",children:t})]})}),u("td",{className:"pt-4 pl-11",children:Ui(e?.saleExchangeRate)}),u("td",{className:"pt-4 pl-11",children:Ui(e?.buyExchangeRate)})]},t)},Ji=g((({className:e="",address:t})=>p("div",{className:`flex ${e}`,children:[u(Rt,{image:{icon:"GpsIcon"},width:"24",height:"24"}),p("div",{className:"ml-3",children:[t?u("p",{className:"text-primary-main m-0 mb-1 text-l",children:t}):null,u("p",{className:"text-secondary-text m-0 text-m",children:"Курс указан для заданного офиса"})]})]}))),Yi=(e,t,l)=>{const n=Number(qi(e))*Math.pow(t,l?-1:1);return Number.isInteger(n)?n:((e,t=2)=>{const l=10**t;return Math.round(parseFloat(String(e))*l)/l})(n)},qi=e=>e.replace(/[^\d.,]/g,"").replace(",","."),Zi=e=>{return(t=[[e=>e.value!==Ei.RUB&&e.oppositeValue!==Ei.RUB,()=>e.handleConvert(e.value,Ei.RUB)],[e=>e.value===Ei.RUB&&e.oppositeValue===Ei.RUB,()=>e.handleConvert(e.value,Ei.USD)],[()=>!0,()=>e.handleConvert(e.value)]],e=>{const[,l]=t.find((([t])=>t(e)))||[];return l})(e)?.();var t};function Qi(e){const{placeholder:t,rates:l,selected:n,value:a,setValue:i,setSelected:r}=e,s=l.map((e=>({key:e?.currency?.currency??"",text:e?.currency?.currency??""}))),o={key:n,text:n};return p("div",{className:"relative flex",children:[u(pe,{className:"shrink-0 text-l w-full appearance-none mr-[-90px]",placeholder:t,type:"text",value:a,onChange:i}),s.length?u(Le,{isBorder:!1,onChange:e=>r(e.key),options:s,value:o}):null]})}const er=g((({className:e="",currencyRatesBuy:t,currencyRatesSell:l,button:a})=>{const[r,s]=n({inputSell:"",inputBuy:"",selectSell:t?.[0]?.currency?.currency||Ei.RUB,selectBuy:l?.[0]?.currency?.currency||Ei.USD}),o=i((e=>s((t=>({...t,...e})))),[]);return p("div",{className:`grid gap-[18px] pt-2 ${e}`,children:[Qi({placeholder:"Хочу продать",rates:l,selected:r.selectSell,setSelected:tr(r,o,l),value:r.inputSell,setValue:e=>nr(o,l)(e,r.selectSell,r.selectBuy)}),Qi({placeholder:"Получу",rates:t,selected:r.selectBuy,setSelected:lr(r,o,t),value:r.inputBuy,setValue:e=>ar(o,t)(e,r.selectBuy,r.selectSell)}),a?.text?u(se,{className:"py-4",version:a?.version,...a,children:a.text}):null]})})),tr=(e,t,l)=>n=>{t({selectSell:n}),Zi({value:n,oppositeValue:e.selectBuy,handleConvert:(n=e.selectSell,a=e.selectBuy)=>{nr(t,l)(e.inputSell,n,a)}})},lr=(e,t,l)=>n=>{t({selectBuy:n}),Zi({value:n,oppositeValue:e.selectSell,handleConvert:(n=e.selectBuy,a=e.selectSell)=>ar(t,l)(e.inputBuy,n,a)})},nr=(e,t)=>(l,n,a)=>{e({inputSell:qi(l),selectBuy:a});const i=t.find((e=>e.currency?.currency===a))?.buyExchangeRate||t.find((e=>e.currency?.currency===n))?.saleExchangeRate;i&&e({inputBuy:String(Yi(l,i,n===Ei.RUB)||"")})},ar=(e,t)=>(l,n,a)=>{e({inputBuy:qi(l),selectSell:a});const i=t.find((e=>e.currency?.currency===a))?.saleExchangeRate||t.find((e=>e.currency?.currency===n))?.buyExchangeRate;i&&e({inputSell:String(Yi(l,i,n===Ei.RUB)||"")})};const ir=async e=>{const t=await rr(),l=t?.code||"000";return{region:t,exchangeRates:await sr(e,l)}},rr=async()=>{try{return await D("/api/v1/region",{method:"GET"})}catch(e){return console.log(e),{}}},sr=async(e,t)=>{try{return await D(e+`?regionCode=${t}`,{method:"GET"})}catch(e){return console.log(e),{}}},or=g((({className:e="",title:t="Курсы обмена валют",button:l,...n})=>{const{exchangeRates:a}=function(){const{data:e}=V("/api/v1/exchangerates",ir);return e||{}}(),i=cr(a?.exchangeRate?.currencies),r=i.filter((e=>e.buyExchangeRate));r.unshift({currency:{currency:Ei.RUB}});const s=i.filter((e=>e.saleExchangeRate));return s.push({currency:{currency:Ei.RUB}}),u(C,{className:w("box-border min-h-80",e),...n,children:u(sa,{className:"h-full",title:u(I,{headingType:"h4",title:t,className:"whitespace-pre-wrap"}),children:p("div",{className:"flex gap-xxl",children:[p("div",{children:[i?u(Ki,{className:"mb-xl",exchangeCurrencyItems:i}):null,u(Ji,{address:a?.address})]}),i.length&&r.length&&s.length?u(er,{className:"grow",currencyRatesBuy:r,currencyRatesSell:s,button:l}):null]})})})})),cr=e=>e?.filter((e=>1===e?.currency?.id||2===e?.currency?.id))||[],dr={};function mr(e,t={}){const{data:l}=V(`/wcms-resources/${e}.json`,D,{fallback:t});return l||dr}const hr={"bg-white":"color",transparent:"white"},ur={"bg-white":"text-primary-main",transparent:"text-white"},pr=(e,t,l)=>u(Rt,t?.src?{image:t,className:ur[e],width:l?.width,height:l?.height,pathPrefix:"/wcms-resources/"}:{image:{icon:t?.icon||"LogoIcon",iconVersion:hr[e]},className:ur[e],width:l?.width,height:l?.height}),gr={"bg-white":"text-primary-text",transparent:"text-white"},xr=(e,t,l)=>u("span",{className:`${gr[t]} ml-2.5 font-medium ${l||""}`,children:e||"Россельхозбанк"}),fr=g((({className:e="",href:t,logo:l,children:n=l?.title,targetBlank:a,bgColor:i="bg-white",showTitle:r=!0})=>p("a",{className:`inline-flex items-center font-sans no-underline ${e}`,href:t||"/",target:a?"_blank":"_self","aria-label":l?.title||"Россельхозбанк",children:[pr(i,l?.image,{width:"40",height:"45"}),r?xr(n||l?.title,i):null]}))),br=g((({className:e,onClick:t})=>u("button",{className:w("flex justify-center items-center w-12 h-12 p-1 bg-transparent border-none",e),onClick:t,title:"Закрыть",children:u(Rt,{image:{icon:"CloseIcon"},width:"24",height:"24"})})));function vr(e){throw new Error(e)}function yr({onOpen:e,onClose:t}={}){a((()=>b.subscribe("dialog",(l=>{switch(l.type){case"open":e&&e(l);break;case"close":t&&t();break;default:vr(l)}}))),[e,t])}function Nr(e,...t){return e.map(((e,l)=>[e,...t.map((e=>e[l]))]))}const wr=e=>t=>{if(e===t)return 1;if(!e||!t)return 0;const{m:l,s1Matches:n,s2Matches:a}=function(e,t){const l=Math.max(0,Math.floor(Math.max(e.length,t.length)/2)-1),n=new Array(e.length),a=new Array(t.length);let i=0;for(let r=0;r<e.length;r++){const s=Math.max(0,r-l),o=Math.min(r+l,t.length-1);for(let l=s;l<=o;l++)n[r]||a[l]||e[r]!==t[l]||(i++,n[r]=!0,a[l]=!0)}return{m:i,s1Matches:n,s2Matches:a}}(e,t);if(0===l)return 0;const i=function(e,t,{s1Matches:l,s2Matches:n}){let a=0;for(let i=0,r=0;i<e.length;i++){if(!l[i])continue;let s=r;for(;s<t.length;s++)if(n[s]){r=s+1;break}e[i]!==t[s]&&a++}return a}(e,t,{s1Matches:n,s2Matches:a}),r=(l/e.length+l/t.length+(l-i/2)/l)/3,s=r>.7?.1*function(e,t){let l=0;for(;e[l]===t[l]&&l<4;)l++;return l}(e,t):0;return r+s*(1-r)};const kr=(e,t)=>(l,n)=>{for(const[a,i]of n)l.set(a,e(l.get(a)||t,i));return l},Cr=(e=[])=>e.reduce(((e,t)=>e+t),0),Sr=e=>e.toLowerCase().split(/[^0-9a-zа-я-]+/).filter((e=>e.length>=3&&!/[0-9a-z]/.test(e))),Ir=e=>t=>e.map((([e,l])=>[wr(t)(e),l])).filter((([e])=>e>=.8)).map((([e,t])=>Br(t,e))).reduce(kr(Math.max,0),new Map),Tr=e=>t=>{return Nr(t,t.map((({title:e})=>e)).map((e=>t=>{const l=Sr(t||"");return l.length?Cr(e.map((e=>Al(l.map(wr(e)))))):0})(e))).sort((n=([,e])=>e,l=(e,t)=>n(e)-n(t),(e,t)=>-l(e,t))).map((([e])=>e));var l,n},Br=(e,t)=>new Map(e.map((e=>[e,t]))),Rr=["/"],Pr=({basePathList:e=Rr,initialQuery:t="",wasOpened:l})=>{const[i,s]=n(t||"");a((()=>{null!=t&&s(t)}),[t]);const o=r((()=>e.map((e=>l?e:null))),[l,e]),{data:c}=V(o,Mr),[d,m]=n(null);return((e,t,l=300)=>{a((()=>{const t=setTimeout(e,l);return()=>{clearTimeout(t)}}),t)})((()=>{c&&m(c.map((e=>t=>{const{corpus:l,dictionary:n}=t||{};if(!(e&&l?.length&&n&&Object.keys(n).length))return[];const a=Sr(e);if(!a.length)return[];const i=Object.entries(n),r=[...a.map(Ir(i)).reduce(kr(((e,t)=>e+t),0),new Map).entries()].filter((([,e])=>e>=.799*a.length)).map((([e])=>l[e]));return Tr(a)(r)})(i)))}),[c,i]),[d,{value:i,onChange:s}]},Mr=async(...e)=>(await Promise.allSettled(e.map((e=>z(H(e,"/","search.index.json")))))).map((e=>"fulfilled"===e.status?e.value:{})),_r=g((({className:e,isOpened:t,head:l,children:n,onClose:i})=>(a((()=>{const e=({key:e})=>{"Escape"===e&&i&&i()};return globalThis.document?.addEventListener("keydown",e),()=>{globalThis.document?.removeEventListener("keydown",e)}}),[i]),t?u("div",{className:w("fixed inset-0 bg-white text-l-light z-50 overflow-x-hidden overflow-y-scroll no-scrollbar",e),role:"dialog",children:p("div",{className:"relative container pb-12 min-h-full",children:[p("div",{className:"sticky bg-white pt-6 top-0",children:[u(br,{className:"absolute top-10 -right-12",onClick:i}),l]}),n]})}):null)));function $r(e,t=!1){const[l,{setTrue:a,setFalse:r}]=_e(t),[o,c]=n({id:e}),d=s(l);d.current||=l;yr({onOpen:i((t=>{t.id===e?(c(t),a()):r()}),[e]),onClose:r});const m=i((()=>{r(),b.fire("dialog",{type:"close"})}),[]);return{...o,isOpened:l,wasOpened:d.current,onClose:m}}const Vr=g((({className:e,topItems:t})=>{const l=Y({isRemote:!0});return u("div",{className:w("flex items-start justify-between",e),children:t?.map(l).map(jr)})})),jr=(e,t)=>{const{text:l,items:n,href:a,target:i,onClick:r}=e;return p("div",{className:"flex flex-col gap-3.5 w-1/4",children:[u("a",{className:"leading-5 text-l text-primary-text hover:text-primary-main no-underline",href:a,target:i||"_self",onClick:r,children:l||`Раздел ${t}`}),n?.map(((e,t)=>u(zr,{...e,basePath:o(a),index:t},String(t))))]},String(t))},zr=g((({text:e,index:t,basePath:l,...n})=>{const a=Y({isRemote:!(!d.BASE_PATH||!l)&&!d.BASE_PATH.startsWith(l),basePath:l}),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-l-light text-secondary-text hover:text-primary-main no-underline","overflow-x-hidden overflow-ellipsis whitespace-nowrap"),href:i,target:r||"_self",onClick:s,children:e||`Раздел ${t}`})})),Dr=g((({className:e,value:t,autoFocus:l,onChange:n,onFocus:a})=>{const r=i((e=>{n&&n(e.target?.value||"")}),[n]);return p("div",{className:w("font-sans relative",e),role:"form",children:[u("div",{className:"absolute h-full flex items-center pl-4 pointer-events-none",children:u(Rt,{image:{icon:"LoupeIcon"},width:"24",height:"24"})}),u("input",{className:w("h-12 pl-12 w-full text-l text-black outline-none box-border","border border-solid rounded-md border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text"),value:t,type:"text",name:"search-bar-input",placeholder:"Поиск по сайту",autoFocus:l,onChange:r,onFocus:a})]})})),Lr="search",Ar=g((({topItems:e})=>{const t=$r(Lr),l=r((()=>e?.map((e=>e.href||"/"))),[e]),[n,i]=Pr({basePathList:l,initialQuery:t.message,wasOpened:t.wasOpened}),s=r((()=>Or(e)(n)),[e,n]);return a((()=>function(e){for(const t of e.filter((({items:e})=>e?.length)))console.group(t.text),console.table(t.items,["text","href"]),console.groupEnd()}(s)),[s]),u(_r,{...t,head:u(Dr,{className:"my-5",autoFocus:!0,...i}),children:u(Vr,{topItems:s})})})),Or=e=>t=>e?.length&&t?.length?Nr(e,t).map((([e,t])=>({...e,items:t?.map((({title:e,uri:t})=>({text:e,href:H("/",t)})))}))):[];const Er=g((({className:e})=>{const[t,l]=n(""),a=i((()=>l("")),[]);yr({onClose:a});const{open:r}=O(Lr),s=i((e=>{l(e),Fr(e)&&r(e)}),[]);return p("div",{className:e,children:[u(Dr,{value:t,onChange:s}),u(br,{className:"absolute top-2 right-3 sm:hidden",onClick:a})]})})),Fr=e=>e&&e.length>=3,Ur=g((({className:e="",items:t,hasButton:l})=>p("div",{className:e,children:[t?.length?t.map(Hr):null,l?u(se,{version:"primary",className:"mb-6 w-full",href:"https://www.rshb.ru/feedback/question/",target:"_blank",ariaLabel:"Обратная связь",text:"Обратная связь"}):null]}))),Hr=(e,t)=>p("div",{className:"mb-6",children:[u("div",{className:"mb-4",children:u(me,{size:"text-l",font:"font-medium",children:e?.title})}),u("div",{children:e.items?.map(Xr)})]},String(t)),Xr=(e,t)=>p("div",{className:"mb-4",children:[u("div",{children:Wr(e.type,e.text)}),u("div",{className:"mt-1 text-s-light text-secondary-text",children:e.description})]},String(t)),Wr=(e,t="")=>{switch(e){case"tel":return u("a",{className:"text-h6 text-primary-text hover:text-primary-main no-underline",href:`tel:${Kr(t)}`,children:t});case"email":return u("a",{className:"text-xl-light text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return u("span",{children:t})}},Kr=e=>e.replaceAll(/\D/g,""),Gr=g((({className:e="",index:t,text:l,...n})=>{const a=Y(),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-secondary-text",e),href:i,target:r,onClick:s,children:l||`Документ ${t}`})})),Jr=g((({className:e="",links:t})=>u("div",{className:e,children:t?.length?u("div",{className:"flex justify-between items-center gap-5 py-5 border-solid border-x-0 border-y border-y-main-divider",children:t.map(((e,t)=>u(Gr,{index:t,className:"text-l-light max-w-[292px]",...e},String(t))))}):null}))),Yr=g((({className:e="",index:t,...l})=>{const n=Y({isRemote:!0}),{href:a,target:i,text:r,onClick:s}=n(l);return u("a",{className:`text-xs-light text-secondary-text visited:text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${e}`,href:a,target:i,onClick:s,children:r||`Документ ${t}`})})),qr=g((({className:e="",links:t})=>p("div",{className:e,children:[u("div",{className:"pt-4 xl:pt-5",children:u(me,{size:"text-xs-light",color:"text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?u("div",{className:"flex justify-start items-start gap-5 pt-4",children:t.map(((e,t)=>u(Yr,{index:t,...e},String(t))))}):null]}))),Zr="w-[204px]",Qr=g((({className:e="",...t})=>{const l=t.options?.page?.fallback,n=mr(d.SITEMAP||"sitemap",l),{documents:a,relatedEnterprises:i,contacts:r,socialMedia:s,mobileApps:o,logo:c}=mr(d.FOOTER||"footer",l);return p(C,{tag:"footer",className:e,...t,children:[p("div",{className:"flex items-stretch gap-[54px] pb-8 xl:gap-8",children:[u(fr,{className:Zr,logo:c}),u(Er,{className:"grow"})]}),p("div",{className:"flex items-stretch gap-[54px] xl:gap-8",children:[p("div",{className:"w-[204px] flex flex-col shrink-0 overflow-hidden",children:[u(Ur,{items:r,hasButton:!0}),u(Va,{media:s,children:"Соцсети"}),u(Va,{className:"mt-6",media:o,children:"Мобильное приложение"})]}),u(Vr,{className:"flex-grow",topItems:n?.topItems})]}),u(Jr,{className:"mt-[98px]",links:i}),u(qr,{links:a})]})})),es=g((({className:e="",title:t,description:l,calendar:n,...a})=>p(C,{className:e,defaultPadding:"p-default",...a,children:[u(Qt,{className:"!p-0 mb-4",title:t,description:l,headlineVersion:"M"}),n?ts(n):null]}))),ts=e=>{const t=100/(e.reduce(((e,t)=>t?.month?.length?e+t.month.length:e),0)||1),l=e.filter((e=>e?.month?.length)).map((e=>({...e,flexBasis:`${e?.month?.length?e.month.length*t:""}%`})));return p("div",{className:"w-full flex flex-col justify-center mt-13",children:[u("div",{className:"flex w-full mb-3 text-h6 text-center",children:l.map((e=>ls(e,t)))}),u("div",{className:"flex w-full",children:l.map(((e,t)=>p("div",{className:"pr-[11px] mr-3 border-r border-main-divider last:border-r-0 last:pr-0 last:mr-0",style:{flexBasis:e.flexBasis},children:[u("div",{className:"flex",children:ns(e)}),p("div",{className:"text-s-light text-primary-text mt-3",children:[u("span",{children:e.text})," ",u("span",{className:"text-primary-main",children:e.greenText})]})]},`monthItem-${t}`)))})]})},ls=(e,t)=>e.month?.map(((e,l)=>u("div",{style:{flexBasis:`${t}%`},children:e.text},`monthName-${l}`))),ns=e=>e.month?.map((e=>e.image?.src?u("div",{className:"h-[207px] border-r pr-3 mr-3 border-main-divider last:border-r-0 last:pr-0 last:mr-0",children:u(Rt,{image:e.image,className:"flex"})},`monthImage-${e.image.src}`):null)),as=864e5;function is(e,t,l=globalThis?.localStorage){const n=i((async(...n)=>{const a=`async:${e}`,i=function(e){const{data:t=null,timestamp:l=null}=e?JSON.parse(e):{};return t&&Date.now()-l<as?t:void 0}(l.getItem(a));if(i)return i;const r=await t(...n);return l.setItem(a,JSON.stringify({data:r,timestamp:Date.now()})),r}),[e,t]);return V(e,n)}const rs=()=>{const e=globalThis.localStorage?.getItem("location");try{return e?JSON.parse(e):null}catch(e){return null}},ss=e=>({href:t})=>U(E(t)?e.href:e.pathname).startsWith(U(t));const os=g((({className:e,searchTerm:t,onSearch:l})=>p("form",{className:`font-sans relative ${e}`,children:[u("div",{className:"absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none",children:t?null:u("label",{htmlFor:"search-bar-input",className:"text-secondary-text ",children:"Поиск по филиалам"})}),u("input",{id:"search-bar-input",className:"h-12 pl-4 w-full peer text-l text-black border border-solid rounded-md box-border\n outline-none border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text",value:t,onChange:e=>l(e.target.value.toLowerCase()),type:"text",name:"location-search-bar-input"})]}))),cs="location",ds=g((({currentLocation:e,onChangeLocation:t,foreignOffices:l})=>{const a=$r(cs),[r,s]=n(""),o=hs(function(){const{data:e}=V("/api/v1/regions",D);return e||[]}()).sort(((e,t)=>e.name.localeCompare(t.name))),c=((e,t)=>{const l=new Map;for(const n of e){const e=t(n),a=l.get(e)||[];l.set(e,[...a,n])}return l})(o,ms),d=i((e=>{a.onClose&&a.onClose(),t&&t(e)}),[a.onClose,t]);return p(_r,{...a,head:p("div",{children:[u(us,{currentLocation:e,onChangeLocation:d}),u(os,{onSearch:s,searchTerm:r,className:"mb-7"})]}),children:[r&&r.length>=3?u("div",{children:o.filter((({name:e})=>e&&wr(e.toLowerCase())(r.toLowerCase())>=.8)).map(gs(d))}):u("div",{className:"columns-5",children:Array.from(c.entries()).map(ps(d))}),u(xs,{foreignOffices:l})]})})),ms=e=>e.name?.charAt(0)||"",hs=e=>e.map((e=>({...e,name:e.name?.replace(/республика|область|край'/gi,"").trim()||""}))),us=g((({currentLocation:e,onChangeLocation:t})=>e?p("div",{className:"mb-4",children:[u(me,{size:"text-l",font:"font-light",children:"Сейчас выбран: "}),u("button",{className:"cursor-pointer",onClick:()=>{t&&t(e)},children:u(me,{color:"text-primary-main",children:e.name})})]}):null)),ps=e=>([t,l])=>p("div",{className:"break-inside-avoid mb-7 w-[224px]",children:[u("div",{className:"mb-2.5",children:u(me,{size:"text-h6",children:t})}),l.map(gs(e))]},t),gs=e=>t=>u("div",{className:"mb-1",children:u("button",{className:"cursor-pointer hover:text-primary-hover",onClick:()=>{e&&e(t)},children:t.name||""})},t.id),xs=g((({foreignOffices:e})=>e?.length?p("div",{className:"border-t border-main-divider mt-7 pt-7",children:[u("div",{className:"mb-4",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:"Представительства за рубежом:"})}),u("div",{className:"flex gap-10",children:e.map(((e,t)=>u(fs,{...e},String(t))))})]}):null)),fs=g((({icon:e,...t})=>{const l=Y(),{text:n,target:a,href:i,onClick:r}=l(t);return p("div",{className:"flex gap-x-3",children:[e?u(Rt,{pathPrefix:"/wcms-resources/",image:e}):null,n?u("a",{className:"hover:text-primary-hover",href:i,target:a,onClick:r,children:n}):null]})})),bs=g((({className:e="",active:t,flat:l,children:n,...a})=>{const i=Y({isRemote:!0}),{href:r,target:s,text:o,onClick:c}=i(a);return u("a",{className:w(vs(t,l),e),href:r,target:s,onClick:c,rel:"noopener noreferrer","aria-label":o,children:u("span",{className:ys(t,l),children:o||n})})})),vs=(e=!1,t=!1)=>w("inline-block border border-solid bg-transparent text-center no-underline",e?"rounded-md border-primary-main group-data-transparent:border-white":"border-transparent",t?"":"px-4 py-2"),ys=(e=!1,t=!1)=>w("font-sans text-s-light",e?"text-primary-main":w(t?"text-primary-text":"text-secondary-text","hover:text-primary-main"),"group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),Ns={default:"w-6 h-6",large:"w-12 h-12"},ws=g((({className:e,isRounded:t,buttonSize:l="default",isGrayBg:n=!1,disabled:a,ariaLabel:i,image:r,onClick:s})=>u("button",{className:w("group/btn border-0 flex shrink-0 items-center",n?"p-3 rounded-full":"p-0 bg-inherit",n&&!t?"bg-main-divider":"",t?"w-8 h-8 text-secondary-light hover:text-secondary-hove":`${Ns[l]} text-primary-text hover:text-primary-main`,"group-data-transparent:text-white",e),type:"button",disabled:a,"aria-label":i,onClick:s,children:u(Rt,{image:r,className:w("h-full",t?"bg-main-divider/20 rounded-full":""),imageClassName:"group-hover/btn:text-primary-hover group-hover/btn:invert-0"})}))),ks=g((({className:e,version:t,locationName:l,officesLink:n})=>{const a="transparent"===t?"white":"black",{open:r}=O(cs),s=i((()=>r()),[]),{open:o}=O(Lr),c=i((()=>o()),[]);return p("div",{className:w("flex items-center gap-5",e),children:[u(bs,{flat:!0,href:"#",text:l,onClick:s}),n?u(bs,{flat:!0,href:n,text:"Офисы и банкоматы"}):null,u(ws,{image:{icon:"LoupeIcon",iconVersion:a},ariaLabel:"Поиск",onClick:c})]})})),Cs=g((({className:e="",items:t,activeItem:l})=>{const a=Y(),[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),c=$e(i((()=>s(!1)),[]));return p("div",{className:w(r?"bg-white rounded-md shadow-blue-gray":"",e),ref:c,children:[u("button",{className:"group/btn flex justify-between items-center h-6","aria-label":""+(r?"Скрыть другие разделы":"Показать другие разделы"),onClick:o,children:Array(3).fill(null).map(((e,t)=>u("div",{className:"w-[3px] h-[3px] rounded mr-1 bg-primary-text group-hover/btn:bg-primary-hover group-data-transparent:bg-white"},String(t))))}),u("div",{className:w("absolute flex flex-col rounded-md bg-white p-6 pb-2",r?"":"hidden"),"aria-hidden":!r,children:t?.map(((e,t)=>{const{text:n,...i}=e;return u("a",{className:w("text-l-light pb-4 hover:text-primary-main",e===l?"text-primary-main":""),...a(i),children:n},e.href||String(t))}))})]})})),Ss=g((({className:e="",active:t,dataItemName:l,children:n,...a})=>{const i=Y(),{href:r,target:s,text:o,onClick:c}=i(a);return p("a",{className:w("relative inline-block bg-transparent text-center no-underline",e),href:r,target:s,"data-item-name":l,onClick:c,children:[u("span",{className:Is(t),children:o||n}),t?u("div",{className:"absolute left-0 right-0 -bottom-3 h-0.5 bg-primary-main group-data-transparent:bg-transparent"}):null]})})),Is=(e=!1)=>w("font-sans text-l-light",e?"text-primary-main":"text-primary-text hover:text-primary-main","group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),Ts=g((({observerOptions:e,onVisibilityChange:t,children:l,className:n,...a})=>{const r=v(i((e=>{if(!e.length||!t)return;const l=e[e.length-1];t(l.isIntersecting)}),[t]),e);return u("span",{ref:r,className:n,children:u(Ss,{...a,children:l})})})),Bs=e=>globalThis[e];function Rs(e,t){const[l,r]=n(),s=i((()=>r(Bs(e))),[e]);return a((()=>{const l=document.getElementById(t);if(!l){const e=document.createElement("script");return e.src=t,e.async=!0,e.id=t,e.addEventListener("load",s),document.head.appendChild(e),()=>{document.head.removeChild(e),r(void 0)}}if(!Bs(e))return l.addEventListener("load",s),()=>{l.removeEventListener("load",s)};s()}),[e,t]),l}const Ps={personal:"//chat.mes.rshb.ru/assets/js/webchat_rshb",business:""},Ms=g((e=>{const[t,{setTrue:l}]=_e();return t?u(_s,{...e}):$s({...e,onClick:l})})),_s=g((({chat:e="personal",...t})=>((e=>{a((()=>globalThis.localStorage?.setItem("webchat-keep-open",String(Date.now()))),[]),Rs("chatbot",Ps[e])})(e),$s(t)))),$s=({className:e,iconVersion:t,onClick:l})=>u(ws,{className:w("text-page__btn-chat",e),image:{icon:"HeadphonesIcon",iconVersion:t},ariaLabel:"Чат",onClick:l,buttonSize:"large",isGrayBg:!0}),Vs={default:"px-5 bg-main-divider rounded hover:text-primary-main",transparent:"text-white hover:text-primary-hover"},js=g((({version:e,internetBankUrl:t})=>t?u(se,{href:t,ariaLabel:"Интернет-банк",target:"_blank",className:w("py-3 ml-3 text-l font-light whitespace-nowrap hover:text-primary-main",Vs["transparent"===e?"transparent":"default"]),children:"Интернет-банк"}):null)),zs=g((({subItems:e=[],version:t,internetBankUrl:l})=>{const a="transparent"===t?"white":"black",i=(e=>(t=[])=>{const l=t?.filter(ss(e));return l?.length?Ll((e=>e.href?.length||0))(l):void 0})(J())(e),[o,c]=n(e.length),m=e.slice(o),h=s(null),g={rootRef:h},x=r((()=>e.map(((e,t)=>e=>{c(e?Ds(t):Ls(t))}))),[e]);return p("nav",{className:"relative mt-3 flex items-center justify-between",children:[u("div",{ref:h,className:"overflow-hidden whitespace-nowrap pb-3 mt-2",children:e.map(((e,t)=>u(Ts,{className:w("ml-8 first:ml-0",o-1<t?"invisible":""),active:e===i,observerOptions:g,onVisibilityChange:x[t],...e},String(t))))}),m.length?u(Cs,{className:"relative w-auto z-40",items:m,activeItem:i}):null,d.CHAT_BOT?u(Ms,{className:"ml-9",iconVersion:a,chat:d.CHAT_BOT}):null,u(js,{version:t,internetBankUrl:l})]})})),Ds=e=>t=>Math.max(t,e+1),Ls=e=>t=>Math.min(t,e),As={"bg-white":"primary",transparent:"transparent"},Os=g((({bgColor:e="bg-white",className:t,showSubMenu:l=!0,version:r=As[e],...s})=>{const o=J(),{topItems:c,logo:m,defaultLocation:h,foreignOffices:g,officesLink:x,internetBankUrl:f}=mr(d.SITEMAP||"sitemap",s.options?.page?.fallback),b=c?.find((e=>ss(d.BASE_PATH?{pathname:d.BASE_PATH}:e))(o)),[v,y]=function(e="Москва"){const t=rs(),[l,r]=n(t?.region??{name:e}),{data:s}=is("/api/v1/region",D);return a((()=>{r(t?.region&&t?.manual?t.region:s||{name:e})}),[s]),[l,i((e=>{globalThis.localStorage?.setItem("location",JSON.stringify({manual:!0,region:e})),r(e)}),[])]}(h);return p(C,{tag:"header",className:w("pt-6 px-20",l&&b?.items?.length?"pb-4":"pb-5",t),defaultPadding:"",version:r,...s,children:[p("div",{className:"container",children:[p("div",{className:"flex items-center",children:[u(fr,{className:"mr-8",bgColor:e,logo:m}),c?.map(((e,t)=>u(bs,{active:e===b,...e},String(t)))),u(ks,{version:r,className:"ml-auto",locationName:v.name,officesLink:x})]}),u("div",{className:w("mt-6 h-px bg-main-divider","transparent"===r?"opacity-30":"")}),l&&b?.items?.length?u(zs,{subItems:b.items,version:r,internetBankUrl:f}):null]}),u(Ar,{topItems:c}),u(ds,{currentLocation:v,foreignOffices:g,onChangeLocation:y})]})})),Es={XXL:"gap-12",XL:"gap-10",L:"gap-8",M:"gap-4",S:"gap-2",XS:"gap-1","":""},Fs=g((({className:e="",gap:t="XS",isPadding:l=!1,version:n="transparent",isTheme:a=!1,...i})=>u(C,{className:w("relative","grid grid-cols-12",Es[t],e),defaultPadding:l?"p-default":"",version:n,isTheme:a,...i,children:Sn(i)})));Fs.childrenTypes={exclude:["HorizontalLayout"]};const Us=g((e=>{const{className:t,image:l,...n}=e;return u(C,{className:t,defaultPadding:"p-0",...n,children:u(Rt,{image:l})})})),Hs=g((({className:e="",cards:t=[],button:l})=>{const[a,r]=n(0),s=i((e=>r(e)),[]),o=t.length,[c,d]=pl({itemCount:o,visibleItemCount:2}),{canDec:m,canInc:h}=d,g=t[c]?.href;return p("section",{role:"listitem",className:`min-w-full text-center ${e}`,children:[p("div",{className:"relative overflow-hidden",children:[o?Xs({activeIndex:c,cards:t,selectedCardIndex:a,onClick:s}):null,bl({...d,btnClass:["left-12","right-12"],className:"top-[62px]"}),m?u("div",{className:"absolute top-0 left-0 h-full w-[136px] bg-opacity-from-white"}):null,h?u("div",{className:"absolute top-0 right-0 h-full w-[136px] bg-opacity-to-white"}):null]}),u(se,{className:"w-60 text-center",version:"primary",...l,href:g})]})}));function Xs({activeIndex:e,cards:t,selectedCardIndex:l,onClick:n}){const a=460*e,i=t.length>2?"justify-start":"justify-center";return u("div",{style:{transform:`translateX(-${a}px)`},className:"duration-1000 px-12",children:u("div",{className:`w-full flex flex-nowrap gap-3.5 pb-12 ${i}`,children:t.map(((e,t)=>function({slide:e,i:t,isActive:l,onClick:n}){return p("button",{type:"button",onClick:n,className:"p-[30px] min-w-[460px] flex items-center bg-white border-solid border relative "+(l?"shadow-dark-blue border-primary-main":"ease-in duration-300 border-gray"),children:[e?.icon?u(Rt,{className:"p-5 rounded-full bg-secondary-light mr-[30px]",image:e.icon,width:"108",height:"108"}):null,p("div",{className:"flex gap-3.5",children:[e?.sum?Ws("страховая сумма",e.sum):null,e?.fee?Ws("страховой взнос",e.fee):null]}),Ks(l)]},String(t))}({slide:e,i:t,isActive:Boolean(t===l),onClick:()=>n(t)})))})})}function Ws(e,t){return p("div",{className:"flex flex-col text-left whitespace-pre",children:[p("span",{className:"text-h6",children:[ot(2)(t)," ₽"]}),u("span",{className:"text-secondary-text text-l mt-1",children:e})]})}function Ks(e){return e?u(Rt,{className:"h-6 w-6 min-w-6 min-h-6 absolute right-4 top-4",image:{icon:"DoneIcon"},width:"24",height:"24"}):null}const Gs=g((({className:e="",title:t,insuranceTabs:l=[],button:a,...r})=>{const[s,o]=n(0),c=i((e=>o(e)),[]);return p(C,{className:w("box-border overflow-hidden relative px-0",e),defaultPadding:"p-default",...r,children:[t?u(I,{className:"text-center mb-8",title:t,headingType:"h3"}):null,l?.length>1?u("div",{className:"p-1.5 bg-secondary-light w-fit mx-auto mb-7 rounded-md",children:l.map(((e,t)=>function({title:e,i:t,isActive:l,onClick:n}){return u("button",{type:"button",onClick:n,"aria-label":e,className:"box-border px-4 py-3 text-m-light "+(l?"bg-primary-main text-white rounded-md":"text-secondary-text"),children:e},String(t))}({title:e?.title,i:t,isActive:Boolean(t===s),onClick:()=>c(t)})))}):null,u("div",{className:"flex",style:{transform:`translateX(-${s}00%)`},role:"list",children:Js({insuranceTabs:l,button:a})})]})})),Js=({insuranceTabs:e,button:t})=>{const l=e?.map((e=>e.cards));return l?.length?l.map(((e,l)=>u(Hs,{button:t,cards:e},String(l)))):null};const Ys=e=>t=>t.reduce(((t,l,n)=>t.length?t.concat({...e,key:`sep-${n}`},l):[l]),[]),qs={yellow:"bg-yellow",green:"bg-green","green-light":"bg-green-light","green-dark":"bg-green-dark"},Zs={XS:"h-[40px]",S:"h-[68px]",M:"h-[102px]",L:"h-[136px]",XL:"h-[204px]"},Qs=g((e=>{const{className:t="",items:l,isDotted:n,investmentZeroColumn:a,investmentColumns:i,...r}=e,s=i?[...i]:[];return a&&s.unshift(a),u(C,{className:t,...r,children:p("div",{className:"container text-m-light",children:[s?.length?p("div",{children:[p("div",{className:"flex items-end relative pl-9 pr-5 text-white",children:[Ys(u("div",{className:"w-px h-4 bg-gray"}))(s.map(eo)),u("div",{className:"absolute right-[30px] w-px h-4 bg-gray"})]}),u("div",{className:"border-t border-gray -mt-2 ml-9 mr-8"}),u("div",{className:"flex justify-between text-primary-text mt-3 -mx-10",children:s.map(no)})]}):null,l?.length?u(ya,{className:"mt-9 max-w-[657px]",items:l,isDotted:n,listItemSize:"M"}):null]})})})),eo=(e,t,l)=>{const n=1===t,a=t===l.length-1;return u("div",{className:`${to(n,a,e.cells)}`,children:e.cells?.length?u("div",{className:"w-full "+(a?"border-4 border-green-more-dark p-1.5 min-w-[290px]":""),children:e.cells.reverse().map(lo)}):null},`column_${t}`)},to=(e,t,l=[])=>[l.length?"flex-1":"flex-0",!l.length||e||t?"":"pl-2.5",l.length&&!t?"pr-2.5 pb-8":"pb-[22px]"].join(" "),lo=(e,t)=>{const l=e.cellSize||"XS",n=e.cellColor||"green";return e.text?u("div",{className:`flex-1 flex items-center justify-center relative py-2 ${Zs[l]} ${qs[n]} ${"XS"===l?"px-3":"px-11"}`,children:u("div",{className:"text-center",children:e.text})},`cell_${t}`):null},no=(e,t,l)=>{const n=0===t,a=t===l.length-1;return u("div",{className:`flex-1 max-w-[180px] text-center px-2 ${n?"pl-9":""} ${a?"mr-3.5":" "}`,children:e.title},`title_${t}`)},ao=g((({doc:e,icon:t})=>{const{text:l,fileSize:n,...a}=e;return p("a",{className:"flex box-border gap-3 group/item h-fit w-fit text-primary-text no-underline hover:text-primary-main",role:"link",...a,children:[t,l?p(me,{size:"text-l",font:"font-light",children:[l,u(me,{color:"text-secondary-text",children:a?.href&&io(ro(a.href),n)})]}):null]})})),io=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),ro=e=>{if(!e)return"";const t=e.lastIndexOf(".");return-1!==t?e.substring(t+1):""},so={double:"flex-wrap",single:"flex-col"},oo=g((({className:e="",title:t,description:l,align:n="text-center",documents:a,icon:i={icon:"DocIcon"},columnsMode:r="double",...s})=>p(C,{className:e,defaultPadding:"p-default",...s,children:[u(Qt,{className:"!p-0",title:t,description:l,align:n,headlineVersion:"M",as:"h2"}),a?.length?u("div",{className:w("mt-8 flex gap-6",so[r]),role:"list",children:a.map(((e,t)=>u("div",{className:"double"===r?"basis-[calc(50%-20px)]":"",role:"listitem",children:u(ao,{doc:e,icon:i?u(Rt,{className:"min-w-6 min-h-6",image:i,width:"24",height:"24"}):null})},String(t))))}):null]}))),co=e=>e?u("div",{className:"mb-5 pt-0.5 sm:mb-0 sm:pt-0",children:u(me,{size:"text-xl","font-weight":"light",children:e})}):null,mo=e=>e?.length?u(ya,{items:e,className:"text-l-light mb-2 last:mb-0"}):u("span",{className:"text-m-light text-secondary-text",children:"Наведите камеру телефона на QR-код и скачайте приложение"}),ho=g((({className:e,padding:t,alignTitle:l="left",buttons:n=[],description:a,headingType:i="h4",image:r,items:s,qr:o,title:c="Мобильное приложение",version:d="primary",...m})=>{const h="secondary"===d?"p-3.5 min-w-[120px]":"min-w-[92px]";return u(C,{className:w("min-h-80",e),defaultPadding:"p-0",version:d,...m,children:p(sa,{className:"h-full",padding:t,defaultPadding:"p-default",title:c?u(I,{headingType:i,title:c,className:w("whitespace-pre-wrap",al[l])}):null,backImage:r?.src?u(Rt,{image:r}):null,buttons:Gt(n,{isVertical:n.length>3}),children:[co(a),p("div",{className:"flex flex-1 gap-s items-center",children:[o?.src?u("div",{className:w("flex justify-center bg-white rounded-md",h),children:u(Rt,{className:"w-fit",image:o})}):null,mo(s)]})]})})})),uo={},po=g((({className:e,filtrationSchema:t={},resetButton:l,...n})=>{const[a,{field:i,reset:r}]=B(uo);return p(C,{className:w(e),defaultPadding:"p-0",version:"transparent",...n,children:[Si({field:i,reset:r,filtrationSchema:t,resetButton:l}),u(wi,{filtrationState:a,...n})]})}));po.childrenTypes=["ProductTile"],po.childSchema=e=>e?.filtrationSchema||{};const go=[{coords:[55.77,37.46],text:"Трактир"},{coords:[55.66,37.48],text:"Трактор"},{coords:[55.65,37.42],text:"Ресторан"},{coords:[55.64,37.54],text:"Музей"},{coords:[55.54,37.52],text:"Библиотека"},{coords:[55.53,37.56],text:"Школа"},{coords:[55.61,37.61],text:"Аптека"},{coords:[55.8,37.58],text:"Бар"},{coords:[55.71,37.35],text:"Институт"},{coords:[55.74,37.57],text:"Университет"},{coords:[55.58,37.69],text:"Больница"},{coords:[55.57,37.7],text:"Цирк"},{coords:[55.55,37.64],text:"Магазин"},{coords:[55.5,37.75],text:"Булочная"},{coords:[55.81,37.73],text:"Полиция"},{coords:[55.73,37.68],text:"Салон красоты"},{coords:[55.86,37.76],text:"Баня"},{coords:[55.38,37.69],text:"Гараж"},{coords:[55.91,37.5],text:"Дом"},{coords:[55.62,37.32],text:"Прачечная"},{coords:[55.85,37.41],text:"Стадион"},{coords:[55.67,37.24],text:"Вокзал"},{coords:[55.79,37.41],text:"Кафе"}];function xo(e,t,l){t.geoObjects.removeAll();const n=e.templateLayoutFactory.createClass('<div style="margin-top: -3px;">{{properties.geoObjects.length}}</div>'),a=new e.Clusterer({clusterIcons:[{href:"icons/MapMarkerClusterIcon.svg",size:[78,84],offset:[-35,-50]}],clusterIconContentLayout:n,clusterHideIconOnBalloonOpen:!1,geoObjectHideIconOnBalloonOpen:!1}),i=l.map((t=>new e.Placemark(t,{},{iconLayout:"default#image",iconImageHref:"icons/MapMarkerSingleIcon.svg",iconImageSize:[78,84],iconImageOffset:[-35,-50]})));a.add(i),t.geoObjects.add(a),t.setBounds(e.util.bounds.fromPoints(l)).then((()=>{t.getZoom()>10&&t.setZoom(10)}))}const fo={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"flex items-center justify-center",font:"text-center font-sans"},bo=e=>u("a",{className:`select-none cursor-pointer px-9 h-12 bg-primary-main text-white ${Object.values(fo).join(" ")}`,href:`https://yandex.ru/maps/?ll=${[e[1],e[0]]}&z=10&l=map`,target:"_blank",children:"Открыть на карте"}),vo={border:"border border-transparent rounded-md",position:"relative flex items-center",font:"text-center font-sans",shadow:"shadow-[0_4px_25px_rgba(0,0,0,0.07)]"},yo=(e,t,l)=>p("div",{className:`${Object.values(vo).join(" ")} bg-white py-3 pl-11 pr-4 w-full`,children:[u(je,{name:"LoupeIcon",iconVersion:"black",width:"20",height:"20",className:"absolute left-4"}),u("input",{type:"text",placeholder:"Введите адрес или метро",onChange:t=>{const n=t.target?.value?t.target?.value.toLowerCase():"";if(n){const t=e.filter((e=>e.text.toLowerCase().indexOf(n)>-1?e:null));l(t)}else l(null)},className:"border-0 focus:border-0 outline-0 w-full"})]}),No={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"absolute flex items-center justify-center",font:"text-center font-sans"},wo=(e,t,l)=>u("div",{className:`select-none cursor-pointer py-4 w-12 bg-white ${Object.values(No).join(" ")} ${l}`,onClick:()=>{t.geolocation.get({provider:"yandex",autoReverseGeocode:!0,mapStateAutoApply:!0}).then((function(t){e.geoObjects.add(t.geoObjects)}))},children:u(je,{name:"UserGeoLocationIcon",width:"20",height:"16"})}),ko={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border-b border-b-2 border-gray last:border-0",position:"relative flex items-center justify-center",font:"text-center font-sans text-l"},Co=g((({yandexMaps:e,direction:t="in"})=>{const l="in"===t?"PlusIcon":"MinusIcon";return u("div",{onClick:()=>{const l=e.current.getZoom(),n="in"===t?l+1:l-1;e.current.setZoom(n,{checkZoomRange:!0})},className:`${Object.values(ko).join(" ")} bg-white select-none cursor-pointer w-12 h-12`,children:u(je,{name:l,width:"20",height:"16"})})})),So={border:"border border-transparent rounded-md ",position:"absolute flex items-center justify-center",size:"w-12 h-12",focus:"focus:border-primary-text focus:border",font:"text-center font-sans",active:"active:bg-primary-active",hover:"hover:bg-primary-hover",other:"select-none cursor-pointer"},Io=g((({points:e,className:t="",zoom:l=5,showSearchField:i=!1})=>{const r=s(null),o=Rs("ymaps",`https://api-maps.yandex.ru/2.1/?apikey=${d.YANDEX_MAP_API_KEY||""}&lang=ru_RU`),[c,m]=n(),[h,g]=n(Po(go)),x=To(e);if(a((()=>{r?.current||o?.ready((()=>{r.current=new o.Map("map",{center:x,zoom:l,controls:[],suppressMapOpenBlock:!0}),xo(o,r.current,h)}))}),[o,r,h]),a((()=>{if(r.current&&h&&o){const e=h.length<1?Po(go):h;xo(o,r.current,e)}}),[r,h,o]),!o)return null;const f=c?"z-[100000]":"z-10";return p("div",{id:"map",className:`${c?"":"relative"} w-full ${t}`,children:[u("div",{className:`absolute flex left-2 top-4 w-[50%] ${f}`,children:i?yo(go,0,(e=>{if(e){const t=Po(e);g(t)}})):bo(x)}),u("div",{className:`${Object.values(So).join(" ")} ${f} right-2 top-4 bg-white`,onClick:()=>{const e=r.current.container;c?e.exitFullscreen():e.enterFullscreen(),m(e.isFullscreen())},children:u(je,{name:"FullScreenIcon",width:"16",height:"16"})}),p("div",{className:`absolute right-2 top-52 z-10 w-12 overflow-hidden border border-transparent rounded-md ${f}`,children:[u(Co,{yandexMaps:r}),u(Co,{yandexMaps:r,direction:"out"})]}),wo(r.current,o,`right-2 top-80 ${f}`)]})})),To=e=>[Ro(Bo(e,0)),Ro(Bo(e,1))],Bo=(e,t)=>e.map((e=>e[t])),Ro=e=>e.reduce(((e,t)=>e+t))/e.length,Po=e=>e?e.map((e=>e.coords)):null,Mo={id:123,branchType:{id:7,code:"21",name:"Отделение на балансе филиала"},shortName:"Ейский ДО",name:"ДО №3349/3/05",address:"353682, Краснодарский край, г.Ейск, ул.Гоголя, 349/ ул.Баррикадная, 42/1",lawAddress:"353682, Краснодарский край, г.Ейск, ул.Гоголя, 349/ ул.Баррикадная, 42/1",openDate:"2000-12-05",closeDate:null,bik:"040349536",corAcc:"30101810700000000536",registrationNumber:"3349/3/05",phone:"+7(XXX)XXX-XX-XX",fax:"+7(XXX)XXX-XX-XY",okpo:"55105921",ogrn:"1027700342890",kpp:"231002002",inn:"7725114488",branchCode:"0305",upperBranchCode:"0300",timeZone:"+03:00",exchangeRate:{currencies:[{buyExchangeRate:0,saleExchangeRate:0,currency:{id:3,code:"156",currency:"CNY",name:"Китайский юань"}},{buyExchangeRate:59.15,saleExchangeRate:69.25,currency:{id:2,code:"978",currency:"EUR",name:"Евро"}},{buyExchangeRate:58.4,saleExchangeRate:70.05,currency:{id:1,code:"840",currency:"USD",name:"Американский доллар"}}],lastUpdate:"2022-11-11 03:56:17"},workSchedule:{id:413,workTime:"09.00–16.30",lunchHour:"без перерыва",workTimeSaturday:"09.00–15.00",lunchHourSaturday:"без перерыва",workingMonday:!1,workingTuesday:!1,workingWednesday:!0,workingThursday:!0,workingFriday:!0,workingSaturday:!0,workingSunday:!1},gpsLatitude:46.709744,gpsLongitude:38.260703,range:null,safeBoxCaseVolumes:null},_o=[{title:"Деловой центр",time:"1 мин",distance:"~30 м.",icon:"MetroIcon"},{title:"Выставочная",time:"5 мин",distance:"~120 м.",icon:"MetroIcon"},{title:"Деловой центр",time:"8 мин",distance:"~350 м.",icon:"MetroIcon"}],$o=({lunchHour:e,status:t,workTime:l})=>{const n=/\d+/gi.test(e)?`Перерыв ${e}`:e;return t?p("div",{className:"flex",children:[u("div",{className:"p-3 border rounded-md text-m flex items-center cursor-pointer text-primary-main border-green-light mr-4",children:l||null}),u("div",{className:"p-3 border rounded-md text-m flex items-center cursor-pointer text-yellow border-golden",children:e?n:null})]}):u("div",{className:"flex",children:u("div",{className:"p-3 border rounded-md text-m flex items-center cursor-pointer text-error border-error",children:"Выходной"})})},Vo=({icon:e,title:t,distance:l,time:n},a)=>p("div",{className:"flex mr-4",children:[u(je,{name:e,width:"16",height:"16",className:"mr-1"}),t?p("span",{className:"text-m",children:[t," "]}):null,p("span",{className:"text-m-light",children:[l?` (${l})`:null,n?`, ${n}`:null]})]},`nearbyOffice${a}`),jo=({title:e,status:t,workTime:l,lunchHour:n,description:a},i)=>p("div",{className:"flex flex-col pb-3 border-b border-solid border-main-divider mb-3 last:border-0",children:[p("div",{className:"flex justify-between items-center w-full pb-1 text-l text-primary-text",children:[u("div",{children:e}),t?null:u("div",{className:"text-m-light text-error",children:"Выходной"}),t&&l?u("div",{children:l}):null]}),t&&n?zo(n):null,a?u("div",{className:"pb-1 text-s-light text-secondary-text",children:a}):null]},`day${i}`),zo=e=>/\d+/gi.test(e)?p("div",{className:"flex justify-between items-center w-full pb-1 text-m-light text-error",children:[u("div",{children:"Перерыв"}),u("div",{children:e})]}):u("div",{className:"flex justify-between items-center w-full pb-1 text-m-light text-primary-main",children:u("div",{children:e})}),Do=g((({className:e=""})=>{const t=Mo,{name:l,address:n,gpsLatitude:a,gpsLongitude:i,workSchedule:r}=t,{workingMonday:s,workingTuesday:o,workingWednesday:c,workingThursday:d,workingFriday:m,workingSaturday:h,workingSunday:g}=r,{workTime:x,lunchHour:f,workTimeSaturday:b,lunchHourSaturday:v}=r,y=a&&i?[a,i]:null,N=[{title:"Понедельник",status:s,workTime:x,lunchHour:f},{title:"Вторник",status:o,workTime:x,lunchHour:f},{title:"Среда",status:c,workTime:x,lunchHour:f},{title:"Четверг",status:d,workTime:x,lunchHour:"13:00 - 14:00",description:"Не работает прием денег с 17:00 до 19:00"},{title:"Пятница",status:m,workTime:x,lunchHour:f},{title:"Суббота",status:h,workTime:b,lunchHour:v},{title:"Воскресенье",status:g}],w=(new Date).getDay(),k=w>0?N[w-1]:N[6];return p("div",{className:`flex flex-col font-sans bg-white w-full ${e}`,children:[p("div",{className:"flex flex-col px-12 pt-12",children:[p("div",{className:"flex justify-between",children:[u("div",{className:"text-h2",children:l}),$o(k)]}),p("div",{className:"flex text-l-light pt-4",children:[u(je,{name:"GeolocationIcon",width:"24",height:"24",className:"pr-1"}),n]}),u("div",{className:"flex pt-4",children:_o.map(Vo)})]}),p("div",{className:"flex justify-between pt-8",children:[u("div",{className:"flex-grow h-full w-full overflow-hidden",children:y?u(Io,{points:[y],className:"h-full"}):null}),u("div",{className:"w-[434px] min-w-[434px] pl-9 pr-12 pb-14 flex flex-col",children:N.map(jo)})]})]})})),Lo=g((({className:e="",title:t,servicesList:l,...n})=>p(C,{className:w("flex flex-col",e),...n,children:[t?u(I,{headingType:"h5",className:"mb-5",title:t}):null,l?.length?u("ul",{className:"list-none m-0 p-0",children:l.map(Ao)}):null]}))),Ao=(e,t)=>p("li",{className:"flex mb-5 last:mb-0 list-none",children:[e.icon?u(Rt,{className:"mr-3 min-w-6 min-h-6 w-6 h-6",width:"24",height:"24",image:e.icon}):null,e.label?u("span",{className:"text-l-light",children:e.label}):null]},`list_item_${String(t)}`),Oo=g((({text:e,size:t,align:l,font:n,children:a,...i})=>u(C,{defaultPadding:"p-0",...i,children:u(de,{size:t,align:l,font:n,children:e||a})}))),Eo=(e=[])=>e?.length?Cr(e)/e.length:0,Fo=g((({className:e,icon:t,label:l,description:n,benefitsVersion:a="normal"})=>p("div",{className:w("flex gap-s",n?"items-start":"items-center",e),children:[t?u("div",{className:Uo(a),children:u(Rt,{className:"w-6 h-6",image:{...t,iconVersion:t.iconVersion||a}})}):null,p("div",{className:"gap-0.5",children:[l?u(me,{color:"text-primary-text group-data-secondary:text-white",size:"text-h6",children:l}):null,n?u(de,{font:"font-light",size:"text-m",color:"text-secondary-text group-data-secondary:text-white",children:n}):null]})]})));function Uo(e){return w("w-12 h-12 min-w-12 p-2.5 box-border flex items-center justify-center rounded-icon","normal"===e?"bg-secondary-light text-primary-main":"bg-primary-main text-black group-data-secondary:bg-white/30 group-data-secondary:text-black")}const Ho=e=>({type:t,...l},n)=>"rte"===t&&"__html"in l?u(Da,{__html:l.__html}):u(Fo,{benefitsVersion:e,...l},String(n)),Xo=e=>"rte"===e.type?e.__html?.length||0:Math.max(e.label?.length||0,e.description?.length||0),Wo=e=>{return((t=e.map(Xo))?.length?Math.sqrt(Math.abs(Eo(t.map((e=>e**2)))-Eo(t)**2)):0)>16;var t},Ko=g((({className:e,benefitsVersion:t="normal",benefits:l})=>l?.length?u("div",{className:w("flex gap-x-m gap-y-s",Wo(l)?"flex-col":"flex-wrap",e),children:l.map(Ho(t))}):null)),Go=g((({className:e,tags:t})=>t?.length?u("div",{className:w("flex flex-wrap gap-xs",e),role:"list",children:t.map(Jo)}):null)),Jo=(e,t)=>u("div",{className:"py-2 px-2.5 border-solid border rounded-md border-gray",role:"listitem",children:u(me,{size:"text-m-light",children:e})},String(t)),Yo=g((({className:e,title:t,description:l,headlineVersion:n="L",align:a="text-left",isInsetTitle:i=!0,benefits:r,benefitsVersion:s,__html:o,items:c,isDotted:d=!0,listItemSize:m,tags:h,buttons:g,image:x,imageOptions:{imageAlign:f,directionRight:b=!0}={},children:v})=>{const y=x?.src?u(Rt,{image:x}):null,N=u(Qt,{title:t,description:l,headlineVersion:n,align:a,isPadding:!1});return u(sa,{className:e,...i?{insetTitle:N}:{title:N},...b?{rightImage:y}:{leftImage:y},imageAlign:f,buttons:Gt(g),children:p("div",{className:"flex flex-col gap-m",children:[u(Ko,{benefitsVersion:s,benefits:r}),o?u(Da,{__html:o}):null,c?.length?u(ya,{items:c,isDotted:d,listItemSize:m}):null,v,h?.length?u(Go,{tags:h}):null]})})})),qo=(e,t)=>e||t?p("div",{className:"flex flex-wrap xl:flex-nowrap xl:bg-main-divider xl:rounded-md p-xs gap-m",children:[Number(e)>0?Zo("Страховая сумма:",e):null,Number(t)>0?Zo("Ежемесячный лимит:",t):null]}):null,Zo=(e,t=0)=>p("div",{className:"basis-full flex flex-col-reverse sm:flex-row sm:justify-between items-baseline whitespace-pre",children:[u(me,{font:"font-light",size:"text-l",children:e}),p(me,{size:"text-h6",color:"text-primary-text",children:[ot(2)(t)," ₽"]})]}),Qo=g((({className:e,headlineVersion:t="M",align:l="text-center",sum:n,monthLimit:a,...i})=>u(C,{className:e,defaultPadding:"p-default",...i,children:u(Yo,{className:"h-full",headlineVersion:t,align:l,isInsetTitle:!1,...i,imageOptions:{directionRight:!1,imageAlign:"center",...i.imageOptions},children:qo(Number(n),Number(a))})}))),ec=g((({className:e,title:t,description:l="Блок в разработке...",...n})=>p(C,{className:w("box-border",e),...n,children:[u(Qt,{className:"max-w-[600px]",title:t,description:l,headlineVersion:"L",align:"text-left",isPadding:!1}),u("figure",{className:"m-0 mt-m min-w-[80%]",children:tc()})]}))),tc=(e=3)=>nc(100,e).map((e=>Math.floor(e))).map(lc),lc=(e,t)=>u("div",{style:{width:`${e||100}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),nc=(e,t)=>[e].concat(t>0?nc(e/1.618,t-1):[]);function ac({text:e,href:t,target:l,icon:n},a){const i="primary"===a?"white":"black",r={text:e,href:t,target:l,ariaLabel:e};return p("div",{className:"flex items-center gap-3",children:[u(se,{className:"w-12 h-12 min-h-12 min-w-12 flex items-center justify-center",version:a,rounded:!0,...r,children:u(Rt,{className:"w-4 h-4",image:{...n,icon:n?.icon||"ArrowLeftIcon",iconVersion:n?.iconVersion||i}})}),u(se,{version:"link",...r})]})}const ic=g((({className:e,backwardButton:t,...l})=>p(C,{className:w("overflow-hidden flex flex-col gap-lg box-border",e),defaultPadding:"p-default",...l,children:[t?.text?ac(t,l.version&&"primary"!==l.version?"white":"primary"):null,u(Yo,{className:"grow h-full",...l})]}))),rc=g((({className:e="",slides:t=[],...l})=>{const[a,i]=n(0);return p(C,{className:w("box-border overflow-hidden",e),defaultPadding:"py-default",...l,children:[u("div",{className:"flex duration-1000",style:{transform:`translateX(-${100*a}%)`},role:"list",children:t.map((({productBlock:e},t)=>u("div",{className:"box-border grow-0 shrink-0 basis-full",role:"listitem",children:u(Yo,{className:"pl-default h-full",headlineVersion:"XXL",...e,...l})},String(t))))}),u("div",{className:"h-28 px-xs mt-m -mb-m flex gap-xs box-border",children:t.map(sc({activeSlideIndex:a,onClick:i}))})]})})),sc=({activeSlideIndex:e,onClick:t})=>({nav:l},n)=>{const a=n===e,i=a?"min-w-[350px] bg-white shadow-dark-blue border-none p-6":"min-w-[290px] ease-in duration-300 bg-white/10 px-6 py-5 hover:py-6 backdrop-blur",r=a?"text-primary-text text-h6 py-2":"text-l pb-1 text-secondary-text group-data-secondary:text-white",s=a?"text-secondary-text text-l-light":"text-m-light text-secondary-text group-data-secondary:text-white/80";return p("button",{type:"button",onClick:()=>t(n),"aria-label":l?.title,className:w("relative px-6 box-border overflow-hidden text-left grow basis-0 border border-gray group-data-secondary:border-white/50",i),children:[u("div",{className:r,children:l?.title}),u("div",{className:s,children:l?.description})]},String(n))};function oc(e,t){if(!e)return null;return u("div",{className:`mt-2.5 z-10 ${t?.src?"max-w-[calc(100%-186px)]":"100%"}`,children:u(de,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:e})})}const cc=(e,t)=>{const{type:l}=e;if("default"!==l&&"rte"!==l)return null;switch(l){case"default":return[u(me,{size:"text-h6",children:e.label},`label-${t}`),u(me,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:e.description},`desc-${t}`)];case"rte":return u("div",{className:"col-span-2",children:u(Da,{__html:e.__html})});default:vr(e)}};function dc(e,t){return e?.src?u(Rt,{className:w("absolute",t?"right-0":"left-0","bottom-0"),image:e}):null}const mc=g((({className:e="",title:t,headlineVersion:l="S",description:n,additionalDescription:a,benefits:i=[],buttons:r,image:s,directionRight:o=!0,...c})=>p(C,{className:w("overflow-hidden box-border relative min-h-[364px] flex flex-col justify-between",e),...c,children:[p("div",{className:w("flex flex-col",o?"":"items-end"),children:[u(Qt,{className:w("!p-0 !bg-transparent z-10",t||n?"mb-3.5":""),title:t,description:n,headlineVersion:l,as:"h2",align:"text-left"}),hc(i,s),oc(a,s)]}),Gt(r,{className:w("mt-5 text-l",o?"":"justify-end")}),dc(s,o)]})));function hc(e,t){if(!e.length)return null;return u("div",{className:w("z-10 grid grid-cols-[max-content_1fr] auto-rows-auto gap-x-6 gap-y-2.5 items-baseline",t?.src?"max-w-[calc(100%-186px)]":"100%"),children:e.length?e.map(cc):null})}const uc=g((({className:e,title:t="Акции и спецпредложения",description:l,headlineVersion:n="S",date:a,buttons:i=[],...r})=>u(C,{className:w("box-border",e),...r,children:p(sa,{className:"h-full",title:t?u(Qt,{title:t,headlineVersion:n,align:"text-left",isPadding:!1}):null,buttons:Gt(i),children:[a?u("div",{className:"text-s mb-2",children:pc(a)}):null,u("div",{className:"text-l",children:l})]})})));function pc(e){return new Date(e).toLocaleString("ru-RU",{day:"numeric",month:"long",year:"numeric"}).replace("г.","")}const gc=g((({address:e,email:t,telephone:l,button:n,className:a="",__html:i,icon:r,title:s,version:o="primary",...c})=>p(C,{className:w("box-border text-left",a),version:o,...c,children:[p("div",{className:"w-full flex justify-between",children:[s?u(I,{headingType:"h4",as:"h3",className:"mb-6",title:s}):null,xc(r)]}),p("div",{className:"w-full",children:[i?fc(i):null,bc("Адрес",e,"GeolocationIcon"),bc("Телефон",l,"PhoneIcon"),bc("E-mail",t,"MailIcon"),n?.text?Gt([n],{className:"mb-6"}):null]})]}))),xc=e=>p("div",{className:"self-end",children:[e?.src?u(Rt,{image:e}):null,e?.icon?u(Rt,{image:e}):null]}),fc=e=>u("div",{className:"border-b border-main-divider pb-5 my-5",children:u(Da,{__html:e})}),bc=(e,t,l)=>p("div",{className:"flex mb-4",children:[u(je,{className:"pr-4",iconVersion:"black",name:l,width:"24",height:"24"}),p("div",{className:"flex flex-col first:pb-1",children:[u(me,{size:"text-m-light",children:e}),t?u(me,{size:"text-h6",color:"text-green",children:t}):null]})]}),vc=g((e=>{const{__html:t,richVersion:l,...n}=e;return u(C,{defaultPadding:"p-0",...n,children:u(Da,{__html:t,richVersion:l})})})),yc=e=>e?"MinusIcon":"PlusIcon",Nc=g((({className:e="",label:t="Развернуть",labelIcon:l,labelIconBgVersion:n,isExpanded:a,isFoldButtonOnTop:i=!0,version:r="primary",...s})=>u(C,{className:w("w-full","border-0 border-b border-solid border-main-divider last:border-b-0",e),defaultPadding:"p-0",tag:"div",version:"transparent",...s,children:u(Aa,{isFoldButtonOnTop:i,unfoldedByDefault:a,renderFoldableSection:({isUnfolded:e})=>u(Oa,{className:w("gap-5 [&>*]:p-0","grid grid-cols-12 [&>*]:pb-4"),isUnfolded:e,children:Sn(s)}),renderFoldButton:({isUnfolded:e,onToggle:a})=>wc({version:r,label:t,labelIcon:l,labelIconBgVersion:n,isUnfolded:e,onToggle:a})})})));Nc.childrenTypes={exclude:["RollupItem"]};const wc=({version:e,label:t,labelIcon:l,labelIconBgVersion:n,isUnfolded:a,onToggle:i})=>{const r=t||(a?"Скрыть":"Развернуть");return"primary"===e?kc({label:r,labelIcon:l,labelIconBgVersion:n,icon:yc(a),onToggle:i}):u(bi,{label:r,icon:a?"ArrowUpIcon":"ArrowDownIcon",onClick:i})},kc=({label:e,labelIconBgVersion:t,icon:l,onToggle:n,labelIcon:a})=>p("button",{className:w("border-none bg-transparent px-0 flex justify-between items-center w-full group/button",a?.icon?"py-2":"py-5"),onClick:n,children:[p("div",{className:"flex items-center group-hover/button:text-primary-main",children:[null,e?u(me,{size:"text-h6",font:"font-normal",children:e}):null]}),l?u(je,{name:l,iconVersion:"color",width:"24",height:"24"}):null]}),Cc=g((({data:e,fieldLabel:t,fieldValue:l,selected:n,placeholder:a="",setSelected:i,label:r})=>{const s=e.filter(Boolean).map((e=>({key:e?.[l||t],text:e?.[t]}))),o=s.find((e=>e.key===n));return u(Le,{options:s,label:r,placeholder:a||n,onChange:e=>i(e.key),value:o})})),Sc=g((({regions:e=[],selectedRegion:t,onSelectedRegion:l,branches:n=[],selectedBranch:a,onSelectedBranch:i})=>p("div",{className:"flex justify-between gap-4 mb-6",children:[u("div",{className:"max-w-[396px] w-1/2",children:u(Cc,{data:e,fieldValue:"code",fieldLabel:"name",selected:t,setSelected:l,label:"Регион"})}),u("div",{className:"max-w-[396px] w-1/2",children:u(Cc,{data:n,fieldValue:"branchCode",fieldLabel:"address",selected:a,setSelected:i,label:"Отделение",placeholder:"Выберите отделение"})})]}))),Ic=g((({name:e,text:t,value:l,checked:n,onChange:a,className:i})=>u("div",{className:i,children:p("label",{className:"font-sans flex items-center relative cursor-pointer",children:[u("input",{className:"appearance-none flex justify-center items-center shrink-0 w-5 h-5 border border-gray hover:border-primary-hover\n checked:border-2 checked:!border-primary-main focus:checked:border-primary-main focus:border-primary-text active:border-primary-text\n after:block after:w-2.5 after:h-2.5 after:rounded-full checked:after:bg-primary-main outline-none rounded-full cursor-pointer",type:"radio",value:l,name:e,checked:n,onChange:e=>a(e.target.value)}),t?u("span",{className:"text-primary-text ml-3 cursor-pointer",children:t}):null]})}))),Tc=g((()=>{const[e,t]=n("option2"),l=i((e=>t(e)),[]);return p("div",{children:[u(Ic,{className:"mb-2",name:"contractType",text:"Простое хранение",value:"option1",checked:"option1"===e,onChange:l}),u(Ic,{name:"contractType",text:"Сделка с недвижимостью",value:"option2",checked:"option2"===e,onChange:l})]})})),Bc=["От 1 дня","До 365 дней"],Rc=g((({days:e,setDays:t})=>p("div",{className:"mb-6",children:[u("span",{className:"block text-m-light mb-[3px]",children:"Срок аренды"}),u(ut,{min:1,max:365,value:e,items:Bc,onChange:t})]}))),Pc=g((({caseVolumes:e=[],selectedCaseVolume:t,onSelectedCaseVolume:l,safeBoxCases:n=[],selectedBoxSize:a,onSelectedBoxSize:i})=>p("div",{className:"flex justify-between mb-6",children:[u("div",{className:"mr-4 w-full",children:u(Cc,{data:e,fieldLabel:"volume",selected:t,setSelected:l,label:"Размер",placeholder:"Выберите размер"})}),u("div",{className:"w-full",children:u(Cc,{data:n,fieldLabel:"safeBoxCasesSize",selected:a,setSelected:i,label:"Параметры ячейки, мм (ВхШхД)",placeholder:"Выберите параметр ячейки"})})]}))),Mc=g((({regions:e,selectedRegion:t,branches:l,selectedBranch:n,days:a,selectedCaseVolume:i,selectedBoxSize:r,safeBoxCases:s,caseVolumes:o,onChange:c,onClick:d})=>p("div",{className:"flex-1 mr-9",children:[u(Sc,{regions:e,selectedRegion:t,onSelectedRegion:e=>c({selectedRegion:e}),branches:l,selectedBranch:n,onSelectedBranch:_c(c)}),u(Rc,{days:a,setDays:e=>c({days:e})}),u(Pc,{caseVolumes:o,selectedCaseVolume:i,onSelectedCaseVolume:$c(c),safeBoxCases:s,selectedBoxSize:r,onSelectedBoxSize:e=>c({selectedBoxSize:e})}),u("span",{className:"text-secondary-text text-l-light",children:"Тип договора"}),p("div",{className:"flex justify-between items-center mt-5",children:[u(Tc,{}),u(se,{text:"Офисы на карте",version:"primary",onClick:d})]})]}))),_c=e=>t=>{e({selectedBranch:t,selectedCaseVolume:"",selectedBoxSize:""})},$c=e=>t=>{e({selectedCaseVolume:t,selectedBoxSize:""})},Vc=g((({days:e,tariffs:t=[]})=>{const l=zc(e,t);return p("div",{className:"flex flex-col justify-between",children:[p("div",{className:"flex",children:[jc("Аренда за",e,"mr-11"),jc("Цена",l+" ₽")]}),p("div",{className:"bg-primary-main px-10 pt-10 pb-4 text-center",children:[u(Rt,{image:{icon:"PackA4Icon"},width:"290",height:"257"}),p("span",{className:"text-s-light text-white opacity-80 mt-2 inline-block",children:["На рисунки изображена пачка",u("br",{})," листов формата А4"]})]})]})})),jc=(e,t,l="")=>p("div",{className:l,children:[u("div",{className:"text-m-light text-secondary-text mb-1",children:e}),u("span",{className:"text-h3 text-primary-text",children:t})]}),zc=(e,t)=>{const l=Dc(e);return e*(t?.find((e=>e.tariffType===String(l)))?.tariffValue||0)},Dc=e=>{let t=1;switch(!0){case e>30&&e<=90:t=2;break;case e>90&&e<=180:t=3;break;case e>180&&e<=365:t=4}return t},Lc=(e,t)=>e.find((e=>e.branchCode===t)),Ac=g((e=>{const{regions:t,data:l,branches:n,onChange:i,onClick:r}=e;a((()=>{i({selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:""})}),[l.selectedRegion,i]);const s=Lc(n,l.selectedBranch),o=Oc(s?.safeBoxCaseVolumes),c=Ec(s?.safeBoxCaseVolumes,l.selectedCaseVolume)?.safeBoxCases,d=Fc(c,l.selectedBoxSize);return p("div",{className:"flex justify-between align-top mb-6",children:[u(Mc,{...l,regions:t,onClick:r,branches:n,caseVolumes:o,safeBoxCases:c,onChange:i}),u(Vc,{days:l.days,tariffs:d})]})})),Oc=e=>e?.length?e?.filter((e=>e?.safeBoxCases?.length)):[],Ec=(e,t)=>e?.find((e=>e.volume===t)),Fc=(e,t)=>e?.find((e=>e.safeBoxCasesSize===t))?.tariffs,Uc=[];const Hc=async e=>await z(e,{method:"GET"})||Uc,Xc=g((({title:e,footnote:t,className:l="",...a})=>{const[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),[c,d]=n({selectedRegion:"",selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:"",days:26}),m=A(),h=Wc(c.selectedRegion,m),g=function(e){const{data:t}=V(e?`/api/v1/safeboxes?regionCode=${e}`:null,Hc);return t||Uc}(h),x=i((e=>d((t=>({...t,...e})))),[d]),f=(b=Lc(g,c.selectedBranch)||g,Array.isArray(b)?b.map((e=>e.gpsLatitude&&e.gpsLongitude?[e.gpsLatitude,e.gpsLongitude]:[])):b?.gpsLatitude&&b?.gpsLongitude?[[b.gpsLatitude,b.gpsLongitude]]:[]);var b;return p(C,{className:l,defaultPadding:"",...a,children:[p("div",{className:"px-8 py-12",children:[e?u(I,{title:e,headingType:"h3",as:"h2",className:"text-primary-text mb-2.5 text-center"}):null,u(Ac,{regions:m,branches:g,data:{...c,selectedRegion:h},onClick:o,onChange:x}),t?u("p",{className:"text-s-light text-secondary-text",children:t}):null]}),f.length&&r?u(Io,{points:f,className:"h-[640px]"}):null]})})),Wc=(e,t)=>!e&&t?.length&&t[0]?.code?t[0].code:e,Kc=e=>Boolean(e?.icon||e?.src),Gc=({styleMap:e,isMainButton:t,version:l})=>(n,a,i)=>{const{label:r,description:s,button:o,items:c,isDotted:d}=n;return p("div",{className:w("relative flex flex-col items-center text-center whitespace-pre-line overflow-hidden",Jc(i.length)),children:[p("div",{className:w(o?.text?"mb-8":"","text-center"),children:[r?u("div",{className:"mb-2",children:u(me,{size:"text-h6",children:r})}):null,p("div",{className:"flex flex-col items-center",children:[s?u("div",{className:e.description,children:s}):null,u(ya,{className:w(s?`${e.description} mt-0.5`:"text-h6"),items:c,listItemSize:"M",isDotted:d})]})]}),o?.text&&!t?u(se,{className:"box-border py-3 h-12 w-full max-w-[240px] mt-auto",version:l,...o,children:o?.text}):null]},String(a))},Jc=e=>e<5?"w-[276px]":"w-[210px]",Yc={description:"text-white/80 text-l-light group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconText:"text-white group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconBackground:"bg-white/30 group-data-primary:bg-main-divider",iconConnector:"bg-white group-data-primary:bg-secondary-light",dot:"bg-white/80 group-data-primary:bg-secondary-text"},qc=g((({className:e="",showLines:t=!0,steps:l=[],buttons:n,size:a="normal",version:i="primary",stepVersion:r="gray",title:s,...o})=>{const c=l.length>3,d=Yc,m=(e=>e?"":"opacity-0")(t),h=(e=>e<5?"px-[88px]":"px-[55px]")(l.length),g=Boolean(n?.every((e=>e?.text)));return p(C,{className:w("box-border flex flex-col items-center overflow-hidden",e),defaultPadding:"p-default",version:i,...o,children:[s?u(I,{headingType:"h4",className:"max-w-[752px] text-center mb-9",title:s}):null,l?.length?p("div",{className:"box-border",children:[u("div",{className:w("flex items-center",h),children:Ys(u("div",{className:w("h-0.5 w-full bg-secondary-light flex-1",m)}))(l.map(Zc(d,a,r)))}),u("div",{className:w("flex justify-between mt-4",c?"gap-x-3":"gap-x-[101px]"),children:l.map((x={styleMap:d,isMainButton:g,version:i},(e,t,l)=>{const{type:n}=e;if("default"!==n&&"rte"!==n)return null;switch(n){case"default":return Gc(x)(e,t,l);case"rte":return u("div",{className:w("text-center",Jc(l.length)),children:u(Da,{__html:e.__html})},String(t));default:return null}}))})]}):null,Gt(n,{className:"mt-8"})]});var x})),Zc=(e,t,l)=>({icon:n},a)=>{const i="secondary"===l?"group-data-primary:text-white":"text-secondary-text",r="secondary"===l?"white":"color";return u(C,{className:`${"normal"===t?"h-[100px] w-[100px]":"h-[63px] w-[63px]"} flex justify-center items-center text-center rounded-full p-[26px] box-border z-10`,version:l,children:Kc(n)?u(Rt,{image:{...n,iconVersion:n.iconVersion||r},width:"48",height:"48"}):u("span",{className:w("text-h4","transparent"===l?e.iconText:i),children:a+1})},String(a))},Qc=g((({className:e,version:t,gap:l=14,padding:n=16,showDots:a=!0,minHeight:i,children:r,onVisibleIndicesChange:s,listType:o="horizontal-list"})=>{const c=Array.isArray(r)?r.length:0,[d,m]=Dn({itemCount:c,onVisibleIndicesChange:s}),[h]=m.visibleIndicesRange;return p("div",{className:w(e,"vertical-list"===o?"relative h-full":""),children:[u(Rn,{containerRef:d,activeIndex:h,visibleItemCount:1,gap:l,padding:n,onVisibleIndicesChange:m.handleVisibleIndicesChange,listType:o,minHeight:i,children:r}),a?u(Vn,{containerRef:d,activeIndex:h,dotCount:c,listType:o,version:t}):null]})})),ed=g((({listType:e,showDots:t,options:l,version:n,...a})=>u(C,{version:n,defaultPadding:"p-0",...a,children:u(Qc,{listType:e,showDots:t,version:n,children:Sn({...a,options:l})})})));ed.childrenTypes={exclude:["SwipeListControlBlock"]};const td="h-12 flex-1 flex items-center justify-center cursor-pointer",ld="font-sans text-m text-center",nd="text-secondary-text sm:group-hover/btn:text-primary-main",ad={block:{scrollable:{active:`inline-flex px-4 grow whitespace-nowrap ${td} bg-white text-primary-main`,default:`inline-flex px-4 grow whitespace-nowrap ${td} group/btn bg-white`},centered:{active:`px-4 rounded-md ${td} bg-primary-main text-white whitespace-nowrap`,default:`px-4 rounded-md ${td} group/btn bg-transparent whitespace-nowrap`},wideScreen:{active:`${td} bg-primary-main text-white whitespace-nowrap`,default:`${td} group/btn bg-white whitespace-nowrap`}},text:{scrollable:{active:`${ld} flex items-center h-full border-0 border-b-2`,default:`${ld} ${nd}`},centered:{active:`${ld} text-white`,default:`${ld} ${nd}`},wideScreen:{active:`${ld} text-white text-black px-2.5 bg-white sm:bg-primary-main sm:text-white`,default:`${ld} ${nd} px-2.5 bg-white`}}},id=(e,t,l)=>{const n=t?"active":"default";return ad[e][l||"wideScreen"][n]},rd=g((e=>{const{tab:t,currentTab:l,onClick:n,tabsMode:a}=e,i="link"===l?.type&&l.href===t.href,r=Y()(t);return u("div",{className:id("block",i,a),role:"tab","aria-selected":i,onClick:()=>n(t),children:u("a",{role:"tab",className:w("flex flex-1 items-center justify-center h-full",id("text",i,a)),target:t.target,href:r.href,onClick:e=>{r.onClick(e),n(t)},children:u("span",{children:t.text})})})})),sd=(e,t,l)=>u("div",{className:w("bg-main-divider min-w-[22px] h-[22px] rounded-full text-xs ml-2 flex justify-center items-center",l&&"scrollable"!==e?"bg-white/30 text-white":"text-secondary-text group-hover/btn:text-primary-main"),children:t}),od=({page:e,showCounter:t,...l})=>(n,a)=>{const i=n.type;if("group"!==i&&"link"!==i)return null;switch(i){case"group":return(({page:e,currentTab:t,showCounter:l,onClick:n,tabsMode:a})=>(i,r)=>{const s=t===i,o=i.ref&&e?.blocks?e.blocks.filter((e=>e?.labels?.includes(i.ref))).length:0;return u("div",{className:id("block",s,a),role:"tab","aria-selected":s,onClick:()=>n(i),children:p("div",{className:w("flex flex-1 items-center justify-center h-full",id("text",s,a)),children:[u("span",{children:i.title}),l&&o?sd(a,o,s):null]})},`group-${String(r)}`)})({page:e,showCounter:t,...l})(n,a);case"link":return u(rd,{tab:n,...l},String(a));default:vr(i)}return null},cd=g((({tabs:e,...t})=>u("div",{className:"flex p-1 m-auto bg-main-gray rounded-md",children:e?.map(od({...t}))}))),dd=g((e=>{const{tabs:t,...l}=e,[n,a]=Dn({itemCount:t?.length||0,isCyclic:!1});return p("div",{className:"relative max-w-full m-auto",children:[u("div",{className:"font-sans max-w-full w-full overflow-hidden relative bg-white",children:u(Rn,{containerRef:n,snapAlign:"snap-start",onVisibleIndicesChange:a.handleVisibleIndicesChange,children:t?.map(od({...l}))})}),a.canScrollLeft?u(xl,{className:"absolute z-40 top-0 left-6",onClick:a.scrollLeft}):null,a.canScrollRight?u(fl,{className:"absolute z-40 top-0 rotate-180 right-6",onClick:a.scrollRight}):null]})})),md=g((e=>{const{className:t="",isSticky:l,tabs:r,...s}=e,[o,c]=n(r?r[0]:void 0);a((()=>{r&&r[0]&&ud(r[0])}),[]),a((()=>{"group"===o?.type&&b.subject("tab",{type:o.type,label:o.ref})}),[o]);const d=i((e=>{ud(e),c(e)}),[]);return u(C,{className:w("relative box-border flex gap-x-1 w-full overflow-x-auto no-scrollbar",l?"sticky top-1 z-20":"",t),defaultPadding:"p-0",role:"tablist",...s,children:hd({tabs:r,onClick:d,currentTab:o,...s})})})),hd=({tabsMode:e,tabs:t,...l})=>{switch(e){case"wideScreen":return t?.map(od({tabsMode:e,...l}));case"centered":return u(cd,{tabs:t,tabsMode:e,...l});case"scrollable":return u(dd,{tabs:t,tabsMode:e,...l})}return null},ud=e=>{"group"===e.type&&b.fire("tab",{type:e.type,label:e.ref}),"link"===e.type&&b.fire("tab",{type:e.type,label:e.href})},pd=g((({isOpen:e,onClick:t})=>p(se,{version:"primary",onClick:t,className:"w-full flex items-center justify-center rounded-none py-5",children:[u("div",{className:"text-h4",children:e?"Скрыть":"Показать"}),u(je,{name:e?"ArrowUpIcon":"ArrowDownIcon",className:"ml-3",iconVersion:"white",width:"20",height:"20"})]}))),gd={Buttons:({buttons:e})=>Gt(e),Img:({image:e})=>e?.src?u(Rt,{image:e}):null,List:({isDotted:e,...t})=>u(ya,{className:"flex flex-col justify-between items-start text-h6",isDotted:e??!0,...t}),LabelDescription:({label:e,description:t})=>p("div",{children:[e?u("div",{className:"text-h6 m-0 "+(t?"mb-1":""),children:e}):null,t?u("div",{className:"text-secondary-text text-l-light",children:t}):null]}),Table:g((({isVisible:e,displayTable:t,dataUrl:l,pdfUrl:n,isOpen:a})=>e?u(pd,{isOpen:a,onClick:()=>{t({dataUrl:l,pdfUrl:n})}}):null))},xd=({rowIdx:e,cellIdx:t,setTableInner:l,tableInner:i,openTableInnerIdx:r,setOpenTableInnerIdx:s})=>(o,c)=>{const[d,m]=n(!0);a((()=>{t===r&&i||m(!0)}),[i,r]);return p("div",{className:"Table"===o?.tableCellType?"ml-10":"first:pt-5 last:pb-5 pl-10",children:[c>0?u("div",{className:"h-5"}):null,fd({cell:o,cellProps:{rowIdx:e,cellIdx:t,fieldIdx:c,displayTable:e=>{m(!1),s(t),l(e)},isVisible:d}})]},String(c))},fd=({cell:e,cellProps:t})=>{if(!e)return null;const{tableCellType:l,...n}=e;if(!l||!(l in gd))return null;return u(gd[l],{...t,...n})},bd=g((({cells:e,rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})=>u("div",{className:"first:pl-0 w-80 flex-grow flex flex-col border-solid border-main-divider border border-t-0 border-x-0",role:"cell",children:e?.length?e.map(xd({rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})):null}))),vd=g((({rows:e})=>{const t=e?.[0]?.length??0,[l,n]=pl({itemCount:t,visibleItemCount:5});return p("div",{children:[e?.map(yd(l)),bl({...n,btnClass:["left-3 top-20","right-3 top-20"],className:""})]})})),yd=e=>(t,l)=>{if(!t?.length)return null;const[n,...a]=t,i=[...Array(e).keys()].reduce(((e,t)=>140*(a?.[t]?.cols?.length??1)+e),0),r=["flex duration-1000 text-center",0!==l?"font-normal":"font-light"].join(" ");return p("div",{className:"flex border-main-divider border border-t-0 border-x-0 border-solid",children:[n?.data?u("div",{className:"text-xl-light w-[214px] pb-5 "+(0===l?"pt-8":"pt-6"),children:n.data}):null,u("div",{className:"flex flex-grow overflow-hidden",children:u("div",{className:r,style:{transform:`translateX(-${i}px)`},children:a?.map(((t,l)=>p("div",{className:"flex flex-col flex-grow justify-center pt-6 pb-5 odd:bg-main-divider",children:[t?.data?u("div",{className:"text-xl-light mb-3",children:t.data}):null,t?.cols?Nd(t.cols,e):null]},`row${l}`)))})})]},String(l))},Nd=(e,t)=>e?.length>0?u("div",{className:`flex ${t} ${0===t?"text-secondary-text":""} last:mr-3`,children:e.map(((e,t)=>u("div",{className:"w-[76px] text-h6 mr-5 first:ml-8",children:e},String(t))))}):null,wd=g((({activeTabIndex:e,items:t})=>{const[l,a]=n({}),r=i((e=>a((t=>({...t,[e]:!t[e]})))),[]);return u("div",{children:t.map(((t,n)=>{const a=`activeTabIdx:${e}-tableIdx:${n}`;return p("div",{className:"w-full",children:[p("div",{className:"flex p-4 bg-gray text-xl-light text-center justify-center cursor-pointer relative",onClick:()=>r(a),children:[t.title,u(Rt,{image:{icon:l[a]?"PlusIcon":"MinusIcon"},className:"absolute right-[22px]",width:"24",height:"24"})]}),u("div",{className:"w-full pl-2 overflow-hidden transition-height duration-500 ease-in-out "+(l[a]?"h-0":""),children:u("div",{className:"relative",children:u(vd,{rows:t.rowsData})})})]},a)}))})})),kd=g((({currencies:e,linkToPDF:t,activeTabIndex:l,setActiveTabIndex:n})=>p("div",{className:"flex justify-between w-full pt-2.5 pb-3",children:[e&&e.length>1?u("div",{className:"flex bg-secondary-light p-1.5 rounded-md",children:e.map(((e,t)=>u("div",{className:"rounded-md text-xl-light px-4 py-3 cursor-pointer "+(t===l?"bg-primary-main text-white":"text-secondary-text"),onClick:()=>n(t),children:e||t+1},e)))}):null,t?u(se,{href:t,version:"secondary",target:"_blank",appendLeft:u(je,{name:"DocDownloadIcon",iconVersion:"color",className:"mr-0.5",width:"20",height:"20"}),text:"Скачать в PDF"}):null]})));async function Cd(e){const t=await fetch(e);return await t.json()}const Sd=g((({dataUrl:e,pdfUrl:t,onClick:l})=>{const{tableData:a}=function(e){const{data:t}=V(function(e){return`/wcms-resources/${e||"tariffs-inner-table-data"}.json`}(e),Cd);return t||{}}(e),[r,s]=n(0),o=i((e=>s(e)),[]),c=a?.[r]?.items??[],d=a?.map((e=>e.currency??""));return p("div",a?{className:"bg-white z-10",children:[u(kd,{currencies:d,activeTabIndex:r,setActiveTabIndex:o,linkToPDF:t}),u(wd,{activeTabIndex:r,items:c}),u(pd,{onClick:l,isOpen:!0})]}:{className:"my-5 text-h6 text-center",children:[u("p",{children:"Данных нет"}),u(pd,{onClick:l,isOpen:!0})]})})),Id=g((({children:e,tableInner:t,onHideContentClick:l})=>p("div",{className:"self-start flex flex-col",role:"row",children:[u("div",{className:"flex",children:e}),t?u("div",{className:"origin-top animate-expansion",children:u(Sd,{...t,onClick:l})}):null]}))),Td=g((({row:{header:e,data:t},activeIndex:l,rowIdx:a,...r})=>{const[s,o]=n(void 0),c=i((e=>o(e)),[]),[d,m]=n(void 0),h=i((e=>m(e)),[]);return p(Id,{onHideContentClick:()=>o(void 0),tableInner:s,...r,children:[u("div",{className:"text-s py-5 w-[354px] flex-shrink-0 border-main-divider border border-t-0 border-x-0",children:p("div",{className:"flex items-center text-primary-text",role:"cell",children:[e?.icon?u(Rt,{className:"mr-3.5 max-w-6",image:e.icon,width:"24",height:"24"}):null,e?.title?u("div",{className:"text-m-light",children:e?.title}):null]})}),t?.length?u(Qa,{activeIndex:l,columnWidth:360,version:"tariff",children:t.map(((e,t)=>u(bd,{cells:e,rowIdx:a,cellIdx:t,setTableInner:c,tableInner:s,openTableInnerIdx:d,setOpenTableInnerIdx:h,...r},String(t))))}):null]})})),Bd=g((({className:e="",title:t,description:l,rowHeaders:n,tariffsColumns:a,hiddenRowsNum:i=0,...r})=>{const s=a?.map((({data:e})=>e))||[],o=n?.map(((e,t)=>({header:e,data:s.map((e=>e?.[t]||[]))}))),c=s.length,[d,m]=pl({itemCount:c,visibleItemCount:2}),h=(o||[]).map(((e,t)=>u(Td,{row:e,activeIndex:d,rowIdx:t,...r},String(t)))),[g,x]=i>0?[h.slice(0,-i),h.slice(-i)]:[h,[]];return p(C,{className:w("overflow-hidden relative",e),defaultPadding:w("p-default",c>1?"pr-0":""),...r,children:[Rd({title:t,description:l}),Pd(l),i>0?u(Aa,{renderFoldableSection:({isUnfolded:e})=>p(Md,{controls:m,children:[g,u(Oa,{isUnfolded:e,children:x})]}),renderFoldButton:vi}):u(Md,{controls:m,children:h})]})}));function Rd({title:e,description:t}){return e?u(I,{headingType:"h3",className:"text-center "+(t?"mb-2.5":"mb-8"),title:e}):null}function Pd(e){return e?u("div",{className:"mb-9 text-center text-l",children:e}):null}const Md=g((({children:e,controls:t})=>{const{isScrollAvailable:l}=t;return p("div",{role:"table",children:[p("div",{className:"relative",children:[e,bl({...t,btnClass:["top-[108px]","top-[44px]"],className:"right-7"})]}),l?u("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"}):null]})})),_d=g((({className:e="",title:t,description:l,iconVersion:n,image:a,__html:i,items:r=[],...s})=>p(C,{className:w("flex gap-3 bg-white group-data-secondary:bg-primary-main/10",e),...s,children:["small"===n?u("div",{className:"mt-1",children:$d()}):null,"big"===n?Vd(a):null,p("div",{className:"flex flex-col w-fit gap-3",children:[t?u(me,{size:"text-l",font:"font-medium",color:"text-primary-text group-data-secondary:text-white",children:t}):null,l?jd(l):null,r?.length?zd(r,!0):null,i?u(Da,{__html:i}):null]})]}))),$d=()=>u("div",{className:"rounded-full h-4 w-4 text-center text-xs-light bg-primary-main text-white group-data-secondary:bg-white group-data-secondary:text-primary-main",children:"i"}),Vd=e=>e?.src?u(Rt,{className:"h-fit",image:e}):null,jd=e=>u(de,{size:"text-s",color:"text-secondary-text group-data-secondary:text-white",children:e}),zd=(e,t)=>u("ul",{className:w("text-secondary-text group-data-secondary:text-white/80",t?"list-disc pl-6":""),children:e.map(((e,t)=>u("li",{children:u(me,{size:"text-s",font:"font-light",children:e})},`listItem-${t}`)))}),Dd=g((({className:e,headlineVersion:t="S",listItemSize:l="M",...n})=>u(C,{className:e,...n,children:u(Yo,{className:"h-full",headlineVersion:t,listItemSize:l,...n,imageOptions:{imageAlign:"end",...n.imageOptions}})}))),Ld={stretch:"items-stretch",left:"items-start",center:"items-center",right:"items-end"},Ad=g((({className:e="",gap:t="",align:l="stretch",isPadding:n=!1,isInnerPadding:a=!0,version:i="transparent",isTheme:r=!1,...s})=>{const o=a?"":"!p-0";return u(C,{className:w("relative","flex flex-col [&>*]:max-w-full",Es[t],l&&Ld[l],e),defaultPadding:n?"p-default":"",version:i,isTheme:r,...s,children:Sn({...s,renderProps:(e,t)=>wn(e,t,{className:o})})})}));Ad.childrenTypes=[];const Od=e=>Yn(e)<10?"py-6 px-11":"py-12 px-32",Ed=g((({className:e,title:t,url:l,previewImg:n,...a})=>{const i=J();return p(C,{className:e,defaultPadding:Od(e),...a,children:[u(Qt,{title:t,headlineVersion:"M"}),l?u("video",{className:"m-auto w-full object-fill",preload:"metadata",poster:W(i)(n?.src),style:{maxHeight:524},controls:!0,children:u("source",{src:W(i)(l)})}):null]})})),Fd={ApplicationForm:Ft,BenefitsBlock:Ut,Bonus:el,BonusBenefitsBlock:cl,BusinessBlock:hl,ButtonsBlock:ul,Calculator:hn,CardTransfer:vn,Carousel:Fn,CarouselBankHistoryCard:Wn,CarouselCard:ea,CarouselCatalogCard:la,CarouselEventCard:ia,CarouselInvestmentCard:da,CarouselLinks:pa,CarouselProductCard:Na,CarouselProgramsCard:Ta,CarouselRecommendationCard:ja,CarouselRichTextCard:La,CarouselTariffsCard:Ua,ComparisonTable:di,ContactsBlock:hi,DepositFiltration:Ri,ErrorBlock:Mi,ExchangeRateTile:or,Footer:Qr,GracePeriod:es,Header:Os,Headline:Qt,HorizontalLayout:Fs,ImgBlock:Us,InsuranceAmountBlock:Gs,InvestmentInfo:Qs,LinkDocs:oo,MobileAppTile:ho,MortgageFiltration:po,OfficeMap:Do,OfficeServicesBlock:Lo,ParagraphBlock:Oo,PictureText:Qo,Placeholder:ec,ProductBlock:ic,ProductGallery:rc,ProductTile:mc,PromoTile:uc,RepresentativeOfficeInfo:gc,RichTextBlock:vc,RollupItem:Nc,SafeDepositRental:Xc,StepsBlock:qc,SwipeListControlBlock:ed,Tabs:md,TariffsTable:Bd,TextBlock:_d,Tile:Dd,VerticalLayout:Ad,Video:Ed,ExchangeRateOffice:Ai};const Ud=["Header","Footer"],Hd=([,{target:e}])=>Math.abs(e.getBoundingClientRect().top);function Xd(e=globalThis){const t=s(new Map);a((()=>N.subscribe("intersection",(({block:e,intersection:l})=>{t.current&&t.current.set(e,l)}))),[]),a((()=>{const l=((e,t=600)=>{let l;const n=(...a)=>{n.dispose(),l=setTimeout((()=>{e(...a)}),t)};return n.dispose=()=>{l&&clearTimeout(l)},n})((()=>{!function(e){const t=`#${l=e?.anchor,l?.replace("#","")||""}`;var l;globalThis.location?.hash!==t&&globalThis.history?.replaceState(globalThis.history?.state,"",t)}(globalThis.scrollY>3*globalThis.innerHeight/4?function(e){const t=e.filter((([e])=>!Ud.includes(e.type||""))).filter((([,{intersectionRatio:e}])=>e>.01)),[l]=t.length>0?El(Hd)(t):[];return l}([...t.current||[]]):void 0)}),100);return e.addEventListener("scroll",l),()=>{l.dispose(),e.removeEventListener("scroll",l)}}),[e])}const Wd="cookieClose",Kd=g((({termLink:e,personalDataPolicyLink:t})=>{const{isOpened:l,onClose:n}=$r("cookie",!globalThis.localStorage?.getItem(Wd)),a=i((()=>{globalThis.localStorage?.setItem(Wd,"true"),n&&n()}),[n]);return l?u("div",{className:"container z-40 fixed bottom-0 left-0 right-0 pointer-events-none",children:p("div",{className:"bg-white m-6 p-6 rounded-md flex items-center pointer-events-auto shadow-[0_4px_25px_rgba(0,0,0,0.07)]",children:[u("div",{className:"flex-1",children:p(de,{size:"text-s-light",color:"text-primary-text",children:["АО «Россельхозбанк» использует",u(aa,{isRemote:!0,className:w(Gd(e?.href)),...e,children:"cookie"}),"(файлы с данными о прошлых посещениях сайта) для персонализации сервисов и удобства пользователей. Вы можете запретить сохранение cookie в настройках своего браузера.",u(aa,{isRemote:!0,className:w(Gd(t?.href)),...t,children:"Обработка Ваших персональных данных"}),"производится в соответствии с требованиями Федерального закона от 27.07.2006 № 152-Ф3 «О персональных данных»."]})}),u("div",{className:"w-24 flex justify-end",children:u(br,{className:"bg-main-gray rounded-md",onClick:a})})]})}):null})),Gd=e=>["inline mx-1",e?"text-green-dark":""],Jd=h();const Yd=g((({className:e,onClick:t,ariaLabel:l})=>u("button",{type:"button",className:`border-0 w-9 bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":l,children:qd()}))),qd=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return p("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[u("path",{...e,strokeMiterlimit:"10",d:"M21.48 11.95c.5-1.4-.4-2.6-1.9-2.6h-4c-.6 0-1.1-.5-1-1.2l.5-3.2c.2-.9-.4-1.9-1.3-2.2-.8-.3-1.8.1-2.2.7l-4.1 6.1M7.48 18.35l3.1 2.4c.4.4 1.3.6 1.9.6h3.8c1.2 0 2.5-.9 2.8-2.1l1.24-3.77"}),u("path",{...e,d:"M2.38 18.35v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9Z"})]})},Zd=g((({className:e=""})=>{const t=function(e){const[t,l]=n(0);return a((()=>{(async()=>{const[t]=await Jd.getLikeCount(e);l(t?.value||0)})()}),[e]),{likeCount:t,like:i((async()=>{l(await Jd.like(e))}),[e]),dislike:i((async()=>{l(await Jd.dislike(e))}),[e])}}(J().pathname);return p("div",{className:`border-main border-2 border-solid bg-white flex w-[125px] items-center justify-center gap-3 p-2 font-sans ${e}`,children:[u(Yd,{onClick:G(t.like),ariaLabel:"Поставить отметку «лайк»"}),u(Yd,{onClick:G(t.dislike),className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),u("span",{className:"select-none",children:t.likeCount})]})})),Qd=g((e=>{const{className:t="",blocksRegistry:l,blockDecorator:n,data:a={}}=e,{style:i,blocks:r,slots:s,likeControl:o,colorPalette:c="pc"}=a,d={key:"",page:a,blocksRegistry:l,blockDecorator:n,parent:a};Xd();const[m,{setTrue:h,setFalse:g}]=_e();return yr({onOpen:h,onClose:g}),p("section",{className:w("relative",i,t,m?"overflow-hidden h-screen":""),"data-theme":c,children:[s?.header?u("div",{className:"mb-5 shadow-[0_8px_32px_0px_#00000014]",children:Cn(s?.header,{...d,slotName:"header"})}):null,p("div",{className:"container grid grid-cols-12 gap-1",children:[Cn(r,d),s?.footer?Cn(s?.footer,{...d,slotName:"footer"}):null]}),o?u("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:u(Zd,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto"})}):null,u(Kd,{termLink:{href:"/pd-policy#cookie",target:"_blank"},personalDataPolicyLink:{href:"/pd-policy",target:"_blank"}})]})}));Qd.childrenTypes=[],Qd.slots=()=>["header","footer"];e.Blocks=Fd,e.ContentPage=Qd,e.DaDataAPI=function(e=""){return{getFetcherAddress:async function(){if(!("geolocation"in navigator))return null;try{const t=await(async()=>new Promise((e=>navigator.geolocation.getCurrentPosition((({coords:t})=>e(t))))))(),l=await fetch(`${e}/geolocate`,{method:"POST",mode:"cors",body:JSON.stringify({lat:t.latitude,lon:t.longitude,count:1})});return(await l.json())?.suggestions?.[0]?.data?.city}catch(e){return console.error(e),null}}}},e.LikeAPI=h,e.handlerDecorator=G,e.joinList=Ys,e.packageVersion="0.12.5",e.projectSettings=d,e.setup=(e,t)=>{globalThis._uni={_jsx:e,_jsxs:t||e}},e.setupHooks=e=>{t=e},e.url=X,e.useRouter=J,Object.defineProperty(e,"__esModule",{value:!0})}));