/* Multi-step Form Styles */
.multi-step-form {
  position: relative;
}

#signupForm {
  max-width: 36rem;
  width: 100%;
  margin: 0 auto;
}

.form-step {
  display: none;
  animation: fadeIn 0.3s ease-in-out;
  width: 100%;
}

.form-step[data-step="1"] {
  display: block;
}

.form-step h2 {
  margin-bottom: 0.5rem;
  font-size: 1.5rem;
  color: var(--text-color);
  text-align: center;
}

.form-step .customFormMessage {
  text-align: center;
  margin-bottom: 1rem;
}

/* Form Field Styles */
.name-fields {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
}

.form-field {
  margin: 0.5rem 0;
  position: relative;
}

.name-fields .form-field {
  flex: 1;
  margin-bottom: 0;
}

.form-field input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  font-family: "Poppins", sans-serif;
  font-size: 1rem;
  transition: all 0.2s ease-out;
}

/* Adjust padding for inputs with prefix */
.form-field:has(.id-prefix) input[type="number"] {
  padding-left: 2.5rem;
}

.form-field input:focus {
  outline: none;
  border-color: var(--accent-color);
}

.form-field label {
  position: absolute;
  left: 1rem;
  top: 0.75rem;
  color: #999;
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.2s ease-out;
  pointer-events: none;
  background-color: transparent;
}

.phone-field-container label
{
  left: 4rem;
} 

.id-prefix {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  color: #999;
  pointer-events: none;
  opacity: 0;
  transition: all 0.2s ease-out;
  width: 1.5rem;
  text-align: center;
}

.form-field:hover .id-prefix,
.form-field input:focus ~ .id-prefix,
.form-field input:not(:placeholder-shown) ~ .id-prefix {
  opacity: 1;
  color: var(--accent-color);
}

.form-field:hover label,
.form-field input:focus + label,
.form-field input:not(:placeholder-shown) + label {
  background-color: var(--background-color);
  padding: 0 0.25rem;
  top: -0.6rem;
  font-size: 0.85rem;
  color: var(--accent-color);
  left: 0.75rem;
}

.form-field input::placeholder {
  color: transparent;
}

/* Hide number input spinners */
.form-field input[type="number"]::-webkit-inner-spin-button,
.form-field input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.form-field input[type="number"] {
  -moz-appearance: textfield;
}

/* Password field adjustments */
.password-field {
  position: relative;
}

.password-input-wrapper {
  position: relative;
}

.password-input-wrapper label {
  background-color: var(--background-color);
}

/* Error Styles */
.form-field input.error-input,
.form-field select.error-input,
.form-field textarea.error-input,
.custom-form-field input.error-input,
.custom-form-field select.error-input,
.custom-form-field textarea.error-input {
  border-color: #ff3b30;
  background-color: #fff8f8;
}

.form-field input.error-input::placeholder,
.custom-form-field input.error-input::placeholder {
  color: #ff3b30;
}

/* Hide error message containers as we're using border styling instead */
.error-message {
  display: none;
}

/* Step Indicators */
.step-indicators {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  position: relative;
  padding: 0 10px;
  height: 60px; /* Fixed height for the indicators */
}

.step-line {
  position: absolute;
  top: 15px;
  left: 30px;
  right: 30px;
  height: 2px;
  background-color: #e0e0e0;
  z-index: 1;
}

.step-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 2;
  flex: 1;
}

.step-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-color: #f0f0f0;
  border: 2px solid #ddd;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
  font-weight: bold;
  color: #666;
}

.step-indicator.active .step-circle {
  background-color: #fff;
  color: var(--accent-color);
  border-color: var(--accent-color);
}

.step-indicator.completed .step-circle {
  background-color: var(--accent-color);
  border-color: var(--accent-color);
  color: #fff;
}

.step-label {
  font-size: 12px;
  text-align: center;
  color: #666;
}

.step-indicator.active .step-label {
  color: var(--accent-color);
  font-weight: bold;
}

.step-indicator.completed .step-label {
  color: var(--accent-color);
}

.warning-text {
  background-color: #f8f9fa;
  border: 1px solid #eee;
  padding: 0.5rem;
  color: var(--secondary-color);
  font-size: 0.9rem;
  border-radius: var(--border-radius);
  line-height: 1.4;
  text-align: center;
}

.confirmation-details {
  margin-bottom: 1rem;
}

.confirmation-details .details {
  padding: 0.5rem 0;
}

.details ul {
  list-style: none;
}

.details li {
  margin-bottom: 0.5rem;
}

