/* ═══════════════════════════════════════
   DIAMO — Shared Design System
   ═══════════════════════════════════════ */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-deep: #0a0a12;
  --bg-surface: #111122;
  --bg-card: #16162a;
  --bg-card-hover: #1c1c38;
  --text-primary: #f0eef5;
  --text-secondary: #9d99b3;
  --text-muted: #6b6580;
  --accent-warm: #d4a574;
  --accent-gold: #c9a55c;
  --accent-rose: #c47d8e;
  --accent-violet: #8b7bc7;
  --accent-teal: #6db5a0;
  --border-subtle: rgba(255,255,255,0.06);
  --border-focus: rgba(139,123,199,0.4);
  --gradient-primary: linear-gradient(135deg, var(--accent-warm), var(--accent-rose), var(--accent-violet));
  --gradient-card: linear-gradient(135deg, rgba(139,123,199,0.08), rgba(212,165,116,0.05));
  --shadow-glow: 0 0 40px rgba(139,123,199,0.08);
  --radius: 8px;
  --radius-lg: 16px;
  --transition: 0.3s ease;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg-deep);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

/* ═══ AMBIENT ═══ */
.ambient {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.ambient::before {
  content: '';
  position: absolute;
  top: -20%; left: -10%;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(139,123,199,0.08) 0%, transparent 70%);
  animation: drift1 25s ease-in-out infinite;
}
.ambient::after {
  content: '';
  position: absolute;
  bottom: -10%; right: -10%;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(212,165,116,0.06) 0%, transparent 70%);
  animation: drift2 30s ease-in-out infinite;
}
@keyframes drift1 {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(80px, 60px); }
}
@keyframes drift2 {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(-60px, -40px); }
}

.content { position: relative; z-index: 1; }

/* ═══ TYPOGRAPHY ═══ */
h1, h2, h3, h4 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  line-height: 1.2;
}

.section-label {
  font-size: 11px;
  letter-spacing: 3px;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 24px;
}

/* ═══ NAV ═══ */
.diamo-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 48px;
  max-width: 1200px;
  margin: 0 auto;
}
.logo {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 3px;
  color: var(--text-primary);
  text-transform: uppercase;
  text-decoration: none;
}
.logo-dot {
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--accent-warm);
  border-radius: 50%;
  margin-left: 2px;
  vertical-align: middle;
  transform: translateY(-2px);
}

/* ═══ BUTTONS ═══ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 40px;
  border: none;
  border-radius: var(--radius);
  font-family: 'Syne', sans-serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}
.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 4px 24px rgba(212,165,116,0.2);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(212,165,116,0.3);
}
.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}
.btn-secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
}
.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-focus);
}
.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  padding: 12px 24px;
}
.btn-ghost:hover {
  color: var(--text-primary);
}

/* ═══ FORM ELEMENTS ═══ */
.form-group {
  margin-bottom: 24px;
}
.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
  letter-spacing: 0.5px;
}
.form-input {
  width: 100%;
  padding: 14px 18px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-input:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(139,123,199,0.1);
}
.form-input::placeholder {
  color: var(--text-muted);
}

.form-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 14px;
  color: var(--text-secondary);
}
.form-checkbox input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent-violet);
}

/* ═══ AUTOCOMPLETE ═══ */
.autocomplete-wrapper {
  position: relative;
}
.autocomplete-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  max-height: 200px;
  overflow-y: auto;
  z-index: 100;
  display: none;
}
.autocomplete-list.active { display: block; }
.autocomplete-item {
  padding: 12px 18px;
  cursor: pointer;
  font-size: 14px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-subtle);
  transition: background var(--transition);
}
.autocomplete-item:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}
.autocomplete-item:last-child { border-bottom: none; }

