/* Стили главной страницы, подключаются после style.css. */

html {
  overflow-x: clip;
}

/* Кнопки */
.btn--accent {
  background: #3ABFA4;
  color: #043945;
  font-weight: 700;
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.22);
  opacity: 1;
}

.btn--link {
  height: auto;
  padding: 0;
  font-size: 16px;
  font-weight: 500;
  color: #27907B;
  text-decoration: underline;
  text-underline-offset: 3px;
}

#start,
#pricing,
#help,
#video {
  scroll-margin-top: 90px;
}

/* Первый экран */
.hero {
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.hero__content {
  align-items: center;
  gap: 40px;
  padding: 56px 48px;
}

.hero__text {
  gap: 24px;
}

.hero__title {
  max-width: 620px;
}

.hero__subtitle {
  max-width: 560px;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.92);
}

.hero__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.hero__note {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
}

/* Карточка панели в hero */
.hero__panel {
  width: 520px;
  flex-shrink: 0;
}

.panel-card {
  background: #fff;
  border-radius: 20px;
  padding: 20px 24px 24px;
  box-shadow: 0 24px 60px rgba(4, 57, 69, 0.35);
  color: #2E2E2E;
}

.panel-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid #EEF2F1;
}

.panel-card__project {
  display: block;
  font-size: 12px;
  color: #7C8B88;
  margin-bottom: 4px;
}

.panel-card__name {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
}

.panel-card__status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 500;
  color: #27907B;
  background: #EBFFFB;
  padding: 6px 10px;
  border-radius: 10px;
}

.panel-card__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3ABFA4;
}

.panel-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 6px;
  font-size: 15px;
}

.panel-table th {
  text-align: left;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.25;
  color: #7C8B88;
  padding: 12px 0 8px;
  vertical-align: bottom;
}

.panel-table td {
  padding: 11px 0;
  border-top: 1px solid #F1F4F3;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.panel-table th.num,
.panel-table td.num {
  text-align: right;
  padding-left: 12px;
}

.panel-table .was {
  color: #A6B2AF;
}

.panel-table td.pos {
  white-space: nowrap;
}

.pos-arrow {
  width: 16px;
  height: 10px;
  margin: 0 8px;
  color: #3ABFA4;
  vertical-align: middle;
}

.panel-table .now {
  color: #27907B;
  font-weight: 700;
}

.panel-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  padding: 14px 16px;
  background: #F4F8F7;
  border-radius: 14px;
}

.panel-card__balance-label {
  display: block;
  font-size: 13px;
  color: #7C8B88;
  margin-bottom: 2px;
}

.panel-card__balance {
  font-size: 20px;
  font-weight: 700;
}

.panel-card__free {
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  background: #27907B;
  padding: 7px 12px;
  border-radius: 10px;
}

.panel-card__caption {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
}

/* Полоса фактов под hero */
.facts {
  width: 1312px;
  max-width: 100%;
  background: #fff;
  border-radius: 20px;
  padding: 18px 32px;
  display: grid;
  grid-template-columns: repeat(4, auto);
  justify-content: space-between;
  gap: 12px 24px;
}

.facts .check-item span {
  font-size: 15px;
}

/* Видео */
.home-video {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-start;
}

.home-video__main {
  flex: 1 1 640px;
  background: #0E2E30;
  border-radius: 20px;
  overflow: hidden;
}

.home-video__player {
  width: 100%;
  height: auto;
  display: block;
  background: #0E2E30;
}

