html.survey-pending { visibility: hidden; }

body.theme-survey {
  visibility: visible;
}

.page-wrap {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

#npsForm {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 86px);
}

.survey-card {
  flex: 1;
  width: min(980px, calc(100% - 32px));
  margin: 20px auto 0;
  padding: 28px 18px 20px;
}

.step {
  display: none;
  animation: slideUp 0.4s cubic-bezier(.22, 1, .36, 1);
}

.step.active {
  display: block;
}

.step1-question,
.step-title {
  font-size: clamp(24px, 5vw, 34px);
  text-align: center;
  margin-bottom: 8px;
}

.step1-sub,
.step-sub {
  font-size: 14px;
  text-align: center;
  color: var(--text-faint);
  margin-bottom: 24px;
}

.emoji-feedback {
  height: 52px;
  font-size: 40px;
  text-align: center;
  opacity: 0;
  transition: all 0.2s ease;
  margin-bottom: 8px;
}

.emoji-feedback.visible {
  opacity: 1;
}

.score-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-bottom: 10px;
}

.score-grid-row2 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-bottom: 18px;
}

.score-btn {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  font-family: var(--font-display);
  font-size: clamp(18px, 5vw, 26px);
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.score-btn:hover,
.score-btn:active {
  transform: scale(1.07);
}

.score-btn[data-range='detractor'] {
  border-color: rgba(255, 80, 80, 0.28);
}

.score-btn[data-range='passive'] {
  border-color: rgba(255, 180, 0, 0.28);
}

.score-btn[data-range='promoter'] {
  border-color: rgba(80, 200, 120, 0.28);
}

.score-btn.selected[data-range='detractor'] {
  background: rgba(220, 50, 50, 0.92);
  border-color: #ff4a4a;
  box-shadow: 0 0 24px rgba(220, 50, 50, 0.45);
}

.score-btn.selected[data-range='passive'] {
  background: rgba(230, 160, 0, 0.92);
  border-color: #ffb000;
  color: #111;
  box-shadow: 0 0 24px rgba(230, 160, 0, 0.42);
}

.score-btn.selected[data-range='promoter'] {
  background: rgba(40, 180, 100, 0.92);
  border-color: #28b464;
  box-shadow: 0 0 24px rgba(40, 180, 100, 0.42);
}

.score-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.42);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.hint {
  min-height: 18px;
  margin-top: 10px;
  font-size: 13px;
  text-align: center;
  color: #ffd1d1;
}

.check-grid {
  grid-template-columns: 1fr 1fr;
  margin-bottom: 16px;
}

.yn-grid {
  grid-template-columns: 1fr 1fr;
  margin: 10px 0 18px;
}

.sticky-footer {
  position: sticky;
  bottom: 0;
  z-index: 5;
  padding: 16px;
  background: linear-gradient(180deg, rgba(0, 8, 56, 0) 0%, rgba(0, 8, 56, 0.75) 24%, rgba(0, 8, 56, 0.95) 100%);
}

.sticky-inner {
  max-width: 980px;
  margin: 0 auto;
  display: flex;
  gap: 10px;
  justify-content: center;
}

#mainBtn,
#skipBtn {
  padding: 14px 18px;
  font-size: 15px;
  font-weight: 700;
}

#mainBtn {
  min-width: 200px;
}

.char-count {
  margin-top: 6px;
  font-size: 12px;
  text-align: right;
  color: var(--text-faint);
}

@media (max-width: 640px) {
  .survey-card {
    width: calc(100% - 24px);
    margin: 18px 12px 0;
    padding: 24px 14px 18px;
  }

  .score-grid,
  .score-grid-row2 {
    gap: 6px;
  }

  .check-grid,
  .yn-grid {
    grid-template-columns: 1fr;
  }

  .sticky-inner {
    flex-direction: column;
  }

  #mainBtn,
  #skipBtn {
    width: 100%;
  }
}

@media (min-width: 900px) {
  .survey-card {
    padding: 34px 28px 24px;
  }
}
