/* ============================================================================
   TORGSOFT — options.css
   Стилі сторінок опцій /options/*. Підключати ПІСЛЯ main.css.
   Версія 1.7

   ПІСЛЯ ОНОВЛЕННЯ ФАЙЛУ ОБОВ'ЯЗКОВО змінити версію в <link ... options.css?v=1.7>,
   інакше Google PageSpeed віддасть стару закешовану версію (саме через це
   правки можуть «не застосовуватися»).

   ВАЖЛИВО (специфічність):
   - Контент лежить у <article class="content m_cause__columns--full">, тож
     main.css застосовує до наших елементів правила .m_cause__columns--full div
     (width:100%; clear:both; margin-bottom). Щоб їх перекрити:
       * reset нижче має селектори рівня «.ts-option div / p / …» (0,1,1) —
         вони б'ють main.css за рахунком порядку підключення (options.css іде ПІСЛЯ);
       * УСІ компоненти мають префікс «.ts-option .ts-option__…» (0,2,0) —
         вони б'ють і reset, і main.css, тож padding/margin компонентів завжди діють.
   - reset НЕ обнуляє padding (main.css його для div не задає), щоб не з'їдати
     внутрішні відступи карток/комірок.
   - У шрифті Rubik підключені 300/400/500/700/900 — 800 не використовуємо.
   ========================================================================== */

/* ---- Lead-summary (обов'язковий перший блок, він поза .ts-option) -------- */
.m_cause__columns--full > .lead-summary,
.m_cause__columns--left > .lead-summary,
.lead-summary {
  width: 100%;
  clear: both;
  margin: 0 0 30px;
  padding: 24px 26px;
  border-left: 6px solid #FAC739;
  border-radius: 0 14px 14px 0;
  background: #FFF9DF;
  box-shadow: 0 8px 24px rgba(40, 40, 43, 0.06);
}
.m_cause__columns--full > .lead-summary p,
.m_cause__columns--left > .lead-summary p,
.lead-summary p {
  width: auto;
  clear: none;
  margin: 0 0 12px;
  font-family: "Rubik", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.58;
  color: #111827;
}
.lead-summary p:last-child { margin-bottom: 0; }
.lead-summary .lead-definition { font-size: 19px; }

/* ---- Root + токени ------------------------------------------------------ */
.ts-option {
  --ts-red: #D30000;
  --ts-red-dark: #B9310F;
  --ts-terracotta: #D43911;
  --ts-yellow: #FAC739;
  --ts-yellow-light: #FFED7A;
  --ts-yellow-pale: #FFF7D1;
  --ts-gray: #F0F0F0;
  --ts-gray-soft: #F8F8F8;
  --ts-border: #E7E7E7;
  --ts-graphite: #28282B;
  --ts-text: #111827;
  --ts-muted: #6B7280;
  --ts-white: #FFFFFF;
  --ts-link: #2196F3;
  --ts-shadow: 0 8px 28px rgba(40, 40, 43, 0.08);

  width: 100%;
  clear: both;
  margin: 0;
  font-family: "Rubik", "Segoe UI", sans-serif;
  color: var(--ts-text);
  font-size: 18px;
  line-height: 1.55;
}
.ts-option, .ts-option * { box-sizing: border-box; }

/* ---- RESET: гасимо лише шкідливі властивості main.css (НЕ чіпаємо padding) */
.ts-option div {
  width: auto;
  clear: none;
  float: none;
  margin: 0;
  font-family: "Rubik", "Segoe UI", sans-serif;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
}
.ts-option p {
  width: auto;
  clear: none;
  float: none;
  margin: 0 0 16px;
  font-family: "Rubik", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.58;
  color: var(--ts-text);
}
.ts-option p:last-child { margin-bottom: 0; }
.ts-option span {
  font-family: "Rubik", "Segoe UI", sans-serif;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
}
.ts-option a {
  color: var(--ts-link);
  font-weight: 500;
  text-decoration: none;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}
.ts-option a:hover { text-decoration: underline; }