.trans-id {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

/* Password Field Styles */
.password-field {
  position: relative;
}

.password-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.password-input-wrapper input {
  padding-right: 40px;
}

.toggle-password {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: 5px;
  color: #666;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toggle-password:hover {
  color: var(--accent-color);
}

.toggle-password ion-icon {
  font-size: 1.2rem;
}

/* Review Section Password Toggle */
.review-toggle {
  position: relative;
  right: auto;
  top: auto;
  transform: none;
  margin-left: 8px;
  display: inline-flex;
  vertical-align: middle;
}

.password-display {
  display: inline-block;
  vertical-align: middle;
}

/* Review Section Styles */
.form-review {
  background: #f8f9fa;
  padding: 1rem;
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
}

.review-text {
  color: #666;
  margin-bottom: 1.5rem;
  line-height: 1.4;
  text-align: center;
}

.review-section {
  background: white;
  padding: 1rem;
  border-radius: var(--border-radius);
  margin-bottom: 0.5rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  width: 100%;
}

.review-section:last-child {
  margin-bottom: 0;
}

.review-section h3 {
  color: var(--text-color);
  font-size: 1.1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #eee;
}
.review-section .line{
  border-top: 1px solid #eee ;
  margin-bottom: 0.5rem; 
  margin-top: 0.75rem; 
}
.review-section p {
  color: #444;
  line-height: 1.4;
  display: flex;
  align-items: flex-start;
}

.review-section strong {
  color: var(--text-color);
  font-weight: 500;
  flex-shrink: 0;
}

.review-section p span {
  flex: 1;
  word-break: break-word;
}

.total {
  color: var(--accent-color);
  font-weight: 600;
  font-size: 1.2rem;
}

/* Stacked info field styles - NEW */
.info-field-stacked {
  margin-bottom: 0.5rem;
}

.info-field-stacked:last-child {
  margin-bottom: 0;
  margin-top: 0.5rem;
}

.info-label {
  font-size: 0.8rem;
  color: #666;
  /* margin-bottom: 0.2rem; */
  font-weight: 500;
}

.info-value {
  font-size: 1rem;
  color: var(--text-color);
  font-weight: 500;
}

/* Order Info and Price Summary Styles */
.order-info {
  line-height: 1.8;
}

.order-info strong {
  display: inline-block;
  width: 100px;
  color: var(--text-color);
  vertical-align: top;
}

.order-info span {
  display: inline-block;
  vertical-align: top;
}

.price-summary {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
  line-height: 1.8;
}

.price-summary strong {
  display: inline-block;
  width: 100px;
  color: var(--text-color);
}

.price-summary .total span {
  font-weight: 600;
  font-size: 1.2rem;
}

/* Animation keyframe */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Base Responsive Styles */
@media (max-width: 768px) {
  #signupForm {
    width: 100%;
  }

  .form-step h2 {
    font-size: 1.3rem;
  }

  .form-field input {
    font-size: 0.95rem;
  }

  .warning-text {
    font-size: 0.85rem;
    margin-top: 1rem;
  }

  .payment-method {
    padding: 1rem;
  }

  .payment-method ol {
    font-size: 0.9rem;
  }
  .review-text {
    text-align: center;
  }

  .form-review {
    padding: 1rem;
    margin: 0;
  }

  .review-section {
    padding: 1rem;
    width: auto;
  }

  .review-section h3 {
    font-size: 1rem;
  }

  .order-info strong {
    min-width: 70px;
  }

  #addonsList {
    padding-left: 70px;
  }
}

/* ========================================
   SIGNUP POPUP SPECIFIC STYLES 
   ======================================== */

/* Signup Popup Container Styles */
.signup-popup .popup-content {
  max-width: 600px;
  padding: 0;
  height: auto;
  max-height: 85vh;
}

.signup-popup .close-popup {
  top: 1rem;
  right: 1rem;
}

.signup-popup #signupForm {
  background: var(--background-color);
  border-radius: var(--border-radius);
  box-shadow: none;
  margin: 0;
  height: 100%;
}

.signup-popup .multi-step-form {
  position: relative;
  height: 100%;
  overflow-y: auto;
}

.signup-popup .form-step {
  padding: 1.5rem;
  display: none;
  animation: fadeIn 0.3s ease-in-out;
}

.signup-popup .form-step[data-step="1"] {
  display: block;
}

.signup-popup .form-step h2 {
  margin-bottom: 1rem;
  font-size: 1.5rem;
  color: var(--text-color);
  text-align: center;
}

/* Custom Form Fields Styles */
#customFormFields {
  margin-bottom: 1rem;
}

.custom-form-field {
  margin: 0.5rem 0;
  position: relative;
}

