/* Trip Booking Wizard - Styles */
:root {
  --tbw-primary: #1a6e8e;
  --tbw-primary-light: #e8f4f8;
  --tbw-primary-dark: #145a73;
  --tbw-accent: #f0a500;
  --tbw-text: #1c1c2e;
  --tbw-muted: #6b7280;
  --tbw-border: #e2e8f0;
  --tbw-bg: #f8fafc;
  --tbw-white: #ffffff;
  --tbw-radius: 16px;
  --tbw-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  --tbw-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.tbw-wrapper {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  max-width: 760px;
  margin: 0 auto;
  padding: 0 16px;
  color: var(--tbw-text);
}

/* Progress Bar */
.tbw-progress {
  margin-bottom: 36px;
}

.tbw-progress-bar-track {
  height: 6px;
  background: var(--tbw-border);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 12px;
}

.tbw-progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--tbw-primary), var(--tbw-accent));
  border-radius: 99px;
  transition: var(--tbw-transition);
}

.tbw-progress-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--tbw-muted);
}

.tbw-progress-labels span.active {
  color: var(--tbw-primary);
  font-weight: 600;
}

/* Step Container */
.tbw-step {
  display: none;
  animation: tbwFadeIn 0.4s ease;
}

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

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

.tbw-step-header {
  text-align: center;
  margin-bottom: 32px;
}

.tbw-step-icon {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
}

.tbw-step-header h2 {
  font-size: 26px;
  font-weight: 700;
  margin: 0 0 8px;
  color: var(--tbw-text);
}

.tbw-step-header p {
  font-size: 15px;
  color: var(--tbw-muted);
  margin: 0;
}

/* Cards Grid */
.tbw-cards {
  display: grid;
  gap: 14px;
}

.tbw-cards.cols-3 {
  grid-template-columns: repeat(3, 1fr);
}

.tbw-cards.cols-2 {
  grid-template-columns: repeat(2, 1fr);
}

.tbw-cards.cols-1 {
  grid-template-columns: 1fr;
}

@media (max-width: 560px) {
  .tbw-cards.cols-3,
  .tbw-cards.cols-2 {
    grid-template-columns: 1fr;
  }
}

.tbw-card {
  background: var(--tbw-white);
  border: 2px solid var(--tbw-border);
  border-radius: var(--tbw-radius);
  padding: 22px 18px;
  cursor: pointer;
  transition: var(--tbw-transition);
  text-align: center;
  position: relative;
  user-select: none;
}

.tbw-card:hover {
  border-color: var(--tbw-primary);
  box-shadow: 0 4px 16px rgba(26, 110, 142, 0.12);
  transform: translateY(-2px);
}

.tbw-card.selected {
  border-color: var(--tbw-primary);
  background: var(--tbw-primary-light);
  box-shadow: 0 4px 20px rgba(26, 110, 142, 0.18);
}

.tbw-card.selected::after {
  content: '✓';
  position: absolute;
  top: 10px;
  right: 14px;
  width: 24px;
  height: 24px;
  background: var(--tbw-primary);
  color: white;
  border-radius: 50%;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 24px;
}

.tbw-card-icon {
  font-size: 36px;
  margin-bottom: 10px;
  display: block;
}

.tbw-card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--tbw-text);
  margin-bottom: 4px;
}

.tbw-card-desc {
  font-size: 13px;
  color: var(--tbw-muted);
  line-height: 1.4;
}

.tbw-card-price {
  font-size: 13px;
  font-weight: 600;
  color: var(--tbw-primary);
  margin-top: 8px;
}

