/**
 * @file
 * Newsletter popup styles.
 */

/* Popup Container - Fixed position bottom right */
.newsletter-popup-overlay {
  position: fixed !important;
  bottom: 20px !important;
  right: 20px !important;
  z-index: 99999 !important;
  width: 730px;
  height: 404px;
  pointer-events: none;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.newsletter-popup-overlay.hidden {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
}

/* Popup Container & Content */
.newsletter-popup-container,
.newsletter-popup-content {
  position: relative;
  width: 100%;
  height: 100%;
}

.newsletter-popup-content {
  display: flex;
  flex-direction: row;
  pointer-events: auto;
  border-radius: 0;
  overflow: hidden;
  background: transparent;
}

/* Left side - Image */
.newsletter-popup-image {
  position: absolute;
  width: 273.5px;
  height: 100%;
  left: 0;
  overflow: hidden;
  z-index: 1;
}

.newsletter-popup-image img {
  width: 100%;
  height: 408px !important;
  margin-top: 8px;
}

.newsletter-popup-image-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Right side - Form */
.newsletter-popup-form {
  position: absolute;
  width: 543px;
  height: 404px;
  left: 164px;
  top: 0;
  color: #F3F7FF;
  padding: 0;
  display: flex;
  flex-direction: column;
  z-index: 2;
  overflow: hidden;
}

/* SVG shape for the form */
.newsletter-popup-form-shape {
  position: absolute;
  top: 0;
  left: 0;
  width: 543px;
  height: 404px;
  z-index: 0;
  pointer-events: none;
}

/* Form content wrapper */
.newsletter-popup-form-content {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 32px 16px 4px 0;
  gap: 4px;
  box-sizing: border-box;
  z-index: 1;
  align-items: end;
}

/* Close button */
.newsletter-popup-close {
  position: absolute;
  top: 6.06%;
  right: 8.37%;
  border: none;
  cursor: pointer;
  display: flex;
  z-index: 10;
  transition: opacity 0.3s ease;
}

.newsletter-popup-close img {
  width: 16px;
  height: 16px;
}

.newsletter-popup-close:hover {
  opacity: 0.7;
}

/* Title and Description */
.newsletter-popup-title-section {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  max-width: 362px;
}

.newsletter-popup-title,
.newsletter-popup-description {
  margin: 0;
  display: flex;
  align-items: center;
  color: #F3F7FF;
}

.newsletter-popup-title {
  min-width: 212px;
  font-family: 'Roboto', sans-serif;
  font-weight: 400;
  font-size: 24px;
  line-height: 25px;
}

.newsletter-popup-description {
  max-width: 362px;
  font-family: 'Lora', serif;
  font-style: italic;
  font-weight: 500;
  font-size: 16px;
  line-height: 25px;
}

/* Mailchimp Form */
#mc_embed_signup,
#mc-embedded-subscribe-form {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

#mc_embed_signup {
  max-width: 411px;
  margin-top: auto;
}

#mc_embed_signup_scroll {
  display: flex;
  flex-direction: column;
}

.indicates-required {
  display: none;
}

/* Field groups */
.mc-field-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-width: 411px;
}

.mc-field-group label {
  font-family: 'Roboto', sans-serif;
  font-weight: 400;
  font-size: 14px;
  line-height: 24px;
  color: #8AC4FF;
  margin: 0;
}

.mc-field-group .asterisk {
  color: #8AC4FF;
}

/* Inputs */
#mce-EMAIL,
#mce-FNAME,
#mce-LNAME,
#mce-MMERGE5 {
  max-width: 411px;
  background: transparent !important;
  border: none;
  border-bottom: 2px solid #F3F7FF;
  color: #F3F7FF;
  font-family: 'Roboto', sans-serif;
  font-size: 14px;
  font-weight: 400;
  outline: none;
  padding: 8px 0;
  margin: 0;
}

#mce-EMAIL::placeholder,
#mce-FNAME::placeholder,
#mce-LNAME::placeholder,
#mce-MMERGE5::placeholder {
  color: rgba(243, 247, 255, 0.7);
}

#mce-EMAIL:focus,
#mce-FNAME:focus,
#mce-LNAME:focus,
#mce-MMERGE5:focus {
  border-bottom-color: #F3F7FF;
  background: transparent;
}

/* Autofill styles */
#mce-EMAIL:-webkit-autofill,
#mce-FNAME:-webkit-autofill,
#mce-LNAME:-webkit-autofill,
#mce-MMERGE5:-webkit-autofill,
#mce-EMAIL:-webkit-autofill:hover,
#mce-FNAME:-webkit-autofill:hover,
#mce-LNAME:-webkit-autofill:hover,
#mce-MMERGE5:-webkit-autofill:hover,
#mce-EMAIL:-webkit-autofill:focus,
#mce-FNAME:-webkit-autofill:focus,
#mce-LNAME:-webkit-autofill:focus,
#mce-MMERGE5:-webkit-autofill:focus,
#mce-EMAIL:-webkit-autofill:active,
#mce-FNAME:-webkit-autofill:active,
#mce-LNAME:-webkit-autofill:active,
#mce-MMERGE5:-webkit-autofill:active {
  -webkit-text-fill-color: #F3F7FF !important;
  -webkit-box-shadow: 0 0 0px 1000px transparent inset !important;
  background-color: transparent !important;
  background: transparent !important;
  transition: background-color 5000s ease-in-out 0s;
}

/* GDPR Consent Checkbox */
.mc-field-group.gdpr-consent {
  margin-bottom: 10px;
}

.gdpr-checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-family: 'Roboto', sans-serif;
  font-weight: 400;
  font-size: 14px;
  line-height: 20px;
  color: #F3F7FF;
  cursor: pointer;
  margin: 0;
}

