/* ========================================
   CREATE DIRECTION PAGE STYLES
   ======================================== */

.create-page {
  background: var(--cream);
  min-height: 100vh;
}

.create-main {
  padding-bottom: 4rem;
}

.create-container {
  max-width: 520px;
  margin-inline: auto;
  padding: 0 1rem;
}

/* ---- Create Hero ---- */
.create-hero {
  text-align: center;
  padding: 2rem 1rem 1.5rem;
  animation: fadeInUp 0.5s ease both;
}

.create-hero-icon {
  font-size: 3rem;
  margin-bottom: 0.5rem;
  animation: bounce 1s ease both 0.3s;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.create-title {
  font-size: 2rem;
  color: var(--text-dark);
  margin-bottom: 0.4rem;
}

.create-subtitle {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.6;
}

/* ---- Progress Steps ---- */
.progress-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.5rem 1.5rem;
  gap: 0;
  animation: fadeInUp 0.5s ease both 0.1s;
  opacity: 0;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  position: relative;
}

.step-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--green-pale);
  color: var(--text-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 2px solid transparent;
}

.step.active .step-dot {
  background: linear-gradient(135deg, var(--green), var(--green-light));
  color: white;
  box-shadow: 0 4px 12px rgba(46,125,50,0.35);
  transform: scale(1.1);
}

.step.completed .step-dot {
  background: var(--green-deep);
  color: white;
}

.step.completed .step-dot::after {
  content: '✓';
  font-size: 0.7rem;
}

.step span {
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.step.active span { color: var(--green); }

.step-line {
  flex: 1;
  height: 2px;
  background: var(--green-pale);
  min-width: 24px;
  max-width: 40px;
  margin-bottom: 20px;
  transition: background 0.3s;
}

.step-line.filled { background: var(--green); }

/* ---- Form Steps ---- */
.form-step {
  display: none;
  animation: fadeInUp 0.4s ease both;
}

.form-step.active { display: block; }

.step-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(46,125,50,0.07);
}

.step-card-header {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--green-pale);
}

.step-card-header h2 {
  font-size: 1.4rem;
  color: var(--text-dark);
  margin-bottom: 0.25rem;
}

.step-card-header p {
  font-size: 0.85rem;
  color: var(--text-light);
}

/* ---- Form Groups ---- */
.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-mid);
  margin-bottom: 0.45rem;
  letter-spacing: 0.2px;
}

.required { color: var(--green); }
.optional { color: var(--text-light); font-weight: 400; }

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  border: 1.5px solid #c8e6c9;
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  color: var(--text-dark);
  background: var(--warm-white);
  font-family: 'DM Sans', sans-serif;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
  appearance: none;
  outline: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(46,125,50,0.1);
  background: white;
}

.form-textarea { resize: vertical; min-height: 100px; }

.form-hint {
  display: block;
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: 0.35rem;
  line-height: 1.4;
}

.select-wrapper {
  position: relative;
}

.select-arrow {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  pointer-events: none;
}

/* ---- Type Toggle ---- */
.type-toggle {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.type-btn {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border: 2px solid #c8e6c9;
  border-radius: var(--radius);
  background: white;
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
  font-family: 'DM Sans', sans-serif;
  width: 100%;
}

.type-btn:hover { border-color: var(--green-mist); background: var(--green-pale); }

.type-btn.active {
  border-color: var(--green);
  background: var(--green-pale);
  box-shadow: 0 0 0 3px rgba(46,125,50,0.1);
}

.type-btn-icon { font-size: 1.5rem; }

.type-btn-content { flex: 1; }

.type-btn-content strong {
  display: block;
  font-size: 0.9rem;
  color: var(--text-dark);
  margin-bottom: 0.1rem;
}

.type-btn-content small {
  font-size: 0.75rem;
  color: var(--text-light);
}

.type-btn-check {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #c8e6c9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  color: transparent;
  transition: all 0.2s;
}

.type-btn.active .type-btn-check {
  background: var(--green);
  color: white;
}

/* ---- Event Grid ---- */
.event-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.6rem;
}

.event-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding: 0.75rem 0.5rem;
  border: 2px solid #c8e6c9;
  border-radius: var(--radius);
  background: white;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  font-family: 'DM Sans', sans-serif;
}

.event-btn:hover {
  border-color: var(--green-mist);
  transform: translateY(-2px);
}

.event-btn.active {
  border-color: var(--green);
  background: var(--green-pale);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(46,125,50,0.2);
}

.event-emoji { font-size: 1.4rem; }

.event-btn span:last-child {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-mid);
}

