/**
 * Custom Styles for KD Capital Website
 * Theme: Bosa Finance Consult
 */

/* Global fix to prevent horizontal scroll */
html, body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
}

/* ===============================
   STICKY HEADER STYLES
   =============================== */

/* Sticky header styling (applied by JavaScript) */
.elementor-element-b206177.sticky-active {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 9999 !important;
    background-color: #ffffff !important;
    -webkit-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    -moz-box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

/* Adjust for logged-in admin bar when sticky */
.admin-bar .elementor-element-b206177.sticky-active {
    top: 32px !important;
}

/* Smooth transitions */
.elementor-element-b206177 {
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

/* Body padding to prevent content overlap */
body {
    transition: padding-top 0.3s ease;
}

/* Push main content down when header becomes sticky */
.elementor-section-wrap {
    transition: margin-top 0.3s ease;
}


/* ===============================
   CONTACT FORM 7 STYLES
   =============================== */

.contact-form {
  max-width: 760px;
  margin: 50px auto;
  padding: 50px;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  font-family: 'Inter', sans-serif;
}

.contact-heading {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 40px;
  color: #222;
  text-align: center;
}

.contact-form .form-row {
  display: flex;
  gap: 28px;
  margin-bottom: 28px;
}

.contact-form .form-col {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.contact-form .form-full {
  display: flex;
  flex-direction: column;
  margin-bottom: 28px;
}

.contact-form label {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 10px;
  color: #222;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 16px 18px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
  background: #fff;
  transition: all 0.25s ease;
  appearance: none;
}

.contact-form input { height: 52px; }
.contact-form textarea { min-height: 180px; resize: vertical; }

.contact-form textarea {
  min-height: 200px;
  padding: 18px 20px;
  border: 1.5px solid #ccc;
  border-radius: 10px;
  font-size: 15px;
  line-height: 1.6;
  background: #fafafa;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.contact-form select {
  position: relative;
  padding-right: 40px;
  cursor: pointer;
}

.contact-form select::after {
  content: "▼";
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  color: #999;
  pointer-events: none;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder,
.contact-form select::placeholder {
  color: #999;
  font-size: 13px;
  font-style: italic;
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
  border-color: #B8974D;
  box-shadow: 0 0 0 3px rgba(184, 151, 77, 0.15);
  outline: none;
  background: #fff;
}

.contact-form .submit-btn {
  margin-top: 35px;
}

.contact-form input[type="submit"] {
  width: 100%;
  background: #B8974D;
  color: #fff;
  border: none;
  padding: 18px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(184, 151, 77, 0.2);
}

.contact-form input[type="submit"]:hover {
  background: #9e7e3e;
}

/* Contact Form 7 Response Messages */
.wpcf7-response-output.wpcf7-mail-sent-ok {
  display: block;
  padding: 18px 22px;
  margin-top: 25px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.6;
  font-family: 'Inter', sans-serif;
  color: #1a1a1a;
  background-color: #e6f4ea;
  border: 1.5px solid #4CAF50;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  text-align: center;
  animation: fadeInUp 0.5s ease-out;
}

.wpcf7-response-output.wpcf7-validation-errors,
.wpcf7-response-output.wpcf7-mail-failed {
  display: block;
  padding: 18px 22px;
  margin-top: 25px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.6;
  font-family: 'Inter', sans-serif;
  color: #fff;
  background-color: #F44336;
  border: 1.5px solid #F44336;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  text-align: center;
  animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
  0% { opacity: 0; transform: translateY(15px); }
  100% { opacity: 1; transform: translateY(0); }
}


/* ===============================
   MOBILE/TABLET HEADER FIXES
   =============================== */

/* Prevent horizontal scroll on all devices */
html, body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
}

/* Tablet and Mobile (up to 1024px) */
@media screen and (max-width: 1024px) {
    
    /* Main header wrapper - prevent overflow */
    .elementor-element-b206177 {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Hide the separate contact button widget on mobile */
    .elementor-element-c40fb76,
    .elementor-element-c40fb76 > *,
    .elementor-element-c40fb76 .elementor-widget-container {
        display: none !important;
    }
    
    /* Show header container */
    .elementor-element-b206177 {
        display: flex !important;
    }
    
    /* Main header container - align logo and menu */
    .elementor-element-beb97d6 {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
        box-sizing: border-box !important;
    }
    
    /* Logo container - smaller on tablet/mobile */
    .elementor-element-ca2d8d8 {
        display: flex !important;
        flex: 0 0 auto !important;
        width: auto !important;
        max-width: 120px !important;
        align-items: center !important;
    }
    
    /* Logo image - smaller on tablet/mobile */
    .elementor-element-ca2d8d8 .bew-site-logo img,
    .elementor-element-ca2d8d8 img,
    .bew-site-logo-img {
        max-width: 100px !important;
        height: auto !important;
        width: 100px !important;
    }
    
    /* Menu container - aligned with logo */
    .elementor-element-b0bd38a {
        display: flex !important;
        flex: 0 0 auto !important;
        width: auto !important;
        align-items: center !important;
        justify-content: flex-end !important;
    }
    
    /* Menu widget alignment */
    .elementor-element-c55046b,
    .elementor-element-c55046b .elementor-widget-container {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    
    /* Navigation menu container */
    .ekit-wid-con,
    .ekit_menu_responsive_tablet {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    /* Hamburger menu icon styling */
    .elementskit-menu-hamburger {
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        width: 32px !important;
        height: 32px !important;
        gap: 5px !important;
        padding: 0 !important;
        line-height: 0 !important;
        background: transparent !important;
        border: none !important;
    }
    
    .elementskit-menu-hamburger-icon {
        display: block !important;
        width: 24px !important;
        height: 2px !important;
        background-color: #333 !important;
        margin: 0 !important;
    }
}


/* ===============================
   MOBILE PHONE FIXES (max-width: 767px)
   =============================== */

@media screen and (max-width: 767px) {
    
    /* Prevent horizontal scroll on mobile */
    .elementor-element-b206177,
    .elementor-element-b206177 .e-con-inner {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Header inner container - properly aligned */
    .elementor-element-b206177 .e-con-inner {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 10px 16px !important;
        min-height: 60px !important;
    }
    
    /* Menu container - centered and full height */
    .elementor-element-b0bd38a {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
        height: 100% !important;
        min-height: 40px !important;
    }
    
    /* Hamburger menu - pushed down to center */
    .elementskit-menu-toggler,
    .elementskit-menu-hamburger {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        height: 40px !important;
        min-height: 40px !important;
        margin-top: 10px !important;
    }
}


/* ===============================
   CONTACT FORM MOBILE RESPONSIVE
   =============================== */

@media (max-width: 768px) {
  .contact-form .form-row {
    flex-direction: column;
    gap: 20px;
  }
  
  .contact-form input,
  .contact-form textarea,
  .contact-form select,
  .contact-form input[type="submit"] {
    font-size: 14px;
    padding: 14px 16px;
  }

  .contact-heading {
    font-size: 24px;
    margin-bottom: 30px;
  }
  
  .wpcf7-response-output {
    font-size: 14px;
    padding: 14px 16px;
  }
}
