/* =======================================
   CREATE YOUR OWN PLUSH — Kid-Friendly CSS
   ======================================= */

@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&family=Playfair+Display:wght@700&display=swap');

:root {
  --pink:      #f472b6;
  --pink-deep: #ec4899;
  --lavender:  #a78bfa;
  --mint:      #34d399;
  --peach:     #fb923c;
  --yellow:    #fbbf24;
  --sky:       #38bdf8;
  --cream:     #fdf8f5;
  --white:     #ffffff;
  --gray-600:  #4b5563;
  --gray-400:  #9ca3af;

  --radius-xl:   1.5rem;
  --radius-full: 9999px;
  --shadow-fun:  0 8px 32px rgba(244,114,182,0.25);
  --transition:  0.25s cubic-bezier(0.4,0,0.2,1);
  --bounce:      0.35s cubic-bezier(0.34,1.56,0.64,1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Nunito', system-ui, sans-serif;
  background: var(--cream);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ---- Floating background bubbles ---- */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 10% 20%, rgba(244,114,182,0.12) 0%, transparent 40%),
    radial-gradient(circle at 85% 10%, rgba(167,139,250,0.12) 0%, transparent 40%),
    radial-gradient(circle at 50% 90%, rgba(52,211,153,0.08) 0%, transparent 40%);
  pointer-events: none;
  z-index: 0;
}

/* ---- Back nav ---- */
.back-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(253,248,245,0.9);
  backdrop-filter: blur(12px);
  padding: 0.75rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-bottom: 1px solid rgba(244,114,182,0.15);
}
.back-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: var(--pink-deep);
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.4rem 1rem;
  border-radius: var(--radius-full);
  border: 2px solid var(--pink);
  transition: var(--bounce);
}
.back-link:hover { background: #fce7f3; transform: scale(1.05); }
.brand-label {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--pink-deep);
  font-weight: 700;
}

/* ---- Page Header ---- */
.page-header {
  text-align: center;
  padding: 2.5rem 1.5rem 1.5rem;
  position: relative;
  z-index: 1;
}
.page-header-emoji { font-size: 3.5rem; display: block; margin-bottom: 0.5rem; animation: wiggle 2s ease-in-out infinite; }
.page-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  background: linear-gradient(135deg, var(--pink-deep), var(--lavender));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}
.page-subtitle {
  font-size: 1.1rem;
  color: var(--gray-600);
  margin-top: 0.5rem;
  font-weight: 600;
}

/* ---- Progress Stars ---- */
.progress-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.4rem;
  padding: 1.25rem 1rem;
  position: relative;
  z-index: 1;
  flex-wrap: wrap;
}
.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  cursor: pointer;
}
.progress-star {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  background: var(--white);
  border: 2px solid #e5e7eb;
  transition: var(--bounce);
  font-weight: 700;
  color: #9ca3af;
}
.progress-step.done .progress-star {
  background: linear-gradient(135deg, var(--mint), #059669);
  border-color: transparent;
  color: white;
  transform: scale(1.05);
}
.progress-step.active .progress-star {
  background: linear-gradient(135deg, var(--pink), var(--lavender));
  border-color: transparent;
  color: white;
  transform: scale(1.15);
  box-shadow: 0 4px 16px rgba(244,114,182,0.5);
  animation: pulse-star 1.5s ease-in-out infinite;
}
.progress-label {
  font-size: 0.62rem;
  font-weight: 700;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.progress-step.active .progress-label { color: var(--pink-deep); }
.progress-step.done .progress-label { color: var(--mint); }
.progress-line {
  flex: 1;
  max-width: 30px;
  height: 2px;
  background: #e5e7eb;
  border-radius: 2px;
  margin-bottom: 1rem;
}
.progress-line.done { background: linear-gradient(90deg, var(--mint), var(--pink)); }

/* ---- Main Layout ---- */
.wizard-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 2rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
  position: relative;
  z-index: 1;
}

/* ---- Step Card ---- */
.step-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.07);
  display: none;
  animation: stepIn 0.4s cubic-bezier(0.34,1.3,0.64,1) both;
}
.step-card.active { display: block; }

@keyframes stepIn {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.step-emoji { font-size: 2.5rem; display: block; margin-bottom: 0.5rem; }
.step-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.7rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 0.4rem;
}
.step-hint {
  font-size: 0.95rem;
  color: var(--gray-400);
  margin-bottom: 2rem;
  font-weight: 600;
}

/* ---- Option Grids ---- */
.options-grid {
  display: grid;
  gap: 1rem;
}
.options-grid-2 { grid-template-columns: repeat(2, 1fr); }
.options-grid-3 { grid-template-columns: repeat(3, 1fr); }
.options-grid-4 { grid-template-columns: repeat(4, 1fr); }

