/* === COMPONENTS: FORMS & INPUTS === */
/* ===================================================================
   CONTACT & ON-PAGE FORMS (Section 5 Reusable Forms)
   =================================================================== */
.contact-section {
  padding: 95px 0;
  background: var(--bg-alt);
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 40px;
  align-items: start;
}

.contact-info-panel {
  background: linear-gradient(135deg, #064e3b 0%, #042f2e 100%);
  color: #ffffff;
  padding: 40px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
}

.contact-info-panel h3 {
  color: #ffffff;
  font-size: 1.75rem;
  margin-bottom: 12px;
}

.contact-channels {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin: 28px 0;
}

.channel-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.channel-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  flex-shrink: 0;
}

.channel-details strong {
  display: block;
  font-size: 0.92rem;
  color: #ffffff;
  margin-bottom: 2px;
}

.channel-details a, .channel-details span {
  font-size: 0.85rem;
  color: #cbd5e1;
}

.contact-form-card {
  background: #ffffff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: var(--shadow-md);
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-field {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-dark);
  margin-bottom: 6px;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 11px 14px;
  background: var(--bg-main);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  color: var(--text-dark);
  transition: var(--transition);
  outline: none;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--primary);
  background: #ffffff;
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-consent-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.form-consent-box input[type="checkbox"] {
  margin-top: 3px;
}


/* === COMPONENTS: MODALS & FLOATING ACTIONS === */
/* ===================================================================
   MODALS (Centered & Clean Blur)
   =================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(9, 19, 31, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

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

.modal-dialog {
  background: #ffffff;
  border-radius: var(--radius-xl);
  max-width: 780px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
  position: relative;
  transform: translateY(20px) scale(0.98);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.active .modal-dialog {
  transform: translateY(0) scale(1);
}

.modal-header {
  padding: 22px 28px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  background: #ffffff;
  z-index: 10;
}

.modal-title {
  font-size: 1.35rem;
  color: var(--text-dark);
}

.modal-close-btn {
  background: var(--bg-alt);
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  color: var(--text-dark);
  transition: var(--transition);
}

.modal-close-btn:hover {
  background: #fee2e2;
  color: #dc2626;
}

.modal-body {
  padding: 28px;
}

/* Floating Actions */
.floating-whatsapp {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.85rem;
  box-shadow: 0 10px 25px rgba(37, 211, 102, 0.4);
  z-index: 999;
  cursor: pointer;
  transition: var(--transition);
  animation: pulseWa 2.8s infinite;
}

@keyframes pulseWa {
  0% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.65), 0 10px 25px rgba(37, 211, 102, 0.4);
  }
  70% {
    box-shadow: 0 0 0 16px rgba(37, 211, 102, 0), 0 10px 25px rgba(37, 211, 102, 0.4);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0), 0 10px 25px rgba(37, 211, 102, 0.4);
  }
}

.floating-whatsapp svg {
  width: 32px;
  height: 32px;
  fill: #ffffff;
  display: block;
  pointer-events: none;
}

.floating-whatsapp:hover {
  transform: scale(1.12);
  box-shadow: 0 14px 30px rgba(37, 211, 102, 0.6);
}

.back-to-top {
  position: fixed;
  bottom: 96px;
  right: 32px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #ffffff;
  color: var(--primary);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: var(--shadow-md);
  z-index: 998;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--primary);
  color: #ffffff;
  transform: translateY(-4px);
}

/* ===================================================================
   RESPONSIVE DESIGN SYSTEM (MOBILE, TABLET & COMPACT DESKTOP)
   =================================================================== */

/* Body scroll lock when mobile navigation drawer is active */
body.nav-open {
  overflow: hidden;
  touch-action: none;
}

/* 1. Large Laptops / Desktops (<= 1400px) */
@media (max-width: 1400px) {
  .main-header .container.navbar {
    padding: 0 18px;
  }
  .navbar {
    gap: 8px;
  }
  .brand-logo-img {
    height: 38px;
  }
  .brand-title {
    font-size: 1.18rem;
  }
  .brand-tag-pill {
    font-size: 0.6rem;
    padding: 2px 7px;
  }
  .nav-menu {
    gap: 4px;
  }
  .nav-link {
    font-size: 0.8rem;
    padding: 6px 8px;
  }
}

