/* ===========================
   BASE / RESET
   =========================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.hidden { display: none !important; }

:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: rgba(37, 99, 235, 0.1);
  --secondary: #10b981;
  --secondary-light: rgba(16, 185, 129, 0.1);
  --accent: #06b6d4;
  --bg-dark: #0f172a;
  --bg-card: #ffffff;
  --bg-light: #f1f5f9;
  --bg-section: #f8fafc;
  --text-dark: #1e293b;
  --text-mid: #475569;
  --text-light: #94a3b8;
  --border: #e2e8f0;
  --border-focus: #2563eb;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --shadow-xl: 0 20px 60px rgba(0,0,0,0.15);
  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--text-dark);
  background: var(--bg-light);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.page-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===========================
   HERO
   =========================== */
.hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.92) 0%, rgba(30, 41, 59, 0.85) 50%, rgba(15, 23, 42, 0.9) 100%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
  text-align: center;
}

.hero-badge {
  display: inline-block;
  padding: 6px 20px;
  border-radius: 999px;
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.15);
  color: #67e8f9;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 28px;
}

.hero h1 {
  font-family: var(--font-heading);
  font-size: 3.2rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.12;
  margin-bottom: 20px;
}

.gradient-text {
  background: linear-gradient(135deg, #67e8f9 0%, #10b981 50%, #34d399 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.65);
  line-height: 1.7;
  max-width: 540px;
  margin: 0 auto 36px;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
  font-weight: 500;
}

.stat-icon {
  font-size: 1.1rem;
}

.hero-cta {
  display: inline-block;
  padding: 16px 40px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  color: #fff;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.35);
}

.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 35px rgba(37, 99, 235, 0.45);
}

/* ===========================
   STATUS MESSAGES
   =========================== */
.status-message {
  padding: 80px 20px;
  display: flex;
  justify-content: center;
}

.status-card {
  text-align: center;
  max-width: 500px;
  background: var(--bg-card);
  padding: 60px 40px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
}

.status-icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

.status-card h2 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin-bottom: 12px;
  color: var(--text-dark);
}

.status-card p {
  color: var(--text-mid);
  font-size: 1.05rem;
  line-height: 1.7;
}

/* ===========================
   SURVEY SECTION
   =========================== */
.survey-section {
  padding: 60px 20px 80px;
  background: var(--bg-section);
  flex: 1;
}

.survey-container {
  max-width: 680px;
  margin: 0 auto;
}

/* Progress Bar */
.progress-bar-wrap {
  margin-bottom: 32px;
}

.progress-track {
  height: 6px;
  background: var(--border);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 10px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 999px;
  transition: width 0.4s ease;
  width: 0%;
}

.progress-label {
  font-size: 0.82rem;
  color: var(--text-light);
  font-weight: 500;
  text-align: right;
}

/* Survey Pages */
.survey-page {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 40px 36px;
  box-shadow: var(--shadow-md);
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.page-header {
  text-align: center;
  margin-bottom: 36px;
}

.page-title {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.page-description {
  color: var(--text-mid);
  font-size: 0.95rem;
}

/* Questions */
.question-block {
  margin-bottom: 32px;
}

.question-block:last-child {
  margin-bottom: 0;
}

.question-label {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 4px;
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.required-mark {
  color: #ef4444;
  font-weight: 700;
}

.question-description {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: 14px;
  line-height: 1.5;
}

/* Radio Options */
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.radio-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.95rem;
  color: var(--text-mid);
}

.radio-option:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

.radio-option.selected {
  border-color: var(--primary);
  background: var(--primary-light);
  color: var(--primary-dark);
  font-weight: 500;
}

.radio-option input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
  flex-shrink: 0;
}

/* Rating Stars */
.rating-group {
  display: flex;
  gap: 8px;
  align-items: center;
}

.rating-star {
  width: 48px;
  height: 48px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.rating-star:hover,
.rating-star.hovered {
  border-color: #fbbf24;
  background: rgba(251, 191, 36, 0.1);
  transform: scale(1.08);
}

.rating-star.selected {
  border-color: #f59e0b;
  background: rgba(245, 158, 11, 0.15);
}

.rating-value {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-left: 8px;
  font-weight: 500;
}

/* Ranking List */
.ranking-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ranking-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-light);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  cursor: grab;
  transition: all 0.2s ease;
  user-select: none;
}