.option-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.2rem 0.75rem;
  border-radius: var(--radius-xl);
  border: 2.5px solid #f3f4f6;
  background: #fafafa;
  cursor: pointer;
  transition: var(--bounce);
  font-family: 'Nunito', sans-serif;
  min-height: 100px;
}
.option-btn:hover {
  border-color: var(--pink);
  background: #fef2f8;
  transform: translateY(-4px) scale(1.03);
  box-shadow: var(--shadow-fun);
}
.option-btn.selected {
  border-color: var(--pink-deep);
  background: linear-gradient(135deg, #fce7f3, #ede9fe);
  transform: scale(1.04);
  box-shadow: 0 6px 24px rgba(244,114,182,0.3);
}
.option-emoji { font-size: 2.5rem; line-height: 1; }
.option-label {
  font-size: 0.88rem;
  font-weight: 800;
  color: #374151;
  text-align: center;
  line-height: 1.3;
}
.option-btn.selected .option-label { color: var(--pink-deep); }
.option-sublabel {
  font-size: 0.72rem;
  color: var(--gray-400);
  font-weight: 600;
  text-align: center;
}

/* ---- Color Options ---- */
.color-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
.color-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: var(--bounce);
}
.color-swatch {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 3px solid transparent;
  transition: var(--bounce);
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}
.color-btn:hover .color-swatch { transform: scale(1.15); }
.color-btn.selected .color-swatch {
  border-color: #1f2937;
  transform: scale(1.2);
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}
.color-name {
  font-size: 0.78rem;
  font-weight: 800;
  color: #374151;
  text-align: center;
}
.color-btn.selected .color-name { color: var(--pink-deep); }

/* ---- Size Options ---- */
.size-btn {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding: 1.2rem 1.5rem;
  border-radius: var(--radius-xl);
  border: 2.5px solid #f3f4f6;
  background: #fafafa;
  cursor: pointer;
  transition: var(--bounce);
  font-family: 'Nunito', sans-serif;
  text-align: left;
}
.size-btn:hover {
  border-color: var(--pink);
  background: #fef2f8;
  transform: translateX(6px);
}
.size-btn.selected {
  border-color: var(--pink-deep);
  background: linear-gradient(135deg, #fce7f3, #ede9fe);
  box-shadow: 0 4px 20px rgba(244,114,182,0.25);
}
.size-icon { font-size: 2.4rem; }
.size-info { display: flex; flex-direction: column; gap: 2px; }
.size-title { font-size: 1rem; font-weight: 800; color: #1f2937; }
.size-desc { font-size: 0.8rem; color: var(--gray-400); font-weight: 600; }
.size-price {
  margin-left: auto;
  font-size: 1.1rem;
  font-weight: 900;
  color: var(--pink-deep);
}

/* ---- Text Input ---- */
.fun-input-wrap {
  position: relative;
  margin-bottom: 1.5rem;
}
.fun-input {
  width: 100%;
  padding: 1.1rem 1.5rem;
  font-family: 'Nunito', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  border: 3px solid #f3f4f6;
  border-radius: var(--radius-xl);
  outline: none;
  transition: var(--transition);
  color: #1f2937;
  background: #fafafa;
}
.fun-input:focus {
  border-color: var(--pink);
  background: white;
  box-shadow: 0 0 0 4px rgba(244,114,182,0.15);
}
.fun-input::placeholder { color: #d1d5db; font-weight: 600; }
.char-count {
  position: absolute;
  right: 1rem;
  bottom: 0.75rem;
  font-size: 0.75rem;
  color: var(--gray-400);
  font-weight: 700;
}
.fun-textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.6;
}

/* ---- Encouragement ---- */
.encouragement {
  display: none;
  background: linear-gradient(135deg, #fce7f3, #ede9fe);
  border-radius: var(--radius-xl);
  padding: 1rem 1.5rem;
  margin-bottom: 1.5rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--pink-deep);
  text-align: center;
  animation: popIn 0.4s cubic-bezier(0.34,1.56,0.64,1);
}
.encouragement.show { display: block; }

/* ---- Navigation Buttons ---- */
.step-nav {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
  align-items: center;
}
.btn-back {
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius-full);
  border: 2px solid #e5e7eb;
  background: white;
  font-family: 'Nunito', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #6b7280;
  cursor: pointer;
  transition: var(--transition);
}
.btn-back:hover { border-color: var(--pink); color: var(--pink-deep); }
.btn-next {
  flex: 1;
  padding: 1rem 2rem;
  border-radius: var(--radius-full);
  border: none;
  background: linear-gradient(135deg, var(--pink-deep), var(--lavender));
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 1.1rem;
  font-weight: 800;
  cursor: pointer;
  transition: var(--bounce);
  box-shadow: 0 6px 24px rgba(244,114,182,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}
.btn-next:hover { transform: translateY(-3px) scale(1.03); box-shadow: 0 10px 32px rgba(244,114,182,0.5); }
.btn-next:active { transform: scale(0.98); }
.btn-next:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ---- Live Preview Panel ---- */
.preview-panel {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 2rem 1.5rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.07);
  position: sticky;
  top: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  height: fit-content;
}
.preview-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: #1f2937;
  text-align: center;
}