/* 2. Compact Desktops & Landscape Tablets (<= 1140px) */
@media (max-width: 1140px) {
  .trust-strip-inner { grid-template-columns: repeat(2, 1fr); }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .benefits-grid, .team-grid { grid-template-columns: repeat(2, 1fr); }
  .solutions-grid { grid-template-columns: repeat(2, 1fr); }
  .service-detail-card { grid-template-columns: 1fr; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .cred-grid { grid-template-columns: repeat(2, 1fr); }
  .workflow-steps-grid { grid-template-columns: repeat(3, 1fr); }
  .epc-hub-grid { grid-template-columns: 1fr; }
  .footer-top, .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}

/* 3. Mobile Navigation Drawer Activation (<= 1024px) */
@media (max-width: 1024px) {
  .nav-toggle {
    display: inline-flex !important;
  }

  .nav-menu {
    position: fixed;
    top: 60px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 60px);
    height: calc(100dvh - 60px);
    background: #ffffff;
    flex-direction: column;
    padding: 20px 18px 48px;
    gap: 4px;
    transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    align-items: stretch;
    z-index: 999;
  }

  .nav-menu.active {
    left: 0;
  }

  .nav-item {
    width: 100%;
    border-bottom: 1px solid #f1f5f9;
    padding: 2px 0;
  }

  .nav-item:last-child {
    border-bottom: none;
  }

  .nav-link {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
  }

  .nav-link:hover,
  .nav-link:focus {
    background: rgba(5, 150, 105, 0.08);
    color: #047857;
  }

  .nav-link.active {
    background: rgba(5, 150, 105, 0.12);
    color: #047857;
  }

  /* Prevent desktop hover glitch on mobile touch */
  .nav-item:hover .dropdown-menu {
    display: none !important;
    visibility: hidden !important;
  }

  .dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    border-left: 3px solid #059669;
    background: #f8fafc;
    border-radius: 8px;
    padding: 8px 10px;
    margin: 4px 0 10px 12px;
    display: none;
    flex-direction: column;
    gap: 6px;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    width: auto;
    min-width: 0;
  }

  .dropdown-menu::before {
    display: none !important;
  }

  .nav-item.mobile-open .dropdown-menu {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  .nav-item.mobile-open .caret {
    transform: rotate(180deg);
    color: #059669;
  }

  .dropdown-item {
    padding: 8px 10px;
    border-radius: 6px;
  }
}

