/* ================= RESET ================= */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  overflow-x: hidden;
  margin: 0;
  padding: 0;
  font-family: "Inter", sans-serif;
  color: #1a1a1a;
}

/* ================= HERO ================= */
.contact-hero {
  background-image: url("../assets/images/contact-us-bg-hero.png");
  background-repeat: no-repeat;
  background-position: right right;
  /* Focus on the image part */
  background-size: contain;
  position: relative;
  min-height: 850px;
  /* Force enough height for the bg to show */
  display: flex;
  flex-direction: column;
}

/* Ensure content sits above background if needed */
.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 220px 24px 100px;
  /* Top padding for fixed header */
  flex: 1;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 2;
}

/* Text column */
.hero-text-col {
  max-width: 550px;
}

.hero-title {
  font-size: 56px;
  font-weight: 800;
  color: #5b4bdb;
  /* Primary Purple */
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.hero-desc {
  font-size: 16px;
  line-height: 1.8;
  color: #6b6b7a;
  margin-bottom: 0;
}

/* Wave Divider */
.hero-divider {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  line-height: 0;
  z-index: 3;
}

.hero-divider img {
  width: 100%;
  height: auto;
  display: block;
}

/* ================= CONTACT SECTION ================= */
.contact-section {
  background: #fff;
  padding-bottom: 80px;
  position: relative;
  z-index: 4;
  /* Above the hero bottom edge */
}

.contact-title {
  text-align: center;
  font-size: 42px;
  font-weight: 700;
  margin-bottom: 50px;
  margin-top: -40px;
  /* Pull up to sit nicely under wave if needed, or just normal spacing */
}

.contact-title span {
  color: #5b4bdb;
}

/* ================= TABS ================= */
.contact-tabs {
  display: flex;
  justify-content: center;
  margin-bottom: 60px;
}

.tabs-inner {
  display: inline-flex;
  gap: 8px;
  background: #fff;
  padding: 0;
  /* Removed grey background wrapper to match clean look or keep if desired. 
     Design shows tabs might be just text or pills. 
     Let's keep the pill style but minimal. */
  border-bottom: 1px solid #eee;
  /* Divider line maybe? */
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
  border-bottom: none;
  /* Reset */
}

/* Actually design shows a border line with active indicator? 
   Or just pills. The prompt image shows simple text/pills. 
   Lets stick to the user's previous code style but refined. */
.tabs-inner {
  border-radius: 0;
  background: transparent;
  border-bottom: 1px solid #e0e0e0;
  padding-bottom: 10px;
  width: 100%;
  max-width: 1000px;
}

.tab {
  background: transparent;
  border: none;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  color: #888;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.3s ease;
  position: relative;
}

.tab:hover {
  color: #5b4bdb;
}

/* Active tab style - solid purple pill */
.tab.active {
  background: #5b4bdb;
  color: #fff;
  box-shadow: 0 4px 10px rgba(91, 75, 219, 0.3);
}

/* ================= FORM ================= */
.contact-form-wrapper {
  max-width: 900px;
  margin: auto;
  position: relative;
  min-height: 400px;
}

.form-title {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: 30px;
  color: #333;
}

.custom-input,
.custom-textarea {
  border: 1px solid #e0e0ff;
  border-radius: 12px;
  padding: 16px 20px;
  font-size: 15px;
  color: #333;
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.custom-input::placeholder,
.custom-textarea::placeholder {
  color: #aaa;
}

.custom-input:focus,
.custom-textarea:focus {
  border-color: #5b4bdb;
  box-shadow: 0 0 0 4px rgba(91, 75, 219, 0.1);
  outline: none;
}

.custom-textarea {
  resize: none;
}

/* ================= CHECKBOX ================= */
.custom-check {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14px;
  color: #555;
  padding-left: 0;
}

.custom-check .form-check-input {
  float: none;
  margin-left: 0;
  margin-top: 3px;
  width: 20px;
  height: 20px;
  border: 1px solid #d0d0ff;
  border-radius: 4px;
}

.custom-check .form-check-input:checked {
  background-color: #5b4bdb;
  border-color: #5b4bdb;
}

/* ================= BUTTON ================= */
.form-actions {
  display: flex;
  justify-content: flex-end;
}

.send-btn {
  background: linear-gradient(270deg, #2f47ac, #792ef1);
  color: #fff;
  border: none;
  padding: 12px 30px;
  border-radius: 8px;
  /* Slightly squarer than pill */
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 16px;
  font-weight: 600;
  transition: transform 0.2s;
}

.send-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(91, 75, 219, 0.25);
}

.send-btn .icon-box {
  background: rgba(0, 0, 0, 0.2);
  /* Darker box around arrow */
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
}

.send-btn i {
  font-size: 12px;
  transform: rotate(-45deg);
  /* Arrow pointing up-right */
}

.send-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* ================= FORM LOADER ================= */
.form-loader-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
  z-index: 10;
}

.form-loader-overlay.active {
  opacity: 1;
  visibility: visible;
}

.form-loader {
  text-align: center;
}

.form-loader-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(91, 75, 219, 0.2);
  border-top-color: #5b4bdb;
  border-radius: 50%;
  animation: formSpinner 0.9s linear infinite;
  margin: 0 auto 16px;
}