/* ---- Plush Preview Character ---- */
.plush-preview {
  position: relative;
  width: 180px;
  height: 200px;
  margin: 0.5rem auto;
}
.plush-body {
  width: 150px;
  height: 155px;
  border-radius: 50% 50% 48% 48% / 55% 55% 45% 45%;
  background: #f9a8d4;
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  transition: background 0.5s ease;
  box-shadow: inset -8px -10px 20px rgba(0,0,0,0.08), 0 8px 24px rgba(0,0,0,0.1);
  animation: sway 4s ease-in-out infinite;
}
.plush-head {
  width: 120px;
  height: 115px;
  border-radius: 50%;
  background: #f9a8d4;
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  transition: background 0.5s ease;
  box-shadow: inset -6px -8px 16px rgba(0,0,0,0.08);
}
.plush-ears {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 50px;
  pointer-events: none;
}
.plush-face {
  position: absolute;
  top: 30px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 3.5rem;
  line-height: 1;
  z-index: 2;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.15));
}
.plush-accessory {
  position: absolute;
  top: -10px;
  right: 12px;
  font-size: 2rem;
  animation: float-acc 3s ease-in-out infinite;
  z-index: 3;
}
.plush-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #1f2937;
  text-align: center;
  min-height: 1.5em;
}
.plush-details {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.plush-detail-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  padding: 0.4rem 0.75rem;
  background: #fafafa;
  border-radius: 0.75rem;
  font-weight: 700;
}
.plush-detail-label { color: var(--gray-400); }
.plush-detail-val { color: #1f2937; }

/* ---- Order Step ---- */
.order-summary {
  background: linear-gradient(135deg, #fce7f3, #ede9fe);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.order-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  font-weight: 700;
  color: #374151;
}
.order-row.total {
  border-top: 2px dashed #f9a8d4;
  padding-top: 0.75rem;
  margin-top: 0.25rem;
  font-size: 1.1rem;
  color: var(--pink-deep);
}
.form-group {
  margin-bottom: 1.25rem;
}
.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 800;
  color: #374151;
  margin-bottom: 0.5rem;
}

/* ---- Confetti & Success ---- */
.success-screen {
  display: none;
  text-align: center;
  padding: 3rem 2rem;
  animation: popIn 0.5s cubic-bezier(0.34,1.56,0.64,1);
}
.success-screen.show { display: flex; flex-direction: column; align-items: center; gap: 1.5rem; }
.success-emoji { font-size: 5rem; animation: spin 1s ease 1; }
.success-title {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--pink-deep), var(--lavender));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.success-text { font-size: 1.05rem; color: var(--gray-600); font-weight: 600; max-width: 400px; line-height: 1.7; }
.order-ref {
  background: #f9fafb;
  border: 2px dashed #e5e7eb;
  border-radius: var(--radius-xl);
  padding: 1rem 2rem;
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--pink-deep);
  letter-spacing: 0.1em;
}

/* ---- Confetti canvas ---- */
#confetti-canvas {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  display: none;
}

/* ---- Animations ---- */
@keyframes wiggle {
  0%,100% { transform: rotate(-8deg); }
  50% { transform: rotate(8deg); }
}
@keyframes sway {
  0%,100% { transform: translateX(-50%) rotate(-2deg); }
  50% { transform: translateX(-50%) rotate(2deg); }
}
@keyframes float-acc {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}
@keyframes popIn {
  from { opacity: 0; transform: scale(0.7); }
  to   { opacity: 1; transform: scale(1); }
}
@keyframes spin {
  from { transform: rotate(-20deg) scale(0.5); }
  to   { transform: rotate(0deg) scale(1); }
}
@keyframes pulse-star {
  0%,100% { box-shadow: 0 4px 16px rgba(244,114,182,0.5); }
  50% { box-shadow: 0 4px 28px rgba(244,114,182,0.8); }
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
  .wizard-layout {
    grid-template-columns: 1fr;
    padding: 0 1rem 3rem;
  }
  .preview-panel { position: static; order: -1; }
  .plush-preview { width: 140px; height: 160px; margin: 0 auto; }
  .plush-body { width: 118px; height: 122px; }
  .plush-head { width: 96px; height: 92px; }
  .options-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .color-grid { grid-template-columns: repeat(4, 1fr); }
  .step-card { padding: 1.5rem; }
  .progress-label { display: none; }
}