.ts-option h2 { margin: 36px 0 18px; font-family: "Rubik", "Segoe UI", sans-serif; font-size: 28px; line-height: 1.25; font-weight: 700; color: var(--ts-graphite); }
.ts-option h3 { margin: 28px 0 14px; font-family: "Rubik", "Segoe UI", sans-serif; font-size: 22px; line-height: 1.3; font-weight: 700; color: var(--ts-graphite); }
.ts-option h4 { margin: 20px 0 10px; font-family: "Rubik", "Segoe UI", sans-serif; font-size: 18px; line-height: 1.35; font-weight: 700; color: var(--ts-graphite); }

/* Відступ НАД заголовками задається самим заголовком (не залежить від попереднього
   елемента) — так зазори над H2/H3/H4 однакові по всій сторінці.
   Виняток: заголовки всередині рамок і найперший елемент — без верхнього відступу,
   щоб не відліплювалися від верхнього краю свого блоку. */
.ts-option > :first-child,
.ts-option .ts-option__hero h2,
.ts-option .ts-option__cta h2, .ts-option .ts-option__cta h3,
.ts-option .ts-option__note h2, .ts-option .ts-option__note h3, .ts-option .ts-option__note h4,
.ts-option .ts-option__card h3, .ts-option .ts-option__card h4,
.ts-option .ts-option__compare-card h4,
.ts-option .ts-option__step h3, .ts-option .ts-option__step h4,
.ts-option .ts-option__price h3 { margin-top: 0; }

/* ---- Списки ------------------------------------------------------------- */
.ts-option ul, .ts-option ol { width: auto; float: none; clear: none; margin: 16px 0 24px; padding: 0 0 0 4px; list-style: none; }
.ts-option ul:last-child, .ts-option ol:last-child { margin-bottom: 0; }
/* Списки всередині рамок (плашки note) не туляться до лівої межі коробки */
.ts-option .ts-option__note ul, .ts-option .ts-option__note ol { padding-left: 14px; }
.ts-option ul li, .ts-option ol li {
  position: relative; width: auto; clear: none; float: none;
  margin: 0 0 10px; padding: 0 0 0 24px; font-size: 17px; line-height: 1.55; color: var(--ts-text);
}
.ts-option ul li::before {
  content: ""; position: absolute; left: 2px; top: 0.7em;
  width: 8px; height: 8px; border-radius: 50%; background: var(--ts-yellow);
}
.ts-option ol { counter-reset: ts-list; }
.ts-option ol li { padding-left: 34px; }
.ts-option ol li::before {
  counter-increment: ts-list; content: counter(ts-list);
  position: absolute; left: 0; top: 2px;
  display: flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 7px;
  background: var(--ts-yellow); color: var(--ts-graphite);
  font-size: 12px; line-height: 1; font-weight: 700;
}
.ts-option ul li::after { display: none !important; } /* гасимо жовту крапку main.css */

/* ======================= КОМПОНЕНТИ (префікс .ts-option) ================= */

/* Секції */
.ts-option .ts-option__section { width: 100%; margin: 0 0 48px; }
.ts-option .ts-option__section--compact { margin-bottom: 30px; }

/* ===== Рівний вертикальний ритм між верхньорівневими блоками =====
   Через float на .m_cause__columns--full звичайні margin між секціями схлопуються
   й зникають (саме тому відступ над заголовком після списку був майже нульовим).
   Робимо кожен блок окремим контекстом (display:flow-root) — його внутрішні відступи
   більше не «витікають», а відстань між блоками задаємо зверху, однакову для всіх. */
.ts-option > .ts-option__hero,
.ts-option > .ts-option__section,
.ts-option > .ts-option__cta { display: flow-root; margin-top: 40px; margin-bottom: 0; }
.ts-option > :first-child { margin-top: 0; }       /* перший блок сторінки — без відступу зверху */
.ts-option > * > :first-child { margin-top: 0; }   /* перший елемент усередині блоку (H2 секції) — без подвоєння */

.ts-option .ts-option__eyebrow {
  display: inline-flex; align-items: center; min-height: 28px;
  margin: 0 0 10px; padding: 4px 12px; border-radius: 999px;
  background: var(--ts-yellow-pale); color: var(--ts-terracotta);
  font-size: 12px; line-height: 1.3; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
}
.ts-option .ts-option__subtext { max-width: 820px; color: var(--ts-muted); }
.ts-option .ts-option__muted { color: var(--ts-muted); }
.ts-option .ts-option__center { text-align: center; }
.ts-option .ts-option__narrow { max-width: 820px; }

