/* Builder Page Styles */

.builder-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--space-8) var(--space-4);
  min-height: 80vh;
}

/* ===== PROGRESS TRACKER ===== */
.builder-progress {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 800px;
  margin: 0 auto var(--space-10);
  padding: var(--space-6);
  background-color: var(--black-soft);
  border-radius: 12px;
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  flex: 1;
}

.progress-circle {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: var(--black-charcoal);
  border: 3px solid var(--black-charcoal);
  color: var(--cream-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--weight-bold);
  font-size: var(--text-lg);
  transition: all var(--transition-base);
}

.progress-step.active .progress-circle {
  background-color: var(--purple-dark);
  border-color: var(--gold-classic);
  color: var(--gold-classic);
  box-shadow: var(--glow-gold);
}

.progress-step.completed .progress-circle {
  background-color: var(--success);
  border-color: var(--success);
  color: white;
}

.progress-step.completed .progress-circle::after {
  content: '✓';
}

.progress-label {
  font-size: var(--text-sm);
  color: var(--cream-muted);
  font-weight: var(--weight-medium);
  transition: color var(--transition-base);
}

.progress-step.active .progress-label {
  color: var(--gold-classic);
}

.progress-line {
  flex: 1;
  height: 3px;
  background-color: var(--black-charcoal);
  margin: 0 var(--space-2);
  align-self: flex-start;
  margin-top: 23px;
}

.progress-step.completed ~ .progress-line,
.progress-step.active ~ .progress-line {
  background-color: var(--gold-classic);
}

@media (max-width: 767px) {
  .builder-progress {
    padding: var(--space-4);
  }
  
  .progress-circle {
    width: 40px;
    height: 40px;
    font-size: var(--text-base);
  }
  
  .progress-label {
    font-size: var(--text-xs);
  }
  
  .progress-line {
    margin-top: 18px;
  }
}

/* ===== BUILDER STEPS ===== */
.builder-step {
  display: none;
  animation: fadeIn 0.4s ease;
}

.builder-step.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.step-title {
  font-size: var(--text-4xl);
  color: var(--cream-warm);
  text-align: center;
  margin-bottom: var(--space-3);
}

.step-subtitle {
  text-align: center;
  font-size: var(--text-lg);
  color: var(--cream-muted);
  margin-bottom: var(--space-8);
}

/* ===== STEP 1: SERIES SELECTION ===== */
.series-options {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  max-width: 900px;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .series-options {
    grid-template-columns: repeat(2, 1fr);
  }
}

.series-option {
  background-color: var(--black-soft);
  border: 3px solid var(--black-charcoal);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
}

.series-option:hover {
  border-color: var(--gold-classic);
  transform: translateY(-8px);
  box-shadow: 0 12px 30px rgba(212, 175, 55, 0.3);
}

.series-option[data-series="acotar"]:hover {
  border-color: var(--purple-light);
}

.series-option[data-series="fourthwing"]:hover {
  border-color: var(--red-ruby);
}

.series-image {
  width: 100%;
  height: 300px;
  overflow: hidden;
  background-color: var(--black-charcoal);
}

.series-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.series-option:hover .series-image img {
  transform: scale(1.08);
}

.series-content {
  padding: var(--space-6);
  text-align: center;
}

.series-content h3 {
  font-size: var(--text-2xl);
  color: var(--gold-classic);
  margin-bottom: var(--space-2);
}

.series-content p {
  color: var(--cream);
  font-size: var(--text-base);
  margin-bottom: var(--space-4);
}

