/* =========================================
   AI Scope Page Custom Styling
   ========================================= */

/* Hide intro text after submit */
#introText {
  transition: opacity 0.3s ease;
}

   /* Ensure messages span full width */
#messages {
  width: 100%;
  margin: 10px 0;
}

/* Success / info messages */
#messages .info {
  background: linear-gradient(90deg, #e0ffe6, #f0fff4);
  color: #166534;
  border: 1px solid #a7f3d0;
  padding: 14px 16px;
  margin-bottom: 15px;
  border-radius: 8px;
  font-weight: 600;
  animation: fadeIn 0.3s ease;
}

/* Error messages */
#messages .error {
  background: linear-gradient(90deg, #ffe6e6, #fff0f0);
  color: #b91c1c;
  border: 1px solid #fecaca;
  padding: 14px 16px;
  margin-bottom: 15px;
  border-radius: 8px;
  font-weight: 600;
  animation: shake 0.3s ease;
}

/* Reset form fields default look */
#contact-form input,
#contact-form textarea,
#contact-form select {
  background: #fff;
  border: 1px solid #d1d5db;
  color: #111;
  border-radius: 6px;
  padding: 6px 12px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

#contact-form input:focus,
#contact-form textarea:focus,
#contact-form select:focus {
  border-color: #0C89D1;
  box-shadow: 0 0 6px rgba(12, 137, 209, 0.4);
  outline: none;
}

/* Hide error border until validation triggers */
#contact-form input.error,
#contact-form textarea.error {
  border-color: #dc2626 !important;
}

/* Futuristic button styling */
@keyframes quantumFlux {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

#submitBtn {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  /* background: linear-gradient(90deg, #0C89D1, #80C84A); */
  background: linear-gradient(270deg,
  #0C89D1,   /* Blue */
  #80C84A,   /* Green */
  #6A5ACD,   /* Violet */
  #00CED1,   /* Teal */
  #FF1493    /* Electric Pink */
  );
  background-size: 600% 600%;
  animation: quantumFlux 8s ease infinite;
  border: none;
  color: #fff;
  font-weight: bold;
  padding: 12px 18px;
  border-radius: 10px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.25);
}

#submitBtn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

.btn-content {
  display: flex;
  align-items: center;
  justify-content: center;
}

#submitBtn svg {
  fill: white;
}


/* ============================= */
/* ==== Futuristic Loading UI ===*/
/* ============================= */

#loadingOverlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100%;
  height: 100%;
  background: rgba(5,35,50,0.6);
  display: none; /* hidden by default, disable if testing */
  align-items: center;
  justify-content: center;
  flex-direction: column;
  z-index: 10; /* sits above form fields but below h2 */
  border-radius: 10px;
}

#loadingOverlay p {
  margin-top: 20px;
  font-size: 17px;
  font-weight: 600;
  color: #9dfca2;
  letter-spacing: 0.6px;
  text-align: center;
  /* animation: glowPulse 1.5s ease-in-out infinite; */
  /* text-shadow:
    0 0 5px rgba(12, 137, 209, 0.4),
    0 0 10px rgba(12, 137, 209, 0.3),
    0 0 15px rgba(12, 137, 209, 0.2); */
  font-family: 'Segoe UI', 'Roboto', sans-serif;
}


/* Futuristic spinner */
.loader-ai {
  width: 60px;
  height: 60px;
  border: 5px solid rgba(255,255,255,0.2);
  border-top: 5px solid #0C89D1;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}


.loader-ai::before,
.loader-ai::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  border: 3px solid transparent;
  left: -15px;
  top: -15px;
  right: -15px;
  bottom: -15px;
}

.loader-ai::before {
  border-top: 3px solid #ff2bed;
  border-left: 3px solid #0C89D1;
  animation: spin 3s linear infinite reverse;
}

.loader-ai::after {
  border-bottom: 3px solid #80C84A;
  border-right: 3px solid #ff416c;
  animation: spin 4s linear infinite;
}

