/* cases-by-model v2
 * Changes vs v1 (client feedback 21.05.2026):
 *  - neutral GRAY outline instead of blue
 *  - no underline on CTA (override .editor a)
 *  - centered on desktop (was 50% left-aligned)
 *  - positive top spacing before button (was -4px)
 *  - model name kept whole via .cbm-cta__model (nowrap)
 *  - optional secondary link .cbm-cta-secondary
 */

.cbm-section {
  margin: 32px 0;
}

/* Mobile-first: full-width button, matches single-column case-slider layout (≤600px) */
.cbm-cta-row {
  margin: 12px 0 28px;
  width: 100%;
}

.cbm-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  font-size: 14px;
  font-weight: 600;
  color: #5a6573 !important;
  text-decoration: none !important;
  padding: 12px 16px;
  border: 1.5px solid #c8cdd4;
  border-radius: 8px;
  background: #fff;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  line-height: 1.3;
  text-align: center;
  box-sizing: border-box;
}

.cbm-cta:hover {
  background: #f2f4f7;
  border-color: #8a94a4;
  color: #3a424d !important;
  text-decoration: none !important;
}

/* Keep car model designation whole on its own line */
.cbm-cta__model {
  white-space: nowrap;
}

.cbm-cta svg {
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.cbm-cta:hover svg {
  transform: translateX(3px);
}

.cbm-cta--placeholder {
  color: #8a94a4 !important;
  border-color: #c8cdd4;
  pointer-events: none;
  cursor: default;
}

/* Optional secondary link (e.g. "Лендинг ТО Mercedes") under the main CTA */
.cbm-cta-secondary {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
  font-weight: 500;
  color: #5a6573 !important;
  text-decoration: underline !important;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}

.cbm-cta-secondary:hover {
  color: #3a424d !important;
}

/* Desktop: center the CTA (was 50% width, left-aligned) */
@media (min-width: 601px) {
  .cbm-cta-row {
    width: 100%;
    max-width: none;
    margin: 16px 0 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .cbm-cta {
    width: auto;
    max-width: 560px;
    font-size: 15px;
    padding: 12px 18px;
  }
}