.custom-form-field input[type="text"],
.custom-form-field input[type="email"],
.custom-form-field input[type="tel"],
.custom-form-field input[type="number"],
.custom-form-field input[type="date"],
.custom-form-field select,
.custom-form-field textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  font-family: "Poppins", sans-serif;
  font-size: 1rem;
  transition: all 0.2s ease-out;
}

.custom-form-field input:focus,
.custom-form-field select:focus,
.custom-form-field textarea:focus {
  outline: none;
  border-color: var(--accent-color);
}

/* Floating label style to match personal info form */
.custom-form-field label {
  position: absolute;
  left: 1rem;
  top: 0.75rem;
  color: #999;
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.2s ease-out;
  pointer-events: none;
  background-color: transparent;
}

.custom-form-field:hover label,
.custom-form-field input:focus + label,
.custom-form-field input:not(:placeholder-shown) + label,
.custom-form-field select:focus + label,
.custom-form-field select:not([value=""]):not([value=" "]) + label,
.custom-form-field textarea:focus + label,
.custom-form-field textarea:not(:placeholder-shown) + label {
  background-color: var(--background-color);
  padding: 0 0.25rem;
  top: -0.6rem;
  font-size: 0.85rem;
  color: var(--accent-color);
  left: 0.75rem;
}

.custom-form-field input::placeholder,
.custom-form-field select::placeholder,
.custom-form-field textarea::placeholder {
  color: transparent;
}

.custom-form-field select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23131313%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem top 50%;
  background-size: 0.65rem auto;
  padding-right: 2.5rem;
}

.custom-form-field .checkbox-container {
  display: flex;
  align-items: center;
  padding: 0.75rem 0;
}

.custom-form-field .checkbox-container input[type="checkbox"] {
  margin-right: 0.5rem;
  width: 1.2rem;
  height: 1.2rem;
}

.custom-form-field .checkbox-container span {
  font-weight: 500;
  color: var(--text-color);
}

.help-text {
  font-size: 0.85rem;
  color: #666;
  margin-top: 0.5rem;
  text-align: center;
}

.custom-form-field.error input,
.custom-form-field.error select,
.custom-form-field.error textarea {
  border-color: #ff3b30;
  background-color: #fff8f8;
}

.custom-form-field .error-message {
  color: #ff3b30;
  font-size: 0.8rem;
  margin-top: 0.5rem;
}

/* Custom Password Field Styles */
.custom-form-field.password-field {
  position: relative;
}

.custom-form-field .password-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.custom-form-field .password-input-wrapper input {
  padding-right: 40px;
}

.custom-form-field .toggle-password {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: 5px;
  color: #666;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.custom-form-field .toggle-password:hover {
  color: var(--accent-color);
}

.custom-form-field .toggle-password ion-icon {
  font-size: 1.2rem;
}

/* Review Section Styles for Custom Fields */
#customFieldsReview p {
  margin: 0.75rem 0;
  color: #444;
  line-height: 1.4;
  display: flex;
  align-items: flex-start;
}

#customFieldsReview strong {
  color: var(--text-color);
  font-weight: 500;
  min-width: 120px;
  flex-shrink: 0;
}

#customFieldsReview p span {
  flex: 1;
  word-break: break-word;
}

/* Popup-specific Responsive Styles */
@media (max-width: 768px) {
  .signup-popup .popup-content {
    max-width: 100%;
    padding: 1rem;
  }

  .signup-popup .form-step {
    padding: 1rem;
  }

  .signup-popup .form-step h2 {
    font-size: 1.3rem;
  }

  #customFieldsReview strong {
    min-width: 100px;
  }
}

/* Overlay Popup Step Indicators - Enhanced Visibility */
.popup.active #signupStepIndicators,
.popup.active .step-indicators {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  position: sticky !important;
  top: 0 !important;
  z-index: 10 !important;
  margin-bottom: 2.5rem !important;
  width: 100% !important;
  background: var(--background-color) !important;
  padding-top: 10px !important;
}

.popup.active .step-indicator {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  position: relative !important;
  z-index: 2 !important;
  flex: 1 !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.popup.active .step-circle {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 30px !important;
  height: 30px !important;
  border-radius: 50% !important;
  margin-bottom: 8px !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.popup.active .step-indicator.active .step-circle {
  background-color: #fff !important;
  border-color: var(--accent-color, #0088cc) !important;
  color: var(--accent-color, #0088cc) !important;
}

.popup.active .step-indicator.completed .step-circle {
  background-color: var(--accent-color, #0088cc) !important;
  border-color: var(--accent-color, #0088cc) !important;
  color: #fff !important;
}

.popup.active .step-label {
  font-size: 12px !important;
  text-align: center !important;
  color: #666 !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.popup.active .step-indicator.active .step-label {
  color: var(--accent-color, #0088cc) !important;
  font-weight: bold !important;
}