/* ═══ QUIZ OPTION CARDS ═══ */
.quiz-option {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
  margin-bottom: 12px;
}
.quiz-option:hover {
  border-color: var(--border-focus);
  background: var(--bg-card-hover);
  transform: translateX(4px);
}
.quiz-option.selected {
  border-color: var(--accent-violet);
  background: rgba(139,123,199,0.08);
}
.quiz-option-letter {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(139,123,199,0.1);
  color: var(--accent-violet);
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 13px;
}
.quiz-option.selected .quiz-option-letter {
  background: var(--accent-violet);
  color: white;
}
.quiz-option-text {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.5;
}
.quiz-option.selected .quiz-option-text {
  color: var(--text-primary);
}

/* ═══ PROGRESS BAR ═══ */
.progress-bar {
  width: 100%;
  height: 3px;
  background: var(--bg-card);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 48px;
}
.progress-fill {
  height: 100%;
  background: var(--gradient-primary);
  transition: width 0.5s ease;
  border-radius: 2px;
}

/* ═══ STEP INDICATOR ═══ */
.step-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.step-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border-subtle);
  transition: background var(--transition);
}
.step-dot.active {
  background: var(--accent-violet);
}
.step-dot.completed {
  background: var(--accent-teal);
}

/* ═══ ARCHETYPE CARD ═══ */
.archetype-card {
  max-width: 520px;
  margin: 0 auto;
  padding: 48px 40px;
  background: var(--gradient-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  position: relative;
  text-align: center;
  overflow: hidden;
}
.archetype-card::before {
  content: '';
  position: absolute;
  top: -1px; left: 50%;
  transform: translateX(-50%);
  width: 80px; height: 2px;
  background: var(--gradient-primary);
}
.archetype-animal {
  font-size: 56px;
  margin-bottom: 16px;
  filter: drop-shadow(0 0 20px rgba(139,123,199,0.3));
}
.archetype-name {
  font-family: 'Syne', sans-serif;
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 16px;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.archetype-traits {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin: 24px 0;
  flex-wrap: wrap;
}
.archetype-trait {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.archetype-trait span {
  display: block;
  font-size: 15px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text-primary);
  margin-top: 4px;
  font-weight: 500;
}
.archetype-phrase {
  font-style: italic;
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.7;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border-subtle);
}

/* ═══ PROFILE PILLS ═══ */
.profile-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin: 32px 0;
}
.profile-pill {
  padding: 8px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 100px;
  font-size: 13px;
  color: var(--text-secondary);
}
.profile-pill strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* ═══ INSIGHT CARDS ═══ */
.insight-card {
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  margin-bottom: 16px;
  transition: all var(--transition);
}
.insight-card:hover {
  border-color: var(--border-focus);
  box-shadow: var(--shadow-glow);
}
.insight-number {
  font-family: 'Syne', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent-warm);
  margin-bottom: 12px;
}
.insight-text {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.8;
}

/* ═══ PAYWALL ═══ */
.paywall {
  margin-top: 48px;
  padding: 48px 32px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  text-align: center;
}
.paywall-title {
  font-family: 'Syne', sans-serif;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
}
.paywall-sub {
  color: var(--text-secondary);
  margin-bottom: 32px;
}
.paywall-plans {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  max-width: 680px;
  margin: 0 auto 24px;
}
.plan-card {
  padding: 32px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  text-align: left;
  position: relative;
  transition: all var(--transition);
}
.plan-card:hover {
  border-color: var(--border-focus);
  transform: translateY(-4px);
}
.plan-card.popular::before {
  content: 'MOST POPULAR';
  position: absolute;
  top: -10px; right: 16px;
  padding: 4px 12px;
  background: var(--accent-violet);
  color: white;
  font-size: 10px;
  letter-spacing: 1.5px;
  font-weight: 700;
  border-radius: 4px;
}
.plan-name {
  font-family: 'Syne', sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}
.plan-price {
  font-family: 'Syne', sans-serif;
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 4px;
}
.plan-price .original {
  font-size: 18px;
  color: var(--text-muted);
  text-decoration: line-through;
  font-weight: 400;
  margin-left: 8px;
}
.plan-features {
  list-style: none;
  margin: 16px 0 24px;
}
.plan-features li {
  padding: 6px 0;
  font-size: 14px;
  color: var(--text-secondary);
}
.plan-features li::before {
  content: '✦ ';
  color: var(--accent-warm);
}
.plan-btn {
  width: 100%;
}
.paywall-guarantee {
  color: var(--text-muted);
  font-size: 13px;
  margin-top: 16px;
}

