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

:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #dbeafe;
  --dark: #0f172a;
  --gray-900: #1e293b;
  --gray-700: #334155;
  --gray-500: #64748b;
  --gray-300: #cbd5e1;
  --gray-100: #f1f5f9;
  --white: #ffffff;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
  --shadow-lg: 0 10px 25px rgba(0,0,0,.1);
}

html { scroll-behavior: smooth; }
body { font-family: 'Inter', system-ui, sans-serif; color: var(--gray-900); line-height: 1.6; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
img { max-width: 100%; }

/* Nav */
.nav { position: fixed; top: 0; left: 0; right: 0; background: rgba(255,255,255,.92); backdrop-filter: blur(12px); z-index: 100; border-bottom: 1px solid var(--gray-100); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo { font-weight: 800; font-size: 1.25rem; color: var(--dark); text-decoration: none; }
.logo span { color: var(--primary); }
.nav-links { display: flex; gap: 32px; list-style: none; }
.nav-links a { text-decoration: none; color: var(--gray-700); font-weight: 500; font-size: .95rem; transition: color .2s; }
.nav-links a:hover { color: var(--primary); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; padding: 14px 28px; border-radius: 8px; font-weight: 600; font-size: 1rem; cursor: pointer; border: none; transition: all .2s; text-decoration: none; }
.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: var(--shadow-lg); }
.btn-outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover { background: var(--primary-light); }
.btn-full { width: 100%; }

/* Hero */
.hero { padding: 140px 0 80px; background: linear-gradient(135deg, #f8faff 0%, #e8f0fe 100%); text-align: center; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; line-height: 1.15; color: var(--dark); margin-bottom: 20px; }
.hero-sub { font-size: 1.2rem; color: var(--gray-500); max-width: 640px; margin: 0 auto 32px; }
.hero-cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 48px; }
.hero-stats { display: flex; gap: 48px; justify-content: center; flex-wrap: wrap; }
.stat { text-align: center; }
.stat strong { display: block; font-size: 2rem; color: var(--primary); }
.stat span { font-size: .875rem; color: var(--gray-500); }

/* Sections */
section { padding: 80px 0; }
h2 { font-size: 2rem; font-weight: 800; text-align: center; color: var(--dark); margin-bottom: 8px; }
.section-sub { text-align: center; color: var(--gray-500); font-size: 1.1rem; margin-bottom: 48px; }

/* Services */
.services { background: var(--white); }
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.service-card { background: var(--gray-100); border-radius: var(--radius); padding: 32px; transition: transform .2s, box-shadow .2s; }
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.service-icon { font-size: 2.5rem; margin-bottom: 16px; }
.service-card h3 { font-size: 1.2rem; margin-bottom: 8px; color: var(--dark); }
.service-card p { color: var(--gray-500); font-size: .95rem; }

/* How It Works */
.how-it-works { background: var(--gray-100); }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 32px; }
.step { text-align: center; padding: 32px; background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); }
.step-number { width: 56px; height: 56px; border-radius: 50%; background: var(--primary); color: var(--white); font-weight: 800; font-size: 1.5rem; display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; }
.step h3 { margin-bottom: 8px; color: var(--dark); }
.step p { color: var(--gray-500); font-size: .95rem; }

/* Contact */
.contact { background: var(--white); }
.quote-form { max-width: 640px; margin: 0 auto; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; color: var(--gray-700); }
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 12px 16px; border: 1px solid var(--gray-300); border-radius: 8px; font-size: 1rem; font-family: inherit; transition: border-color .2s; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.15); }
.form-status { text-align: center; margin-top: 12px; font-weight: 500; }
.form-status.success { color: #16a34a; }
.form-status.error { color: #dc2626; }

/* Footer */
.footer { background: var(--dark); color: var(--gray-300); padding: 32px 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; }
.footer .logo { color: var(--white); }
.footer p { font-size: .875rem; }

/* Chat Widget */
.chat-widget { position: fixed; bottom: 24px; right: 24px; z-index: 1000; }
.chat-toggle { width: 60px; height: 60px; border-radius: 50%; background: var(--primary); color: var(--white); border: none; cursor: pointer; box-shadow: 0 4px 16px rgba(37,99,235,.4); display: flex; align-items: center; justify-content: center; transition: transform .2s; }
.chat-toggle:hover { transform: scale(1.08); }
.chat-panel { position: absolute; bottom: 72px; right: 0; width: 380px; max-height: 520px; background: var(--white); border-radius: 16px; box-shadow: 0 12px 40px rgba(0,0,0,.15); display: flex; flex-direction: column; overflow: hidden; }
.chat-header { padding: 16px; background: var(--primary); color: var(--white); display: flex; align-items: center; }
.chat-header-info { display: flex; align-items: center; gap: 12px; }
.chat-avatar { width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,.2); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .85rem; }
.chat-status { font-size: .75rem; opacity: .8; }
.chat-contact-actions { display: flex; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--gray-100); background: #f8fbff; }
.chat-contact-btn { flex: 1; text-align: center; text-decoration: none; font-size: .8rem; font-weight: 600; border-radius: 999px; padding: 8px 10px; background: var(--primary); color: var(--white); }
.chat-contact-btn-secondary { background: #e2e8f0; color: var(--gray-700); }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 12px; min-height: 280px; max-height: 340px; }
.chat-msg { max-width: 85%; padding: 10px 14px; border-radius: 12px; font-size: .9rem; line-height: 1.5; word-wrap: break-word; }
.chat-msg.bot { background: var(--gray-100); color: var(--gray-900); align-self: flex-start; border-bottom-left-radius: 4px; }
.chat-msg.user { background: var(--primary); color: var(--white); align-self: flex-end; border-bottom-right-radius: 4px; }
.chat-msg.typing { color: var(--gray-500); font-style: italic; }
.chat-input-area { display: flex; padding: 12px; border-top: 1px solid var(--gray-100); gap: 8px; }
.chat-input-area input { flex: 1; padding: 10px 14px; border: 1px solid var(--gray-300); border-radius: 8px; font-size: .9rem; font-family: inherit; }
.chat-input-area input:focus { outline: none; border-color: var(--primary); }
.chat-send { width: 40px; height: 40px; border-radius: 8px; background: var(--primary); color: var(--white); border: none; cursor: pointer; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.chat-send:hover { background: var(--primary-dark); }

/* Responsive */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .form-row { grid-template-columns: 1fr; }
  .hero-stats { gap: 24px; }
  .footer-inner { flex-direction: column; gap: 8px; text-align: center; }
  .chat-panel { width: calc(100vw - 48px); right: -12px; }
  .chat-contact-actions { flex-direction: column; }
}