.gdpr-checkbox-label input[type="checkbox"] {
  margin: 3px 0 0 0;
  width: 18px;
  height: 18px;
  min-width: 18px;
  cursor: pointer;
  accent-color: #0834BA;
  background-color: transparent;
  border: 2px solid #F3F7FF;
  border-radius: 3px;
  flex-shrink: 0;
}

.gdpr-checkbox-label input[type="checkbox"]:checked {
  background-color: #F3F7FF;
  border-color: #F3F7FF;
}

.gdpr-checkbox-label span {
  font-size: 12px;
  flex: 1;
  color: #F3F7FF;
}

.gdpr-checkbox-label a {
  color: #8AC4FF;
  text-decoration: underline;
  transition: color 0.3s ease;
}

.gdpr-checkbox-label a:hover,
#mce-success-response a:hover {
  color: #F3F7FF;
}

/* Submit button container */
.optionalParent {
  margin-top: auto;
}

.optionalParent .clear.foot {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 30px;
}

.optionalParent .clear.foot p {
  margin: 0;
}

.optionalParent .clear.foot a {
  display: flex;
  align-items: center;
  justify-content: center;
}

.optionalParent .clear.foot .refferal_badge {
  width: 109px;
  height: auto;
  max-height: 33px;
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.optionalParent .clear.foot .refferal_badge:hover {
  opacity: 1;
}

/* Submit button */
#mc-embedded-subscribe {
  box-sizing: border-box;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 10px;
  width: 268px;
  height: 46px;
  background: transparent;
  border: 1.5px solid #F3F7FF;
  border-radius: 30px;
  color: #F3F7FF;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  font-size: 16px;
  line-height: 24px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

#mc-embedded-subscribe:hover:not(:disabled) {
  background: rgba(243, 247, 255, 0.1);
}

#mc-embedded-subscribe:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Mailchimp response messages */
#mce-error-response,
#mce-success-response {
  padding: 4px;
  border-radius: 4px;
  font-size: 12px;
  font-family: 'Roboto', sans-serif;
  color: #F3F7FF;
}

#mce-error-response {
  background-color: rgba(244, 67, 54, 0.2);
  border: 1px solid rgba(244, 67, 54, 0.5);
}

#mce-success-response {
  background-color: rgba(76, 175, 80, 0.2);
  border: 1px solid rgba(76, 175, 80, 0.5);
}

#mce-success-response a {
  color: #8AC4FF;
  text-decoration: underline;
  transition: color 0.3s ease;
}

/* Responsive adjustments */
@media (max-width: 1023px) {
  .newsletter-popup-overlay {
    width: calc(100% - 40px);
    max-width: 500px;
    height: auto;
    bottom: 10px;
    left: 20px;
    right: 20px;
  }

  .newsletter-popup-content {
    flex-direction: column;
    border-radius: 15px;
    height: auto;
    min-height: auto;
    overflow: hidden;
    background: #0834BA;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  }

  .newsletter-popup-image,
  .newsletter-popup-form-shape {
    display: none;
  }

  .newsletter-popup-form {
    position: relative;
    width: 100%;
    height: auto;
    min-height: auto;
    left: 0;
    top: 0;
    transform: none;
    background: #0834BA;
    border-radius: 15px;
  }

  .newsletter-popup-form-content {
    position: relative;
    padding: 30px 20px;
    gap: 24px;
    left: 0;
    top: 0;
    transform: none;
    align-items: flex-start;
  }

  .newsletter-popup-close {
    top: 15px;
    right: 15px;
  }

  .newsletter-popup-title-section {
    max-width: 100%;
    width: 100%;
  }

  .newsletter-popup-title {
    font-size: 20px;
    line-height: 28px;
    min-width: auto;
  }

  .newsletter-popup-description {
    font-size: 14px;
    line-height: 20px;
    max-width: 100%;
  }

  #mc_embed_signup {
    max-width: 100%;
    width: 100%;
    gap: 24px;
    margin-top: 0;
  }

  .mc-field-group,
  .mc-field-group label,
  #mce-EMAIL,
  #mce-FNAME,
  #mce-LNAME,
  #mce-MMERGE5 {
    max-width: 100%;
    width: 100%;
  }

  .optionalParent .clear.foot {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
  }

  #mc-embedded-subscribe {
    width: 100%;
    max-width: 100%;
  }

  #mce-error-response,
  #mce-success-response {
    position: relative;
    margin-top: 16px;
    width: 100%;
  }
}

@media (max-width: 768px) {
  .newsletter-popup-form-content {
    padding: 25px 18px;
    gap: 20px;
  }

  .newsletter-popup-title {
    font-size: 18px;
    line-height: 24px;
  }

  .newsletter-popup-description {
    font-size: 13px;
    line-height: 18px;
  }
}

@media (max-width: 480px) {
  .newsletter-popup-overlay {
    width: calc(100% - 20px);
    left: 10px;
    right: 10px;
    bottom: 10px;
  }

  .newsletter-popup-content,
  .newsletter-popup-form {
    border-radius: 12px;
  }

  .newsletter-popup-form-content {
    padding: 20px 16px;
    gap: 20px;
  }

  #mc_embed_signup {
    gap: 20px;
  }

  #mce-EMAIL,
  #mce-FNAME,
  #mce-LNAME,
  #mce-MMERGE5,
  #mce-MMERGE6,
  select#mce-MMERGE6 {
    font-size: 14px;
    padding: 6px 0;
  }

  .gdpr-checkbox-label {
    font-size: 12px;
    line-height: 18px;
  }

  .gdpr-checkbox-label span {
    font-size: 11px;
  }

  #mc-embedded-subscribe {
    height: 42px;
    font-size: 14px;
  }
}