.series-badge {
  display: inline-block;
  padding: var(--space-2) var(--space-4);
  border-radius: 20px;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.series-badge-purple {
  background-color: var(--purple-medium);
  color: var(--cream);
}

.series-badge-red {
  background-color: var(--red-dark);
  color: var(--cream);
}

/* ===== STEP 2: BOOK OPTIONS ===== */
.book-options {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
  max-width: 800px;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .book-options {
    grid-template-columns: repeat(2, 1fr);
  }
}

.book-option {
  background-color: var(--black-soft);
  border: 3px solid var(--black-charcoal);
  border-radius: 10px;
  padding: var(--space-5);
  cursor: pointer;
  transition: all var(--transition-base);
  text-align: center;
}

.book-option:hover {
  border-color: var(--gold-classic);
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.book-option.selected {
  border-color: var(--gold-classic);
  background-color: var(--purple-dark);
}

.book-option h3 {
  font-size: var(--text-xl);
  color: var(--gold-classic);
  margin-bottom: var(--space-3);
}

.book-option .book-price {
  font-size: var(--text-3xl);
  color: var(--gold-bright);
  font-weight: var(--weight-black);
  margin-bottom: var(--space-2);
  font-family: var(--font-heading);
}

.book-option .price-label {
  font-size: var(--text-sm);
  color: var(--cream-muted);
  display: block;
  margin-bottom: var(--space-4);
}

.book-option ul {
  list-style: none;
  text-align: left;
  color: var(--cream);
  font-size: var(--text-sm);
}

.book-option li {
  padding: var(--space-1) 0;
}

.book-option li::before {
  content: '✓ ';
  color: var(--success);
  font-weight: bold;
}

/* ===== STEP 3: BOOK SELECTION ===== */
.book-selection-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
  max-width: 900px;
  margin: 0 auto var(--space-8);
}

@media (min-width: 768px) {
  .book-selection-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .book-selection-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.book-select-item {
  background-color: var(--black-soft);
  border: 3px solid var(--black-charcoal);
  border-radius: 10px;
  padding: var(--space-5);
  cursor: pointer;
  transition: all var(--transition-base);
  text-align: center;
  position: relative;
}

.book-select-item:hover {
  border-color: var(--purple-light);
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.book-select-item.selected {
  border-color: var(--gold-classic);
  background-color: var(--purple-dark);
}

.book-select-item.selected::after {
  content: '✓';
  position: absolute;
  top: 10px;
  right: 10px;
  width: 30px;
  height: 30px;
  background-color: var(--gold-classic);
  color: var(--black-true);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--weight-bold);
  font-size: var(--text-lg);
}

.book-select-item img {
  width: 120px;
  height: 180px;
  object-fit: contain;
  margin: 0 auto var(--space-3);
}

.book-select-item h4 {
  font-size: var(--text-lg);
  color: var(--cream-warm);
  margin-bottom: var(--space-2);
}

.book-select-item p {
  font-size: var(--text-sm);
  color: var(--cream-muted);
  margin: 0;
}

/* ===== STEP 4: DRINKS ===== */
.drinks-counter {
  text-align: center;
  font-size: var(--text-xl);
  color: var(--gold-classic);
  margin-bottom: var(--space-6);
  font-weight: var(--weight-semibold);
}

.drinks-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
  max-width: 900px;
  margin: 0 auto var(--space-8);
}

@media (min-width: 768px) {
  .drinks-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .drinks-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.drink-item {
  background-color: var(--black-soft);
  border: 2px solid var(--black-charcoal);
  border-radius: 10px;
  padding: var(--space-4);
  text-align: center;
  transition: all var(--transition-base);
}

.drink-item:hover {
  border-color: var(--purple-light);
  transform: translateY(-2px);
}

.drink-item.selected {
  border-color: var(--gold-classic);
  background-color: rgba(212, 175, 55, 0.1);
}

.drink-item img {
  width: 60px;
  height: 60px;
  margin: 0 auto var(--space-3);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

.drink-item h4 {
  font-size: var(--text-sm);
  color: var(--cream);
  margin-bottom: var(--space-3);
  min-height: 36px;
}

.drink-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
}

.drink-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--purple-medium);
  color: var(--cream);
  border: none;
  font-size: var(--text-lg);
  font-weight: var(--weight-bold);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 767px) {
  .drink-btn {
    width: 44px;
    height: 44px;
  }
}

.drink-btn:hover {
  background-color: var(--gold-classic);
  color: var(--black-true);
  transform: scale(1.1);
}

.drink-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: scale(1);
}

