/* Modern SaaS Checkout Design - Two Column Layout */

* {
  box-sizing: border-box;
}

.etollfree-v2-container {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica', 'Arial', sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  padding: 20px;
}

.checkout-wrapper {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 30px;
  background: white;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* Left Column - Form */
.checkout-form {
  padding: 50px;
}

.back-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 600;
  color: #ffffff !important;
  background: #970300;
  text-decoration: none;
  margin-bottom: 20px;
  padding: 10px 20px;
  border-radius: 6px;
  transition: all 0.2s;
}

.back-button:hover {
  color: #ffffff !important;
  background: #c50400;
  transform: translateX(-3px);
  box-shadow: 0 4px 12px rgba(151, 3, 0, 0.3);
}

.back-button svg {
  flex-shrink: 0;
  stroke: #ffffff !important;
}

.checkout-form h1 {
  font-size: 32px;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 8px;
}

.subtitle {
  color: #666;
  margin-bottom: 40px;
  font-size: 15px;
}

/* Messages */
.etollfree-message {
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.error-message {
  background: #fee;
  color: #c00;
  border: 1px solid #fcc;
}

.success-message {
  background: #efe;
  color: #060;
  border: 1px solid #cfc;
}

/* Social Login */
.social-login {
  margin-bottom: 35px;
}

.social-title {
  font-size: 13px;
  font-weight: 600;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 15px;
}

.social-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 20px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  background: white;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  transition: all 0.2s;
  font-family: inherit;
}

.social-btn:hover {
  border-color: #970300;
  background: #fafafa;
  transform: translateY(-2px);
}

.social-btn svg {
  flex-shrink: 0;
}

/* Express Checkout */
.express-checkout {
  margin-bottom: 35px;
}

.express-buttons {
  display: grid;
  gap: 12px;
}

.express-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px;
  border: none;
  border-radius: 8px;
  background: #000;
  color: #ffffff;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.2s;
  font-family: inherit;
}

.express-btn.credit-card-btn {
  background: #970300;
  border-color: #970300;
  color: #ffffff !important;
}

.express-btn.credit-card-btn:hover {
  background: #c50400;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(151, 3, 0, 0.3);
}

.express-btn.credit-card-btn svg {
  stroke: #ffffff !important;
}

.express-btn.paypal-btn {
  background: #0070ba;
  border-color: #0070ba;
}

.express-btn:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

/* Card fields container animation */
#cardEntrySection {
  overflow: hidden;
  transition: all 0.4s ease-out;
  margin-top: 20px;
}

#cardEntrySection.card-fields-revealed {
  animation: slideDownFadeIn 0.5s ease-out forwards;
}

/* PayPal Smart Payment Button Container */
div[id^="paypal-button-container"] {
  min-height: 55px;
}

.divider {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 35px 0;
  color: #999;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

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

/* Form Fields */
.form-group {
  margin-bottom: 24px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #333;
  margin-bottom: 8px;
}

input,
select {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 15px;
  transition: all 0.2s;
  font-family: inherit;
}

input:focus,
select:focus {
  outline: none;
  border-color: #970300;
  box-shadow: 0 0 0 3px rgba(151, 3, 0, 0.1);
}

/* International phone input styling */
#contactNumber {
  width: 100%;
}

.iti {
  width: 100%;
}

.iti__flag-container {
  padding: 0;
}

.iti__selected-flag {
  padding: 0 8px 0 12px;
}

/* Submit Button */
.submit-btn {
  width: 100%;
  padding: 18px;
  background: linear-gradient(135deg, #970300 0%, #c50400 100%);
  color: #ffffff !important;
  border: none;
  border-radius: 8px;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 24px;
  transition: all 0.3s;
  font-family: inherit;
}

.submit-btn:hover {
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(151, 3, 0, 0.3);
}

.submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.submit-btn span {
  color: #ffffff !important;
}

.security-note {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: #666;
}

.security-icons {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 15px;
}

.security-badge {
  padding: 6px 12px;
  background: #f0f0f0;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
}

.payment-message {
  margin-top: 15px;
  padding: 12px;
  border-radius: 6px;
  text-align: center;
  font-weight: 600;
}

.payment-message.error {
  background: #fee;
  color: #c00;
}

.payment-message.success {
  background: #efe;
  color: #060;
}

.payment-message.processing {
  background: #ffa;
  color: #660;
}

/* Right Column - Order Summary */
.order-summary {
  background: #f8f9fa;
  padding: 50px 40px;
  border-left: 1px solid #e0e0e0;
}

.summary-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 25px;
  color: #1a1a1a;
}