/* Animations */
@keyframes glowPulse {
  0%, 100% {
    opacity: 0.7;
    text-shadow:
      0 0 5px rgba(12, 137, 209, 0.3),
      0 0 10px rgba(12, 137, 209, 0.2),
      0 0 15px rgba(12, 137, 209, 0.1);
  }
  50% {
    opacity: 1;
    text-shadow:
      0 0 10px rgba(12, 137, 209, 0.6),
      0 0 20px rgba(12, 137, 209, 0.5),
      0 0 25px rgba(12, 137, 209, 0.3);
  }
}

.loading-dots::after {
  content: '.';
  animation: dotsJump 2s steps(4, end) infinite;
}

@keyframes dotsJump {
  0% { content: '.'; }
  25% { content: '..'; }
  50% { content: '...'; }
  75% { content: ''; }
  100% { content: '.'; }
}

/* ==== other ==== */

@keyframes spin {
  100% {
    transform: rotate(360deg);
  }
}

@keyframes fadeInOverlay {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes pulseText {
  0%, 100% {
    opacity: 0.4;
  }
  50% {
    opacity: 1;
  }
}

/* @keyframes pulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
  50% { transform: translate(-50%, -50%) scale(1.2); opacity: 0.7; }
} */
/* ======= end ====== */


/* Back button */
#backBtn {
  margin-top: 15px;
  padding: 10px 18px;
  background: linear-gradient(90deg, #80C84A, #0C89D1);
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  transition: transform 0.2s, box-shadow 0.2s;
  display: none; /* hidden by default */
}

#backBtn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Success message inside result */
#resultMessage {
  margin-top: 15px;
  padding: 12px;
  background: #e6ffed;
  border: 1px solid #bbf7d0;
  border-radius: 6px;
  color: #166534;
  font-weight: 600;
}

@keyframes spin {
  100% { transform: rotate(360deg); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-3px); }
  50% { transform: translateX(3px); }
  75% { transform: translateX(-3px); }
}

/* Futuristic Success Banner */
#resultMessage.success-banner {
  margin-top: 20px;
  padding: 16px 20px;
  background: linear-gradient(90deg, #0C89D1, #80C84A);
  color: #fff;
  font-weight: 700;
  font-size: 1.1em;
  text-align: center;
  border-radius: 10px;
  box-shadow: 0 0 15px rgba(12, 137, 209, 0.6),
              0 0 25px rgba(128, 200, 74, 0.5);
  animation: pulseGlow 1s infinite alternate;
  letter-spacing: 0.5px;
}

@keyframes pulseGlow {
  0% {
    box-shadow: 0 0 10px rgba(12,137,209,0.4),
                0 0 20px rgba(128,200,74,0.3);
    transform: scale(1);
  }
  100% {
    box-shadow: 0 0 25px rgba(12,137,209,0.7),
                0 0 35px rgba(128,200,74,0.6);
    transform: scale(1.02);
  }
}

/* Result Preview styling */
#resultCard {
  background: rgba(255,255,255,0.95);
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.15);
  padding: 22px;
  margin-top: 20px;
  animation: fadeIn 0.4s ease;
  position: relative; /* new added*/
}

#resultPreview {
  line-height: 1.7;
  font-size: 15px;
  color: #222 !important;
}
#resultPreview h2, #resultPreview h3 {
  color: #0C89D1;
}

#resultPreview > p {
  color: #000; /* or any color you like */
}

.corner-wrap {
  position: absolute;
  top: 0;
  left: 0;
  width: 120px;
  height: 120px;
  overflow: hidden;
  z-index: 10;
}

.corner-text {
  position: absolute;
  top: 25px;
  left: -50px;
  width: 180px;
  background: #F97316;
  color: white;
  text-align: center;
  font-size: 13px;
  font-weight: bold;
  transform: rotate(-45deg);
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  padding: 6px 0;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.25);
}


/* ===========from style========== */
/* ==================== */
/* ==== ai section ==== */
/* ==================== */
/* .ai-section {
  background:
linear-gradient(27deg, #151515 5px, transparent 5px) 0 5px,
linear-gradient(207deg, #151515 5px, transparent 5px) 10px 0px,
linear-gradient(27deg, #222 5px, transparent 5px) 0px 10px,
linear-gradient(207deg, #222 5px, transparent 5px) 10px 5px,
linear-gradient(90deg, #1b1b1b 10px, transparent 10px),
linear-gradient(#1d1d1d 25%, #1a1a1a 25%, #1a1a1a 50%, transparent 50%, transparent 75%, #242424 75%, #242424);
background-color: #131313;
background-size: 20px 20px;
} */

