/* Стили страницы поверх дизайн-системы. Блоки по БЭМ, адаптив внутри каждого блока (основной брейкпоинт 600px) */

/* Base */
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--white); }
a { color: var(--link); }
a:hover { color: var(--navy); }
[id] { scroll-margin-top: 88px; }

/* Утилиты: m-only — только телефон, d-only — только десктоп, m-hide — скрыть на телефоне (переключается из main.js) */
[hidden] { display: none !important; }
.m-only { display: none; }
@media (max-width: 600px) {
  .d-only, .m-hide { display: none !important; }
  .m-only { display: block; }
}

/* Дизайн-система: правки для этой страницы */
.isr-form__row { grid-template-columns: 1fr; }
@media (min-width: 601px) {
  /* В выделенных карточках блок цены уже салатовый, поэтому кнопка при наведении становится белой */
  .isr .isr-card--featured .isr-btn:not(.isr-btn--promo):not(.isr-btn--outline):hover { background: var(--white); border-color: var(--navy); color: var(--navy); }
}
.isr-price__old { font-size: 24px; line-height: 28px; font-weight: 800; text-decoration-thickness: 3px; }
@media (max-width: 600px) {
  .isr { font-weight: 400; }
  .isr-btn { padding: 0 20px; }
  .isr .isr-btn:not(.isr-btn--promo):not(.isr-btn--outline):hover { background: var(--navy); border-color: var(--navy); color: var(--white); }
  .isr .isr-btn--promo:hover { background: var(--lime); border-color: var(--lime); color: var(--navy); }
  .isr .isr-btn--outline:hover { background: transparent; color: var(--navy); }
  .isr .isr-dark .isr-btn--outline:hover { background: transparent; color: var(--white); }
  .isr-card__name { font-size: 24px; line-height: 28px; }
  .isr-card__body, .isr-price { padding: 16px; }
  .isr-card__badge { white-space: normal; max-width: 170px; height: auto; min-height: 28px; padding-top: 4px; padding-bottom: 4px; line-height: 18px; text-align: center; }
  .isr-price__row .isr-price__old { display: none; }
  .isr-price__was { margin: 0 0 -8px; font-size: 17px; line-height: 22px; font-weight: 800; color: var(--slate); text-decoration: line-through; text-decoration-thickness: 2px; }
  .isr-card--featured .isr-price__was { color: var(--navy); }
  .isr-review__text { font-weight: 400; }
  .isr-faq__a { padding-right: 0; }
  .isr-form { padding: 20px; }
  .isr-field input { border-color: var(--slate); }
  .isr-contacts { flex-direction: column; align-items: stretch; }
}

/* Page, container, section */
.page { min-height: 100vh; background: var(--white); }
.container { max-width: var(--container); margin: 0 auto; padding-left: 16px; padding-right: 16px; }
.section { background: var(--white); }
.section--surface { background: var(--surface); }
.section--navy { background: var(--navy); color: var(--white); }
.section__inner { display: flex; flex-direction: column; gap: 32px; padding-top: clamp(48px, 8vw, 80px); padding-bottom: clamp(48px, 8vw, 80px); }
.section__title { margin: 0; font-size: clamp(32px, 5vw, 44px); line-height: 1.05; font-weight: 800; letter-spacing: -.02em; }
@media (max-width: 600px) {
  .section__title { font-size: 30px; line-height: 34px; }
}

/* Header */
.header { position: sticky; top: 0; z-index: 10; background: var(--white); border-bottom: var(--border-card) solid var(--line); }
.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 12px; padding-bottom: 12px; }
.header__actions { display: flex; align-items: center; gap: 8px 16px; }
.header__link { display: flex; align-items: center; gap: 8px; min-height: 44px; text-decoration: none; font-size: 16px; line-height: 20px; font-weight: 800; }
.header__link, .header__link:hover { color: var(--navy); }
.header__link-icon { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--sky); color: var(--navy); }
.header__link-text { white-space: nowrap; }
.header__cta { white-space: nowrap; }
.header__cta-short { display: none; }
@media (max-width: 930px) {
  .header__link-text { display: none; }
}
@media (max-width: 760px) {
  .header__cta-long { display: none; }
  .header__cta-short { display: inline; }
}
@media (max-width: 600px) {
  .header__actions { gap: 6px; }
}
@media (max-width: 360px) {
  .header__cta { padding: 0 14px; }
}

/* Logo: знак-домик с сигналом Wi-Fi и надпись internet-expert.rs.
   На телефоне короткая форма IE.rs без подписи, на самых узких экранах только знак */