/* ---- Audio Recorder ---- */
.audio-recorder {
  background: linear-gradient(135deg, #0d1a0e, #102010);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  overflow: hidden;
}

.recorder-visual {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.75rem;
  position: relative;
}

.recorder-waves {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 60px;
  display: none;
}

.recorder-waves.active { display: flex; }

.wave {
  width: 4px;
  height: 4px;
  background: var(--green);
  border-radius: 99px;
  animation: waveAnim 0.8s ease-in-out infinite;
}

.wave:nth-child(1) { animation-delay: 0s; }
.wave:nth-child(2) { animation-delay: 0.1s; }
.wave:nth-child(3) { animation-delay: 0.2s; }
.wave:nth-child(4) { animation-delay: 0.3s; }
.wave:nth-child(5) { animation-delay: 0.4s; }
.wave:nth-child(6) { animation-delay: 0.3s; }
.wave:nth-child(7) { animation-delay: 0.2s; }
.wave:nth-child(8) { animation-delay: 0.1s; }

@keyframes waveAnim {
  0%, 100% { height: 4px; }
  50% { height: 50px; background: var(--green-light); }
}

.recorder-idle-icon {
  text-align: center;
  color: rgba(255,255,255,0.5);
}

.recorder-idle-icon svg { stroke: rgba(255,255,255,0.4); }
.recorder-idle-icon p { font-size: 0.8rem; margin-top: 0.4rem; color: rgba(255,255,255,0.4); }

.recorder-timer {
  text-align: center;
  font-size: 2rem;
  font-weight: 700;
  color: white;
  font-variant-numeric: tabular-nums;
  margin-bottom: 1rem;
  font-family: 'Cormorant Garamond', serif;
}

.recorder-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.record-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--green);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 99px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.2s;
  box-shadow: 0 4px 16px rgba(46,125,50,0.4);
}

.record-btn.recording {
  background: #d32f2f;
  animation: recordPulse 1.5s ease infinite;
  box-shadow: 0 4px 20px rgba(211,47,47,0.5);
}

@keyframes recordPulse {
  0%, 100% { box-shadow: 0 4px 20px rgba(211,47,47,0.5); }
  50% { box-shadow: 0 4px 30px rgba(211,47,47,0.8); }
}

.stop-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255,255,255,0.15);
  color: white;
  border: 1px solid rgba(255,255,255,0.3);
  padding: 0.6rem 1.2rem;
  border-radius: 99px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.2s;
}

.stop-btn:hover { background: rgba(255,255,255,0.25); }

.delete-record-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: transparent;
  color: rgba(255,100,100,0.8);
  border: 1px solid rgba(255,100,100,0.3);
  padding: 0.5rem 1rem;
  border-radius: 99px;
  font-size: 0.8rem;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.2s;
}

.audio-preview {
  margin-top: 1rem;
  background: rgba(255,255,255,0.08);
  border-radius: var(--radius-sm);
  padding: 0.75rem;
}

.audio-preview-label {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.6);
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.audio-preview audio {
  width: 100%;
  height: 36px;
}

/* ---- Image Upload ---- */
.image-upload-zone {
  border: 2px dashed var(--green-mist);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--green-pale);
}

.image-upload-zone:hover {
  border-color: var(--green);
  background: #e8f5e9;
}

.hidden-input {
  display: none;
}

.upload-prompt { color: var(--text-light); }
.upload-icon { font-size: 2rem; margin-bottom: 0.5rem; }
.upload-prompt p { font-size: 0.9rem; font-weight: 500; color: var(--text-mid); }
.upload-prompt small { font-size: 0.75rem; }

.image-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
  margin-top: 0.75rem;
}

.image-thumb {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--green-pale);
  animation: scaleIn 0.3s ease both;
}

.image-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.image-thumb-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(0,0,0,0.6);
  color: white;
  border: none;
  font-size: 0.7rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: background 0.2s;
}

.image-thumb-remove:hover { background: #d32f2f; }

.image-count-badge {
  font-size: 0.78rem;
  color: var(--green);
  font-weight: 600;
  margin-top: 0.4rem;
}

/* ---- RSVP Contacts ---- */
.rsvp-info-box {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  background: linear-gradient(135deg, var(--green-pale), #fff8e1);
  border-radius: var(--radius);
  padding: 1rem;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(46,125,50,0.1);
}

.rsvp-info-icon { font-size: 1.2rem; flex-shrink: 0; }
.rsvp-info-box p { font-size: 0.85rem; color: var(--text-mid); line-height: 1.5; }

.contact-entry {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  margin-bottom: 1.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--green-pale);
}

.contact-entry:last-child { border-bottom: none; margin-bottom: 0; }

.contact-number-badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green), var(--green-light));
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 0.4rem;
}

.contact-fields { flex: 1; }
.contact-fields .form-group:last-child { margin-bottom: 0; }

.phone-input-wrapper {
  display: flex;
  align-items: center;
  border: 1.5px solid #c8e6c9;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--warm-white);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.phone-input-wrapper:focus-within {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(46,125,50,0.1);
}

.phone-prefix {
  padding: 0.75rem 0.75rem;
  font-size: 0.85rem;
  color: var(--text-mid);
  font-weight: 600;
  background: var(--green-pale);
  white-space: nowrap;
  border-right: 1px solid #c8e6c9;
}

.phone-input {
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  flex: 1;
}

/* ---- Summary Preview ---- */
.summary-preview {
  background: linear-gradient(135deg, var(--green-deep), var(--green));
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  margin-top: 1.5rem;
  color: white;
}

