/* VSL REPAPA, версия «blue». Три блока: калькулятор, кейсы, история Влады.
   Доработка 15 ноября. Все классы начинаются с cc-, общие стили в style.css не тронуты. */

/* ================= Калькулятор ================= */
.cc-calc-sec .head { margin-bottom: clamp(24px, 2.6vw, 36px); }
.cc-calc-sec .head .lead { max-width: 47em; margin-top: clamp(12px, 1.4vw, 18px); }
@media (min-width: 861px) and (max-height: 960px) {
  .cc-calc-sec { padding-block: clamp(72px, 6.8vw, 98px) clamp(72px, 7.6vw, 112px); }
}

.cc-calc {
  display: grid; grid-template-columns: minmax(0, .96fr) minmax(0, 1.04fr); gap: clamp(8px, 1vw, 12px);
  padding: clamp(8px, 1vw, 12px); background: var(--paper); border-radius: var(--r-l);
  box-shadow: 0 0 0 1px rgba(27, 86, 223, .06), 0 2px 6px rgba(20, 60, 160, .05), 0 34px 70px -42px rgba(20, 60, 160, .42);
}
.cc-ctl { padding: clamp(16px, 2vw, 26px) clamp(16px, 2.4vw, 32px); display: grid; gap: 12px; align-content: center; }
.cc-kicker { display: flex; align-items: center; gap: 12px; font: 750 13px/1 var(--f-d); letter-spacing: .08em; text-transform: uppercase; color: var(--blue); }
.cc-kicker::after { content: ""; flex: 1; height: 1.5px; background: repeating-linear-gradient(90deg, rgba(27, 86, 223, .32) 0 7px, transparent 7px 15px); }
.cc-kicker.is-now { margin-top: 8px; color: var(--ink-3); }
.cc-kicker.is-now::after { background: repeating-linear-gradient(90deg, rgba(11, 26, 74, .22) 0 7px, transparent 7px 15px); }