/* Ensure parent is positioned so overlay can sit inside it */
.contact-form-s1.form {
  position: relative;
}

.contact-form-s1 form .textarea-wrap {
  width: 100%;
  float: left;
  padding: 0 12px;
  margin-top: 12px;
}

.contact-form-s1 textarea {
  height: 78px;
  border: 0;
}

.ai-sec {
  background: #0f2027;
  background: linear-gradient(145deg, #0f2027 0%, #0C89D1 50%, #2c6435 100%);
}

/* Only scope intro/details text */
.ai-sec .details p,
.ai-sec .section-title-white p {
  color: #F0F0F0 !important;
}

/* Section labels */
.ai-sec label {
  color: #9dfca2;
  font-weight: 500;
  font-size: 14px;
  display: inline-block;
  margin-bottom: 6px;
}

.ai-sec input:invalid {
  border: 1px solid #ff4d4d; /* Red border for invalid inputs */
  background: rgba(255, 77, 77, 0.1); /* Light red background */
}

/* Highlight GrowTrade brand text */
.ai-sec .gt {
  color: #9dfca2 !important;
}

/* ======= */
/* Error messages */
.ai-sec .error {
  color: #C00909;
}

/* Input error borders */
.ai-sec input:invalid {
  border: 1px solid #C00909;
  background: rgba(192, 9, 9, 0.05);
}

/* Specific error styling for the error label with id (e.g., #name-error) */
.ai-sec label.error {
  color: #C00909;
}
/* ======= */

/* ========================= */
/* ==== animated button ==== */
/* ========================= */

/* Animated gradient for the input button */
/* ========================= */
/* ==== Animated Button ==== */
/* ========================= */

.theme-btn.animated-submit {
  display: inline-block;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  background: linear-gradient(
    270deg,
    #ff416c,
    #ff2bed,
    #0C89D1,
    #80C84A,
    #ff416c
  );
  background-size: 1000% 1000%;
  animation: gradientShift 10s ease infinite;
  transition: transform 0.2s ease, box-shadow 0.3s ease;
  font-family: inherit;
}

.theme-btn.animated-submit:hover {
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.4);
}

@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* ============================= */
/* ==== AI Response Preview ==== */
/* ============================= */

.ai-preview {
  margin-top: 20px;
  padding: 20px;
  background: #ffffff;
  border-radius: 10px;
  border: 1px solid #ddd;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  line-height: 1.6;
  font-size: 15px;
  color: #222;
  animation: fadeInUp 0.5s ease;
}

.ai-preview h2,
.ai-preview h3 {
  color: #0C89D1;
  margin-top: 15px;
}

.ai-preview strong {
  display: block;
  margin-top: 12px;
  font-size: 16px;
  color: #1a73e8;
}

.ai-preview ul {
  padding-left: 20px;
  margin: 10px 0;
}

.ai-preview li {
  margin-bottom: 6px;
}

.ai-preview p {
  margin: 8px 0;
}

/* Preview entry animation */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ai-form error label */
label.error[id] {
  /* color: yellow !important;
  font-size: 14px;
  font-weight: bold; */

  background: linear-gradient(90deg, #ffe6e6, #fff0f0);
  color: #b91c1c;
  padding: 2px 6px;
  /* border: 1px solid #fecaca; */
  /* margin-bottom: 15px; */
  /* font-size: 14px; */
  /* font-weight: bold; */
  /* font-weight: 600; */

  border-radius: 4px;
  animation: shake 0.3s ease;
}

body#ai-solutions-page .page-wrapper .contact-section .section-title-white h2 {
  font-family: 'Poppins', sans-serif;
  /*font-weight: 700; /* Bold */
  letter-spacing: 0.1px; /* Optional: improves sharpness */
  text-transform: uppercase; /* Optional: matches your design */
}

.grecaptcha-badge {
  bottom: 80px !important; /* default is 0px, move it 40px up */
  /* right: 10px !important; */
}