.summary-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  font-family: 'DM Sans', sans-serif;
}

.summary-content {
  font-size: 0.85rem;
  line-height: 1.7;
  opacity: 0.9;
}

.summary-row {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.3rem;
}

.summary-label {
  font-weight: 600;
  opacity: 0.8;
  min-width: 80px;
}

/* ---- Step Actions ---- */
.step-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--green-pale);
}

.btn-next {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, var(--green), var(--green-light));
  color: white;
  border: none;
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  box-shadow: 0 4px 16px rgba(46,125,50,0.35);
  transition: all 0.2s;
}

.btn-next:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(46,125,50,0.45);
}

.btn-back {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--green-pale);
  color: var(--green);
  border: none;
  padding: 0.85rem 1.2rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.2s;
}

.btn-back:hover { background: var(--green-mist); }

.btn-submit {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  background: linear-gradient(135deg, #2e7d32, #43a047);
  color: white;
  border: none;
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  box-shadow: 0 4px 16px rgba(46,125,50,0.35);
  transition: all 0.2s;
}

.btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(46,125,50,0.45);
}

/* ---- Success State ---- */
.success-state {
  text-align: center;
  padding: 2rem 1rem;
  animation: scaleIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.success-animation { display: flex; flex-direction: column; align-items: center; }

.success-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--green-pale);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  animation: popIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes popIn {
  from { transform: scale(0); }
  to { transform: scale(1); }
}

.check-path {
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  animation: drawCheck 0.5s ease forwards 0.3s;
}

@keyframes drawCheck {
  to { stroke-dashoffset: 0; }
}

.success-state h2 {
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
}

.success-state p {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.share-box {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--green-pale);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  width: 100%;
  max-width: 380px;
}

.share-link {
  flex: 1;
  font-size: 0.8rem;
  color: var(--green-deep);
  font-weight: 500;
  word-break: break-all;
  text-align: left;
}

.btn-copy {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  background: var(--green);
  color: white;
  border: none;
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  white-space: nowrap;
  transition: all 0.2s;
  flex-shrink: 0;
}

.share-actions {
  display: flex;
  gap: 0.75rem;
  width: 100%;
  max-width: 380px;
}

.btn-share-wa {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: #25d366;
  color: white;
  border: none;
  padding: 0.75rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
}

.btn-home {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--green-pale);
  color: var(--green);
  text-decoration: none;
  padding: 0.75rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
}

/* ========================================
   GPS LOCATION PICKER
   ======================================== */
.gps-picker {
  border: 2px solid #c8e6c9;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--warm-white);
  transition: border-color 0.3s;
}

.gps-picker:has(#gpsSuccess:not(.hidden)) {
  border-color: #2e7d32;
}

/* Idle state */
.gps-idle {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  text-align: center;
}

.gps-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--green-pale);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green);
  animation: gpsFloat 3s ease-in-out infinite;
}

@keyframes gpsFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

.gps-idle-text strong {
  display: block;
  font-size: 0.9rem;
  color: var(--text-dark);
  margin-bottom: 0.2rem;
}

.gps-idle-text small {
  font-size: 0.78rem;
  color: var(--text-light);
  line-height: 1.5;
}

.btn-get-location {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, var(--green), var(--green-light));
  color: white;
  border: none;
  padding: 0.7rem 1.4rem;
  border-radius: 99px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  box-shadow: 0 4px 14px rgba(46,125,50,0.3);
  transition: all 0.2s;
}

.btn-get-location:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(46,125,50,0.4);
}

.btn-retry {
  margin-top: 0.5rem;
}

/* Loading state */
.gps-loading {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-mid);
  font-size: 0.88rem;
}

.gps-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--green-pale);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Success state */
.gps-success {
  padding: 1rem 1.25rem;
  background: linear-gradient(135deg, #e8f5e9, #f1f8e9);
}

.gps-success-top {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.gps-success-icon { font-size: 1.4rem; flex-shrink: 0; }

.gps-success-info { flex: 1; }
.gps-success-info strong {
  display: block;
  font-size: 0.88rem;
  color: #2e7d32;
  font-weight: 700;
}

.gps-coords {
  font-size: 0.75rem;
  color: #558b2f;
  font-family: monospace;
  letter-spacing: 0.3px;
}

.gps-clear-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(0,0,0,0.06);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
  transition: background 0.2s;
  flex-shrink: 0;
}

.gps-clear-btn:hover { background: rgba(211,47,47,0.12); color: #d32f2f; }

.gps-preview-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: #1565c0;
  font-weight: 600;
  text-decoration: none;
  background: rgba(21,101,192,0.08);
  padding: 0.45rem 0.9rem;
  border-radius: 99px;
  transition: background 0.2s;
}

.gps-preview-link:hover { background: rgba(21,101,192,0.15); }
.gps-preview-link svg { stroke: #1565c0; }

/* Error state */
.gps-error {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
}

.gps-error-icon { font-size: 1.8rem; }
.gps-error p { font-size: 0.85rem; color: #c62828; }