/* ============================================================================
   CAMP FINDER STYLES - Extends HatDay base styles
   ============================================================================ */

/* Progress Steps */
.progress-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 40px;
  padding: 20px;
}

.progress-steps .step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  opacity: 0.4;
  transition: all 0.3s ease;
}

.progress-steps .step.active,
.progress-steps .step.completed {
  opacity: 1;
}

.progress-steps .step-num {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #e9e3ff;
  color: var(--text-subtle);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.progress-steps .step.active .step-num {
  background: var(--hat-purple);
  color: white;
  box-shadow: 0 4px 15px rgba(155, 124, 246, 0.4);
}

.progress-steps .step.completed .step-num {
  background: var(--hat-green);
  color: white;
}

.progress-steps .step.completed .step-num::after {
  content: '✓';
}

.progress-steps .step-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-subtle);
}

.progress-steps .step.active .step-label {
  color: var(--text-main);
}

.step-line {
  flex: 1;
  max-width: 80px;
  height: 3px;
  background: #e9e3ff;
  margin: 0 10px;
  margin-bottom: 28px;
}

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

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

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

.form-subtitle {
  color: var(--text-subtle);
  margin-bottom: 24px;
}

.form-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--card-border);
}

.form-hint {
  font-size: 0.9rem;
  color: var(--text-subtle);
  margin-top: 16px;
}

/* Kid Cards */
.kid-card {
  background: #faf8ff;
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 20px;
}

.kid-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.kid-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--hat-purple);
}

.btn-remove {
  background: none;
  border: none;
  color: #e74c3c;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: background 0.2s;
}

.btn-remove:hover {
  background: #fdeaea;
}

.kid-fields {
  margin-bottom: 16px;
}

.field-row {
  display: flex;
  gap: 16px;
}

.field {
  flex: 1;
}

.field-small {
  flex: 0 0 100px;
}

.field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-main);
}

.field input,
.field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d8cffd;
  border-radius: 10px;
  background: white;
  font-size: 1rem;
}

/* Interests Grid */
.interests-section label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-main);
}

.interests-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.interest-chip {
  padding: 8px 14px;
  border: 2px solid #e9e3ff;
  border-radius: 20px;
  background: white;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.interest-chip:hover {
  border-color: var(--hat-purple);
  background: #f8f5ff;
}

.interest-chip.selected {
  border-color: var(--hat-purple);
  background: var(--hat-purple);
  color: white;
}

/* Budget Slider */
.budget-slider-container {
  display: flex;
  align-items: center;
  gap: 20px;
}

.budget-slider-container input[type="range"] {
  flex: 1;
  height: 8px;
  border-radius: 4px;
  background: #e9e3ff;
  -webkit-appearance: none;
}

.budget-slider-container input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--hat-purple);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(155, 124, 246, 0.4);
}

.budget-display {
  text-align: center;
  min-width: 100px;
}

#budget-value {
  display: block;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--hat-purple);
}

.budget-label {
  font-size: 0.85rem;
  color: var(--text-subtle);
}

/* Checkbox Cards */
.checkbox-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.checkbox-card {
  cursor: pointer;
}

.checkbox-card input {
  display: none;
}

.checkbox-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  border: 2px solid #e9e3ff;
  border-radius: 14px;
  background: white;
  transition: all 0.2s ease;
  text-align: center;
}

.checkbox-card input:checked + .checkbox-content {
  border-color: var(--hat-purple);
  background: #f8f5ff;
}

.checkbox-icon {
  font-size: 2rem;
  margin-bottom: 8px;
}

.checkbox-title {
  font-weight: 600;
  color: var(--text-main);
}

.checkbox-desc {
  font-size: 0.85rem;
  color: var(--text-subtle);
}

/* Form Select */
.form-select {
  width: 100%;
  padding: 12px;
  border: 1px solid #d8cffd;
  border-radius: 10px;
  background: white;
  font-size: 1rem;
  cursor: pointer;
}

.form-group {
  margin-bottom: 24px;
}

.form-group > label {
  display: block;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-main);
}