.logo { display: flex; align-items: center; gap: 12px; min-width: 0; text-decoration: none; }
.logo, .logo:hover { color: var(--navy); }
.logo__mark { flex: none; display: block; width: 44px; height: 44px; }
.logo__text { display: flex; flex-direction: column; min-width: 0; overflow: hidden; }
.logo__name, .logo__short { font-size: 20px; line-height: 24px; font-weight: 800; letter-spacing: -.02em; white-space: nowrap; }
.logo__short { display: none; }
.logo__tld { color: var(--link); }
.logo__caption { font-size: 13px; line-height: 16px; font-weight: 400; color: var(--slate); white-space: nowrap; }
@media (max-width: 600px) {
  .logo { gap: 8px; }
  .logo__mark { width: 36px; height: 36px; }
  .logo__name, .logo__caption { display: none; }
  .logo__short { display: block; font-size: 18px; }
}
@media (max-width: 389px) {
  .logo__text { display: none; }
}

/* Hero: первый экран */
.hero { position: relative; overflow: hidden; }
.hero__inner { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: center; gap: 48px; height: 556px;
  padding-top: clamp(48px, 8vw, 80px); padding-bottom: clamp(48px, 8vw, 80px); }
.hero__content { position: relative; flex: 999 1 min(520px, 100%); min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.hero__badge { align-self: flex-start; padding: 6px 16px; border-radius: var(--radius-pill); background: var(--lime); color: var(--navy);
  font-size: 20px; line-height: 28px; font-weight: 800; }
.hero__title { width: 663px; margin: 0; font-size: clamp(40px, 7vw, 64px); line-height: 1; font-weight: 800; letter-spacing: -.02em; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__visual { flex: 0 1 420px; min-width: 0; display: flex; justify-content: center; align-items: center; padding: 40px; }
.hero__visual-inner { position: relative; display: flex; align-items: center; }
.hero__arc { position: absolute; left: 223px; top: -343px; width: 420px; height: 420px; border-radius: 50%; background: var(--lime); }
.hero__arc-hole { position: absolute; inset: 80px; border-radius: 50%; background: var(--navy); }
.hero__circle { position: relative; z-index: 1; flex: none; display: flex; align-items: center; justify-content: center; width: 300px; height: 300px;
  border-radius: 50%; background: var(--lime); color: var(--navy); box-shadow: 0 0 0 10px var(--navy), 0 0 0 14px var(--lime); }
.hero__circle-svg { display: block; overflow: visible; font-family: inherit; }
.hero__circle-text { fill: currentColor; font-weight: 700; }
.hero__circle-text--l { font-size: 92px; font-weight: 800; }
.hero__circle-text--m { font-size: 60px; }
.hero__circle-text--s { font-size: 30px; }
@media (max-width: 1070px) {
  .hero__visual { display: none; }
}
@media (max-width: 670px) {
  .hero__title { width: auto; }
}
@media (max-width: 600px) {
  .hero__inner { height: auto; }
  .hero__title { font-size: 36px; line-height: 38px; }
  .hero__cta { width: 100%; }
}

/* Tariffs: вкладки, группы тарифов, тарифы с сим-картой */
.tariffs__group { display: flex; flex-direction: column; }
.tariffs__group--panel { gap: 20px; padding: clamp(16px, 4vw, 32px); border-radius: var(--radius-block); background: var(--sky); }
.tariffs__group--sim { gap: 16px; padding-top: 8px; }
.tariffs__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; }
.tariffs__head-main { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 16px; }
.tariffs__title { margin: 0; font-size: clamp(32px, 5vw, 44px); line-height: 1.05; font-weight: 800; letter-spacing: -.02em; }
.tariffs__title--small { font-size: clamp(22px, 4vw, 28px); line-height: 1.2; letter-spacing: normal; }
.tariffs__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 24px; }
@media (max-width: 600px) {
  .tariffs__title { font-size: 22px; line-height: 26px; }
  .tariffs__group--panel { gap: 16px; padding: 0; background: transparent; }
  .tariffs__tabs { display: flex; gap: 4px; padding: 4px; border: 2px solid var(--navy); border-radius: var(--radius-pill); background: var(--white); }
  .tariffs__tab { flex: 1; height: 44px; border: 0; border-radius: var(--radius-pill); background: transparent; color: var(--navy);
    font: 800 16px/20px var(--font-sans); cursor: pointer; }
  .tariffs__tab[aria-pressed="true"] { background: var(--navy); color: var(--lime); }
  .tariffs__sim-toggle { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; padding: 16px;
    border: 2px solid var(--line); border-radius: var(--radius-card); background: var(--white); color: var(--navy); font: inherit; text-align: left; cursor: pointer; }
  .tariffs__sim-toggle[aria-expanded="true"] .isr-faq__icon::after { transform: rotate(0); }
  .tariffs__sim-title { display: block; font-size: 20px; line-height: 24px; }
  .tariffs__sim-text { display: block; margin-top: 2px; font-size: 15px; line-height: 20px; color: var(--slate); }
}