/* Hero */
.ts-option .ts-option__hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.85fr);
  gap: 28px; align-items: center;
  width: 100%; margin: 0 0 48px; padding: 30px;
  border: 1px solid #F2E6B0; border-radius: 20px;
  background: linear-gradient(180deg, #FFFDF3 0%, #FFFFFF 78%);
  box-shadow: var(--ts-shadow);
}
.ts-option .ts-option__hero h2 { margin-bottom: 14px; font-size: 30px; }
.ts-option .ts-option__hero-media { display: flex; align-items: center; justify-content: center; }
.ts-option .ts-option__hero-media img,
.ts-option .ts-option__image { display: block; max-width: 100%; height: auto; border-radius: 14px; margin: 0 auto; }
.ts-option .ts-option__media { width: 100%; margin: 8px 0 48px; border-radius: 16px; overflow: hidden; background: var(--ts-gray-soft); }
.ts-option .ts-option__media iframe { display: block; width: 100%; height: 166px; border: 0; }
		
/* Відео 16:9 (YouTube) — щоб не сплющувалось */
.ts-option .ts-option__media--video { background: transparent; }
.ts-option .ts-option__media--video iframe { height: auto; aspect-ratio: 16 / 9; }

/* Пілюлі / бейджі */
.ts-option .ts-option__pills { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 0; }
.ts-option .ts-option__pill {
  display: inline-flex; align-items: center; min-height: 34px;
  padding: 6px 14px; border: 1px solid #EADFAE; border-radius: 999px;
  background: var(--ts-white); color: var(--ts-graphite);
  font-size: 14px; line-height: 1.25; font-weight: 500;
}
.ts-option .ts-option__badge {
  display: inline-flex; align-items: center; justify-content: center;
  align-self: flex-start; min-width: 46px; height: 40px;
  margin: 0 0 14px; padding: 0 12px; border-radius: 12px;
  background: var(--ts-yellow-light); color: var(--ts-graphite);
  font-size: 12px; line-height: 1; font-weight: 700; letter-spacing: 0.04em;
}

