@media (prefers-reduced-motion: no-preference) {

  /* === Reveal === */
  .js [data-reveal] > * {
    opacity: 0;
  }

  .js [data-reveal].is_visible > * {
    animation: reveal_up 0.65s cubic-bezier(0.22, 0.61, 0.36, 1) both;
    animation-delay: calc(var(--reveal-index, 0) * 70ms);
  }

  .js [data-reveal-self] {
    opacity: 0;
  }

  .js [data-reveal-self].is_visible {
    animation: reveal_up 0.65s cubic-bezier(0.22, 0.61, 0.36, 1) both;
  }

  @keyframes reveal_up {
    from {
      opacity: 0;
      translate: 0 26px;
    }
    to {
      opacity: 1;
      translate: 0 0;
    }
  }

  /* === Hero === */
  .js .hero__badge,
  .js .hero__title,
  .js .hero__subtitle,
  .js .hero__actions {
    animation: hero_in 0.9s cubic-bezier(0.22, 0.61, 0.36, 1) both;
  }

  .js .hero__badge {
    animation-delay: 0.05s;
  }

  .js .hero__title {
    animation-delay: 0.14s;
  }

  .js .hero__subtitle {
    animation-delay: 0.24s;
  }

  .js .hero__actions {
    animation-delay: 0.34s;
  }

  .js .hero__overlay {
    animation: fade_in 1.2s ease both;
  }

  .js .hero__image {
    animation: hero_zoom 14s cubic-bezier(0.16, 0.84, 0.32, 1) both;
  }

  @keyframes hero_in {
    from {
      opacity: 0;
      translate: 0 24px;
    }
    to {
      opacity: 1;
      translate: 0 0;
    }
  }

  @keyframes fade_in {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }

  @keyframes hero_zoom {
    from {
      transform: scale(1.06);
    }
    to {
      transform: scale(1);
    }
  }

  /* === Price steps === */
  .price__steps::after {
    animation: price_step_move 7s linear infinite;
  }

  .price__step-number {
    animation: price_step_pulse 7s ease-out infinite;
  }

  .price__step:nth-child(2) .price__step-number {
    animation-delay: 1.9s;
  }

  .price__step:nth-child(3) .price__step-number {
    animation-delay: 3.9s;
  }

  @keyframes price_step_move {
    0% {
      left: var(--step_dot-a);
      opacity: 0;
      animation-timing-function: linear;
    }
    5% {
      left: var(--step_dot-a);
      opacity: 1;
      animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    }
    27% {
      left: var(--step_dot-b);
      opacity: 1;
      animation-timing-function: linear;
    }
    30% {
      left: var(--step_dot-b);
      opacity: 0;
      animation-timing-function: linear;
    }
    34% {
      left: var(--step_dot-c);
      opacity: 0;
      animation-timing-function: linear;
    }
    37% {
      left: var(--step_dot-c);
      opacity: 1;
      animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    }
    60% {
      left: var(--step_dot-d);
      opacity: 1;
      animation-timing-function: linear;
    }
    90% {
      left: var(--step_dot-d);
      opacity: 1;
      animation-timing-function: linear;
    }
    96% {
      left: var(--step_dot-d);
      opacity: 0;
      animation-timing-function: linear;
    }
    100% {
      left: var(--step_dot-a);
      opacity: 0;
    }
  }

  @keyframes price_step_pulse {
    0% {
      border-color: var(--accent);
      box-shadow: 0 0 0 0 rgba(232, 89, 12, 0.32);
    }
    9% {
      border-color: rgba(232, 89, 12, 0.5);
      box-shadow: 0 0 0 14px rgba(232, 89, 12, 0);
    }
    100% {
      border-color: rgba(232, 89, 12, 0.5);
      box-shadow: 0 0 0 14px rgba(232, 89, 12, 0);
    }
  }

  /* === Header === */
  .nav__link {
    position: relative;
  }

  .nav__link::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.25s ease;
  }

  .nav__link:hover::after {
    transform: scaleX(1);
  }

  /* === Buttons === */
  .button_accent:hover {
    box-shadow: 0 12px 26px rgba(232, 89, 12, 0.3);
    transform: translateY(-2px);
  }

  .button_accent:active {
    box-shadow: 0 6px 14px rgba(232, 89, 12, 0.24);
    transform: translateY(0);
  }

  /* === Cards === */
  .program__item,
  .benefits__item {
    transition: box-shadow 0.25s ease, border-color 0.25s ease;
  }

  .program__item:hover,
  .benefits__item:hover {
    box-shadow: 0 20px 44px rgba(16, 28, 44, 0.1);
  }

  .program__item:hover {
    border-color: rgba(232, 89, 12, 0.35);
  }

  /* === Program break === */
  .program__break-cup svg {
    animation: program_cup_float 6s ease-in-out infinite;
  }

  .program__break-steam path {
    animation: program_steam_rise 4.5s ease-in-out infinite;
  }

  .program__break-steam path:nth-child(2) {
    animation-delay: 0.7s;
  }

  .program__break-steam path:nth-child(3) {
    animation-delay: 1.4s;
  }

  @keyframes program_cup_float {
    0%,
    100% {
      transform: translateY(0);
    }

    50% {
      transform: translateY(-5px);
    }
  }

  @keyframes program_steam_rise {
    0% {
      opacity: 0;
      transform: translateY(5px);
    }

    30% {
      opacity: 0.85;
    }

    65%,
    100% {
      opacity: 0;
      transform: translateY(-7px);
    }
  }

  /* === FAQ === */
  .faq__icon::after {
    transition: transform 0.25s ease, opacity 0.25s ease;
  }

  .faq__question[aria-expanded="true"] .faq__icon::after {
    opacity: 0;
    transform: translate(-50%, -50%) rotate(90deg);
  }

  .faq__answer:not([hidden]) {
    animation: answer_in 0.3s ease both;
  }

  @keyframes answer_in {
    from {
      opacity: 0;
      translate: 0 -6px;
    }
    to {
      opacity: 1;
      translate: 0 0;
    }
  }

  /* === Mobile menu === */
  .mobile_menu:not([hidden]) .mobile_menu__inner {
    animation: menu_in 0.3s cubic-bezier(0.22, 0.61, 0.36, 1) both;
  }

  @keyframes menu_in {
    from {
      opacity: 0;
      translate: 0 -10px;
    }
    to {
      opacity: 1;
      translate: 0 0;
    }
  }

  /* === Popup === */
  .popup:not([hidden]) .popup__overlay {
    animation: fade_in 0.25s ease both;
  }

  .popup:not([hidden]) .popup__dialog {
    animation: popup_in 0.32s cubic-bezier(0.22, 0.61, 0.36, 1) both;
  }

  @keyframes popup_in {
    from {
      opacity: 0;
      scale: 0.97;
      translate: 0 18px;
    }
    to {
      opacity: 1;
      scale: 1;
      translate: 0 0;
    }
  }

}

@media (prefers-reduced-motion: reduce) {

  html {
    scroll-behavior: auto;
  }

  .price__steps::after {
    display: none;
  }

  .price__step-number {
    animation: none;
  }

}

@media print {

  .js [data-reveal] > *,
  .js [data-reveal-self] {
    opacity: 1;
    animation: none;
  }

  .js .hero__badge,
  .js .hero__title,
  .js .hero__subtitle,
  .js .hero__actions,
  .js .hero__overlay,
  .js .hero__image {
    opacity: 1;
    animation: none;
  }

}