.drink-qty {
  font-size: var(--text-xl);
  font-weight: var(--weight-bold);
  color: var(--gold-classic);
  min-width: 30px;
}

/* ===== STEP NAVIGATION ===== */
.step-navigation {
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  max-width: 600px;
  margin: var(--space-8) auto 0;
}

.step-navigation .btn {
  flex: 1;
}

/* ===== STEP 4: REVIEW ===== */
.review-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
}

@media (min-width: 1024px) {
  .review-grid {
    grid-template-columns: 1.5fr 1fr;
  }
}

.review-summary,
.review-options {
  background-color: var(--black-soft);
  border: 2px solid var(--black-charcoal);
  border-radius: 12px;
  padding: var(--space-6);
}

.review-summary h3,
.review-options h3 {
  font-size: var(--text-2xl);
  color: var(--gold-classic);
  margin-bottom: var(--space-5);
  border-bottom: 2px solid var(--gold-classic);
  padding-bottom: var(--space-3);
}

.review-section {
  margin-bottom: var(--space-5);
}

.review-section h4 {
  font-size: var(--text-base);
  color: var(--cream-warm);
  margin-bottom: var(--space-2);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.review-section h4 i {
  color: var(--gold-classic);
}

.review-section p {
  color: var(--cream);
  margin: 0;
}

.review-section ul {
  list-style: none;
  color: var(--cream);
  font-size: var(--text-sm);
}

.review-section li {
  padding: var(--space-1) 0 var(--space-1) var(--space-5);
  position: relative;
}

.review-section li::before {
  content: '•';
  position: absolute;
  left: var(--space-3);
  color: var(--gold-classic);
}

/* ===== PRICING CARD ===== */
.price-card {
  background-color: var(--purple-dark);
  border-radius: 10px;
  padding: var(--space-5);
  margin-bottom: var(--space-6);
}

.price-row {
  display: flex;
  justify-content: space-between;
  padding: var(--space-2) 0;
  color: var(--cream-muted);
  font-size: var(--text-base);
}

.price-total-row {
  border-top: 2px solid rgba(212, 175, 55, 0.4);
  margin-top: var(--space-3);
  padding-top: var(--space-3);
  font-weight: var(--weight-bold);
  font-size: var(--text-xl);
  color: var(--cream-warm);
}

.price-total-row span:last-child {
  color: var(--gold-classic);
  font-size: var(--text-2xl);
  font-family: var(--font-heading);
}

/* ===== GIFT OPTIONS ===== */
.gift-options-card {
  background-color: var(--black-charcoal);
  border-radius: 10px;
  padding: var(--space-5);
  margin-bottom: var(--space-6);
}

.checkbox-wrapper {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}

.checkbox-wrapper input[type="checkbox"] {
  width: 24px;
  height: 24px;
  accent-color: var(--gold-classic);
}

.checkbox-wrapper label {
  font-size: var(--text-base);
  color: var(--cream);
  margin: 0;
  cursor: pointer;
}

.gift-fields {
  margin-top: var(--space-5);
  padding-top: var(--space-5);
  border-top: 1px solid var(--black-charcoal);
}

.form-group {
  margin-bottom: var(--space-5);
}

.form-group label {
  display: block;
  margin-bottom: var(--space-2);
  color: var(--cream-warm);
  font-weight: var(--weight-medium);
  font-size: var(--text-sm);
}

.form-group textarea {
  width: 100%;
  min-height: 80px;
}

.form-group small {
  display: block;
  margin-top: var(--space-2);
  color: var(--cream-muted);
  font-size: var(--text-xs);
}

.char-count {
  display: block;
  text-align: right;
  font-size: var(--text-xs);
  color: var(--cream-muted);
  margin-top: var(--space-1);
}

/* ===== BUTTONS ===== */
.btn-large {
  width: 100%;
  padding: var(--space-5);
  font-size: var(--text-lg);
  margin-bottom: var(--space-3);
}

.btn-large i {
  margin-right: var(--space-2);
}

.review-options .btn-ghost {
  width: 100%;
  text-align: center;
}
