/* =========================
   Global Styles
   ========================= */
:root {
  --primary-color: #1e3a8a;
  --secondary-color: #ff9800;
  --accent-color: #3b82f6;
  --text-color: #333333;
  --light-text: #ffffff;
  --light-bg: #f8f9fa;
  --dark-bg: #1a1a1a;
  --border-color: #e0e0e0;
  --success-color: #4caf50;
  --error-color: #f44336;
  --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Poppins', sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: #fff;
  overflow-x: hidden;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.logo-img { height: 30px; width: auto; }

section { padding: 80px 0; }

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 15px;
}

p { margin-bottom: 15px; }

a {
  text-decoration: none;
  color: var(--primary-color);
  transition: var(--transition);
}
a:hover { color: var(--secondary-color); }

ul { list-style: none; }
img { max-width: 100%; height: auto; }

/* =========================
   Buttons
   ========================= */
.btn {
  display: inline-block;
  padding: 12px 30px;
  border-radius: 50px;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  outline: none;
}

.btn-primary {
  background-color: var(--primary-color);
  color: var(--light-text);
}
.btn-primary:hover {
  background-color: #152a66;
  color: var(--light-text);
  transform: translateY(-3px);
  box-shadow: var(--box-shadow);
}

.btn-secondary {
  background-color: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}
.btn-secondary:hover {
  background-color: var(--primary-color);
  color: var(--light-text);
  transform: translateY(-3px);
  box-shadow: var(--box-shadow);
}

.btn-text {
  color: var(--primary-color);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
}
.btn-text i { margin-left: 5px; transition: var(--transition); }
.btn-text:hover i { transform: translateX(5px); }

/* =========================
   Section Header
   ========================= */