/* 4. Tablets & Mid-size Handhelds (<= 768px) */
@media (max-width: 768px) {
  .top-bar {
    display: none;
  }

  /* Container & Section Spacing */
  .container {
    padding: 0 18px;
  }

  .hero-section {
    padding: 44px 0 54px;
  }

  .benefits-section,
  .dashboard-preview-section,
  .services-section,
  .solutions-section,
  .epc-partners-section,
  .how-it-works-section,
  .calc-section,
  .about-section,
  .credentials-section,
  .faq-section,
  .contact-section {
    padding: 50px 0;
  }

  .section-tag {
    font-size: 0.74rem;
    padding: 5px 12px;
    margin-bottom: 10px;
  }

  .section-title {
    font-size: clamp(1.75rem, 5.5vw, 2.15rem);
    line-height: 1.22;
    margin-bottom: 12px;
  }

  .section-subtitle {
    font-size: 0.96rem;
    line-height: 1.55;
    margin-bottom: 30px;
  }

  /* Hero Section */
  .hero-title {
    font-size: clamp(1.95rem, 6.8vw, 2.5rem);
    line-height: 1.18;
    margin-bottom: 16px;
  }

  .hero-description {
    font-size: 0.98rem;
    line-height: 1.58;
    margin-bottom: 24px;
  }

  .hero-ctas {
    gap: 12px;
    margin-bottom: 30px;
  }

  .hero-visual-card {
    border-radius: 18px;
  }

  .hero-img {
    height: 320px;
  }

  /* Grid Reductions */
  .benefits-grid,
  .team-grid,
  .solutions-grid,
  .contact-layout,
  .form-grid-2,
  .mission-vision-grid,
  .srv-inclusions-list,
  .trust-strip-inner,
  .partner-models-grid {
    grid-template-columns: 1fr;
  }

  .workflow-steps-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .dash-stats-row {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  /* Card Paddings */
  .service-detail-card {
    padding: 26px 20px;
    border-radius: 18px;
    gap: 24px;
  }

  .contact-info-panel,
  .contact-form-card,
  .about-intro-box,
  .partner-steps-card {
    padding: 26px 20px;
    border-radius: 18px;
  }

  /* Calculator Mobile */
  .calculator-wrapper {
    grid-template-columns: 1fr;
    border-radius: 18px;
  }

  .calc-inputs-panel,
  .calc-results-panel {
    padding: 26px 20px;
  }

  .calc-cards-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .result-metric-card.subsidy-card {
    grid-column: span 2;
  }

  /* Dashboard Mockup Mobile */
  .dashboard-mockup-wrapper {
    padding: 20px 16px;
    border-radius: 18px;
  }

  .dashboard-top-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .dashboard-tabs {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 3px;
  }

  .dashboard-tabs::-webkit-scrollbar {
    display: none;
  }

  .dash-tab-btn {
    flex: 1 0 auto;
    padding: 7px 12px;
    font-size: 0.8rem;
    white-space: nowrap;
    text-align: center;
  }

  .svg-chart-container {
    height: 190px;
  }

  .svg-power-curve {
    height: 150px;
  }

  /* Footer Mobile */
  .footer-top,
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 14px;
  }

  .footer-legal-links {
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
  }

  /* Modals Mobile */
  .modal-overlay {
    padding: 12px;
  }

  .modal-dialog {
    max-height: 92vh;
    border-radius: 18px;
  }

  .modal-header {
    padding: 18px 20px;
  }

  .modal-body {
    padding: 20px 18px;
  }

  /* Floating Buttons */
  .floating-whatsapp {
    bottom: 20px;
    right: 20px;
    width: 52px;
    height: 52px;
  }

  .floating-whatsapp svg {
    width: 28px;
    height: 28px;
  }

  .back-to-top {
    bottom: 80px;
    right: 24px;
    width: 38px;
    height: 38px;
  }
}