/* Calendar Connection Section */
.calendar-connect-section {
  background: linear-gradient(135deg, #f0f7ff 0%, #e8f4f8 100%);
  border: 2px solid #d0e8ff;
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 20px;
}

.connect-option {
  display: flex;
  align-items: center;
  gap: 16px;
}

.connect-icon {
  font-size: 2.5rem;
  flex-shrink: 0;
}

.connect-info {
  flex: 1;
}

.connect-info h3 {
  margin: 0 0 4px;
  font-size: 1.1rem;
  color: #2c5282;
}

.connect-info p {
  margin: 0;
  font-size: 0.9rem;
  color: #4a7298;
}

.calendar-status {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 12px 16px;
  background: #e6ffed;
  border-radius: 10px;
  color: #276749;
}

.calendar-status .status-icon {
  font-size: 1.2rem;
  color: #38a169;
}

.btn-success {
  background: #38a169 !important;
  box-shadow: 0 4px 12px rgba(56, 161, 105, 0.3) !important;
}

.divider-or {
  display: flex;
  align-items: center;
  margin: 24px 0;
  color: var(--text-subtle);
  font-size: 0.9rem;
}

.divider-or::before,
.divider-or::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e2e8f0;
}

.divider-or span {
  padding: 0 16px;
}

.manual-label {
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 12px;
}

/* Weeks Grid */
.weeks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
}

.week-btn {
  padding: 14px 10px;
  border: 2px solid #e9e3ff;
  border-radius: 12px;
  background: white;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.week-btn:hover {
  border-color: var(--hat-purple);
}

.week-btn.blocked {
  border-color: #e74c3c;
  background: #fdeaea;
}

.week-label {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main);
}

.week-status {
  display: block;
  font-size: 0.8rem;
  margin-top: 4px;
  color: var(--hat-green);
}

.week-btn.blocked .week-status {
  color: #e74c3c;
}

/* Loading Spinner */
.loading-spinner {
  text-align: center;
  padding: 60px 20px;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #e9e3ff;
  border-top-color: var(--hat-purple);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 20px;
}

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

/* Results Cards */
.results-card {
  max-width: 900px;
  margin: 0 auto;
}

.camp-result-card {
  display: grid;
  grid-template-columns: 50px 1fr auto auto;
  gap: 16px;
  align-items: center;
  padding: 20px;
  background: #faf8ff;
  border: 1px solid var(--card-border);
  border-radius: 14px;
  margin-bottom: 16px;
  animation: slideIn 0.4s ease backwards;
}

@keyframes slideIn {
  from { opacity: 0; transform: translateX(-20px); }
  to { opacity: 1; transform: translateX(0); }
}

.camp-rank {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: var(--hat-purple);
  color: white;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.camp-info {
  min-width: 0;
}

.camp-name {
  margin: 0 0 6px;
  font-size: 1.1rem;
  color: var(--text-main);
}

.camp-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.85rem;
}

.camp-category {
  background: #e9e3ff;
  color: var(--hat-purple);
  padding: 3px 10px;
  border-radius: 12px;
  font-weight: 500;
}

.camp-ages,
.camp-location {
  color: var(--text-subtle);
}

.match-reasons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.reason-tag {
  font-size: 0.8rem;
  color: var(--hat-green);
  background: #e8f8f0;
  padding: 3px 8px;
  border-radius: 8px;
}

.camp-score {
  text-align: center;
}

.score-circle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: conic-gradient(
    var(--hat-green) calc(var(--score) * 1%),
    #e9e3ff calc(var(--score) * 1%)
  );
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.score-circle::before {
  content: '';
  position: absolute;
  width: 48px;
  height: 48px;
  background: white;
  border-radius: 50%;
}

.score-circle span {
  position: relative;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--hat-green);
}

.score-label {
  font-size: 0.75rem;
  color: var(--text-subtle);
  margin-top: 4px;
  display: block;
}

.camp-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-small {
  padding: 8px 14px;
  font-size: 0.85rem;
}

.btn-secondary {
  background: white;
  color: var(--text-main);
  border: 2px solid var(--card-border);
}

.btn-secondary:hover {
  border-color: var(--hat-purple);
  background: #f8f5ff;
}

/* Error & Empty States */
.error-state,
.no-results {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-subtle);
}

.error-detail {
  font-size: 0.9rem;
  color: #e74c3c;
  margin-bottom: 20px;
}

/* Camp Hero */
.camp-hero-content {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

/* Responsive */
@media (max-width: 768px) {
  .progress-steps {
    flex-wrap: wrap;
    gap: 10px;
  }
  
  .step-line {
    display: none;
  }
  
  .progress-steps .step {
    flex: 0 0 calc(50% - 10px);
  }
  
  .field-row {
    flex-direction: column;
  }
  
  .field-small {
    flex: 1;
  }
  
  .checkbox-group {
    grid-template-columns: 1fr;
  }
  
  .camp-result-card {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .camp-rank {
    margin: 0 auto;
  }
  
  .camp-meta {
    justify-content: center;
  }
  
  .match-reasons {
    justify-content: center;
  }
  
  .camp-actions {
    flex-direction: row;
    justify-content: center;
  }
}