.home-video__side {
  flex: 0 1 320px;
  background: #fff;
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.home-video__label {
  font-size: 16px;
  font-weight: 700;
  color: #27907B;
  margin-bottom: 6px;
}

.home-video__chip {
  display: flex;
  align-items: baseline;
  gap: 10px;
  width: 100%;
  text-align: left;
  border: 0;
  background: #F4F8F7;
  border-radius: 12px;
  padding: 11px 14px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.3;
  color: #2E2E2E;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.home-video__chip:hover { background: #EBFFFB; }

.home-video__chip.is-active {
  background: #27907B;
  color: #fff;
}

.home-video__chip b {
  flex-shrink: 0;
  font-size: 14px;
  font-weight: 700;
  color: #27907B;
  font-variant-numeric: tabular-nums;
}

.home-video__chip.is-active b { color: #7FEFD6; }

.home-video__note {
  margin-top: auto;
  padding-top: 14px;
  font-size: 14px;
  line-height: 1.45;
  color: #7C8B88;
}

.section-head {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 32px;
}

.section-lead {
  max-width: 720px;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.45;
  color: #2E2E2E;
}

/* Три шага */
.start__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}

.start__card {
  background: #fff;
  border-radius: 20px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.start__card-title {
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
  color: #27907B;
}

.start__card-text {
  font-size: 16px;
  line-height: 1.45;
  color: #2E2E2E;
}

.start__fit {
  border-radius: 20px;
  background: linear-gradient(260deg, #3ABFA4 2.07%, #0C687C 99.43%);
  color: #fff;
  padding: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 24px 48px;
  align-items: flex-start;
}

.start__fit-title {
  flex: 0 0 280px;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
}

.start__fit-list {
  flex: 1 1 500px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px 32px;
}

/* Помощь с настройкой */
.help .section-title {
  margin-bottom: 12px;
}

.help .section-lead {
  margin-bottom: 32px;
}

/* Цены */
.pricing__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.pricing__card {
  border-radius: 20px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.pricing__card--gradient {
  background: linear-gradient(258deg, #3ABFA4 2.07%, #0C687C 99.43%);
  color: #fff;
}

.pricing__card--white {
  background: #fff;
}

.pricing__big {
  font-size: 64px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
}

.pricing__big small {
  display: block;
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 0;
  margin-top: 8px;
  opacity: 0.9;
}

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

.pricing__list .check-item span {
  line-height: 1.35;
}

.pricing__title {
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
  color: #27907B;
}

.calc__label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 16px;
  font-weight: 500;
}

.calc__value {
  font-size: 24px;
  font-weight: 700;
  color: #27907B;
  font-variant-numeric: tabular-nums;
}

.calc__range {
  width: 100%;
  accent-color: #27907B;
  height: 32px;
  cursor: pointer;
}

.calc__hint {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: #7C8B88;
  margin-top: -8px;
}

.calc__out {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.calc__cell {
  background: #F4F8F7;
  border-radius: 14px;
  padding: 16px;
}

.calc__cell--accent {
  background: #EBFFFB;
}

.calc__cell-label {
  display: block;
  font-size: 13px;
  color: #7C8B88;
  margin-bottom: 6px;
}

.calc__cell-value {
  font-size: 26px;
  font-weight: 700;
  color: #2E2E2E;
  font-variant-numeric: tabular-nums;
}

.calc__cell--accent .calc__cell-value {
  color: #27907B;
}

.calc__compare {
  font-size: 15px;
  line-height: 1.45;
  color: #2E2E2E;
}

.calc__compare b {
  font-variant-numeric: tabular-nums;
}

/* Кейсы */
.cases-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.case-card {
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.case-card__cover {
  width: 100%;
  height: 170px;
  object-fit: cover;
}

.case-card__body {
  padding: 24px 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.case-card__niche {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
  color: #27907B;
}

.case-card__region {
  display: block;
  font-size: 14px;
  font-weight: 400;
  color: #7C8B88;
  margin-top: 4px;
}

.case-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.case-table td {
  padding: 9px 0;
  border-top: 1px solid #F1F4F3;
  font-variant-numeric: tabular-nums;
}

.case-table td:last-child {
  text-align: right;
  font-weight: 700;
}

.case-table .was {
  color: #A6B2AF;
  font-weight: 500;
}

.case-table .now {
  color: #27907B;
}


/* Попап для новичков */
.offer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(4, 57, 69, 0.55);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.offer-overlay--open {
  display: flex;
}

.offer {
  position: relative;
  width: 100%;
  max-width: 520px;
  background: #fff;
  border-radius: 24px;
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: 0 30px 80px rgba(4, 57, 69, 0.35);
  animation: offerIn 0.3s ease;
}

@keyframes offerIn {
  from { opacity: 0; transform: translateY(16px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.offer:focus {
  outline: none;
}

.offer__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: #F4F8F7;
  color: #2E2E2E;
  font-size: 22px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.offer__close:hover {
  background: #EBFFFB;
}

.offer__close:focus-visible,
.btn:focus-visible,
.home-video__chip:focus-visible {
  outline: 2px solid #3ABFA4;
  outline-offset: 2px;
}

.offer__icon {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: linear-gradient(223deg, #24A08F 2.38%, #043945 93.74%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.offer__icon svg {
  width: 32px;
  height: 32px;
}

.offer__title {
  font-size: 30px;
  font-weight: 700;
  line-height: 1.15;
  color: #2E2E2E;
}

.offer__text {
  font-size: 17px;
  line-height: 1.45;
  color: #2E2E2E;
}

.offer__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.offer__list .check-item span {
  font-size: 16px;
}

.offer__actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-start;
  margin-top: 4px;
}

.offer__actions .btn--primary {
  width: 100%;
  height: 56px;
  border-radius: 16px;
}

.offer__actions .btn--link {
  align-self: center;
}


/* Адаптив */
@media (max-width: 1360px) {
  .facts {
    width: 100%;
  }
}

@media (max-width: 1100px) {
  .hero__panel {
    width: 440px;
  }

  .facts {
    grid-template-columns: repeat(2, auto);
  }

  .home-video__side {
    flex-basis: 100%;
  }

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

  .pricing__big {
    font-size: 52px;
  }
}

@media (max-width: 1024px) {
  .hero__actions .btn {
    width: auto;
  }

  .start__grid {
    grid-template-columns: 1fr;
  }

  .pricing__row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .hero__content {
    flex-direction: column;
    align-items: stretch;
    gap: 28px;
  }

  .hero__panel {
    width: 100%;
  }

  .hero__title {
    max-width: none;
  }
}

@media (max-width: 768px) {
  .hero__content {
    padding: 24px;
  }

  .hero__actions .btn {
    width: 100%;
  }

  .panel-card {
    padding: 16px 18px 18px;
  }

  .panel-table {
    font-size: 14px;
  }

  .facts {
    padding: 16px 20px;
    border-radius: 16px;
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .start__card,
  .pricing__card,
  .case-card__body {
    padding: 24px;
  }

  .start__fit {
    padding: 24px;
  }

  .start__fit-title {
    flex-basis: 100%;
  }

  .start__fit-list {
    grid-template-columns: 1fr;
  }

  .cases-grid {
    grid-template-columns: 1fr;
  }

  .calc__out {
    grid-template-columns: 1fr;
  }

  .offer {
    padding: 28px 22px;
    border-radius: 20px;
  }

  .offer__title {
    font-size: 24px;
  }
}
