/**
 * Страница «Сервис» — секции по макету Mindray Сервис.dc.html
 */

.service-page {
  font-family: var(--font-text);
  color: var(--text-body);
  background: var(--surface-card);
}

.service-page__main {
  box-sizing: border-box;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 28px var(--container-pad) 88px;
}

.service-section__title {
  margin: 0 0 36px;
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: var(--fw-bold);
  line-height: var(--lh-heading);
  letter-spacing: var(--ls-tight);
  color: var(--text-strong);
}

.service-section__subtitle {
  margin: -20px 0 36px;
  max-width: 640px;
  font-size: 14px;
  line-height: var(--lh-relaxed);
  color: var(--text-muted);
}

/* Hero */
.service-hero {
  position: relative;
  display: flex;
  overflow: hidden;
  min-height: 460px;
  margin-bottom: 72px;
  border-radius: var(--radius-lg);
}

.service-hero__bg {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
      rgba(12, 16, 20, 0.82) 0%,
      rgba(12, 16, 20, 0.64) 46%,
      rgba(12, 16, 20, 0.24) 100%);
}

.service-hero__content {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 720px;
  padding: 64px 52px;
}

.service-hero__title {
  margin: 0 0 20px;
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: var(--fw-bold);
  line-height: 1.14;
  letter-spacing: var(--ls-tight);
  color: #fff;
  text-wrap: balance;
}

.service-hero__subtitle {
  max-width: 520px;
  margin: 0 0 34px;
  font-size: 18px;
  line-height: var(--lh-relaxed);
  color: rgba(255, 255, 255, 0.82);
}

.service-hero__cta.ds-btn--lg {
  min-height: 52px;
  padding: 14px 28px;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-tight);
}

/* Stats */
.service-stats {
  margin-bottom: 88px;
}

.service-stats__grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}

.service-stats__item {
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: center;
}

.service-stats__value {
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: var(--fw-bold);
  line-height: 1;
  letter-spacing: var(--ls-tight);
  color: var(--color-primary);
}

.service-stats__label {
  font-size: 14px;
  line-height: var(--lh-relaxed);
  color: var(--text-muted);
}

/* Advantages */
.service-advantages {
  margin-bottom: 88px;
}

.service-advantages__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.service-advantages__card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  background: var(--surface-sunken);
}

.service-advantages__media {
  height: 240px;
  background: var(--surface-sunken);
}

.service-advantages__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-advantages__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 14px;
  padding: 30px 32px;
}

.service-advantages__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: var(--fw-bold);
  line-height: 1.2;
  letter-spacing: var(--ls-tight);
  color: var(--text-strong);
}

.service-advantages__text {
  margin: 0;
  font-size: 14px;
  line-height: var(--lh-relaxed);
  color: var(--text-strong);
}

/* CTA light */
.service-cta-light {
  margin-bottom: 88px;
}

.service-cta-light__inner {
  display: grid;
  grid-template-columns: minmax(0, 620px) auto;
  gap: 40px;
  align-items: center;
  padding: 52px 56px;
  border-radius: var(--radius-lg);
  background: var(--surface-sunken);
}

.service-cta-light__title {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: var(--fw-bold);
  line-height: var(--lh-heading);
  letter-spacing: var(--ls-tight);
  color: var(--color-primary);
}

.service-cta-light__text {
  max-width: 560px;
  margin: 0;
  font-size: 17px;
  line-height: var(--lh-relaxed);
  color: var(--text-muted);
}

.service-cta-light__action {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: stretch;
  min-width: 260px;
}

.service-cta-light__btn {
  width: 100%;
  min-height: 56px;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-tight);
}

/* Directions */
.service-directions {
  margin-bottom: 88px;
}

.service-directions__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.service-directions__tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  box-sizing: border-box;
  width: 100%;
  aspect-ratio: 1 / 1;
  padding: 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface-sunken);
  text-align: center;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-standard),
    box-shadow var(--dur-fast) var(--ease-standard),
    border-color var(--dur-fast) var(--ease-standard);
}