.phone-number-display {
  background: white;
  padding: 20px;
  border-radius: 10px;
  margin-bottom: 25px;
  border: 2px solid #970300;
}

.phone-label {
  font-size: 12px;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 5px;
}

.phone-value {
  font-size: 24px;
  font-weight: 700;
  color: #970300;
}

.plan-selector {
  margin-bottom: 25px;
}

.plan-option {
  background: white;
  padding: 18px;
  border: 2px solid #e0e0e0;
  border-radius: 10px;
  margin-bottom: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.plan-option:hover {
  border-color: #970300;
}

.plan-option.selected {
  border-color: #970300;
  background: #fff5f5;
}

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

.plan-name {
  font-weight: 600;
  font-size: 15px;
}

.plan-price {
  font-weight: 700;
  font-size: 18px;
  color: #970300;
}

.plan-unit {
  font-size: 12px;
  font-weight: 400;
  color: #666;
}

.plan-description {
  font-size: 13px;
  color: #666;
}

.summary-breakdown {
  background: white;
  padding: 20px;
  border-radius: 10px;
}

.summary-line {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  font-size: 15px;
}

.summary-line.total {
  border-top: 2px solid #e0e0e0;
  margin-top: 15px;
  padding-top: 20px;
  font-size: 20px;
  font-weight: 700;
}

.guarantee {
  background: #e8f5e9;
  padding: 15px;
  border-radius: 8px;
  margin-top: 25px;
  text-align: center;
}

.guarantee-title {
  font-weight: 700;
  color: #2e7d32;
  margin-bottom: 5px;
}

.guarantee-text {
  font-size: 13px;
  color: #555;
}

/* Responsive Design */
@media (max-width: 900px) {
  .checkout-wrapper {
    grid-template-columns: 1fr;
  }

  .order-summary {
    border-left: none;
    border-top: 1px solid #e0e0e0;
  }

  .checkout-form {
    padding: 30px 25px;
  }

  .order-summary {
    padding: 30px 25px;
  }
}

@media (max-width: 600px) {
  .social-buttons {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }
}

/* Stored Payment Profile Styles */
.stored-card-display {
  background: #f8f9fa;
  border: 2px solid #970300;
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 20px;
}

.stored-card-info {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 15px;
  flex-wrap: wrap;
}

.card-icon {
  font-size: 24px;
}

.card-details {
  font-weight: 600;
  font-size: 16px;
  color: #1a1a1a;
}

.card-expiry {
  font-size: 14px;
  color: #666;
}

.use-new-card-btn {
  background: white;
  border: 2px solid #970300;
  color: #970300;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  width: 100%;
}

.use-new-card-btn:hover {
  background: #970300;
  color: white;
  transform: translateY(-1px);
}

#cardEntrySection {
  transition: all 0.3s ease-in-out;
}

#cardEntrySection.hidden {
  display: none;
}

@media (max-width: 600px) {
  .stored-card-info {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

/* Progressive Disclosure - Hide payment sections until user identifies */
.payment-section.hidden-until-identified,
.express-checkout.payment-section.hidden-until-identified,
div.payment-section.hidden-until-identified {
  display: none !important;
  opacity: 0 !important;
  transform: translateY(-10px) !important;
  visibility: hidden !important;
  max-height: 0 !important;
  overflow: hidden !important;
  margin: 0 !important;
  padding: 0 !important;
}

.payment-section.payment-revealed,
.express-checkout.payment-section.payment-revealed,
div.payment-section.payment-revealed {
  display: block !important;
  visibility: visible !important;
  max-height: none !important;
  overflow: visible !important;
  animation: slideDownFadeIn 0.5s ease-out forwards;
}

@keyframes slideDownFadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Divider also hidden initially */
.divider.hidden-until-identified,
div.divider.hidden-until-identified {
  display: none !important;
  visibility: hidden !important;
  max-height: 0 !important;
  overflow: hidden !important;
  margin: 0 !important;
}

.divider.payment-revealed,
div.divider.payment-revealed {
  display: flex !important;
  visibility: visible !important;
  max-height: none !important;
  overflow: visible !important;
  animation: fadeIn 0.5s ease-out forwards;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