/* Package cards special styles */
.tbw-card[data-value="heaven"] .tbw-card-icon { filter: drop-shadow(0 2px 6px gold); }
.tbw-card[data-value="ultra_luxury"] .tbw-card-icon { filter: drop-shadow(0 2px 6px #c0c0c0); }

/* Duration Selector */
.tbw-duration-wrap {
  background: var(--tbw-white);
  border: 2px solid var(--tbw-border);
  border-radius: var(--tbw-radius);
  padding: 32px;
  text-align: center;
}

.tbw-duration-display {
  font-size: 72px;
  font-weight: 800;
  color: var(--tbw-primary);
  line-height: 1;
  margin-bottom: 8px;
}

.tbw-duration-label {
  font-size: 18px;
  color: var(--tbw-muted);
  margin-bottom: 28px;
}

.tbw-duration-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

.tbw-duration-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--tbw-primary);
  background: var(--tbw-white);
  color: var(--tbw-primary);
  font-size: 26px;
  cursor: pointer;
  transition: var(--tbw-transition);
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.tbw-duration-btn:hover {
  background: var(--tbw-primary);
  color: var(--tbw-white);
}

.tbw-duration-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.tbw-duration-slider {
  width: 100%;
  max-width: 300px;
  margin: 20px auto 0;
  accent-color: var(--tbw-primary);
}

/* Family size input */
.tbw-family-extra {
  margin-top: 20px;
  padding: 20px;
  background: var(--tbw-primary-light);
  border-radius: 12px;
  text-align: center;
  display: none;
}

.tbw-family-extra.visible { display: block; }

.tbw-family-extra label {
  font-size: 15px;
  font-weight: 600;
  color: var(--tbw-text);
  display: block;
  margin-bottom: 10px;
}

.tbw-number-input {
  width: 100px;
  padding: 10px;
  border: 2px solid var(--tbw-primary);
  border-radius: 10px;
  font-size: 18px;
  text-align: center;
  font-weight: 700;
  color: var(--tbw-primary);
  outline: none;
}

/* Activities Section */
.tbw-days-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tbw-day-block {
  background: var(--tbw-white);
  border: 2px solid var(--tbw-border);
  border-radius: var(--tbw-radius);
  overflow: hidden;
  transition: var(--tbw-transition);
}

.tbw-day-block.completed {
  border-color: var(--tbw-primary);
}

.tbw-day-header {
  padding: 14px 20px;
  background: var(--tbw-bg);
  border-bottom: 1px solid var(--tbw-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.tbw-day-block.completed .tbw-day-header {
  background: var(--tbw-primary-light);
  border-bottom-color: var(--tbw-primary);
}

.tbw-day-number {
  font-size: 14px;
  font-weight: 700;
  color: var(--tbw-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.tbw-day-selected {
  font-size: 13px;
  color: var(--tbw-muted);
  font-style: italic;
}

.tbw-day-block.completed .tbw-day-selected {
  color: var(--tbw-primary);
  font-style: normal;
  font-weight: 600;
}

.tbw-activities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  padding: 16px;
}

.tbw-activity-item {
  border: 2px solid var(--tbw-border);
  border-radius: 10px;
  padding: 12px 10px;
  cursor: pointer;
  text-align: center;
  transition: var(--tbw-transition);
  background: var(--tbw-white);
  user-select: none;
}

.tbw-activity-item:hover {
  border-color: var(--tbw-primary);
  background: var(--tbw-primary-light);
}

.tbw-activity-item.selected {
  border-color: var(--tbw-primary);
  background: var(--tbw-primary);
  color: white;
}

.tbw-activity-item.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.tbw-activity-emoji {
  font-size: 28px;
  display: block;
  margin-bottom: 6px;
}

.tbw-activity-name {
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
}

.tbw-activity-cost {
  font-size: 11px;
  margin-top: 4px;
  opacity: 0.8;
}

/* Activities summary */
.tbw-activities-progress {
  padding: 10px 16px;
  font-size: 13px;
  color: var(--tbw-muted);
  border-top: 1px solid var(--tbw-border);
  text-align: center;
}

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

.tbw-btn {
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: var(--tbw-transition);
  letter-spacing: 0.03em;
}

.tbw-btn-back {
  background: var(--tbw-bg);
  color: var(--tbw-muted);
  border: 2px solid var(--tbw-border);
}

.tbw-btn-back:hover {
  border-color: var(--tbw-primary);
  color: var(--tbw-primary);
}

.tbw-btn-next {
  background: linear-gradient(135deg, var(--tbw-primary), var(--tbw-primary-dark));
  color: white;
  box-shadow: 0 4px 14px rgba(26, 110, 142, 0.35);
  margin-left: auto;
}

.tbw-btn-next:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(26, 110, 142, 0.45);
}

.tbw-btn-next:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.tbw-btn-submit {
  background: linear-gradient(135deg, #16a34a, #15803d);
  color: white;
  box-shadow: 0 4px 14px rgba(22, 163, 74, 0.35);
  margin-left: auto;
}

.tbw-btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(22, 163, 74, 0.45);
}

/* Summary / Results */
.tbw-summary {
  background: var(--tbw-white);
  border-radius: var(--tbw-radius);
  overflow: hidden;
  box-shadow: var(--tbw-shadow);
}

.tbw-summary-header {
  background: linear-gradient(135deg, var(--tbw-primary), var(--tbw-primary-dark));
  color: white;
  padding: 32px;
  text-align: center;
}

.tbw-summary-header h2 {
  font-size: 24px;
  margin: 0 0 6px;
  color: white;
}

.tbw-summary-header p {
  opacity: 0.85;
  margin: 0;
  font-size: 15px;
}

.tbw-summary-body {
  padding: 28px;
}

.tbw-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 14px 0;
  border-bottom: 1px solid var(--tbw-border);
  gap: 12px;
}

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

.tbw-summary-label {
  font-size: 14px;
  color: var(--tbw-muted);
  font-weight: 500;
  flex-shrink: 0;
}

.tbw-summary-value {
  font-size: 15px;
  font-weight: 700;
  color: var(--tbw-text);
  text-align: right;
}

.tbw-cost-box {
  background: linear-gradient(135deg, var(--tbw-primary-light), #f0f9ff);
  border: 2px solid var(--tbw-primary);
  border-radius: 14px;
  padding: 24px;
  text-align: center;
  margin-top: 24px;
}

.tbw-cost-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--tbw-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}

.tbw-cost-range {
  font-size: 36px;
  font-weight: 800;
  color: var(--tbw-primary);
  line-height: 1.1;
  margin-bottom: 6px;
}

.tbw-cost-note {
  font-size: 12px;
  color: var(--tbw-muted);
}

.tbw-activities-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
  justify-content: flex-end;
}

.tbw-tag {
  background: var(--tbw-primary-light);
  color: var(--tbw-primary);
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
}

/* Reset / restart */
.tbw-restart-btn {
  display: block;
  width: 100%;
  margin-top: 20px;
  padding: 13px;
  background: var(--tbw-bg);
  border: 2px solid var(--tbw-border);
  border-radius: 10px;
  color: var(--tbw-muted);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--tbw-transition);
}

.tbw-restart-btn:hover {
  border-color: var(--tbw-primary);
  color: var(--tbw-primary);
}

/* Validation error */
.tbw-error {
  color: #dc2626;
  font-size: 13px;
  text-align: center;
  margin-top: 12px;
  display: none;
}

.tbw-error.visible { display: block; }