.service-directions__tile:hover {
  border-color: var(--border-subtle);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.service-directions__tile:focus-visible {
  outline: 2px solid var(--border-focus);
  outline-offset: 3px;
}

.service-directions__tile:hover .service-directions__title {
  color: var(--cyan-500, var(--color-primary));
}

.service-directions__tile:focus-visible .service-directions__title {
  color: var(--color-primary);
}

.service-directions__title {
  flex: 0 0 auto;
  height: 32px;
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: var(--fw-bold);
  line-height: 1.2;
  letter-spacing: var(--ls-tight);
  color: var(--text-strong);
  text-wrap: pretty;
  transition: color var(--dur-fast) var(--ease-standard);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.service-directions__media {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 0;
  overflow: hidden;
}

.service-directions__media img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 100%;
  object-fit: contain;
  mix-blend-mode: multiply;
  transform: scale(1);
  transition: transform var(--dur-base) var(--ease-standard);
}

.service-directions__tile:hover .service-directions__media img,
.service-directions__tile:focus-visible .service-directions__media img {
  transform: scale(1.03);
}

/* Cases */
.service-cases {
  margin-bottom: 88px;
}

.service-cases__carousel {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 48px;
  gap: 24px;
  align-items: center;
}

.service-cases__swiper {
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

.service-cases__swiper .swiper-wrapper {
  height: auto;
  box-sizing: border-box;
}

.service-cases__card.swiper-slide {
  display: flex;
  flex-direction: column;
  height: 425px;
  max-height: 425px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  background: var(--surface-sunken);
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: border-color var(--dur-base) var(--ease-standard),
    box-shadow var(--dur-base) var(--ease-standard);
  box-sizing: border-box;
}

.service-cases__card.swiper-slide:hover,
.service-cases__card.swiper-slide:focus-visible {
  box-shadow: var(--shadow-md);
  outline: none;
}

.service-cases__media {
  flex: 2 1 0;
  min-height: 0;
  overflow: hidden;
  background: var(--surface-sunken);
}

.service-cases__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-cases__body {
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
  overflow: hidden;
  padding: 12px 26px;
  background: var(--surface-sunken);
}

.service-cases__title {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  margin: 0;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: var(--fw-bold);
  line-height: 1.2;
  letter-spacing: var(--ls-tight);
  color: var(--text-strong);
}

.service-cases__excerpt {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  margin: 0;
  font-size: 14px;
  line-height: var(--lh-relaxed);
  color: var(--text-strong);
}

.service-cases__nav {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: 1.5px solid var(--border-subtle);
  border-radius: 50%;
  background: var(--surface-sunken);
  color: var(--text-strong);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: border-color var(--dur-base) var(--ease-standard),
    color var(--dur-base) var(--ease-standard);
}

.service-cases__nav:hover,
.service-cases__nav:focus-visible {
  border-color: var(--color-primary);
  color: var(--color-primary);
  outline: none;
}

.service-cases__footer {
  display: flex;
  justify-content: center;
  margin-top: 32px;
}

.service-cases__all-link {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-tight);
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-standard);
}

.service-cases__all-link-arrow {
  font-size: 18px;
  line-height: 1;
}

.service-cases__all-link:hover {
  color: var(--color-primary-hover);
}

/* Form */
.service-form-section {
  margin-bottom: 88px;
}

.service-form--dark {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: #14181c;
  color: #fff;
}

.service-form--inline {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 48px;
  align-items: center;
  padding: 48px 52px;
}

.service-form--inline::before,
.service-form--inline::after,
.service-form-modal__dialog::before,
.service-form-modal__dialog::after {
  position: absolute;
  z-index: 0;
  pointer-events: none;
  content: '';
}

.service-form--inline::before,
.service-form-modal__dialog::before {
  top: -80px;
  right: -80px;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(200, 0, 10, 0.34), transparent 68%);
}

.service-form--inline::after,
.service-form-modal__dialog::after {
  bottom: -140px;
  left: -140px;
  width: 460px;
  height: 460px;
  background: radial-gradient(circle, rgba(200, 0, 10, 0.34), transparent 68%);
}

.service-form__header {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.service-form__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: var(--fw-bold);
  line-height: 1.12;
  letter-spacing: var(--ls-tight);
  color: #fff;
}