/* Поле: подпись, значение, ползунок. --p это положение от 0 до 1, --c цвет бегунка, --g сила свечения. */
.cc-f { --p: .5; --c: var(--amber); --g: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; column-gap: 12px; }
.cc-f label { font-size: 17px; color: var(--ink-2); }
.cc-f label small { display: block; font-size: 13.5px; color: var(--ink-3); margin-top: 1px; }
.cc-f output { font: 800 clamp(22px, 2vw, 26px)/1 var(--f-d); letter-spacing: -.03em; color: var(--ink); font-variant-numeric: tabular-nums lining-nums; white-space: nowrap; transition: color .3s; }
.cc-f output .cc-unit { font-size: .62em; font-weight: 650; letter-spacing: 0; color: var(--ink-3); margin-left: .3em; }
.cc-range { --tw: 30px; grid-column: 1 / -1; position: relative; height: 40px; margin-top: 1px; }
.cc-range input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; z-index: 2; touch-action: pan-y; -webkit-appearance: none; appearance: none; background: none; }
.cc-range input::-webkit-slider-thumb { -webkit-appearance: none; width: var(--tw); height: 40px; margin: 0; border: 0; box-shadow: none; background: none; transform: none; }
.cc-range input::-moz-range-thumb { width: var(--tw); height: 40px; border: 0; box-shadow: none; background: none; }
.cc-range input::-webkit-slider-runnable-track { height: 40px; background: none; }
.cc-range input::-moz-range-track { height: 40px; background: none; }
.cc-track { position: absolute; left: 0; right: 0; top: 50%; height: 10px; margin-top: -5px; border-radius: 6px; background: var(--cloud-2); overflow: hidden; }
.cc-fill { position: absolute; inset: 0; border-radius: 6px; background: var(--sky-1); clip-path: inset(0 calc(100% - (var(--p) * (100% - var(--tw)) + var(--tw) / 2)) 0 0 round 6px); }
.cc-thumb {
  position: absolute; top: 50%; left: calc(var(--p) * (100% - var(--tw))); width: var(--tw); height: var(--tw); margin-top: calc(var(--tw) / -2);
  border-radius: 50%; background: var(--c); border: 4px solid #fff; pointer-events: none; z-index: 1;
  box-shadow: 0 0 0 1.5px rgba(11, 26, 74, .12), 0 8px 16px -6px color-mix(in srgb, var(--c) 85%, #000 0%),
    0 0 0 calc(var(--g) * 7px) color-mix(in srgb, var(--c) 22%, transparent), 0 0 calc(var(--g) * 26px) calc(var(--g) * 3px) color-mix(in srgb, var(--c) 60%, transparent);
  transition: transform .2s var(--ease), background-color .25s;
}
.cc-range input:active ~ .cc-thumb { transform: scale(1.14); }
.cc-range input:focus-visible ~ .cc-thumb { outline: 3px solid var(--blue); outline-offset: 3px; }
html:not(.js) .cc-range { display: none; }

/* Деньги: чем выше цена, тем светлее и легче дорожка, бегунок светится золотом */
.cc-f.is-money .cc-fill { background: linear-gradient(90deg, #1650dc 0%, #2f74ea 38%, #6fb4f6 72%, #a9dcfc 100%); }
.cc-f.is-money .cc-track { background: linear-gradient(90deg, var(--cloud-2), #eef6ff); }

/* Часы: синий покой, янтарь, после 30 часов жар */
.cc-f.is-hours .cc-track { background: linear-gradient(90deg, var(--cloud-2) 0 71%, #ffe0d6 73%, #ffc9bd 100%); }
.cc-f.is-hours .cc-fill { background: linear-gradient(90deg, #1650dc 0%, #2a6ae6 20%, #6c9fe8 31%, #f6cf6b 41%, #ffb627 50%, #ff8a1e 68%, #f4511e 84%, #e0261b 100%); }
.cc-heat { grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; min-height: 20px; font-size: 14px; font-weight: 550; line-height: 1.3; color: var(--ink-3); transition: color .3s; }
.cc-heat svg { width: 15px; height: 15px; flex: none; fill: currentColor; display: none; }
.cc-f.is-warm output { color: #b45a00; }
.cc-f.is-warm .cc-heat { color: #b45a00; }
.cc-f.is-hot output { color: #d22a1c; }
.cc-f.is-hot .cc-heat { color: #d22a1c; font-weight: 650; }
.cc-f.is-hot .cc-heat svg { display: block; }
.cc-f.is-hot .cc-track { box-shadow: 0 0 0 1px rgba(226, 40, 27, .14), 0 0 calc(var(--g) * 18px) rgba(255, 96, 40, .55); overflow: visible; }
.cc-f.is-hot .cc-fill::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 0 40%, rgba(255, 236, 170, .75) 50%, transparent 60% 100%); background-size: 220% 100%; mix-blend-mode: screen; }

/* Правая часть: небо с результатом */
.cc-res { padding: clamp(20px, 2.6vw, 34px) clamp(20px, 2.8vw, 38px); display: grid; gap: clamp(14px, 1.5vw, 20px); align-content: center; border-radius: calc(var(--r-l) - 8px); }
.cc-figs { display: grid; gap: clamp(10px, 1.2vw, 16px); }
.cc-cap { font-size: 15.5px; line-height: 1.3; color: rgba(255, 255, 255, .9); }
.cc-cap b { color: #fff; font-weight: 700; white-space: nowrap; }
.cc-fig { font: 800 clamp(34px, 3.5vw, 48px)/1 var(--f-d); letter-spacing: -.045em; margin-top: 4px; font-variant-numeric: tabular-nums lining-nums; white-space: nowrap; }
.cc-fig.amt { font-size: clamp(48px, 6.1vw, 86px); margin-top: 2px; }
.cc-fig.tick { animation: tick .35s var(--ease); }
.cc-hourline { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; margin-top: 4px; }
.cc-hourline .cc-fig { margin-top: 0; }
.cc-eq { display: inline-flex; align-items: center; padding: 7px 12px; border-radius: 11px; font: 650 14.5px/1 var(--f-d); letter-spacing: -.005em; white-space: nowrap; background: rgba(255, 255, 255, .16); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .3); font-variant-numeric: tabular-nums lining-nums; }

.cc-cmp { display: grid; gap: 9px; padding-top: clamp(14px, 1.5vw, 20px); background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .4) 0 7px, transparent 7px 15px) top / 100% 1.5px no-repeat; }
.cc-bar { --w: 50%; --bc: #fff; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 5px 12px; }
.cc-bl { font-size: 15px; color: rgba(255, 255, 255, .92); }
.cc-bar b { font: 800 clamp(18px, 1.7vw, 22px)/1 var(--f-d); letter-spacing: -.025em; white-space: nowrap; font-variant-numeric: tabular-nums lining-nums; }
.cc-bt { grid-column: 1 / -1; height: 12px; border-radius: 7px; background: rgba(4, 24, 110, .34); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); }
.cc-bt i { display: block; height: 100%; width: var(--w); min-width: 12px; border-radius: 7px; background: var(--bc); transition: width .45s var(--ease), background-color .3s; }
.cc-bar.is-solo .cc-bt i { box-shadow: 0 0 16px -2px color-mix(in srgb, var(--bc) 80%, transparent); }
.cc-over { font-size: 13.5px; line-height: 1.3; color: rgba(255, 255, 255, .88); margin-top: -3px; }
.cc-over[hidden] { display: none; }
.cc-res .btn { justify-self: start; margin-top: 2px; }
.cc-fine { font-size: 13.5px; line-height: 1.4; color: var(--ink-3); margin-top: 2px; }

@media (prefers-reduced-motion: no-preference) {
  .cc-f.is-hot .cc-thumb { animation: cc-burn 1.5s ease-in-out infinite; }
  .cc-f.is-hot .cc-fill::after { animation: cc-ember 2.2s linear infinite; }
  .cc-f.is-hot .cc-heat svg { animation: cc-flick 1.1s ease-in-out infinite; transform-origin: 50% 90%; }
}
@keyframes cc-burn {
  0%, 100% { box-shadow: 0 0 0 1.5px rgba(11, 26, 74, .12), 0 0 0 calc(var(--g) * 6px) rgba(255, 84, 30, .2), 0 0 calc(var(--g) * 22px) calc(var(--g) * 3px) rgba(255, 96, 30, .6), 0 -6px 16px -4px rgba(255, 176, 40, .7); }
  50% { box-shadow: 0 0 0 1.5px rgba(11, 26, 74, .12), 0 0 0 calc(var(--g) * 10px) rgba(255, 84, 30, .14), 0 0 calc(var(--g) * 34px) calc(var(--g) * 6px) rgba(255, 70, 20, .72), 0 -10px 22px -4px rgba(255, 190, 60, .9); }
}
@keyframes cc-ember { 0% { background-position: 120% 0; } 100% { background-position: -100% 0; } }
@keyframes cc-flick { 0%, 100% { transform: scale(1) rotate(-3deg); } 50% { transform: scale(1.16) rotate(4deg); } }

@media (max-width: 860px) {
  /* Телефон: суммы прилипают сверху, пока двигаешь ползунки; сравнение часов идет после них */
  .cc-calc { grid-template-columns: minmax(0, 1fr); padding: 0; gap: 10px; background: none; box-shadow: none; border-radius: 0; }
  .cc-res { display: contents; }
  .cc-res::before, .cc-res::after { display: none; }
  .cc-capx { display: none; }
  .cc-figs, .cc-cmp { color: #fff; border-radius: var(--r-l); background: radial-gradient(90% 160px at 90% 0%, rgba(143, 208, 251, .45), transparent 72%), linear-gradient(180deg, var(--sky-0), var(--sky-1) 40%, var(--sky-2)); }
  .cc-figs { order: 1; position: sticky; top: 8px; z-index: 6; grid-template-columns: auto minmax(0, 1fr); gap: 4px 18px; align-items: end; padding: 14px 18px 15px; box-shadow: 0 18px 34px -20px rgba(4, 24, 110, .75); }
  .cc-figs .cc-cap { font-size: 13px; }
  .cc-fig { font-size: clamp(22px, 6.4vw, 30px); }
  .cc-fig.amt { font-size: clamp(27px, 8.2vw, 40px); }
  .cc-hourline { margin-top: 3px; }
  .cc-eq { display: none; }
  .cc-month { text-align: right; }
  .cc-ctl { order: 2; padding: 22px 18px 20px; gap: 16px; background: var(--paper); border-radius: var(--r-l); box-shadow: 0 0 0 1px rgba(27, 86, 223, .06), 0 24px 50px -36px rgba(20, 60, 160, .42); }
  .cc-range { --tw: 34px; height: 48px; }
  .cc-range input::-webkit-slider-thumb, .cc-range input::-webkit-slider-runnable-track { height: 48px; }
  .cc-range input::-moz-range-thumb, .cc-range input::-moz-range-track { height: 48px; }
  .cc-track { height: 12px; margin-top: -6px; }
  .cc-cmp { order: 3; padding: 20px 18px; gap: 12px; }
  .cc-res .btn { justify-self: stretch; margin-top: 6px; font-size: 16px; padding-inline: 12px; gap: 8px; white-space: nowrap; }
}
@media (max-width: 380px) {
  .cc-f label { font-size: 16px; }
  .cc-figs { padding-inline: 14px; gap: 4px 12px; }
  .cc-res .btn { font-size: 15.5px; padding-inline: 10px; gap: 6px; }
}

/* ================= Кейсы ================= */
.cc-cases { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(12px, 1.4vw, 18px); }
.cc-case {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-rows: auto auto auto 1fr;
  grid-template-areas: "ph id go" "ph sum sum" "txt txt txt" "rate rate rate";
  column-gap: clamp(14px, 1.6vw, 20px); padding: clamp(18px, 2vw, 26px); transition: transform .35s var(--ease);
}
@media (hover: hover) { .cc-case:hover { transform: translateY(-3px); } }
.cc-ph { grid-area: ph; width: clamp(96px, 9.4vw, 124px); height: clamp(96px, 9.4vw, 124px); object-fit: cover; border-radius: 26px; border: 2.5px solid #fff; box-shadow: 0 18px 30px -18px rgba(3, 18, 96, .8); background: rgba(255, 255, 255, .2); }
.cc-ini { grid-area: ph; width: clamp(96px, 9.4vw, 124px); height: clamp(96px, 9.4vw, 124px); display: grid; place-items: center; border-radius: 26px; border: 2.5px solid #fff; font: 800 44px/1 var(--f-d); background: rgba(255, 255, 255, .2); }
.cc-id { grid-area: id; align-self: start; padding-top: 2px; }
.cc-id h3 { font-size: clamp(22px, 2vw, 27px); line-height: 1.05; }
.cc-id span { display: block; margin-top: 3px; font-size: 15px; color: rgba(255, 255, 255, .88); }
.cc-sum { grid-area: sum; align-self: end; }
.cc-sum .fig { font-size: clamp(40px, 4.3vw, 60px); line-height: .95; letter-spacing: -.05em; white-space: nowrap; }
.cc-sum .fig small { font: 650 .32em/1 var(--f-d); letter-spacing: 0; margin-right: .35em; -webkit-text-fill-color: #fff; color: #fff; vertical-align: .12em; }
.cc-sum .per { margin-top: 6px; font-size: 15px; color: rgba(255, 255, 255, .9); }
.cc-txt { grid-area: txt; margin-top: 16px; font-size: 16.5px; line-height: 1.45; color: rgba(255, 255, 255, .96); text-wrap: pretty; }
.cc-go { grid-area: go; align-self: start; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 5px 13px 5px 14px; border-radius: 14px; font: 650 14.5px/1.2 var(--f-t); color: #fff; text-align: left; cursor: pointer; background: rgba(255, 255, 255, .14); border: 1.5px solid rgba(255, 255, 255, .42); text-decoration: none; transition: background .2s; }
.cc-go .i { width: 17px; height: 17px; flex: none; }
.cc-go span { max-width: 9.6em; }
.cc-id { min-width: max-content; }
.cc-go img { width: 50px; height: 34px; margin-left: -8px; object-fit: cover; object-position: left top; border-radius: 9px; }
@media (hover: hover) { .cc-go:hover { background: rgba(255, 255, 255, .26); } }
.cc-rate { grid-area: rate; align-self: end; margin-top: 16px; display: grid; grid-template-columns: auto minmax(0, 1fr); border-radius: 18px; background: rgba(8, 36, 140, .3); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .2); }
.cc-rate > div { padding: 12px clamp(14px, 1.5vw, 18px) 13px; }
.cc-rate > div + div { background: repeating-linear-gradient(180deg, rgba(255, 255, 255, .34) 0 6px, transparent 6px 12px) left / 1.5px 100% no-repeat; }
.cc-rate dt { font-size: 13.5px; color: rgba(255, 255, 255, .84); }
.cc-rate dd { display: flex; align-items: center; gap: 7px; margin-top: 4px; font: 800 clamp(20px, 1.9vw, 24px)/1.1 var(--f-d); letter-spacing: -.03em; font-variant-numeric: lining-nums; white-space: nowrap; }
.cc-rate dd s { font-weight: 600; opacity: .72; text-decoration-thickness: 2px; }
.cc-rate dd .i { width: 17px; height: 17px; color: var(--amber); stroke-width: 2.6; }
.cc-rate dd.txt { display: block; font: 550 14.5px/1.3 var(--f-t); letter-spacing: 0; white-space: normal; text-wrap: balance; }
@media (prefers-reduced-motion: no-preference) {
  .js .cc-case[data-reveal] { opacity: 0; transform: translateY(26px); }
  .js .cc-case[data-reveal].is-in { opacity: 1; transform: none; transition: opacity .8s var(--ease), transform 1s var(--ease); }
  .js .cc-case[data-reveal].is-in:nth-child(even) { transition-delay: .09s; }
  .js .cc-case[data-reveal] > * { opacity: 1; transform: none; }
}
@media (max-width: 1020px) {
  .cc-case { grid-template-areas: "ph id id" "ph sum sum" "txt txt txt" "rate rate rate" "go go go"; }
  .cc-go { justify-self: start; margin-top: 12px; }
}
@media (max-width: 760px) {
  .cc-cases { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 420px) {
  .cc-case { padding: 16px; column-gap: 14px; }
  .cc-ph, .cc-ini { width: 88px; height: 88px; border-radius: 22px; }
  .cc-sum .fig { font-size: clamp(34px, 10.4vw, 42px); }
  .cc-sum .fig small { display: block; font-size: 14px; margin: 0 0 5px; }
  .cc-rate { grid-template-columns: minmax(0, 1fr); }
  .cc-rate > div + div { background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .34) 0 6px, transparent 6px 12px) top / 100% 1.5px no-repeat; }
  .cc-go { justify-self: stretch; }
}

/* ================= История Влады: карточка «было и стало» ================= */
.cc-vl { padding: clamp(20px, 2.4vw, 30px); box-shadow: 0 40px 80px -44px rgba(12, 59, 196, .75); }
.cc-vl-top { display: flex; align-items: center; gap: 14px; }
.cc-vl-top img { width: 60px; height: 60px; flex: none; object-fit: cover; border-radius: 18px; border: 2px solid #fff; }
.cc-vl-name { font: 800 clamp(20px, 1.9vw, 24px)/1.1 var(--f-d); letter-spacing: -.03em; }
.cc-vl-sub { margin-top: 3px; font-size: 14.5px; color: rgba(255, 255, 255, .9); }
.cc-vl-head, .cc-vl-row { display: grid; grid-template-columns: minmax(0, 1fr) 20px minmax(0, 1.18fr); column-gap: 8px; }
.cc-vl-head { margin-top: 18px; font: 750 12.5px/1 var(--f-d); letter-spacing: .09em; text-transform: uppercase; color: rgba(255, 255, 255, .82); }
.cc-vl-head span:last-child { grid-column: 3; color: var(--amber-hi); }
.cc-vl-rows { display: grid; margin-top: 10px; }
.cc-vl-rows li { padding: 13px 0 14px; background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .36) 0 7px, transparent 7px 15px) top / 100% 1.5px no-repeat; }
.cc-vl-k { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 14.5px; color: rgba(255, 255, 255, .92); }
.cc-vl-k em { font: 650 12.5px/1 var(--f-d); font-style: normal; padding: 5px 9px; border-radius: 8px; white-space: nowrap; background: rgba(255, 255, 255, .16); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .26); }
.cc-vl-row { align-items: end; margin-top: 8px; }
.cc-vl-row > .i { align-self: center; width: 20px; height: 20px; color: var(--amber); stroke-width: 2.6; margin-bottom: 14px; }
.cc-vl-row b { display: block; font: 800 clamp(22px, 2.1vw, 28px)/1 var(--f-d); letter-spacing: -.04em; white-space: nowrap; font-variant-numeric: lining-nums; }
.cc-vl-row .was b { color: rgba(255, 255, 255, .86); font-weight: 700; }
.cc-vl-row .now b { font-size: clamp(27px, 2.8vw, 38px); }
.cc-vl-row small { display: block; margin-top: 5px; font-size: 13px; line-height: 1.2; color: rgba(255, 255, 255, .84); }
.cc-vl-note { padding-top: 13px; font-size: 13.5px; line-height: 1.4; color: rgba(255, 255, 255, .88); background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .36) 0 7px, transparent 7px 15px) top / 100% 1.5px no-repeat; }
@media (max-width: 860px) {
  .cc-vl { max-width: 520px; margin-inline: auto; }
}

/* Правая лента: подпись «открыть крупнее» на скриншотах */
.cc-open { position: absolute; left: 10px; bottom: 10px; z-index: 1; padding: 6px 10px; border-radius: 9px; font: 650 12.5px/1 var(--f-d); color: #fff; background: rgba(11, 26, 74, .78); pointer-events: none; }

/* 15.11: от 1021 до 1200 px кнопки «Ее история» и «Ее сообщение» наезжали на имя и предмет. Там они уходят вниз карточки, как на планшете. */
@media (min-width: 1021px) and (max-width: 1200px) {
  .cc-case { grid-template-areas: "ph id id" "ph sum sum" "txt txt txt" "rate rate rate" "go go go"; }
  .cc-go { justify-self: start; margin-top: 12px; }
}

/* Кейсы на светлом экране: синими остаются сами карточки, а не вся секция (иначе три синих экрана подряд). */
#cases:not(.sky) .cc-case { color: #fff; border: 0; border-radius: var(--r-l); background: radial-gradient(90% 180px at 88% 0%, rgba(143, 208, 251, .42), transparent 72%), linear-gradient(180deg, var(--sky-0), var(--sky-1) 42%, var(--sky-2)); box-shadow: 0 30px 60px -34px rgba(10, 40, 150, .75); -webkit-backdrop-filter: none; backdrop-filter: none; }
#cases:not(.sky) .cc-case h3 { color: #fff; }