/* ═══ BLURRED PREVIEW ═══ */
.blurred-preview {
  position: relative;
  overflow: hidden;
  margin: 32px 0;
  padding: 32px;
  background: var(--bg-card);
  border-radius: var(--radius);
}
.blurred-preview-content {
  filter: blur(6px);
  opacity: 0.4;
  user-select: none;
  pointer-events: none;
}
.blurred-preview-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, transparent, rgba(10,10,18,0.8));
}
.blurred-preview-overlay span {
  font-family: 'Syne', sans-serif;
  font-size: 14px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent-warm);
}

/* ═══ SHARE BUTTONS ═══ */
.share-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin: 32px 0;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 100px;
  color: var(--text-secondary);
  font-size: 13px;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}
.share-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
  border-color: var(--border-focus);
}

/* ═══ REPORT STYLES ═══ */
.report-container {
  max-width: 780px;
  margin: 0 auto;
  padding: 48px;
}
.report-section {
  margin-bottom: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--border-subtle);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease forwards;
}
.report-section:last-child {
  border-bottom: none;
}
.report-section h2 {
  font-family: 'Syne', sans-serif;
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--accent-warm);
}
.report-section h3 {
  font-family: 'Syne', sans-serif;
  font-size: 18px;
  font-weight: 600;
  margin: 24px 0 12px;
  color: var(--text-primary);
}
.report-section p {
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.8;
  margin-bottom: 16px;
}

/* Clickable technical terms */
.term {
  color: var(--accent-violet);
  cursor: help;
  border-bottom: 1px dashed rgba(139,123,199,0.4);
  position: relative;
}
.term-tooltip {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--text-secondary);
  max-width: 280px;
  white-space: normal;
  z-index: 1000;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}
.term:hover .term-tooltip {
  opacity: 1;
}

/* ═══ FEEDBACK WIDGET ═══ */
.feedback-widget {
  padding: 40px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  text-align: center;
  margin-top: 48px;
}
.feedback-stars {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 20px 0;
}
.feedback-star {
  font-size: 32px;
  cursor: pointer;
  transition: transform var(--transition);
  opacity: 0.3;
}
.feedback-star:hover,
.feedback-star.active {
  opacity: 1;
  transform: scale(1.2);
}
.feedback-textarea {
  width: 100%;
  min-height: 100px;
  padding: 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  resize: vertical;
  outline: none;
  margin: 16px 0;
}
.feedback-textarea:focus {
  border-color: var(--border-focus);
}
.feedback-incentive {
  font-size: 13px;
  color: var(--accent-teal);
  margin-bottom: 16px;
}

/* ═══ LOADING ═══ */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-deep);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}
.loading-spinner {
  width: 48px;
  height: 48px;
  border: 3px solid var(--border-subtle);
  border-top-color: var(--accent-violet);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
.loading-text {
  margin-top: 24px;
  color: var(--text-secondary);
  font-size: 15px;
}
.loading-sub {
  color: var(--text-muted);
  font-size: 13px;
  margin-top: 8px;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ═══ ANIMATIONS ═══ */
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

/* ═══ RESPONSIVE ═══ */
@media (max-width: 768px) {
  .diamo-nav { padding: 20px 24px; }

  .archetype-card { padding: 32px 24px; }
  .archetype-name { font-size: 26px; }
  .archetype-traits { gap: 20px; }

  .paywall { padding: 32px 20px; }
  .paywall-plans {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .report-container { padding: 24px; }
  .report-section h2 { font-size: 20px; }

  .share-buttons { gap: 8px; }
  .share-btn { padding: 8px 16px; font-size: 12px; }

  .insight-card { padding: 24px; }
}