/* Why: «Почему выбирают нас». На десктопе сетка карточек, на телефоне баннер и список */
.why__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 24px; }
.why__promo { grid-column: 1 / -1; position: relative; overflow: hidden; display: flex; flex-wrap: wrap; align-items: center; gap: 16px 40px;
  padding: clamp(24px, 5vw, 48px); border-radius: var(--radius-block); background: var(--lime); color: var(--navy); }
.why__ring { position: absolute; top: 50%; border: 22px solid var(--navy); border-radius: 50%; pointer-events: none; }
.why__ring--s { right: -90px; width: 180px; height: 180px; margin-top: -90px; }
.why__ring--m { right: -134px; width: 268px; height: 268px; margin-top: -134px; }
.why__ring--l { right: -178px; width: 356px; height: 356px; margin-top: -178px; }
.why__promo-percent { position: relative; font-size: clamp(64px, 12vw, 120px); line-height: 1; font-weight: 800; letter-spacing: -.02em; }
.why__promo-body { position: relative; flex: 1 1 280px; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.why__promo-title { margin: 0; font-size: clamp(26px, 4vw, 36px); line-height: 1.1; font-weight: 800; letter-spacing: -.02em; }
.why__promo-text { margin: 0; font-size: 18px; line-height: 26px; }
.why__card { display: flex; flex-direction: column; gap: 12px; padding: 24px; border-radius: var(--radius-card); background: var(--navy); color: var(--white); }
.why__card-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--lime); color: var(--navy); }
.why__card-title { margin: 0; font-size: 22px; line-height: 26px; font-weight: 800; color: var(--lime); }
.why__card-text { margin: 0; color: var(--on-navy-muted); }
.why__banner { position: relative; overflow: hidden; margin-bottom: 8px; padding: 24px; border-radius: var(--radius-block); background: var(--lime); color: var(--navy); }
.why__banner-ring { position: absolute; right: -120px; top: -100px; width: 180px; height: 180px; border: 22px solid var(--navy); border-radius: 50%; pointer-events: none; }
.why__banner-body { position: relative; display: flex; flex-direction: column; gap: 8px; }
.why__banner-percent { font-size: 64px; line-height: 1; font-weight: 800; letter-spacing: -.02em; }
.why__banner-title { margin: 0; font-size: 24px; line-height: 28px; font-weight: 800; letter-spacing: -.02em; }
.why__banner-text { margin: 0; font-size: 16px; line-height: 22px; }
.why__list { border-top: var(--border-card) solid var(--navy); }
.why__item { display: flex; align-items: flex-start; gap: 14px; padding: 16px 0; border-bottom: var(--border-card) solid var(--line); }
.why__item-icon { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--lime); color: var(--navy); }
.why__item-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.why__item-title { margin: 0; font-size: 20px; line-height: 24px; font-weight: 800; }
.why__item-text { margin: 0; font-size: 16px; line-height: 22px; color: var(--slate); }
@media (max-width: 1100px) {
  .why__rings { display: none; }
}

/* Reviews: бегущая лента отзывов.
   В ленте две одинаковые группы карточек (вторая aria-hidden). У каждой группы справа отступ на размер gap,
   поэтому сдвиг ленты ровно на -50% возвращает её в ту же картинку и цикл бесшовный.
   Ширина карточек задана через width: при одном flex-basis Chrome считает max-content ленты по тексту отзывов
   в одну строку, лента становится втрое шире, и большую часть цикла в окне пусто */