.service-form__subtitle {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.6);
}

.service-form__fields {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.service-form__row--split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.service-form__input,
.service-form__textarea {
  box-sizing: border-box;
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-family: var(--font-text);
  font-size: 16px;
  line-height: 1.4;
  outline: none;
  transition: border-color 160ms ease, background 160ms ease;
  -webkit-appearance: none;
  appearance: none;
}

.service-form--dark .service-form__input[type='text'],
.service-form--dark .service-form__input[type='tel'],
.service-form--dark .service-form__textarea {
  height: auto;
  margin-bottom: 0;
  border-color: rgba(255, 255, 255, 0.16);
  background-color: rgba(255, 255, 255, 0.06);
  box-shadow: none;
}

.service-form--dark .service-form__input[type='text']:hover,
.service-form--dark .service-form__input[type='tel']:hover,
.service-form--dark .service-form__textarea:hover,
.service-form--dark .service-form__input[type='text']:focus,
.service-form--dark .service-form__input[type='tel']:focus,
.service-form--dark .service-form__textarea:focus {
  border-color: rgba(255, 255, 255, 0.55);
  background-color: rgba(255, 255, 255, 0.1);
}

.service-form--dark .service-form__input[type='text']:-webkit-autofill,
.service-form--dark .service-form__input[type='tel']:-webkit-autofill {
  -webkit-text-fill-color: #fff;
  caret-color: #fff;
  transition: background-color 9999s ease-out 0s;
  box-shadow: 0 0 0 1000px rgba(255, 255, 255, 0.06) inset;
}

.service-form__input:focus,
.service-form__textarea:focus {
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.1);
}

.service-form__input::placeholder,
.service-form__textarea::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.service-form__textarea {
  min-height: 88px;
  resize: vertical;
}

.service-form__agree {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
}

.service-form__agree input {
  width: 17px;
  height: 17px;
  flex: none;
  accent-color: var(--color-primary);
}

.service-form__agree a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: underline;
}

.service-form__submit {
  align-self: flex-start;
  min-height: 52px;
  margin-top: 4px;
  padding: 0 32px;
  border: none;
  border-radius: var(--radius-sm);
  background: var(--color-primary);
  color: #fff;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-tight);
  transition: background 160ms ease, transform 120ms ease;
}

.service-form__submit:not(:disabled):hover {
  background: var(--color-primary-hover, #a80009);
}

.service-form__submit:not(:disabled):active {
  transform: translateY(1px);
}

.service-form__submit:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

.service-form__notice {
  margin: 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.75);
}

.service-form__notice[hidden] {
  display: none;
}

.service-form__notice.is-error {
  color: #ffb4b4;
}

.service-form__notice.is-success {
  color: #b8f0c8;
}

.service-form__spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 24px;
  margin-top: 12px;
}

.service-form__spinner[hidden] {
  display: none;
}

.service-form__spinner-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  animation: service-form-spinner 0.9s infinite ease-in-out;
}

.service-form__spinner-dot:nth-child(2) {
  animation-delay: 0.15s;
}

.service-form__spinner-dot:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes service-form-spinner {

  0%,
  80%,
  100% {
    opacity: 0.35;
    transform: scale(0.85);
  }

  40% {
    opacity: 1;
    transform: scale(1);
  }
}

/* Modal */
.service-form-modal[hidden] {
  display: none;
}

.service-form-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  padding: 32px;
}

.service-form-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(12, 14, 18, 0.6);
}

.service-form-modal__dialog {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-sizing: border-box;
  width: min(620px, 100%);
  aspect-ratio: 1 / 1;
  max-height: calc(100vh - 64px);
  padding: 52px 54px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: #14181c;
}

.service-form-modal__dialog::before {
  top: -90px;
  right: -90px;
  width: 300px;
  height: 300px;
}

.service-form-modal__dialog::after {
  bottom: -150px;
  left: -150px;
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(200, 0, 10, 0.3), transparent 68%);
}

.service-form-modal__dialog > .service-form--dark {
  position: relative;
  z-index: 1;
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  background: transparent;
  overflow: visible;
}

