/* ==========================================
   CSS VARIABLES & RESET
   ========================================== */
:root {
  --primary: #0284c7;
  --primary-hover: #0369a1;
  --secondary: #0f172a;
  --accent: #38bdf8;
  --bg-light: #f8fafc;
  --text-main: #334155;
  --text-muted: #64748b;
  --white: #ffffff;
  --border: #e2e8f0;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.05);
  --shadow-lg: 0 10px 25px -5px rgba(0,0,0,0.1);
  --radius: 12px;
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: American Typewriter, serif;
}

html {
  scroll-behavior: smooth;
}

body {
  color: var(--text-main);
  background-color: var(--white);
  line-height: 1.6;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

/* ==========================================
   UTILITIES & LAYOUT
   ========================================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
}

.btn-primary {
  background-color: var(--primary);
  color: var(--white);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}

.btn-outline:hover {
  background-color: var(--primary);
  color: var(--white);
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 3.5rem auto;
}

.section-header span {
  color: var(--primary);
  text-transform: uppercase;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 1px;
}

.section-header h2 {
  font-size: 2.25rem;
  color: var(--secondary);
  margin-top: 0.5rem;
}

/* ==========================================
   NAVBAR
   ========================================== */
.navbar {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  border-bottom: 1px solid var(--border);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 80px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--secondary);
}

.logo i {
  color: var(--primary);
}

.logo-img {
  height: 40px;
  width: auto;
  object-fit: contain;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links a {
  font-weight: 500;
  color: var(--text-main);
  transition: var(--transition);
}

.nav-links a:hover {
  color: var(--primary);
}

.menu-toggle {
  display: none;
  font-size: 1.5rem;
  cursor: pointer;
}

/* ==========================================
   HERO SECTION
   ========================================== */
.hero {
  padding: 5rem 0;
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.hero-content h1 {
  font-size: 3.25rem;
  line-height: 1.15;
  color: var(--secondary);
  margin-bottom: 1.25rem;
}

.hero-content h1 span {
  color: var(--primary);
}

.hero-content p {
  font-size: 1.125rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.hero-badges {
  display: flex;
  gap: 1.5rem;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(0,0,0,0.08);
}

.badge-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.badge-item i {
  font-size: 1.5rem;
  color: var(--primary);
}

.badge-text strong {
  display: block;
  color: var(--secondary);
  font-size: 1.1rem;
}

.badge-text span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.hero-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
}

.hero-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--secondary);
}

/* ==========================================
   CALCULATOR FORM
   ========================================== */
.calc-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--secondary);
}

.form-control, select {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 1rem;
  outline: none;
  transition: var(--transition);
  width: 100%;
}

.form-control:focus, select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.price-display {
  background: var(--bg-light);
  padding: 1rem;
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 0.5rem;
}

.price-amount {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--primary);
}

/* Location Input with Detect Button */
.location-input-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  position: relative;
}

.location-input-wrapper input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 1rem;
  outline: none;
  transition: var(--transition);
  width: 100%;
  background: var(--white);
  cursor: pointer;
}

.location-input-wrapper input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.location-input-wrapper input::placeholder {
  color: var(--text-muted);
}

.location-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  background: var(--primary);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  cursor: pointer;
  transition: var(--transition);
}

.location-btn:hover {
  background: var(--primary-hover);
  transform: scale(1.05);
}

.location-btn:active {
  transform: scale(0.95);
}

/* Phone Input with +91 Prefix */
.phone-input-wrapper {
  display: flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: var(--transition);
  background: var(--white);
}

.phone-input-wrapper:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.phone-prefix {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 0.75rem;
  background: var(--bg-light);
  border-right: 1px solid var(--border);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--secondary);
  white-space: nowrap;
}

.phone-input-wrapper input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: none;
  outline: none;
  font-size: 1rem;
  width: 100%;
  background: transparent;
}

.phone-input-wrapper input::placeholder {
  color: var(--text-muted);
}

/* ==========================================
   SERVICES SECTION
   ========================================== */
.services {
  padding: 6rem 0;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.service-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem 2rem;
  transition: var(--transition);
  position: relative;
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.service-icon {
  width: 60px;
  height: 60px;
  background: #e0f2fe;
  color: var(--primary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
}

.service-card h3 {
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
  color: var(--secondary);
}

.service-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.service-features {
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
  margin-bottom: 1.5rem;
}

.service-features li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  color: var(--text-main);
}

.service-features i {
  color: #10b981;
}

/* ==========================================
   WHY CHOOSE US
   ========================================== */
.features {
  padding: 6rem 0;
  background-color: var(--bg-light);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature-card {
  text-align: center;
  padding: 2rem;
}

.feature-icon {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 1.25rem;
}

.feature-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--secondary);
}

.feature-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ==========================================
   TESTIMONIALS
   ========================================== */
.testimonials {
  padding: 6rem 0;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.testimonial-card {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.stars {
  color: #f59e0b;
  margin-bottom: 1rem;
}

.testimonial-card p {
  color: var(--text-main);
  font-style: italic;
  margin-bottom: 1.5rem;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.avatar {
  width: 48px;
  height: 48px;
  background-color: #cbd5e1;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--secondary);
}

.user-details h4 {
  font-size: 1rem;
  color: var(--secondary);
}

.user-details span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ==========================================
   FOOTER
   ========================================== */
footer {
  background-color: var(--secondary);
  color: var(--white);
  padding: 4rem 0 2rem 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-about p {
  color: #94a3b8;
  margin-top: 1rem;
  margin-bottom: 1.5rem;
  max-width: 320px;
}

.footer-col h4 {
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
  color: var(--white);
}

.footer-col ul li {
  margin-bottom: 0.75rem;
}

.footer-col ul a {
  color: #94a3b8;
  transition: var(--transition);
}

.footer-col ul a:hover {
  color: var(--white);
}

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 2rem;
  text-align: center;
  color: #64748b;
  font-size: 0.9rem;
}

/* ==========================================
   SUCCESS POPUP MODAL
   ========================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-box {
  background: var(--white);
  border-radius: 20px;
  padding: 2.5rem;
  width: 90%;
  max-width: 420px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  transform: translateY(20px) scale(0.95);
  transition: transform 0.3s ease;
}

.modal-overlay.active .modal-box {
  transform: translateY(0) scale(1);
}

.modal-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 1.25rem auto;
  background: #d1fae5;
  color: #10b981;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
}

.modal-box h3 {
  font-size: 1.5rem;
  color: var(--secondary);
  margin-bottom: 0.75rem;
}

.modal-box p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.75rem;
  line-height: 1.6;
}

.modal-box .btn {
  width: 100%;
  justify-content: center;
}

/* ==========================================
   RESPONSIVE DESIGN
   ========================================== */
@media (max-width: 992px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .hero-content h1 {
    font-size: 2.5rem;
  }
  .nav-links {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    width: 100%;
    background: var(--white);
    flex-direction: column;
    padding: 2rem;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
  }
  .nav-links.active {
    display: flex;
  }
  .menu-toggle {
    display: block;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
}