@keyframes formSpinner {
  to {
    transform: rotate(360deg);
  }
}

.form-loader-text {
  font-size: 15px;
  font-weight: 500;
  color: #5b4bdb;
  margin: 0;
}

/* ================= SUCCESS MESSAGE ================= */
.form-success-message {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 48px 24px;
  opacity: 0;
  visibility: hidden;
  transform: scale(0.9);
  transition: opacity 0.5s ease, visibility 0.5s ease, transform 0.5s ease;
  z-index: 5;
}

.form-success-message.active {
  opacity: 1;
  visibility: visible;
  transform: scale(1);
}

.success-icon-wrapper {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, #5b4bdb 0%, #792ef1 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  box-shadow: 0 12px 40px rgba(91, 75, 219, 0.35);
  animation: successPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 0.2s both;
}

.success-icon-wrapper i {
  font-size: 40px;
  color: #fff;
}

@keyframes successPop {
  0% {
    transform: scale(0);
    opacity: 0;
  }

  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.success-title {
  font-size: 32px;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 12px;
}

.success-message {
  font-size: 17px;
  line-height: 1.6;
  color: #555;
  max-width: 420px;
  margin-bottom: 8px;
}

.success-subtext {
  font-size: 14px;
  color: #888;
  margin: 0;
}


/* ================= RESPONSIVE ================= */

/* Mobile Menu Styling */
.mobile-toggle {
  background: none;
  border: none;
  font-size: 24px;
  color: #333;
  cursor: pointer;
  padding: 8px;
}

.mobile-menu-container {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: #fff;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  flex-direction: column;
  gap: 16px;
  z-index: 999;
  border-radius: 0 0 16px 16px;
}

.mobile-menu-container.show {
  display: flex;
}

.mobile-menu-container a {
  text-decoration: none;
  color: #333;
  font-weight: 500;
  font-size: 16px;
  padding: 8px 0;
  border-bottom: 1px solid #f0f0f0;
}

.mobile-menu-container .header-cta {
  text-align: center;
  margin-top: 10px;
  display: block;
  width: 100%;
}

@media (min-width: 1024px) {
  /* Large screens adjustments if needed */
}


/* Tablet */
@media (max-width: 1023px) {
  .hero-inner {
    padding: 160px 24px 80px;
  }

  .hero-title {
    font-size: 42px;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .contact-hero {
    background-position: center top;
    /* Move background up or remove if it clashes with text */
    min-height: auto;
  }

  .hero-inner {
    padding: 140px 20px 80px;
    text-align: center;
    flex-direction: column;
  }

  .hero-text-col {
    max-width: 100%;
    margin-bottom: 40px;
  }

  .hero-title {
    font-size: 32px;
  }

  .tabs-inner {
    border: none;
    flex-direction: row;
    /* Horizontal scroll or wrapping? Image implies line */
    background: #f5f5f5;
    /* Fallback to pill box on mobile for better touch targets? */
    border-radius: 12px;
    padding: 8px;
  }

  .tab.active {
    width: 100%;
    /* Full width active on mobile? */
  }

  .send-btn {
    width: 100%;
    justify-content: center;
  }
}