.reviews__viewport { overflow: hidden; margin: 0 -16px; padding: 0 16px; }
.reviews__track { display: flex; width: max-content; animation: reviews-scroll 60s linear infinite; }
.reviews__group { display: flex; gap: 24px; padding-right: 24px; }
.reviews__item { flex: none; width: 373px; }
/* Пауза, пока посетитель читает отзыв или переходит по ленте с клавиатуры */
.reviews__viewport:hover .reviews__track, .reviews__viewport:focus-within .reviews__track { animation-play-state: paused; }
@keyframes reviews-scroll { to { transform: translateX(-50%); } }
@media (max-width: 600px) {
  .reviews__track { animation-duration: 45s; }
  .reviews__group { gap: 12px; padding-right: 12px; }
  .reviews__item { width: 300px; }
}
/* Без анимации лента листается вручную, копия карточек не нужна */
@media (prefers-reduced-motion: reduce) {
  .reviews__viewport { overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 16px; }
  .reviews__track { animation: none; }
  .reviews__group[aria-hidden="true"] { display: none; }
  .reviews__item { scroll-snap-align: start; }
}

/* FAQ */
.faq__inner { gap: 24px; }
.faq__subtitle { margin: 8px 0 0; font-size: 20px; line-height: 26px; font-weight: 800; }
.faq__subtitle--spaced { margin-top: 16px; }
@media (max-width: 600px) {
  .faq__list--continued { margin-top: -24px; border-top: 0; }
}

/* Request: форма заявки */
.request__inner { align-items: center; }
.request__head { max-width: 760px; display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; }
.request__title { margin: 0; font-size: clamp(44px, 9vw, 80px); line-height: 1; font-weight: 800; letter-spacing: -.02em; color: var(--lime); }
.request__text { margin: 0; font-size: 18px; line-height: 26px; }
.request__text--large { font-size: 24px; line-height: 32px; font-weight: 400; color: var(--white); }
.request__body { width: 100%; max-width: 760px; min-width: 0; }
.request__form { border: 0; color: var(--navy); }
.request__trap { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); opacity: 0; }
.request__submit:disabled { opacity: .6; cursor: progress; }
@media (min-width: 601px) {
  /* Белый ховер сливается с белой формой */
  .isr .request__submit:hover { background: var(--sky-pale); border-color: var(--sky-pale); }
}
.request__success { color: var(--navy); outline: none; }
.request__back { justify-self: center; margin-top: var(--space-3); }
.request__error { margin: 0; font-size: 15px; line-height: 22px; color: var(--slate); text-align: center; }
@media (max-width: 600px) {
  .request__title { font-size: 32px; line-height: 36px; }
}

/* Chosen tariff: плашка «Выбранный тариф» в форме */
.chosen-tariff { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px;
  border-radius: var(--radius-card); background: var(--navy); color: var(--white); }
.chosen-tariff__info { display: flex; flex-direction: column; }
.chosen-tariff__label { font-size: 14px; line-height: 18px; font-weight: 800; color: var(--on-navy-muted); }
.chosen-tariff__name { font-size: 22px; line-height: 28px; font-weight: 800; color: var(--lime); }
.chosen-tariff__summary { font-size: 14px; line-height: 20px; color: var(--on-navy-muted); white-space: pre-line; }
.chosen-tariff__change { font-weight: 800; }
.chosen-tariff__change, .chosen-tariff__change:hover { color: var(--white); }
@media (max-width: 600px) {
  .chosen-tariff__change { display: inline-flex; align-items: center; height: 44px; padding: 0 18px; border: 2px solid var(--white);
    border-radius: var(--radius-pill); text-decoration: none; }
}

/* 404 */
.page:has(.not-found) { background: var(--navy); }
.not-found__inner { align-items: center; justify-content: center; min-height: 60vh; gap: 24px; text-align: center; }
.not-found__code { margin: 0; font-size: clamp(80px, 18vw, 160px); line-height: 1; font-weight: 800; letter-spacing: -.02em; color: var(--lime); }
.not-found__title { margin: 0; font-size: clamp(30px, 5vw, 44px); line-height: 1.05; font-weight: 800; letter-spacing: -.02em; }
.not-found__text { max-width: 560px; margin: 0; font-size: 18px; line-height: 26px; color: var(--on-navy-muted); }

/* Footer */
.footer__inner { display: flex; flex-direction: column; gap: 32px; padding-top: clamp(40px, 7vw, 64px); padding-bottom: clamp(40px, 7vw, 64px); }
.footer__title { margin: 0; font-size: 28px; line-height: 34px; font-weight: 800; }
.footer__note { margin: 0; font-size: 13px; line-height: 18px; color: var(--on-navy-muted); }
@media (max-width: 600px) {
  .footer { border-top: 2px solid var(--navy-line); }
  .footer__note { font-size: 14px; line-height: 20px; }
}