/* 5. Standard Smartphones (<= 540px) */
@media (max-width: 540px) {
  .container {
    padding: 0 16px;
  }

  /* Header Branding */
  .main-header .container.navbar {
    padding: 0 14px;
  }

  .brand-logo-img {
    height: 33px;
  }

  .brand-title {
    font-size: 1.1rem;
  }

  .brand-tag-pill {
    display: none;
  }

  /* Hero Adjustments */
  .hero-section {
    padding: 36px 0 44px;
  }

  .hero-title {
    font-size: clamp(1.72rem, 7.8vw, 2.15rem);
    letter-spacing: -0.4px;
  }

  .hero-ctas {
    flex-direction: column;
    width: 100%;
  }

  .hero-ctas .btn {
    width: 100%;
    justify-content: center;
    padding: 12px 16px;
  }

  .hero-stats-bar {
    grid-template-columns: 1fr;
    gap: 10px;
    padding-top: 18px;
  }

  .hero-stat-item {
    display: flex;
    align-items: baseline;
    gap: 12px;
    justify-content: center;
    background: rgba(255, 255, 255, 0.06);
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
  }

  .hero-stat-item h4 {
    font-size: 1.45rem;
    margin-bottom: 0;
  }

  .hero-stat-item p {
    font-size: 0.82rem;
    margin: 0;
  }

  .hero-img {
    height: 240px;
  }

  .floating-pill-card {
    display: none;
  }

  /* Calculator Mobile */
  .calc-property-types {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .calc-cards-grid {
    grid-template-columns: 1fr;
  }

  .result-metric-card.subsidy-card {
    grid-column: span 1;
  }

  .lifetime-banner {
    flex-direction: column;
    text-align: center;
    gap: 8px;
    padding: 14px 12px;
  }

  .lifetime-amount {
    font-size: 1.35rem;
  }

  .calc-results-panel .btn {
    width: 100%;
    justify-content: center;
  }

  /* Form Elements Font Size (prevents iOS auto-zoom) */
  .form-input,
  .form-select,
  .form-textarea {
    font-size: 16px !important;
    padding: 12px 14px;
  }

  /* Steps and Cards */
  .workflow-steps-grid {
    grid-template-columns: 1fr;
  }

  .workflow-step-card {
    display: flex;
    align-items: center;
    text-align: left;
    gap: 14px;
    padding: 16px 14px;
  }

  .wf-step-badge {
    margin: 0;
    flex-shrink: 0;
  }

  .cred-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  /* Modal bottom-sheet style on phone screens */
  .modal-overlay {
    padding: 0;
    align-items: flex-end;
  }

  .modal-dialog {
    max-height: 94vh;
    border-radius: 20px 20px 0 0;
    width: 100%;
  }

  .modal-header {
    padding: 16px 18px;
  }

  .modal-title {
    font-size: 1.15rem;
  }

  .modal-body {
    padding: 18px 16px 28px;
  }

  /* Page Banners on Subpages */
  .page-banner {
    padding: 42px 16px 32px !important;
  }

  .page-banner h1 {
    font-size: 1.75rem !important;
    line-height: 1.25 !important;
  }

  .page-banner p {
    font-size: 0.92rem !important;
  }
}

/* 6. Ultra-compact Handhelds (<= 380px) */
@media (max-width: 380px) {
  .brand-title {
    font-size: 1.02rem;
  }

  .hero-title {
    font-size: 1.6rem;
  }

  .section-title {
    font-size: 1.55rem;
  }

  .calc-inputs-panel,
  .calc-results-panel,
  .service-detail-card,
  .contact-form-card,
  .contact-info-panel {
    padding: 18px 14px;
  }

  .dash-stats-row {
    grid-template-columns: 1fr;
  }
}

/* ===================================================================
   COOKIE & PRIVACY COMPLIANCE BANNER (Glassmorphism & DPDP Act 2023)
   =================================================================== */
.cookie-banner-wrapper {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(140%);
  width: calc(100% - 36px);
  max-width: 860px;
  z-index: 999999;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  box-shadow: 0 24px 50px -12px rgba(0, 0, 0, 0.55), 0 0 25px rgba(16, 185, 129, 0.2);
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.45s ease;
  opacity: 0;
  pointer-events: none;
}

.cookie-banner-wrapper.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.cookie-content {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
}

.cookie-icon {
  font-size: 1.4rem;
  background: rgba(16, 185, 129, 0.16);
  border: 1px solid rgba(16, 185, 129, 0.35);
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cookie-text {
  font-size: 0.84rem;
  color: #cbd5e1;
  line-height: 1.5;
}

.cookie-text strong {
  display: block;
  font-size: 0.92rem;
  color: #ffffff;
  margin-bottom: 2px;
  font-weight: 700;
}

.cookie-text a {
  color: #34d399;
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
  transition: color 0.2s ease;
}

.cookie-text a:hover {
  color: #6ee7b7;
}

.cookie-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.btn-cookie-accept {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  border: none;
  padding: 9px 18px;
  border-radius: 10px;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.25s ease;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.btn-cookie-accept:hover {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.5);
}

.btn-cookie-essential {
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  padding: 8px 15px;
  border-radius: 10px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-cookie-essential:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
}

@media (max-width: 768px) {
  .cookie-banner-wrapper {
    flex-direction: column;
    align-items: stretch;
    bottom: 16px;
    padding: 16px 16px;
    width: calc(100% - 24px);
    gap: 14px;
    border-radius: 16px;
  }
  .cookie-content {
    align-items: flex-start;
  }
  .cookie-actions {
    flex-direction: column;
    width: 100%;
    gap: 8px;
  }
  .btn-cookie-accept,
  .btn-cookie-essential {
    width: 100%;
    text-align: center;
    padding: 11px 16px;
  }
}

/* ===================================================================
   CLOUDFLARE TURNSTILE SECURITY VERIFICATION WIDGET
   =================================================================== */
.cf-turnstile-wrap {
  margin: 16px 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 65px;
}