.service-form-modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}

.service-form-modal__close:hover,
.service-form-modal__close:focus-visible {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  outline: none;
}

.service-form-modal .service-form__header {
  margin-bottom: 28px;
}

.service-form-modal .service-form__textarea {
  resize: none;
}

body.service-form-modal-open {
  overflow: hidden;
}

/* Roadmap */
.service-roadmap {
  margin-bottom: 88px;
}

.service-roadmap__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}

.service-roadmap__head {
  display: flex;
  gap: 14px;
  align-items: center;
}

.service-roadmap__num {
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: var(--fw-bold);
  line-height: 1;
  letter-spacing: var(--ls-tight);
  color: var(--color-primary);
}

.service-roadmap__line {
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
}

.service-roadmap__step {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.service-roadmap__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: var(--fw-bold);
  line-height: 1.2;
  letter-spacing: var(--ls-tight);
  color: var(--text-strong);
}

.service-roadmap__text {
  margin: 0;
  font-size: 14px;
  line-height: var(--lh-relaxed);
  color: var(--text-muted);
}

/* Reviews */
.service-reviews {
  margin-bottom: 0;
}

.service-reviews__list {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.service-reviews__item {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 36px;
  align-items: start;
  padding: 32px 36px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  background: var(--surface-card);
}

.service-reviews__item--no-photo {
  grid-template-columns: 1fr;
}

.service-reviews__photo {
  width: 130px;
  height: 130px;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--surface-sunken);
}

.service-reviews__photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-reviews__content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.service-reviews__name {
  margin: 0;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: var(--fw-bold);
  line-height: 1.2;
  letter-spacing: var(--ls-tight);
  color: var(--text-strong);
}

.service-reviews__role {
  margin: 0;
  font-size: 14px;
  font-weight: var(--fw-medium);
  color: var(--text-muted);
}

.service-reviews__text {
  margin: 0;
  font-size: 14px;
  line-height: var(--lh-relaxed);
  color: var(--text-strong);
  text-wrap: pretty;
}

/* Responsive */
@media (max-width: 991px) {
  .service-stats__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .service-advantages__grid,
  .service-directions__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .service-roadmap__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .service-cta-light__inner,
  .service-form--inline {
    grid-template-columns: 1fr;
  }

  .service-cta-light__action {
    min-width: 0;
  }
}

@media (max-width: 767px) {
  .service-page__main {
    padding-top: 16px;
    padding-bottom: 56px;
  }

  .service-hero {
    min-height: 380px;
    margin-bottom: 48px;
  }

  .service-hero__content {
    padding: 40px 24px;
  }

  .service-hero__title {
    font-size: 28px;
  }

  .service-hero__subtitle {
    font-size: 16px;
  }

  .service-stats,
  .service-advantages,
  .service-cta-light,
  .service-directions,
  .service-cases,
  .service-form-section,
  .service-roadmap {
    margin-bottom: 56px;
  }

  .service-section__title {
    margin-bottom: 24px;
    font-size: 24px;
  }

  .service-stats__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .service-stats__value {
    font-size: 32px;
  }

  .service-advantages__grid,
  .service-directions__grid,
  .service-roadmap__grid {
    grid-template-columns: 1fr;
  }

  .service-directions__tile {
    padding: 12px;
  }

  .service-cta-light__inner {
    padding: 32px 24px;
  }

  .service-cases__carousel {
    grid-template-columns: 40px 1fr 40px;
    gap: 12px;
  }

  .service-cases__nav {
    width: 40px;
    height: 40px;
  }

  .service-form__row--split {
    grid-template-columns: 1fr;
  }

  .service-form--inline,
  .service-form-modal__dialog {
    padding: 32px 24px;
  }

  .service-form-modal {
    padding: 16px;
  }

  .service-form-modal__dialog {
    aspect-ratio: auto;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
  }

  .service-form__title {
    font-size: 24px;
  }

  .service-reviews__item {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 24px;
  }

  .service-reviews__photo {
    width: 96px;
    height: 96px;
  }
}

@media (max-width: 479px) {
  .service-stats__grid {
    grid-template-columns: 1fr;
  }
}