/* Кнопки */
.ts-option .ts-option__actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin: 22px 0 0; }
.ts-option .demo_but,
.ts-option .ts-option__btn {
  display: inline-flex !important; align-items: center !important; justify-content: center !important;
  width: auto !important; min-width: 200px; max-width: 100%; min-height: 50px;
  padding: 0 28px !important; border: 0; border-radius: 25px; float: none !important;
  background: var(--ts-terracotta) !important; color: var(--ts-white) !important;
  font-family: "Rubik", "Segoe UI", sans-serif !important;
  font-size: 16px !important; line-height: 1.2 !important; font-weight: 700 !important;
  text-align: center; text-decoration: none !important; white-space: normal;
  transition: background-color 0.2s ease;
}
.ts-option .demo_but:hover,
.ts-option .ts-option__btn:hover { background: var(--ts-red-dark) !important; color: var(--ts-white) !important; text-decoration: none !important; }
.ts-option .demo_but__yellow,
.ts-option .ts-option__btn--yellow { background: var(--ts-yellow) !important; color: var(--ts-graphite) !important; }
.ts-option .demo_but__yellow:hover,
.ts-option .ts-option__btn--yellow:hover { background: #F9CD54 !important; color: var(--ts-graphite) !important; }

/* Картки та сітки */
.ts-option .ts-option__grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px; width: 100%; margin: 18px 0 30px;
}
.ts-option .ts-option__grid--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ts-option .ts-option__grid--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ts-option .ts-option__card {
  display: flex; flex-direction: column; min-width: 0; height: 100%; padding: 22px;
  border: 1px solid var(--ts-border); border-radius: 16px; background: var(--ts-white);
  box-shadow: 0 2px 14px rgba(40, 40, 43, 0.04); transition: border-color .2s, box-shadow .2s;
}
.ts-option .ts-option__card:hover { border-color: var(--ts-yellow); box-shadow: var(--ts-shadow); }
.ts-option .ts-option__card p { font-size: 16px; line-height: 1.55; }
.ts-option .ts-option__card--warning { border-left: 5px solid #E3B0AB; }
.ts-option .ts-option__card--success { border-left: 5px solid var(--ts-yellow); }

/* Таблиця можливостей (без <table>) */
.ts-option .ts-option__features {
  width: 100%; margin: 18px 0 30px; border: 1px solid var(--ts-border);
  border-radius: 16px; overflow: hidden; background: var(--ts-white);
}
.ts-option .ts-option__features-head,
.ts-option .ts-option__features-row { display: grid; grid-template-columns: 1.1fr 1.4fr 1.1fr; align-items: stretch; }
.ts-option .ts-option__features-head { background: var(--ts-graphite); }
.ts-option .ts-option__features-row:nth-child(even) { background: #FFFCF5; }
.ts-option .ts-option__features-cell {
  min-width: 0; padding: 14px 16px; border-top: 1px solid var(--ts-border);
  border-right: 1px solid var(--ts-border); font-size: 15px; line-height: 1.45;
  color: var(--ts-text); overflow-wrap: anywhere;
}
.ts-option .ts-option__features-cell:last-child { border-right: 0; }
.ts-option .ts-option__features-head .ts-option__features-cell { border-top: 0; color: var(--ts-white); font-weight: 700; }
.ts-option .ts-option__features-label {
  display: none; margin: 0 0 4px; color: var(--ts-muted); font-size: 12px;
  line-height: 1.3; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
}

/* Порівняння До / Після */
.ts-option .ts-option__compare { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; width: 100%; margin: 18px 0 30px; }
.ts-option .ts-option__compare-card { padding: 24px; border: 1px solid var(--ts-border); border-radius: 16px; background: var(--ts-white); }
.ts-option .ts-option__compare-card--before { background: #FFF4F2; border-left: 5px solid #DCA29A; }
.ts-option .ts-option__compare-card--after { background: #FFFBEA; border-left: 5px solid var(--ts-yellow); }
.ts-option .ts-option__compare-card--before h4 { color: #B23A2E; }

/* Кроки */
.ts-option .ts-option__steps { display: grid; grid-template-columns: 1fr; gap: 14px; width: 100%; margin: 18px 0 30px; counter-reset: ts-step; }
.ts-option .ts-option__step {
  position: relative; min-height: 72px; padding: 18px 22px 18px 78px;
  border: 1px solid var(--ts-border); border-radius: 16px; background: var(--ts-white);
}
.ts-option .ts-option__step::before {
  counter-increment: ts-step; content: counter(ts-step);
  position: absolute; left: 20px; top: 18px;
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, #FFE200 0%, #FF8300 100%);
  color: var(--ts-graphite); font-size: 18px; line-height: 1; font-weight: 700;
}
.ts-option .ts-option__step p, .ts-option .ts-option__step div { font-size: 16px; line-height: 1.55; }

/* Плашки (note) */
.ts-option .ts-option__note {
  width: 100%; margin: 18px 0 30px; padding: 20px 22px;
  border-radius: 16px; border-left: 5px solid var(--ts-yellow); background: var(--ts-yellow-pale);
}
.ts-option .ts-option__note--gray { border-left-color: var(--ts-graphite); background: var(--ts-gray-soft); }
.ts-option .ts-option__note--red { border-left-color: var(--ts-red); background: #FFF0F0; }

/* Темна CTA-плашка */
.ts-option .ts-option__cta {
  width: 100%; margin: 14px 0 48px; padding: 40px 30px; border-radius: 20px;
  background: var(--ts-graphite); text-align: center;
}
.ts-option .ts-option__cta h2,
.ts-option .ts-option__cta h3 { color: var(--ts-white); margin-bottom: 10px; }
.ts-option .ts-option__cta p { color: rgba(255,255,255,0.82); max-width: 640px; margin: 0 auto 22px; }
.ts-option .ts-option__cta .ts-option__actions { justify-content: center; margin: 0; }

/* Прайс */
.ts-option .ts-option__price {
  display: flow-root;
  width: 100%; max-width: 620px; margin: 18px 0 30px; padding: 26px;
  border: 1px solid var(--ts-border); border-radius: 18px; background: var(--ts-white); box-shadow: var(--ts-shadow);
}
.ts-option .ts-option__price ul { margin: 4px 0 20px; }
.ts-option .ts-option__price .ts-option__actions { margin-top: 6px; width: 100%; clear: both; }
/* кнопки прайсу завжди всередині картки: тягнуться й переносяться, не вилазять праворуч */
.ts-option .ts-option__price .demo_but,
.ts-option .ts-option__price .ts-option__btn {
  float: none !important;
  min-width: 0 !important;
  flex: 1 1 220px;
  max-width: 100%;
}
.ts-option .ts-option__price-title { margin: 0 0 8px; color: var(--ts-muted); font-size: 15px; line-height: 1.4; }
.ts-option .ts-option__price-value { margin: 0 0 18px; color: var(--ts-graphite); font-size: 42px; line-height: 1.05; font-weight: 700; }
.ts-option .ts-option__price-value small { font-size: 22px; font-weight: 700; }

/* FAQ */
.ts-option .ts-option__faq { display: grid; gap: 12px; width: 100%; margin: 18px 0 0; }
.ts-option .ts-option__faq details {
  width: 100%; clear: none; margin: 0; padding: 0;
  border: 1px solid var(--ts-border); border-radius: 14px; background: var(--ts-white); overflow: hidden;
}
.ts-option .ts-option__faq summary {
  position: relative; display: block; cursor: pointer; padding: 17px 54px 17px 20px;
  color: var(--ts-graphite); font-size: 17px; line-height: 1.35; font-weight: 700; list-style: none;
}
.ts-option .ts-option__faq summary::-webkit-details-marker { display: none; }
.ts-option .ts-option__faq summary::after {
  content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%);
  color: var(--ts-terracotta); font-size: 26px; line-height: 1; font-weight: 400;
}
.ts-option .ts-option__faq details[open] summary::after { content: "\2212"; }
.ts-option .ts-option__faq details p { padding: 0 20px 18px; font-size: 16px; line-height: 1.55; }

/* ======================= Адаптив ======================= */
@media (max-width: 900px) {
  .ts-option .ts-option__hero { grid-template-columns: 1fr; padding: 24px; }
  .ts-option .ts-option__hero-media { order: -1; }
  .ts-option .ts-option__grid--two,
  .ts-option .ts-option__grid--three,
  .ts-option .ts-option__compare { grid-template-columns: 1fr; }

  .ts-option .ts-option__features-head { display: none; }
  .ts-option .ts-option__features-row { display: block; padding: 14px 16px; border-top: 1px solid var(--ts-border); }
  .ts-option .ts-option__features-row:first-child { border-top: 0; }
  .ts-option .ts-option__features-cell { border: 0; padding: 6px 0; }
  .ts-option .ts-option__features-label { display: block; }
}

@media (max-width: 680px) {
  .m_cause__columns--full > .lead-summary,
  .m_cause__columns--left > .lead-summary,
  .lead-summary { padding: 18px; border-radius: 0 12px 12px 0; }
  .m_cause__columns--full > .lead-summary p,
  .m_cause__columns--left > .lead-summary p,
  .lead-summary p,
  .lead-summary .lead-definition { font-size: 16px; line-height: 1.55; }

  .ts-option { font-size: 16px; }
  .ts-option h2 { font-size: 24px; }
  .ts-option h3 { font-size: 20px; }
  .ts-option p { font-size: 16px; line-height: 1.55; }

  .ts-option .ts-option__hero { gap: 20px; padding: 20px; border-radius: 16px; }
  .ts-option .ts-option__hero h2 { font-size: 24px; }
  .ts-option .ts-option__cta { padding: 30px 20px; }
  .ts-option .ts-option__section { margin-bottom: 34px; }
  .ts-option .ts-option__grid { grid-template-columns: 1fr; gap: 14px; }
  .ts-option .ts-option__card { padding: 18px; }
  .ts-option .ts-option__actions { gap: 10px; }
  .ts-option .demo_but,
  .ts-option .ts-option__btn { width: 100% !important; min-width: 0; min-height: 48px; padding: 0 20px !important; font-size: 15px !important; }
  .ts-option .ts-option__pill { font-size: 13px; }
  .ts-option .ts-option__step { padding: 16px 16px 16px 64px; }
  .ts-option .ts-option__step::before { left: 16px; width: 34px; height: 34px; border-radius: 10px; font-size: 16px; }
  .ts-option .ts-option__price { padding: 22px 18px; }
  .ts-option .ts-option__price-value { font-size: 34px; }
}