.section-header { text-align: center; margin-bottom: 50px; }
.section-header h2 {
  font-size: 36px;
  color: var(--primary-color);
  position: relative;
  display: inline-block;
  margin-bottom: 15px;
}
.section-header h2::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 70px;
  height: 3px;
  background-color: var(--secondary-color);
}
.section-header p { font-size: 18px; color: #666; }

/* =========================
   Header
   ========================= */
header {
  position: fixed;
  top: 0; left: 0; width: 100%;
  z-index: 1000;
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
}

.header-content {
  display: flex; justify-content: space-between; align-items: center;
  height: 80px;
}

.logo h1 { font-size: 28px; font-weight: 700; color: var(--primary-color); margin: 0; }
.logo span { color: var(--secondary-color); }

.nav-links { display: flex; }
.nav-links li { margin: 0 15px; }
.nav-links a {
  color: var(--text-color); font-weight: 500; position: relative;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -5px; left: 0;
  width: 0; height: 2px; background-color: var(--primary-color);
  transition: var(--transition);
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

.mobile-menu { display: none; font-size: 24px; cursor: pointer; }

/* =========================
   Hero
   ========================= */
.hero {
  padding: 160px 0 80px;
  background: linear-gradient(135deg, #f5f7ff 0%, #e8eeff 100%);
}
.hero-content { display: flex; align-items: center; justify-content: space-between; }
.hero-text { flex: 1; padding-right: 40px; }
.hero-text h1 { font-size: 48px; color: var(--primary-color); margin-bottom: 20px; }
.hero-text p { font-size: 18px; color: #555; margin-bottom: 30px; }
.hero-buttons { display: flex; gap: 15px; }
.hero-image { flex: 1; text-align: right; }

/* =========================
   Services
   ========================= */
.services { background-color: var(--light-bg); }
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}
.service-card {
  background-color: #fff; border-radius: 10px; padding: 30px; text-align: center;
  box-shadow: var(--box-shadow); transition: var(--transition);
}
.service-card:hover { transform: translateY(-10px); box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1); }
.service-icon {
  width: 70px; height: 70px; background-color: rgba(30, 58, 138, 0.1);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
}
.service-icon i { font-size: 30px; color: var(--primary-color); }
.service-card h3 { font-size: 20px; margin-bottom: 15px; }
.service-card p { color: #666; }

/* =========================
   About
   ========================= */
.about-content { display: flex; align-items: center; gap: 50px; }
.about-image { flex: 1; }
.about-text { flex: 1; }
.about-text .section-header { text-align: left; }
.about-text .section-header h2::after { left: 0; transform: none; }
.about-stats { display: flex; justify-content: space-between; margin-top: 30px; }
.stat { text-align: center; }
.stat h3 { font-size: 36px; color: var(--primary-color); margin-bottom: 5px; }
.stat p { color: #666; font-size: 14px; }

/* =========================
   Loan Types
   ========================= */
.loan-types-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px;
}
.loan-type-card {
  background-color: #fff; border-radius: 10px; padding: 30px;
  box-shadow: var(--box-shadow); transition: var(--transition);
  border-bottom: 3px solid transparent;
}
.loan-type-card:hover { border-bottom: 3px solid var(--primary-color); transform: translateY(-5px); }
.loan-type-icon {
  width: 60px; height: 60px; background-color: rgba(30, 58, 138, 0.1);
  border-radius: 10px; display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
}
.loan-type-icon i { font-size: 24px; color: var(--primary-color); }
.loan-type-card h3 { font-size: 20px; margin-bottom: 15px; }
.loan-type-card p { color: #666; margin-bottom: 20px; }

/* =========================
   Loan Calculator
   ========================= */
.loan-calculator { background-color: var(--light-bg); }
.calculator-container {
  display: flex; background-color: #fff; border-radius: 10px; overflow: hidden; box-shadow: var(--box-shadow);
}
.calculator-form { flex: 1; padding: 30px; border-right: 1px solid var(--border-color); }
.calculator-result {
  flex: 1; padding: 30px; background-color: #f8f9ff; display: flex; flex-wrap: wrap;
}
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 500; }
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: 12px 15px; border: 1px solid var(--border-color);
  border-radius: 5px; font-family: 'Poppins', sans-serif; font-size: 16px;
  transition: var(--transition);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--primary-color); outline: none; box-shadow: 0 0 0 2px rgba(30, 58, 138, 0.2);
}
.result-item { flex: 1 0 50%; margin-bottom: 20px; }
.result-item h4 { font-size: 16px; color: #666; margin-bottom: 5px; }
.result-item p { font-size: 24px; font-weight: 600; color: var(--primary-color); }
.pie-chart { width: 100%; margin-top: 20px; }

/* =========================
   Testimonials
   ========================= */
.testimonial-slider { display: flex; overflow: hidden; margin-bottom: 30px; }
.testimonial-card {
  flex: 0 0 100%; background-color: #fff; border-radius: 10px; padding: 30px;
  box-shadow: var(--box-shadow); margin: 0 15px; transition: var(--transition);
}
.client-rating { color: #ffc107; margin-bottom: 15px; }
.testimonial-text { font-style: italic; margin-bottom: 20px; }
.client-info { display: flex; align-items: center; }
.client-image { width: 60px; height: 60px; border-radius: 50%; overflow: hidden; margin-right: 15px; }
.client-details h4 { font-size: 18px; margin-bottom: 5px; }
.client-details p { color: #666; font-size: 14px; }
.testimonial-controls {
  display: flex; justify-content: center; gap: 15px;
}
.prev-btn, .next-btn {
  width: 40px; height: 40px; border-radius: 50%; background-color: #fff;
  border: 1px solid var(--border-color); display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: var(--transition);
}
.prev-btn:hover, .next-btn:hover {
  background-color: var(--primary-color); color: #fff; border-color: var(--primary-color);
}

/* =========================
   Contact
   ========================= */
.contact-content { display: flex; gap: 50px; }
.contact-form {
  flex: 1; background-color: #fff; border-radius: 10px; padding: 30px; box-shadow: var(--box-shadow);
}
.contact-info { flex: 1; }
.info-item { display: flex; margin-bottom: 30px; }
.info-icon {
  width: 50px; height: 50px; background-color: rgba(30, 58, 138, 0.1);
  border-radius: 50%; display: flex; align-items: center; justify-content: center; margin-right: 15px;
}
.info-icon i { font-size: 20px; color: var(--primary-color); }
.info-content h4 { font-size: 18px; margin-bottom: 5px; }
.info-content p { color: #666; margin-bottom: 5px; }

.social-links {
  display: flex; gap: 15px; margin-top: 30px; justify-content: center; padding: 20px 0;
}
.social-link {
  width: 40px; height: 40px; background-color: rgba(30, 58, 138, 0.1);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  color: var(--primary-color); transition: var(--transition);
}
.social-link:hover { background-color: var(--primary-color); color: #fff; transform: translateY(-3px); }

/* =========================
   Footer
   ========================= */
footer { background-color: #1a1a2e; color: #fff; padding: 70px 0 0; }
.footer-content { display: flex; justify-content: space-between; margin-bottom: 50px; }
.footer-logo { flex: 1; }
.footer-logo h2 { font-size: 28px; color: #fff; margin-bottom: 15px; }
.footer-logo span { color: var(--secondary-color); }
.footer-links { flex: 2; display: flex; justify-content: space-between; }
.footer-column h3 {
  font-size: 18px; color: #fff; margin-bottom: 20px; position: relative;
}
.footer-column h3::after {
  content: ''; position: absolute; bottom: -8px; left: 0; width: 40px; height: 2px; background-color: var(--secondary-color);
}
.footer-column ul li { margin-bottom: 10px; }
.footer-column ul li a { color: #bbb; transition: var(--transition); }
.footer-column ul li a:hover { color: var(--secondary-color); padding-left: 5px; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 0; display: flex; justify-content: space-between; align-items: center;
}
.payment-methods { display: flex; align-items: center; }
.payment-methods span { margin-right: 10px; color: #bbb; }

/* =========================
   Responsive
   ========================= */
@media (max-width: 1024px) {
  .hero-text h1 { font-size: 40px; }
  .about-content, .contact-content { flex-direction: column; }
  .calculator-container { flex-direction: column; }
  .calculator-form { border-right: none; border-bottom: 1px solid var(--border-color); }
}

@media (max-width: 768px) {
  section { padding: 60px 0; }
  .nav-links {
    position: fixed; top: 80px; left: -100%; width: 100%;
    height: calc(100vh - 80px); background-color: #fff;
    flex-direction: column; align-items: center; justify-content: center;
    transition: var(--transition);
  }
  .nav-links.active { left: 0; }
  .nav-links li { margin: 15px 0; }
  .mobile-menu { display: block; }
  .hero-content { flex-direction: column; text-align: center; }
  .hero-text { padding-right: 0; margin-bottom: 40px; }
  .hero-buttons { justify-content: center; }
  .footer-content { flex-direction: column; }
  .footer-logo { margin-bottom: 30px; text-align: center; }
  .footer-links { flex-direction: column; }
  .footer-column { margin-bottom: 30px; text-align: center; }
  .footer-column h3::after { left: 50%; transform: translateX(-50%); }
  .footer-bottom { flex-direction: column; text-align: center; }
  .payment-methods { margin-top: 15px; justify-content: center; }
}

@media (max-width: 576px) {
  .section-header h2 { font-size: 28px; }
  .hero-text h1 { font-size: 32px; }
  .about-stats { flex-direction: column; gap: 20px; }
  .testimonial-card { margin: 0; }
}

/* =========================
   Ask Diva Sticky Chatbot
   ========================= */

/* Icon */
#askDivaIcon {
  position: fixed; bottom: 20px; right: 20px;
  width: 80px; height: 80px;
  background: url('/ask-diva.png') no-repeat center center / cover; /* absolute path */
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  z-index: 10002;
  cursor: pointer;
  transition: transform 0.3s ease;
}
#askDivaIcon:hover { transform: scale(1.1); }

/* Popup (works for both inline UI OR iframe) */
#chatbox {
  display: none; /* hidden by default; JS toggles to block/flex */
  position: fixed; bottom: 110px; right: 20px;
  width: 340px; height: 480px;
  background: #fff; border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  z-index: 10001;
  overflow: hidden;            /* clip corners for iframe/inner content */
}

/* If you use iframe popup */
#chatbox iframe { width: 100%; height: 100%; border: none; }

/* If you use inline popup (header/body/footer), you can optionally add: */
/* .chat-header/.chat-body/.chat-footer styles live in your HTML page */
/* To show as flex when toggled in JS, either:
   - set style via JS -> box.style.display='flex', or
   - add a class and this rule:
#chatbox.open { display: flex; flex-direction: column; }
*/

/* Mobile tweak */
@media (max-width: 480px) {
  #chatbox { right: 10px; width: 92vw; height: 70vh; }
  #askDivaIcon { width: 64px; height: 64px; bottom: 16px; right: 16px; }
}
