/* Сайт и приложение для клиентов. */
body { background: #EEF5FC; font-size: 16px; }

/* Шапка как на vodoley.kz: белая, оригинальный логотип, синие кнопки. */
.shop-bar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; background: #fff;
  color: var(--brand-dark); padding: 8px 16px; padding-top: max(8px, env(safe-area-inset-top));
  box-shadow: 0 1px 0 #e3ebf5; }
.shop-bar .brand { display: flex; align-items: center; text-decoration: none; }
.shop-bar .brand img { height: 40px; width: auto; }
.shop-bar .btn-light { background: var(--brand-soft); border-color: var(--brand-soft); color: var(--brand); }
.shop-main { max-width: 640px; margin: 0 auto; padding: 16px 16px 32px; }
.shop-footer { text-align: center; color: #6b7280; font-size: 13px; padding: 16px; }
.office-contacts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px;
  max-width: 640px; margin: 0 auto 12px; text-align: left; }
.office-contact { background: #fff; border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; }
.office-contact b { color: var(--brand-dark); }

.hero { background: linear-gradient(135deg, #02439D, #3890D0); color: #fff; border-radius: 16px; padding: 20px; margin-bottom: 16px; }
.hero h1 { font-size: 1.5rem; font-weight: 700; }

.panel { background: #fff; border-radius: 14px; padding: 16px; margin-bottom: 14px; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.panel h2 { font-size: 1.05rem; font-weight: 700; margin-bottom: 10px; }

.product { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid #eef2f7; }
.product:last-child { border-bottom: 0; }
.product .info { flex: 1; }
.product .price { font-weight: 700; }
.product .tiers { font-size: 13px; color: #198754; }
.stepper { display: flex; align-items: center; gap: 6px; }
.stepper input { width: 56px; text-align: center; }
.stepper .btn { width: 40px; height: 40px; border-radius: 50%; }

.total-bar { position: sticky; bottom: 0; background: #fff; border-radius: 14px 14px 0 0; padding: 12px 16px;
  box-shadow: 0 -2px 10px rgba(0,0,0,.08); display: flex; align-items: center; gap: 12px; }
.total-bar .sum { font-size: 1.3rem; font-weight: 700; }

.hp { position: absolute; left: -10000px; }

/* Чат с Vodoley — тот же вид, что в CRM (владелец 02.11.2026): спокойный фон, пузыри с хвостиком, время справа. */
.chat { display: flex; flex-direction: column; gap: 6px; max-height: 62vh; overflow-y: auto; padding: 10px; background: #eef3f9; border-radius: 12px; }
.chat .msg { max-width: 82%; padding: 7px 11px 5px; border-radius: 14px; line-height: 1.4; }
.chat .msg .t { white-space: pre-wrap; overflow-wrap: anywhere; }
.chat .msg.in { background: #02439D; color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }   /* клиент */
.chat .msg.out { background: #fff; border: 1px solid #e3e8ef; align-self: flex-start; border-bottom-left-radius: 4px; }  /* Vodoley */
.chat .msg .who { display: block; font-size: 11px; font-weight: 600; color: #02439D; margin-bottom: 1px; }
.chat .msg .meta { font-size: 11px; opacity: .75; text-align: right; margin-top: 2px; }
.chat .chat-day { align-self: center; font-size: 12px; color: #4b5563; background: #dfe7f1; border-radius: 999px; padding: 2px 12px; margin: 6px 0 2px; }
.chat .chat-empty { margin: auto; color: #6b7280; text-align: center; padding: 16px 0; }

.status-step { display: flex; gap: 8px; align-items: center; color: #9ca3af; }
.status-step.done { color: var(--st-delivered); }
.status-step.current { color: #02439D; font-weight: 700; }

/* Главный экран 2026-10 (вариант из макетов, на настоящих данных). Шрифт и цвет текста — как на vodoley.kz. */
body { font-family: Arial, Helvetica, sans-serif; color: #102B4D; }
body.has-tabbar { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
.city-chip { display: inline-flex; align-items: center; gap: 4px; background: var(--brand-soft); color: var(--brand);
  border-radius: 999px; padding: 5px 10px; font-size: 14px; font-weight: 700; }
.city-select select { border: 0; background: transparent; color: var(--brand); font-weight: 700; padding: 0 2px; }
.hello { font-size: 1.15rem; font-weight: 700; color: var(--brand-dark); margin-bottom: 10px; }

.addr-chip { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 14px; padding: 10px 14px;
  margin-bottom: 12px; color: inherit; text-decoration: none; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.addr-chip > .bi-geo-alt-fill { color: var(--brand); font-size: 20px; }
.addr-chip small { display: block; color: #6b7280; font-size: 12px; }

.promo { position: relative; overflow: hidden; display: flex; align-items: center; gap: 8px; border-radius: 18px;
  padding: 18px 14px 18px 18px; margin-bottom: 12px; background: linear-gradient(135deg, #fff 0%, #E3F0FB 60%, #CFE5F7 100%); }
.promo-text { flex: 1; min-width: 0; position: relative; z-index: 1; }
.promo .eyebrow { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--brand-green); font-weight: 700; }
.promo h1 { font-size: 1.45rem; line-height: 1.2; font-weight: 500; color: var(--brand); margin: 6px 0 10px; }
.promo h1 span { border-bottom: 3px solid var(--brand-green-light); }
.promo-facts { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; font-size: 13px; }
.promo-facts i { color: var(--brand); width: 18px; display: inline-block; }
.promo-photo { width: 108px; height: 150px; object-fit: contain; flex-shrink: 0; mix-blend-mode: multiply; }

.round-icon { width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0; display: inline-flex; align-items: center;
  justify-content: center; background: var(--brand-soft); color: var(--brand); font-size: 20px; }
.round-icon.go { background: #E7F4E4; color: var(--brand-green); }

.order-track { display: block; background: #fff; border-radius: 16px; padding: 14px; margin-bottom: 12px; color: inherit;
  text-decoration: none; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.track-steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); padding: 0; margin: 12px 0 0; counter-reset: s; }
.track-steps li { position: relative; text-align: center; font-size: 11px; color: #9ca3af; padding-top: 22px; }
.track-steps li::before { content: ''; position: absolute; top: 3px; left: 50%; width: 14px; height: 14px; margin-left: -7px;
  border-radius: 50%; background: #e5e7eb; z-index: 1; }
.track-steps li + li::after { content: ''; position: absolute; top: 9px; right: 50%; width: 100%; height: 3px; background: #e5e7eb; }
.track-steps li.done, .track-steps li.now { color: #102B4D; }
.track-steps li.done::before { background: var(--brand-green); }
.track-steps li.now::before { background: #fff; border: 4px solid var(--brand); }
.track-steps li.done::after, .track-steps li.now::after { background: var(--brand-green); }

.repeat-card { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; border-radius: 16px; padding: 14px;
  margin-bottom: 12px; color: #fff; background: linear-gradient(135deg, var(--brand) 0%, var(--brand-light) 100%); }
.repeat-card .round-icon { background: rgba(255,255,255,.2); color: #fff; }
.repeat-card b { display: block; font-size: 1.05rem; }
.repeat-card small { display: block; opacity: .9; }

.stats { display: flex; gap: 8px; margin-bottom: 14px; color: inherit; text-decoration: none; }
.stats > div { flex: 1; background: #fff; border-radius: 14px; padding: 10px 12px; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.stats small { display: block; color: #6b7280; font-size: 12px; line-height: 1.2; }
.stats b { font-size: 1.25rem; }

.section-title { font-size: 1.05rem; font-weight: 700; margin: 4px 0 10px; }
.section-title small { font-weight: 400; color: #6b7280; font-size: 13px; }
.pgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 14px; }
.pcard { background: #fff; border-radius: 16px; padding: 10px; display: flex; flex-direction: column; gap: 2px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06); border: 2px solid transparent; }
.pcard.picked { border-color: var(--brand-light); }
.pphoto { height: 110px; border-radius: 12px; background: linear-gradient(180deg, #F3F8FD, #E3F0FB);
  display: flex; align-items: center; justify-content: center; margin-bottom: 6px; }
.pphoto img { max-height: 100px; max-width: 100%; object-fit: contain; mix-blend-mode: multiply; }
.pphoto .product-photo { border: 0; background: transparent; }
.pname { font-size: 14px; line-height: 1.25; flex: 1; }
.pcard .price { font-weight: 700; font-size: 1.1rem; }
.pcard .tiers { font-size: 12px; color: var(--brand-green); }
.pcard .stepper { justify-content: space-between; margin-top: 6px; gap: 4px; }
.pcard .stepper .btn { width: 36px; height: 36px; padding: 0; }
.pcard .stepper input { width: 44px; padding: 4px; }
.pcard .stepper input[max="100000"] { width: 64px; }  /* талоны — до 6 знаков */
.coupon-quick { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.coupon-quick .btn { padding: 2px 8px; font-size: 12px; }
.coupon-form .coupon-qty { width: 7.5rem; }
.coupon-sum { background: #F3F8FD; border-radius: 12px; padding: 8px 12px; }
.coupon-picture { display: block; width: 100%; max-width: 280px; margin: 0 auto 8px; border-radius: 12px; }

.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; background: #fff;
  border-top: 1px solid #e3ebf5; padding-bottom: env(safe-area-inset-bottom); }
.tabbar a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 6px;
  font-size: 11px; color: #6b7280; text-decoration: none; }
.tabbar a i { font-size: 21px; }
.tabbar a.active { color: var(--brand); font-weight: 700; }
.has-tabbar .total-bar { bottom: calc(64px + env(safe-area-inset-bottom)); }
/* Нечётное число товаров: последняя карточка — на всю ширину, фото слева. */
.pgrid > .pcard:last-child:nth-child(odd) { grid-column: 1 / -1; display: grid; grid-template-columns: 120px minmax(0, 1fr);
  align-content: start; column-gap: 12px; }
.pgrid > .pcard:last-child:nth-child(odd) .pphoto { grid-row: 1 / span 4; height: 110px; margin: 0; }
.pgrid > .pcard:last-child:nth-child(odd) .stepper { justify-content: flex-start; gap: 8px; }

/* Точка на карте в форме заказа (владелец 31.10.2026) */
.shop-point-map { height: 260px; border-radius: 12px; border: 1px solid #dbe3ec; }
.leaflet-div-icon.address-pin { background: none; border: 0; color: #0b5cab; }
.address-pin svg { width: 30px; height: 42px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.45)); }

/* Правовые страницы: «Конфиденциальность», «Условия», «Удаление данных» (пакет юриста 01.11.2026) */
.legal-footer { margin-top: 4px; }
.legal-footer a, .legal-links a { color: inherit; }
.legal { max-width: 860px; margin: 0 auto 14px; line-height: 1.5; overflow-wrap: anywhere; font-size: 14px; }
/* мелкий шрифт правовых страниц — владелец 02.11.2026 */
.legal-lang { display: flex; gap: 6px; margin-bottom: 12px; }
.legal-text h1 { font-size: 1.15rem; font-weight: 700; margin-bottom: 8px; }
.legal-text h2 { font-size: 1rem; font-weight: 700; margin: 16px 0 6px; }
.legal-text h3 { font-size: .95rem; font-weight: 700; margin: 12px 0 4px; }
.legal-text ul, .legal-text ol { padding-left: 1.3rem; }
.legal-text li { margin-bottom: 4px; }
.legal-table { font-size: 12px; }
@media (max-width: 575px) { .legal-table { font-size: 11px; } .legal-table td, .legal-table th { padding: 4px; } }
.legal-table th { background: #f1f5fa; font-weight: 600; }
.legal-table td, .legal-table th { vertical-align: top; }
.legal-request { border-top: 1px solid #eef2f7; margin-top: 18px; padding-top: 14px; }
.legal-request h2 { font-size: 1rem; }
.legal-links { display: flex; flex-wrap: wrap; gap: 6px 16px; border-top: 1px solid #eef2f7; margin-top: 18px; padding-top: 10px; }

/* Ноль — серым и не жирным, как в CRM («Единый вид», 01.11.2026). */
.zero { color: #9aa3af; font-weight: 400; }
