/* ===== GUEST CHECKOUT POPUP STYLES ===== */
#guest-checkout-popup {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  animation: fadeIn 0.3s ease-out;
  display: none;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.checkout-background {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.85), rgba(30, 30, 30, 0.9));
  backdrop-filter: blur(10px);
}

.checkout-container {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

/* Responsive popup constraints */
.checkout-container {
  /* Ensure popup never exceeds viewport */
  max-width: calc(100vw - 20px);
  max-height: calc(100vh - 0px);
  box-sizing: border-box;
}


.checkout-card {
  position: relative;
  background: #ffffff;
  border-radius: 24px;
  width: 100%;
  max-width: 480px;
  min-height: 660px;
  margin: 20px;
  box-shadow: 
    0 32px 64px -12px rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(255, 255, 255, 0.05);
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
    /* Constrain popup to viewport dimensions */
  max-width: min(480px, calc(100vw - 40px));
  max-height: calc(100vh - 20px);
  width: 100%;
  box-sizing: border-box;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Close button */
.checkout-close-btn {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 30px;
  height: 30px;
  border: none;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #64748B;
  z-index: 10;
}

.checkout-close-btn:hover {
  background: rgba(0, 0, 0, 0.1);
  transform: scale(1.05);
}

.checkout-close-btn svg {
  transition: transform 0.2s ease;
}

.checkout-close-btn:hover svg {
  transform: rotate(90deg);
}
/* Header */
.checkout-header {
  padding: 24px 24px 20px 24px;
  text-align: center;
   background: #F8FAFC;
  border-bottom: 1px solid #E2E8F0;
}

/* Fixed Header */
.checkout-header-fixed {
  padding: 24px 24px 20px 24px;
  text-align: center;
  background: #F8FAFC;
  border-bottom: 1px solid #E2E8F0;
  flex-shrink: 0;
}

/* Fixed Footer */
.checkout-footer-fixed {
  padding: 16px 24px;
  text-align: center;
  background: #F8FAFC;
  border-top: 1px solid #E2E8F0;
  flex-shrink: 0;
}

.footer-text {
  color: #30c130;
  font-size: 14px;
  font-weight: 600;
  margin: 0;
}

/* Progress Steps */
.progress-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5px 0 0 0;
  margin-top: 6px;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.progress-steps .step-number {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #E2E8F0;
  color: #64748B;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s ease;
}

/* Clickable steps */
.step.clickable {
  cursor: pointer;
}

.progress-steps .step.clickable:hover  .step-number {
  background: #CBD5E1;
  transform: scale(1.05);
}

.progress-steps .step.clickable.active:hover .step-number {
  background: #de1624;
}

.progress-steps .step.clickable.completed:hover .step-number {
  background: #de1624;
}

.progress-steps .step.active .step-number {
  background: #de1624;
  color: white;
}

.progress-steps .step.completed .step-number {
  background: #de1624;
  color: white;
}

@media ((max-width: 640px) or (max-height: 640px)) and (orientation: landscape) {
.progress-steps{
  display: none;
}
.checkout-header-fixed{
  padding: 8px;
}
}

.step-label {
  font-size: 12px;
  font-weight: 500;
  color: #64748B;
  text-align: center;
  line-height: 1.2;
  transition: all 0.3s ease;
}

.step.active .step-label {
  color: #de1624;
  font-weight: 600;
}

.step.completed .step-label {
  color: #de1624;
  font-weight: 600;
}

.step-line {
  width: 60px;
  height: 2px;
  background: #E2E8F0;
  margin: 0 16px;
  position: relative;
  overflow: hidden;
}

.step-line::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0%;
  height: 100%;
  background: #de1624;
  transition: width 0.5s ease;
}

.step.completed + .step-line::after {
  width: 100%;
}



.checkout-title {
  font-size: 28px;
  font-weight: 700;
  color: #0F172A;
  margin: 0 0 12px 0;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.checkout-subtitle {
  font-size: 16px;
  color: #64748B;
  margin: 0;
  line-height: 1.5;
  font-weight: 400;
}

/* Multi-step container */
.checkout-steps-container {
  position: relative;
  overflow: hidden;
  flex: 1;
  display: flex;
  flex-direction: column;
  scrollbar-color: #de1624 #ccc;
}

.checkout-step {
  opacity: 0;
  transform: translateX(100%);
  transition: all 0.4s ease-in-out;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  overflow-y: auto;
}

.checkout-step.active {
  opacity: 1;
  transform: translateX(0);
  position: relative;
  pointer-events: all;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.checkout-step.sliding-out {
  opacity: 0;
  transform: translateX(-100%);
}

.checkout-step.sliding-out-reverse {
  opacity: 0;
  transform: translateX(100%);
}

/* Success message */
.checkout-success {
  padding: 40px 24px;
  font-size: 20px;
  text-align: center;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  /*background-image: url('../assets-static/img/inside-bosspod.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;*/
}

/*.checkout-success::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.88);
  z-index: 1;
}*/

.checkout-success > * {
  position: relative;
  z-index: 2;
}

.checkout-success p{
 margin-bottom: 0;
 line-height: 24px;
 text-align: left;
 font-size: 18px;
 color: #2d5016;
 font-weight: 500;
}

.checkout-success svg {
  filter: drop-shadow(0 2px 4px rgba(0, 80, 0, 0.2));
}

@media (max-width: 640px) or (max-height: 640px) {
  .checkout-success {
    padding: 24px 10px;
  }
  .checkout-success p{
    font-size: 15px;
  }
  
  .checkout-success::before {
    background: rgba(255, 255, 255, 0.92);
  }
}
/* Form */
.checkout-form {
  padding: 24px 24px 0px 24px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 0px;
  overflow-y: auto;
}

/* Required field star */
.required {
  color: #de1624;
  font-weight: bold;
}

/* Textarea styling */
.form-field textarea {
  width: 100%;
  min-height: 80px;
  padding: 16px 16px;
  border: 2px solid #E2E8F0;
  border-radius: 12px;
  font-size: 16px;
  color: #1E293B;
  background: #ffffff;
  transition: all 0.2s ease;
  box-sizing: border-box;
  font-family: inherit;
  resize: vertical;
}

.form-field textarea:focus {
  outline: none;
  border-color: #de1624;
  box-shadow: 0 0 0 3px rgba(222, 22, 36, 0.1);
}

.form-field textarea::placeholder {
  color: #94A3B8;
  font-weight: 400;
}

/* Select dropdown styling */
.form-field select {
  width: 100%;
  height: 56px;
  padding: 16px 16px;
  border: 2px solid #E2E8F0;
  border-radius: 12px;
  font-size: 16px;
  color: #1E293B;
  background: #ffffff;
  transition: all 0.2s ease;
  box-sizing: border-box;
  font-family: inherit;
  cursor: pointer;
}

.form-field select:focus {
  outline: none;
  border-color: #de1624;
  box-shadow: 0 0 0 3px rgba(222, 22, 36, 0.1);
}

.form-field select option {
  padding: 12px;
  font-size: 16px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 15px;
}

/* Single field rows (email, phone) - full width */
.form-row:has(.form-field:only-child) {
  grid-template-columns: 1fr;
}

.form-row.button-row {
  grid-template-columns: 1fr;
  justify-items: center;
}

.form-field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 3px;
  line-height: 1.4;
}

.form-field input {
  width: 100%;
  height: 44px;
  padding: 6px 12px;
  border: 2px solid #E2E8F0;
  border-radius: 12px;
  font-size: 16px;
  color: #1E293B;
  background: #ffffff;
  transition: all 0.2s ease;
  box-sizing: border-box;
  font-family: inherit;
}

.form-field input:focus {
  outline: none;
  border-color: #de1624;
  box-shadow: 0 0 0 3px rgba(222, 22, 36, 0.1);
}

.form-field input::placeholder {
  color: #94A3B8;
  font-weight: 400;
}

/* Radio button group styling */
.radio-group {
  display: flex;
  gap: 20px;
  margin-top: 8px;
}

.radio-option {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.radio-option input[type="radio"] {
  width: 18px;
  height: 18px;
  margin: 0;
  cursor: pointer;
  accent-color: #dc2626;
}

.radio-option label {
  font-size: 14px;
  font-weight: 400;
  color: #374151;
  cursor: pointer;
  margin: 0;
  user-select: none;
}

/* Error messages */
.error-message {
  font-size: 13px;
  color: #EF4444;
  margin-top: 6px;
  font-weight: 500;
  opacity: 0;
  transform: translateY(-4px);
  transition: all 0.2s ease;
  display: none;
}

.error-message.show {
  opacity: 1;
  transform: translateY(0);
}

/* Submit button */
.submit-btn {
  width: auto;
  height: 40px;
  background: #de1624;
  border: none;
  border-radius: 7px;
  color: white;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  padding: 8px 16px;
  font-family: inherit;
  box-shadow: 0 2px 8px rgba(222, 22, 36, 0.3);
}

.submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(222, 22, 36, 0.4);
  background: #c01221;
}

.submit-btn:active {
  transform: translateY(0);
}

.submit-btn svg {
  transition: transform 0.2s ease;
}

.submit-btn:hover svg {
  transform: translateX(2px);
}

/* Final Generate button - bigger and more prominent */
.submit-btn-final {
  height: 52px;
  font-size: 16px;
  font-weight: 700;
  padding: 12px 24px;
  border-radius: 10px;
  background: linear-gradient(135deg, #de1624, #c01221);
  box-shadow: 0 4px 16px rgba(222, 22, 36, 0.4);
  margin-top: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.submit-btn-final:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(222, 22, 36, 0.5);
  background: linear-gradient(135deg, #c01221, #a00f1c);
}

.submit-btn-final svg {
  width: 22px;
  height: 22px;
}

/* Mobile responsiveness */
@media (max-width: 640px) {
  .checkout-container{
    padding: 0;
  }
   .checkout-header-fixed{
    padding: 10px;
   }

  .checkout-card {
    margin: 16px;
    border-radius: 20px;
  }
  
  .progress-steps {
    padding: 5px;
  }
  .form-field input{
    height: 45px;
  }
  .form-row.form-row.button-row{
    margin-bottom: 0;
  }
  
  .step-line {
    width: 40px;
    margin: 0 8px;
  }
  
  .step-label {
    font-size: 11px;
  }
  
  .progress-steps .step-number {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }
  
  .checkout-header {
    padding: 16px 16px 12px 16px;
  }
  
  .checkout-form {
    padding: 16px 16px 24px 16px;
  }
  
  .checkout-title {
    font-size: 24px;
  }
  
  .checkout-subtitle {
    font-size: 15px;
  }
  
  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
  
  .checkout-close-btn {
    top: 5px;
    right: 5px;
    width: 30px;
    height: 30px;
  }
  
  .checkout-close-btn svg {
    width: 16px;
    height: 16px;
  }
}

/* Small screen optimizations */
@media (max-height: 700px), (max-width: 520px) {
  .checkout-container {
    align-items: center;
    padding: 20px;
  }
  .form-row {
    margin-bottom: 10px;
  }
  .form-field label{
    margin-bottom: 2px;
  }
  .checkout-card {
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 40px);
    min-height: auto;
    margin: 0;
    display: flex;
    flex-direction: column;
  }
  
  /* Make form container scrollable */
  .checkout-steps-container {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    max-height: calc(100vh - 20px); /* Account for header and footer */
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    scrollbar-width: thin; /* Thin scrollbar on Firefox */
  }
  
  /* Custom scrollbar styling */
  .checkout-steps-container::-webkit-scrollbar {
    width: 6px;
  }
  
  .checkout-steps-container::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 3px;
  }
  
  .checkout-steps-container::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
  }
  
  .checkout-steps-container::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
  }
  
  /* Ensure header and footer stay fixed */
  .checkout-header-fixed {
    flex-shrink: 0;
  }
  
  .checkout-footer-fixed {
    flex-shrink: 0;
    padding: 5px;
  }
  
  /* Add padding to prevent content from touching edges when scrolling */
  .checkout-step {
    padding-bottom: 20px;
  }
}