.ranking-item:active {
  cursor: grabbing;
}

.ranking-item.dragging {
  opacity: 0.5;
  border-color: var(--primary);
  background: var(--primary-light);
}

.ranking-item.drag-over {
  border-color: var(--primary);
  background: var(--primary-light);
  transform: scale(1.02);
}

.ranking-number {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ranking-text {
  flex: 1;
  font-size: 0.95rem;
  color: var(--text-dark);
}

.ranking-handle {
  color: var(--text-light);
  font-size: 1.1rem;
  flex-shrink: 0;
}

.ranking-arrows {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex-shrink: 0;
}

.ranking-arrow-btn {
  width: 28px;
  height: 22px;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--bg-card);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  color: var(--text-mid);
  transition: all 0.15s ease;
}

.ranking-arrow-btn:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
}

/* Textarea */
.survey-textarea {
  width: 100%;
  min-height: 100px;
  padding: 14px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text-dark);
  resize: vertical;
  transition: border-color 0.2s ease;
  background: var(--bg-card);
}

.survey-textarea:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.textarea-counter {
  text-align: right;
  font-size: 0.78rem;
  color: var(--text-light);
  margin-top: 6px;
}

/* NPS Scale */
.nps-scale {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: center;
}

.nps-btn {
  width: 44px;
  height: 44px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-mid);
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nps-btn:hover {
  transform: scale(1.08);
}

.nps-btn.selected {
  color: #fff;
  border-color: transparent;
}

.nps-btn.nps-detractor.selected { background: #ef4444; }
.nps-btn.nps-passive.selected { background: #f59e0b; }
.nps-btn.nps-promoter.selected { background: #10b981; }

.nps-btn.nps-detractor:hover { border-color: #ef4444; background: rgba(239, 68, 68, 0.1); }
.nps-btn.nps-passive:hover { border-color: #f59e0b; background: rgba(245, 158, 11, 0.1); }
.nps-btn.nps-promoter:hover { border-color: #10b981; background: rgba(16, 185, 129, 0.1); }

.nps-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 0.78rem;
  color: var(--text-light);
}

/* Form Inputs */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.form-group input[type="text"],
.form-group input[type="email"] {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text-dark);
  transition: border-color 0.2s ease;
  background: var(--bg-card);
}

.form-group input:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Email Page */
.email-page-illustration {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 16px;
  box-shadow: var(--shadow-md);
}

/* Error Message */
.error-message {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: var(--radius-md);
  color: #dc2626;
  font-size: 0.9rem;
  font-weight: 500;
  margin-top: 16px;
}

.error-icon {
  flex-shrink: 0;
}

/* Navigation */
.survey-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 24px;
  gap: 12px;
}

.btn {
  padding: 14px 32px;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-next {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  color: #fff;
  margin-left: auto;
  box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.btn-next:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.btn-back {
  background: transparent;
  color: var(--text-mid);
  border: 2px solid var(--border);
}

.btn-back:hover {
  border-color: var(--text-mid);
  color: var(--text-dark);
}

/* ===========================
   THANK YOU / RESULTS
   =========================== */
.thankyou-section {
  padding: 60px 20px 80px;
  background: var(--bg-section);
}

.thankyou-container {
  max-width: 800px;
  margin: 0 auto;
}

.thankyou-header {
  text-align: center;
  margin-bottom: 48px;
}

.thankyou-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.thankyou-header h2 {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 10px;
}

.thankyou-header p {
  color: var(--text-mid);
  font-size: 1.05rem;
}

/* Results Grid */
.results-grid {
  display: grid;
  gap: 24px;
}

.result-card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: var(--shadow-md);
}

.result-card h3 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 4px;
}

.result-subtitle {
  color: var(--text-light);
  font-size: 0.85rem;
  margin-bottom: 24px;
}

/* Bar Chart */
.bar-chart-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.bar-label {
  font-size: 0.82rem;
  color: var(--text-mid);
  width: 180px;
  flex-shrink: 0;
  text-align: right;
  line-height: 1.3;
}

.bar-track {
  flex: 1;
  height: 28px;
  background: var(--bg-light);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width 1s ease;
  min-width: 0;
}

.bar-percent {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-mid);
  width: 42px;
  text-align: left;
  flex-shrink: 0;
}

/* Satisfaction */
.satisfaction-avg {
  text-align: center;
}

.satisfaction-number {
  font-family: var(--font-heading);
  font-size: 4rem;
  font-weight: 700;
  background: linear-gradient(135deg, #f59e0b, #10b981);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1;
  margin-bottom: 8px;
}

.satisfaction-stars {
  font-size: 1.8rem;
  margin-bottom: 6px;
  letter-spacing: 4px;
}

.satisfaction-label {
  color: var(--text-light);
  font-size: 0.9rem;
}

/* Priority Ranking */
.priority-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.priority-row:last-child {
  border-bottom: none;
}

.priority-rank {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.priority-rank.rank-1 { background: linear-gradient(135deg, #f59e0b, #fbbf24); color: #fff; }
.priority-rank.rank-2 { background: linear-gradient(135deg, #94a3b8, #cbd5e1); color: #fff; }
.priority-rank.rank-3 { background: linear-gradient(135deg, #a16207, #ca8a04); color: #fff; }
.priority-rank.rank-other { background: var(--bg-light); color: var(--text-mid); }

.priority-text {
  flex: 1;
  font-size: 0.95rem;
  color: var(--text-dark);
  font-weight: 500;
}

.priority-score {
  font-size: 0.82rem;
  color: var(--text-light);
  font-weight: 500;
}

/* NPS Display */
.nps-gauge {
  text-align: center;
  margin-bottom: 20px;
}

.nps-score {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 6px;
}

.nps-score.nps-positive { color: var(--secondary); }
.nps-score.nps-neutral { color: #f59e0b; }
.nps-score.nps-negative { color: #ef4444; }

.nps-breakdown {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.nps-segment {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--text-mid);
}

.nps-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.nps-dot.detractor { background: #ef4444; }
.nps-dot.passive { background: #f59e0b; }
.nps-dot.promoter { background: #10b981; }

/* Share Panel */
.share-panel {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 32px;
  text-align: center;
  margin-top: 32px;
  box-shadow: var(--shadow-md);
}

.share-panel h3 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.share-panel p {
  color: var(--text-mid);
  margin-bottom: 20px;
  font-size: 0.95rem;
}

.share-input-group {
  display: flex;
  gap: 8px;
  max-width: 480px;
  margin: 0 auto 16px;
}

.share-input-group input {
  flex: 1;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  color: var(--text-mid);
  background: var(--bg-light);
}

.btn-copy {
  background: var(--primary);
  color: #fff;
  padding: 12px 20px;
  font-size: 0.85rem;
}

.btn-copy:hover {
  background: var(--primary-dark);
}

.share-social {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.social-btn {
  padding: 10px 24px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  color: #fff;
  transition: opacity 0.2s;
}

.social-btn:hover { opacity: 0.85; }
.social-btn.facebook { background: #1877f2; }
.social-btn.twitter { background: #0f1419; }

/* Coupon */
.coupon-section {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 32px;
  text-align: center;
  margin-top: 32px;
  box-shadow: var(--shadow-md);
}

.coupon-section h3 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  margin-bottom: 16px;
}

.coupon-code-display {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  background: var(--bg-light);
  padding: 16px 24px;
  border-radius: var(--radius-md);
  border: 2px dashed var(--primary);
  color: var(--primary);
  display: inline-block;
  margin-bottom: 12px;
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 600px) {
  .hero h1 {
    font-size: 2.2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero-stats {
    gap: 16px;
  }

  .survey-page {
    padding: 28px 20px;
  }

  .bar-label {
    width: 100px;
    font-size: 0.75rem;
  }

  .nps-btn {
    width: 38px;
    height: 38px;
    font-size: 0.85rem;
  }

  .rating-star {
    width: 42px;
    height: 42px;
  }

  .result-card {
    padding: 24px 20px;
  }

  .btn {
    padding: 12px 24px;
    font-size: 0.95rem;
  }
}

@media (min-width: 768px) {
  .results-grid {
    grid-template-columns: 1fr 1fr;
  }

  .result-card:first-child {
    grid-column: 1 / -1;
  }
}

/* ===========================
   MISC / UTILITIES
   =========================== */
#wbx-powered-by-slot {
  text-align: center;
  padding: 20px;
}
